/* BirthdayPartyPal's own look: the marketing site, sign-in, simple pages and the dashboard frame. */
body.site, body.app-page {
  --bg: #fff8f1; --bg2: #f3ecff; --ink: #2a1f4f; --card: #ffffff; --cardInk: #2a1f4f; --muted: #6d6491; --line: #ece4f7;
  --accent: #6a45e8; --accent2: #ffb3d1; /* #7b5cff was 4.36:1 under white labels; this is AA on white, cream and lilac */ --accent3: #8de3c6; --gold: #ffd166; --btnInk: #ffffff;
  --font-display: "Fredoka", "BPP Display Fallback", system-ui, sans-serif; --font-body: "Nunito", "BPP Body Fallback", system-ui, sans-serif;
  background: var(--bg); color: var(--ink);
}
.site a { color: var(--accent); }
.site .btn, .app-page .btn { color: var(--btnInk); }
.site .btn.alt, .app-page .btn.alt { color: var(--cardInk); } /* white on the pink alt fill was 1.7:1 */
.site .btn.ghost, .app-page .btn.ghost { color: var(--accent); }
.brand { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; color: var(--ink) !important; text-decoration: none; }
.logo { width: 30px; height: 30px; border-radius: 10px; background: conic-gradient(from 200deg, #7b5cff, #ff8fc0, #ffd166, #8de3c6, #7b5cff); box-shadow: inset 0 0 0 5px #fff; flex: none; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }

/* header + footer */
.sitebar { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.sitebar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 60px; }
.sitenav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.sitenav a { color: var(--ink); text-decoration: none; font-weight: 800; display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px; border-radius: 10px; font-size: .95rem; }
.sitenav a:hover, .sitenav a[aria-current] { background: var(--bg2); }
.sitenav .btn { padding: 6px 14px; min-height: 44px; }
.sitenav .hide-sm { display: none; }
@media (min-width: 720px) { .sitenav .hide-sm { display: inline-flex; } }
.sitefoot { margin-top: 60px; padding: 30px 0 40px; background: var(--bg2); font-size: .95rem; }
.sitefoot .wrap { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .sitefoot .wrap { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.sitefoot nav { display: grid; gap: 0; justify-items: start; }
.sitefoot a { color: var(--ink); font-weight: 700; display: inline-flex; align-items: center; min-height: 44px; }

/* marketing sections */
.hero-m { padding-block: 36px 20px; display: grid; gap: 26px; align-items: center; }
@media (min-width: 860px) { .hero-m { grid-template-columns: 1.1fr 1fr; padding-block: 60px 30px; } }
.hero-m h1 { font-size: clamp(2.2rem, 7vw, 3.6rem); }
.hero-m .lead { font-size: 1.15rem; color: var(--muted); max-width: 46ch; }
.kicker { display: inline-block; background: var(--bg2); color: var(--accent); font-weight: 800; padding: 4px 12px; border-radius: 999px; font-size: .88rem; margin-bottom: 10px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 18px; }
.price-note { color: var(--muted); font-weight: 700; font-size: .95rem; }
.phone-mock { position: relative; margin: 0 auto; width: min(340px, 100%); height: 560px; border-radius: 40px; border: 10px solid #241a46; box-shadow: var(--shadow); overflow: hidden; background: #241a46; }
.phone-mock .pm-screen { position: absolute; inset: 0; overflow: hidden; }
.phone-mock .pm-scroll { transform: scale(.82); transform-origin: top center; width: 122%; margin-left: -11%; pointer-events: none; animation: pm-scroll 18s ease-in-out infinite alternate; }
@keyframes pm-scroll { 0%, 12% { transform: scale(.82) translateY(0); } 100% { transform: scale(.82) translateY(-48%); } }
.section { padding-block: 34px; }
.section h2 { font-size: clamp(1.6rem, 5vw, 2.3rem); text-align: center; }
.section .sub { text-align: center; color: var(--muted); max-width: 60ch; margin: 0 auto 22px; }
.feature-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .feature-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px) { .feature-grid { grid-template-columns: repeat(3, 1fr); } }
.feature { background: var(--card); border-radius: 20px; padding: 18px; box-shadow: 0 4px 14px rgba(40, 20, 90, .07); }
.feature h3 { display: flex; align-items: center; gap: 8px; font-size: 1.15rem; }
.feature .ic { color: var(--accent); width: 1.4em; height: 1.4em; }
.feature p { margin: 0; color: var(--muted); }
.steps-m { counter-reset: s; display: grid; gap: 12px; list-style: none; padding: 0; max-width: 680px; margin: 0 auto; }
.steps-m li { counter-increment: s; background: var(--card); border-radius: 18px; padding: 14px 16px 14px 62px; position: relative; box-shadow: 0 4px 14px rgba(40, 20, 90, .07); }
.steps-m li::before { content: counter(s); position: absolute; left: 14px; top: 12px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; font-family: var(--font-display); font-weight: 700; }
.steps-m b { display: block; }
.theme-strip { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.theme-tile { border-radius: 22px; overflow: hidden; background: var(--bg); color: var(--ink); box-shadow: var(--shadow); text-decoration: none; display: flex; flex-direction: column; }
.theme-tile .tt-art { height: 130px; background: radial-gradient(120% 90% at 50% 0%, var(--bg2), var(--bg)); }
.theme-tile .tt-art svg { width: 100%; height: 100%; }
.theme-tile .tt-body { padding: 12px 14px 16px; }
.theme-tile h3 { margin: 0 0 4px; font-family: var(--font-display); }
.theme-tile p { margin: 0; font-size: .92rem; opacity: .9; }
.theme-tile .tt-squad { display: flex; gap: 2px; margin-top: 6px; }
.price-card { max-width: 460px; margin: 0 auto; text-align: center; background: var(--card); border-radius: 28px; padding: 28px 22px; box-shadow: var(--shadow); }
.price-card .amount { font-family: var(--font-display); font-size: 4rem; line-height: 1; color: var(--accent); margin: 6px 0; }
.price-card ul { text-align: left; list-style: none; padding: 0; margin: 18px 0; display: grid; gap: 8px; }
.price-card li { display: flex; gap: 8px; align-items: flex-start; font-weight: 700; }
.price-card li .ic { color: #19a974; margin-top: 2px; }
.addon-list { max-width: 680px; margin: 0 auto; display: grid; gap: 10px; }
.addon-row { display: flex; justify-content: space-between; gap: 12px; background: var(--card); border-radius: 16px; padding: 12px 16px; box-shadow: 0 2px 8px rgba(40, 20, 90, .06); }
.addon-row > b { white-space: nowrap; color: var(--accent); }
.addon-row .nm { color: var(--ink); }
.faq { max-width: 760px; margin: 0 auto; display: grid; gap: 10px; }
.faq details { background: var(--card); border-radius: 16px; padding: 4px 16px; box-shadow: 0 2px 8px rgba(40, 20, 90, .06); }
.faq summary { cursor: pointer; font-weight: 800; padding: 12px 0; min-height: 44px; }
.prose { max-width: 760px; margin: 0 auto; }
.prose h1 { font-size: clamp(1.9rem, 6vw, 2.6rem); }
.prose h2 { margin-top: 1.4em; font-size: 1.4rem; }
.draft-banner { background: #fff1c2; border: 2px dashed #e0a800; color: #5a4300; padding: 12px 16px; border-radius: 14px; font-weight: 800; margin: 16px 0; }

/* sign-in + simple pages */
.simple-card, .signin-card { max-width: 440px; margin: 40px auto; background: var(--card); border-radius: 24px; padding: 26px 22px; box-shadow: var(--shadow); }
body.simple { min-height: 100vh; padding: 0 16px; }
.simple-card .brand { margin-bottom: 14px; }
.signin-card h1 { font-size: 1.8rem; }
.code-input { letter-spacing: .4em; font-size: 1.5rem !important; text-align: center; font-family: var(--font-display); }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-weight: 800; margin: 16px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.btn.big.auto { width: auto; }
.center-row { text-align: center; margin-top: 18px; }
@media (max-width: 420px) {
  .sitebar .brand { font-size: 1.05rem; gap: 6px; }
  .sitebar .logo-mark { width: 26px; height: 26px; }
  .sitenav { flex-wrap: nowrap; gap: 2px; }
  .sitenav a { padding: 8px 6px; }
  .sitenav .btn { padding: 6px 10px; font-size: .9rem; }
}
.sitenav a { white-space: nowrap; }
.page-title { font-size: clamp(2rem, 7vw, 3rem); text-align: center; margin-top: 10px; }
.mt { margin-top: 34px; }
.section h2 .kicker { vertical-align: middle; font-size: .9rem; }

/* Sign-in, step 2: open your mail app, then the help line under the code. */
.mail-open { margin: 4px 0 16px; }
.mail-open .btn { display: inline-flex; width: 100%; justify-content: center; }
.signin-help { margin-top: 18px; padding-top: 14px; border-top: 1px dashed color-mix(in srgb, currentColor 20%, transparent); }
.signin-help .linkbtn:disabled { opacity: .5; cursor: default; text-decoration: none; }
#codeErr:not(.err) { color: inherit; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* ---- Sign in (signin.html): one clear job per screen, thumb-sized, nothing to figure out ---- */
.signin { padding-top: 8px; padding-bottom: 48px; }
.signin .signin-card { position: relative; overflow: hidden; margin: 20px auto 0; padding: 0 22px 24px; text-align: left; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(42, 31, 79, .06), 0 18px 40px -18px rgba(42, 31, 79, .28); }
.signin .signin-card h1 { margin: 18px 0 6px; font-family: var(--font-display); font-size: clamp(1.75rem, 7vw, 2.1rem); line-height: 1.1; letter-spacing: -.01em; }
.signin-lead { margin: 0 0 18px; color: var(--muted); font-size: 1.02rem; line-height: 1.45; overflow-wrap: anywhere; }
.signin-lead b { color: var(--cardInk); }
.signin .f { margin-bottom: 6px; }
.signin-input, .signin .code-input { min-height: 58px !important; font-size: 1.1rem !important; padding: 12px 16px !important; border-radius: 16px !important; }
.signin-go { margin-top: 12px; }
.signin .chk-sm { margin-top: 10px; font-weight: 600; font-size: .9rem; color: var(--muted); }
.signin .chk-sm .box { width: 24px; height: 24px; border-radius: 8px; }
.signin-perks { list-style: none; margin: 18px 0 0; padding: 16px 0 0; border-top: 1px solid var(--line); display: grid; gap: 8px; font-size: .93rem; font-weight: 700; color: var(--cardInk); }
.signin-perks li { display: flex; align-items: center; gap: 10px; }
.signin-perks li span { display: grid; place-items: center; width: 22px; height: 22px; flex: none; border-radius: 50%; background: color-mix(in srgb, var(--accent3) 55%, #fff); color: var(--cardInk); font-size: .75rem; }

/* The header art: three balloons drifting up over a soft lilac sky (still under reduced motion). */
.signin-hero, .signin-mail { position: relative; height: 112px; margin: 0 -22px; background: radial-gradient(120% 90% at 50% 0%, #efe6ff 0%, #f8f2ff 55%, var(--card) 100%); }
.sh-balloon { position: absolute; bottom: 14px; width: 46px; height: 56px; border-radius: 50% 50% 48% 48% / 56% 56% 44% 44%; box-shadow: inset -7px -9px 0 rgba(0, 0, 0, .08), inset 7px 7px 0 rgba(255, 255, 255, .35); }
.sh-balloon::after { content: ""; position: absolute; left: 50%; top: 100%; width: 1.5px; height: 26px; background: rgba(42, 31, 79, .25); transform: translateX(-50%); }
.sh-b1 { left: calc(50% - 74px); background: #ff8fb8; transform: rotate(-10deg); }
.sh-b2 { left: calc(50% - 23px); bottom: 30px; width: 52px; height: 62px; background: var(--accent); }
.sh-b3 { left: calc(50% + 34px); background: var(--gold); transform: rotate(9deg); }
.sh-confetti { position: absolute; inset: 0; background:
  radial-gradient(circle, #8de3c6 0 3px, transparent 4px) 18% 30% / 100% 100% no-repeat,
  radial-gradient(circle, #ff8fb8 0 3px, transparent 4px) 82% 26% / 100% 100% no-repeat,
  radial-gradient(circle, #ffd166 0 2.5px, transparent 3.5px) 70% 64% / 100% 100% no-repeat,
  radial-gradient(circle, #6a45e8 0 2.5px, transparent 3.5px) 28% 70% / 100% 100% no-repeat; }
@media (prefers-reduced-motion: no-preference) {
  .sh-b1 { animation: sh-float 4.2s ease-in-out infinite; }
  .sh-b2 { animation: sh-float 3.6s ease-in-out -1.2s infinite; }
  .sh-b3 { animation: sh-float 4.8s ease-in-out -2.4s infinite; }
  .signin-card:not([hidden]) { animation: signin-in .45s cubic-bezier(.2, .8, .2, 1) both; }
  @keyframes sh-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -7px; } }
  @keyframes signin-in { from { opacity: 0; transform: translateY(10px) scale(.985); } }
}
/* Step 2's art: a little envelope with a code peeking out. */
.sm-env { position: absolute; left: 50%; bottom: 18px; width: 92px; height: 62px; translate: -50% 0; border-radius: 10px; background: #fff; border: 2px solid #d9cdf7; box-shadow: 0 10px 22px -12px rgba(106, 69, 232, .55); }
.sm-env::before { content: ""; position: absolute; inset: -2px -2px auto; height: 38px; background: linear-gradient(to bottom right, transparent 49%, #d9cdf7 50%, #d9cdf7 53%, transparent 54%) left / 50% 100% no-repeat, linear-gradient(to bottom left, transparent 49%, #d9cdf7 50%, #d9cdf7 53%, transparent 54%) right / 50% 100% no-repeat; }
.sm-env::after { content: "123 456"; position: absolute; left: 50%; top: -22px; translate: -50% 0; padding: 4px 9px; border-radius: 8px; background: var(--accent); color: #fff; font: 700 .8rem/1 var(--font-display); letter-spacing: .12em; white-space: nowrap; }
@media (prefers-reduced-motion: no-preference) { .sm-env::after { animation: sm-peek 2.6s ease-in-out infinite; } @keyframes sm-peek { 0%, 100% { top: -22px; } 50% { top: -28px; } } }

.signin .code-input { text-align: center; letter-spacing: .5em; text-indent: .5em; font: 700 1.6rem/1 var(--font-display) !important; }
.signin .code-input::placeholder { color: #cfc6e6; letter-spacing: .5em; }
.signin .mail-open { margin: 0 0 16px; }
.signin .mail-open .btn { width: 100%; min-height: 52px; }
.signin .signin-help { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.signin-links { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 14px; margin: 10px 0 0; font-size: .95rem; }
.signin-links .linkbtn { min-height: 44px; color: var(--accent); }
.signin-links #resendWait { color: var(--muted); font-size: .85rem; margin-left: -10px; margin-right: auto; }
.signin-links #resendWait:empty { display: none; }
@media (max-width: 420px) { .signin { padding-left: 12px; padding-right: 12px; } .signin .signin-card { margin-top: 12px; padding: 0 18px 20px; border-radius: 22px; } .signin-hero, .signin-mail { margin: 0 -18px; } }
.signin #codeHelp { margin: 8px 0 14px; font-size: .88rem; }

/* One logo everywhere: the home page balloon (public/_partials/mk-header.html). */
.logo-mark { flex: none; display: block; overflow: visible; }

/* Smallest phones (320–359px): logo + "Sign in" + "Start a party" fit on one line inside the screen. */
@media (max-width: 359px) {
  .sitebar .wrap { gap: 4px; padding-left: 12px; padding-right: 12px; }
  .sitebar .brand { font-size: .92rem; gap: 5px; min-width: 0; }
  .sitebar .logo-mark { width: 24px; height: 24px; }
  .sitenav a { padding: 0 7px; font-size: .88rem; }
  .sitenav .btn { padding: 6px 10px; font-size: .85rem; }
}
