/* DermaLogic v2: landing, auth, onboarding, dashboard, motion. Loads after styles.css. */
:root {
  --grad: linear-gradient(135deg, #3d0a1c 0%, #7b1e3a 50%, #a8305a 100%);
  --on-grad: #ffffff;
  --on-grad-soft: #fde7ee;
  --ok: #166534;
}
@media (prefers-color-scheme: dark) { :root { --ok: #4ade80; } }

/* --- shared buttons / bits --- */
.btn-lg { min-height: 52px; padding: 0.7rem 1.5rem; font-size: 1.05rem; border-radius: 14px; }
.btn-block { width: 100%; }
.btn-white { background: #fff; color: #5a0f2a; border-color: #fff; }
.btn-white:hover { background: #fde7ee; }
.btn-ghost-light { background: transparent; color: #fff; border-color: rgb(255 255 255 / 0.55); }
.btn-ghost-light:hover { background: rgb(255 255 255 / 0.14); }
.btn.loading { opacity: 0.8; pointer-events: none; }
.btn.loading span::before { content: ''; display: inline-block; width: 1em; height: 1em; margin-right: 0.5em; vertical-align: -0.15em; border: 2.5px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn-row.center { justify-content: center; }
.ic { flex: none; vertical-align: middle; }
.eyebrow { display: inline-flex; align-items: center; gap: 0.4rem; font-weight: 700; font-size: 0.85rem; letter-spacing: 0.06em; text-transform: uppercase; margin: 0 0 0.75rem; padding: 0.3rem 0.8rem; border-radius: 999px; background: rgb(255 255 255 / 0.16); color: #fff; }
.eyebrow.dark { background: var(--accent-bg); color: var(--primary); }
.engine-pill { display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.8rem; font-weight: 700; padding: 0.15rem 0.6rem; border-radius: 999px; background: var(--accent-bg); color: var(--primary); }
.engine-line { margin: 0 0 0.5rem; }

/* --- mode switching: public pages hide the app chrome --- */
body[data-mode='public'] .app-header,
body[data-mode='public'] .primary-nav,
body[data-mode='public'] .app-footer,
body[data-mode='public'] #banners { display: none; }
body[data-mode='public'] .layout { display: block; max-width: none; }
body[data-mode='public'] main { padding: 0; }
.nav-user { display: flex; flex-direction: column; gap: 0.5rem; padding: 0.5rem 1rem 1rem; }
.nav-user .btn { align-self: flex-start; }

/* --- reveal on scroll --- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }

/* --- public header --- */
.pub { color: var(--text); }
.pub-header { position: absolute; z-index: 5; top: 0; left: 0; right: 0; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem clamp(1rem, 4vw, 3rem); }
.pub-brand { display: inline-flex; align-items: center; gap: 0.5rem; color: #fff; font-weight: 800; font-size: 1.25rem; text-decoration: none; }
.pub-nav { display: flex; align-items: center; gap: 0.6rem; }
.pub-nav > a:not(.btn) { color: #fff; text-decoration: none; padding: 0.5rem 0.7rem; border-radius: 8px; font-weight: 600; }
.pub-nav > a:not(.btn):hover { background: rgb(255 255 255 / 0.14); }

/* --- landing hero --- */
.l-hero { position: relative; overflow: hidden; background: var(--grad); color: var(--on-grad); padding: 7rem clamp(1rem, 5vw, 4rem) 5rem; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 2rem; align-items: center; min-height: 92vh; }
.l-hero-bg { position: absolute; inset: 0; pointer-events: none; }
.l-hero-bg .blob { position: absolute; border-radius: 50%; filter: blur(60px); opacity: 0.45; animation: blob 14s ease-in-out infinite; }
.blob.b1 { width: 380px; height: 380px; background: #f4a6c1; top: -120px; right: 5%; }
.blob.b2 { width: 300px; height: 300px; background: #d9557f; bottom: -100px; left: 10%; animation-delay: -5s; }
.blob.b3 { width: 220px; height: 220px; background: #fff; opacity: 0.18; top: 40%; left: 45%; animation-delay: -9s; }
@keyframes blob { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(30px, -26px) scale(1.12); } }
.l-hero-copy { position: relative; max-width: 620px; }
.l-hero h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); line-height: 1.08; letter-spacing: -0.02em; color: #fff; margin: 0 0 1rem; }
.l-hero h1 em { font-style: normal; background: linear-gradient(90deg, #ffd1de, #fff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.l-lead { font-size: 1.15rem; color: var(--on-grad-soft); max-width: 52ch; }
.trust { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; padding: 0; margin: 1.5rem 0 0; color: var(--on-grad-soft); font-weight: 600; }
.trust li { display: inline-flex; align-items: center; gap: 0.4rem; }
.l-hero-art { position: relative; display: grid; place-items: center; }
.float-drops { position: absolute; inset: auto -4% -8% auto; width: 70%; opacity: 0.9; pointer-events: none; }

.phone { position: relative; width: min(300px, 70vw); aspect-ratio: 9 / 17; background: #1b0810; border-radius: 38px; padding: 12px; box-shadow: 0 30px 60px rgb(0 0 0 / 0.4), 0 0 0 2px rgb(255 255 255 / 0.12) inset; animation: bob 6s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(-1.5deg); } 50% { transform: translateY(-12px) rotate(1deg); } }
.phone-notch { position: absolute; top: 12px; left: 50%; width: 90px; height: 20px; background: #1b0810; border-radius: 0 0 14px 14px; transform: translateX(-50%); z-index: 3; }
.scan-demo { position: relative; height: 100%; border-radius: 28px; overflow: hidden; background: linear-gradient(180deg, #fce8ef, #f4a6c1 70%, #d9557f); }
.face-svg { position: absolute; inset: 8% 6% 0; width: 88%; height: auto; }
.scan-brackets { animation: brackets 2.6s ease-in-out infinite; transform-origin: center; transform-box: fill-box; }
@keyframes brackets { 0%, 100% { opacity: 0.55; transform: scale(1.04); } 50% { opacity: 1; transform: scale(1); } }
.scan-beam { position: absolute; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, transparent, #fff, transparent); box-shadow: 0 0 18px 6px rgb(255 255 255 / 0.7); animation: beam 3.2s ease-in-out infinite; }
@keyframes beam { 0% { top: 8%; } 50% { top: 88%; } 100% { top: 8%; } }
.metric { position: absolute; display: inline-flex; gap: 0.4rem; align-items: center; font-size: 0.72rem; background: rgb(255 255 255 / 0.95); color: #3d0a1c; padding: 0.3rem 0.6rem; border-radius: 999px; box-shadow: 0 6px 16px rgb(60 10 30 / 0.25); animation: pop 6s ease-in-out infinite; opacity: 0; }
.metric i { font-style: normal; color: #166534; font-weight: 700; }
.metric.m1 { top: 14%; left: 5%; animation-delay: 0.6s; }
.metric.m2 { top: 36%; right: 5%; animation-delay: 1.6s; }
.metric.m3 { bottom: 24%; left: 5%; animation-delay: 2.6s; }
.metric.m4 { bottom: 8%; right: 5%; animation-delay: 3.6s; }
@keyframes pop { 0% { opacity: 0; transform: translateY(8px) scale(0.9); } 10%, 70% { opacity: 1; transform: none; } 85%, 100% { opacity: 0; transform: translateY(-6px); } }
@media (prefers-reduced-motion: reduce) { .metric { opacity: 1; } .scan-beam { top: 50%; } }

.l-strip { background: var(--surface); border-bottom: 1px solid var(--border); }
.l-strip ul { list-style: none; margin: 0 auto; padding: 1.5rem clamp(1rem, 4vw, 3rem); max-width: 1100px; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 1rem; text-align: center; }
.l-strip strong { display: block; font-size: 2.2rem; color: var(--primary); line-height: 1.1; }
.l-strip span { color: var(--muted); font-size: 0.95rem; }

.l-section { padding: clamp(3rem, 8vw, 5.5rem) clamp(1rem, 5vw, 4rem); max-width: 1200px; margin: 0 auto; }
.l-alt { max-width: none; background: var(--accent-bg); }
.l-alt > * { max-width: 1100px; margin-left: auto; margin-right: auto; }
.l-head { text-align: center; margin-bottom: 2.5rem; }
.l-head h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); line-height: 1.15; margin: 0; }
.feature-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 1.25rem; }
.feature { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 1.5rem; transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s; }
.feature:hover { transform: translateY(-6px); box-shadow: 0 18px 36px rgb(123 30 58 / 0.14); border-color: var(--pink); }
.feature h3 { margin: 0.9rem 0 0.35rem; font-size: 1.15rem; }
.feature p { margin: 0; color: var(--muted); }
.feature-ic { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: var(--grad); color: #fff; }
.how { list-style: none; padding: 0; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; counter-reset: s; }
.how-step { text-align: center; padding: 1rem; position: relative; }
.how-step h3 { margin: 0.9rem 0 0.3rem; }
.how-step p { margin: 0; color: var(--muted); }
.how-n { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--primary); color: var(--primary-ink); font-size: 1.6rem; font-weight: 800; box-shadow: 0 0 0 8px var(--surface); }
.l-split { display: grid; grid-template-columns: 1.2fr 1fr; gap: 2.5rem; align-items: center; }
.l-split h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.15; margin: 0 0 0.75rem; }
.phases { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.75rem; }
.phases li { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-left: 6px solid var(--primary); border-radius: 14px; padding: 1rem 1.25rem; }
.phases li:nth-child(2) { border-left-color: #d9557f; margin-left: 1.5rem; }
.phases li:nth-child(3) { border-left-color: var(--pink); margin-left: 3rem; }
.phases b { color: var(--primary); }
.l-cta { text-align: center; background: var(--grad); color: #fff; padding: 4rem 1rem; margin: 0; }
.l-cta h2 { color: #fff; font-size: clamp(1.7rem, 4vw, 2.6rem); margin: 0 0 0.5rem; }
.l-cta p { color: var(--on-grad-soft); margin: 0 0 1.5rem; }
.pub-footer { padding: 2rem clamp(1rem, 5vw, 4rem); color: var(--muted); text-align: center; background: var(--surface); }
.pub-footer p { max-width: 70ch; margin: 0.5rem auto; }
.pub-footer-brand { display: inline-flex; gap: 0.5rem; align-items: center; font-weight: 800; color: var(--primary); font-size: 1.1rem; }

@media (max-width: 860px) {
  .l-hero { grid-template-columns: 1fr; padding-top: 6rem; min-height: 0; text-align: left; }
  .l-hero-art { margin-top: 1rem; }
  .l-split { grid-template-columns: 1fr; }
}

/* --- auth --- */
.auth { display: grid; grid-template-columns: minmax(300px, 0.9fr) 1.1fr; min-height: 100vh; }
.auth-side { background: var(--grad); color: #fff; padding: 2rem clamp(1.5rem, 4vw, 3.5rem); display: flex; flex-direction: column; gap: 1.5rem; position: relative; overflow: hidden; }
.auth-art { max-width: 340px; margin-top: auto; }
.auth-pitch { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; line-height: 1.15; margin: 0; }
.auth-points { list-style: none; padding: 0; margin: 0 0 auto; display: grid; gap: 0.75rem; color: var(--on-grad-soft); }
.auth-points li { display: flex; gap: 0.6rem; align-items: center; }
.auth-main { display: grid; place-items: center; padding: 2rem 1rem; }
.auth-card { width: min(440px, 100%); animation: rise 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
.auth-card h1 { font-size: 2rem; margin-top: 0; }
.auth-alt { text-align: center; color: var(--muted); margin-top: 1.5rem; }
.demo-note { display: flex; gap: 0.5rem; align-items: flex-start; font-size: 0.88rem; background: var(--accent-bg); border-radius: 10px; padding: 0.6rem 0.8rem; margin: 0 0 1rem; }
.input-wrap { position: relative; display: flex; }
.input-wrap input { padding-right: 3rem; }
.pw-toggle { position: absolute; right: 2px; top: 2px; bottom: 2px; width: 44px; border: 0; background: transparent; color: var(--muted); cursor: pointer; border-radius: 8px; display: grid; place-items: center; }
.pw-toggle:hover { color: var(--primary); }
input[aria-invalid='true'] { border-color: var(--danger); }
.field-err { color: var(--danger); font-size: 0.9rem; margin: 0; min-height: 0; font-weight: 600; }
.forgot { text-align: right; margin: -0.25rem 0 0.75rem; font-size: 0.92rem; }
.ok-msg { color: var(--ok); font-weight: 600; margin: 0.25rem 0 0.75rem; min-height: 1px; }
.strength { display: flex; gap: 4px; margin: 0 0 0.25rem; }
.strength span { flex: 1; height: 5px; border-radius: 99px; background: var(--border); transition: background 0.3s; }
.strength span.on { background: #d9557f; }
form[data-strength='3'] .strength span.on, form[data-strength='4'] .strength span.on { background: #16a34a; }
.confirm-box { text-align: center; }
.confirm-ic { width: 72px; height: 72px; margin: 0 auto 1rem; border-radius: 50%; display: grid; place-items: center; background: var(--grad); color: #fff; animation: pulse-pop 0.6s ease both; }
@keyframes pulse-pop { from { transform: scale(0.4); opacity: 0; } 70% { transform: scale(1.1); } }
@media (max-width: 800px) {
  .auth { grid-template-columns: 1fr; }
  .auth-side { padding: 1.25rem; }
  .auth-art, .auth-points { display: none; }
  .auth-pitch { font-size: 1.3rem; }
}

/* --- onboarding --- */
.onboard { min-height: 100vh; background: var(--grad); display: flex; flex-direction: column; color: #fff; }
.ob-top { display: flex; justify-content: space-between; align-items: center; padding: 1rem clamp(1rem, 4vw, 3rem); }
.ob-progress { height: 6px; background: rgb(255 255 255 / 0.25); margin: 0 clamp(1rem, 4vw, 3rem); border-radius: 99px; overflow: hidden; }
.ob-progress span { display: block; height: 100%; width: 0; background: #fff; border-radius: 99px; transition: width 0.5s cubic-bezier(0.2, 0.7, 0.2, 1); }
.ob-count { margin: 0.5rem clamp(1rem, 4vw, 3rem) 0; color: var(--on-grad-soft); min-height: 1.4em; }
.ob-stage { flex: 1; display: grid; place-items: start center; padding: 1rem 1rem 3rem; }
.ob-card { width: min(640px, 100%); background: var(--surface); color: var(--text); border-radius: 24px; padding: clamp(1.25rem, 4vw, 2.25rem); box-shadow: 0 30px 60px rgb(0 0 0 / 0.3); }
.ob-card.in-right { animation: slide-r 0.45s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.ob-card.in-left { animation: slide-l 0.45s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
@keyframes slide-r { from { opacity: 0; transform: translateX(40px); } }
@keyframes slide-l { from { opacity: 0; transform: translateX(-40px); } }
.ob-card h1 { font-size: clamp(1.5rem, 4vw, 2rem); margin-top: 0; }
.ob-hero { margin-bottom: 0.5rem; }
.ob-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 1.5rem; gap: 1rem; }
.ob-more { margin: 0.5rem 0 1rem; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0.6rem; margin: 1rem 0; }
.tiles-sm { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.tile { position: relative; display: block; cursor: pointer; font-weight: 400; }
.tile input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.tile-body { display: flex; flex-direction: column; justify-content: center; gap: 0.15rem; min-height: 64px; padding: 0.7rem 0.9rem; border: 2px solid var(--border); border-radius: 14px; background: var(--surface); transition: border-color 0.2s, background 0.2s, transform 0.2s, box-shadow 0.2s; }
.tile:hover .tile-body { border-color: var(--pink); transform: translateY(-2px); }
.tile input:checked + .tile-body { border-color: var(--primary); background: var(--accent-bg); box-shadow: 0 0 0 3px rgb(123 30 58 / 0.18); }
.tile input:focus-visible + .tile-body { outline: 3px solid var(--focus); outline-offset: 2px; }
.tile input:checked + .tile-body::after { content: '✓'; position: absolute; top: 8px; right: 12px; color: var(--primary); font-weight: 800; }
.tile small { color: var(--muted); }
.switch-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.9rem 1rem; border: 1.5px solid var(--border); border-radius: 14px; margin: 0.75rem 0; font-weight: 400; cursor: pointer; }
.switch-row span { display: flex; flex-direction: column; gap: 0.2rem; }
.switch-row small { color: var(--muted); }
.switch-row input[role='switch'] { appearance: none; -webkit-appearance: none; flex: none; width: 52px; height: 30px; border-radius: 99px; background: var(--border); position: relative; cursor: pointer; transition: background 0.25s; border: 0; }
.switch-row input[role='switch']::after { content: ''; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / 0.3); transition: transform 0.25s; }
.switch-row input[role='switch']:checked { background: var(--primary); }
.switch-row input[role='switch']:checked::after { transform: translateX(22px); }
.switch-row input[role='switch']:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.time-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.done-wrap { display: grid; place-items: center; margin-bottom: 0.5rem; }
.done-badge { position: relative; width: 96px; height: 96px; border-radius: 50%; background: var(--grad); display: grid; place-items: center; animation: pulse-pop 0.6s ease both; }
.done-badge svg { width: 60px; height: 60px; stroke: #fff; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.done-badge circle { stroke: rgb(255 255 255 / 0.35); }
.done-badge path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw 0.6s 0.4s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.burst-drop { position: absolute; top: 50%; left: 50%; border-radius: 50% 50% 50% 0; pointer-events: none; animation: burst 1.2s cubic-bezier(0.1, 0.8, 0.3, 1) forwards; }
@keyframes burst { from { transform: translate(-50%, -50%) scale(0.4) rotate(-45deg); opacity: 1; } to { transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(1) rotate(-45deg); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .done-badge path { stroke-dashoffset: 0; } }

/* --- dashboard --- */
.dash-hero { padding: 1.5rem; }
.hero-next { display: flex; align-items: center; gap: 0.8rem; margin-top: 1rem; padding: 0.8rem 1rem; background: rgb(255 255 255 / 0.16); border: 1px solid rgb(255 255 255 / 0.3); border-radius: 14px; color: #fff; text-decoration: none; transition: background 0.2s, transform 0.2s; max-width: 440px; }
.hero-next:hover { background: rgb(255 255 255 / 0.26); transform: translateX(4px); }
.hero-next span:nth-child(2) { display: flex; flex-direction: column; flex: 1; }
.hero-next small { color: #fde7ee; }
.hero-next-ic { display: grid; place-items: center; width: 38px; height: 38px; background: #fff; color: var(--primary); border-radius: 50%; flex: none; }
html.high-contrast .hero-next-ic { color: #000; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 0.9rem; margin: 1rem 0; }
.stat-card { display: flex; align-items: center; gap: 1rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem; box-shadow: var(--shadow); transition: transform 0.2s, box-shadow 0.2s; }
.stat-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgb(123 30 58 / 0.12); }
.stat-h { font-size: 1rem; margin: 0 0 0.15rem; }
.stat-card p { margin: 0; }
.ring { position: relative; width: 96px; height: 96px; flex: none; }
.ring-track { stroke: var(--border); }
.ring-bar { stroke: var(--primary); transition: stroke-dashoffset 1.2s cubic-bezier(0.2, 0.7, 0.2, 1); }
.ring-text { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; line-height: 1.1; }
.ring-text strong { font-size: 1.5rem; }
.ring-text span { font-size: 0.7rem; color: var(--muted); }
.streak-badge { display: flex; align-items: center; justify-content: center; gap: 0.2rem; width: 96px; height: 96px; flex: none; border-radius: 50%; background: var(--accent-bg); color: var(--primary); font-size: 1.8rem; }
.streak-badge.ok { background: var(--ok); color: #fff; }
.streak-badge svg { animation: flicker 1.8s ease-in-out infinite; transform-origin: 50% 90%; }
@keyframes flicker { 0%, 100% { transform: scale(1) rotate(-2deg); } 50% { transform: scale(1.12) rotate(2deg); } }
.trend { display: flex; align-items: center; gap: 0.25rem; }
.trend-up { color: var(--ok); }
.trend-down { color: var(--high); }
.week { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(7, 1fr); gap: 0.3rem; text-align: center; font-size: 0.85rem; color: var(--muted); }
.week li { display: flex; flex-direction: column; align-items: center; gap: 0.3rem; }
.week .dot { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--border); background: var(--surface); }
.week .some .dot { border-color: var(--pink); background: var(--accent-bg); }
.week .done .dot { border-color: var(--primary); background: var(--primary); color: var(--primary-ink); animation: pop-in 0.4s both; }
@keyframes pop-in { from { transform: scale(0.5); } }
.snapshot { list-style: none; padding: 0; margin: 0.5rem 0 1rem; display: grid; gap: 0.5rem; }
.meter .lvl-low { background: var(--low) !important; }
.meter .lvl-moderate { background: #d99a00 !important; }
.meter .lvl-noticeable { background: var(--high) !important; }
.empty { text-align: center; padding: 0.5rem; }
.quick { list-style: none; padding: 0; margin: 0 0 0.5rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 0.6rem; }
.quick a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.4rem; min-height: 86px; padding: 0.6rem; border: 1.5px solid var(--border); border-radius: 14px; text-decoration: none; color: var(--text); text-align: center; font-weight: 600; font-size: 0.92rem; transition: transform 0.2s, border-color 0.2s, background 0.2s; }
.quick a:hover { transform: translateY(-3px); border-color: var(--primary); background: var(--accent-bg); }
.quick .ic { color: var(--primary); width: 28px; height: 28px; }

/* meters grow when they appear */
.meter span { transform-origin: left; animation: grow 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
@keyframes grow { from { transform: scaleX(0); } }

/* --- scanning screen --- */
.scan-stage { display: grid; grid-template-columns: minmax(180px, 280px) 1fr; gap: 1.5rem; align-items: center; }
.scan-photo { position: relative; border-radius: 16px; overflow: hidden; background: #000; }
.scan-photo img { display: block; width: 100%; filter: saturate(0.9) brightness(0.92); }
.scan-line { position: absolute; left: 0; right: 0; height: 4px; background: linear-gradient(90deg, transparent, #f4a6c1, #fff, #f4a6c1, transparent); box-shadow: 0 0 24px 8px rgb(244 166 193 / 0.75); animation: beam 2.4s ease-in-out infinite; }
.scan-grid { position: absolute; inset: 0; background: linear-gradient(rgb(255 255 255 / 0.13) 1px, transparent 1px) 0 0 / 100% 28px, linear-gradient(90deg, rgb(255 255 255 / 0.13) 1px, transparent 1px) 0 0 / 28px 100%; animation: gridfade 2.4s ease-in-out infinite; }
@keyframes gridfade { 50% { opacity: 0.4; } }
.scan-title { font-size: 1.2rem; font-weight: 700; margin: 0.5rem 0; }
.scan-steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.35rem; }
.scan-steps li { color: var(--muted); padding-left: 1.7rem; position: relative; transition: color 0.3s; }
.scan-steps li::before { content: ''; position: absolute; left: 0.35rem; top: 0.45em; width: 0.7rem; height: 0.7rem; border-radius: 50%; border: 2px solid var(--border); }
.scan-steps li.on { color: var(--text); font-weight: 600; }
.scan-steps li.on::before { border-color: var(--primary); border-top-color: transparent; animation: spin 0.8s linear infinite; }
.scan-steps li.done { color: var(--text); }
.scan-steps li.done::before { background: var(--primary); border-color: var(--primary); }
@media (max-width: 640px) { .scan-stage { grid-template-columns: 1fr; } .scan-photo { max-width: 260px; } }
.engine-card .switch-row { margin-bottom: 0; }

/* ===== v2.1: illustrations, scan coaching, page banners ===== */
.art { display: block; width: 100%; height: auto; overflow: visible; }
.a-float { animation: drop-float 4.5s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.a-bob { animation: bob2 3.6s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes bob2 { 50% { transform: translateY(-7px); } }
.a-pulse { animation: pulse2 2.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes pulse2 { 50% { transform: scale(1.08); } }
.a-spin { animation: spin 14s linear infinite; }
.a-twinkle { animation: twinkle 2.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes twinkle { 0%, 100% { opacity: 0.2; transform: scale(0.6); } 50% { opacity: 1; transform: scale(1.1); } }
.a-blink { animation: blink 4s infinite; transform-box: fill-box; transform-origin: center; }
@keyframes blink { 0%, 92%, 100% { transform: scaleY(1); } 96% { transform: scaleY(0.1); } }
.a-ring-dash { animation: dash 8s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -150; } }
.a-scanline { animation: scanline 3s ease-in-out infinite; }
@keyframes scanline { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(104px); } }
.a-slide-in { animation: slidein 3.2s ease-in-out infinite; }
@keyframes slidein { 0% { transform: translate(34px, 10px) scale(0.8); opacity: 0.4; } 40%, 85% { transform: none; opacity: 1; } 100% { transform: translate(34px, 10px) scale(0.8); opacity: 0.4; } }
.a-wiggle { animation: dash 5s linear infinite; }
.a-expand { animation: expand 2.2s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes expand { from { transform: scale(0.9); opacity: 0.9; } to { transform: scale(1.7); opacity: 0; } }
.a-nudge { animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateX(8px); } }
.a-slide-x { animation: slidex 3s ease-in-out infinite alternate; }
@keyframes slidex { from { transform: translateX(-28px); } to { transform: translateX(28px); } }
.a-rise { animation: rise2 2.4s ease-in infinite; }
@keyframes rise2 { from { transform: translateY(0); opacity: 1; } to { transform: translateY(-52px); opacity: 0; } }
.a-wave { animation: wave 1s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes wave { 0%, 100% { transform: scaleY(0.3); } 50% { transform: scaleY(1.2); } }
.a-ring-bell { animation: bell 2.6s ease-in-out infinite; }
@keyframes bell { 0%, 60%, 100% { transform: rotate(0); } 10% { transform: rotate(14deg); } 20% { transform: rotate(-12deg); } 30% { transform: rotate(9deg); } 40% { transform: rotate(-6deg); } 50% { transform: rotate(3deg); } }
@media (prefers-reduced-motion: reduce) { .a-scanline { transform: translateY(52px); } }

/* page banners */
.page-hero { position: relative; overflow: hidden; display: grid; grid-template-columns: 1fr minmax(120px, 220px); align-items: center; gap: 1rem; background: var(--grad); color: #fff; border-radius: 20px; padding: 1.1rem 1.4rem; margin: 0.25rem 0 1.25rem; box-shadow: 0 10px 26px rgb(123 30 58 / 0.22); animation: rise 0.5s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.page-hero::before, .page-hero::after { content: ''; position: absolute; border-radius: 50%; background: rgb(255 255 255 / 0.1); animation: blob 12s ease-in-out infinite; }
.page-hero::before { width: 180px; height: 180px; right: -40px; top: -80px; }
.page-hero::after { width: 110px; height: 110px; left: 38%; bottom: -60px; animation-delay: -6s; }
.page-hero h1 { color: #fff; margin: 0 0 0.25rem; }
.page-hero .lead { color: var(--on-grad-soft); margin: 0; }
.page-hero-copy, .page-hero-art { position: relative; z-index: 1; }
html.high-contrast .page-hero { background: #000; border: 2px solid #fff; }
@media (max-width: 560px) { .page-hero { grid-template-columns: 1fr 96px; padding: 0.9rem; } .page-hero h1 { font-size: 1.4rem; } }

/* view entrance */
#view > *:not(.reveal):not(.page-hero) { animation: rise 0.5s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
#view > *:nth-child(2) { animation-delay: 0.05s; }
#view > *:nth-child(3) { animation-delay: 0.1s; }
#view > *:nth-child(4) { animation-delay: 0.15s; }
#view > *:nth-child(n + 5) { animation-delay: 0.2s; }

/* scan how-to + coaching */
.howto-grid { list-style: none; padding: 0; margin: 0.75rem 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0.9rem; }
.howto-grid li { display: flex; flex-direction: column; gap: 0.35rem; }
.howto-art { background: var(--grad); border-radius: 16px; padding: 0.4rem 0.8rem; aspect-ratio: 200 / 140; display: grid; place-items: center; overflow: hidden; }
.howto-grid span { color: var(--muted); font-size: 0.92rem; }
.guide-oval { transition: border-color 0.3s, box-shadow 0.3s; }
.guide-oval.is-ready { border-color: #7dffb0; border-style: solid; box-shadow: 0 0 0 9999px rgb(0 0 0 / 0.3), 0 0 28px 4px rgb(125 255 176 / 0.7); }
.coach { position: absolute; left: 0.6rem; right: 0.6rem; bottom: 0.6rem; margin: 0; padding: 0.6rem 0.9rem; text-align: center; font-weight: 700; color: #fff; background: rgb(74 14 34 / 0.88); border-radius: 14px; backdrop-filter: blur(4px); transition: background 0.3s; }
.coach[data-state='ready'] { background: rgb(22 101 52 / 0.92); }
.coach[data-state='dark'], .coach[data-state='bright'] { background: rgb(138 90 0 / 0.92); }
.countdown { position: absolute; inset: 0; display: grid; place-items: center; font-size: 6rem; font-weight: 800; color: #fff; text-shadow: 0 4px 24px rgb(0 0 0 / 0.6); pointer-events: none; }
.countdown.tick, .countdown:not([hidden]) { animation: tick 1s ease-out both; }
@keyframes tick { from { transform: scale(1.8); opacity: 0; } 30% { opacity: 1; } to { transform: scale(1); opacity: 0.9; } }
.auto-cap { margin-top: 0.25rem; }
.result-score { display: flex; align-items: center; gap: 1.25rem; background: var(--accent-bg); border-radius: 16px; padding: 1rem 1.25rem; margin-bottom: 1rem; }
.result-score h3 { margin: 0 0 0.2rem; }
.result-score .ring { width: 120px; height: 120px; }
.result-score .ring-text strong { font-size: 2rem; }

/* other places art shows up */
.ob-art { background: var(--grad); border-radius: 18px; padding: 0.4rem 1rem; margin: -0.25rem 0 1rem; max-height: 180px; display: grid; place-items: center; overflow: hidden; }
.ob-art .art { max-height: 160px; }
.how-art { width: 170px; margin: 0 auto 0.75rem; background: var(--grad); border-radius: 18px; padding: 0.3rem 0.6rem; }
.split-art { background: var(--grad); border-radius: 20px; padding: 0.6rem 1.2rem; margin-bottom: 1rem; max-width: 330px; margin-left: auto; margin-right: auto; }
.auth-art { max-width: 380px; width: 100%; }

/* ===== swipeable rows on small screens ===== */
.swipe-wrap { position: relative; }
.swipe-hint, .swipe-dots { display: none; }
@media (max-width: 800px) {
  .swipe { display: flex !important; overflow-x: auto; scroll-snap-type: x mandatory; gap: 0.8rem !important; padding: 0.25rem 0.1rem 0.9rem; margin-left: 0; margin-right: 0; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
  .swipe::-webkit-scrollbar { display: none; }
  .swipe > * { flex: 0 0 78%; scroll-snap-align: center; min-width: 0; margin: 0 !important; }
  .swipe.quick > *, .swipe.how > * { flex-basis: 46%; }
  .swipe.how > * { flex-basis: 70%; }
  .swipe-hint { display: inline-flex; align-items: center; gap: 0.4rem; position: absolute; right: 0.25rem; top: -0.4rem; z-index: 2; background: var(--primary); color: var(--primary-ink); font-size: 0.8rem; font-weight: 700; padding: 0.3rem 0.75rem 0.3rem 0.6rem; border-radius: 999px; box-shadow: 0 6px 16px rgb(123 30 58 / 0.3); pointer-events: none; transition: opacity 0.4s, transform 0.4s; }
  .swipe-hint.gone { opacity: 0; transform: translateY(-6px); }
  .swipe-hand { display: inline-flex; animation: hand 1.6s ease-in-out infinite; }
  @keyframes hand { 0%, 100% { transform: translateX(6px) rotate(8deg); } 50% { transform: translateX(-8px) rotate(-8deg); } }
  .swipe-arrows { display: inline-flex; }
  .swipe-arrows i { width: 7px; height: 7px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); margin-left: -3px; opacity: 0; animation: chev 1.4s ease-in-out infinite; }
  .swipe-arrows i:nth-child(2) { animation-delay: 0.2s; }
  .swipe-arrows i:nth-child(3) { animation-delay: 0.4s; }
  @keyframes chev { 50% { opacity: 1; } }
  .swipe-dots { display: flex; justify-content: center; gap: 6px; margin-top: -0.3rem; }
  .swipe-dots span { width: 7px; height: 7px; border-radius: 99px; background: var(--border); transition: width 0.25s, background 0.25s; }
  .swipe-dots span.on { width: 22px; background: var(--primary); }
  .l-section .swipe-hint { top: -1.6rem; }
}
@media (prefers-reduced-motion: reduce) { .swipe-hand, .swipe-arrows i { animation: none; } .swipe-arrows i { opacity: 1; } }

/* ===== v2.2: layouts from the reference designs, in burgundy ===== */
.pill-cta { display: flex; align-items: center; justify-content: space-between; gap: 1rem; width: 100%; max-width: 420px; min-height: 56px; padding: 0.3rem 0.3rem 0.3rem 1.4rem; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 999px; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; box-shadow: 0 8px 22px rgb(123 30 58 / 0.14); transition: transform 0.2s, box-shadow 0.2s; }
.pill-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgb(123 30 58 / 0.22); }
.pill-go { display: grid; place-items: center; flex: none; width: 46px; height: 46px; border-radius: 50%; background: var(--primary); color: var(--primary-ink); font-style: normal; transition: transform 0.25s; }
.pill-cta:hover .pill-go { transform: translateX(3px); }
.pill-sm { min-height: 46px; width: auto; min-width: 190px; padding-left: 1.1rem; margin-top: 0.4rem; }
.pill-sm .pill-go { width: 38px; height: 38px; }
.ob-nav-solo { justify-content: center; }
.ob-nav-solo .pill-cta { max-width: 360px; }

/* score card */
.score-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 1rem 0; padding: 1.2rem 1.4rem; background: linear-gradient(135deg, var(--accent-bg), var(--surface)); border: 1px solid var(--border); border-radius: 22px; box-shadow: var(--shadow); }
.sc-title { font-size: 1rem; color: var(--muted); margin: 0; font-weight: 600; }
.score-big { font-size: clamp(2.8rem, 9vw, 4rem); line-height: 1; font-weight: 800; margin: 0.15rem 0; color: var(--text); letter-spacing: -0.02em; }
.score-big span { font-size: 1.6rem; color: var(--primary); }
.score-card p { margin: 0; }
.score-card .ring { width: 130px; height: 130px; }
.score-card .ring-text strong { font-size: 2rem; }

/* metric ring tiles */
.tiles-row { list-style: none; padding: 0; margin: 0.5rem 0 1rem; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.7rem; }
.concerns.tiles-row { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.mtile { --ringc: var(--low); display: flex; flex-direction: column; align-items: center; gap: 0.4rem; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 0.8rem 0.6rem; box-shadow: 0 6px 16px rgb(123 30 58 / 0.08); height: 100%; transition: transform 0.2s; }
.mtile:hover { transform: translateY(-3px); }
.mtile.lvl-moderate { --ringc: #d99a00; }
.mtile.lvl-noticeable { --ringc: #d9557f; }
.mtile .ring-bar { stroke: var(--ringc); }
.mt-label { font-weight: 700; font-size: 0.92rem; text-align: center; min-height: 2.6em; display: grid; place-items: center; }
.mtile .ring { width: 76px; height: 76px; }
.mtile .ring-text strong { font-size: 1.15rem; }
.mtile .ring-text span { font-size: 0.62rem; }
.concern-tile { display: flex; flex-direction: column; gap: 0.3rem; }
.concern-tile > p { margin: 0; padding: 0 0.3rem; }

/* For you cards */
.foryou h2 { margin: 1.25rem 0 0.5rem; }
.fy-row { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0.9rem; }
.fy a { position: relative; display: flex; flex-direction: column; height: 100%; border-radius: 22px; overflow: hidden; text-decoration: none; color: var(--text); background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow); transition: transform 0.25s, box-shadow 0.25s; }
.fy a:hover { transform: translateY(-5px); box-shadow: 0 16px 30px rgb(123 30 58 / 0.18); }
.fy-art { padding: 0.5rem 1rem; background: linear-gradient(135deg, #4a0e22, #7b1e3a 55%, #d9557f); }
.fy-1 .fy-art { background: linear-gradient(135deg, #7b1e3a, #c2456f 60%, #f4a6c1); }
.fy-2 .fy-art { background: linear-gradient(135deg, #5a0f2a, #9b2c4f 50%, #e394ae); }
.fy-3 .fy-art { background: linear-gradient(135deg, #3d0a1c, #8c2a4d 60%, #d9557f); }
.fy-art .art { max-height: 120px; margin: 0 auto; }
.fy-body { display: flex; flex-direction: column; gap: 0.2rem; padding: 0.8rem 3.4rem 1rem 1rem; }
.fy-body small { color: var(--primary); font-weight: 700; }
.fy-body strong { font-size: 0.98rem; line-height: 1.3; }
.fy-go { position: absolute; right: 0.8rem; bottom: 0.8rem; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--primary); color: var(--primary-ink); }

/* reminders list with tabs */
.rt-tabs { display: flex; gap: 0.3rem; background: var(--accent-bg); border-radius: 999px; padding: 0.25rem; margin-bottom: 0.8rem; }
.rt-tab { flex: 1; min-height: 42px; border: 0; border-radius: 999px; background: transparent; color: var(--text); font: inherit; font-weight: 600; cursor: pointer; transition: background 0.2s; }
.rt-tab[aria-selected='true'] { background: var(--surface); color: var(--primary); box-shadow: 0 2px 8px rgb(123 30 58 / 0.18); }
.rt-n { display: inline-grid; place-items: center; min-width: 1.4rem; height: 1.4rem; padding: 0 0.3rem; margin-left: 0.2rem; border-radius: 99px; background: var(--primary); color: var(--primary-ink); font-size: 0.78rem; }
.rt-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.rt-row { display: flex; align-items: center; gap: 0.8rem; padding: 0.7rem 0.9rem; border: 1px solid var(--border); border-left-width: 5px; border-radius: 16px; background: var(--surface); color: var(--text); text-decoration: none; transition: transform 0.2s; }
.rt-row:hover { transform: translateX(4px); }
.rt-due { border-left-color: #d9557f; }
.rt-upcoming { border-left-color: var(--pink); }
.rt-complete { border-left-color: var(--low); }
.rt-ic { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--primary); color: var(--primary-ink); flex: none; }
.rt-text { display: flex; flex-direction: column; flex: 1; }
.rt-text small { color: var(--muted); }
.rt-empty { list-style: none; padding: 0.5rem; }

/* bottom tab bar (phones) */
.tabbar { display: none; }
@media (max-width: 800px) {
  body[data-mode='app'] .tabbar { display: flex; position: fixed; z-index: 30; left: 50%; bottom: 0.7rem; transform: translateX(-50%); width: min(430px, calc(100vw - 1rem)); justify-content: space-between; align-items: center; padding: 0.35rem 0.5rem; background: var(--surface); border: 1px solid var(--border); border-radius: 999px; box-shadow: 0 12px 32px rgb(74 14 34 / 0.28); }
  .tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.1rem; min-width: 56px; min-height: 52px; padding: 0.2rem 0.4rem; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font: inherit; font-size: 0.68rem; font-weight: 700; text-decoration: none; cursor: pointer; }
  .tab[aria-current='page'], .tab[aria-expanded='true'] { color: var(--primary); background: var(--accent-bg); }
  .tab-scan { position: relative; top: -14px; min-width: 64px; min-height: 64px; border-radius: 50%; background: var(--primary); color: var(--primary-ink); box-shadow: 0 8px 20px rgb(123 30 58 / 0.5); animation: scanpulse 2.4s ease-out infinite; }
  .tab-scan[aria-current='page'] { background: var(--primary); color: var(--primary-ink); }
  @keyframes scanpulse { 0% { box-shadow: 0 8px 20px rgb(123 30 58 / 0.5), 0 0 0 0 rgb(217 85 127 / 0.55); } 70%, 100% { box-shadow: 0 8px 20px rgb(123 30 58 / 0.5), 0 0 0 16px rgb(217 85 127 / 0); } }
  body[data-mode='app'] main { padding-bottom: 7rem; }
  body[data-mode='app'] .menu-toggle { display: none; }
  body[data-mode='app'] .toasts { bottom: 6.5rem; }
  body[data-mode='app'] .app-footer { padding-bottom: 6rem; }
  .tiles-row.swipe > * { flex-basis: 44%; }
  .fy-row.swipe > * { flex-basis: 74%; }
  .score-card { padding: 1rem; }
  .score-card .ring { width: 108px; height: 108px; }
}
@media (prefers-reduced-motion: reduce) { .tab-scan { animation: none; } }
@media (min-width: 801px) { .menu-toggle { display: none !important; } }

/* ===== voice conversation ===== */
.voice-stage { text-align: center; }
.orb { position: relative; display: grid; place-items: center; width: 168px; height: 168px; margin: 0.5rem auto 0.25rem; border: 0; border-radius: 50%; cursor: pointer; background: var(--grad); color: #fff; box-shadow: 0 14px 34px rgb(123 30 58 / 0.4); transition: transform 0.2s; -webkit-tap-highlight-color: transparent; }
.orb:active { transform: scale(0.96); }
.orb:disabled { opacity: 0.5; cursor: not-allowed; }
.orb-rings i { position: absolute; inset: 0; border-radius: 50%; border: 3px solid var(--pink); opacity: 0; }
.orb-bars { position: absolute; display: none; align-items: center; gap: 5px; height: 60px; }
.orb-bars i { width: 7px; height: 14px; border-radius: 99px; background: #fff; animation: wave 0.9s ease-in-out infinite; }
.orb-bars i:nth-child(2n) { animation-delay: 0.15s; } .orb-bars i:nth-child(3n) { animation-delay: 0.3s; } .orb-bars i:nth-child(4) { animation-delay: 0.45s; }
.voice-stage[data-state='idle'] .orb-core { animation: bob2 3.6s ease-in-out infinite; }
.voice-stage[data-state='listening'] .orb { animation: orbpulse 1.4s ease-in-out infinite; background: linear-gradient(135deg, #b42318, #7b1e3a); }
.voice-stage[data-state='listening'] .orb-rings i { animation: ripple 1.8s ease-out infinite; }
.voice-stage[data-state='listening'] .orb-rings i:nth-child(2) { animation-delay: 0.6s; }
.voice-stage[data-state='listening'] .orb-rings i:nth-child(3) { animation-delay: 1.2s; }
.voice-stage[data-state='thinking'] .orb-core { animation: spin 1.6s linear infinite; }
.voice-stage[data-state='speaking'] .orb-core { display: none; }
.voice-stage[data-state='speaking'] .orb-bars { display: flex; }
.voice-stage[data-state='speaking'] .orb-rings i { animation: ripple 2.4s ease-out infinite; border-color: #fff; }
@keyframes orbpulse { 50% { transform: scale(1.06); } }
@keyframes ripple { from { transform: scale(1); opacity: 0.7; } to { transform: scale(1.7); opacity: 0; } }
.orb-title { margin: 0.4rem 0 0; font-size: 1.25rem; font-weight: 800; }
.orb-state { margin: 0.1rem 0 0.6rem; min-height: 1.4em; }
.heard { display: grid; gap: 0.5rem; text-align: left; max-width: 560px; margin: 0 auto; }
.heard p { margin: 0; padding: 0.6rem 0.9rem; border-radius: 16px; }
.heard small { display: block; font-weight: 700; color: var(--primary); }
.heard-you { background: var(--accent-bg); }
.heard-bot { background: var(--surface); border: 1px solid var(--border); }
.followups { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem; margin: 0.75rem 0 0; }
.voice-opts { text-align: left; max-width: 560px; margin: 1rem auto 0; border-top: 1px solid var(--border); padding-top: 0.5rem; }
@media (prefers-reduced-motion: reduce) { .voice-stage[data-state='listening'] .orb-rings i { opacity: 0.5; } }

/* ===== v2.4: illustrated products and portraits ===== */
.pic { display: block; width: 100%; height: auto; overflow: visible; }
.photo { display: block; width: 100%; height: 100%; object-fit: cover; }
.portrait { border-radius: 22px; }
.shelf-item { animation: bob2 4s ease-in-out infinite; transform-box: fill-box; transform-origin: bottom center; }

/* landing hero phone: cycling portraits */
.demo-faces { position: absolute; inset: 6% 7% 18%; }
.demo-face { position: absolute; inset: 0; border-radius: 26px; overflow: hidden; opacity: 0; animation: faces 16s ease-in-out infinite; box-shadow: 0 10px 24px rgb(74 14 34 / 0.3); }
.demo-face .pic { width: 100%; height: 100%; border-radius: 0; }
@keyframes faces { 0% { opacity: 0; transform: scale(1.06); } 5%, 22% { opacity: 1; transform: none; } 27%, 100% { opacity: 0; } }
.face-svg { z-index: 2; inset: 6% 7% 18% !important; width: 86% !important; height: auto; }
@media (prefers-reduced-motion: reduce) { .demo-face:first-child { opacity: 1; } }

.l-people { text-align: center; }
.l-sub { max-width: 60ch; margin: 0.6rem auto 0; color: var(--muted); }
.people { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; }
.person-pic { border-radius: 26px; overflow: hidden; box-shadow: 0 14px 28px rgb(123 30 58 / 0.2); transition: transform 0.3s; margin-bottom: 0.6rem; }
.person:hover .person-pic { transform: translateY(-6px) rotate(-1.5deg); }
.person-pic .pic { border-radius: 0; }
.product-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1rem; }
.product-card { text-align: center; background: var(--surface); border: 1px solid var(--border); border-radius: 22px; padding: 0 1rem 1.2rem; transition: transform 0.25s, box-shadow 0.25s; overflow: hidden; }
.product-card:hover { transform: translateY(-6px); box-shadow: 0 18px 34px rgb(123 30 58 / 0.18); }
.product-stage { background: linear-gradient(160deg, #fce8ef, #f4a6c1); margin: 0 -1rem 0.8rem; padding: 1.2rem 1rem 0.6rem; }
.product-stage .pic { width: 62%; margin: 0 auto; filter: drop-shadow(0 10px 12px rgb(74 14 34 / 0.25)); transition: transform 0.4s; }
.product-card:hover .product-stage .pic { transform: translateY(-6px) scale(1.05); }
.product-role { font-size: 0.8rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 0.04em; }
.product-card h3 { margin: 0.2rem 0; }
.product-card p { margin: 0; color: var(--muted); font-size: 0.92rem; }

/* onboarding welcome faces */
.ob-faces { display: flex; justify-content: center; margin: 0 0 0.75rem; }
.ob-faces span { width: 76px; height: 76px; margin-left: -14px; border-radius: 50%; overflow: hidden; border: 3px solid var(--surface); box-shadow: 0 6px 14px rgb(123 30 58 / 0.25); animation: bob2 3.6s ease-in-out infinite; }
.ob-faces span:first-child { margin-left: 0; }
.ob-faces span:nth-child(2n) { animation-delay: 0.4s; }
.ob-faces span:nth-child(3n) { animation-delay: 0.8s; }
.ob-faces .pic { width: 100%; height: 100%; border-radius: 0; }
.ob-faces svg { transform: scale(1.5) translateY(6%); }
.ob-hero { display: none; }

/* dashboard avatar and routine thumbs */
.hero-main { display: flex; gap: 0.9rem; align-items: flex-start; }
.hero-avatar { flex: none; width: 64px; height: 64px; border-radius: 50%; overflow: hidden; border: 3px solid rgb(255 255 255 / 0.85); box-shadow: 0 6px 16px rgb(0 0 0 / 0.3); }
.hero-avatar svg { width: 100%; height: 100%; border-radius: 0; transform: scale(1.5) translateY(6%); }
.cthumb, .rthumb { flex: none; width: 38px; background: linear-gradient(160deg, #fce8ef, #f4a6c1); border-radius: 12px; padding: 4px 6px 2px; align-self: flex-start; }
.rstep { list-style: none; display: flex; gap: 0.7rem; align-items: flex-start; }
.routine { padding-left: 0 !important; }
.rtext { display: flex; flex-direction: column; }
.rthumb { width: 46px; }
.fy-art .art { max-height: 130px; }
.page-hero-art .art { max-height: 150px; }
@media (max-width: 560px) { .hero-avatar { width: 52px; height: 52px; } }
