/* ============================================================================
   EHS TRAINING PORTAL  -  design layer (loads AFTER legacy.css)
   Direction: iOS-style grouped surfaces, large titles, frosted bars, 50pt
   controls. Identity from the warehouse floor: ink navy, hi-vis orange and the
   four ISO 7010 sign colours (red fire, blue mandatory, yellow caution, green safe).
   ============================================================================ */
:root {
  color-scheme: light;
  --ink: #0F1B2D;
  --ink-2: #566274;
  --ink-3: #8590A0;
  --paper: #F2F2F7;
  --card: #FFFFFF;
  --rule: #E3E6EC;
  --rule-soft: #EEF0F4;
  --navy: #0E1B2E;
  --navy-2: #17304F;
  --blue: #1F5FA8;
  --hivis: #FF6A13;
  --action: #C2410C;           /* 5.2:1 with white text */
  --action-700: #9A3412;
  --go: #0B7A44;  --go-bg: #E2F5EA;
  --wait: #9A5B00; --wait-bg: #FFF1D6;
  --stop: #C0281F; --stop-bg: #FDE8E6;

  /* remap legacy violet/pink tokens */
  --violet-950: var(--navy);
  --violet-900: #13243B;
  --violet-700: #1B3B63;
  --violet-600: #17406F;
  --violet-500: #2F6DB5;
  --violet-400: #7FA6D6;
  --pink: var(--action);
  --pink-700: var(--action-700);
  --gold: #FFB36B;
  --grad: linear-gradient(120deg, #17406F, #2F6DB5);

  --radius: 20px;
  --shadow-sm: 0 1px 2px rgba(15, 27, 45, .05);
  --shadow-md: 0 12px 32px rgba(15, 27, 45, .12);
  --shadow-lg: 0 24px 60px rgba(15, 27, 45, .22);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Noto Sans", "Noto Sans Devanagari", "Noto Sans Tamil", "Noto Sans Telugu", "Noto Sans Kannada", "Noto Sans Malayalam", "Noto Sans Bengali", "Helvetica Neue", Arial, sans-serif;
  --nav-h: 56px;
  --tab-h: 62px;
}

html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--font); font-size: 16px; line-height: 1.5; background: var(--paper); color: var(--ink);
       -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid rgba(31, 95, 168, .55); outline-offset: 2px; }
[hidden] { display: none !important; }

