:root {
  font-family: "Segoe UI", Arial, sans-serif;
  color: #173b35;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 30px 16px;
  background: radial-gradient(ellipse at 30% 25%, #f5f7f0, #e9eee7 55%, #dce5dc);
}
.panel {
  position: relative;
  width: min(100%, 560px);
  padding: 58px 52px 64px;
  background: linear-gradient(110deg, #fffaf3, #f6ecdf 80%, #eee0cd);
  border: 13px solid #f9f2e7;
  border-radius: 4px;
  box-shadow:
    0 0 0 2px #d9cbb7,
    0 18px 45px #554d3b26,
    inset 0 0 0 2px #e8dac7,
    inset 8px 0 15px #ffffff80,
    inset -8px 0 15px #b9a58b20;
}
.panel::before {
  content: "";
  position: absolute;
  inset: 24px 20px;
  border: 2px solid #dfcfb8;
  border-radius: 48% 48% 2px 2px / 12% 12% 2px 2px;
  box-shadow: 0 0 0 4px #fff8ee, 0 0 0 6px #e7d9c6;
  pointer-events: none;
}
.panel::after {
  content: "";
  position: absolute;
  right: 5px;
  top: 63%;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 25%, #fff0c1, #d9ae66 50%, #8d6735);
  border: 2px solid #c59a58;
  box-shadow: 0 0 0 4px #b78b4d35, 1px 3px 5px #0003;
  pointer-events: none;
}
.brand {
  position: relative;
  font-family: Georgia, serif;
  font-size: 29px;
  font-weight: bold;
  text-align: center;
  color: #145b46;
}
.brand::after {
  content: "Stands out. Never shouts.";
  display: block;
  margin: 7px 0 23px;
  font-size: 13px;
  font-style: italic;
  font-weight: normal;
  color: #97743a;
}
.eyebrow {
  position: relative;
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #286653;
}
h1 {
  position: relative;
  font-family: Georgia, serif;
  font-size: 32px;
  text-align: center;
  color: #123e34;
  margin: 15px 0;
}
p {
  position: relative;
  font-size: 13px;
  line-height: 1.6;
  color: #53615a;
}
form {
  position: relative;
  display: grid;
  gap: 16px;
  margin-top: 25px;
}
label {
  display: grid;
  gap: 7px;
  font-size: 12px;
  font-weight: 700;
  color: #174a3b;
}
input, select {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid #d4c9ba;
  border-radius: 5px;
  background: #fffdfa;
  color: #173b35;
  font: inherit;
}
input:focus, select:focus {
  outline: 2px solid #b89b66;
}
button {
  height: 48px;
  margin-top: 8px;
  border: 0;
  border-radius: 6px;
  background: #17634c;
  color: white;
  font-weight: 700;
  cursor: pointer;
}
button:hover { background: #10513d; }
button:disabled { opacity: .6; cursor: wait; }
.status {
  position: relative;
  min-height: 16px;
  color: #17634c;
}
.fine {
  position: relative;
  margin-top: 18px;
  font-size: 10px;
  color: #69746e;
}
@media(max-width:600px) {
  .panel { padding: 44px 30px 50px; }
  .panel::before { inset: 15px 12px; }
  h1 { font-size: 27px; }
}

/* Refined brass lockset */
.panel::after {
  content: "";
  position: absolute;
  right: 22px;
  top: 59%;
  width: 21px;
  height: 74px;
  border-radius: 11px;
  background:
    radial-gradient(circle at 50% 22%,
      #fff0c4 0 8px,
      #d7ad64 9px,
      #90672f 11px,
      transparent 12px),
    linear-gradient(90deg,
      #a7793d,
      #e7c58a 35%,
      #b88743 75%,
      #8d642f);
  border: 1px solid #a77a3c;
  box-shadow:
    inset 1px 0 2px #fff2ca,
    2px 3px 6px #6b543544;
  pointer-events: none;
  z-index: 2;
}

/* Architectural cream doorframe */
.panel {
  margin-top: 24px;
  border: 16px solid #f7ecdc;
  border-top-width: 24px;
  border-bottom-width: 18px;
  border-radius: 2px;
  box-shadow:
    0 0 0 2px #d5bea0,
    0 0 0 7px #fff8ee,
    0 0 0 9px #ddc9ad,
    0 18px 28px #65513b33,
    inset 7px 0 10px #ffffffaa,
    inset -7px 0 12px #a68b6a33;
}

/* Projecting decorative crown molding */
.panel .brand::before {
  content: "";
  position: absolute;
  top: -107px;
  left: -91px;
  right: -91px;
  height: 19px;
  background: linear-gradient(
    to bottom,
    #fffaf1 0%,
    #f5e5d0 35%,
    #d7bea0 55%,
    #fff8ec 75%,
    #e7d3b9 100%
  );
  border: 1px solid #d4bda0;
  border-radius: 3px 3px 0 0;
  box-shadow: 0 5px 8px #66503a24;
  pointer-events: none;
}

@media(max-width:600px) {
  .panel .brand::before {
    left: -65px;
    right: -65px;
  }
}

/* KinaraFlow welcome-door animation */
body {
  perspective: 1800px;
}

.panel {
  transform-origin: left center;
  backface-visibility: hidden;
}

body.door-opening .panel {
  animation: kfDoorOpen 2.2s cubic-bezier(.42,0,.18,1) forwards;
}

@keyframes kfDoorOpen {
  0% {
    transform: rotateY(0deg);
    opacity: 1;
  }
  65% {
    transform: rotateY(-65deg);
    opacity: 1;
  }
  100% {
    transform: rotateY(-85deg);
    opacity: 0;
  }
}

body::before {
  content: "Welcome in";
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle, #fffaf1, #e5ede5);
  color: #145b46;
  font: italic 48px Georgia, serif;
  letter-spacing: 1px;
  opacity: 0;
  pointer-events: none;
}

body.door-opening::before {
  animation: kfWelcome 2.6s ease forwards;
}

@keyframes kfWelcome {
  0%, 25% { opacity: 0; }
  65%, 100% { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  body.door-opening .panel {
    animation: none;
    opacity: 0;
  }
  body.door-opening::before {
    animation: none;
    opacity: 1;
  }
}
