:root {
  --canvas: #f5f0e7;
  --canvas-deep: #e5d9c7;
  --ink: #1d2429;
  --ink-muted: #4f5a5f;
  --panel: rgba(255, 255, 255, 0.74);
  --panel-strong: rgba(255, 255, 255, 0.86);
  --line: rgba(29, 36, 41, 0.14);
  --line-strong: rgba(29, 36, 41, 0.26);
  --teal: #1d7f79;
  --teal-deep: #125e5a;
  --amber: #bd7145;
  --error: #9f2f24;
  --shadow: 0 28px 56px rgba(30, 24, 16, 0.15);
  --shadow-soft: 0 12px 24px rgba(30, 24, 16, 0.09);
  --radius-lg: 24px;
  --radius-md: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: "Aptos", "Segoe UI Variable", "Bahnschrift", "Trebuchet MS", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1100px 520px at -8% -10%, #fbf8f3 0%, transparent 70%),
    radial-gradient(1000px 480px at 105% 2%, #d9e4df 0%, transparent 68%),
    linear-gradient(160deg, var(--canvas) 6%, var(--canvas-deep) 100%);
}

body::before,
body::after {
  content: "";
  position: fixed;
  pointer-events: none;
  z-index: -1;
}

body::before {
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.2) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.16) 1px, transparent 1px);
  background-size: 34px 34px;
  mix-blend-mode: soft-light;
}

body::after {
  right: 4vw;
  bottom: 5vh;
  width: min(38vw, 390px);
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  background: radial-gradient(circle at 35% 35%, rgba(29, 127, 121, 0.18), transparent 70%);
  filter: blur(2px);
}

.shell {
  width: min(1080px, calc(100% - 2.5rem));
  margin: 2.6rem auto 2rem;
  display: grid;
  gap: 1.15rem;
}

.hero {
  display: grid;
  gap: 0.58rem;
  animation: rise 0.52s ease both;
}

.eyebrow {
  margin: 0;
  align-self: start;
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.36rem 0.74rem;
  background: rgba(255, 255, 255, 0.5);
  color: var(--ink-muted);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 650;
}

h1 {
  margin: 0;
  font-family: "Palatino Linotype", "Book Antiqua", "Iowan Old Style", serif;
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 0.98;
  letter-spacing: -0.015em;
  max-width: 14ch;
  color: #14191d;
}

.subtitle {
  margin: 0;
  max-width: 62ch;
  font-size: 0.97rem;
  line-height: 1.6;
  color: var(--ink-muted);
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.05rem;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}

.controls,
.output {
  padding: 1.3rem;
  animation: rise 0.6s ease both;
}

.controls {
  background:
    linear-gradient(160deg, var(--panel-strong) 12%, rgba(255, 255, 255, 0.67) 100%);
}

.output {
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.84) 0%, rgba(224, 236, 233, 0.74) 100%);
  border-color: rgba(18, 94, 90, 0.2);
}

h2 {
  margin: 0 0 1rem;
  font-family: "Palatino Linotype", "Book Antiqua", "Iowan Old Style", serif;
  letter-spacing: 0.01em;
  font-size: 1.1rem;
  font-weight: 700;
}

label {
  display: block;
  margin: 0.68rem 0 0.4rem;
  color: var(--ink-muted);
  font-size: 0.84rem;
}

select,
input,
button {
  width: 100%;
  font: inherit;
  border-radius: var(--radius-md);
}

select,
input {
  border: 1px solid var(--line);
  padding: 0.74rem 0.82rem;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

select:focus,
input:focus {
  outline: 2px solid #2a9a93;
  border-color: transparent;
}

button {
  margin-top: 0.98rem;
  border: 0;
  padding: 0.88rem 0.94rem;
  color: #f8fbfb;
  font-weight: 640;
  letter-spacing: 0.01em;
  background: linear-gradient(120deg, var(--teal), var(--teal-deep));
  box-shadow: 0 10px 20px rgba(18, 94, 90, 0.24);
  cursor: pointer;
  transition: transform 0.14s ease, filter 0.2s ease;
}

button:hover {
  filter: brightness(1.04);
}

button:active {
  transform: translateY(1px);
}

.status {
  min-height: 1.25rem;
  margin: 0.78rem 0 0;
  color: var(--ink-muted);
  font-size: 0.82rem;
}

.status.error {
  color: var(--error);
}

.estimate {
  margin: 0.1rem 0 0;
  font-family: "Palatino Linotype", "Book Antiqua", "Iowan Old Style", serif;
  font-size: clamp(2.15rem, 4.2vw, 3rem);
  line-height: 1;
  letter-spacing: -0.02em;
  color: #0f4f4c;
}

.rate {
  margin: 0.34rem 0 1rem;
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.details {
  margin: 0;
  display: grid;
  gap: 0.62rem;
}

.details div {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 0.7rem;
  padding: 0.68rem 0.78rem;
  border: 1px solid rgba(18, 94, 90, 0.18);
  border-radius: 12px;
  background:
    linear-gradient(140deg, rgba(255, 255, 255, 0.72), rgba(248, 252, 251, 0.72));
  box-shadow: var(--shadow-soft);
}

.details dt {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.81rem;
}

.details dd {
  margin: 0;
  font-size: 0.83rem;
  font-weight: 640;
  text-align: right;
  color: #192529;
}

.footnote {
  padding: 0.88rem 1rem;
  background: rgba(255, 255, 255, 0.66);
  color: var(--ink-muted);
  font-size: 0.8rem;
  line-height: 1.45;
  animation: rise 0.68s ease both;
}

.footnote p {
  margin: 0.2rem 0;
}

.footnote a {
  color: var(--amber);
  font-weight: 660;
  text-decoration-color: rgba(189, 113, 69, 0.4);
  text-decoration-thickness: 1.5px;
}

.footnote a:hover {
  text-decoration-color: var(--amber);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 920px) {
  .shell {
    width: min(920px, calc(100% - 1.4rem));
    margin-top: 1.35rem;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  h1 {
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0s !important;
    transition-duration: 0s !important;
  }
}
