/*
 * core/assets/app.css — the Sobirax look, shared by every app. Change colours and sizes HERE, not page by page.
 * A page's own extra styles go in a <style> block scoped under the page's id (#auPage .something { ... }).
 * Font: Inter (SIL Open Font Licence), kept on our server in core/assets/fonts/.
 */
@font-face { font-family: 'Inter'; src: url('fonts/inter.woff2') format('woff2'); font-weight: 100 900; font-style: normal; font-display: swap; }

:root {
  /* brand */
  --green: #0b996f; --green-dark: #006a43; --green-deep: #004227;
  --mint-50: #f6fdf2; --mint: #e8fedf; --mint-2: #d8fbc8; --mint-3: #c0ffa5;
  --cream: #fffdf6; --cream-2: #fbf6e6;
  --accent: #6358de; --accent-bg: #eeedfc; --accent-dark: #4b41c2;
  /* text, lines, surfaces */
  --ink: #1b1b1b; --ink-2: #2c2c2c; --muted: #696969; --line: #e6e6e6; --line-2: #d4d4d4;
  --bg: #f7f7f4; --card: #ffffff; --page: #ffffff;
  /* text on the dark main button and on toasts; shadows; the loading shimmer; small one-off fills */
  --on-ink: #ffffff; --ink-hover: #000000; --shadow: rgba(27,27,27,.14); --shadow-2: rgba(27,27,27,.25); --scrim: rgba(27,27,27,.35);
  --skel-a: #efefeb; --skel-b: #f8f8f5; --cream-line: #f1ead2; --pill-soon: #f0f0ed; --bad-ink: #8c2a16; --nav-glass: rgba(255,255,255,.94);
  --focus: rgba(11,153,111,.16); --foot-bg: var(--green-deep);
  /* states */
  --bad: #b3261e; --bad-bg: #fdf0ec; --ok-bg: var(--mint); --warn-bg: #fff3d6; --warn: #7a5200;
  /* sizes */
  --radius: 16px; --field: 46px; --side: 248px; --rail: 76px; --panel: 272px;
  /* older names, kept so existing pages still work */
  --navy: var(--ink); --navy-2: var(--green-deep); --teal: var(--green); --teal-dark: var(--green-dark);
}
/* Always light, whatever the appearance: pictures drawn for a light page (the log-in pictures) and the memo. The light
   colours again, on that box only. */
.stay-light {
  color-scheme: light; color: var(--ink);
  --green: #0b996f; --green-dark: #006a43; --green-deep: #004227;
  --mint-50: #f6fdf2; --mint: #e8fedf; --mint-2: #d8fbc8; --mint-3: #c0ffa5;
  --cream: #fffdf6; --cream-2: #fbf6e6;
  --accent: #6358de; --accent-bg: #eeedfc; --accent-dark: #4b41c2;
  --ink: #1b1b1b; --ink-2: #2c2c2c; --muted: #696969; --line: #e6e6e6; --line-2: #d4d4d4;
  --bg: #f7f7f4; --card: #ffffff; --page: #ffffff;
  --on-ink: #ffffff; --ink-hover: #000000; --shadow: rgba(27,27,27,.14); --shadow-2: rgba(27,27,27,.25); --scrim: rgba(27,27,27,.35);
  --skel-a: #efefeb; --skel-b: #f8f8f5; --cream-line: #f1ead2; --pill-soon: #f0f0ed; --bad-ink: #8c2a16; --nav-glass: rgba(255,255,255,.94);
  --focus: rgba(11,153,111,.16); --foot-bg: #004227;
  --bad: #b3261e; --bad-bg: #fdf0ec; --ok-bg: #e8fedf; --warn-bg: #fff3d6; --warn: #7a5200;
}
/* Dark: chosen (html.theme-dark), or the device's choice when following it (html.theme-auto, the default). Printed pages
   (the memo) are always light: the dark colours are for the screen only. */
@media screen {
html.theme-dark {
  color-scheme: dark;
  --green: #3cc796; --green-dark: #93e6c1; --green-deep: #c4f2dc;
  --mint-50: #10221a; --mint: #173527; --mint-2: #1d4231; --mint-3: #2b5f45;
  --cream: #142319; --cream-2: #1a2d22;
  --accent: #a9a2ff; --accent-bg: #28254b; --accent-dark: #cdc8ff;
  --ink: #f3eee0; --ink-2: #e5dfcc; --muted: #a8b4ac; --line: #25392e; --line-2: #34493d;
  --bg: #0a140f; --card: #111f18; --page: #0d1913;
  --bad: #ff9389; --bad-bg: #3a1b18; --ok-bg: var(--mint); --warn-bg: #382e12; --warn: #f2cf6c;
  --on-ink: #10201a; --ink-hover: #ffffff; --shadow: rgba(0,0,0,.5); --shadow-2: rgba(0,0,0,.6); --scrim: rgba(0,0,0,.6);
  --skel-a: #182a20; --skel-b: #213629; --cream-line: #26392d; --pill-soon: #1d2e25; --bad-ink: #ffb3aa; --nav-glass: rgba(13,25,19,.94);
  --focus: rgba(60,199,150,.28); --foot-bg: #072417;
}
}
@media screen and (prefers-color-scheme: dark) {
  html.theme-auto {
    color-scheme: dark;
    --green: #3cc796; --green-dark: #93e6c1; --green-deep: #c4f2dc;
    --mint-50: #10221a; --mint: #173527; --mint-2: #1d4231; --mint-3: #2b5f45;
    --cream: #142319; --cream-2: #1a2d22;
    --accent: #a9a2ff; --accent-bg: #28254b; --accent-dark: #cdc8ff;
    --ink: #f3eee0; --ink-2: #e5dfcc; --muted: #a8b4ac; --line: #25392e; --line-2: #34493d;
    --bg: #0a140f; --card: #111f18; --page: #0d1913;
    --bad: #ff9389; --bad-bg: #3a1b18; --ok-bg: var(--mint); --warn-bg: #382e12; --warn: #f2cf6c;
    --on-ink: #10201a; --ink-hover: #ffffff; --shadow: rgba(0,0,0,.5); --shadow-2: rgba(0,0,0,.6); --scrim: rgba(0,0,0,.6);
    --skel-a: #182a20; --skel-b: #213629; --cream-line: #26392d; --pill-soon: #1d2e25; --bad-ink: #ffb3aa; --nav-glass: rgba(13,25,19,.94);
    --focus: rgba(60,199,150,.28); --foot-bg: #072417;
  }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--page); color: var(--ink); font: 15px/1.55 Inter, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif; }
