/* The product: landing page, sign-in, dashboard. Warm and quiet, so the love pages themselves stay the show. */
:root {
  --ink: #2a1621;
  --ink-2: #5a4350;
  --ink-3: #7a6370;
  --bg: #fbf7f4;
  --surface: #ffffff;
  --surface-2: #f6efeb;
  --line: #ecdfd8;
  --line-2: #dccbc2;
  --brand: #b0456a;
  --brand-ink: #8e3354;
  --brand-soft: #fbe8ee;
  --gold: #a8742f;
  --ok: #1f7a4d; --ok-soft: #e3f3e9;
  --warn: #8f5300; --warn-soft: #fcefd8;
  --danger: #b42318; --danger-soft: #fde8e6;
  --night: #170b14; --night-2: #2a1220; --night-text: #fbeef0; --night-muted: rgba(251, 238, 240, .7);
  --radius-sm: 10px; --radius: 14px; --radius-lg: 22px;
  --shadow-1: 0 1px 2px rgba(42, 22, 33, .06), 0 1px 1px rgba(42, 22, 33, .04);
  --shadow-2: 0 12px 34px rgba(42, 22, 33, .09);
  --focus: 0 0 0 3px rgba(176, 69, 106, .3);
  --font-ui: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font-ui); font-size: 15px; line-height: 1.55; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
[hidden] { display: none !important; }
img, svg { max-width: 100%; }
a { color: var(--brand); text-underline-offset: 2px; }
a:hover { color: var(--brand-ink); }
h1, h2, h3 { margin: 0; line-height: 1.15; }
p { margin: 0; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.container { width: min(1180px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }
.muted { color: var(--ink-3); }
.small { font-size: .85rem; }
.display { font-family: var(--font-display); font-weight: 500; letter-spacing: -.01em; }
.eyebrow { font-size: .72rem; letter-spacing: .22em; text-transform: uppercase; color: var(--gold); font-weight: 500; }
.stack > * + * { margin-top: var(--gap, 14px); }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.spacer { flex: 1; }

/* ---------- brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-family: var(--font-display); font-size: 1.35rem; font-weight: 500; }
.brand-mark { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; color: #fff; background: linear-gradient(140deg, #f0cfa8, #e58aa3 45%, var(--brand)); box-shadow: 0 4px 12px rgba(176, 69, 106, .3); }
.brand-mark svg { width: 19px; height: 19px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px; border-radius: 999px;
  border: 1px solid transparent; font: inherit; font-weight: 500; font-size: .95rem; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background .2s, border-color .2s, color .2s, transform .2s var(--ease), box-shadow .2s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { color: #fff; background: var(--brand); box-shadow: 0 6px 16px rgba(176, 69, 106, .25); }
.btn-primary:hover { color: #fff; background: var(--brand-ink); }
.btn-secondary { color: var(--ink); background: var(--surface); border-color: var(--line-2); }
.btn-secondary:hover { color: var(--ink); border-color: var(--ink-3); }
.btn-ghost { color: var(--ink-2); background: transparent; }
.btn-ghost:hover { color: var(--ink); background: var(--surface-2); }
.btn-danger { color: #fff; background: var(--danger); }
.btn-danger:hover { color: #fff; background: #8f1c13; }
.btn-light { color: var(--night); background: #fff; }
.btn-light:hover { color: var(--night); background: #fff3f6; }
.btn-outline-light { color: #fff; border-color: rgba(255, 255, 255, .4); background: transparent; }
.btn-outline-light:hover { color: #fff; border-color: #fff; }
.btn-sm { min-height: 34px; padding: 0 13px; font-size: .85rem; }
.btn-lg { min-height: 50px; padding: 0 26px; font-size: 1rem; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; pointer-events: none; }
.icon-btn { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); cursor: pointer; }
.icon-btn:hover { color: var(--ink); border-color: var(--ink-3); }
.icon-btn.danger:hover { color: var(--danger); border-color: var(--danger); }
.icon-btn svg { width: 16px; height: 16px; }

/* ---------- forms ---------- */
.field { display: grid; gap: 6px; }
.field > label, .label { font-size: .88rem; font-weight: 500; color: var(--ink); }
.hint { font-size: .82rem; color: var(--ink-3); }
.input, .textarea, .select {
  width: 100%; min-height: 44px; padding: 10px 13px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface);
  font: inherit; color: var(--ink); transition: border-color .2s, box-shadow .2s;
}
.textarea { min-height: 220px; line-height: 1.6; resize: vertical; }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--brand); box-shadow: var(--focus); }
.input[aria-invalid="true"], .textarea[aria-invalid="true"] { border-color: var(--danger); }
.error { font-size: .84rem; color: var(--danger); }
.input-group { display: flex; align-items: stretch; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface); overflow: hidden; }
.input-group:focus-within { border-color: var(--brand); box-shadow: var(--focus); }
.input-group .input { border: 0; border-radius: 0; box-shadow: none; min-width: 0; }
.input-group .addon { display: flex; align-items: center; padding: 0 12px; color: var(--ink-3); background: var(--surface-2); font-size: .92rem; white-space: nowrap; }
.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.check input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--brand); }

