@font-face {
  font-family: 'Fraunces';
  src: url('../assets/fonts/fraunces.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Nunito';
  src: url('../assets/fonts/nunito.woff2') format('woff2');
  font-weight: 200 1000;
  font-display: swap;
}

:root {
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --cream: #fffaf2;
  --cream-2: #f6ecdc;
  --ink-0: #2b1d16;
  --muted: #6d5d52;
  --green: #1f6b4f;
  --green-d: #154c38;
  --red: #c8352e;
  --gold: #e9b949;
  --line: #e7dccb;
  --radius: 18px;
  --shadow: 0 10px 30px -12px rgba(60, 35, 20, 0.28);
  /* Theme variables (overridden per calendar theme) */
  --paper: var(--cream);
  --ink: var(--ink-0);
  --accent: var(--green);
  --accent2: var(--red);
  --soft: var(--cream-2);
  --theme-font: var(--font-display);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink-0);
  background: var(--cream);
  background-image: radial-gradient(circle at 1px 1px, rgba(120, 90, 60, 0.07) 1px, transparent 0);
  background-size: 22px 22px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1; outline: none; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; margin: 0 0 0.5em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.3rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
a { color: var(--green); }
img, svg { max-width: 100%; }
.small { font-size: 0.85rem; }
.muted { color: var(--muted); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 99; background: #fff; padding: 0.5rem 1rem; }

/* ---- Buttons --------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4em;
  font: 800 1rem/1.2 var(--font-body);
  padding: 0.7em 1.2em; border-radius: 999px; border: 2px solid var(--line);
  background: #fff; color: var(--ink-0); text-decoration: none; cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px -8px rgba(60, 35, 20, 0.4); }
.btn:active { transform: translateY(1px); }
.btn:focus-visible, button:focus-visible, a:focus-visible, input:focus-visible + span, .chip input:focus-visible + span { outline: 3px solid var(--gold); outline-offset: 2px; }
.btn-primary { background: var(--green); border-color: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-d); }
.btn-ghost { background: transparent; }
.btn-gold { background: var(--gold); border-color: var(--gold); color: #3a2a00; }
.btn-big { font-size: 1.12rem; padding: 0.9em 1.6em; }
.btn-small { font-size: 0.88rem; padding: 0.45em 0.9em; }
.btn-wide { width: 100%; }
.link-btn { background: none; border: 0; padding: 0.3em 0.2em; font: inherit; font-weight: 700; color: var(--green); cursor: pointer; text-decoration: none; }
.link-btn:hover { text-decoration: underline; }
.icon-btn { width: 2.4rem; height: 2.4rem; border-radius: 50%; border: 2px solid var(--line); background: #fff; font-size: 1.3rem; cursor: pointer; align-self: end; margin-bottom: 0.2rem; }
.pro-tag { display: inline-block; font-size: 0.7rem; font-weight: 900; letter-spacing: 0.04em; text-transform: uppercase; background: var(--gold); color: #3a2a00; border-radius: 999px; padding: 0.1em 0.6em; vertical-align: middle; }
.pro-badge { font-weight: 900; color: #8a6500; background: #fff3cf; border-radius: 999px; padding: 0.3em 0.8em; font-size: 0.85rem; }

/* ---- Header / footer ------------------------------------------------------- */
.site-head {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.8rem clamp(1rem, 4vw, 2.5rem);
  padding-top: max(0.8rem, env(safe-area-inset-top));
  position: sticky; top: 0; z-index: 10;
  background: rgba(255, 250, 242, 0.9); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 0.55rem; text-decoration: none; color: var(--ink-0); font: 800 1.25rem var(--font-display); }
.brand em { font-style: italic; font-weight: 600; color: var(--red); }
.nav { display: flex; align-items: center; gap: 1rem; font-weight: 800; }
.nav a { text-decoration: none; }
.site-foot { border-top: 1px solid var(--line); padding: 2rem clamp(1rem, 4vw, 2.5rem) 2.5rem; background: #fbf3e6; }
.footer-inner { max-width: 980px; margin: 0 auto; }
.instead-promo { display: flex; flex-wrap: wrap; gap: 0.4rem 0.8rem; align-items: baseline; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: 1rem; }

/* ---- Landing ---------------------------------------------------------------- */
.band { max-width: 1080px; margin: 0 auto; padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1rem, 4vw, 2.5rem); }
.band-soft { max-width: none; background: #fbf1e2; }
.band-soft > * { max-width: 1080px; margin-left: auto; margin-right: auto; }
.section-title { text-align: center; }
.section-lead { text-align: center; max-width: 620px; margin: 0 auto 2rem; color: var(--muted); }
.eyebrow { text-transform: uppercase; letter-spacing: 0.12em; font-weight: 900; font-size: 0.78rem; color: var(--red); margin-bottom: 0.7rem; }
.hero { max-width: 1160px; margin: 0 auto; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 2.5rem; align-items: center; padding: clamp(2rem, 6vw, 5rem) clamp(1rem, 4vw, 2.5rem) clamp(2rem, 5vw, 4rem); }
.hero h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); }
.hl { color: var(--green); font-style: italic; }
.lead { font-size: 1.2rem; color: #4d3d33; max-width: 34em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 0.8rem; margin: 1.6rem 0 0.8rem; }
.hero-art { perspective: 900px; }
.mini-cal { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; padding: 18px; background: var(--green); border-radius: 26px; box-shadow: var(--shadow); transform: rotate(2deg); }
.mini-door { aspect-ratio: 1; border-radius: 12px; background: var(--cream); display: grid; place-items: center; position: relative; font: 800 1.5rem var(--font-display); color: var(--red); box-shadow: inset 0 -4px 0 rgba(0, 0, 0, 0.08); animation: pop 0.5s backwards; animation-delay: calc(var(--i) * 60ms); }
.mini-door:nth-child(3n) { background: var(--red); color: var(--cream); }
.mini-door:nth-child(4n+2) { background: var(--gold); color: #5a3d00; }
.mini-door.is-open { background: #fff; }
.mini-door.is-open span { position: absolute; inset: 0; display: grid; place-items: center; background: var(--red); color: #fff; border-radius: 12px; transform-origin: left; transform: rotateY(-62deg); box-shadow: 4px 0 10px rgba(0, 0, 0, 0.2); }
.mini-door em { font-style: normal; font-size: 2rem; }
@keyframes pop { from { transform: scale(0.6); opacity: 0; } }
.steps { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; margin: 2rem 0 0; }
.steps li { background: #fff; border-radius: var(--radius); padding: 1.6rem; border: 1px solid var(--line); }
.step-n { display: inline-grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--red); color: #fff; font: 800 1.2rem var(--font-display); margin-bottom: 0.8rem; }
.sample-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.sample-card { background: #fff; border-radius: var(--radius); padding: 1.4rem 1.4rem 0.6rem; border: 1px solid var(--line); box-shadow: 0 4px 0 var(--line); }
.sample-card:nth-child(2n) { transform: rotate(-0.8deg); }
.sample-card:nth-child(3n) { transform: rotate(0.7deg); }
.sample-emoji { font-size: 2.2rem; }
.sample-card p { color: #5b4b40; font-size: 0.95rem; }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.6rem 2rem; margin-top: 2rem; }
.features p { color: var(--muted); }
.f-ico { font-size: 1.8rem; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 380px)); justify-content: center; gap: 1.5rem; margin-top: 2rem; }
.plan { background: #fff; border: 2px solid var(--line); border-radius: 22px; padding: 1.8rem; display: flex; flex-direction: column; }
.plan ul { padding-left: 1.2rem; flex: 1; }
.plan li { margin-bottom: 0.4rem; }
.plan-pro { border-color: var(--gold); box-shadow: 0 0 0 4px #fff3cf; }
.plan-price { font: 800 1.8rem var(--font-display); margin-bottom: 0.6rem; }
.plan-price small { font-size: 1rem; color: var(--muted); }
.faq { max-width: 760px; margin: 1.5rem auto 0; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 0.9rem 1.2rem; margin-bottom: 0.7rem; }
.faq summary { font-weight: 800; cursor: pointer; }
.faq details p { margin: 0.7rem 0 0.2rem; color: #4d3d33; }
.band-cta { text-align: center; }
.prose { max-width: 760px; }
.empty { text-align: center; }

/* ---- Builder ---------------------------------------------------------------- */
.builder { max-width: 760px; margin: 0 auto; padding: 2rem clamp(1rem, 4vw, 2rem) 4rem; }
.builder-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.progress { list-style: none; display: flex; gap: 0.5rem; padding: 0; margin: 0; }
.progress li { width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; font-weight: 900; background: #fff; border: 2px solid var(--line); color: var(--muted); }
.progress li.now { background: var(--red); border-color: var(--red); color: #fff; }
.progress li.done { background: var(--green); border-color: var(--green); color: #fff; }
.builder-card { background: #fff; border-radius: 24px; border: 1px solid var(--line); box-shadow: var(--shadow); padding: clamp(1.4rem, 4vw, 2.4rem); }
.builder-nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 2rem; padding-top: 1.4rem; border-top: 1px solid var(--line); }
.kids { display: grid; gap: 0.8rem; margin-bottom: 1rem; }
.kid-row { display: flex; gap: 0.8rem; align-items: end; }
.field { display: grid; gap: 0.25rem; font-weight: 800; font-size: 0.9rem; }
.field.grow { flex: 1; }
.field input, .field select, .field textarea, .share-box input, .code-form input, .stack textarea, .stack input {
  font: 600 1.05rem var(--font-body); padding: 0.7em 0.9em; border-radius: 12px; border: 2px solid var(--line); background: #fffdf9; color: var(--ink-0); width: 100%;
}
.field input:focus, .field select:focus, textarea:focus, .share-box input:focus, .code-form input:focus { outline: none; border-color: var(--green); }
.field-block { margin: 1.5rem 0 0.4rem; }
.field-row { display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: end; }
.field-row .seg-opt { flex: 0 0 auto; }
.label { font-weight: 900; margin-bottom: 0.5rem; }
.seg { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.seg-opt { flex: 1 1 140px; cursor: pointer; }
.seg-opt input, .chip input, .emoji-pick input { position: absolute; opacity: 0; pointer-events: none; }
.seg-opt span { display: block; height: 100%; padding: 0.7rem 0.9rem; border-radius: 14px; border: 2px solid var(--line); background: #fffdf9; font-weight: 800; transition: all 0.12s; }
.seg-opt small { display: block; font-weight: 600; color: var(--muted); font-size: 0.8rem; }
.seg-opt input:checked + span { border-color: var(--green); background: #eaf4ee; box-shadow: inset 0 0 0 1px var(--green); }
.check { display: flex; gap: 0.5rem; align-items: center; margin-top: 0.7rem; font-weight: 600; cursor: pointer; }
.check input { width: 1.2rem; height: 1.2rem; accent-color: var(--green); }
.chips { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.chip { cursor: pointer; }
.chip span { display: inline-block; padding: 0.6rem 1rem; border-radius: 999px; border: 2px solid var(--line); background: #fffdf9; font-weight: 800; transition: all 0.12s; }
.chip input:checked + span { background: var(--green); border-color: var(--green); color: #fff; }

/* ---- Calendar --------------------------------------------------------------- */
.calendar { background: var(--paper); color: var(--ink); min-height: 100%; }
.calendar[data-theme='classic'] { background: transparent; }
.cal-wrap { max-width: 1100px; margin: 0 auto; padding: 1.6rem clamp(0.8rem, 3vw, 2rem) 3rem; }
.calendar[data-dark='1'] .cal-sub, .calendar[data-dark='1'] .cal-foot { color: var(--ink); opacity: 0.75; }
.calendar[data-dark='1'] .btn:not(.btn-primary) { background: transparent; color: var(--ink); border-color: rgba(255, 255, 255, 0.3); }
.calendar[data-dark='1'] .banner { background: var(--soft); color: var(--ink); }
.calendar[data-dark='1'] .banner a { color: var(--accent2); }
.cal-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1rem; margin-bottom: 1.2rem; }
.cal-title { font-family: var(--theme-font); color: var(--ink); font-size: clamp(1.8rem, 5vw, 2.8rem); margin-bottom: 0.2rem; }
.cal-sub { margin: 0 0 0.4rem; font-weight: 700; color: var(--muted); }
.progress-bar { width: min(320px, 70vw); height: 10px; border-radius: 99px; background: var(--soft); overflow: hidden; }
.progress-bar span { display: block; height: 100%; background: var(--accent2); border-radius: 99px; transition: width 0.4s; }
.cal-actions { display: flex; gap: 0.5rem; }
.banner { background: #fff; border: 2px dashed var(--accent); border-radius: var(--radius); padding: 0.9rem 1.2rem; margin-bottom: 1.2rem; display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; align-items: center; }
.banner-done { border-style: solid; border-color: var(--gold); background: #fffbea; }
.doors {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(8px, 1.4vw, 14px);
  padding: clamp(10px, 2vw, 22px); border-radius: 28px;
  background: var(--accent);
  background-image: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.12) 2px, transparent 3px), radial-gradient(circle at 70% 60%, rgba(255, 255, 255, 0.1) 1.5px, transparent 2.5px);
  background-size: 60px 60px, 44px 44px;
  box-shadow: var(--shadow);
}
.door { position: relative; aspect-ratio: 1; border: 0; padding: 0; background: none; cursor: pointer; perspective: 600px; font: inherit; }
.doors-25 { grid-template-columns: repeat(5, 1fr); }
.door.is-special .door-n::before { content: '★'; position: absolute; top: 8%; left: 50%; transform: translateX(-50%); font-size: 0.42em; color: var(--gold); }
.door.is-special .door-panel { box-shadow: inset 0 0 0 3px var(--gold), inset 0 -5px 0 rgba(0, 0, 0, 0.1); }
.door-inside {
  position: absolute; inset: 0; border-radius: 14px; background: #fffdf8; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 6px; text-align: center; box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.18); color: var(--ink-0);
}
.door-emoji { font-size: clamp(1.4rem, 4vw, 2.4rem); line-height: 1.1; }
.door-t { font-size: clamp(0.6rem, 1.3vw, 0.8rem); font-weight: 800; line-height: 1.2; margin-top: 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.door-panel {
  position: absolute; inset: 0; border-radius: 14px; display: grid; place-items: center;
  background: var(--paper); color: var(--accent2); transform-origin: left center; transition: transform 0.7s cubic-bezier(0.3, 1.4, 0.5, 1), box-shadow 0.7s;
  box-shadow: inset 0 -5px 0 rgba(0, 0, 0, 0.1), 0 2px 0 rgba(0, 0, 0, 0.12); backface-visibility: hidden;
}
.door:nth-child(3n+1) .door-panel { background: var(--accent2); color: var(--paper); }
.door:nth-child(5n+2) .door-panel { background: var(--soft); color: var(--accent); }
.door:nth-child(7n+3) .door-panel { background: var(--gold); color: #5a3d00; }
[data-theme='midnight'] .door-panel { color: var(--ink); background: var(--soft); }
[data-theme='midnight'] .door:nth-child(3n+1) .door-panel { background: var(--accent2); color: #2a1d00; }
[data-theme='midnight'] .door:nth-child(5n+2) .door-panel { background: var(--accent); color: #fff; }
[data-theme='midnight'] .doors { background-color: #0e1628; }
.door-n { font: 800 clamp(1.4rem, 4.2vw, 2.6rem) var(--theme-font); }
.door-panel::after { content: ''; position: absolute; right: 9%; top: 50%; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: 0.5; }
.door:hover .door-panel { transform: rotateY(-14deg); }
.door.is-open .door-panel { transform: rotateY(-108deg); box-shadow: 8px 0 14px rgba(0, 0, 0, 0.25); }
.door.is-today .door-inside { box-shadow: 0 0 0 4px var(--gold), inset 0 3px 8px rgba(0, 0, 0, 0.18); }
.door.is-today:not(.is-open) .door-panel { animation: wiggle 2.4s ease-in-out infinite; box-shadow: 0 0 0 4px var(--gold), inset 0 -5px 0 rgba(0, 0, 0, 0.1); }
.door.is-done .door-inside { background: #fffbea; }
.door-star { position: absolute; top: -6px; right: -6px; width: 26px; height: 26px; border-radius: 50%; background: var(--gold); color: #5a3d00; display: grid; place-items: center; font-size: 15px; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25); z-index: 2; }
@keyframes wiggle { 0%, 80%, 100% { transform: rotateY(0); } 86% { transform: rotateY(-18deg); } 92% { transform: rotateY(-6deg); } }
.cal-foot { text-align: center; color: var(--muted); margin-top: 1rem; }
.cal-list { display: grid; gap: 0.8rem; margin: 1.5rem 0; }
.cal-item { display: flex; align-items: center; gap: 1rem; background: var(--paper); color: var(--ink); text-decoration: none; padding: 1rem 1.2rem; border-radius: var(--radius); border: 2px solid var(--line); }
.cal-item-art svg { width: 44px; height: 44px; }

/* ---- Dialogs ---------------------------------------------------------------- */
.dialog { border: 0; border-radius: 24px; padding: 1.8rem; max-width: min(520px, calc(100vw - 1.5rem)); width: 100%; max-height: calc(100dvh - 2rem); overflow: auto; color: var(--ink-0); background: #fff; box-shadow: 0 30px 80px -20px rgba(30, 15, 5, 0.5); }
.dialog::backdrop { background: rgba(35, 22, 14, 0.55); backdrop-filter: blur(3px); }
.dialog[open] { animation: rise 0.35s cubic-bezier(0.2, 1.3, 0.4, 1); }
@keyframes rise { from { transform: translateY(30px) scale(0.96); opacity: 0; } }
.dialog-x { position: absolute; top: 0.6rem; right: 0.7rem; width: 2.2rem; height: 2.2rem; border-radius: 50%; border: 0; background: rgba(0, 0, 0, 0.06); font-size: 1.4rem; cursor: pointer; z-index: 3; color: inherit; }
.dialog-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.6rem; margin-top: 1.2rem; }
.dialog-card { padding: 0; overflow: hidden auto; }
.act-card { position: relative; background: var(--paper); color: var(--ink); padding: 2rem 1.8rem 1.5rem; text-align: center; }
.act-motif { position: absolute; top: -18px; left: -18px; width: 96px; opacity: 0.9; transform: rotate(-12deg); pointer-events: none; }
.act-day { font-weight: 900; text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.75rem; color: var(--accent2); margin-bottom: 0.3rem; }
.act-emoji { font-size: 4rem; line-height: 1.2; animation: bounce 0.7s cubic-bezier(0.3, 1.8, 0.5, 1); }
@keyframes bounce { from { transform: scale(0.2) rotate(-20deg); } }
.act-title { font-family: var(--theme-font); font-size: 1.8rem; }
.act-desc { font-size: 1.08rem; text-align: left; }
.act-need { text-align: left; font-size: 0.95rem; background: rgba(0, 0, 0, 0.04); border-radius: 12px; padding: 0.6rem 0.9rem; }
.act-note { font-family: var(--font-display); font-style: italic; font-size: 1.1rem; background: #fff7d9; color: #4a3800; padding: 0.7rem 1rem; border-radius: 12px; transform: rotate(-1deg); }
.leader { background: rgba(0, 0, 0, 0.05); border-radius: 12px; padding: 0.5rem 0.8rem; font-size: 0.95rem; }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem; margin-bottom: 1.2rem; }
.pill { background: rgba(0, 0, 0, 0.06); border-radius: 999px; padding: 0.25em 0.8em; font-size: 0.85rem; font-weight: 700; }
.edit-row { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0.2rem 0.8rem; margin-top: 0.9rem; font-size: 0.9rem; }
.edit-row .link-btn { color: inherit; opacity: 0.85; }
[data-theme='midnight'] .act-need, [data-theme='midnight'] .pill, [data-theme='midnight'] .leader { background: rgba(255, 255, 255, 0.1); }
.locked { text-align: center; padding: 2.4rem 1.8rem; }
.lock-ico { font-size: 3.4rem; animation: shake 0.6s; }
@keyframes shake { 20%, 60% { transform: rotate(-12deg); } 40%, 80% { transform: rotate(12deg); } }
.alt-list { display: grid; gap: 0.5rem; }
.alt { display: flex; gap: 0.8rem; align-items: center; text-align: left; padding: 0.7rem 0.9rem; border-radius: 14px; border: 2px solid var(--line); background: #fffdf9; cursor: pointer; font: inherit; }
.alt:hover { border-color: var(--green); }
.alt-e { font-size: 1.8rem; }
.alt small { color: var(--muted); }
.stack { display: grid; gap: 0.8rem; }
.emoji-pick { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0.3rem; }
.emoji-pick legend { font-weight: 800; font-size: 0.9rem; margin-bottom: 0.3rem; }
.emoji-pick span { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 10px; border: 2px solid var(--line); font-size: 1.3rem; cursor: pointer; }
.emoji-pick input:checked + span { border-color: var(--green); background: #eaf4ee; }
.day-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0.4rem; }
.day-btn { display: grid; padding: 0.4rem 0; border-radius: 10px; border: 2px solid var(--line); background: #fffdf9; font: 800 1rem var(--font-body); cursor: pointer; }
.day-btn:hover { border-color: var(--green); }
.menu-list { display: grid; gap: 0.3rem; }
.menu-list button { text-align: left; padding: 0.8rem 1rem; border-radius: 12px; border: 0; background: #faf4ea; font: 700 1rem var(--font-body); cursor: pointer; color: inherit; }
.menu-list button:hover { background: #f2e6d3; }
.menu-list .danger { color: #a3261f; }
.share-box { display: flex; gap: 0.5rem; margin-bottom: 0.8rem; }
.paywall { text-align: left; }
.paywall h2 { padding-right: 2rem; }
.pro-list { list-style: none; padding: 0; margin: 1rem 0; display: grid; gap: 0.8rem; }
.pro-list li { display: flex; gap: 0.8rem; }
.pro-list span { color: var(--muted); font-size: 0.92rem; }
.pro-list .pro-ico { font-size: 1.5rem; color: inherit; }
.price { font-size: 1.1rem; }
.notice { background: #fff7d9; border-radius: 12px; padding: 0.7rem 1rem; }
.code-box { margin-top: 0.8rem; }
.code-box summary { cursor: pointer; font-weight: 800; color: var(--green); }
.code-form { display: flex; gap: 0.5rem; margin: 0.6rem 0; }
.theme-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.6rem; }
.swatch { position: relative; display: grid; justify-items: center; gap: 0.2rem; padding: 0.7rem 0.4rem 0.5rem; border-radius: 14px; border: 2px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; font: 800 0.8rem var(--font-body); }
.swatch.is-on { border-color: var(--accent2); box-shadow: 0 0 0 3px var(--accent2); }
.swatch-art svg { width: 40px; height: 40px; }
.swatch .pro-tag { position: absolute; top: -7px; right: -5px; font-size: 0.6rem; }

.toast { position: fixed; left: 50%; bottom: max(1.5rem, env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--ink-0); color: #fff; padding: 0.8rem 1.3rem; border-radius: 999px; font-weight: 800; z-index: 1000; box-shadow: var(--shadow); animation: rise 0.3s; transition: opacity 0.5s; max-width: calc(100vw - 2rem); text-align: center; }
.toast.out { opacity: 0; }
.celebrate { position: fixed; inset: 0; pointer-events: none; z-index: 999; overflow: hidden; }
.celebrate span { position: absolute; top: -40px; color: var(--gold); animation: fall 2.6s ease-in forwards; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); }
.celebrate span:nth-child(3n) { color: var(--red); }
.celebrate span:nth-child(3n+1) { color: #9fd3e8; }
@keyframes fall { to { transform: translate(var(--drift), 110vh) rotate(360deg); } }

/* ---- Print UI (screen) ------------------------------------------------------ */
.print-ui { max-width: 1000px; margin: 0 auto; padding: 1.5rem clamp(1rem, 4vw, 2rem) 0.5rem; }
.print-controls { background: #fff; border-radius: 24px; border: 1px solid var(--line); padding: 0.6rem 1.6rem 1.4rem; box-shadow: var(--shadow); }
.theme-grid.compact { grid-template-columns: repeat(8, 1fr); }
.print-go { margin-top: 1.4rem; display: grid; gap: 0.6rem; justify-items: start; }
.preview { max-width: 1000px; margin: 1.5rem auto 3rem; padding: 0 8px; }
.preview .sheets { display: grid; gap: 18px; justify-content: center; }
.preview .sheet { box-shadow: 0 8px 30px -10px rgba(0, 0, 0, 0.35); }
.preview.is-locked .sheet { position: relative; }
.preview.is-locked .sheet::before { content: 'PREVIEW · Pro theme'; position: absolute; inset: 0; display: grid; place-items: center; font: 900 64px var(--font-body); color: rgba(0, 0, 0, 0.12); transform: rotate(-30deg); z-index: 5; pointer-events: none; letter-spacing: 0.05em; }

/* ---- Responsive -------------------------------------------------------------- */
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .hero-art { max-width: 380px; margin: 0 auto; }
  .steps, .sample-cards, .features { grid-template-columns: 1fr 1fr; }
  .theme-grid.compact { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .steps, .sample-cards, .features, .plans { grid-template-columns: 1fr; }
  .doors, .doors-25 { grid-template-columns: repeat(4, 1fr); border-radius: 20px; grid-auto-flow: dense; }
  .door.is-big { grid-column: span 4; aspect-ratio: auto; min-height: 84px; }
  .door-panel, .door-inside { border-radius: 10px; }
  .door-t { display: none; }
  .door.is-big .door-t { display: -webkit-box; }
  .cal-actions { width: 100%; }
  .cal-actions .btn { flex: 1; }
  .kid-row { flex-wrap: wrap; }
  .field.grow { flex-basis: 100%; }
  .theme-grid { grid-template-columns: repeat(2, 1fr); }
  .theme-grid.compact { grid-template-columns: repeat(4, 1fr); }
  .day-grid { grid-template-columns: repeat(5, 1fr); }
  .dialog { padding: 1.4rem; }
  .dialog-card { padding: 0; }
  .brand span { font-size: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
.pro-badge { border: 0; cursor: pointer; font-family: var(--font-body); }
.code-card { background: #f3faf6; border: 2px dashed var(--green); border-radius: var(--radius); padding: 1rem 1.2rem; margin: 1rem auto; max-width: 460px; }
.code-card p { margin: 0.3rem 0; }
.the-code { font: 900 1.6rem var(--font-body); letter-spacing: 0.08em; color: var(--green-d); user-select: all; overflow-wrap: anywhere; }
.the-code.is-key { font-size: 1rem; letter-spacing: 0; }
.brand, .nav a, .nav .btn { white-space: nowrap; }
@media (max-width: 440px) {
  .site-head { gap: 0.5rem; padding-left: 0.8rem; padding-right: 0.8rem; }
  .brand { font-size: 1.05rem; gap: 0.4rem; }
  .brand img { width: 28px; height: 28px; }
  .nav { gap: 0.6rem; font-size: 0.9rem; }
  .nav .btn-small { padding: 0.4em 0.75em; font-size: 0.82rem; }
}