h1, h2, h3 { margin: 0; line-height: 1.2; color: var(--ink); font-weight: 600; letter-spacing: -.02em; }
h1 { font-size: 1.85rem; } h2 { font-size: 1.25rem; } h3 { font-size: 1.05rem; }
p { margin: 0; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.ic { width: 22px; height: 22px; flex: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* logo: green badge with a white diamond, then the word */
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.3rem; letter-spacing: -.03em; color: var(--green-dark); text-decoration: none !important; white-space: nowrap; }
.logo.light { color: #fff; }
.logo-mark { width: 34px; height: 34px; border-radius: 50%; background: var(--green); position: relative; flex: none; }
.logo-mark::after { content: ''; position: absolute; inset: 11px; border-radius: 3px; background: #fff; transform: rotate(45deg); }
.logo.light .logo-mark { background: var(--mint-3); }
.logo.light .logo-mark::after { background: var(--green-deep); }

/* ================= app frame: sidebar · second sidebar · top bar ================= */
.shell { display: flex; min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; width: var(--side); flex: none; display: flex; flex-direction: column; z-index: 40;
        background: var(--mint-50); border-right: 1px solid var(--mint-2); border-bottom-right-radius: 28px; padding: 14px 12px;
        transition: width .22s ease, padding .22s ease; overflow: hidden; }
.side-top { display: flex; align-items: center; gap: 8px; height: 52px; padding: 0 6px 0 8px; margin-bottom: 14px; }
.side-top .logo { flex: 1; min-width: 0; }
.side-btn { border: 0; background: none; color: var(--ink); width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; cursor: pointer; flex: none; }
.side-btn:hover { background: var(--mint); }
.side-close { display: none; }
.side-nav { display: flex; flex-direction: column; gap: 4px; flex: 1; overflow-y: auto; overflow-x: hidden; }
.side-item.bottom { margin-top: auto; }
.side-link { position: relative; display: flex; align-items: center; gap: 14px; min-height: 50px; padding: 0 14px; border-radius: 14px;
             color: var(--ink); font-size: 1rem; text-decoration: none !important; white-space: nowrap; }
.side-link:hover { background: var(--mint); }
.side-link.active { background: var(--mint-2); font-weight: 600; }
.side-label { overflow: hidden; text-overflow: ellipsis; }
.side-badge { margin-left: auto; flex: none; padding: 1px 8px; }   /* "3 new" on a sidebar entry */
body.rail .side-badge { position: absolute; top: 4px; right: 2px; margin: 0; padding: 0 5px; font-size: .66rem; }
.side-chev { display: none; width: 18px; height: 18px; margin-left: auto; transition: transform .2s; }
.side-sub { display: none; }

/* rail: the sidebar shrunk to icons. Labels become small tips on hover. */
body.rail .side { width: var(--rail); padding: 14px 10px; overflow: visible; }
body.rail .side-top { flex-direction: column; height: auto; gap: 10px; padding: 0; }
body.rail .side-top .logo { flex: none; }
body.rail .side .logo-word { display: none; }
body.rail.has-panel .side-toggle { display: none; }
body.rail .side-nav { overflow: visible; }
body.rail .side-link { justify-content: center; padding: 0; }
body.rail .side-label { position: absolute; left: calc(100% + 10px); top: 50%; transform: translateY(-50%); background: var(--ink); color: var(--on-ink);
  font-size: .82rem; font-weight: 600; padding: 5px 10px; border-radius: 8px; pointer-events: none; opacity: 0; transition: opacity .12s; z-index: 60; }
body.rail .side-link:hover .side-label, body.rail .side-link:focus-visible .side-label { opacity: 1; }

/* second sidebar: the sub-pages of the open section */
.panel { display: none; position: sticky; top: 0; height: 100vh; width: var(--panel); flex: none; background: var(--card); overflow-y: auto;
         border-right: 1px solid var(--line); border-top-right-radius: 36px; padding: 26px 18px 24px 22px; z-index: 30; }
body.has-panel .panel { display: block; }
body.panel-anim .panel { animation: panelIn .45s cubic-bezier(.34, 1.36, .64, 1) both; }
@keyframes panelIn { from { transform: translateX(-36px); opacity: 0; } to { transform: none; opacity: 1; } }
.panel-title { font-size: 1.15rem; margin: 6px 0 22px; }
.sub-group { font-size: .82rem; color: var(--muted); margin: 18px 0 8px; }
.sub-group:first-child { margin-top: 0; }
.sub-link { display: block; padding: 9px 12px; margin: 2px 0; border-radius: 10px; color: var(--ink); font-size: .98rem; text-decoration: none !important; }
.sub-link:hover { background: var(--bg); }
.sub-link.active { background: var(--accent-bg); color: var(--accent); font-weight: 600; }

/* the page column: top bar + page. The top bar stays at the top while the page scrolls, on every size
   (under the phone menu, drawers and messages). */
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 14px; min-height: 76px; padding: 0 36px;
       position: sticky; top: 0; z-index: 2400; background: var(--card); border-bottom: 1px solid var(--line); }
.top-space { flex: 1; }
/* #headerSlot: the empty left part of the top bar, where a page may put its own bar on wide screens (headerSlot()) */
.top-slot { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px 16px; }
.top-slot:empty { display: none; }
.top-slot:not(:empty) ~ .top-space { display: none; }
/* the page's heading, in the top bar once it has scrolled up under it (app.js) */
.ph-sticky { display: flex; align-items: center; gap: 14px; min-width: 0; animation: phIn .18s ease-out both; }
.ph-sticky b { font-size: 1.05rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ph-sticky .btn { flex: none; }
@keyframes phIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
/* a thin progress bar along the very top edge of the top bar:  <div class="top-progress"><i style="width:40%"></i></div> */
.top-progress { position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--mint); overflow: hidden; }
.top-progress i { display: block; height: 100%; width: 0; background: var(--green); transition: width .5s ease-in-out; }
.top-btn { border: 0; background: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; cursor: pointer; color: var(--ink); }
.top-btn:hover { background: var(--bg); }
.top-bell { position: relative; flex: none; color: var(--ink); }
.top-badge { position: absolute; top: 4px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent); color: var(--on-ink);
  font-size: .7rem; font-weight: 700; line-height: 18px; text-align: center; }
.top-menu, .top-logo { display: none !important; }
.who { position: relative; flex: none; }   /* the account menu never leaves the screen, whatever the language */
.top .top-trial { display: block; flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.who-btn { display: flex; align-items: center; gap: 10px; border: 0; background: none; font: inherit; font-size: 1rem; font-weight: 500; color: var(--ink);
           min-height: 44px; padding: 0 10px; border-radius: 12px; cursor: pointer; max-width: 300px; }
.who-btn:hover { background: var(--bg); }
.who-company { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.who-chev { width: 18px; height: 18px; }
.who-menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 2600; width: 290px; background: var(--card); border: 1px solid var(--line);
            border-radius: 16px; box-shadow: 0 16px 40px var(--shadow); padding: 8px; }
.who-head { display: grid; gap: 2px; padding: 10px 12px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.who-head span { color: var(--muted); font-size: .88rem; overflow: hidden; text-overflow: ellipsis; }
.who-head .pill { justify-self: start; margin-top: 6px; color: var(--ink); max-width: 100%; white-space: normal; text-align: left; height: auto; line-height: 1.35; padding-top: 4px; padding-bottom: 4px; }
.who-menu a, .who-menu button { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 0 12px; border: 0; background: none;
            border-radius: 10px; color: var(--ink); font: inherit; text-align: left; cursor: pointer; text-decoration: none !important; }
.who-menu a:hover, .who-menu button:hover { background: var(--bg); }
.who-menu .ic { width: 20px; height: 20px; color: var(--muted); }
.who-menu form { margin: 0; }
.who-menu .who-val { margin-left: auto; color: var(--muted); font-size: .88rem; }
.who-menu .who-lang { min-height: 52px; background: var(--mint); color: var(--ink); font-size: .88rem; text-align: left; line-height: 1.35; padding: 6px 12px; }
.who-menu .who-lang b { color: var(--green-dark); }
.who-menu .who-lang .ic { color: var(--green-dark); }
/* Language: the banner after a change, the drawer's list, the footer link (core/header.php, app.js langDrawer) */
.lang-banner { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; padding: 8px 16px; background: var(--mint); color: var(--ink); font-size: .92rem; }
.lang-banner[hidden] { display: none; }
.lang-banner > .ic { width: 18px; height: 18px; color: var(--green-dark); flex: none; }
.lang-banner .linkbtn { min-height: 36px; font-weight: 600; }
.lang-banner .lang-x { margin-left: auto; display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 50%; background: none; color: var(--muted); cursor: pointer; }
.lang-banner .lang-x:hover { background: var(--card); }
.lang-banner .lang-x .ic { width: 18px; height: 18px; }
.lang-list { display: grid; gap: 10px; }
.lang-pick { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 56px; padding: 0 18px; border: 1.5px solid var(--line-2);
  border-radius: 14px; background: var(--card); color: var(--ink); font: inherit; font-size: 1.05rem; cursor: pointer; text-align: start; }
.lang-pick[aria-pressed="true"] { border-color: var(--green); background: var(--mint); font-weight: 600; }
.lang-pick .ic { width: 20px; height: 20px; color: var(--green-dark); }
.lang-go { margin-top: 20px; }
.lang-go .btn { width: 100%; height: auto; min-height: 48px; padding: 10px 18px; white-space: normal; line-height: 1.35; }
.theme-seg { width: 100%; }
.theme-seg button { flex: 1; min-height: 44px; }
.theme-note { margin-top: 14px; font-size: .92rem; }
.foot-lang, .auth-lang { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; text-decoration: none; }
.foot-lang { margin-left: 18px; color: inherit; }
.foot-lang .ic, .auth-lang .ic { width: 18px; height: 18px; }
.auth-lang { margin-top: 24px; color: var(--muted); font-size: .9rem; }
.auth-lang:hover, .foot-lang:hover { text-decoration: underline; }
.subnav-phone { display: none; }
.side-back { display: none; }

/* page area */
.wrap { width: 100%; max-width: 1240px; padding: 12px 36px 56px; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.page-head h1 { font-size: 2.2rem; letter-spacing: -.03em; }
.page-head p { color: var(--muted); margin-top: 6px; }

/* buttons: one dark filled button for the main action, ghost for the rest */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border: 0; border-radius: 999px;
       background: linear-gradient(180deg, var(--ink-2), var(--ink)); color: var(--on-ink); font: inherit; font-weight: 600; cursor: pointer;
       text-decoration: none !important; white-space: nowrap; transition: background .15s, transform .15s; }
.btn:hover { background: var(--ink-hover); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.wide { width: 100%; }
.btn.small { min-height: 40px; padding: 0 18px; font-size: .92rem; }
.btn.ghost { background: var(--card); color: var(--ink); border: 1.5px solid var(--line-2); }
.btn.ghost:hover { border-color: var(--ink); background: var(--card); }
.btn.ghost:disabled:hover { border-color: var(--line-2); }
.btn.green { background: var(--green-dark); }
.btn.green:hover { background: var(--green-deep); }
.btn .ic { width: 18px; height: 18px; }
/* a button waiting for its answer (busy() in app.js): a small spinner in place of its icon, its words kept */
.spin { display: inline-block; width: 16px; height: 16px; flex: none; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent;
        animation: spin .7s linear infinite; vertical-align: -3px; }
.btn.busy { cursor: progress; }
.btn.busy:disabled { opacity: .8; }
.btn.busy > .ic { display: none; }
.linkbtn.busy .spin { width: 13px; height: 13px; margin-right: 6px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation-duration: 1.6s; } }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; font-weight: 600; color: var(--accent); cursor: pointer; }
.linkbtn:hover { text-decoration: underline; }

/* form fields */
.field { margin-bottom: 16px; }
.field label { display: block; font-size: .86rem; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.field input, .field select, .field textarea { width: 100%; height: var(--field); border: 1.5px solid var(--line-2); border-radius: 10px; padding: 0 14px;
       font: inherit; font-size: 16px; color: var(--ink); background: var(--card); transition: border-color .15s, box-shadow .15s; }
.field textarea { height: auto; padding: 10px 14px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 0; border-color: var(--green); box-shadow: 0 0 0 3px var(--focus); }
.field input[readonly] { background: var(--bg); color: var(--muted); }
.field .hint { font-size: .8rem; color: var(--muted); margin-top: 4px; }
.err { font-size: .82rem; color: var(--bad); margin-top: 4px; }
.err:empty { display: none; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.pw { position: relative; }
.pw input { padding-right: 68px; }
.pw button { position: absolute; right: 4px; top: 4px; height: calc(var(--field) - 8px); min-width: 58px; border: 0; background: none; color: var(--accent); font: inherit; font-size: .84rem; font-weight: 600; cursor: pointer; }

/* on / off switch:  <label class="switch"><input type="checkbox"><span></span>Follow-up reminders</label> */
.switch { position: relative; display: inline-flex; align-items: center; gap: 12px; min-height: 44px; cursor: pointer; font-weight: 500; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch input + span { width: 44px; height: 26px; flex: none; border-radius: 999px; background: var(--line-2); position: relative; transition: background .15s; }
.switch input + span::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff;
                      box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .15s; }
.switch input:checked + span { background: var(--green); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { box-shadow: 0 0 0 3px rgba(11,153,111,.3); }
.switch input:disabled + span { opacity: .5; }
/* a choice of a few options in one row:  <div class="seg"><button aria-pressed="true">Required</button>...</div> */
.seg { display: inline-flex; border: 1.5px solid var(--line-2); border-radius: 999px; padding: 2px; gap: 2px; background: var(--card); }
.seg button { min-height: 36px; padding: 0 14px; border: 0; border-radius: 999px; background: none; font: inherit; font-size: .88rem; color: var(--muted); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--on-ink); font-weight: 600; }
.seg button:disabled { opacity: .4; cursor: default; }
/* choose several: <div class="chips"><button type="button" class="chip" aria-pressed="true"><svg class="ic">✓</svg>Phone</button></div> */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1.5px solid var(--line-2);
        background: var(--card); color: var(--ink); font: inherit; font-size: .9rem; cursor: pointer; }
.chip .ic { width: 15px; height: 15px; display: none; }
.chip[aria-pressed="true"] { background: var(--mint); border-color: var(--green); color: var(--green-dark); font-weight: 600; }
.chip[aria-pressed="true"] .ic { display: block; }
.chip:disabled { opacity: .5; cursor: default; }
/* the form engine (renderForm in app.js) */
.ff-opt { color: var(--muted); font-weight: 400; }
.ff-money { display: flex; align-items: stretch; }
.ff-money span { display: grid; place-items: center; padding: 0 14px; border: 1.5px solid var(--line-2); border-right: 0; border-radius: 10px 0 0 10px;
                 background: var(--bg); color: var(--muted); font-weight: 600; font-size: .9rem; }
.ff-money input { border-top-left-radius: 0 !important; border-bottom-left-radius: 0 !important; min-width: 0; }
.ff-acts { display: flex; align-items: center; gap: 8px 14px; flex-wrap: wrap; }
.ff-acts .linkbtn { min-height: 44px; }
.ff-status { color: var(--muted); font-size: .86rem; }
.ff-status.bad { color: var(--bad); }
.ff-photo .thumb { margin-bottom: 8px; }
.ff-sign .ff-thumb { display: block; border-radius: 12px; border: 1px solid var(--line); margin-bottom: 8px; }
/* Pictures: the only way to show one (pic() in app.js). The picture fills its box; a grey box with an icon when there is
   none; tapping one opens the viewer. .avatar a 72px circle (44px in table rows, or .avatar.small) · .photo a 4:3 box up
   to 240px wide · .thumb a 96px square. .file-box: a document that is not a picture (a PDF), opened in a new tab. */
.avatar, .photo, .thumb, .file-box { position: relative; display: inline-block; flex: none; overflow: hidden; vertical-align: middle; padding: 0;
  background: var(--bg); border: 1px solid var(--line); color: inherit; font: inherit; }
.avatar { width: 72px; height: 72px; border-radius: 50%; }
.avatar.small, table.list .avatar { width: 44px; height: 44px; }
.photo { width: 100%; max-width: 240px; aspect-ratio: 4 / 3; border-radius: var(--radius); }
.thumb, .file-box { width: 96px; height: 96px; border-radius: 12px; }
.avatar img, .photo img, .thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
button.avatar, button.photo, button.thumb { cursor: zoom-in; }
.avatar.empty, .photo.empty, .thumb.empty { padding: 0; }   /* a picture box, not the theme's .empty message */
.avatar.empty::before, .photo.empty::before, .thumb.empty::before, .file-box::before { content: ''; position: absolute; inset: 0; margin: auto; width: 46%; height: 46%;
  background: var(--muted); opacity: .45; -webkit-mask: var(--pic-icon) center / contain no-repeat; mask: var(--pic-icon) center / contain no-repeat; }
.avatar { --pic-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='8' r='4.2'/%3E%3Cpath d='M3.5 21.5c0-4.6 3.8-7 8.5-7s8.5 2.4 8.5 7z'/%3E%3C/svg%3E"); }
.photo, .thumb { --pic-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M4 7h3l2-3h6l2 3h3a1 1 0 0 1 1 1v11a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V8a1 1 0 0 1 1-1zM12 9.2a4 4 0 1 0 0 8a4 4 0 1 0 0-8z'/%3E%3C/svg%3E"); }
.file-box { --pic-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M6 2h8l6 6v13a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1zM13 3.5V9h5.5z'/%3E%3C/svg%3E"); text-decoration: none; }
.file-box::before { width: 34%; height: 34%; top: -18px; }
.file-box span { position: absolute; left: 0; right: 0; bottom: 10px; text-align: center; font-size: .78rem; font-weight: 700; color: var(--muted); }
.viewer { position: fixed; inset: 0; z-index: 3200; background: rgba(15,15,15,.9); display: grid; place-items: center; padding: 64px 12px 12px; }
.viewer img { max-width: 100%; max-height: calc(100vh - 80px); object-fit: contain; border-radius: 8px; background: #fff; }
.viewer button { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: #fff; color: #1b1b1b;
  font-size: 1.5rem; line-height: 1; cursor: pointer; }
.ff-pin { display: grid; gap: 8px; }
.ff-pin a { min-height: 44px; display: inline-flex; align-items: center; font-weight: 600; }
.ff-sign canvas { display: block; width: 100%; max-width: 520px; height: auto; aspect-ratio: 3 / 1; background: #fff; border: 1.5px dashed var(--line-2);
                  border-radius: 12px; touch-action: none; cursor: crosshair; }
.ff-sign .ff-thumb { max-width: 300px; background: #fff; }
.ff-photo .ff-acts { flex-wrap: wrap; }
/* the bar under a settings editor (saveBar() in app.js): stays at the bottom of the screen while editing */
.save-bar { position: sticky; bottom: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
            margin-top: 24px; padding: 14px 0; background: var(--page); border-top: 1px solid var(--line); }
.save-note { color: var(--muted); font-size: .9rem; }
.save-note.bad { color: var(--bad); font-weight: 600; }
.save-acts { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.save-undo { position: static; }   /* the menu opens from the bar's right edge, so it stays on screen on a phone */
.save-menu { position: absolute; right: 0; bottom: calc(100% + 6px); z-index: 2500; width: 270px; max-width: calc(100vw - 32px); background: var(--card); border: 1px solid var(--line);
             border-radius: 14px; box-shadow: 0 14px 34px var(--shadow); padding: 6px; display: grid; }
.save-menu button { display: grid; gap: 2px; text-align: left; min-height: 48px; padding: 8px 12px; border: 0; border-radius: 10px; background: none; font: inherit; cursor: pointer; }
.save-menu button:hover { background: var(--bg); }
.save-menu span { color: var(--muted); font-size: .82rem; }

/* cards, grids, pills */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card.cream { background: var(--cream); border-color: var(--cream-line); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.cards .card { display: flex; flex-direction: column; gap: 10px; }
.cards .card p { color: var(--muted); font-size: .93rem; flex: 1; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 12px; border-radius: 999px; font-size: .78rem; font-weight: 600; background: var(--mint); color: var(--green-dark); white-space: nowrap; }
.pill.soon { background: var(--pill-soon); color: var(--muted); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
.pill.accent { background: var(--accent-bg); color: var(--accent); }
.section { margin-top: 36px; }
.section > h2 { margin-bottom: 14px; }

/* messages */
.alert { border-radius: 14px; padding: 14px 16px; font-size: .93rem; margin-bottom: 16px; background: var(--bad-bg); color: var(--bad-ink); }
.alert.good { background: var(--mint); color: var(--green-deep); }
.alert:empty { display: none; }
.notice { max-width: 480px; margin: 56px auto; background: var(--card); border: 1px solid var(--line); border-radius: 24px; padding: 32px; text-align: center; }
.notice p { color: var(--muted); margin: 10px 0 22px; }
.toast { position: fixed; right: 16px; bottom: 16px; z-index: 3000; max-width: min(420px, calc(100vw - 32px)); background: var(--ink); color: var(--on-ink);
         padding: 13px 18px; border-radius: 14px; font-size: .92rem; box-shadow: 0 10px 30px var(--shadow-2); display: none; }
.toast.bad { background: var(--bad); }

/* tables */
.table-wrap { overflow-x: auto; }
table.list { width: 100%; border-collapse: collapse; font-size: .93rem; }
table.list th { text-align: left; font-size: .8rem; font-weight: 600; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.list td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.list tbody tr[data-id] { cursor: pointer; }
table.list tbody tr[data-id]:hover td { background: var(--mint-50); }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; font-size: .9rem; color: var(--muted); }
.search { position: relative; max-width: 360px; margin-bottom: 16px; }
.search .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); }
.search input { padding-left: 42px; }

/* tabs: related things are tabs on ONE page. Underlined, the open one in purple. */
.tabs { display: flex; align-items: center; gap: 6px; max-width: 100%; overflow: hidden; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.tabs-seg { display: inline-flex; white-space: nowrap; }
.tabs button, .tabs-menu button { border: 0; background: transparent; min-height: 48px; padding: 0 18px; font: inherit; font-size: 1rem; color: var(--ink); cursor: pointer; white-space: nowrap; }
.tabs-seg button { border-bottom: 2.5px solid transparent; }
.tabs-seg button:hover { color: var(--accent); }
.tabs-seg button.active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }
.tabs-more { position: relative; flex: none; }
.tabs-more > button { color: var(--muted); }
.tabs-menu { position: fixed; z-index: 2500; min-width: 190px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 6px; box-shadow: 0 14px 34px var(--shadow); display: grid; }
.tabs-menu button { text-align: left; border-radius: 10px; min-height: 44px; }
.tabs-menu button:hover { background: var(--bg); }

/* skeleton: grey shapes shown while a tab or list is loading (use skeleton(n), not the word "Loading") */
.skel { display: grid; gap: 12px; }
.skel i { display: block; height: 16px; border-radius: 8px; background: linear-gradient(90deg, var(--skel-a) 25%, var(--skel-b) 50%, var(--skel-a) 75%); background-size: 200% 100%; animation: skel 1.2s linear infinite; }
.skel i:nth-child(3n) { width: 70%; } .skel i:nth-child(3n+1) { width: 92%; }
@keyframes skel { to { background-position: -200% 0; } }
.empty { text-align: center; color: var(--muted); padding: 36px 12px; }

/* drawer: a panel that slides in over the page for viewing or editing one record */
.drawer-back { position: fixed; inset: 0; z-index: 2800; background: var(--scrim); display: flex; justify-content: flex-end; }
.drawer { width: min(520px, 100%); height: 100%; background: var(--card); display: flex; flex-direction: column; box-shadow: -12px 0 32px var(--shadow);
          border-top-left-radius: 24px; border-bottom-left-radius: 24px; animation: drawerIn .28s ease both; }
@keyframes drawerIn { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.drawer.wide { width: min(760px, 100%); }
.drawer-head { display: flex; align-items: center; gap: 10px; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { flex: 1; }
.drawer-head button { border: 0; background: var(--bg); width: 40px; height: 40px; border-radius: 12px; font-size: 1.3rem; cursor: pointer; color: var(--ink); }
.drawer-body { padding: 22px; overflow-y: auto; flex: 1; position: relative; overscroll-behavior: contain; }
/* the top of a record's drawer (name, number, status, inner tabs) stays while the body scrolls under it */
.drawer-top { position: sticky; top: -22px; z-index: 6; background: var(--card); margin: -22px -22px 18px; padding: 18px 22px 12px; border-bottom: 1px solid var(--line); }
.drawer-top .seg { margin-bottom: 0; }
/* while a drawer is open only the page (html) is locked: body keeps its overflow, so the sticky sidebar, panel and top bar
   stay exactly where they are; the scrollbar's room is kept so nothing shifts sideways */
html { scrollbar-gutter: stable; }
html.drawer-open { overflow: hidden; }
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 12px 24px; margin: 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }

/* ================= log in / sign up frame: brand panel + form ================= */
/* On a computer the frame is exactly the window: the page itself never scrolls. The green panel keeps its content
   inside (the demo shrinks to fit), and the right column scrolls on its own when it needs to. */
.auth { display: grid; grid-template-columns: minmax(320px, 42%) 1fr; height: 100vh; height: 100dvh; }
.auth-brand { background: var(--cream); color: var(--ink); padding: 32px 44px; display: flex; flex-direction: column; position: relative; overflow: hidden; min-height: 0; }
.auth-brand .logo.light { color: var(--ink); }
.auth-brand .logo.light .logo-mark { background: var(--green); }
.auth-brand .logo.light .logo-mark::after { background: #fff; }
.auth-pitch { margin: 48px 0 0; position: relative; z-index: 1; flex: none; display: grid; }
/* the words beside the picture: every pair sits in the same place (the tallest sets the height, so nothing jumps);
   app.js moves .on along with the picture, with a soft cross-fade */
.auth-say { grid-area: 1 / 1; opacity: 0; transition: opacity .5s ease; }
.auth-say.on { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .auth-say { transition: none; } }
.auth-pitch h2 { color: var(--green-dark); font-size: 2.2rem; letter-spacing: -.03em; line-height: 1.15; }
.auth-pitch p { color: var(--ink); margin: 14px 0 0; font-size: 1.05rem; }
/* the moving picture of the app (core/auth-login.svg, core/auth-signup.svg): it takes whatever height is left under the headline and is
   drawn inside that box (shrinking on short windows), so it can never push the page */
.auth-demo { flex: 1 1 0; min-height: 0; position: relative; z-index: 1; }
/* .auth-demo carries .stay-light: the picture keeps its light colours on the dark page (it draws its own white card) */
.auth-demo svg { position: absolute; left: 0; top: 28px; width: 100%; max-width: 520px; height: calc(100% - 44px); }
.auth-main { display: flex; flex-direction: column; align-items: center; padding: 32px 40px; background: var(--cream); min-height: 0; overflow-y: auto; }
/* centred when it fits; when it is taller than the window the column scrolls from its top */
.auth-main > .auth-card, .auth-main > .notice { margin-top: auto; margin-bottom: auto; }
.auth-logo-small { display: none; margin-bottom: 14px; }
/* the form column on the cream background: open, no card. Start it with a heading row:
   <div class="auth-head"><h1>Log in</h1><span>Welcome back</span></div> */
.auth-card { width: 100%; max-width: 820px; }
.auth-card.narrow { max-width: 440px; }
.auth-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-bottom: 14px; margin-bottom: 22px; border-bottom: 1px solid var(--line-2); }
.auth-head h1 { font-size: 1.6rem; }
.auth-head > span { color: var(--muted); font-size: .9rem; white-space: nowrap; }
.auth-card .sub { color: var(--muted); margin: 0 0 20px; }
.auth-foot { text-align: center; font-size: .92rem; margin-top: 12px; min-height: 48px; display: flex; align-items: center; justify-content: center; gap: 6px; flex-wrap: wrap; }

/* ================= website frame (landing): header + footer ================= */
.site-in { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.site-nav { position: sticky; top: 0; z-index: 50; background: var(--nav-glass); backdrop-filter: saturate(1.4) blur(10px); }
.site-nav .site-in { display: flex; align-items: center; gap: 36px; min-height: 76px; position: relative; }
.site-links { display: flex; gap: 28px; flex: 1; }
.site-links a, .site-login { color: var(--ink); font-weight: 500; text-decoration: none !important; }
.site-links a:hover, .site-login:hover { color: var(--green); }
.site-acts { display: flex; align-items: center; gap: 22px; }
.site-burger { display: none; border: 0; background: none; width: 44px; height: 44px; border-radius: 12px; cursor: pointer; color: var(--ink); place-items: center; }
.site-only-phone { display: none; }
.site-foot { background: var(--foot-bg); color: #cfe9dc; padding: 56px 0 28px; border-top-left-radius: 80px; }
.foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.foot-grid h3 { color: #fff; font-size: .95rem; margin-bottom: 12px; }
.foot-grid > div:not(.foot-brand) { display: grid; gap: 8px; align-content: start; }
.foot-grid a { color: #cfe9dc; }
.foot-grid a:hover { color: #fff; }
.foot-grid small { font-size: .72rem; background: rgba(255,255,255,.12); padding: 1px 7px; border-radius: 999px; margin-left: 4px; }
.foot-brand p { margin-top: 12px; max-width: 320px; }
.foot-base { margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.14); font-size: .86rem; }

/* ================= smaller screens ================= */
@media (max-width: 991px) {
  /* the sticky heading takes the logo's place on phones */
  .top.has-title .top-logo, .top.has-title .top-trial { display: none !important; }
  .ph-sticky b { font-size: .98rem; }
  /* the sidebar becomes a menu that slides in from the left */
  .shell { display: block; }
  .side, body.rail .side { position: fixed; left: 0; top: 0; bottom: 0; height: auto; width: min(320px, 86vw); padding: 14px 12px; transform: translateX(-105%);
          transition: transform .25s ease; border-radius: 0 24px 24px 0; overflow-y: auto; z-index: 2700; }
  body.nav-open .side { transform: none; box-shadow: 0 0 40px var(--shadow-2); }
  body.nav-open .side-back { display: block; position: fixed; inset: 0; z-index: 2650; background: var(--scrim); }
  body.rail .side-top { flex-direction: row; padding: 0 6px 0 8px; height: 52px; }
  body.rail .side-top .logo { flex: 1; }
  body.rail .side .logo-word { display: inline; }
  body.rail .side-nav { overflow-y: auto; }
  body.rail .side-link { justify-content: flex-start; padding: 0 14px; }
  body.rail .side-label { position: static; transform: none; background: none; color: inherit; font: inherit; padding: 0; opacity: 1; }
  .side-toggle { display: none !important; }
  .side-close { display: grid; }
  .side-chev { display: block; }
  .side-item.open .side-chev { transform: rotate(180deg); }
  .side-item.open .side-sub { display: block; padding: 4px 0 8px 50px; }
  .side-item.bottom { margin-top: 0; }
  .panel { display: none !important; }
  .top { padding: 0 12px; min-height: 64px; gap: 6px; }
  .top:not(.has-title) .top-slot { display: none !important; }   /* on phones the slot shows only the sticky heading */
  .top-menu { display: grid !important; }
  .top-logo { display: inline-flex !important; }
  .top-logo .logo-mark { width: 30px; height: 30px; }
  .top-logo .logo-mark::after { inset: 10px; }
  /* the section's chips stay under the sticky top bar (--top-h is measured by app.js); tabs marked .stick stay under both */
  .subnav-phone { display: flex; gap: 6px; overflow-x: auto; padding: 10px 16px 8px; scrollbar-width: none;
                  position: sticky; top: var(--top-h, 64px); z-index: 2300; background: var(--page); }
  .tabs.stick { position: sticky; top: var(--below-top, 64px); z-index: 2200; background: var(--page); }
  .subnav-phone .sub-group { display: none; }
  .subnav-phone .sub-link { white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; font-size: .9rem; margin: 0; }
  .subnav-phone .sub-link.active { border-color: transparent; }
  .wrap { padding: 8px 16px 48px; }
  .page-head h1 { font-size: 1.7rem; }
  .auth { grid-template-columns: 1fr; height: auto; min-height: 100vh; }
  .auth-brand { display: none; }
  .auth-logo-small { display: inline-flex; }
  .auth-main { justify-content: flex-start; padding: 18px 16px 12px; overflow: visible; }
  .auth-main > .auth-card, .auth-main > .notice { margin-top: 0; margin-bottom: 0; }
  .site-links { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--card); flex-direction: column; gap: 0; padding: 8px 16px 16px; border-bottom: 1px solid var(--line); box-shadow: 0 16px 30px rgba(27,27,27,.08); }
  .site-links.open { display: flex; }
  .site-links a { padding: 12px 8px; border-radius: 10px; }
  .site-only-phone { display: block; }
  .site-login { display: none; }
  .site-burger { display: grid; }
  .site-nav .site-in { gap: 10px; }
  .site-nav .logo { flex: 1; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .row2 { grid-template-columns: 1fr; }
  .auth-head { margin-bottom: 16px; padding-bottom: 10px; }
  .auth-head h1 { font-size: 1.3rem; }
  .auth-card .sub { margin-bottom: 12px; }
  .auth-main { padding: 12px 16px 8px; }
  .auth-logo-small { margin-bottom: 10px; }
  .field { margin-bottom: 12px; }
  .who-company, .who-chev { display: none; }
  .who-btn { padding: 0; width: 44px; justify-content: center; }
  .top-trial { font-size: .72rem; padding: 3px 8px; }
  .top .top-trial { margin-left: auto; }
  .top-space { display: none; }   /* its gap is room the trial pill needs; the pill pushes the account button right */
  .logo { font-size: 1.15rem; }
  .page-head h1 { font-size: 1.5rem; }
  .card { padding: 18px; }
  .site-in { padding: 0 16px; }
  .site-acts .btn { padding: 0 14px; }
  .site-foot { border-top-left-radius: 48px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* "Open as this admin" (core/view.php): the read-only banner under the top bar, on every page of the view */
.view-banner { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; padding: 10px 24px; background: var(--warn-bg); color: var(--warn);
               border-bottom: 1px solid var(--line); font-size: .92rem; }
.view-banner > .ic { width: 18px; height: 18px; flex: none; }
.view-banner span { flex: 1; min-width: 200px; }
@media (max-width: 560px) { .view-banner { padding: 10px 16px; } }
@media (max-width: 400px) { .top { gap: 4px; padding-left: 10px; padding-right: 10px; } }

/* ---------- the admin app's log in, set-password and code pages (core/header.php, frame-adm) ---------- */
/* the company login's cream, with small soft mint dots (core/admin-net.svg) drifting slowly; still with reduced motion */
body.frame-adm { background: var(--cream); }
.adm-auth { position: relative; min-height: 100vh; min-height: 100dvh; overflow: hidden; background: var(--cream); }
.adm-net { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.adm-net .far { animation: adm-drift 90s ease-in-out infinite alternate; }
.adm-net .near { animation: adm-drift2 70s ease-in-out infinite alternate; }
@keyframes adm-drift { from { transform: translate(0, 0); } to { transform: translate(-36px, 24px); } }
@keyframes adm-drift2 { from { transform: translate(0, 0); } to { transform: translate(44px, -28px); } }
@media (prefers-reduced-motion: reduce) { .adm-net .far, .adm-net .near { animation: none; } }
.adm-main { position: relative; z-index: 1; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 16px; }
.adm-card { width: 100%; max-width: 570px; }   /* no card: the content sits on the cream */
.adm-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.adm-top b { font-size: 1.15rem; letter-spacing: -.02em; color: var(--green-deep); }
.adm-badge { margin-left: auto; font-size: .72rem; font-weight: 700; letter-spacing: .08em; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.adm-badge.test { background: #fdecc0; color: #6b4500; }
.adm-badge.live { background: var(--mint); color: var(--green-deep); }
.adm-steps { list-style: none; display: flex; gap: 6px; margin: 20px 0 18px; padding: 0; counter-reset: s; }
.adm-steps li { flex: 1; font-size: .78rem; color: var(--muted); counter-increment: s; }
.adm-steps li::before { content: ''; display: block; height: 4px; border-radius: 4px; background: var(--line); margin-bottom: 6px; transition: background .3s; }
.adm-steps li.on { color: var(--ink); font-weight: 600; }
.adm-steps li.on::before, .adm-steps li.done::before { background: var(--green); }
.adm-view { overflow: hidden; transition: height .35s ease; }
.adm-track { display: flex; align-items: flex-start; transition: transform .35s ease; }
.adm-step { flex: 0 0 100%; min-width: 0; padding: 2px; }
.adm-step[aria-hidden="true"] { visibility: hidden; }
.adm-step h1 { font-size: 1.45rem; margin: 0 0 6px; }
.adm-step .sub { color: var(--muted); margin: 0 0 18px; overflow-wrap: anywhere; }
.adm-step .btn.wide { width: 100%; }
.adm-step .adm-links { display: flex; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; margin-top: 12px; font-size: .92rem; }
.adm-step .adm-links .linkbtn { min-height: 40px; }
.adm-rec { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 14px 0 0; color: var(--muted); font-size: .84rem; }
.adm-rec .ic { width: 15px; height: 15px; }
@media (prefers-reduced-motion: reduce) { .adm-view, .adm-track, .adm-steps li::before { transition: none; } }
@media (max-width: 480px) { .adm-main { align-items: flex-start; padding: 24px 16px; } }

/* a phone box with the country's code shown in front: <div class="tel"><span>+256</span><input type="tel"></div> */
.tel { display: flex; align-items: stretch; }
.tel > span { display: inline-flex; align-items: center; padding: 0 12px; border: 1.5px solid var(--line-2); border-right: 0; border-radius: 10px 0 0 10px;
  background: var(--bg); color: var(--muted); font-weight: 600; white-space: nowrap; }
.field .tel input { border-radius: 0 10px 10px 0; min-width: 0; flex: 1; }

/* Dark details (both ways of being dark) */
@media screen {
  html.theme-dark .adm-net { opacity: .3; }
  html.theme-dark .adm-badge.test { background: #4a3a10; color: #f8dc8a; }
}
@media screen and (prefers-color-scheme: dark) {
  html.theme-auto .adm-net { opacity: .3; }
  html.theme-auto .adm-badge.test { background: #4a3a10; color: #f8dc8a; }
}
