/* ===== iQ Salon — design system (dark-first, violet) ===== */
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('/static/fonts/PlusJakartaSans.woff2') format('woff2-variations'), url('/static/fonts/PlusJakartaSans.woff2') format('woff2');
  font-weight: 200 800; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+2000-206F, U+20AC, U+2122, U+2190-2199;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('/static/fonts/Vazirmatn.woff2') format('woff2-variations'), url('/static/fonts/Vazirmatn.woff2') format('woff2');
  font-weight: 100 900; font-display: swap;
}
:root, :root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0E0E14;
  --surface: #16161F;
  --surface-2: #1B1B26;
  --nude: #272735;
  --nude-2: #1F1F2B;
  --line: #2B2B3A;
  --line-soft: #22222E;
  --ink: #F8F8FA;
  --ink-2: #D3D3DD;
  --muted: #A6A6B5;
  --faint: #80808F;
  --accent: #7B61FF;
  --accent-2: #9B87FF;
  --accent-ink: #B9ADFF;
  --accent-soft: rgba(123, 97, 255, .16);
  --on-accent: #FFFFFF;
  --sand: #EADCC8;
  --deep: #0A0A0F;
  --deep-2: #191923;
  --deep-line: #2A2A38;
  --deep-ink: #F8F8FA;
  --deep-muted: #A6A6B5;
  --hero-bg: var(--deep); --hero-ink: var(--deep-ink); --hero-muted: var(--deep-muted); --hero-line: var(--deep-line);
  --hero-pill: rgba(255,255,255,.03); --hero-pill-line: #3A3A4A; --hero-q: .9;
  --strong: #F8F8FA;
  --on-strong: #0E0E14;
  --green: #74D3A0;  --green-soft: rgba(116, 211, 160, .13);
  --red: #FF9282;    --red-soft: rgba(255, 146, 130, .13);
  --violet: #B9ADFF; --violet-soft: rgba(123, 97, 255, .16);
  --rose: #F5A3C0;   --rose-soft: rgba(245, 163, 192, .13);
  --amber: #F0C47A;  --amber-soft: rgba(240, 196, 122, .13);
  --gray-soft: rgba(255, 255, 255, .07);
  --now: #FF6B8A;
  --glass: rgba(14, 14, 20, .86);
  --shadow: 0 1px 0 rgba(255,255,255,.03) inset, 0 10px 30px rgba(0,0,0,.28);
  --shadow-lg: 0 24px 70px rgba(0,0,0,.55);
  --grad: linear-gradient(135deg, #A897FF 0%, #7B61FF 45%, #5B3FE6 100%);
  --radius: 22px;
  --radius-sm: 14px;
  --side-w: 260px;
  --tabbar-h: 72px;
  --gutter: clamp(14px, 2.6vw, 32px);
  /* legacy aliases used by templates */
  --plum: var(--deep); --plum-2: var(--deep-2); --plum-line: var(--deep-line);
  --gold: var(--accent); --gold-ink: var(--accent-ink); --gold-soft: var(--accent-soft);
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #F6F6F9;
  --surface: #FFFFFF;
  --surface-2: #FAFAFC;
  --nude: #ECEAF5;
  --nude-2: #F2F1F8;
  --line: #E4E3EC;
  --line-soft: #EEEDF3;
  --ink: #0E0E14;
  --ink-2: #3A3A48;
  --muted: #646474;
  --faint: #868695;
  --accent-ink: #5B3FE6;
  --accent-soft: #EFEBFF;
  --strong: #0E0E14;
  --on-strong: #F8F8FA;
  --green: #217A4B;  --green-soft: #E5F4EC;
  --red: #B1402F;    --red-soft: #FBE9E6;
  --violet: #5B3FE6; --violet-soft: #EFEBFF;
  --rose: #A83A62;   --rose-soft: #FBEAF1;
  --amber: #8A5A10;  --amber-soft: #FBF1DF;
  --gray-soft: #EEEEF2;
  --glass: rgba(255, 255, 255, .92);
  --hero-bg: radial-gradient(120% 140% at 0% 0%, #EFEAFF 0%, #FFFFFF 55%); --hero-ink: #0E0E14; --hero-muted: #5C5C6E; --hero-line: #E4E0F5;
  --hero-pill: #FFFFFF; --hero-pill-line: #E0DCF0; --hero-q: 1;
  --shadow: 0 1px 2px rgba(14,14,20,.04), 0 8px 28px rgba(14,14,20,.06);
  --shadow-lg: 0 24px 60px rgba(14,14,20,.18);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: 'Plus Jakarta Sans', 'Vazirmatn', Tahoma, sans-serif; font-size: 15px; line-height: 1.7;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img, svg { max-width: 100%; }
a { color: var(--accent-ink); text-decoration: none; }
a:hover { color: var(--accent-2); }
h1, h2, h3 { margin: 0; line-height: 1.5; }
h1 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 800; }
h2 { font-size: 17px; font-weight: 700; }
h3 { font-size: 15px; font-weight: 700; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2.5px solid var(--accent-2); outline-offset: 2px; border-radius: 6px; }
::selection { background: rgba(123, 97, 255, .35); }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.trunc { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.num { font-feature-settings: "tnum"; }
.signed { direction: ltr; unicode-bidi: isolate; }
.green { color: var(--green); } .red { color: var(--red); } .gold { color: var(--accent-ink); }
.row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.row.wrap { flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }
.stack { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.stack.sm { gap: 8px; }
.only-mobile { display: none; }

/* ===== Brand ===== */
.logo { --wm-ink: var(--ink); display: inline-flex; align-items: center; gap: .32em; direction: ltr; unicode-bidi: isolate; color: var(--ink); font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 600; letter-spacing: -.5px; line-height: 1; align-self: flex-start; }
.logo svg { flex: 0 0 auto; }
.logo .word {
  font-size: 1em; font-weight: 700; letter-spacing: -.035em; line-height: 1; padding-bottom: .06em;
  background: linear-gradient(100deg, var(--wm-ink) 0%, var(--wm-ink) 42%, #C9BCFF 50%, var(--wm-ink) 58%, var(--wm-ink) 100%);
  background-size: 260% 100%; background-position: 100% 0; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: wmShine 7s ease-in-out 1.6s infinite;
}
@keyframes wmShine { 0%, 62% { background-position: 100% 0; } 85%, 100% { background-position: 0% 0; } }
.logo.on-deep { --wm-ink: var(--deep-ink); color: var(--deep-ink); }
.tagline { align-self: flex-start; font-family: 'Plus Jakarta Sans', sans-serif; letter-spacing: .32em; text-transform: uppercase; font-size: 11px; color: var(--muted); direction: ltr; }
.brand-mark { width: 42px; height: 42px; flex: 0 0 42px; border-radius: 13px; background: var(--deep); border: 1px solid var(--deep-line); display: grid; place-items: center; }
.glow { position: absolute; border-radius: 50%; filter: blur(60px); background: radial-gradient(circle, rgba(123,97,255,.55), rgba(123,97,255,0) 70%); pointer-events: none; }

/* ===== App shell ===== */
.app { min-height: 100vh; display: flex; align-items: flex-start; }
.side {
  flex: 0 0 var(--side-w); width: var(--side-w); position: sticky; top: 0; height: 100vh; overflow-y: auto; overflow-x: hidden;
  background: var(--deep); color: var(--deep-ink); padding: 24px 14px; display: flex; flex-direction: column; gap: 4px;
  border-inline-start: 1px solid var(--deep-line); scrollbar-width: thin; scrollbar-color: var(--deep-line) transparent;
}
.brand { display: flex; flex-direction: column; gap: 6px; padding: 4px 10px 20px; color: var(--deep-ink); min-width: 0; }
.brand:hover { color: var(--deep-ink); }
.brand-sub { font-size: 12px; color: var(--deep-muted); }
.navsec { font-size: 11px; color: #6E6E7E; padding: 14px 14px 4px; }
.navlink {
  display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 0 14px; border-radius: 14px;
  color: #B4B4C2; font-size: 14.5px; white-space: nowrap; position: relative;
}
.navlink:hover { background: var(--deep-2); color: var(--deep-ink); }
.navlink.on { background: rgba(123, 97, 255, .22); color: #FFFFFF; font-weight: 700; }
.navlink.on::before { content: ''; position: absolute; inset-inline-start: -14px; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--accent); }
.navlink.on svg { color: var(--accent-2); }
.navlink .badge { margin-inline-start: auto; }
.side-foot { margin-top: auto; padding-top: 16px; }
.side-card { border: 1px solid var(--deep-line); background: var(--deep-2); border-radius: 18px; padding: 12px; display: flex; flex-direction: column; gap: 6px; }

.main { flex: 1 1 auto; min-width: 0; padding: var(--gutter); padding-top: max(var(--gutter), calc(env(safe-area-inset-top) + 8px)); padding-bottom: calc(var(--gutter) + 12px); display: flex; flex-direction: column; gap: 20px; }
.topbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.topbar .title { flex: 1 1 220px; min-width: 0; }
.topbar .actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* Mobile tab bar */
.tabbar {
  display: none; position: fixed; inset-inline: 0; bottom: 0; z-index: 30; height: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  padding: 0 6px env(safe-area-inset-bottom); background: var(--glass); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--line); grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: center;
}
.tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px; color: var(--faint); font-size: 11px; background: none; border: 0; padding: 0; cursor: pointer; }
.tab.on { color: var(--accent-ink); font-weight: 700; }
.tab-fab { display: grid; place-items: center; }
.fab {
  width: 58px; height: 58px; border-radius: 50%; border: 0; background: var(--grad); color: #fff;
  display: grid; place-items: center; box-shadow: 0 10px 26px rgba(123,97,255,.5); margin-top: -26px; cursor: pointer;
}
.mtop { display: none; }

@media (max-width: 1023px) {
  .side { display: none; }
  .tabbar { display: grid; }
  .main { padding-bottom: calc(var(--tabbar-h) + 28px + env(safe-area-inset-bottom)); }
  .mtop { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .hide-mobile { display: none !important; }
  .only-mobile { display: initial; }
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px;
  border-radius: var(--radius-sm); border: 1.5px solid transparent; font-size: 15px; font-weight: 700; cursor: pointer;
  white-space: nowrap; text-decoration: none; transition: transform .08s ease, filter .15s ease, background .15s ease; line-height: 1;
}
.btn:active { transform: scale(.98); }
.btn-gold { background: var(--grad); color: var(--on-accent); box-shadow: 0 8px 22px rgba(123,97,255,.32); }
.btn-gold:hover { filter: brightness(1.08); color: var(--on-accent); }
.btn-dark { background: var(--accent); color: #fff; }
.btn-dark:hover { filter: brightness(1.1); color: #fff; }
.btn-line { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-line:hover { background: var(--nude-2); border-color: var(--muted); color: var(--ink); }
.btn-soft { background: var(--nude-2); color: var(--ink); border-color: var(--line-soft); }
.btn-soft:hover { background: var(--nude); color: var(--ink); }
.btn-ghost { background: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--nude-2); color: var(--ink); }
.btn-danger { background: var(--red-soft); color: var(--red); }
.btn-sm { min-height: 40px; padding: 0 14px; font-size: 13.5px; border-radius: 12px; }
.btn-block { width: 100%; }
.icon-btn { width: 48px; height: 48px; padding: 0; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); display: inline-grid; place-items: center; cursor: pointer; position: relative; flex: 0 0 auto; }
.icon-btn:hover { background: var(--nude-2); color: var(--ink); }
.back-btn { border-radius: 14px; }
.back-btn svg { transition: transform .15s ease; }
.back-btn:hover svg { transform: translateX(3px); }
.icon-btn .dot { position: absolute; top: 10px; left: 11px; width: 9px; height: 9px; border-radius: 50%; background: var(--now); border: 2px solid var(--surface); }
.pill { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 999px; font-size: 14px; font-weight: 600; white-space: nowrap; cursor: pointer; border: 1px solid transparent; }

/* ===== Cards ===== */
.card { background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; min-width: 0; }
.card.flat { box-shadow: none; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; min-width: 0; flex-wrap: wrap; }
.card-head a { font-size: 13px; min-height: 40px; display: inline-flex; align-items: center; }
.cols { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
.cols > .wide { flex: 999 1 520px; min-width: 0; }
.cols > .narrow { flex: 1 1 300px; min-width: 0; }
.cols > .half { flex: 1 1 340px; min-width: 0; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 14px; }
.grid-kpi { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); gap: 14px; }
@media (max-width: 639px) {
  .grid-kpi { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .grid-kpi .card { padding: 14px; border-radius: 18px; }
  .grid-kpi .kpi .value { font-size: 19px; }
  .grid-kpi .kpi .label { font-size: 12px; }
  .grid-kpi .chip { display: none; }
}

.hero {
  position: relative; overflow: hidden; background: var(--hero-bg); color: var(--hero-ink); border-radius: 28px; border: 1px solid var(--hero-line);
  padding: clamp(22px, 3vw, 36px); display: flex; flex-wrap: wrap; gap: 22px; align-items: flex-end; justify-content: space-between;
}
.hero h1 { font-weight: 300; }
.hero h1 b { font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero { flex-direction: column; align-items: flex-start; justify-content: center; min-height: 230px; }
.hero > .hero-text { flex: 0 0 auto; max-width: 640px; }
.hero .deco { overflow: visible; position: absolute; left: 20px; top: 50%; width: 250px; height: 250px; transform: translateY(-50%); opacity: var(--hero-q); pointer-events: none; filter: drop-shadow(0 18px 36px rgba(91,63,230,.32)); }
@media (min-width: 900px) { .hero { padding-inline-end: 300px; } }
@media (max-width: 899px) { .hero .deco { left: -140px; top: -50px; width: 250px; height: 250px; transform: none; opacity: .26; } }
.hero .glow { width: 360px; height: 360px; left: -80px; bottom: -180px; }
.hero-sub { color: var(--hero-muted); }
.hero-text { position: relative; flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.hero-actions { position: relative; display: flex; flex-wrap: wrap; gap: 10px; }
.hero .pill-gold { background: var(--grad); color: #fff; box-shadow: 0 8px 24px rgba(123,97,255,.4); }
.hero .pill-gold:hover { color: #fff; filter: brightness(1.08); }
.hero .pill-line { border-color: var(--hero-pill-line); color: var(--hero-ink); background: var(--hero-pill); }
.hero .pill-line:hover { border-color: var(--accent); color: var(--hero-ink); }

.kpi { display: flex; flex-direction: column; gap: 8px; }
.kpi .label { font-size: 13px; color: var(--muted); }
.kpi .value { font-size: clamp(22px, 2.3vw, 28px); font-weight: 800; line-height: 1.3; }
.kpi .unit { font-size: 12px; color: var(--faint); }
.kpi.dark { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 14px 34px rgba(91,63,230,.35); }
.kpi.dark .label, .kpi.dark .unit { color: rgba(255,255,255,.78); }
.kpi.dark .value { color: #fff; }
.spark { width: 100%; height: 30px; display: block; }

.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; border-radius: 999px; padding: 2px 10px; white-space: nowrap; font-weight: 600; line-height: 1.8; }
.chip-green { background: var(--green-soft); color: var(--green); }
.chip-red { background: var(--red-soft); color: var(--red); }
.chip-gold { background: var(--accent-soft); color: var(--accent-ink); }
.chip-violet { background: var(--violet-soft); color: var(--violet); }
.chip-gray { background: var(--gray-soft); color: var(--ink-2); }
.chip-rose { background: var(--rose-soft); color: var(--rose); }
.chip-amber { background: var(--amber-soft); color: var(--amber); }
.badge { background: var(--accent); color: #fff; font-weight: 700; font-size: 11.5px; border-radius: 999px; padding: 0 8px; line-height: 20px; }

.avatar { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #0E0E14; font-size: 15px; }
.avatar.sm { width: 32px; height: 32px; flex-basis: 32px; font-size: 13px; }
.avatar.lg { width: 64px; height: 64px; flex-basis: 64px; font-size: 24px; }
.avatar.soft { background: var(--accent-soft) !important; color: var(--accent-ink); }
.ico-box { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 13px; display: grid; place-items: center; }

/* Lists */
.list { display: flex; flex-direction: column; }
.item { display: flex; align-items: center; gap: 12px; padding: 12px 2px; border-bottom: 1px solid var(--line-soft); min-width: 0; color: var(--ink); }
.item:last-child { border-bottom: 0; }
a.item:hover { background: var(--surface-2); color: var(--ink); }
.item .meta { display: flex; flex-direction: column; gap: 1px; flex: 1 1 auto; min-width: 0; }
.item .t { font-weight: 600; font-size: 14.5px; }
.item .s { font-size: 12.5px; color: var(--muted); }
.item .end { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.time { font-weight: 700; flex: 0 0 52px; font-size: 14px; }
.dot { width: 9px; height: 9px; flex: 0 0 9px; border-radius: 50%; display: inline-block; }

/* Segmented control */
.seg { display: inline-flex; gap: 4px; background: var(--nude-2); border: 1px solid var(--line-soft); border-radius: 14px; padding: 4px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg a, .seg button { min-height: 40px; padding: 0 14px; border-radius: 11px; font-size: 13.5px; font-weight: 600; color: var(--muted); display: inline-flex; align-items: center; white-space: nowrap; border: 0; background: none; cursor: pointer; }
.seg a:hover { color: var(--ink); }
.seg .on { background: var(--accent); color: #fff !important; box-shadow: 0 4px 14px rgba(123,97,255,.35); }

.pager { display: inline-flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 4px; max-width: 100%; }
.pager a { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 12px; display: grid; place-items: center; color: var(--ink); }
.pager a:hover { background: var(--nude-2); }
.pager .lbl { padding: 0 8px; font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* Forms */
.form { display: flex; flex-direction: column; gap: 16px; }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .field > .lbl { font-size: 13.5px; font-weight: 600; color: var(--ink-2); }
.field .hint { font-size: 12px; color: var(--faint); }
.input, select.input, textarea.input {
  width: 100%; min-height: 50px; border: 1.5px solid var(--line); background: var(--surface-2); border-radius: var(--radius-sm);
  padding: 0 14px; font-size: 16px; color: var(--ink); transition: border-color .15s, box-shadow .15s;
}
.input::placeholder { color: var(--faint); }
textarea.input { padding: 12px 14px; min-height: 96px; resize: vertical; line-height: 1.8; }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23A6A6B5' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: left 14px center; padding-left: 36px; }
select.input option, select.input optgroup { background: var(--surface); color: var(--ink); }
.input:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 4px rgba(123,97,255,.22); }
.input.ltr { direction: ltr; text-align: right; }
.input-money { position: relative; }
.input-money .input { padding-left: 64px; font-weight: 700; letter-spacing: .2px; }
.input-money .unit { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-size: 13px; color: var(--faint); pointer-events: none; }
.search { position: relative; flex: 1 1 260px; min-width: 0; }
.search .input { padding-right: 46px; }
.search svg { position: absolute; right: 15px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 130px), 1fr)); gap: 8px; }
.choice label { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; }
.choice span { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 6px 12px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); font-weight: 600; font-size: 14px; text-align: center; background: var(--surface-2); line-height: 1.5; }
.choice input:checked + span { border-color: var(--accent); background: var(--accent-soft); color: var(--ink); box-shadow: 0 0 0 1px var(--accent) inset; }
.choice input:focus-visible + span { outline: 2.5px solid var(--accent-2); outline-offset: 2px; }
.check { display: flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; font-size: 14.5px; }
.check input { width: 22px; height: 22px; accent-color: var(--accent); }
.swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.swatches label { position: relative; }
.swatches input { position: absolute; opacity: 0; }
.swatches span { width: 40px; height: 40px; border-radius: 50%; display: block; border: 3px solid var(--surface); box-shadow: 0 0 0 1.5px var(--line); cursor: pointer; }
.swatches input:checked + span { box-shadow: 0 0 0 2.5px var(--ink); }
.swatches input:focus-visible + span { outline: 2.5px solid var(--accent-2); outline-offset: 3px; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-start; padding-top: 4px; }
.form-actions .btn { flex: 1 1 160px; }

/* Flash */
.flash { border-radius: 16px; padding: 12px 16px; font-size: 14px; display: flex; gap: 10px; align-items: center; border: 1px solid transparent; }
.flash.ok { background: var(--green-soft); color: var(--green); border-color: rgba(116,211,160,.18); }
.flash.err { background: var(--red-soft); color: var(--red); border-color: rgba(255,146,130,.18); }
.flash.info { background: var(--accent-soft); color: var(--accent-ink); border-color: rgba(123,97,255,.22); }

/* Dialog / bottom sheet */
dialog.sheet {
  border: 1px solid var(--line); padding: 0; border-radius: 28px; width: min(560px, calc(100vw - 32px)); max-height: calc(100vh - 48px);
  background: var(--surface); color: var(--ink); box-shadow: var(--shadow-lg); overflow: hidden;
}
dialog.sheet::backdrop { background: rgba(5,5,10,.6); backdrop-filter: blur(3px); }
.sheet-in { display: flex; flex-direction: column; max-height: calc(100vh - 48px); }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 18px 22px 8px; }
.sheet-body { padding: 8px 22px 22px; overflow-y: auto; }
@media (max-width: 639px) {
  dialog.sheet { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 26px 26px 0 0; max-height: 92vh; border-bottom: 0; }
  .sheet-in { max-height: 92vh; }
  .sheet-body { padding-bottom: calc(22px + env(safe-area-inset-bottom)); }
}
.grip { width: 44px; height: 5px; border-radius: 5px; background: var(--line); margin: 10px auto 0; display: none; }
@media (max-width: 639px) { .grip { display: block; } }

/* Tables */
.table-wrap { overflow-x: auto; margin: 0 -4px; padding: 0 4px; }
table.table { width: 100%; border-collapse: collapse; min-width: 560px; font-size: 14px; }
.table th { text-align: right; font-size: 12.5px; color: var(--muted); font-weight: 600; padding: 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 12px 10px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table .n { text-align: left; white-space: nowrap; font-weight: 700; }

/* Empty */
.empty { text-align: center; padding: 36px 16px; display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--muted); }
.empty svg { color: var(--accent-2); }
.empty h3 { color: var(--ink); }

/* Bars */
.bar { height: 8px; background: var(--nude); border-radius: 8px; overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 8px; }
.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; align-items: end; height: 150px; }
.week .d { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 100%; min-width: 0; }
.week .b { width: 100%; max-width: 30px; min-height: 4px; background: var(--nude); border-radius: 8px 8px 4px 4px; }
.week .d.today .b { background: var(--grad); box-shadow: 0 6px 18px rgba(123,97,255,.4); }
.week .l { font-size: 11px; color: var(--faint); }
.week .d.today .l { color: var(--ink); font-weight: 800; }

/* ===== Calendar ===== */
.cal-wrap { overflow-x: auto; margin: 0 -6px; padding: 0 6px 6px; -webkit-overflow-scrolling: touch; }
.cal { display: grid; column-gap: 10px; min-width: var(--cal-min, 640px); }
.cal-head { display: flex; align-items: center; gap: 8px; padding-bottom: 12px; min-width: 0; }
.cal-times { position: relative; }
.cal-times span { position: absolute; right: 0; transform: translateY(-50%); font-size: 11px; color: var(--faint); }
.cal-col {
  position: relative; border-radius: 14px; background-color: var(--surface-2); border: 1px solid var(--line-soft);
  background-image: repeating-linear-gradient(to bottom, var(--line-soft) 0, var(--line-soft) 1px, transparent 1px, transparent var(--hour, 64px));
}
.cal-slot { position: absolute; inset-inline: 0; display: block; border-radius: 10px; }
.cal-slot:hover { background: var(--accent-soft); }
.appt {
  position: absolute; inset-inline: 4px; border-radius: 12px; padding: 6px 10px; overflow: hidden;
  display: flex; flex-direction: column; color: var(--ink); font-size: 12px; line-height: 1.6; border-inline-start: 3px solid var(--c, var(--accent));
}
.appt:hover { color: var(--ink); filter: brightness(1.12); }
.appt b { font-size: 12.5px; }
.appt span { color: var(--ink-2); }
.appt.done { opacity: .7; }
.appt.cancelled, .appt.noshow { opacity: .45; text-decoration: line-through; }
.now-line { position: absolute; inset-inline: 0; height: 2px; background: var(--now); z-index: 2; pointer-events: none; box-shadow: 0 0 10px var(--now); }
.now-line::before { content: ''; position: absolute; right: -5px; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--now); }

/* Statement */
.statement .line { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line-soft); font-size: 14.5px; }
.statement .line span:first-child { color: var(--ink-2); }
.statement .line b { white-space: nowrap; }
.statement .total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-top: 16px; flex-wrap: wrap; }
.statement .total b { font-size: clamp(22px, 3vw, 28px); color: var(--accent-ink); }

/* ===== Login ===== */
.auth { min-height: 100vh; display: flex; flex-wrap: wrap; background: var(--deep); }
.auth-art { flex: 1 1 440px; min-height: 280px; position: relative; overflow: hidden; color: var(--deep-ink); padding: clamp(28px, 5vw, 64px); display: flex; flex-direction: column; justify-content: flex-end; gap: 14px; background-size: cover; background-position: center; }
.auth-art::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,10,15,.2) 0%, rgba(10,10,15,.85) 85%); pointer-events: none; }
.auth-art > *:not(.deco):not(.glow) { position: relative; z-index: 1; }
.auth-art .deco { overflow: visible; position: absolute; z-index: 0; right: -120px; top: -80px; width: 620px; height: 620px; }
.auth-art .glow { z-index: 0; width: 520px; height: 520px; right: -60px; top: 0; }
.auth-art h1 { font-size: clamp(28px, 4vw, 46px); font-weight: 300; line-height: 1.45; }
.auth-art h1 b { font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.auth-art .en { font-family: 'Plus Jakarta Sans', sans-serif; direction: ltr; text-align: right; font-size: clamp(18px, 2vw, 22px); font-weight: 300; color: var(--deep-ink); letter-spacing: -.2px; }
.auth-art p { color: var(--deep-muted); max-width: 460px; }
.auth-form { flex: 1 1 420px; background: var(--bg); display: flex; align-items: center; justify-content: center; padding: clamp(24px, 5vw, 64px) 20px; border-radius: 0 32px 32px 0; }
.auth-box { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 20px; }
@media (max-width: 860px) { .auth-form { border-radius: 32px 32px 0 0; margin-top: -32px; position: relative; z-index: 2; } .auth-art { min-height: 300px; padding-bottom: 56px; } .auth-art .deco { width: 420px; height: 420px; right: -140px; } }
.otp-input { letter-spacing: 10px; text-align: center; font-size: 26px; font-weight: 800; direction: ltr; }





/* ===== No sideways scrolling on phones ===== */
.seg { flex-wrap: wrap; overflow: visible; }
.people { display: flex; flex-wrap: wrap; gap: 8px; }
.person { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 4px 6px 4px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-size: 14px; font-weight: 600; }
.person:hover { border-color: var(--accent); color: var(--ink); }
.person.on { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent) inset; }
.person .pc { min-width: 24px; height: 24px; border-radius: 999px; display: grid; place-items: center; font-size: 12px; background: var(--nude); color: var(--ink-2); padding: 0 6px; }
.person.on .pc { background: var(--accent); color: #fff; }
.multi-agenda { display: none; }
@media (max-width: 639px) {
  .multi-grid { display: none; }
  .multi-agenda { display: block; }
  .person { padding-inline-start: 10px; }
  /* tables become stacked cards */
  .table-wrap { overflow: visible; margin: 0; padding: 0; }
  table.table { min-width: 0; }
  .table thead { display: none; }
  .table tr { display: block; padding: 10px 0; border-bottom: 1px solid var(--line-soft); }
  .table tr:last-child { border-bottom: 0; }
  .table td { display: flex; justify-content: space-between; gap: 12px; padding: 4px 2px; border: 0; text-align: left; }
  .table td::before { content: attr(data-label); color: var(--muted); font-size: 12.5px; font-weight: 600; text-align: right; }
  .table td.n { font-weight: 700; }
}

/* ===== Photo gallery ===== */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 112px), 1fr)); gap: 10px; }
.ph { position: relative; display: block; aspect-ratio: 1 / 1; border-radius: 16px; overflow: hidden; border: 1px solid var(--line-soft); background: var(--nude-2); padding: 0; cursor: zoom-in; }
.ph img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease; }
.ph:hover img { transform: scale(1.05); }
.ph-tag { position: absolute; bottom: 8px; inset-inline-start: 8px; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: rgba(10,10,15,.72); color: #fff; backdrop-filter: blur(6px); }
.ph-tag.ph-after { background: rgba(123,97,255,.88); }
.drop { position: relative; display: block; border: 1.5px dashed var(--line); border-radius: 20px; background: var(--surface-2); cursor: pointer; overflow: hidden; }
.drop:hover, .drop:focus-within { border-color: var(--accent); }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop-preview { min-height: 170px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--muted); font-size: 14px; text-align: center; padding: 16px; }
.drop-preview svg { color: var(--accent-2); }
.drop-preview img { max-height: 260px; width: auto; max-width: 100%; border-radius: 14px; }
.consent { align-items: flex-start; line-height: 1.8; }
.consent input { margin-top: 4px; flex: 0 0 auto; }
dialog.lightbox { width: min(760px, calc(100vw - 32px)); }
@media (max-width: 639px) { dialog.lightbox { width: 100vw; max-width: 100vw; } }
.lightbox img { width: 100%; max-height: 70vh; object-fit: contain; border-radius: 16px; background: #000; display: block; }

/* ===== Logo motion ===== */
.q-float, .q-tail, .m-tail, .m-i { transform-box: fill-box; transform-origin: center; }
.q-float { animation: qFloat 7s ease-in-out infinite; }
.q-glint { transform-origin: 190px 175px; animation: qOrbit 9s linear infinite; }
@keyframes qFloat { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-7px) rotate(-1.5deg); } }
@keyframes qOrbit { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
/* small mark: ambient motion */
.m-glint { transform-origin: 72px 52px; animation: qOrbit 6s linear infinite; }
.m-dot { transform-box: fill-box; transform-origin: center; animation: mDot 3.6s ease-in-out infinite; }
@keyframes mDot { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.14); } }
.iq-mark { filter: drop-shadow(0 4px 10px rgba(123,97,255,.35)); }
/* intro: plays once per session (intro.js sets .q-intro on <html>) */
.q-intro .q-ring { stroke-dasharray: 100 100; animation: qDraw 1.5s cubic-bezier(.65,0,.25,1) .15s both; }
.q-intro .q-fade, .q-intro .q-glint { animation: qFadeIn .8s ease 1.3s both; }
.q-intro .q-glint { animation: qFadeIn .8s ease 1.6s both, qOrbit 9s linear 1.6s infinite; }
.q-intro .q-tail { animation: qTail .9s cubic-bezier(.34,1.56,.64,1) 1.05s both; }
@keyframes qDraw { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@keyframes qFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes qTail { from { opacity: 0; transform: translate(-34px, -38px) scale(.55); } to { opacity: 1; transform: none; } }
.q-intro .m-ring { stroke-dasharray: 100 100; animation: qDraw 1.1s cubic-bezier(.65,0,.25,1) .1s both; }
.q-intro .m-tail { animation: qTail .7s cubic-bezier(.34,1.56,.64,1) .85s both; }
.q-intro .m-i { animation: mI .6s cubic-bezier(.34,1.56,.64,1) .05s both; }
@keyframes mI { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
/* hover: the small mark's ring catches the light */
.logo svg { transition: filter .3s ease, transform .3s ease; }
a:hover .logo svg, .brand:hover svg { filter: drop-shadow(0 0 12px rgba(155,135,255,.75)) brightness(1.12); transform: rotate(-6deg) scale(1.04); }
@media (prefers-reduced-motion: reduce) {
  .logo .word, .m-glint, .m-dot, .q-float, .q-glint, .q-intro .q-ring, .q-intro .q-fade, .q-intro .q-glint, .q-intro .q-tail, .q-intro .m-ring, .q-intro .m-tail, .q-intro .m-i { animation: none !important; stroke-dasharray: none; }
}


/* ===== Welcome & sign-in (start of the app) ===== */
.wl { position: relative; min-height: 100vh; min-height: 100dvh; background: #07070B; color: #F8F8FA; overflow: hidden; display: flex; justify-content: center; }
.wl-bokeh { position: absolute; inset: 0; pointer-events: none; }
.wl-bokeh::before { content: ''; position: absolute; inset: 0; background:
  radial-gradient(60% 45% at 50% 38%, rgba(123,97,255,.20), transparent 70%),
  radial-gradient(40% 30% at 50% 100%, rgba(91,63,230,.25), transparent 70%); }
.wl-bokeh i { position: absolute; border-radius: 50%; filter: blur(28px); opacity: .55; animation: wlDrift 14s ease-in-out infinite alternate; }
.wl-bokeh i:nth-child(1) { width: 140px; height: 140px; left: 6%; top: 34%; background: #F2A07A; opacity: .28; }
.wl-bokeh i:nth-child(2) { width: 90px; height: 90px; left: 12%; top: 58%; background: #F5B98E; opacity: .22; animation-delay: -4s; }
.wl-bokeh i:nth-child(3) { width: 260px; height: 520px; right: 4%; top: -6%; background: #8C5CFF; opacity: .30; border-radius: 40%; }
.wl-bokeh i:nth-child(4) { width: 120px; height: 120px; right: 10%; top: 40%; background: #F0A07E; opacity: .20; animation-delay: -7s; }
.wl-bokeh i:nth-child(5) { width: 200px; height: 360px; left: 2%; top: -10%; background: #6A44E8; opacity: .28; border-radius: 40%; animation-delay: -2s; }
.wl-bokeh i:nth-child(6) { width: 70%; height: 140px; left: 15%; bottom: -60px; background: #5B3FE6; opacity: .30; animation-delay: -9s; }
@keyframes wlDrift { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(14px,-18px,0) scale(1.08); } }
.wl-col { position: relative; z-index: 1; width: 100%; max-width: 460px; min-height: 100vh; min-height: 100dvh; justify-content: center; padding: max(28px, env(safe-area-inset-top)) 22px max(28px, env(safe-area-inset-bottom)); display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.wl-brand { display: flex; justify-content: center; }
.wl-back { position: absolute; top: max(18px, env(safe-area-inset-top)); right: 18px; width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; color: #F8F8FA; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); z-index: 2; animation: none !important; }
.wl-back:hover { background: rgba(255,255,255,.12); color: #fff; }
.wl-brand .logo { align-self: center; }
.wl-brand .logo .word { font-weight: 600; }
.wl-tag { font-family: 'Plus Jakarta Sans', sans-serif; direction: ltr; font-weight: 300; font-size: clamp(22px, 5.6vw, 28px); line-height: 1.25; letter-spacing: .01em; color: #E9E6F5; margin: 4px 0 0; }
.wl-hero { position: relative; margin: 6px 0 0; width: 100%; aspect-ratio: 572 / 494; max-width: 100%; }
.wl-arc { position: absolute; z-index: 0; width: 125%; height: auto; left: -32%; top: -22%; opacity: .95; overflow: visible; filter: drop-shadow(0 20px 40px rgba(91,63,230,.45)); }
.wl-fa { font-size: 15px; color: #B9B6C9; margin: -6px 0 6px; }
.wl-fa b { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.wl-actions { width: 100%; display: flex; flex-direction: column; gap: 14px; margin-top: 4px; }
.wl-btn { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 58px; border-radius: 999px; font-size: 17px; font-weight: 700; text-decoration: none; cursor: pointer; border: 1.5px solid transparent; font-family: inherit; transition: transform .1s ease, filter .2s ease, background .2s ease; }
.wl-btn:active { transform: scale(.98); }
.wl-primary { background: linear-gradient(135deg, #8E78FF 0%, #6B4EFF 55%, #5B3FE6 100%); color: #fff; box-shadow: 0 14px 34px rgba(91,63,230,.45), inset 0 1px 0 rgba(255,255,255,.25); }
.wl-primary:hover { filter: brightness(1.08); color: #fff; }
.wl-ghost { background: rgba(255,255,255,.02); color: #F8F8FA; border-color: rgba(255,255,255,.55); }
.wl-ghost:hover { background: rgba(255,255,255,.07); color: #fff; }
.wl-fine { font-size: 12px; color: #7E7B90; margin-top: 4px; }
.wl-h { font-size: 22px; font-weight: 800; color: #F8F8FA; }
.wl-card { width: 100%; margin-top: 18px; text-align: right; display: flex; flex-direction: column; gap: 18px; padding: 24px 22px; border-radius: 28px;
  background: linear-gradient(180deg, rgba(30,28,44,.78), rgba(18,17,27,.82)); border: 1px solid rgba(255,255,255,.08); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 30px 80px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.06); }
.wl-card .muted { color: #A9A6BA; }
.wl-card .input { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); color: #F8F8FA; min-height: 56px; border-radius: 16px; }
.wl-card .input:focus { border-color: #8E78FF; box-shadow: 0 0 0 4px rgba(123,97,255,.25); }
.wl-card .field > label, .wl-card .lbl { color: #D3D0E2; }
.wl-card .choice span { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); color: #F8F8FA; }
.wl-card .choice input:checked + span { background: rgba(123,97,255,.25); border-color: #8E78FF; box-shadow: 0 0 0 1px #8E78FF inset; }
.wl-card a { color: #B9ADFF; }
.wl-card a.wl-primary { color: #fff; }
.wl-auth .wl-tag { font-size: 18px; color: #A9A6BA; }
/* entrance */
.wl-col > * { animation: wlUp .8s cubic-bezier(.2,.8,.2,1) both; }
.wl-col > *:nth-child(2) { animation-delay: .12s; } .wl-col > *:nth-child(3) { animation-delay: .24s; }
.wl-col > *:nth-child(4) { animation-delay: .36s; } .wl-col > *:nth-child(5) { animation-delay: .48s; }
@keyframes wlUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@media (min-width: 900px) {
  .wl-col { max-width: 520px; padding-top: 40px; }
  .wl-hero { max-width: 470px; }
}
@media (prefers-reduced-motion: reduce) { .wl-col > *, .wl-bokeh i { animation: none !important; } }

/* ===== Brand photo: rises into view inside a ring that draws itself ===== */
.ppl { position: relative; display: block; margin: 0; width: 100%; aspect-ratio: 572 / 494; isolation: isolate; pointer-events: none; animation: pplFloat 9s ease-in-out 1.8s infinite; }
.ppl-photo { position: absolute; inset: 0; z-index: 2; overflow: hidden; animation: pplRise 1.3s cubic-bezier(.16,1,.3,1) .1s both;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 64%, transparent 97%), linear-gradient(to right, transparent 0, #000 14%, #000 92%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 64%, transparent 97%), linear-gradient(to right, transparent 0, #000 14%, #000 92%, transparent 100%);
  mask-composite: intersect; }
.ppl-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ppl-shine { position: absolute; inset: -10% 0; background: linear-gradient(105deg, transparent 38%, rgba(214,204,255,.28) 50%, transparent 62%); mix-blend-mode: screen; transform: translateX(130%); animation: pplShine 8s ease-in-out 1.5s infinite; }
.ppl-glow { position: absolute; inset: 6% 8% 14%; z-index: 0; border-radius: 50%; background: radial-gradient(circle, rgba(123,97,255,.55), rgba(91,63,230,.18) 45%, transparent 70%); filter: blur(30px); animation: pplGlow 6s ease-in-out infinite alternate; }
.ppl-ring { position: absolute; z-index: 1; width: 112%; left: -6%; top: -16%; overflow: visible; filter: drop-shadow(0 0 16px rgba(123,97,255,.6)); animation: pplSpin 48s linear 2.2s infinite; }
.ppl-arc { stroke-dasharray: 0 100; opacity: 0; animation: pplDraw 1.9s cubic-bezier(.65,0,.35,1) .3s forwards; }
.ppl-dot { opacity: 0; animation: pplIn .5s ease 2s forwards; filter: drop-shadow(0 0 6px #B9ADFF); }
.ppl-spark { position: absolute; z-index: 3; width: 5px; height: 5px; border-radius: 50%; background: #E3DCFF; box-shadow: 0 0 10px 2px rgba(185,173,255,.8); opacity: 0; animation: pplSpark 6s ease-in infinite; }
.ppl-spark:nth-of-type(1) { left: 14%; bottom: 22%; animation-delay: 1.6s; }
.ppl-spark:nth-of-type(2) { right: 12%; bottom: 34%; animation-delay: 3.4s; width: 4px; height: 4px; }
.ppl-spark:nth-of-type(3) { left: 52%; bottom: 12%; animation-delay: 5s; }
@keyframes pplRise { 0% { opacity: 0; transform: translateY(72px) scale(.93); filter: blur(12px) brightness(.6); } 55% { filter: blur(0) brightness(1.08); } 100% { opacity: 1; transform: none; filter: none; } }
@keyframes pplDraw { 0% { opacity: 0; stroke-dasharray: 0 100; } 8% { opacity: 1; } 100% { opacity: 1; stroke-dasharray: 62 100; } }
@keyframes pplIn { to { opacity: 1; } }
@keyframes pplSpin { to { transform: rotate(360deg); } }
@keyframes pplFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes pplGlow { from { opacity: .75; transform: scale(.96); } to { opacity: 1; transform: scale(1.05); } }
@keyframes pplShine { 0% { transform: translateX(130%); } 28%, 100% { transform: translateX(-130%); } }
@keyframes pplSpark { 0% { opacity: 0; transform: translateY(0) scale(.6); } 15% { opacity: 1; } 70% { opacity: .8; } 100% { opacity: 0; transform: translateY(-90px) scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .ppl, .ppl-photo, .ppl-shine, .ppl-glow, .ppl-ring, .ppl-arc, .ppl-dot, .ppl-spark { animation: none !important; }
  .ppl-arc { stroke-dasharray: 62 100; opacity: 1; } .ppl-dot { opacity: 1; } .ppl-shine, .ppl-spark { display: none; }
}
/* Start screen and login */
.wl-hero.ppl { max-width: 380px; margin: 44px auto 0; }
.ppl-auth { max-width: 280px; margin: 34px auto -54px; z-index: 0; }
.wl-auth .wl-card { position: relative; z-index: 1; }
@media (max-height: 720px) { .ppl-auth { display: none; } }
/* Today page hero: the photo in dark mode, the Q ribbon in light mode */
.hero-ppl { display: none; }
:root[data-theme="dark"] .has-ppl .hero-ppl { display: block; }
:root[data-theme="dark"] .has-ppl .deco, :root[data-theme="dark"] .has-ppl .glow { display: none; }
@media (min-width: 900px) {
  :root[data-theme="dark"] .has-ppl { padding-inline-end: 330px; min-height: 270px; }
  .hero-ppl { position: absolute; left: 20px; bottom: 0; width: 270px; z-index: 0; }
}
@media (max-width: 899px) {
  .hero-ppl { width: 100%; max-width: 300px; margin: -8px auto -26px; align-self: center; }
}

/* Print */
@media print {
  :root { --bg: #fff; --surface: #fff; --ink: #000; --ink-2: #222; --muted: #555; --line: #ddd; --line-soft: #eee; }
  .side, .tabbar, .topbar .actions, .no-print, .mtop { display: none !important; }
  body { background: #fff; color: #000; }
  .main { padding: 0; }
  .card { box-shadow: none; border: 1px solid #ddd; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
