/* Festie product pages (preview + dashboard). Built on the landing tokens in styles.css. Mobile first. */

.bar-top { border-bottom: 1px solid var(--line); background: var(--bg); }
.bar-row { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.bar-top .logo { font-size: 28px; }
.bar-top .nav-btn { display: inline-flex; align-items: center; text-decoration: none; font-weight: 700; font-size: 15px; }
.link-btn {
  min-height: 44px; padding: 0 6px; border: 0; background: none; cursor: pointer;
  font: 700 15px var(--f-ui); color: var(--ink); text-decoration: underline; text-underline-offset: 3px;
}
.link-btn.danger { color: #B3261E; }
[data-look="halloween"] .link-btn.danger, [data-look="christmas"] .link-btn.danger { color: #FFB4A8; }
.cta[disabled] { opacity: .7; cursor: progress; }
.cta.wide { width: 100%; }
em { font-family: var(--f-accent); font-weight: 400; color: var(--accent); }

/* ---------- Preview ---------- */
.pv-main { padding-top: 20px; padding-bottom: 120px; }
.pv-h { margin: 0; font-family: var(--f-head); font-weight: 700; font-size: clamp(32px, 8vw, 56px); letter-spacing: -.04em; line-height: 1.02; }
.pv-h em { font-size: 1.14em; letter-spacing: -.01em; }
.pv-form { margin-top: 18px; }
.pv-row { display: grid; gap: 10px; }
.pv-row .cta { margin-top: 0; min-height: 52px; font-size: 18px; padding: 0 26px; }
.pv-chips { justify-content: flex-start; margin: 16px 0 0; padding: 0; }
.pv-msg { margin: 12px 0 0; min-height: 1.5em; font-weight: 700; }
.pv-stage {
  margin-top: 8px; border-radius: 18px; overflow: hidden; background: var(--shop);
  border: 1.5px solid var(--cardLine); box-shadow: 0 24px 50px rgba(20,14,10,.16);
}
.pv-chrome { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 14px; background: var(--chrome); border-bottom: 1px solid var(--cardLine); }
.pv-dots { display: flex; gap: 6px; }
.pv-dots i { width: 10px; height: 10px; border-radius: 50%; background: #E6A397; }
.pv-dots i:nth-child(2) { background: #EBCB8B; } .pv-dots i:nth-child(3) { background: #A9D7BF; }
.pv-url {
  flex: 1; min-width: 0; text-align: center; font: 600 14px var(--f-ui); color: var(--shopInk);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 42px;
}
.pv-frame { position: relative; height: min(72vh, 860px); min-height: 460px; background: #fff; }
.pv-frame iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
.pv-loading {
  position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px;
  background: var(--shop); color: var(--shopInk); font-weight: 700;
}
.pv-loading[hidden], .gate-form[hidden], [hidden] { display: none !important; }
.pv-loading img { width: 120px; height: auto; }
.pv-loading p { margin: 0; }
@media (prefers-reduced-motion: no-preference) {
  .pv-loading img { animation: pv-bob 1.6s ease-in-out infinite; }
}
@keyframes pv-bob { 50% { transform: translateY(-8px); } }

.pv-dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
  background: var(--bg); border-top: 1px solid var(--line);
  padding: 10px 0 max(10px, env(safe-area-inset-bottom));
  box-shadow: 0 -10px 30px rgba(20,14,10,.12);
}
.pv-dock-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pv-dock p { margin: 0; font-size: 14px; color: var(--mute); line-height: 1.3; }
.pv-dock strong { color: var(--ink); display: block; }
.pv-dock .cta { margin-top: 0; min-height: 48px; padding: 0 20px; font-size: 16px; white-space: nowrap; flex: none; }

/* ---------- Gate ---------- */
.gate { max-width: 480px; padding-top: 32px; padding-bottom: 64px; text-align: center; }
.gate-mascot { width: 140px; height: auto; margin: 0 auto; }
.gate-h { margin: 8px 0 0; font-family: var(--f-head); font-weight: 700; font-size: clamp(34px, 9vw, 52px); letter-spacing: -.04em; line-height: 1.02; }
.gate-h em { font-size: 1.14em; letter-spacing: -.01em; }
.gate-sub { margin: 10px 0 0; color: var(--mute); font-weight: 600; }
.gate-form { margin-top: 24px; }
.consent { margin: 6px 0 0; }
.consent a { font-weight: 700; }
.sent { margin: 0 0 6px; }
.dev-code { margin: 4px 0 0; padding: 10px 14px; border-radius: 12px; background: var(--pill); font-weight: 700; }
#g-code { font-size: 24px; letter-spacing: .3em; text-align: center; }

/* ---------- Dashboard ---------- */
.who { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--mute); min-width: 0; }
.who-email { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 40vw; }
.dash-main { padding-top: 28px; padding-bottom: 64px; max-width: 860px; }
.dash-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.dash-head h1 { margin: 0; font-family: var(--f-head); font-weight: 700; font-size: clamp(34px, 8vw, 52px); letter-spacing: -.04em; line-height: 1; }
.dash-head h1 em { font-size: 1.14em; }
.plan-pill { padding: 8px 14px; border-radius: 999px; background: var(--banner); color: var(--bannerInk); font-weight: 700; font-size: 14px; }
.add-form { margin-top: 18px; }

.site { margin-top: 22px; padding: 20px 16px; border-radius: 24px; background: var(--shop); color: var(--shopInk); border: 1.5px solid var(--cardLine); }
.site-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.site-domain { margin: 0; font-family: var(--f-head); font-size: 26px; letter-spacing: -.03em; overflow-wrap: anywhere; }
.step { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--cardLine); }
.step h3 { display: flex; align-items: center; gap: 10px; font-size: 20px; }
.step h3 .num { margin: 0; width: 32px; height: 32px; font-size: 15px; flex: none; }
.hint { margin: 6px 0 0; color: color-mix(in srgb, var(--shopInk) 72%, transparent); font-size: 15px; }
.snippet { margin-top: 12px; padding: 14px; border-radius: 14px; background: var(--ink0); color: #E8F5EE; overflow-x: auto; }
.snippet code { font: 500 13.5px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; word-break: break-all; }
.copy { width: 100%; margin-top: 12px; }
.sched { margin-top: 18px; display: block; }
.tz-label { display: grid; gap: 6px; margin-top: 12px; font-size: 15px; }
.tz, .hol input[type="date"] {
  width: 100%; min-height: 48px; padding: 0 12px; border-radius: 14px; border: 1.5px solid var(--cardLine);
  background: var(--shop); color: var(--shopInk); font: 600 16px var(--f-ui);
}
.hols { display: grid; gap: 10px; margin-top: 14px; }
.hol { margin: 0; padding: 4px 14px 14px; border-radius: 18px; border: 1.5px solid var(--cardLine); background: var(--tile); min-width: 0; }
.hol.off { background: transparent; }
.hol.off .hol-body { display: none; }
.hol-top { padding: 0; width: 100%; }
.toggle { display: flex; align-items: center; gap: 12px; min-height: 48px; font-family: var(--f-head); font-size: 19px; letter-spacing: -.02em; cursor: pointer; }
.hol input[type="checkbox"] { width: 22px; height: 22px; min-height: 0; margin: 0; padding: 0; accent-color: var(--mint-deep); flex: none; }
.hol-body { display: grid; gap: 10px; }
.dates { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dates label, .offer-label { display: grid; gap: 4px; font-size: 14px; }
.offer-label input { min-height: 48px; font-size: 16px; }
.hol label + label, .hol input + label { margin-top: 0; }
.hol-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.check { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-size: 15px; cursor: pointer; }
.preview-link { min-height: 44px; display: inline-flex; align-items: center; font-weight: 700; color: var(--shopInk); }
.save { width: 100%; margin-top: 16px; }
.season { display: block; }
.write, .approve-all { width: 100%; margin-top: 14px; }
.items { display: grid; gap: 10px; margin-top: 14px; }
.item { margin: 0; padding: 4px 14px 14px; border-radius: 18px; border: 1.5px solid var(--cardLine); background: var(--tile); min-width: 0; display: grid; gap: 8px; }
.item legend { padding: 0; }
.item input[type="checkbox"] { width: 22px; height: 22px; min-height: 0; margin: 0; padding: 0; accent-color: var(--mint-deep); flex: none; }
.item input[type="text"], .item textarea { min-height: 48px; font-size: 16px; }
.item textarea { width: 100%; padding: 12px 18px; border-radius: 16px; border: 1.5px solid var(--cardLine); background: var(--shop); color: var(--shopInk); font: 600 16px/1.45 var(--f-ui); resize: vertical; }
.item.off input[type="text"], .item.off textarea { opacity: .55; }
.season-btns { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; }

@media (min-width: 640px) {
  .pv-row { grid-template-columns: 1fr auto; }
  .pv-main { padding-top: 36px; }
  .site { padding: 26px 28px; }
  .copy, .save, .write, .approve-all { width: auto; }
  .hol-body { grid-template-columns: 1.1fr 1fr; align-items: end; }
  .hol-foot { grid-column: 1 / -1; }
}
@media (min-width: 1000px) {
  .pv-main { max-width: 1240px; }
}