/* ---------- surfaces ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-1); }
.card-pad { padding: 22px; }
.section-card { scroll-margin-top: 84px; }
.section-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 6px 12px; padding: 20px 22px 0; }
.section-head > div { flex: 1 1 280px; min-width: 0; }
.section-head > .small { flex: none; white-space: nowrap; }
.section-head h2 { font-size: 1.12rem; font-weight: 600; }
.section-head p { margin-top: 3px; color: var(--ink-3); font-size: .9rem; }
.section-body { padding: 18px 22px 22px; }
.section-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--line); background: #fdfaf8; border-radius: 0 0 var(--radius-lg) var(--radius-lg); }

.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 500; white-space: nowrap; }
.pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill-draft { color: var(--ink-2); background: var(--surface-2); }
.pill-active { color: var(--ok); background: var(--ok-soft); }
.pill-expired { color: var(--warn); background: var(--warn-soft); }
.pill-plan { color: var(--brand-ink); background: var(--brand-soft); }
.pill-plan::before { display: none; }

.notice { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius); background: var(--surface-2); color: var(--ink-2); font-size: .9rem; }
.notice-brand { background: var(--brand-soft); color: var(--brand-ink); }
.notice-warn { background: var(--warn-soft); color: var(--warn); }
.toast {
  position: fixed; z-index: 50; left: 50%; bottom: 22px; transform: translateX(-50%); max-width: min(560px, calc(100% - 32px));
  padding: 12px 18px; border-radius: 14px; background: var(--night); color: var(--night-text); box-shadow: 0 16px 40px rgba(0, 0, 0, .25);
  font-size: .92rem; animation: toastIn .5s var(--ease) both;
}
.toast.hide { opacity: 0; transform: translate(-50%, 10px); transition: opacity .4s, transform .4s; }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 12px); } }

/* ---------- top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 30; background: rgba(251, 247, 244, .86); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
.topbar .container { display: flex; align-items: center; gap: 14px; min-height: 64px; }
.topbar nav { display: flex; align-items: center; gap: 4px; }
.topbar nav a:not(.btn) { padding: 8px 12px; border-radius: 999px; color: var(--ink-2); text-decoration: none; font-size: .92rem; }
.topbar nav a:not(.btn):hover { color: var(--ink); background: var(--surface-2); }
.who { font-size: .85rem; color: var(--ink-3); max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 720px) {
  .topbar .hide-sm { display: none; }
  .who { display: none; }
}

/* ---------- auth ---------- */
.auth { min-height: 100dvh; display: grid; grid-template-columns: 1fr; }
.auth-art { display: none; }
.auth-main { display: grid; place-items: center; padding: 40px 16px; }
.auth-card { width: min(420px, 100%); }
.auth-card h1 { font-size: 2.2rem; margin: 18px 0 6px; }
.auth-card form { margin-top: 24px; }
@media (min-width: 960px) {
  .auth { grid-template-columns: 1.05fr 1fr; }
  .auth-art {
    display: flex; flex-direction: column; justify-content: flex-start; padding: 40px 44px; color: var(--night-text);
    background: radial-gradient(60% 50% at 25% 20%, rgba(242, 167, 184, .38), transparent 70%), radial-gradient(50% 50% at 80% 85%, rgba(240, 207, 168, .28), transparent 70%), var(--night);
  }
  .auth-art { position: relative; overflow: hidden; gap: 28px; }
  .auth-art > * { position: relative; z-index: 1; }
  .auth-art .muted { color: var(--night-muted); }
}