/* -------------------------------------------------------------- frame */
#frame { min-height: 100vh; min-height: 100dvh; }
.navbar {
  position: sticky; top: 0; z-index: 30; height: calc(var(--nav-h) + env(safe-area-inset-top));
  padding-top: env(safe-area-inset-top);
  background: rgba(242, 242, 247, .82); -webkit-backdrop-filter: saturate(180%) blur(18px); backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid rgba(15, 27, 45, .08);
}
.navbar .in { max-width: 1120px; margin: 0 auto; height: var(--nav-h); padding: 0 18px; display: flex; align-items: center; gap: 12px; }
.brandlock { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -.01em; color: var(--ink); text-decoration: none; background: none; border: 0; padding: 0; font-size: 17px; }
.brandlock .mark { width: 30px; height: 30px; flex: none; }
.brandlock small { display: block; font-size: 11px; font-weight: 500; color: var(--ink-2); letter-spacing: 0; margin-top: -2px; }
.navbar .grow { flex: 1; }
.navlinks { display: none; gap: 4px; }
.navlinks button { background: none; border: 0; padding: 8px 14px; border-radius: 10px; font-size: 15px; font-weight: 600; color: var(--ink-2); }
.navlinks button.on { background: rgba(15, 27, 45, .07); color: var(--ink); }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; border: 0; padding: 0; }
.menu { position: absolute; right: 14px; top: calc(var(--nav-h) + env(safe-area-inset-top) - 4px); width: 260px; background: #fff; border-radius: 16px; box-shadow: var(--shadow-md); border: 1px solid var(--rule); padding: 8px; z-index: 40; }
.menu .who { padding: 10px 12px 12px; border-bottom: 1px solid var(--rule-soft); margin-bottom: 6px; text-align: left; color: var(--ink); }
.menu .who b { display: block; font-size: 15px; }
.menu .who span { font-size: 13px; color: var(--ink-2); word-break: break-all; }
.menu button { width: 100%; text-align: left; background: none; border: 0; border-radius: 10px; padding: 11px 12px; font-size: 15px; color: var(--ink); font-weight: 600; }
.menu button:hover { background: var(--rule-soft); }
.menu button.danger { color: var(--stop); }

#app.wrap { max-width: 780px; padding: 18px 16px calc(var(--tab-h) + 40px + env(safe-area-inset-bottom)); margin: 0 auto; }
#app.wrap.wide { max-width: 1120px; }
.sitefoot { margin-top: 0; border: 0; padding: 8px 16px 24px; font-size: 12.5px; color: var(--ink-3); text-align: center; }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; height: calc(var(--tab-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: rgba(249, 249, 251, .88); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid rgba(15, 27, 45, .1); display: flex; justify-content: space-around;
}
.tabbar button { flex: 1; max-width: 160px; background: none; border: 0; border-radius: 0; padding: 7px 4px 4px; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 11px; font-weight: 600; color: var(--ink-3); }
.tabbar button svg { width: 25px; height: 25px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tabbar button.on { color: var(--action); }
@media (min-width: 900px) {
  .tabbar { display: none; }
  .navlinks { display: flex; }
  #app.wrap { padding-bottom: 60px; }
}

/* ------------------------------------------------- legacy components, restyled */
.card { border: 1px solid rgba(15, 27, 45, .06); box-shadow: none; padding: 22px 20px; margin-bottom: 14px; border-radius: var(--radius); }
.card.flush { padding: 0; }
h1 { font-size: 30px; font-weight: 800; letter-spacing: -.025em; line-height: 1.15; }
h2 { font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
h3 { font-size: 17px; font-weight: 650; }
.sub { font-size: 15px; }
button { font-family: inherit; font-size: 16px; font-weight: 600; border-radius: 14px; padding: 14px 20px; min-height: 48px; }
.btn-primary { background: var(--action); box-shadow: none; font-size: 17px; }
.btn-primary:hover:not(:disabled) { background: var(--action-700); box-shadow: none; }
.btn-primary:disabled { background: #C9CED7; color: #fff; }
.btn-ghost { background: #fff; border: 1px solid var(--rule); color: var(--ink); }
.btn-ghost:hover { background: var(--rule-soft); }
.btn-go { background: var(--go); box-shadow: none; font-size: 17px; }
.btn-go:disabled { background: #C9CED7; }
.btn-dark { background: var(--navy); color: #fff; }
.btn-dark:hover:not(:disabled) { background: var(--navy-2); }
.btn-sm { min-height: 38px; padding: 8px 14px; font-size: 14px; border-radius: 11px; }
.btn-text { background: none; border: 0; color: var(--blue); padding: 8px 4px; min-height: 0; font-size: 15px; }
input[type=text], input[type=password], input[type=email], input[type=tel], input[type=search], input[type=number], select, textarea {
  font-family: inherit; width: 100%; padding: 14px 15px; font-size: 17px; border: 1px solid var(--rule); border-radius: 12px; background: #fff; color: var(--ink); min-height: 50px;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); background: #fff; box-shadow: 0 0 0 4px rgba(31, 95, 168, .16); }
label { font-size: 14px; font-weight: 600; }
.msg { border-radius: 12px; border-left-width: 0; padding: 13px 15px; font-size: 14.5px; }
.msg.info { background: #EAF1FA; color: #17406F; }
.msg.err { background: var(--stop-bg); color: #8A1C15; }
.msg.ok { background: var(--go-bg); color: #095C33; }
.msg.warn { background: var(--wait-bg); color: #6E4200; }

.chip { background: #EEF0F4; color: var(--ink-2); font-size: 12.5px; }
.pill { font-size: 12px; font-weight: 700; }
.pill.done { background: var(--go-bg); color: var(--go); }
.pill.pend, .pill.wait { background: var(--wait-bg); color: var(--wait); }
.pill.fail { background: var(--stop-bg); color: var(--stop); }

/* language picker -> iOS segmented scroller */
.langtabs { flex-wrap: nowrap; overflow-x: auto; gap: 6px; padding: 2px 0 6px; margin: 0 -16px 12px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.langtabs::-webkit-scrollbar { display: none; }
.langlabel { display: none; }
.langtabs button { flex: none; background: #fff; border: 1px solid var(--rule); color: var(--ink-2); padding: 8px 15px; min-height: 38px; font-size: 14.5px; border-radius: 999px; }
.langtabs button.on { background: var(--navy); color: #fff; border-color: var(--navy); }

/* step rail */
.rail { gap: 4px; margin-bottom: 14px; }
.rail div { background: transparent; border: 0; border-top: 4px solid var(--rule); border-radius: 0; padding: 8px 2px 0; font-size: 12px; text-align: left; color: var(--ink-3); }
.rail div.on { background: transparent; color: var(--ink); border-top-color: var(--action); box-shadow: none; }
.rail div.past { background: transparent; color: var(--go); border-top-color: var(--go); }

.thead { border-top: 0; padding: 20px; }
.thead-row h1 { font-size: 24px; }
.seccard { border: 1px solid rgba(15, 27, 45, .06); box-shadow: none; padding: 22px 20px; }
.seccard h3 { font-size: 20px; }
.pts li { font-size: 17px; line-height: 1.55; }
.seccard p { font-size: 17px; }
.pts li.pthead { color: var(--blue); }
.ptmark.neutral { background: var(--blue); }
.secdots span.on { background: var(--action); }
.secdots span.past { background: var(--go); }
.secicon { background: #EAF1FA; }
.secicon svg { stroke: var(--blue); }
.scene, .scene.tone-violet { background: radial-gradient(circle at 85% 10%, rgba(255, 106, 19, .35), transparent 50%), linear-gradient(135deg, #0E1B2E, #1F5FA8); }
.scene.tone-red    { background: radial-gradient(circle at 85% 10%, rgba(255,200,120,.35), transparent 50%), linear-gradient(135deg, #7a1410, #E23A2E); }
.scene.tone-blue   { background: radial-gradient(circle at 85% 10%, rgba(140,200,255,.35), transparent 50%), linear-gradient(135deg, #0b2f6b, #1767D6); }
.scene.tone-yellow { background: radial-gradient(circle at 85% 10%, rgba(255,240,160,.40), transparent 50%), linear-gradient(135deg, #6b4500, #d99200); }
.scene.tone-green  { background: radial-gradient(circle at 85% 10%, rgba(170,255,210,.30), transparent 50%), linear-gradient(135deg, #064a2b, #0FA05A); }
.audiobar { background: #EEF3F9; border: 1px solid #D9E4F1; border-radius: 14px; }
.aud-opts { border-top-color: #D3E0EF; }
.audbtn { background: var(--navy); }
.audbtn:hover { background: var(--navy-2); }
.audbtn svg { stroke: #fff; }
.audiobar.playing .audbtn { background: var(--stop); }
.audicon { border-color: #D3E0EF; }
.audicon svg { stroke: var(--blue); }
.vbars i { background: var(--blue); }
.audiobar.playing .vbars i { background: var(--hivis); }
.spdgroup { border-color: #D3E0EF; }
.spd.on { background: var(--navy); }
.autoread input { accent-color: var(--navy); }
.autonote { color: var(--blue); border-color: #D3E0EF; }
.tapline:hover { background: #F3F7FB; }
.speaking, .opt.speaking { background: #FFF1D6; box-shadow: 0 0 0 6px #FFF1D6; }
.keypt { border-left-color: var(--hivis); background: #FFF4E5; }
.keypt svg { stroke: #B45309; }
.keypt div b { color: #B45309; }
.qaud { background: #EEF3F9; border-color: #D3E0EF; }
.qaud svg { stroke: var(--blue); }
.q { border-color: rgba(15, 27, 45, .06); box-shadow: none; }
.q .qnum { background: var(--navy); }
.opt { background: #fff; border-radius: 14px; padding: 14px 15px; min-height: 52px; font-size: 16.5px; }
.opt:hover { border-color: var(--violet-400); }
.opt.sel { border-color: var(--blue); background: #EAF1FA; box-shadow: 0 0 0 1px var(--blue); }
.opt input { accent-color: var(--blue); }
.opt .k { color: var(--blue); }
.ack { background: #fff; border-radius: 14px; }
.scorebox { border-radius: var(--radius); }
.scorebox .big { font-size: 68px; }
.shot img { border-radius: 14px; }
.navrow .btn-ghost { min-width: 56px; }
.dl dd { word-break: break-word; }
.done-head { border-bottom-color: var(--rule); }

.tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; scrollbar-width: none; margin-bottom: 14px; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; border-radius: 999px; min-height: 40px; padding: 9px 16px; font-size: 14.5px; background: #fff; }
.tabs button.on { background: var(--navy); border-color: var(--navy); box-shadow: none; }
.kpi { border-top: 0; border-radius: 16px; border: 1px solid rgba(15, 27, 45, .06); }
.kpi b { font-size: 28px; }
.kpi.kpi-violet b { color: var(--blue); }
th { background: var(--navy); }
tbody tr:hover td { background: #F6F9FC; }
.bar i { background: var(--go); }
.spin { border-top-color: var(--action); }

/* ----------------------------------------------------------- dashboard */
.hello { margin: 6px 2px 16px; }
.hello h1 { margin: 0 0 2px; }
.hello p { color: var(--ink-2); font-size: 15px; }
.progcard { display: flex; align-items: center; gap: 18px; background: var(--navy); color: #fff; border-radius: 24px; padding: 20px; margin-bottom: 14px; position: relative; overflow: hidden; }
.progcard::after { content: ""; position: absolute; right: -30px; top: -30px; width: 140px; height: 140px; border-radius: 50%; background: rgba(255, 106, 19, .18); }
.ring { width: 92px; height: 92px; flex: none; position: relative; z-index: 1; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .trk { stroke: rgba(255, 255, 255, .16); }
.ring .val { stroke: var(--hivis); transition: stroke-dasharray .9s cubic-bezier(.2, .8, .2, 1); }
.ring b { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.progtxt { position: relative; z-index: 1; }
.progtxt h2 { color: #fff; font-size: 19px; margin: 0 0 4px; }
.progtxt p { color: rgba(255, 255, 255, .78); font-size: 14.5px; }
.progtxt .stats { display: flex; gap: 16px; margin-top: 10px; font-size: 13px; color: rgba(255, 255, 255, .7); }
.progtxt .stats b { display: block; color: #fff; font-size: 20px; letter-spacing: -.01em; }

.upnext { display: block; width: 100%; text-align: left; background: #fff; border: 1px solid rgba(15, 27, 45, .06); border-radius: 24px; padding: 20px; margin-bottom: 14px; position: relative; overflow: hidden; color: var(--ink); }
.upnext .lbl { font-size: 12.5px; font-weight: 700; color: var(--action); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.upnext .lbl i { width: 8px; height: 8px; border-radius: 50%; background: var(--hivis); display: inline-block; }
.upnext h2 { font-size: 23px; margin-bottom: 8px; }
.upnext p { color: var(--ink-2); font-size: 15px; margin-bottom: 14px; }
.upnext .go { margin-top: 16px; }

.sectionlabel { font-size: 13px; font-weight: 600; color: var(--ink-2); margin: 20px 6px 8px; }
.list { background: #fff; border-radius: 20px; border: 1px solid rgba(15, 27, 45, .06); overflow: hidden; }
.row { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; background: #fff; border: 0; border-radius: 0; padding: 14px 16px; min-height: 68px; color: var(--ink); border-bottom: 1px solid var(--rule-soft); }
.row:last-child { border-bottom: 0; }
.row:active { background: var(--rule-soft); transform: none; }
.row .meta { flex: 1; min-width: 0; }
.row .meta b { display: block; font-size: 16.5px; font-weight: 650; line-height: 1.3; }
.row .meta span { display: block; font-size: 13.5px; color: var(--ink-2); margin-top: 2px; }
.row .chev { width: 18px; height: 18px; stroke: var(--ink-3); fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.row .tbadge { width: 40px; height: 40px; }
.empty-state { text-align: center; padding: 34px 20px; color: var(--ink-2); }
.empty-state b { display: block; color: var(--ink); font-size: 17px; margin-bottom: 4px; }

/* ------------------------------------------------------------- landing */
.signstripe { height: 6px; background: linear-gradient(90deg, var(--sign-red) 0 25%, var(--sign-blue) 25% 50%, var(--sign-yellow) 50% 75%, var(--sign-green) 75% 100%); }
.lp { background: var(--paper); min-height: 100vh; min-height: 100dvh; }
.lp-nav { max-width: 1120px; margin: 0 auto; padding: 16px 20px; display: flex; align-items: center; gap: 12px; }
.lp-nav .grow { flex: 1; }
.lp-hero { max-width: 1120px; margin: 0 auto; padding: 28px 20px 44px; display: grid; grid-template-columns: 1fr; gap: 36px; align-items: center; }
.lp-hero h1 { font-size: clamp(38px, 9vw, 68px); font-weight: 850; letter-spacing: -.035em; line-height: 1.02; margin: 0 0 18px; }
.lp-hero p.lead { font-size: clamp(17px, 2.4vw, 20px); color: var(--ink-2); max-width: 34em; margin-bottom: 26px; }
.lp-cta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.lp-cta .btn-primary { width: auto; padding-left: 32px; padding-right: 32px; }
.lp-cta small { color: var(--ink-2); font-size: 13.5px; }
.phone { width: min(320px, 82vw); margin: 0 auto; background: var(--navy); border-radius: 44px; padding: 12px; box-shadow: var(--shadow-lg); transform: rotate(2deg); }
.phone .scr { background: var(--paper); border-radius: 34px; padding: 18px 14px 20px; min-height: 460px; }
.phone .notch { width: 92px; height: 24px; background: var(--navy); border-radius: 0 0 16px 16px; margin: -18px auto 12px; }
.phone .mini-h { font-size: 11.5px; color: var(--ink-2); margin: 0 4px 2px; }
.phone .mini-t { font-size: 22px; font-weight: 800; letter-spacing: -.02em; margin: 0 4px 12px; }
.phone .mini-ring { display: flex; align-items: center; gap: 12px; background: var(--navy); color: #fff; border-radius: 18px; padding: 12px; margin-bottom: 10px; }
.phone .mini-ring .ring { width: 56px; height: 56px; }
.phone .mini-ring .ring b { font-size: 15px; }
.phone .mini-ring p { font-size: 12px; color: rgba(255, 255, 255, .8); }
.phone .mini-ring h4 { font-size: 13.5px; margin-bottom: 2px; }
.phone .mini-card { background: #fff; border-radius: 16px; padding: 12px; margin-bottom: 8px; font-size: 12px; }
.phone .mini-card b { display: block; font-size: 14.5px; margin-bottom: 4px; }
.phone .mini-card .bt { margin-top: 8px; background: var(--action); color: #fff; text-align: center; font-weight: 700; border-radius: 10px; padding: 8px; font-size: 13px; }
.phone .mini-pts { display: grid; gap: 5px; margin-top: 6px; }
.phone .mini-pts span { display: flex; gap: 7px; align-items: flex-start; font-size: 12px; }
.phone .mini-pts i { width: 7px; height: 7px; margin-top: 5px; flex: none; background: var(--blue); clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%); }
.lp-band { background: #fff; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.lp-sec { max-width: 1120px; margin: 0 auto; padding: 44px 20px; }
.lp-sec h2 { font-size: clamp(26px, 5vw, 36px); letter-spacing: -.03em; margin-bottom: 8px; }
.lp-sec > p { color: var(--ink-2); max-width: 40em; margin-bottom: 26px; font-size: 17px; }
.steps { display: grid; gap: 14px; counter-reset: st; }
.step { background: var(--paper); border-radius: 20px; padding: 20px; position: relative; }
.step::before { counter-increment: st; content: counter(st); display: inline-flex; width: 34px; height: 34px; border-radius: 50%; background: var(--navy); color: #fff; align-items: center; justify-content: center; font-weight: 800; margin-bottom: 12px; }
.step h3 { font-size: 18px; margin-bottom: 4px; }
.step p { color: var(--ink-2); font-size: 15px; }
.feats { display: grid; gap: 12px; }
.feat { background: #fff; border: 1px solid rgba(15, 27, 45, .06); border-radius: 20px; padding: 18px; display: flex; gap: 14px; align-items: flex-start; }
.feat .ic { width: 44px; height: 44px; flex: none; }
.feat h3 { font-size: 17px; margin-bottom: 2px; }
.feat p { font-size: 14.5px; color: var(--ink-2); }
.langs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.langs span { background: #fff; border: 1px solid var(--rule); border-radius: 999px; padding: 7px 14px; font-weight: 600; font-size: 15px; }
.lp-foot { max-width: 1120px; margin: 0 auto; padding: 26px 20px 40px; color: var(--ink-2); font-size: 13.5px; display: flex; gap: 8px 24px; flex-wrap: wrap; justify-content: space-between; }
@media (min-width: 860px) {
  .lp-hero { grid-template-columns: 1.15fr .85fr; padding-top: 48px; padding-bottom: 72px; }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .feats { grid-template-columns: repeat(2, 1fr); }
}

/* --------------------------------------------------------------- login */
.auth { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
.auth-in { flex: 1; display: flex; align-items: center; justify-content: center; padding: 22px 16px 40px; }
.auth-card { width: 100%; max-width: 420px; background: #fff; border-radius: 28px; padding: 30px 24px 26px; box-shadow: var(--shadow-md); border: 1px solid rgba(15, 27, 45, .05); }
.auth-card .mark { width: 54px; height: 54px; margin-bottom: 14px; }
.auth-card h1 { font-size: 28px; margin-bottom: 6px; }
.auth-card .sub { margin-bottom: 20px; }
.auth-card .field { margin-bottom: 14px; }
.codebox { letter-spacing: .5em; font-size: 28px; text-align: center; font-weight: 700; padding-left: .5em; font-variant-numeric: tabular-nums; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; font-weight: 500; color: var(--ink-2); margin: 4px 0 16px; cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--navy); flex: none; min-height: 0; }
.auth-links { display: flex; justify-content: space-between; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.seg { display: flex; background: #E6E8EE; border-radius: 12px; padding: 3px; margin-bottom: 16px; }
.seg button { flex: 1; background: transparent; border: 0; min-height: 38px; padding: 7px; font-size: 14.5px; color: var(--ink-2); border-radius: 10px; }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(15, 27, 45, .15); }
.help { background: var(--paper); border-radius: 14px; padding: 13px 15px; font-size: 13.5px; color: var(--ink-2); margin-top: 16px; }
.help b { color: var(--ink); }

/* --------------------------------------------------------------- admin */
.drop { border: 2px dashed #C5CCD8; border-radius: 16px; padding: 22px; text-align: center; background: #fff; color: var(--ink-2); font-size: 14.5px; }
.drop.over { border-color: var(--blue); background: #EAF1FA; }
.drop input[type=file] { display: none; }
.drop label { display: inline-block; margin: 8px 0 0; background: var(--navy); color: #fff; padding: 10px 18px; border-radius: 12px; font-size: 15px; cursor: pointer; }
.grid2 { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .grid2 { grid-template-columns: 1fr 1fr; } }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.toolbar input { flex: 1; min-width: 180px; }
.errlist { font-size: 13.5px; max-height: 220px; overflow: auto; background: var(--stop-bg); border-radius: 12px; padding: 10px 14px; margin-top: 10px; }
.errlist li { margin-left: 16px; padding: 2px 0; }
td .btn-sm { white-space: nowrap; }
.tag { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: #EEF0F4; color: var(--ink-2); }
.tag.admin { background: #E3EDF9; color: var(--blue); }
.tag.off { background: var(--stop-bg); color: var(--stop); }
.progbar { height: 8px; background: var(--rule-soft); border-radius: 6px; overflow: hidden; margin-top: 8px; }
.progbar i { display: block; height: 100%; background: var(--action); width: 0; transition: width .2s; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tab-h) + 22px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--navy); color: #fff; padding: 12px 18px; border-radius: 14px; font-size: 14.5px; z-index: 60; max-width: 90vw; box-shadow: var(--shadow-md); }
@media (min-width: 900px) { .toast { bottom: 28px; } }

@media print {
  .navbar, .tabbar, .sitefoot, .noprint { display: none !important; }
  body { background: #fff; }
  #app.wrap { padding: 0; max-width: none; }
  .card, .list { border: 1px solid #ccc; }
}
@media (prefers-reduced-motion: reduce) { .ring .val { transition: none; } }

.brandlock .mark{height:30px;width:auto;margin-right:2px}
.brandlock>span{border-left:1px solid var(--rule);padding-left:10px;line-height:1.15}
.auth-card .mark{height:44px;width:auto}
