@font-face {
  font-family: "Young Serif";
  src: url("fonts/young-serif-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Figtree";
  src: url("fonts/figtree-latin-wght-normal.woff2") format("woff2");
  font-weight: 300 900;
  font-display: swap;
}

:root {
  --cream: #fff5ee;
  --peach: #f9dcc9;
  --peach-2: #f3c6aa;
  --terra: #cf6a45;
  --terra-dark: #a9522f;
  --sage: #7f9f7e;
  --sage-tint: #e4eedf;
  --plum: #4a2e39;
  --muted: #7b6670;
  --line: #f0dccf;
  --card: #fffdfb;
  --serif: "Young Serif", Georgia, "Times New Roman", serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--plum);
  background:
    radial-gradient(60% 40% at 100% 0%, #fde6d6 0%, transparent 70%),
    radial-gradient(50% 40% at 0% 30%, #f1f5ea 0%, transparent 70%),
    var(--cream);
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--terra); outline-offset: 3px; }
.icon { width: 1.2em; height: 1.2em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Demo bar */
.demo-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 14px; padding: 2px 14px; background: var(--plum); color: #fff5ee; font-size: 14px; }
.demo-bar__note { margin: 0; display: flex; align-items: center; gap: 8px; padding: 6px 0; }
.demo-bar__note strong { padding: 1px 10px; border-radius: 999px; background: var(--peach); color: var(--plum); font-weight: 800; }
.demo-bar__actions { display: flex; gap: 4px; margin-left: auto; }
.demo-bar__reset, .demo-bar__made { display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px; border: 0; background: none; color: #fff5ee; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.demo-bar__made { color: var(--peach-2); }

.shell { max-width: 1120px; margin: 0 auto; padding: 22px 16px 48px; }

/* Hero */
.hero {
  display: grid;
  gap: 8px;
  align-items: center;
  padding: 22px 20px 0;
  border-radius: 32px;
  background: linear-gradient(160deg, #fbe2d3 0%, var(--peach) 60%, #f6cdb4 100%);
  overflow: hidden;
}
.hero__kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0; color: var(--terra-dark); font-weight: 800; font-size: 14px; letter-spacing: 0.04em; text-transform: uppercase; }
.hero h1 { margin: 6px 0 8px; font-family: var(--serif); font-weight: 400; font-size: clamp(42px, 11vw, 76px); line-height: 1; letter-spacing: -0.01em; }
.hero__lede { margin: 0; font-size: 18px; max-width: 40ch; }
.hero__by { margin: 10px 0 0; color: var(--muted); }
.pot { width: min(170px, 50%); justify-self: end; margin: -40px -4px -6px 0; }
.pot__steam { fill: none; stroke: #fff6ee; stroke-width: 5; stroke-linecap: round; opacity: 0.9; animation: steam 3.6s ease-in-out infinite; }
.pot__heart { fill: #e46f63; animation: float 3.6s ease-in-out infinite; transform-origin: 100px 74px; }
@keyframes steam { 50% { transform: translateY(-6px); opacity: 0.55; } }
@keyframes float { 50% { transform: translateY(-5px) scale(1.06); } }

/* Top cards */
.top-grid { display: grid; gap: 14px; margin: 16px 0 26px; }
.card { min-width: 0; padding: 20px; border-radius: 26px; background: var(--card); box-shadow: 0 1px 0 var(--line), 0 24px 44px -34px rgb(74 46 57 / 0.55); }
.card h2 { margin: 0 0 6px; font-family: var(--serif); font-weight: 400; font-size: 24px; line-height: 1.2; }
.progress h2 strong { font-size: 40px; color: var(--terra); }
.progress p { margin: 10px 0 14px; color: var(--muted); }
.meter { height: 14px; border-radius: 999px; background: #f6e6dc; overflow: hidden; }
.meter span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--sage), #a4bf96); }
.info ul { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 12px; }
.info li { display: flex; gap: 12px; align-items: flex-start; color: var(--muted); }
.info li .icon { margin-top: 2px; color: var(--terra); }
.info li strong { color: var(--plum); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 20px; border: 0; border-radius: 999px; font-weight: 800; font-size: 16px; transition: transform 0.1s ease, background 0.2s ease; }
.btn:active { transform: translateY(1px); }
.btn--terra { background: var(--terra); color: #fff; box-shadow: 0 10px 20px -12px rgb(207 106 69 / 0.9); }
.btn--terra:hover { background: var(--terra-dark); }
.btn--small { min-height: 44px; padding: 0 16px; background: var(--terra); color: #fff; font-size: 14px; }
.icon-btn { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border: 1.5px solid var(--line); border-radius: 50%; background: #fff; color: var(--terra-dark); }

/* Nights */
.layout { display: grid; gap: 22px; }
.section-title { margin: 0 0 6px; font-family: var(--serif); font-weight: 400; font-size: 30px; }
.week + .week { margin-top: 18px; }
.week h3 { margin: 12px 0 8px; font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.week ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.night {
  display: grid;
  grid-template-columns: 52px 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 8px 10px 8px 8px;
  border-radius: 20px;
  background: var(--card);
  box-shadow: 0 1px 0 var(--line);
}
.night__date { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--peach); line-height: 1; }
.night__date small { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; color: var(--terra-dark); }
.night__date strong { font-family: var(--serif); font-weight: 400; font-size: 22px; }
.night__who { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--c); color: #fff; font-weight: 800; }
.night__who--free { background: transparent; border: 2px dashed var(--terra); color: var(--terra); }
.night__text { display: grid; min-width: 0; }
.night__text strong { font-weight: 700; line-height: 1.25; }
.night__text small { color: var(--muted); font-size: 13px; }
.night__act { display: flex; align-items: center; gap: 6px; }
.night--free { background: #fffaf6; box-shadow: inset 0 0 0 2px #f2cdb9; }
.night--past { opacity: 0.62; }
.night--past .night__date { background: #efe4dc; }
.night--tonight { box-shadow: inset 0 0 0 2.5px var(--sage), 0 14px 30px -24px rgb(74 46 57 / 0.6); }
.night--mine { box-shadow: inset 0 0 0 2.5px var(--terra); }
.badge { padding: 4px 10px; border-radius: 999px; background: var(--sage); color: #fff; font-size: 12px; font-weight: 800; }
.night__done { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--sage-tint); color: var(--sage); }

/* Side */
.side { display: grid; gap: 16px; align-content: start; }
.menu p { margin: 0 0 12px; color: var(--muted); }
.menu__chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.menu__chips li { padding: 6px 12px; border-radius: 999px; background: var(--sage-tint); font-weight: 700; text-transform: capitalize; }
.menu__chips li.menu--lots { background: #fbe1d3; color: var(--terra-dark); }
.thanks { background: linear-gradient(170deg, #fff 0%, #fdf0e8 100%); }
.thanks__text { margin: 0; font-family: var(--serif); font-size: 21px; line-height: 1.4; }
.thanks__from { display: flex; align-items: center; gap: 8px; margin: 12px 0 0; color: var(--terra-dark); font-weight: 700; }

/* Make your own */
.own { margin-top: 34px; padding: 22px; border: 2px dashed var(--peach-2); border-radius: 26px; background: rgb(255 253 251 / 0.7); }
.own__label { margin: 0; font-size: 12px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--terra); }
.own__words { margin: 8px 0; font-family: var(--serif); font-size: 22px; line-height: 1.35; }
.own__note { margin: 0; font-size: 14px; color: var(--muted); }

/* Dialog */
.dialog { width: min(540px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); padding: 0; border: 0; border-radius: 28px; background: var(--card); color: var(--plum); box-shadow: 0 30px 70px -24px rgb(74 46 57 / 0.55); }
.dialog::backdrop { background: rgb(74 46 57 / 0.45); }
.dialog__body { padding: 20px 20px 22px; }
.dialog__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.dialog__title { margin: 0; font-family: var(--serif); font-weight: 400; font-size: 26px; }
.dialog__close { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border: 1.5px solid var(--line); border-radius: 50%; background: #fff; }
.dialog__close svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.form { display: grid; gap: 14px; }
.form__date { display: flex; align-items: center; gap: 8px; margin: 0; padding: 10px 14px; border-radius: 14px; background: var(--peach); font-weight: 700; }
.field { display: grid; gap: 6px; min-width: 0; }
.field__label { font-weight: 800; font-size: 14px; }
.field__note { font-size: 13px; color: var(--muted); }
.field input { width: 100%; min-height: 50px; padding: 0 14px; border: 1.5px solid #ead1c3; border-radius: 14px; background: #fff; font-size: 16px; }
.field input:focus { outline: none; border-color: var(--terra); box-shadow: 0 0 0 3px rgb(207 106 69 / 0.15); }
.form__hint { display: flex; gap: 8px; align-items: flex-start; margin: -4px 0 0; padding: 10px 12px; border-radius: 12px; background: #fff3d6; color: #7a5310; font-weight: 600; font-size: 14px; }
.form__problem { margin: 0; padding: 10px 12px; border-radius: 12px; background: #fbe1d3; color: var(--terra-dark); font-weight: 700; }
.form__actions { display: flex; justify-content: flex-end; }
.mail { display: grid; gap: 14px; }
.mail__head { margin: 0; display: grid; gap: 6px; padding: 12px 14px; border-radius: 14px; background: #fbefe7; font-size: 14px; }
.mail__head div { display: grid; grid-template-columns: 64px 1fr; gap: 8px; }
.mail__head dt { color: var(--muted); font-weight: 600; }
.mail__head dd { margin: 0; font-weight: 700; }
.mail__body p { margin: 0 0 10px; }
.mail__demo { margin: 0; font-size: 13px; font-weight: 700; color: var(--muted); }

.toast-region { position: fixed; left: 0; right: 0; bottom: 18px; z-index: 20; display: grid; justify-items: center; pointer-events: none; }
.toast { max-width: 560px; margin: 0 16px; padding: 12px 18px; border-radius: 18px; background: var(--plum); color: #fff5ee; font-weight: 700; box-shadow: 0 16px 30px -14px rgb(74 46 57 / 0.7); animation: toast-in 0.25s ease; }
@keyframes toast-in { from { transform: translateY(10px); opacity: 0; } }

@media (min-width: 760px) {
  .hero { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); padding: 34px 40px 0; }
  .hero__text { padding-bottom: 34px; }
  .pot { width: 100%; max-width: 300px; align-self: end; }
  .top-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); }
}

@media (min-width: 1000px) {
  .shell { padding: 32px 28px 64px; }
  .layout { grid-template-columns: minmax(0, 1.6fr) minmax(300px, 1fr); gap: 28px; align-items: start; }
  .side { position: sticky; top: 20px; }
}

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