/* the left panel: a sample page that changes with the occasion */
.art-glows, .art-hearts { position: absolute; inset: 0; pointer-events: none; z-index: 0 !important; overflow: hidden; }
.art-glow { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; }
.art-glow.on { opacity: 1; }
.art-glow[data-for="anniversary"] { background: radial-gradient(55% 45% at 70% 30%, rgba(240, 207, 168, .30), transparent 70%), radial-gradient(45% 45% at 20% 85%, rgba(242, 167, 184, .22), transparent 70%); }
.art-glow[data-for="wedding"] { background: radial-gradient(55% 45% at 50% 25%, rgba(255, 244, 226, .26), transparent 70%), radial-gradient(45% 45% at 80% 85%, rgba(240, 207, 168, .22), transparent 70%); }
.art-glow[data-for="partner"] { background: radial-gradient(55% 45% at 30% 30%, rgba(242, 130, 170, .36), transparent 70%), radial-gradient(45% 45% at 85% 80%, rgba(255, 190, 150, .2), transparent 70%); }
.art-glow[data-for="birthday"] { background: radial-gradient(55% 45% at 75% 25%, rgba(255, 190, 120, .32), transparent 70%), radial-gradient(45% 45% at 15% 80%, rgba(180, 160, 255, .22), transparent 70%); }
.art-hearts i { position: absolute; bottom: -40px; left: var(--x); width: var(--s); height: var(--s); opacity: 0; background: #f2a7b8; animation: artRise var(--d) linear var(--w) infinite;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-8-4.900-8-11.100C4 6.700 6.300 5 8.600 5c1.500 0 2.900.8 3.400 2 .5-1.200 1.900-2 3.400-2C17.700 5 20 6.700 20 9.900 20 16.100 12 21 12 21z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-8-4.900-8-11.100C4 6.700 6.300 5 8.600 5c1.500 0 2.900.8 3.400 2 .5-1.200 1.900-2 3.400-2C17.700 5 20 6.700 20 9.900 20 16.100 12 21 12 21z'/%3E%3C/svg%3E") center / contain no-repeat; }
.art-hearts i:nth-child(3n) { background: #f0cfa8; }
.art-hearts i:nth-child(4n) { background: #fff; }
@keyframes artRise { 0% { transform: translateY(0) translateX(0) rotate(-8deg); opacity: 0; } 12% { opacity: .5; } 50% { transform: translateY(-48vh) translateX(18px) rotate(8deg); } 100% { transform: translateY(-105vh) translateX(-10px) rotate(-6deg); opacity: 0; } }
.art-main { display: grid; gap: clamp(22px, 3.6vh, 38px); justify-items: start; margin: auto 0; padding: 20px 0; width: 100%; }
.art-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 14px; width: 100%; }
.art-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.art-tab { font: inherit; font-size: .84rem; color: var(--night-muted); background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .16); border-radius: 999px; padding: 6px 14px; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.art-tab:hover { color: var(--night-text); border-color: rgba(255, 255, 255, .4); }
.art-tab[aria-selected="true"] { color: #2a1220; background: #f2c9d2; border-color: #f2c9d2; }
.art-tab:focus-visible { outline: 2px solid #f2c9d2; outline-offset: 2px; box-shadow: none; }
.art-card {
  --rx: 0deg; --ry: 0deg; flex: 1 1 320px; max-width: 540px; padding: clamp(26px, 3.4vh, 38px) clamp(26px, 2.4vw, 36px) clamp(22px, 3vh, 32px); border-radius: 22px; color: var(--night-text);
  background: linear-gradient(155deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .06)); border: 1px solid rgba(255, 255, 255, .22);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .35); backdrop-filter: blur(10px);
  transform: perspective(900px) rotateX(var(--ry)) rotateY(var(--rx)); transition: transform .25s var(--ease);
}
.art-card.moving { transition: transform .05s linear; }
.art-sample .eyebrow { color: #f0cfa8; }
.art-sample h2 { font-size: clamp(2rem, 3.2vh, 2.5rem); margin: 6px 0 12px; }
.art-sample.on { animation: artIn .6s var(--ease) both; }
@keyframes artIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.art-letter { font-family: var(--font-display); font-style: italic; font-size: clamp(1.22rem, 2.1vh, 1.45rem); line-height: 1.5; min-height: 7.4em; }
.art-letter.typing::after { content: ''; display: inline-block; width: 2px; height: 1.05em; margin-left: 2px; vertical-align: -.15em; background: #f2c9d2; animation: artBlink .8s steps(1) infinite; }
@keyframes artBlink { 50% { opacity: 0; } }
.art-photos { display: flex; gap: 10px; margin: clamp(14px, 2.2vh, 22px) 0; }
.art-photos img { flex: 1; min-width: 0; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; box-shadow: 0 6px 16px rgba(0, 0, 0, .25); transition: transform .3s var(--ease); }
.art-card:hover .art-photos img:nth-child(1) { transform: rotate(-3deg) translateY(-3px); }
.art-card:hover .art-photos img:nth-child(3) { transform: rotate(3deg) translateY(-3px); }
.art-lock { display: flex; align-items: center; gap: 6px; color: var(--night-muted); }
/* Lettie, the mascot: she talks while the letter types, blinks, and waves and hugs a heart when clicked */
.art-lettie { position: relative; margin-left: auto; flex: 0 0 clamp(150px, 20vh, 190px); width: clamp(150px, 20vh, 190px); margin-bottom: -6px; }
.lettie-btn { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; animation: lettieBob 3.4s ease-in-out infinite; filter: drop-shadow(0 12px 18px rgba(0, 0, 0, .35)); }
.lettie-btn:focus-visible { outline: 2px solid #f2c9d2; outline-offset: 4px; border-radius: 24px; box-shadow: none; }
.lettie-svg { display: block; width: 100%; height: auto; overflow: visible; }
@keyframes lettieBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
#l-eyes { transform-origin: 200px 262px; animation: lettieBlink 5s infinite; }
@keyframes lettieBlink { 0%, 94%, 100% { transform: scaleY(1); } 97% { transform: scaleY(.08); } }
.art-lettie.talking #l-mouth-smile { animation: lettieMouthA .3s steps(1) infinite; }
.art-lettie.talking #l-mouth-open { animation: lettieMouthB .3s steps(1) infinite; }
@keyframes lettieMouthA { 0% { opacity: 1; } 50% { opacity: 0; } }
@keyframes lettieMouthB { 0% { opacity: 0; } 50% { opacity: 1; } }
.art-lettie.love #l-hug, .art-lettie.love #l-eyes-happy { opacity: 1; }
.art-lettie.love #l-eyes { opacity: 0; }
.art-lettie.love .lettie-btn { animation: lettieHop .6s var(--ease); }
@keyframes lettieHop { 40% { transform: translateY(-18px) scale(1.04); } }
.art-bubble { position: absolute; z-index: 3; left: 0; bottom: calc(100% - 4px); width: max-content; max-width: min(190px, calc(100vw - 40px)); margin: 0; padding: 9px 13px; border-radius: 14px 14px 14px 4px; font-size: .84rem; line-height: 1.35; color: #3a1f2b; background: #fffaf3; box-shadow: 0 10px 24px rgba(0, 0, 0, .3); animation: artIn .4s var(--ease) both; }
.art-copy blockquote { margin: 0 0 8px; font-family: var(--font-display); font-style: italic; font-size: clamp(1.7rem, 3vh, 2.2rem); line-height: 1.25; max-width: 32ch; }
.art-burst { position: absolute; z-index: 2; width: 18px; height: 18px; margin: -9px 0 0 -9px; pointer-events: none; color: #f2a7b8; animation: artBurst 1.1s ease-out forwards; }
@keyframes artBurst { to { transform: translate(var(--dx), var(--dy)) scale(.4) rotate(var(--r)); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .art-hearts { display: none; }
  .art-card, .art-sample.on, .art-glow, .art-bubble, .lettie-btn, #l-eyes { animation: none !important; transition: none; }
}

/* ---------- landing ---------- */
.hero { position: relative; overflow: hidden; padding-top: 70px; color: var(--night-text); background: var(--night); }
.hero::before { content: ''; position: absolute; inset: -20%; background: radial-gradient(40% 35% at 18% 20%, rgba(242, 167, 184, .35), transparent 70%), radial-gradient(40% 40% at 85% 80%, rgba(240, 207, 168, .22), transparent 70%); pointer-events: none; }
.hero > .container { position: relative; display: grid; gap: 40px; padding: 48px 0 72px; align-items: center; }
.hero h1 { font-family: var(--font-display); font-weight: 500; font-size: clamp(2.6rem, 6vw, 4.4rem); line-height: 1.02; letter-spacing: -.015em; }
.hero h1 em { color: #f2a7b8; }
.hero p.lead { margin-top: 18px; max-width: 46ch; font-size: 1.08rem; color: var(--night-muted); }
.hero > .container .row { margin-top: 28px; }
.hero-nav { position: sticky; top: 0; z-index: 30; margin-bottom: -70px; } /* transparent: the hero shows through; it overlaps the hero's top 70px */
.hero-nav .container { display: flex; align-items: center; gap: 14px; min-height: 70px; }
.hero-nav a:not(.btn) { color: var(--night-muted); text-decoration: none; padding: 8px 12px; border-radius: 999px; font-size: .92rem; }
.hero-nav a:not(.btn):hover { color: #fff; background: rgba(255, 255, 255, .08); }
.hero-nav .brand { color: #fff; }
/* transparent over the hero; once a light section is under it the header takes the hero's own dark gradient, text unchanged */
.hero-nav.on-light { background: linear-gradient(135deg, var(--night), var(--night-2)); }
@media (max-width: 720px) { .hero-nav .hide-sm { display: none; } }
@media (min-width: 960px) { .hero > .container { grid-template-columns: 1.1fr .9fr; padding: 40px 0 88px; } }

.phone {
  position: relative; width: min(320px, 82vw); aspect-ratio: 9 / 18.5; margin-inline: auto; border-radius: 44px; padding: 12px;
  background: #0e070c; box-shadow: 0 40px 90px rgba(0, 0, 0, .55), inset 0 0 0 1px rgba(255, 255, 255, .08);
}
.phone-screen { position: relative; height: 100%; border-radius: 34px; overflow: hidden; display: grid; place-items: center; padding: 20px;
  background: radial-gradient(70% 50% at 30% 25%, #e58aa3, transparent 70%), radial-gradient(60% 50% at 75% 70%, #f0cfa8, transparent 70%), linear-gradient(160deg, #5c2440, #1e0c19); }
.phone-screen::before { content: ''; position: absolute; inset: 0; backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); background: rgba(30, 10, 24, .25); }
.mock-card { position: relative; width: 100%; padding: 26px 18px 20px; text-align: center; border-radius: 26px; background: linear-gradient(160deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, .07)); border: 1px solid rgba(255, 255, 255, .26); color: #fff; }
.mock-card .q { font-family: var(--font-display); font-style: italic; font-size: 1.75rem; line-height: 1.1; margin: 8px 0 18px; }
.mock-input { display: flex; align-items: center; justify-content: space-between; height: 46px; padding: 0 6px 0 18px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .1); color: rgba(255, 255, 255, .6); font-size: .85rem; letter-spacing: .2em; }
.mock-input span:last-child { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; color: #2a1220; background: linear-gradient(135deg, #f0cfa8, #f2a7b8); letter-spacing: 0; }
.mock-lock { display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; color: #f2a7b8; border: 1px solid rgba(242, 167, 184, .35); background: rgba(242, 167, 184, .14); }

.band { padding: 80px 0; }
.band-alt { background: var(--surface-2); }
.band h2 { font-family: var(--font-display); font-weight: 500; font-size: clamp(2rem, 4vw, 2.8rem); letter-spacing: -.01em; }
.band .sub { margin-top: 10px; color: var(--ink-2); max-width: 58ch; }
.grid-3 { display: grid; gap: 18px; margin-top: 34px; }
@media (min-width: 820px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.step-n { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-ink); font-weight: 600; }
.step h3 { margin-top: 14px; font-size: 1.08rem; }
.step p { margin-top: 6px; color: var(--ink-2); }

.layout-card { overflow: hidden; display: flex; flex-direction: column; }
.layout-card .shot { aspect-ratio: 16 / 10; border-bottom: 1px solid var(--line); }
.layout-card .body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.layout-card h3 { font-size: 1.1rem; }
.layout-card p { color: var(--ink-2); font-size: .92rem; }
.layout-card .row { margin-top: auto; padding-top: 6px; }
.layout-card .play, .choice .box .play { color: var(--brand); font-weight: 500; }
.layout-card .play { font-size: .85rem; }
.grid-templates { display: grid; gap: 18px; margin-top: 34px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); }

/* mini schematic of each layout (landing + dashboard design picker) */
.schem { position: relative; height: 100%; background: linear-gradient(160deg, #3b1730, #170b14); overflow: hidden; }
.schem .ph { position: absolute; background: linear-gradient(135deg, #f6b3c3, #f0cfa8); }
.schem .lt { position: absolute; display: grid; align-content: start; gap: 5px; padding: 9px; }
.schem .lt i { display: block; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .55); }
.schem .lt i:nth-child(2n) { width: 80%; }
.schem-classic .ph { inset: 0 38% 0 0; }
.schem-classic .lt { inset: 0 0 0 62%; background: rgba(38, 14, 32, .9); padding-top: 18%; }
.schem-cinematic .ph { inset: 0; }
.schem-cinematic .lt { left: 18%; right: 18%; bottom: 10%; height: 30%; border-radius: 8px; background: rgba(30, 10, 25, .55); border: 1px solid rgba(255, 255, 255, .25); padding-top: 12px; justify-items: center; }
.schem-cinematic .lt i { width: 90%; }
.schem-polaroid { background: linear-gradient(160deg, #fbe7ea, #f6d9cf); }
.schem-polaroid .ph { left: 9%; top: 14%; width: 38%; height: 70%; border: 5px solid #fff; border-bottom-width: 16px; transform: rotate(-3deg); box-shadow: 0 6px 14px rgba(0, 0, 0, .18); }
.schem-polaroid .lt { right: 9%; top: 14%; width: 38%; height: 72%; background: #fffaf3; transform: rotate(2deg); box-shadow: 0 6px 14px rgba(0, 0, 0, .14); padding-top: 14px; }
.schem-polaroid .lt i { background: rgba(58, 34, 48, .35); }
/* envelope: a sealed envelope with a heart seal */
.schem-envelope .ph { left: 22%; right: 22%; top: 24%; bottom: 16%; border-radius: 4px; background: linear-gradient(160deg, #f8dde3, #efc4cf); box-shadow: 0 8px 18px rgba(0, 0, 0, .3); }
.schem-envelope .ph::before { content: ''; position: absolute; inset: 0 0 38% 0; background: #f4cdd6; clip-path: polygon(0 0, 100% 0, 50% 100%); }
.schem-envelope .ph::after { content: ''; position: absolute; left: 50%; top: 62%; width: 16%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(circle at 35% 30%, #e88aa3, #b3405f 70%); }
.schem-envelope .lt { display: none; }
/* scratch card: a photo card, half of it still under the foil */
.schem-scratch .ph { left: 32%; right: 32%; top: 12%; bottom: 12%; border-radius: 8px; border: 3px solid #fffaf3; box-shadow: 0 8px 18px rgba(0, 0, 0, .3); }
.schem-scratch .lt { left: calc(32% + 3px); right: calc(32% + 3px); top: calc(12% + 3px); bottom: 46%; padding: 0; border-radius: 5px 5px 0 0; background: repeating-linear-gradient(135deg, #f0cfa8 0 6px, #f2a7b8 6px 12px); clip-path: polygon(0 0, 100% 0, 100% 78%, 86% 100%, 72% 80%, 58% 100%, 44% 82%, 30% 100%, 16% 80%, 0 96%); }
.schem-scratch .lt i { display: none; }
/* storybook: an open book, a photo on the left page, words on the right */
.schem-storybook .ph { left: 12%; width: 37%; top: 14%; bottom: 14%; border-radius: 4px 0 0 4px; background: #fffaf3; box-shadow: inset -8px 0 12px -8px rgba(0, 0, 0, .35); }
.schem-storybook .ph::before { content: ''; position: absolute; inset: 14% 14% 22%; background: linear-gradient(135deg, #f6b3c3, #f0cfa8); transform: rotate(-2deg); }
.schem-storybook .lt { right: 12%; width: 37%; top: 14%; bottom: 14%; border-radius: 0 4px 4px 0; background: #fffaf3; align-content: center; padding: 12%; box-shadow: inset 8px 0 12px -8px rgba(0, 0, 0, .3); }
.schem-storybook .lt i { background: rgba(58, 34, 48, .3); }
/* memory game: a grid of face-down cards, two of them turned */
.schem-memory .ph { left: 22%; right: 22%; top: 16%; bottom: 16%; background: repeating-linear-gradient(90deg, #b3405f 0 21%, transparent 21% 26.33%); -webkit-mask: repeating-linear-gradient(180deg, #000 0 44%, transparent 44% 56%); mask: repeating-linear-gradient(180deg, #000 0 44%, transparent 44% 56%); }
.schem-memory .lt { left: 22%; right: 22%; top: 16%; bottom: 16%; padding: 0; display: block; }
.schem-memory .lt i { position: absolute; width: 21%; height: 44%; border-radius: 2px; background: linear-gradient(135deg, #f6b3c3, #f0cfa8); }
.schem-memory .lt i:nth-child(1) { left: 26.33%; top: 0; }
.schem-memory .lt i:nth-child(2) { left: 78.99%; top: 56%; }
.schem-memory .lt i:nth-child(n+3) { display: none; }
/* timeline: a line down the middle, photos and words on either side */
.schem-timeline .ph { left: 18%; width: 24%; top: 12%; height: 34%; border: 3px solid #fff; transform: rotate(-3deg); }
.schem-timeline .ph::after { content: ''; position: absolute; left: 190%; top: 140%; width: 100%; height: 100%; border: 3px solid #fff; background: linear-gradient(135deg, #f0cfa8, #f6b3c3); transform: rotate(5deg); }
.schem-timeline .lt { left: 50%; top: 8%; bottom: 8%; width: 2px; padding: 0; background: linear-gradient(#f2a7b8, #f0cfa8); }
.schem-timeline .lt i { position: absolute; left: 50%; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: #f2a7b8; }
.schem-timeline .lt i:nth-child(1) { top: 22%; } .schem-timeline .lt i:nth-child(2) { top: 64%; } .schem-timeline .lt i:nth-child(n+3) { display: none; }
/* gift box: a wrapped present with a bow */
.schem-gift .ph { left: 36%; right: 36%; top: 42%; bottom: 14%; border-radius: 3px; background: linear-gradient(90deg, transparent 42%, #f0cfa8 42% 58%, transparent 58%), linear-gradient(160deg, #e88aa3, #b3405f); box-shadow: 0 8px 18px rgba(0, 0, 0, .3); }
.schem-gift .ph::before { content: ''; position: absolute; left: -7%; right: -7%; top: -26%; height: 30%; border-radius: 3px; background: linear-gradient(90deg, transparent 42%, #f0cfa8 42% 58%, transparent 58%), linear-gradient(160deg, #f2a7b8, #c9506f); }
.schem-gift .ph::after { content: ''; position: absolute; left: 50%; top: -52%; width: 46%; height: 30%; transform: translateX(-50%); border: 4px solid #f0cfa8; border-radius: 50% 50% 40% 40%; border-bottom-color: transparent; }
.schem-gift .lt { display: none; }
/* starry sky: stars in the shape of a heart */
.schem-stars { background: radial-gradient(90% 80% at 50% 20%, #2a1a40, #0c0a1a 70%); }
.schem-stars .ph { inset: 10% 26%; background:
  radial-gradient(circle at 50% 22%, #f0cfa8 0 3px, transparent 4px), radial-gradient(circle at 26% 10%, #f0cfa8 0 3px, transparent 4px),
  radial-gradient(circle at 74% 10%, #f0cfa8 0 3px, transparent 4px), radial-gradient(circle at 6% 34%, #f2a7b8 0 3px, transparent 4px),
  radial-gradient(circle at 94% 34%, #f2a7b8 0 3px, transparent 4px), radial-gradient(circle at 20% 64%, #f0cfa8 0 3px, transparent 4px),
  radial-gradient(circle at 80% 64%, #f0cfa8 0 3px, transparent 4px), radial-gradient(circle at 50% 92%, #f2a7b8 0 3px, transparent 4px); }
.schem-stars .lt { display: none; }

/* halloween: a lit door under the moon */
.schem-halloween { background: radial-gradient(90% 80% at 50% 10%, #4a2470, #130a1c 70%); }
.schem-halloween .ph { left: 36%; right: 36%; top: 30%; bottom: 8%; border-radius: 999px 999px 2px 2px; background: radial-gradient(60% 70% at 50% 60%, #ffcf7a, #ff8a2b 70%); box-shadow: 0 0 14px rgba(255, 140, 40, .6); }
.schem-halloween .ph::after { content: ''; position: absolute; right: -150%; top: -150%; width: 120%; aspect-ratio: 1; border-radius: 50%; background: #f2d98a; }
.schem-halloween .lt { display: none; }
/* christmas: a snow globe with a tree */
.schem-christmas { background: radial-gradient(90% 80% at 50% 20%, #1f5a45, #0b1a16 72%); }
.schem-christmas .ph { left: 30%; right: 30%; top: 12%; bottom: 14%; border-radius: 50%; background: radial-gradient(circle at 32% 24%, rgba(255, 255, 255, .5), transparent 24%), radial-gradient(circle at 50% 60%, #12304a, #0a1a2c 72%); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .3); }
.schem-christmas .ph::after { content: ''; position: absolute; left: 30%; right: 30%; top: 22%; bottom: 14%; background: linear-gradient(#2f8a5c, #1d6341); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.schem-christmas .lt { display: none; }
/* valentine: a flower of petals */
.schem-valentine .ph { left: 34%; right: 34%; top: 20%; bottom: 20%; border-radius: 50%; background: radial-gradient(circle, #f0cfa8 0 18%, transparent 19%), conic-gradient(from 0deg, #e88aa3 0 14%, #f2a7b8 14% 28%, #e88aa3 28% 43%, #f2a7b8 43% 57%, #e88aa3 57% 71%, #f2a7b8 71% 86%, #e88aa3 86% 100%); }
.schem-valentine .lt { display: none; }

.swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.swatch { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border: 1px solid var(--line-2); border-radius: 999px; background: var(--surface); font-size: .88rem; }
.swatch .dots { display: inline-flex; }
.swatch .dots i { width: 20px; height: 20px; border-radius: 50%; border: 2px solid #fff; margin-left: -6px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .06); }
.swatch .dots i:first-child { margin-left: 0; }

.plans { display: grid; gap: 18px; margin-top: 34px; }
@media (min-width: 820px) { .plans { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.plan { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 26px; }
.plan.featured { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand), var(--shadow-2); }
.plan .tag { position: absolute; top: -12px; left: 24px; padding: 3px 10px; border-radius: 999px; background: var(--brand); color: #fff; font-size: .75rem; font-weight: 600; letter-spacing: .04em; }
.plan h3 { font-size: 1.15rem; }
.price { font-family: var(--font-display); font-size: 2.6rem; font-weight: 500; line-height: 1; }
.price small { font-family: var(--font-ui); font-size: .85rem; color: var(--ink-3); font-weight: 400; }
.plan ul { list-style: none; margin: 6px 0 10px; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; color: var(--ink-2); font-size: .92rem; }
.plan li { display: flex; gap: 9px; align-items: flex-start; }
.plan li::before { content: '♥'; color: var(--brand); font-size: .8rem; line-height: 1.7; }
.plan .btn { margin-top: auto; }
.plan .or { margin: -4px 0 0; font-size: .86rem; color: var(--ink-2); }
.plan .or strong { color: var(--brand); font-weight: 600; }
.plans-more { margin-top: 22px; }

.faq { margin-top: 30px; display: grid; gap: 10px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 0 18px; }
.faq summary { cursor: pointer; padding: 16px 0; font-weight: 500; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; color: var(--brand); font-size: 1.2rem; line-height: 1; }
.faq details[open] summary::after { content: '–'; }
.faq details p { padding: 0 0 16px; color: var(--ink-2); }

.footer { padding: 34px 0 48px; border-top: 1px solid var(--line); color: var(--ink-3); font-size: .88rem; }
.footer .container { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between; }

/* ---------- dashboard ---------- */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px; padding: 30px 0 22px; }
.page-head h1 { font-family: var(--font-display); font-weight: 500; font-size: clamp(2rem, 4vw, 2.6rem); letter-spacing: -.01em; }
.page-head .meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.create-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-start; padding: 16px; }
.create-form .field { flex: 1 1 260px; }
.page-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin: 22px 0 60px; }
.page-card { display: flex; flex-direction: column; overflow: hidden; transition: box-shadow .2s, transform .2s var(--ease); }
.page-card:hover { box-shadow: var(--shadow-2); transform: translateY(-2px); }
.page-card .cover { position: relative; aspect-ratio: 16 / 10; background: linear-gradient(140deg, #f6b3c3, #f0cfa8); overflow: hidden; }
.page-card .cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.page-card .cover .for { position: absolute; left: 14px; bottom: 12px; color: #fff; font-family: var(--font-display); font-style: italic; font-size: 1.6rem; text-shadow: 0 2px 10px rgba(0, 0, 0, .4); }
.page-card .body { padding: 14px 16px 16px; display: grid; gap: 10px; }
.page-card .facts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: .84rem; color: var(--ink-3); }
.page-card .link { font-size: .85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.empty { text-align: center; padding: 56px 20px; }
.empty .art { width: 72px; height: 72px; margin: 0 auto 14px; display: grid; place-items: center; border-radius: 22px; background: var(--brand-soft); color: var(--brand); }
.empty h2 { font-family: var(--font-display); font-weight: 500; font-size: 1.8rem; }
.empty p { margin: 8px auto 0; max-width: 46ch; color: var(--ink-2); }

.editor { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; padding-bottom: 80px; }
@media (min-width: 1140px) { .editor { grid-template-columns: minmax(0, 1fr) 380px; align-items: start; } }
.editor-main { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; min-width: 0; } /* minmax(0, …): a wide child must not stretch every card past the phone */
.section-nav { position: sticky; top: 64px; z-index: 20; display: flex; gap: 6px; overflow-x: auto; padding: 10px 0; background: var(--bg); scrollbar-width: none; }
.section-nav::-webkit-scrollbar { display: none; }
.section-nav a { flex: none; padding: 7px 13px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); text-decoration: none; font-size: .86rem; }
.section-nav a:hover { color: var(--ink); border-color: var(--ink-3); }
.preview-pane { display: none; }
@media (min-width: 1140px) {
  .preview-pane { display: block; position: sticky; top: 84px; }
  .preview-pane .phone { width: 100%; max-width: 340px; }
  .preview-pane iframe { width: 100%; height: 100%; border: 0; border-radius: 34px; background: #170b14; }
  .preview-pane .row { justify-content: center; margin-top: 14px; }
}

.thumbs { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); }
.thumb { position: relative; border-radius: 12px; overflow: hidden; background: var(--surface-2); aspect-ratio: 1; border: 1px solid var(--line); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .n { position: absolute; left: 8px; top: 8px; min-width: 24px; height: 24px; padding: 0 7px; display: grid; place-items: center; border-radius: 999px; background: rgba(23, 11, 20, .72); color: #fff; font-size: .75rem; font-weight: 600; }
.thumb .tools { position: absolute; left: 6px; right: 6px; bottom: 6px; display: flex; gap: 4px; justify-content: space-between; }
.thumb .tools .icon-btn { width: 30px; height: 30px; background: rgba(255, 255, 255, .92); border-color: transparent; }
.upload-zone { display: grid; place-items: center; align-content: center; gap: 8px; aspect-ratio: 1; border: 1.5px dashed var(--line-2); border-radius: 12px; background: #fdfaf8; color: var(--ink-2); text-align: center; padding: 10px; cursor: pointer; font-size: .86rem; }
.upload-zone:hover, .upload-zone.drag { border-color: var(--brand); color: var(--brand-ink); background: var(--brand-soft); }
.upload-zone svg { width: 26px; height: 26px; }
.meter { height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, #f0cfa8, var(--brand)); border-radius: 3px; }

/* the account's photos: used, left, buying more (partials/photo-usage) */
.usage { display: grid; gap: 10px; }
.usage-head { display: flex; flex-wrap: wrap; gap: 4px 12px; justify-content: space-between; align-items: baseline; }
.usage-count { font-size: .9rem; color: var(--ink-2); }
.usage-count b { color: var(--ink); font-weight: 600; }
.usage-full .meter i, .usage-over .meter i { background: var(--warn); }
.usage-card { padding: 16px; margin-top: 18px; }

.choice-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.choice { position: relative; display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice .box { display: block; height: 100%; border: 1.5px solid var(--line-2); border-radius: var(--radius); overflow: hidden; background: var(--surface); transition: border-color .2s, box-shadow .2s; }
.choice .box .shot { display: block; aspect-ratio: 16 / 10; }
.choice .box .txt { display: block; padding: 10px 12px; }
.choice .box b { display: block; font-size: .92rem; }
.choice .box small { display: block; margin-top: 2px; color: var(--ink-3); font-size: .8rem; line-height: 1.4; }
.choice .box small.play { margin-top: 6px; font-size: .78rem; }
.choice input:checked + .box { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.choice input:focus-visible + .box { box-shadow: var(--focus); }
.theme-choice .box { display: flex; align-items: center; gap: 10px; padding: 10px 12px; }
.theme-choice .dots { display: inline-flex; }
.theme-choice .dots i { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #fff; margin-left: -7px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .08); }
.theme-choice .dots i:first-child { margin-left: 0; }

.share-grid { display: grid; gap: 18px; }
@media (min-width: 720px) { .share-grid { grid-template-columns: 1fr 180px; } }
.qr-box { display: grid; gap: 10px; justify-items: center; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.qr-box img { width: 150px; height: 150px; }
.copy-row { display: flex; gap: 8px; }
.copy-row .input { font-size: .9rem; }

.plan-row { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.plan-option { display: flex; flex-direction: column; gap: 8px; padding: 16px; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--surface); }
.plan-option .price { font-size: 2rem; }
.plan-option.featured { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.plan-option { position: relative; }
.plan-option .tag { position: absolute; top: -11px; right: 14px; padding: 2px 9px; border-radius: 999px; background: var(--brand); color: #fff; font-size: .72rem; font-weight: 600; letter-spacing: .04em; }
.plan-option form { margin: 0; }
.plan-option.current { border-color: var(--ok); box-shadow: 0 0 0 1px var(--ok); background: linear-gradient(180deg, var(--ok-soft), var(--surface) 90px); }
.plan-option .tag-current { right: auto; left: 14px; background: var(--ok); }
.plan-option .current-note { color: var(--ok); font-weight: 500; }
.plan-option .offer { width: 100%; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0 8px; text-align: left; }
.plan-option .offer small { font-size: .74rem; font-weight: 500; opacity: .85; }
.choice .box { position: relative; }
.plan-badge { position: absolute; top: 8px; right: 8px; padding: 2px 8px; border-radius: 999px; background: rgba(255, 255, 255, .92); color: var(--brand); font-size: .7rem; font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .15); }
.orders { width: 100%; border-collapse: collapse; font-size: .88rem; }
.orders th, .orders td { text-align: left; padding: 9px 8px; border-bottom: 1px solid var(--line); }
.orders th { color: var(--ink-3); font-weight: 500; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.table-wrap { position: relative; overflow-x: auto; } /* relative: the screen-reader-only header cell must not leave the box and widen the page */

.danger-zone { border-color: #f3c9c4; }
dialog.modal { width: min(440px, calc(100% - 32px)); padding: 0; border: 0; border-radius: var(--radius-lg); box-shadow: 0 30px 80px rgba(0, 0, 0, .3); color: var(--ink); }
dialog.modal::backdrop { background: rgba(23, 11, 20, .5); backdrop-filter: blur(3px); }
dialog.modal .modal-body { padding: 22px; display: grid; gap: 12px; }
dialog.modal h2 { font-size: 1.2rem; }
dialog.modal .section-foot { border-radius: 0 0 var(--radius-lg) var(--radius-lg); }

.order-card { margin: 40px auto 80px; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 10px 22px; font-size: .95rem; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; font-weight: 500; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
@media (min-width: 960px) { .hide-art { display: none; } }

/* ---------- occasion templates (new page) ---------- */
.occasions { border: 0; padding: 0; margin: 0; min-width: 0; }
.occasions legend { font-weight: 500; padding: 0; margin-bottom: 8px; }
.occasion-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.occasion-tab input, .template-card input { position: absolute; opacity: 0; pointer-events: none; }
.occasion-tab span { display: inline-block; padding: 7px 14px; border: 1px solid var(--line-2); border-radius: 999px; cursor: pointer; background: var(--surface); }
.occasion-tab input:checked + span { background: var(--brand-soft); border-color: var(--brand); color: var(--brand-ink); }
.occasion-tab input:focus-visible + span, .template-card:has(input:focus-visible) { box-shadow: var(--focus); }
.template-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); margin-bottom: 10px; }
.template-card { position: relative; display: grid; gap: 2px; align-content: start; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; }
.template-card .name { font-weight: 500; }
.template-card:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.js .template-grid { display: none; }
.js .template-grid.on { display: grid; }

/* ---------- sign in with Google / Facebook ---------- */
.social { display: grid; gap: 10px; margin-top: 24px; }
.btn-social { width: 100%; gap: 10px; justify-content: center; }
.social-or { display: flex; align-items: center; gap: 12px; margin: 6px 0 -8px; text-align: center; }
.social-or::before, .social-or::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* ---------- admin ---------- */
.admin-tabs { display: flex; gap: 6px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.admin-tabs a { padding: 9px 14px; margin-bottom: -1px; border-bottom: 2px solid transparent; color: var(--ink-2); text-decoration: none; font-weight: 500; }
.admin-tabs a[aria-current="page"] { color: var(--brand-ink); border-bottom-color: var(--brand); }
.stat-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); margin-bottom: 18px; }
.stat { display: grid; gap: 2px; padding: 16px 18px; text-decoration: none; color: var(--ink); }
.stat .n { font-family: var(--font-display); font-size: 2.3rem; line-height: 1.1; }
.stat .l { font-weight: 500; }
.stat .s { font-size: .82rem; color: var(--ink-3); }
a.stat:hover { box-shadow: var(--shadow-2); }
.admin-card { padding: 18px; margin-bottom: 18px; }
.admin-card h2 { font-size: 1.1rem; margin-bottom: 10px; }
.admin-cols { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.bars { display: flex; align-items: flex-end; gap: 3px; height: 120px; margin: 8px 0; }
.bars .bar { flex: 1; height: 100%; display: flex; align-items: flex-end; }
.bars .bar i { display: block; width: 100%; background: var(--brand); border-radius: 3px 3px 0 0; opacity: .85; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 500; }
.table .num { text-align: right; white-space: nowrap; }
.admin-filter { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; padding: 14px 16px; margin-bottom: 18px; }
.admin-filter .field { flex: 1 1 200px; }
.admin-filter .check { display: inline-flex; align-items: center; gap: 6px; min-height: 42px; }
.table td.actions { white-space: nowrap; text-align: right; }
.table td.actions .icon-btn { width: 30px; height: 30px; margin-left: 4px; text-decoration: none; }
.pill-active { color: var(--ok); background: var(--ok-soft); }
.pill-deactivated { color: var(--ink-2); background: var(--surface-2); }
.pill-suspended { color: var(--danger); background: var(--danger-soft); }

/* ---------- paying: the ways to pay, each opening its form beneath it ---------- */
.pay-methods { display: grid; gap: 10px; }
.pay-option { border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.pay-radio { position: absolute; opacity: 0; pointer-events: none; }
.pay-tile { display: flex; align-items: center; gap: 14px; padding: 14px 16px; cursor: pointer; }
.pay-tile:hover { background: var(--surface-2); }
.pay-radio:focus-visible + .pay-tile { box-shadow: var(--focus); border-radius: var(--radius); }
.pay-radio:checked + .pay-tile { background: var(--brand-soft); }
.pay-name { display: grid; flex: 1; line-height: 1.25; }
.pay-name small { color: var(--ink-3); font-size: .84rem; }
.pay-chevron { width: 10px; height: 10px; border-right: 2px solid var(--ink-3); border-bottom: 2px solid var(--ink-3); transform: rotate(45deg); transition: transform .2s var(--ease); margin-right: 4px; }
.pay-radio:checked + .pay-tile .pay-chevron { transform: rotate(-135deg); }
.pay-panel { display: none; padding: 6px 16px 18px; border-top: 1px solid var(--line); }
.pay-radio:checked ~ .pay-panel { display: block; }
.pay-logo { display: grid; place-items: center; flex: 0 0 52px; height: 34px; border-radius: 8px; color: #fff; font-weight: 700; font-size: .8rem; letter-spacing: .04em; }
.pay-logo-gcash { background: #0b6cf5; font-size: 1.1rem; }
.pay-logo-paymaya { background: #0a0a0a; color: #3be39a; font-size: 1.2rem; text-transform: lowercase; }
.pay-logo-card-credit { background: #1a1f71; }
.pay-logo-card-mastercard { background: #222; gap: 0; }
.pay-logo-card-mastercard i { width: 18px; height: 18px; border-radius: 50%; background: #eb001b; }
.pay-logo-card-mastercard i + i { background: #f79e1b; margin-left: -7px; opacity: .92; }
.pay-form { padding-top: 14px; }
.pay-field { border: 0; margin: 0; padding: 0; min-width: 0; }
.pay-field legend { margin-bottom: 10px; }
.pay-wait { display: grid; gap: 10px; padding: 16px; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--surface-2); }
.pay-change summary { cursor: pointer; font-weight: 500; color: var(--brand-ink); width: fit-content; margin: 8px 0 12px; }
.sub-box form { margin-top: 2px; }
.subs-card { padding: 18px; margin-bottom: 14px; }
.subs-card h2 { font-size: 1.1rem; margin-bottom: 8px; }
.subs-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.subs-list li { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; padding: 10px 0; border-top: 1px solid var(--line); }
.subs-list li:first-child { border-top: 0; }
.subs-list li > div { display: grid; gap: 2px; }

/* buying photos and upgrading, under the photo meter */
.usage-more { display: grid; gap: 6px; margin-top: 4px; padding-top: 12px; border-top: 1px solid var(--line); }
.pack-form { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; }
.pack-form .field { flex: 1 1 240px; max-width: 340px; }
.usage-more .hint { margin: 0; }
@media (max-width: 520px) { .pack-form .field { flex-basis: 100%; max-width: none; } }

/* Terms and Privacy Policy */
.legal { padding-bottom: 56px; }
.legal h1 { margin: 6px 0 10px; }
.legal h2 { margin: 34px 0 10px; font-size: 1.25rem; }
.legal p, .legal li { line-height: 1.65; }
.legal ul { padding-left: 1.2em; display: grid; gap: 8px; margin: 10px 0; }
.legal code { font-size: .88em; background: var(--surface-2, rgba(0,0,0,.05)); padding: 1px 6px; border-radius: 6px; }
.legal-table { overflow-x: auto; margin: 12px 0; border: 1px solid var(--line); border-radius: 14px; }
.legal-table table { border-collapse: collapse; width: 100%; min-width: 620px; font-size: .92rem; }
.legal-table th, .legal-table td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.legal-table tr:last-child td { border-bottom: 0; }
.legal-table th { font-weight: 600; background: var(--surface-2, rgba(0,0,0,.04)); }

/* ---------- first-visit tour ---------- */
.tour-backdrop { position: fixed; inset: 0; z-index: 90; }
.tour-spot { position: fixed; z-index: 91; border-radius: 12px; pointer-events: none; box-shadow: 0 0 0 9999px rgba(23, 11, 20, .55); transition: top .25s var(--ease), left .25s var(--ease), width .25s var(--ease), height .25s var(--ease); }
.tour-spot[hidden] { display: block; visibility: hidden; }
.tour-pop { position: fixed; z-index: 92; width: min(360px, calc(100% - 24px)); padding: 18px 18px 14px; border-radius: var(--radius-lg); background: var(--surface); color: var(--ink); box-shadow: 0 30px 80px rgba(0, 0, 0, .3); display: grid; gap: 8px; }
.tour-pop h2 { font-size: 1.1rem; }
.tour-pop p { color: var(--ink-2); font-size: .94rem; }
.tour-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.tour-actions { display: flex; gap: 6px; flex-wrap: wrap; }
@media (prefers-reduced-motion: reduce) { .tour-spot { transition: none; } }
