/* Shared TV board design. Sized with --u (1vw on a TV, 1cqw in the app preview). */
.tvx{--g1:#f8dc86;--g2:#d9a53a;--gt:#f3c969;--a:#23252f;--b:#0b0c11;--c:#050609;position:relative;width:100%;height:100%;display:flex;flex-direction:column;justify-content:space-between;gap:calc(var(--u)*1.2);padding:calc(var(--u)*2.2) calc(var(--u)*3);color:#f6e7bf;font-family:Georgia,"Times New Roman",serif;overflow:hidden;background:radial-gradient(120% 120% at 20% 0,var(--a),var(--b) 60%,var(--c))}
.tvx.t-wine{--a:#7a2432;--b:#3b0f17;--c:#25080e}.tvx.t-emerald{--a:#12664b;--b:#0b3d2e;--c:#06251c}.tvx.t-navy{--a:#24408a;--b:#0f2147;--c:#08122a}
.tvx:before{content:"";position:absolute;right:-6%;top:18%;width:42%;aspect-ratio:1;background:radial-gradient(circle,rgba(243,201,105,.16),transparent 66%);pointer-events:none}
.tvx>*{position:relative}
.tvx-top{display:flex;justify-content:space-between;align-items:center;gap:calc(var(--u)*2)}
.tvx-brand{display:flex;align-items:center;gap:calc(var(--u)*1.6);min-width:0}
.tvx-brand svg,.tvx-brand img{height:calc(var(--u)*6.4);width:auto;max-width:calc(var(--u)*14);object-fit:contain;flex:none}
.tvx-shop{font-size:calc(var(--u)*3.6);font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--gt);line-height:1.05}
.tvx-tag{font-size:calc(var(--u)*1.2);letter-spacing:.3em;text-transform:uppercase;opacity:.85;margin-top:.4em}
.tvx-date{text-align:right;font-size:calc(var(--u)*1.6);white-space:nowrap}.tvx-date b{display:block;font-size:calc(var(--u)*3);color:#fff;line-height:1.15}
.tvx-bn{display:none;color:#fff;padding:calc(var(--u)*.6) calc(var(--u)*1.6);border-radius:6px;font-size:calc(var(--u)*1.5);font-family:system-ui,sans-serif;background:#a52a2a}
.tvx-bn.o{background:#b4531a}.tvx-bn.d{background:#8a6414}.tvx-bn.on{display:block}
.tvx-rates{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:calc(var(--u)*1.4)}
.tvx-c{border-radius:calc(var(--u)*.8);overflow:hidden;border:1px solid rgba(243,201,105,.55);background:rgba(8,9,13,.8);text-align:center;display:flex;flex-direction:column;box-shadow:0 calc(var(--u)*.6) calc(var(--u)*2) rgba(0,0,0,.4)}
.tvx-c h3{margin:0;padding:calc(var(--u)*.8) 0;background:linear-gradient(180deg,var(--g1),var(--g2));color:#1c1405;font-size:calc(var(--u)*2.8);line-height:1;font-weight:700}
.tvx-c h3 small{display:block;font-size:calc(var(--u)*1.25);font-weight:600;margin-top:.35em}
.tvx-c .ig{padding:calc(var(--u)*1.2) 0 calc(var(--u)*.2)}.tvx-c .ig svg{height:calc(var(--u)*5.5);width:auto}
.tvx-c b{font-size:calc(var(--u)*3.2);color:#fff;font-variant-numeric:lining-nums tabular-nums;white-space:nowrap;line-height:1.3}
.tvx-c i{font-style:normal;display:block;font-size:calc(var(--u)*1.2);opacity:.85;padding-bottom:calc(var(--u)*1)}
.tvx-s{display:flex;align-items:center;gap:calc(var(--u)*3);padding:calc(var(--u)*1.1) calc(var(--u)*3);border-radius:calc(var(--u)*.8);background:linear-gradient(180deg,#f3f5f8,#aab1bd);color:#14161c;font-family:system-ui,sans-serif}
.tvx-s svg{height:calc(var(--u)*5);width:auto;flex:none}.tvx-s small{display:block;font-size:calc(var(--u)*1.5);font-weight:700;letter-spacing:.04em}
.tvx-s b{font-size:calc(var(--u)*3.4);font-family:Georgia,serif;font-variant-numeric:lining-nums tabular-nums;white-space:nowrap}.tvx-s span{white-space:nowrap;font-size:calc(var(--u)*1.8);font-weight:600}
.tvx-e{text-align:center;font-size:calc(var(--u)*2.6);padding:calc(var(--u)*6) 0;opacity:.85}
.tvx-f{text-align:center;font-size:calc(var(--u)*1.8);color:var(--gt);min-height:calc(var(--u)*3.4);letter-spacing:.06em}
.tvx.hasbg{background:linear-gradient(rgba(5,6,9,.55),rgba(5,6,9,.82)),var(--bg) center/cover no-repeat,radial-gradient(120% 120% at 20% 0,var(--a),var(--b) 60%,var(--c))}
.tvx.live{height:100vh}
@media (orientation:portrait){.tvx.live .tvx-rates{grid-template-columns:1fr 1fr}.tvx.live .tvx-top{flex-wrap:wrap}}

/* picture layout: side photo, card photos, trust points */
.tvx-main{flex:1;display:grid;grid-template-columns:minmax(0,1fr);gap:calc(var(--u)*2);min-height:0}.tvx.hasside .tvx-main{grid-template-columns:minmax(0,3fr) minmax(0,1fr)}
.tvx-l{display:flex;flex-direction:column;justify-content:center;gap:calc(var(--u)*1.4);min-width:0}
.tvx-tag u{display:inline-block;width:calc(var(--u)*3);height:1px;background:currentColor;vertical-align:middle;margin:0 .9em;text-decoration:none;opacity:.8}.tvx-tag u:first-child{margin-left:0}
.tvx-c b{color:var(--gt)}.tvx-c i{color:#fff}
.tvx-c .ig.ph{padding:0;height:calc(var(--u)*9.5);background:#000}.tvx-c .ig.ph img{width:100%;height:100%;object-fit:cover;display:block}
.tvx.hasside .tvx-c b{font-size:calc(var(--u)*2.6)}.tvx.hasside .tvx-c h3{font-size:calc(var(--u)*2.4)}
.tvx-s img{height:calc(var(--u)*6.5);width:auto;max-width:calc(var(--u)*12);object-fit:contain;flex:none;mix-blend-mode:multiply}.tvx-s>div{display:flex;flex-direction:column}.tvx-s>div b{display:block}.tvx-s{gap:calc(var(--u)*2.4)}
.tvx-side{position:relative;border-radius:calc(var(--u)*.8);overflow:hidden;min-height:calc(var(--u)*20)}
.tvx-side img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;-webkit-mask-image:linear-gradient(to right,transparent,#000 28%);mask-image:linear-gradient(to right,transparent,#000 28%)}
.tvx-side .cap{position:absolute;left:0;right:0;bottom:calc(var(--u)*1);text-align:center;color:var(--gt);font-size:calc(var(--u)*1.7);letter-spacing:.1em;text-transform:uppercase;text-shadow:0 2px 8px #000}.tvx-side .cap span{display:block}.tvx-side .cap .b{font-size:calc(var(--u)*1.4)}
.tvx-pts{display:flex;justify-content:space-around;align-items:center;border-top:1px solid rgba(243,201,105,.5);padding-top:calc(var(--u)*1);font-size:calc(var(--u)*1.5);font-family:system-ui,sans-serif}
.tvx-pts span{display:flex;align-items:center;gap:calc(var(--u)*.8);flex:1;justify-content:center}.tvx-pts span+span{border-left:1px solid rgba(243,201,105,.35)}.tvx-pts svg{width:calc(var(--u)*2.4);height:calc(var(--u)*2.4);color:var(--gt);flex:none}
.tvx-f:empty{display:none}.tvx-f{border-top:0;padding-top:0;min-height:0}
@media (orientation:portrait){.tvx.live.hasside .tvx-main{grid-template-columns:1fr}.tvx.live .tvx-side{min-height:calc(var(--u)*30)}}

/* TV board polish, loaded after tvlayout.css. Same markup, sized with --u.
   Direction: a lit jeweller's display case. Gold-framed rate plates, foil numerals, metallic silver bar.
   Motion is limited to transform/opacity so low-end Android TVs stay smooth. Delete this file + its <link> to revert. */

.tvx {
    --foil: linear-gradient(180deg, #fff6cf 0%, #f3c969 45%, #c8942c 100%);
    --edge: rgba(243, 201, 105, .6);
}

/* ambient light: soft spotlight top-left, warm pool bottom-right, fine vignette */
.tvx:before {
    right: auto; left: -8%; top: -18%; width: 60%;
    background: radial-gradient(circle, rgba(255, 226, 150, .20), transparent 64%);
}
.tvx:after {
    content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 0;
    background:
        radial-gradient(60% 50% at 100% 100%, rgba(243, 201, 105, .10), transparent 70%),
        radial-gradient(120% 120% at 50% 50%, transparent 60%, rgba(0, 0, 0, .45) 100%);
}
.tvx > * { z-index: 1 }

/* inner gold frame */
.tvx-top { padding-bottom: calc(var(--u) * 1.2); position: relative }
.tvx-top:after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px;
    background: linear-gradient(90deg, transparent, var(--edge) 15%, #fff1bd 50%, var(--edge) 85%, transparent);
}

/* shop name in foil */
.tvx-shop {
    background: var(--foil); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
    filter: drop-shadow(0 calc(var(--u) * .15) calc(var(--u) * .6) rgba(0, 0, 0, .5));
    letter-spacing: .06em;
}
.tvx-tag { color: #f3dfa6; letter-spacing: .34em }
.tvx-date { padding-left: calc(var(--u) * 2); border-left: 1px solid var(--edge) }
.tvx-date b { text-shadow: 0 0 calc(var(--u) * 1.5) rgba(243, 201, 105, .35); font-variant-numeric: tabular-nums }

/* rate plates */
.tvx-rates { gap: calc(var(--u) * 1.6) }
.tvx-c {
    position: relative;
    border: 0;
    border-radius: calc(var(--u) * 1);
    padding: 2px;                                   /* the gold frame */
    background: linear-gradient(160deg, #fff1bd, #c8942c 40%, #6e4d12 62%, #f3c969);
    box-shadow: 0 calc(var(--u) * .8) calc(var(--u) * 2.4) rgba(0, 0, 0, .55), 0 0 calc(var(--u) * 2.4) rgba(243, 201, 105, .12);
}
.tvx-c > * { position: relative; z-index: 1 }
.tvx-c:before {                                      /* velvet face inside the frame */
    content: ""; position: absolute; inset: 2px; z-index: 0;
    border-radius: calc(var(--u) * .8);
    background:
        radial-gradient(90% 60% at 50% 0%, rgba(243, 201, 105, .16), transparent 70%),
        linear-gradient(180deg, #14151c, #07080c);
}
.tvx-c h3 {
    margin: 0; border-radius: calc(var(--u) * .8) calc(var(--u) * .8) 0 0;
    background: linear-gradient(180deg, #fff1bd 0%, #f3c969 40%, #d9a53a 100%);
    box-shadow: inset 0 -2px 0 rgba(110, 77, 18, .35), inset 0 1px 0 rgba(255, 255, 255, .7);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .5);
    letter-spacing: .02em;
}
.tvx-c h3 small { font-family: system-ui, sans-serif; letter-spacing: .12em; opacity: .8 }
.tvx-c .ig { filter: drop-shadow(0 calc(var(--u) * .4) calc(var(--u) * .6) rgba(0, 0, 0, .55)) }
.tvx-c b {
    background: var(--foil); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
    text-shadow: none; padding: calc(var(--u) * .2) 0;
    filter: drop-shadow(0 0 calc(var(--u) * .8) rgba(243, 201, 105, .30));
}
.tvx-c i { font-family: system-ui, sans-serif; letter-spacing: .14em; text-transform: none; color: #e7d6a4; opacity: .9 }

/* one slow sheen across the plates, transform only */
.tvx.live .tvx-c:after {
    content: ""; position: absolute; top: 2px; bottom: 2px; left: 0; width: 40%; z-index: 2; pointer-events: none;
    background: linear-gradient(100deg, transparent, rgba(255, 244, 200, .16), transparent);
    transform: translateX(-120%) skewX(-18deg);
    animation: tvsheen 9s ease-in-out infinite;
    will-change: transform;
}
body.lite .tvx.live .tvx-c:after { display: none }
.tvx.live .tvx-c:nth-child(2):after { animation-delay: .5s }
.tvx.live .tvx-c:nth-child(3):after { animation-delay: 1s }
.tvx.live .tvx-c:nth-child(4):after { animation-delay: 1.5s }
@keyframes tvsheen { 0%, 62% { transform: translateX(-120%) skewX(-18deg) } 100% { transform: translateX(380%) skewX(-18deg) } }

/* silver bar: brushed metal */
.tvx-s {
    position: relative; border-radius: calc(var(--u) * 1);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, .85) 0, rgba(255, 255, 255, 0) 45%),
        repeating-linear-gradient(90deg, #cfd5de 0 3px, #dfe4eb 3px 6px),
        linear-gradient(180deg, #eef1f5, #9aa3b1);
    box-shadow: 0 calc(var(--u) * .7) calc(var(--u) * 2) rgba(0, 0, 0, .45);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .6);
}
.tvx-s small { letter-spacing: .18em; color: #2c313b }
.tvx-s b { color: #0f1218 }
.tvx-s span { color: #2c313b }

/* footer promo + trust points */
.tvx-f { text-shadow: 0 0 calc(var(--u) * 1.2) rgba(243, 201, 105, .35); letter-spacing: .1em }
.tvx-pts { border-top: 0; position: relative }
.tvx-pts:before {
    content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--edge) 20%, var(--edge) 80%, transparent);
}

/* side photo gets a gold frame */
.tvx-side { box-shadow: 0 calc(var(--u) * .8) calc(var(--u) * 2.4) rgba(0, 0, 0, .5) }

/* banners read clearly on the dark board */
.tvx-bn { box-shadow: 0 calc(var(--u) * .4) calc(var(--u) * 1.4) rgba(0, 0, 0, .45); letter-spacing: .02em }

/* themes: richer faces */
.tvx.t-wine { --edge: rgba(243, 201, 105, .65) }
.tvx.t-emerald .tvx-c:before { background: radial-gradient(90% 60% at 50% 0%, rgba(243, 201, 105, .16), transparent 70%), linear-gradient(180deg, #0c2b21, #04140f) }
.tvx.t-wine .tvx-c:before { background: radial-gradient(90% 60% at 50% 0%, rgba(243, 201, 105, .16), transparent 70%), linear-gradient(180deg, #3a1018, #1a060a) }
.tvx.t-navy .tvx-c:before { background: radial-gradient(90% 60% at 50% 0%, rgba(243, 201, 105, .16), transparent 70%), linear-gradient(180deg, #14275a, #081330) }

@media (prefers-reduced-motion: reduce) { .tvx.live .tvx-c:after { animation: none; display: none } }

/* silver unit label sits at the right edge of the bar */
.tvx-s > span { margin-left: auto; padding-left: calc(var(--u) * 2); border-left: 1px solid rgba(44, 49, 59, .35) }

/* ---- fit-to-screen fixes (photo layout): the middle area absorbs spare/short height, header + footer never overlap ---- */
.tvx { gap: calc(var(--u) * 1) }
.tvx-top, .tvx-bn, .tvx-f, .tvx-pts { flex: none }
.tvx-main { flex: 1 1 0; min-height: 0; grid-template-rows: minmax(0, 1fr) }
.tvx-l { min-height: 0; height: 100% }
.tvx-rates { flex: 1 1 0; min-height: 0 }
.tvx-c { min-height: 0 }
.tvx-c .ig { flex: 1 1 0; min-height: 0; display: flex; align-items: center; justify-content: center; padding: calc(var(--u) * .6) 0 }
.tvx-c .ig.ph { padding: 0; height: auto; display: block; position: relative }
.tvx-c .ig.ph img { position: absolute; inset: 0 }
.tvx-c .ig svg { height: 70%; max-height: calc(var(--u) * 5.5) }
.tvx-c b { flex: none }
.tvx-c i { flex: none; padding-bottom: calc(var(--u) * .8) }
.tvx-s { flex: none }
.tvx-side { min-height: 0; height: 100% }
.tvx-top { padding-bottom: calc(var(--u) * .9) }

/* footer text must be readable on any background: it sits on its own dark strip */
.tvx-f { background: linear-gradient(90deg, transparent, rgba(0, 0, 0, .55) 15%, rgba(0, 0, 0, .55) 85%, transparent); padding: calc(var(--u) * .5) 0; border-radius: 999px }
.tvx-pts { background: rgba(0, 0, 0, .45); border-radius: calc(var(--u) * .8); padding: calc(var(--u) * .8) 0 }
.tvx-pts:before { display: none }

/* lining numerals (the photo theme font showed old-style figures like "20K") */
.tvx-c h3, .tvx-date, .tvx-c b, .tvx-s b { font-variant-numeric: lining-nums tabular-nums; font-feature-settings: "lnum" 1, "tnum" 1 }

/* photo behind the board: darker so gold text stays legible */
.tvx.hasbg { background: linear-gradient(rgba(5, 6, 9, .72), rgba(5, 6, 9, .9)), var(--bg) center/cover no-repeat, radial-gradient(120% 120% at 20% 0, var(--a), var(--b) 60%, var(--c)) }

/* ---- compact chrome so the photos get most of the height ---- */
.tvx { padding: calc(var(--u) * 1.3) calc(var(--u) * 2.4); gap: calc(var(--u) * .9) }
.tvx-brand svg, .tvx-brand img { height: calc(var(--u) * 5) }
.tvx-shop { font-size: calc(var(--u) * 3.2) }
.tvx-tag { font-size: calc(var(--u) * 1.05); margin-top: .2em }
.tvx-date { font-size: calc(var(--u) * 1.35) }
.tvx-date b { font-size: calc(var(--u) * 2.5) }
.tvx-top { padding-bottom: calc(var(--u) * .7) }
.tvx-rates { gap: calc(var(--u) * 1.2) }
.tvx-c h3, .tvx.hasside .tvx-c h3 { font-size: calc(var(--u) * 2.1); padding: calc(var(--u) * .5) 0 }
.tvx-c h3 small { display: inline; margin: 0 0 0 .6em; font-size: calc(var(--u) * 1) }
.tvx-c b, .tvx.hasside .tvx-c b { font-size: calc(var(--u) * 2.5); line-height: 1.2 }
.tvx-c i { font-size: calc(var(--u) * 1); padding-bottom: calc(var(--u) * .5) }
.tvx-c .ig.ph { min-height: calc(var(--u) * 9) }
.tvx-s { padding: calc(var(--u) * .6) calc(var(--u) * 2.4); gap: calc(var(--u) * 2) }
.tvx-s img { height: calc(var(--u) * 4.6) }
.tvx-s svg { height: calc(var(--u) * 3.6) }
.tvx-s small { font-size: calc(var(--u) * 1.15) }
.tvx-s b { font-size: calc(var(--u) * 2.7) }
.tvx-s span { font-size: calc(var(--u) * 1.5) }
.tvx-f { font-size: calc(var(--u) * 1.5); padding: calc(var(--u) * .3) 0 }
.tvx-pts { font-size: calc(var(--u) * 1.3); padding: calc(var(--u) * .5) 0 }
.tvx-pts svg { width: calc(var(--u) * 2); height: calc(var(--u) * 2) }
.tvx-side .cap { font-size: calc(var(--u) * 1.5) }

/* On-screen copy of a numeric LED rate board (7-segment digits). Sized by its container width. */
.ledw{container-type:inline-size;width:100%}
.ledb{background:#060606;color:#fff;border-radius:2.2cqw;padding:3.4cqw 4cqw;display:flex;flex-direction:column;gap:2.2cqw;font-family:Georgia,"Times New Roman",serif;border:.6cqw solid #1b1b1b;min-height:56cqw;justify-content:center}
.lb-title{text-align:center;font-weight:700;font-size:4.4cqw;letter-spacing:.04em;margin-bottom:.6cqw}
.lb-row,.lb-clock{display:grid;grid-template-columns:34% 1fr;align-items:center;gap:3cqw}
.lb-clock{grid-template-columns:auto 1fr auto 1.3fr;gap:2cqw;background:#0d0d0d;padding:1.2cqw 2cqw;border-radius:1cqw}
.lb-lab{font:700 3.3cqw/1.1 system-ui,sans-serif;color:#37e58a;text-transform:uppercase}
.lb-lab b{display:block;font-weight:700}.lb-lab small{display:block;font-size:2.8cqw;color:#9be9c0;font-weight:600}
.lb-clock .lb-lab{color:#f0c75a;font-size:2.6cqw}
.lb-dig{width:100%;height:auto;display:block;background:#120404;border-radius:.8cqw;padding:.5cqw .8cqw;transform:skewX(-6deg)}
.lb-dig polygon.on,.lb-dig circle.on{fill:#ff3030;filter:drop-shadow(0 0 .35cqw rgba(255,40,40,.85))}
.lb-dig polygon.off,.lb-dig circle.off{fill:#2b0b0b}
.lb-dig.sm{background:transparent;padding:0}

@font-face{font-family:'Prata';font-weight:400;font-style:normal;font-display:swap;src:url(fonts/prata-latin-400-normal.woff2) format('woff2')}
/* Gold Rate ERP: shared styles for phone, tablet and laptop.
   Idea: a jeweller's velvet tray (deep indigo), paper-white work surface, and BIS-style hallmark stamps
   (999 / 916 / 833 / 750) as the one memorable element. Everything else stays quiet. */

:root {
    --ink: #1a1919;
    --ink2: #2b2929;
    --ink3: #262525;
    --paper: #f6f6f4;
    --card: #ffffff;
    --line: #e9e8e5;
    --line2: #f3f2f0;
    --text: #1e1d1d;
    --mut: #6b6862;
    --gold: #a9883c;
    --gold-lt: #d9b96e;
    --gold-bg: #f8f1e2;
    --ok: #16795a;
    --ok-bg: #e3f4ec;
    --bad: #b3261e;
    --bad-bg: #fbe7e5;
    --warn: #8a6716;
    --warn-bg: #f9f0dc;
    --info: #363535;
    --info-bg: #f3f2ef;
    --r-card: 14px;
    --r-in: 10px;
    --sw: 244px;
    --tab: 64px;
    --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Noto Sans Devanagari", sans-serif;
    --serif: 'Prata', "Iowan Old Style", Georgia, serif;
}

* {
    box-sizing: border-box
}

html,
body {
    height: 100%
}

body {
    margin: 0;
    font: 15px/1.5 var(--sans);
    background: var(--paper);
    color: var(--text);
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent
}

[hidden] {
    display: none !important
}

h1,
h2,
h3 {
    margin: 0;
    line-height: 1.25
}

a {
    color: var(--info)
}

.ic {
    width: 1.2em;
    height: 1.2em;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex: none;
    vertical-align: -.22em
}

.logo {
    display: block;
    flex: none
}

.m {
    color: var(--mut);
    font-size: 13px
}

.ok {
    color: var(--ok)
}

.bad {
    color: var(--bad)
}

.warn {
    color: var(--warn)
}

.num {
    font-family: var(--serif);
    font-variant-numeric: tabular-nums lining-nums
}

:focus-visible {
    outline: 3px solid var(--gold-lt);
    outline-offset: 2px;
    border-radius: 6px
}


/* ---- form controls ---- */

input,
select,
textarea,
button {
    font: inherit;
    color: inherit
}

input,
select,
textarea {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid #d1d0ce;
    border-radius: var(--r-in);
    background: #ffffff
}

input[type=checkbox],
input[type=radio] {
    width: 20px;
    height: 20px;
    min-height: 0;
    padding: 0;
    accent-color: var(--ink2)
}

input[type=file] {
    padding: 8px;
    min-height: 0
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--ink3);
    box-shadow: 0 0 0 3px rgba(38, 37, 37, .18)
}

.fld {
    display: grid;
    gap: 5px;
    margin-bottom: 12px;
    font-weight: 600;
    font-size: 14px
}

.fld>.m {
    font-weight: 400
}

.fld.inline {
    grid-template-columns: 110px 1fr;
    align-items: center
}

.two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px
}

.err {
    color: var(--bad);
    min-height: 1.3em;
    font-size: 14px;
    margin: 4px 0 8px
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 18px;
    border-radius: var(--r-in);
    border: 1px solid #d1d0ce;
    background: #ffffff;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    text-decoration: none;
    color: var(--text)
}

.btn:hover {
    background: #f9f9f8
}

.btn:active {
    transform: translateY(1px)
}

.btn.pri {
    background: var(--ink);
    border-color: var(--ink);
    color: #ffffff
}

.btn.pri:hover {
    background: var(--ink2)
}

.btn.gold {
    background: linear-gradient(180deg, #e2c37b, #c59f48);
    border-color: #ae8a37;
    color: #201804
}

.btn.gold:hover {
    filter: brightness(1.05)
}

.btn.dng {
    background: var(--bad);
    border-color: var(--bad);
    color: #ffffff
}

.btn.ghost {
    border-color: transparent;
    background: transparent
}

.btn.ghost:hover {
    background: var(--line2)
}

.btn.sm {
    min-height: 34px;
    padding: 0 12px;
    font-size: 13px
}

.btn.block {
    width: 100%
}

.btn[disabled] {
    opacity: .55;
    cursor: not-allowed
}

.lnk {
    background: none;
    border: 0;
    padding: 6px 4px;
    color: var(--info);
    font-weight: 600;
    cursor: pointer;
    min-height: 34px
}

.lnk.bad {
    color: var(--bad)
}

.ib {
    width: 42px;
    height: 42px;
    display: inline-grid;
    place-items: center;
    border-radius: 11px;
    border: 1px solid transparent;
    background: transparent;
    cursor: pointer;
    padding: 0
}

.ib .ic {
    width: 22px;
    height: 22px
}


/* ---- chips and stamps ---- */

.chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 700;
    background: var(--line2);
    color: var(--mut);
    white-space: nowrap
}

.chip.ok {
    background: var(--ok-bg);
    color: var(--ok)
}

.chip.bad {
    background: var(--bad-bg);
    color: var(--bad)
}

.chip.warn {
    background: var(--warn-bg);
    color: var(--warn)
}

.chip.info {
    background: var(--info-bg);
    color: var(--info)
}

.stamp {
    display: inline-block;
    padding: 1px 6px;
    border: 1.5px solid currentColor;
    border-radius: 3px;
    box-shadow: 0 0 0 2px var(--card), 0 0 0 3px currentColor;
    font: 700 11px/1.3 var(--sans);
    letter-spacing: .06em;
    color: var(--gold);
    margin: 3px
}


/* ---- cards, grid, tables ---- */

.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--r-card);
    padding: 18px;
    min-width: 0
}

.card>h2,
.card-h h2 {
    font-size: 16px;
    font-weight: 700
}

.card-h {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
    flex-wrap: wrap
}

.card-h .m {
    margin-top: 2px
}

.grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 16px
}

.s3 {
    grid-column: span 3
}

.s4 {
    grid-column: span 4
}

.s5 {
    grid-column: span 5
}

.s6 {
    grid-column: span 6
}

.s7 {
    grid-column: span 7
}

.s8 {
    grid-column: span 8
}

.s12 {
    grid-column: span 12
}

@media(max-width:1100px) {
    .grid>* {
        grid-column: span 12
    }
}

.row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center
}

.row.end {
    justify-content: flex-end
}

.sp {
    flex: 1
}

.stack>*+* {
    margin-top: 12px
}

.tw {
    overflow-x: auto;
    margin: 0 -6px
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px
}

th {
    font-weight: 600;
    color: var(--mut);
    text-align: left;
    font-size: 13px;
    padding: 8px 10px;
    border-bottom: 1px solid var(--line);
    white-space: nowrap
}

td {
    padding: 11px 10px;
    border-bottom: 1px solid var(--line2);
    vertical-align: middle
}

tr:last-child td {
    border-bottom: 0
}

tbody tr.click {
    cursor: pointer
}

tbody tr.click:hover {
    background: #fcfbfa
}

td .m {
    display: block
}

.empty {
    padding: 28px 12px;
    text-align: center;
    color: var(--mut)
}

.empty b {
    display: block;
    color: var(--text);
    margin-bottom: 4px
}

.meter {
    height: 8px;
    border-radius: 99px;
    background: var(--line2);
    overflow: hidden
}

.meter i {
    display: block;
    height: 100%;
    background: var(--ink3);
    border-radius: 99px
}

.meter.full i {
    background: var(--bad)
}

.meter.near i {
    background: var(--gold)
}


/* ---- KPI + rate strip ---- */

.kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(155px, 1fr));
    gap: 12px;
    margin-bottom: 16px
}

.kpi {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--r-card);
    padding: 14px 16px;
    min-width: 0
}

.kpi small {
    display: block;
    color: var(--mut);
    font-size: 13px
}

.kpi b {
    display: block;
    font-size: 24px;
    line-height: 1.2;
    margin-top: 2px;
    font-weight: 700;
    font-variant-numeric: tabular-nums
}

.kpi span {
    font-size: 12.5px;
    color: var(--mut)
}

.strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;
    background: var(--ink);
    color: #ffffff;
    border-radius: var(--r-card);
    overflow: hidden;
    margin-bottom: 16px
}

.strip>div {
    padding: 16px 16px 14px;
    border-left: 1px solid rgba(255, 255, 255, .1);
    min-width: 0
}

.strip>div:first-child {
    border-left: 0
}

.mini .stamp {
    color: var(--gold-lt);
    box-shadow: 0 0 0 2px #111111, 0 0 0 3px var(--gold-lt);
    margin: 3px 8px 3px 3px
}

.strip .stamp {
    color: var(--gold-lt);
    box-shadow: 0 0 0 2px var(--ink), 0 0 0 3px var(--gold-lt);
    margin: 3px 5px 3px 3px
}

.strip small {
    color: #c7c6c4;
    font-size: 13px
}

.strip b {
    display: block;
    font: 600 26px/1.15 var(--serif);
    font-variant-numeric: tabular-nums lining-nums;
    margin-top: 6px;
    white-space: nowrap
}

.strip em {
    font-style: normal;
    font-size: 12.5px;
    color: #c7c6c4
}

.strip.empty-s {
    grid-template-columns: 1fr;
    padding: 20px;
    text-align: center;
    color: #c7c6c4
}

@media(max-width:900px) {
    .strip {
        grid-template-columns: 1fr 1fr
    }
    .strip>div {
        border-left: 0;
        border-top: 1px solid rgba(255, 255, 255, .1)
    }
    .strip>div:nth-child(-n+2) {
        border-top: 0
    }
    .strip>div:nth-child(even) {
        border-left: 1px solid rgba(255, 255, 255, .1)
    }
    .strip>div:last-child {
        grid-column: span 2;
        border-left: 0
    }
    .strip b {
        font-size: 23px
    }
}


/* ---- banner ---- */

.bn {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 16px;
    background: var(--info-bg);
    color: #262525;
    border: 1px solid #e5e4dd
}

.bn.warn {
    background: var(--warn-bg);
    color: #523c0a;
    border-color: #e8d7ae
}

.bn.bad {
    background: var(--bad-bg);
    color: #7a1a14;
    border-color: #f3c5c1
}

.bn .ic {
    width: 22px;
    height: 22px
}

.bn .tx {
    flex: 1;
    min-width: 0
}

.bn b {
    display: block
}


/* ---- auth ---- */

#auth {
    min-height: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr)
}

.hero {
    position: relative;
    overflow: hidden;
    background: var(--ink);
    color: #ffffff;
    padding: 56px clamp(32px, 5vw, 80px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 28px
}

.hero:before {
    content: "";
    position: absolute;
    inset: auto -140px -160px auto;
    width: 460px;
    height: 460px;
    border-radius: 50%;
    border: 1px solid rgba(217, 185, 110, .22);
    box-shadow: 0 0 0 70px rgba(217, 185, 110, .04), 0 0 0 140px rgba(217, 185, 110, .03)
}

.hero>* {
    position: relative
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px
}

.brand .logo {
    width: 44px;
    height: 44px
}

.brand b {
    font: 700 20px/1.1 var(--serif);
    color: var(--gold-lt)
}

.hero h1 {
    font: 600 clamp(30px, 3.4vw, 46px)/1.12 var(--serif);
    max-width: 15em;
    letter-spacing: -.01em
}

.hero p {
    margin: 0;
    max-width: 30em;
    color: #dfdedb;
    font-size: 17px;
    line-height: 1.55
}

.mini {
    max-width: 460px;
    border-radius: 16px;
    background: #111111;
    border: 1px solid rgba(255, 255, 255, .12);
    padding: 16px 18px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, .35)
}

.mini .top {
    display: flex;
    justify-content: space-between;
    color: #c7c6c4;
    font-size: 12.5px;
    margin-bottom: 10px
}

.mini .r {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding: 9px 0;
    border-top: 1px solid rgba(255, 255, 255, .08)
}

.mini .r span {
    color: #dfdedb
}

.mini .r b {
    font: 600 24px var(--serif);
    color: var(--gold-lt);
    font-variant-numeric: tabular-nums
}

.pts {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
    color: #edede8
}

.pts li {
    display: flex;
    gap: 10px;
    align-items: center
}

.pts .ic {
    color: var(--gold-lt)
}

.formside {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 24px;
    background: var(--card)
}

.formbox {
    width: 100%;
    max-width: 400px
}

.formbox h2 {
    font-size: 26px;
    margin-bottom: 4px
}

.seg {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    background: var(--line2);
    border-radius: 12px;
    padding: 4px;
    margin: 0 0 20px;
    gap: 4px
}

.seg button {
    border: 0;
    background: transparent;
    min-height: 40px;
    border-radius: 9px;
    font-weight: 600;
    color: var(--mut);
    cursor: pointer
}

.seg button.on {
    background: #ffffff;
    color: var(--text);
    box-shadow: 0 1px 3px rgba(26, 25, 25, .15)
}

.seg.in {
    display: inline-grid;
    margin: 0
}

.fine {
    font-size: 13px;
    color: var(--mut);
    margin-top: 16px
}

.legal {
    display: flex;
    gap: 6px;
    align-items: flex-start;
    font-size: 13.5px;
    font-weight: 400;
    color: var(--mut)
}

.legal input {
    margin-top: 2px
}

@media(max-width:900px) {
    #auth {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
        background: var(--ink)
    }
    .hero {
        padding: calc(28px + env(safe-area-inset-top)) 24px 36px;
        gap: 0;
        align-items: center;
        text-align: center
    }
    .hero:before,
    .hero h1,
    .hero p,
    .mini,
    .pts {
        display: none
    }
    .brand {
        flex-direction: column;
        gap: 10px
    }
    .brand .logo {
        width: 64px;
        height: 64px
    }
    .brand b {
        font-size: 24px
    }
    .tag {
        display: block !important;
        color: #d4d3d0;
        margin-top: 6px;
        font-size: 14px
    }
    .formside {
        align-items: flex-start;
        border-radius: 24px 24px 0 0;
        padding: 24px 20px calc(28px + env(safe-area-inset-bottom))
    }
}

.tag {
    display: none
}


/* ---- app shell ---- */

#sb {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sw);
    background: var(--ink);
    color: #e6e5de;
    display: flex;
    flex-direction: column;
    z-index: 20
}

.sbh {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 18px 16px 16px
}

.sbh .logo {
    width: 38px;
    height: 38px
}

.sbh b {
    display: block;
    color: var(--gold-lt);
    font: 700 16px/1.2 var(--serif);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 158px
}

.sbh span {
    font-size: 12.5px;
    color: #a8a39a
}

#nav {
    flex: 1;
    overflow: auto;
    padding: 4px 10px 12px
}

.ng {
    font-size: 12.5px;
    color: #8f8a80;
    padding: 16px 10px 5px;
    font-weight: 600
}

#nav a {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 9px 10px;
    border-radius: 10px;
    color: inherit;
    text-decoration: none;
    margin: 1px 0;
    font-weight: 500
}

#nav a:hover {
    background: rgba(255, 255, 255, .07)
}

#nav a.on {
    background: var(--ink3);
    color: #ffffff;
    font-weight: 600;
    box-shadow: inset 3px 0 0 var(--gold-lt)
}

#nav .ic {
    width: 19px;
    height: 19px
}

.bd {
    margin-left: auto;
    min-width: 20px;
    text-align: center;
    background: var(--gold-lt);
    color: var(--ink);
    border-radius: 99px;
    padding: 0 6px;
    font-size: 12px;
    font-weight: 800
}

.sbf {
    padding: 12px 14px 16px;
    border-top: 1px solid rgba(255, 255, 255, .09);
    font-size: 13.5px;
    display: flex;
    align-items: center;
    gap: 10px
}

.av {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--ink3);
    color: var(--gold-lt);
    display: grid;
    place-items: center;
    font-weight: 700;
    flex: none
}

.sbf .w {
    min-width: 0;
    flex: 1
}

.sbf .w b {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #ffffff
}

.sbf .w span {
    color: #a8a39a;
    font-size: 12.5px;
    text-transform: capitalize
}

.sbf button {
    color: #e6e5de
}

.sbf button:hover {
    background: rgba(255, 255, 255, .08)
}

#mn {
    margin-left: var(--sw);
    min-height: 100%
}

#hd {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 28px;
    background: rgba(246, 246, 244, .92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
    min-height: 64px
}

#hd h1 {
    font-size: 21px;
    font-weight: 700
}

#hd .back {
    display: none
}

.hlogo {
    display: none
}

#view {
    max-width: 1360px;
    margin: 0 auto;
    padding: 24px 28px 60px
}

#hd select {
    width: auto;
    min-height: 38px;
    padding: 6px 10px
}

#tabs {
    display: none
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 99px;
    font-weight: 700;
    font-size: 13px;
    background: var(--gold-bg);
    color: #604912;
    border: 1px solid #e4d3ac;
    text-decoration: none;
    cursor: pointer
}

.pill.bad {
    background: var(--bad-bg);
    color: var(--bad);
    border-color: #f3c5c1
}

.pill.ok {
    background: var(--ok-bg);
    color: var(--ok);
    border-color: #bfe3d3
}

.pg {
    margin-bottom: 18px
}

.pg p {
    margin: 2px 0 0;
    color: var(--mut)
}

.pg h2 {
    font-size: 24px
}

@media(max-width:900px) {
    #sb {
        display: none
    }
    #mn {
        margin-left: 0;
        padding-bottom: calc(var(--tab) + env(safe-area-inset-bottom))
    }
    #hd {
        background: var(--ink);
        color: #ffffff;
        border-bottom: 0;
        padding: calc(8px + env(safe-area-inset-top)) 10px 8px 14px;
        min-height: 56px
    }
    #hd h1 {
        font-size: 18px;
        color: #ffffff;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap
    }
    #hd .ib {
        color: #ffffff
    }
    #hd select {
        background: #2b2929;
        color: #ffffff;
        border-color: rgba(255, 255, 255, .25);
        max-width: 46vw
    }
    #hd .back {
        display: inline-grid
    }
    body.top #hd .back {
        display: none
    }
    body.top #hd .hlogo {
        display: block;
        width: 34px;
        height: 34px
    }
    #view {
        padding: 16px 14px 28px
    }
    #tabs {
        display: flex;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 30;
        height: calc(var(--tab) + env(safe-area-inset-bottom));
        padding-bottom: env(safe-area-inset-bottom);
        background: #ffffff;
        border-top: 1px solid var(--line)
    }
    #tabs a {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2px;
        color: var(--mut);
        text-decoration: none;
        font-size: 12px;
        font-weight: 600;
        position: relative;
        min-width: 0
    }
    #tabs a .ic {
        width: 24px;
        height: 24px
    }
    #tabs a.on {
        color: var(--ink)
    }
    #tabs a.on:before {
        content: "";
        position: absolute;
        top: 0;
        width: 28px;
        height: 3px;
        border-radius: 0 0 3px 3px;
        background: var(--gold)
    }
    #tabs .bd {
        position: absolute;
        top: 6px;
        left: calc(50% + 8px);
        margin: 0
    }
    .pg h2 {
        display: none
    }
    .pg:not(:has(p, .btn)) {
        display: none
    }
    .pg {
        margin-bottom: 14px
    }
    .card {
        padding: 16px
    }
    .two {
        grid-template-columns: 1fr
    }
    .fld.inline {
        grid-template-columns: 1fr
    }
    .kpis {
        grid-template-columns: 1fr 1fr
    }
    .kpi b {
        font-size: 21px
    }
    .hide-m {
        display: none !important
    }
}

@media(min-width:901px) {
    .only-m {
        display: none !important
    }
}


/* tables become cards on phones */

@media(max-width:760px) {
    .tw {
        margin: 0;
        overflow: visible
    }
    table,
    tbody {
        display: block
    }
    thead {
        display: none
    }
    tr {
        display: block;
        border: 1px solid var(--line);
        border-radius: 12px;
        padding: 6px 12px;
        margin-bottom: 10px;
        background: #ffffff
    }
    td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 6px 14px;
        flex-wrap: wrap;
        border: 0;
        padding: 6px 0;
        text-align: right
    }
    td::before {
        content: attr(data-label);
        color: var(--mut);
        font-weight: 600;
        font-size: 13px;
        text-align: left;
        flex: none
    }
    td[data-label=""] {
        justify-content: flex-end
    }
    td[data-label=""]::before {
        display: none
    }
    td.main {
        display: block;
        text-align: left;
        font-weight: 600;
        font-size: 15px;
        padding-top: 8px
    }
    td.main::before {
        display: none
    }
}


/* ---- More page rows ---- */

.rows {
    border: 1px solid var(--line);
    border-radius: var(--r-card);
    background: #ffffff;
    overflow: hidden;
    margin-bottom: 16px
}

.rows a,
.rows button {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    min-height: 54px;
    padding: 10px 16px;
    border: 0;
    border-top: 1px solid var(--line2);
    background: none;
    text-decoration: none;
    color: var(--text);
    font-weight: 600;
    text-align: left;
    cursor: pointer
}

.rows>:first-child {
    border-top: 0
}

.rows .ic {
    color: var(--ink3)
}

.rows .chev {
    margin-left: auto;
    color: var(--mut)
}


/* ---- plans ---- */

.plans {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 14px
}

.plan {
    border: 1px solid var(--line);
    border-radius: var(--r-card);
    padding: 18px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    gap: 10px
}

.plan.cur {
    border-color: var(--ink3);
    box-shadow: 0 0 0 2px var(--ink3) inset
}

.plan.rec {
    border-color: var(--gold)
}

.plan h3 {
    font-size: 18px;
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap
}

.plan .pr {
    font: 600 30px/1.1 var(--serif);
    font-variant-numeric: lining-nums
}

.plan .pr small {
    font: 500 14px var(--sans);
    color: var(--mut)
}

.plan ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 7px;
    font-size: 14px;
    flex: 1
}

.plan li {
    display: flex;
    gap: 8px;
    align-items: flex-start
}

.plan li .ic {
    color: var(--ok);
    margin-top: 3px
}

.plan li.no {
    color: var(--mut)
}

.plan li.no .ic {
    color: var(--mut)
}

.use {
    display: grid;
    gap: 12px
}

.use .l {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    margin-bottom: 5px
}


/* ---- chart ---- */

.bars {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    height: 170px;
    padding-top: 8px
}

.bars .b {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    height: 100%;
    gap: 6px;
    min-width: 0
}

.bars .b i {
    display: block;
    width: 100%;
    max-width: 56px;
    background: var(--ink3);
    border-radius: 6px 6px 0 0;
    min-height: 3px
}

.bars .b.now i {
    background: var(--gold)
}

.bars .b span {
    font-size: 12.5px;
    color: var(--mut)
}

.bars .b em {
    font-style: normal;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap
}


/* ---- modal / sheet ---- */

#ov {
    position: fixed;
    inset: 0;
    background: rgba(19, 19, 19, .55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 100
}

.md {
    background: #ffffff;
    border-radius: 18px;
    width: 100%;
    max-width: 520px;
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .4)
}

.md.wide {
    max-width: 760px
}

.md header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 18px 10px
}

.md header h2 {
    font-size: 19px;
    flex: 1
}

.md .bd2 {
    padding: 4px 18px 16px;
    overflow: auto
}

.md footer {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 12px 18px calc(14px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line2);
    flex-wrap: wrap
}

@media(max-width:700px) {
    #ov {
        align-items: flex-end;
        padding: 0
    }
    .md,
    .md.wide {
        max-width: none;
        border-radius: 20px 20px 0 0;
        max-height: 92vh;
        animation: up .2s ease-out
    }
    .md footer .btn {
        flex: 1
    }
}

@keyframes up {
    from {
        transform: translateY(40px);
        opacity: .4
    }
    to {
        transform: none;
        opacity: 1
    }
}

.ok-mark {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: var(--ok);
    color: #ffffff;
    display: grid;
    place-items: center;
    margin: 6px auto 12px
}

.ok-mark .ic {
    width: 34px;
    height: 34px;
    stroke-width: 2.6
}

.ctr {
    text-align: center
}

#toast {
    position: fixed;
    left: 50%;
    bottom: calc(24px + env(safe-area-inset-bottom));
    transform: translateX(-50%);
    padding: 11px 18px;
    border-radius: 12px;
    color: #ffffff;
    background: var(--ink);
    z-index: 200;
    max-width: 90vw;
    font-weight: 600;
    display: none
}

#toast.bad {
    background: var(--bad)
}

#toast.ok {
    background: var(--ok)
}

@media(max-width:900px) {
    #toast {
        bottom: calc(var(--tab) + 16px + env(safe-area-inset-bottom))
    }
}

.tvw {
    --u: 1cqw;
    container-type: inline-size;
    border-radius: 10px;
    overflow: hidden
}

.tvw .tvx {
    aspect-ratio: 16/9
}

.ip {
    display: grid;
    gap: 3px;
    margin-bottom: 10px;
    font-weight: 600
}

.ip .m {
    font-weight: 400
}

.kv {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 8px 12px;
    font-size: 14px
}

.kv dt {
    color: var(--mut)
}

.kv dd {
    margin: 0;
    word-break: break-word
}

.codebox {
    font: 700 34px var(--serif);
    letter-spacing: .3em;
    text-align: center;
    padding: 14px;
    background: var(--gold-bg);
    border-radius: 12px;
    margin: 10px 0
}

@media(prefers-reduced-motion:reduce) {
    * {
        animation: none !important;
        transition: none !important
    }
}

@media(max-width:520px) {
    .bn {
        flex-wrap: wrap
    }
    .bn .tx {
        flex-basis: calc(100% - 40px)
    }
    .bn .btn {
        width: 100%
    }
}
/* ---- Publish page: rate plates + live TV preview ---- */
.pubgrid { align-items: start }
.pubprev { position: sticky; top: 84px }
.rt-list { display: grid; gap: 10px; margin-bottom: 16px }
.rt {
    display: grid; grid-template-columns: 112px minmax(0, 1fr) minmax(104px, auto); align-items: center; gap: 6px 14px;
    padding: 10px 14px; border: 1px solid var(--line); border-radius: 14px; background: linear-gradient(180deg, #ffffff, #faf9f7);
    transition: border-color .2s, box-shadow .2s; margin: 0; cursor: text
}
.rt:focus-within { border-color: var(--gold); box-shadow: 0 0 0 4px rgba(217, 185, 110, .25) }
.rt-k { display: flex; align-items: center; gap: 10px; min-width: 0 }
.rt-k b { font: 700 24px/1 var(--serif); color: var(--ink) }
.rt-k .stamp { margin: 3px }
.rt-in { display: flex; align-items: center; gap: 8px; min-width: 0 }
.rt-in i { font: 600 22px var(--serif); font-style: normal; color: var(--gold) }
.rt-in input {
    border: 0; background: transparent; box-shadow: none; padding: 4px 0; min-height: 44px;
    font: 600 30px/1.1 var(--serif); font-variant-numeric: lining-nums tabular-nums; letter-spacing: -.01em; color: var(--text); min-width: 0
}
.rt-in input:focus { box-shadow: none; border: 0; outline: none }
.rt-in input::placeholder { color: #cbcbc9 }
.rt-in select { width: auto; min-height: 36px; padding: 4px 8px; font-size: 14px; flex: none }
.rt-d { font-size: 13px; font-weight: 700; text-align: right; color: var(--mut); white-space: nowrap }
.rt-d.up { color: var(--ok) }
.rt-d.dn { color: var(--bad) }
.pub-opts { margin-top: 4px }
.pubgo { min-height: 52px; font-size: 16px }
@media(max-width:700px) {
    .pubprev { position: static; order: 2 }
    .rt { grid-template-columns: 1fr auto; padding: 10px 12px }
    .rt-in { grid-column: 1 / -1; grid-row: 2 }
    .rt-d { grid-row: 1; grid-column: 2 }
    .rt-in input { font-size: 28px }
}

/* Gold Rate ERP: "fancy" polish layer. Loaded after app.css; delete this file + its <link> to revert.
   Direction: velvet tray + gold foil. Depth, foil sheen on the rate strip, a live pulse, softer motion. */

:root {
    --foil: linear-gradient(135deg, #f9ebca 0%, #d9b96e 38%, #a9883c 62%, #ebd299 100%);
    --foil-soft: linear-gradient(135deg, rgba(217, 185, 110, .22), rgba(169, 136, 60, .06));
    --velvet: radial-gradient(120% 90% at 0% 0%, #2d2c2c 0%, #2b2929 38%, #1a1919 100%);
    --sh1: 0 1px 2px rgba(26, 25, 25, .06), 0 4px 14px rgba(26, 25, 25, .06);
    --sh2: 0 2px 4px rgba(26, 25, 25, .06), 0 14px 34px rgba(26, 25, 25, .12);
    --ease: cubic-bezier(.2, .8, .2, 1);
}

body {
    background:
        radial-gradient(900px 420px at 100% -10%, rgba(217, 185, 110, .13), transparent 60%),
        radial-gradient(700px 400px at -10% 110%, rgba(38, 37, 37, .10), transparent 60%),
        var(--paper);
    background-attachment: fixed;
}

/* ---------- cards ---------- */
.card, .kpi, .plan, .rows {
    border-color: rgba(233, 232, 229, .9);
    box-shadow: var(--sh1);
    transition: box-shadow .25s var(--ease), transform .25s var(--ease), border-color .25s;
}
.card:hover, .kpi:hover, .plan:hover { box-shadow: var(--sh2); }
.kpi { position: relative; overflow: hidden; }
.kpi:before {
    content: ""; position: absolute; inset: 0 auto 0 0; width: 3px;
    background: var(--foil); opacity: .9;
}
.kpi b { letter-spacing: -.01em; }
.card-h h2, .card > h2 { letter-spacing: -.005em; }

/* ---------- rate strip: gold foil on velvet ---------- */
.strip {
    position: relative;
    background: var(--velvet);
    box-shadow: 0 18px 40px rgba(26, 25, 25, .28), inset 0 1px 0 rgba(255, 255, 255, .08);
    border: 1px solid rgba(217, 185, 110, .22);
    isolation: isolate;
}
.strip:before {              /* slow foil sweep, one calm moving highlight */
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(100deg, transparent 35%, rgba(245, 225, 178, .10) 50%, transparent 65%);
    transform: translateX(-100%); will-change: transform;
    animation: sweep 7s var(--ease) 1.2s infinite;
}
.strip b {
    background: var(--foil);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
    text-shadow: none;
    filter: drop-shadow(0 1px 8px rgba(217, 185, 110, .25));
}
.strip > div { transition: background .25s; }
.strip > div:hover { background: rgba(255, 255, 255, .04); }
@keyframes sweep { 0%, 55% { transform: translateX(-100%) } 100% { transform: translateX(100%) } }

/* ---------- buttons ---------- */
.btn { transition: transform .15s var(--ease), box-shadow .2s, background .2s, filter .2s; }
.btn:hover { box-shadow: 0 6px 16px rgba(26, 25, 25, .12); transform: translateY(-1px); }
.btn:active { transform: translateY(1px); box-shadow: none; }
.btn.pri {
    background: linear-gradient(180deg, #222121, #1a1919);
    box-shadow: 0 1px 0 rgba(255, 255, 255, .12) inset, 0 6px 16px rgba(26, 25, 25, .28);
}
.btn.pri:hover { background: linear-gradient(180deg, #2b2a2a, #222121); }
.btn.gold {
    position: relative; overflow: hidden;
    background: var(--foil);
    border-color: #a9883c;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .6) inset, 0 8px 20px rgba(169, 136, 60, .35);
    text-shadow: 0 1px 0 rgba(255, 255, 255, .35);
}
.btn.gold:after {
    content: ""; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .55), transparent);
    transform: skewX(-20deg); transition: left .6s var(--ease);
}
.btn.gold:hover:after { left: 120%; }

/* ---------- inputs ---------- */
input, select, textarea { transition: border-color .2s, box-shadow .2s, background .2s; }
input:focus, select:focus, textarea:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(217, 185, 110, .28);
}

/* ---------- chips, pills ---------- */
.chip, .pill { box-shadow: inset 0 0 0 1px rgba(26, 25, 25, .04); }
.chip.ok:before, .pill.ok:before {      /* live heartbeat on "online/confirmed" */
    content: ""; width: 7px; height: 7px; border-radius: 50%;
    background: currentColor; box-shadow: 0 0 0 0 currentColor;
    animation: beat 2.2s ease-out infinite;
}
@keyframes beat { 0%, 100% { opacity: 1; transform: scale(1) } 50% { opacity: .4; transform: scale(.65) } }

/* ---------- tables ---------- */
th { text-transform: none; background: linear-gradient(180deg, #fdfdfc, #f8f8f6); }
th:first-child { border-top-left-radius: 8px; }
th:last-child { border-top-right-radius: 8px; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: #fcfbfa; }

/* ---------- sidebar ---------- */
#sb {
    background:
        radial-gradient(140% 60% at 0% 0%, rgba(217, 185, 110, .10), transparent 55%),
        linear-gradient(180deg, #222121 0%, #1a1919 55%, #141313 100%);
    box-shadow: 6px 0 30px rgba(26, 25, 25, .18);
    border-right: 1px solid rgba(217, 185, 110, .10);
}
.sbh { border-bottom: 1px solid rgba(255, 255, 255, .06); margin-bottom: 4px; }
.sbh b, .brand b {
    background: var(--foil); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
}
#nav a { transition: background .2s, transform .2s var(--ease), color .2s; }
#nav a:hover { transform: translateX(2px); background: rgba(255, 255, 255, .08); }
#nav a.on {
    background: linear-gradient(90deg, rgba(217, 185, 110, .20), rgba(38, 37, 37, .85) 60%);
    box-shadow: inset 3px 0 0 var(--gold-lt), 0 6px 16px rgba(0, 0, 0, .25);
}
.av { background: var(--foil); color: #251c05; box-shadow: 0 0 0 2px rgba(217, 185, 110, .35); }

/* ---------- header ---------- */
#hd { box-shadow: 0 1px 0 rgba(26, 25, 25, .04), 0 10px 30px rgba(26, 25, 25, .04); backdrop-filter: blur(8px); }
#hd h1 { letter-spacing: -.01em; }

/* ---------- sign-in hero ---------- */
.hero { background: var(--velvet); }
.hero:after {                       /* faint hallmark ring pattern */
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background:
        radial-gradient(circle at 18% 22%, rgba(217, 185, 110, .10), transparent 28%),
        repeating-radial-gradient(circle at 85% 110%, transparent 0 38px, rgba(217, 185, 110, .045) 38px 39px);
}
.hero h1 { text-shadow: 0 2px 24px rgba(0, 0, 0, .35); }
.mini {
    position: relative; overflow: hidden;
    background: linear-gradient(160deg, #191818, #0e0d0d);
    border: 1px solid rgba(217, 185, 110, .28);
    box-shadow: 0 30px 70px rgba(0, 0, 0, .5), 0 0 0 1px rgba(255, 255, 255, .03) inset, 0 0 60px rgba(217, 185, 110, .08);
    animation: rise .9s var(--ease) both;
}
.mini:after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(105deg, transparent 40%, rgba(245, 225, 178, .12) 50%, transparent 60%);
    transform: translateX(-100%); will-change: transform; animation: sweep 6s var(--ease) 1.5s infinite;
}
.mini .r b {
    background: var(--foil); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
}
.mini .top span:last-child {
    color: #7be0b3; display: inline-flex; align-items: center; gap: 6px;
}
.mini .top span:last-child:before {
    content: ""; width: 7px; height: 7px; border-radius: 50%; background: #3ddc97;
    animation: beat2 2s ease-out infinite;
}
@keyframes beat2 { 0%, 100% { opacity: 1; transform: scale(1) } 50% { opacity: .4; transform: scale(.65) } }
@keyframes rise { from { opacity: 0; transform: translateY(12px) } to { opacity: 1; transform: none } }

.formside { background: radial-gradient(80% 60% at 100% 0%, #fcf6e9 0%, #ffffff 55%); }
.formbox { animation: rise .7s var(--ease) .1s both; }
.seg { box-shadow: inset 0 1px 3px rgba(26, 25, 25, .08); }
.seg button { transition: background .2s, box-shadow .2s, color .2s; }
.seg button.on { box-shadow: 0 2px 8px rgba(26, 25, 25, .15); }

/* ---------- plans ---------- */
.plan.rec { border-color: #c59f48; background: linear-gradient(180deg, #fdfaf2, #ffffff 40%); box-shadow: 0 10px 30px rgba(169, 136, 60, .18); }
.plan.cur { box-shadow: 0 0 0 2px var(--ink3) inset, var(--sh2); }
.plan .pr {
    background: linear-gradient(180deg, #222121, #1a1919); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
}

/* ---------- charts + meters ---------- */
.meter { box-shadow: inset 0 1px 2px rgba(26, 25, 25, .1); }
.meter i { background: linear-gradient(90deg, #262525, #434141); transition: width .8s var(--ease); }
.meter.near i { background: var(--foil); }
.bars .b i { background: linear-gradient(180deg, #434141, #262525); transition: height .8s var(--ease); }
.bars .b.now i { background: var(--foil); box-shadow: 0 6px 16px rgba(169, 136, 60, .35); }

/* ---------- modal, toast ---------- */
#ov { backdrop-filter: blur(6px); background: rgba(19, 19, 19, .5); animation: fade .2s ease-out; }
.md { box-shadow: 0 40px 100px rgba(15, 15, 15, .5), 0 0 0 1px rgba(255, 255, 255, .4) inset; animation: pop .28s var(--ease); }
@keyframes fade { from { opacity: 0 } to { opacity: 1 } }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.97) } to { opacity: 1; transform: none } }
#toast { box-shadow: 0 14px 40px rgba(26, 25, 25, .35); border: 1px solid rgba(255, 255, 255, .12); backdrop-filter: blur(8px); }
.ok-mark { background: linear-gradient(135deg, #1f9f78, #16795a); box-shadow: 0 0 0 8px rgba(22, 121, 90, .12), 0 12px 28px rgba(22, 121, 90, .35); animation: pop .5s var(--ease); }
.codebox { background: var(--foil-soft); border: 1px dashed rgba(169, 136, 60, .55); }

/* ---------- banners ---------- */
.bn { box-shadow: var(--sh1); }

/* ---------- phone ---------- */
@media(max-width:900px) {
    #hd { background: var(--velvet); box-shadow: 0 8px 24px rgba(26, 25, 25, .3); }
    #tabs {
        background: rgba(255, 255, 255, .92); backdrop-filter: blur(16px) saturate(1.5);
        box-shadow: 0 -8px 30px rgba(26, 25, 25, .10);
    }
    #tabs a { transition: color .2s, transform .2s var(--ease); }
    #tabs a.on { transform: translateY(-1px); }
    #tabs a.on:before { background: var(--foil); box-shadow: 0 2px 10px rgba(217, 185, 110, .7); }
    .formside { border-radius: 26px 26px 0 0; box-shadow: 0 -12px 40px rgba(0, 0, 0, .25); }
    tr { box-shadow: var(--sh1); }
}

/* ---------- one gentle entrance for the page content ---------- */
#view > * { animation: rise .5s var(--ease) both; }
#view > *:nth-child(2) { animation-delay: .05s }
#view > *:nth-child(3) { animation-delay: .1s }
#view > *:nth-child(n+4) { animation-delay: .14s }
#view > * { animation-duration: .38s }

@media (prefers-reduced-motion: reduce) {
    .strip:before, .mini:after, .chip.ok:before, .pill.ok:before, .mini .top span:last-child:before { animation: none !important }
}
@media print { body { background: #ffffff } .strip:before, .mini:after { display: none } }

/* Gold Rate ERP: "Publish Rates" screen, purple + gold redesign.
   Loaded after fancy.css. Delete this file + its <link> in index.html to revert the old look
   (the old markup is replaced in app.js V.publish, so restore that function too). */

:root {
    --pp1: #212020;
    --pp2: #2b2a2a;
    --pp3: #373636;
    --pp4: #525050;
    --lav: #f8f7f5;
    --lav2: #f1f0ec;
    --pline: #e7e6df;
    --pink: #1f1e1e;
    --gold-pill: linear-gradient(180deg, #f4dca5 0%, #dfbe72 55%, #daac40 100%);
}

/* ------------------------------------------------ hero header */
body.pub #hd { display: none }
body.pub #view { padding: 0 0 28px; max-width: 760px }
.pubhero {
    position: relative; overflow: hidden; isolation: isolate;
    padding: calc(66px + env(safe-area-inset-top, 0px)) 16px 50px;
    background: #1f1e1e url(img/hero.webp) right bottom / auto 100% no-repeat; min-height: 226px;
    color: #ffffff;
}
.ph-t { display: flex; align-items: center; gap: 12px; min-width: 0; max-width: 72% }
.ph-mark { width: 54px; height: auto; flex: none; filter: drop-shadow(0 2px 8px rgba(218, 172, 64, .45)) }
.pubhero h1 { white-space: nowrap; font: 700 28px/1.1 var(--sans); letter-spacing: -.01em; color: #ffffff; margin: 0 }
.pubhero h1 em {
    font-style: normal;
    background: var(--foil, linear-gradient(135deg, #f9ebca, #d9b96e 45%, #ebd299));
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent;
}
.pubhero p { max-width: 165px; margin: 6px 0 0; color: rgba(255, 255, 255, .86); font-size: 14px; line-height: 1.3 }
.pubbr {
    position: absolute; top: calc(18px + env(safe-area-inset-top, 0px)); right: 16px;
    display: inline-flex; align-items: center; gap: 8px; max-width: 54%;
    padding: 8px 14px; border-radius: 999px; color: #ffffff; font-weight: 600; font-size: 15px;
    border: 1.5px solid rgba(222, 185, 98, .85); background: rgba(38, 37, 37, .55); backdrop-filter: blur(6px);
}
.pubbr .ic { width: 20px; height: 20px; flex: none; color: #dfbe72 }
.pubbr .ic.dn { width: 16px; height: 16px; transform: rotate(90deg); color: #ffffff }
.pubbr b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.pubbr select {
    appearance: none; -webkit-appearance: none; background: transparent; border: 0; box-shadow: none; outline: 0;
    color: #ffffff; font: 600 15px var(--sans); padding: 0; min-height: 0; width: auto; max-width: 34vw;
    text-overflow: ellipsis
}
.pubbr select option { color: #1e1d1d }

/* ------------------------------------------------ sheet */
.pubsheet {
    position: relative; margin-top: -26px; padding: 16px 12px 0;
    background: linear-gradient(180deg, #ffffff, var(--lav) 120%);
    border-radius: 28px 28px 0 0; box-shadow: 0 -10px 30px rgba(38, 37, 37, .18);
}
.pubsheet .bn { margin-top: 0 }
.pubinfo {
    display: flex; align-items: center; gap: 14px; padding: 14px 16px; margin-bottom: 16px;
    background: var(--lav2); border: 1px solid var(--pline); border-radius: 18px; color: var(--pink)
}
.pubinfo .ic { width: 38px; height: 38px; flex: none; color: var(--pp3); padding-right: 12px; box-sizing: content-box; border-right: 1px solid var(--pline) }
.pubinfo p { margin: 0; font-size: 16px; font-weight: 500; line-height: 1.3 }
.pubgrid { gap: 16px }

/* ------------------------------------------------ rates card */
.ratescard {
    position: relative; background: #ffffff; border: 1px solid var(--pline); border-radius: 22px;
    box-shadow: 0 10px 30px rgba(45, 43, 43, .10); overflow: hidden; margin-bottom: 16px
}
.ratescard header {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 0 10px 0 0; background: linear-gradient(180deg, var(--lav), #ffffff)
}
.rc-tab {
    display: inline-flex; align-items: center; gap: 10px; padding: 12px 38px 12px 14px; color: #ffffff;
    background: linear-gradient(135deg, var(--pp3), #1f1e1e);
    clip-path: polygon(0 0, calc(100% - 26px) 0, 100% 100%, 0 100%); border-top-left-radius: 22px
}
.rc-tab .ic { width: 26px; height: 26px; color: #dfbe72 }
.rc-tab b { font-size: 22px; font-weight: 700 }
.rc-live {
    display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 999px;
    background: var(--lav2); border: 1px solid var(--pline); color: var(--pp3); font-weight: 700; font-size: 13px; white-space: nowrap
}
.rc-live .ic { width: 16px; height: 16px }
.rc-live.off { color: #545151; background: #f4f4f2 }
.pubsheet .rt-list { display: grid; gap: 0; margin: 0; padding: 2px 10px 12px }
.pubsheet .rt {
    display: grid; grid-template-columns: 44px 62px minmax(0, 1fr) auto; align-items: center; gap: 4px 10px;
    padding: 11px 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; cursor: text;
    border-bottom: 1px solid var(--line2)
}
.pubsheet .rt:last-child { border-bottom: 0 }
.pubsheet .rt:focus-within { box-shadow: none; border-color: var(--line2) }
.rt-ico { width: 44px; height: 44px; display: grid; place-items: center; filter: drop-shadow(0 3px 6px rgba(168, 130, 43, .25)) }
.rt.silver .rt-ico { filter: drop-shadow(0 3px 6px rgba(52, 50, 50, .25)) }
.rt-ico img { width: 100%; height: 100%; object-fit: contain; display: block }
.pubsheet .rt-k { display: block }
.pubsheet .rt-k b { display: block; font: 700 19px/1.1 var(--sans); color: var(--pink) }
.pubsheet .rt-k small { display: block; margin-top: 3px; color: #4c4949; font-size: 12.5px; white-space: nowrap }
.rt-mid { display: contents }
.pubsheet .rt-in {
    display: block; min-width: 0; border: 1.5px solid var(--pline); border-radius: 14px; background: #ffffff;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .8) inset; transition: border-color .2s, box-shadow .2s
}
.pubsheet .rt-in:focus-within { border-color: var(--pp4); box-shadow: 0 0 0 4px rgba(82, 80, 80, .16) }
.pubsheet .rt-in input {
    width: 100%; text-align: center; min-height: 48px; padding: 0 4px; border: 0; background: transparent; box-shadow: none;
    font: 600 21px/1 var(--sans); font-variant-numeric: lining-nums tabular-nums; color: var(--pink)
}
.pubsheet .rt-in input:focus { outline: 0; border: 0; box-shadow: none }
.pubsheet .rt-in input::placeholder { color: #d4d3d1 }
.pubsheet .rt-d { grid-column: 3 / -1; grid-row: 2; text-align: left; padding-left: 4px; font-size: 12px; font-weight: 700; color: #545151; white-space: nowrap }
.pubsheet .rt-d:empty { display: none }
.pubsheet .rt-d.up { color: var(--ok) }
.pubsheet .rt-d.dn { color: var(--bad) }
.pbadge {
    display: inline-flex; align-items: center; justify-content: center; min-width: 66px; padding: 0 8px; min-height: 48px;
    border-radius: 14px; background: var(--gold-pill); color: #342606; font: 800 20px/1 var(--sans);
    border: 1px solid #d0aa52; box-shadow: 0 6px 14px rgba(218, 172, 64, .35), inset 0 1px 0 rgba(255, 255, 255, .7)
}
.pbadge i { font-style: normal; font-weight: 800 }
.pbadge.up i { color: #6d500d }
.pbadge.dn i { color: #a3261b }
.rt-unit {
    position: relative; display: inline-flex; align-items: center; min-height: 48px; border: 1.5px solid var(--pline);
    border-radius: 14px; background: #ffffff; color: var(--pink)
}
.rt-unit select {
    appearance: none; -webkit-appearance: none; background: transparent; border: 0; box-shadow: none; outline: 0;
    min-height: 46px; width: auto; padding: 0 28px 0 12px; font: 600 16px var(--sans); color: var(--pink)
}
.rt-unit .ic { position: absolute; right: 9px; width: 16px; height: 16px; transform: rotate(90deg); pointer-events: none }

/* explicit cell placement so the delta line can sit under the input */
.pubsheet .rt > .rt-ico { grid-column: 1; grid-row: 1 }
.pubsheet .rt > .rt-k { grid-column: 2; grid-row: 1 }
.pubsheet .rt .rt-in { grid-column: 3; grid-row: 1 }
.pubsheet .rt > .pbadge, .pubsheet .rt > .rt-unit { grid-column: 4; grid-row: 1 }

/* ------------------------------------------------ message + go live cards */
.pubcard {
    display: flex; align-items: center; gap: 12px; margin: 0 0 16px; padding: 12px 14px; cursor: text; overflow: hidden;
    background: #ffffff; border: 1px solid var(--pline); border-radius: 20px; box-shadow: 0 8px 24px rgba(45, 43, 43, .08)
}
.pubcard.pm { background: linear-gradient(180deg, #f9f9f7, #f3f3f0) }
.pubcard:focus-within { border-color: var(--pp4); box-shadow: 0 0 0 4px rgba(82, 80, 80, .14) }
.pc-ico { flex: none; display: grid; place-items: center; width: 48px; height: 48px; color: var(--pp3) }
.pc-ico .ic { width: 34px; height: 34px }
.pc-ico.tvi {
    width: 50px; height: 46px; border-radius: 12px; color: #ffffff; background: linear-gradient(135deg, var(--pp3), #1f1e1e);
    box-shadow: 0 6px 14px rgba(45, 43, 43, .3)
}
.pc-ico.tvi .ic { width: 28px; height: 28px }
.pubcard.pm .pc-body { border-left: 1px solid var(--pline); padding-left: 14px }
.pc-body { flex: 1; min-width: 0; display: grid; gap: 4px; grid-template-columns: minmax(0, 1fr) }
.pc-body b { font-size: 17px; font-weight: 700; color: var(--pink); line-height: 1.2 }
.pc-body input {
    width: 100%; min-height: 0; padding: 2px 0; border: 0; background: transparent; box-shadow: none;
    font: 500 17px var(--sans); color: #393838
}
.pc-body input:focus { outline: 0; border: 0; box-shadow: none }
.pc-body input::placeholder { color: #555252 }
.pubcard.gl .pc-body input {
    min-height: 46px; max-width: 100%; min-width: 0; padding: 0 10px; border: 1.5px solid var(--pline); border-radius: 12px; background: #ffffff; font-size: 16px
}
.pubcard.gl .pc-body input:focus { border-color: var(--pp4); box-shadow: 0 0 0 4px rgba(82, 80, 80, .14) }
.pc-edit {
    flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; color: #ffffff;
    background: linear-gradient(135deg, var(--pp4), var(--pp3)); box-shadow: 0 4px 10px rgba(60, 58, 58, .3)
}
.pc-edit .ic { width: 20px; height: 20px }

/* ------------------------------------------------ publish button */
.pubsheet .err { margin: 0 0 10px }
.pubsheet #rv { margin-bottom: 12px }
.pubsheet #rv .btn.pri, .pubsheet #cf {
    min-height: 52px; border-radius: 16px; border: 0; color: #ffffff; font-weight: 700; font-size: 17px;
    background: linear-gradient(180deg, var(--pp4), var(--pp2)); box-shadow: 0 8px 20px rgba(60, 58, 58, .35)
}
.pubgo {
    display: flex; align-items: center; justify-content: center; gap: 14px; width: 100%; min-height: 66px;
    padding: 0 20px; margin: 4px 0 20px; border-radius: 22px; cursor: pointer; color: #ffffff; font: 700 26px var(--sans);
    background: linear-gradient(180deg, #4b4949 0%, #333131 55%, #292828 100%);
    border: 2px solid #d0aa52;
    box-shadow: 0 0 0 6px rgba(220, 177, 78, .12), 0 14px 30px rgba(60, 58, 58, .45), inset 0 1px 0 rgba(255, 255, 255, .3);
    transition: transform .15s var(--ease, ease), box-shadow .2s, filter .2s
}
.pubgo .ic { width: 30px; height: 30px; flex: none }
.pubgo:hover { filter: brightness(1.08); transform: translateY(-1px) }
.pubgo:active { transform: translateY(1px) }
.pubgo:disabled { filter: grayscale(.8); opacity: .55; cursor: not-allowed; transform: none }
.pubsheet .pubprev { margin-top: 0 }

/* ------------------------------------------------ bottom tabs (phones) */
@media(max-width:900px) {
    #tabs {
        background: #ffffff; border-top: 1px solid var(--pline); border-radius: 26px 26px 0 0;
        box-shadow: 0 -10px 30px rgba(45, 43, 43, .14); backdrop-filter: none
    }
    #tabs a { color: #494747; font-size: 15px; font-weight: 600; gap: 3px }
    #tabs a .ic { width: 30px; height: 30px; padding: 6px; box-sizing: content-box; border-radius: 50%; transition: background .2s }
    #tabs a.on { color: var(--pp3); transform: none }
    #tabs a.on .ic { background: var(--lav2) }
    #tabs a.on:before {
        top: auto; bottom: 0; width: 46%; height: 4px; border-radius: 4px 4px 0 0;
        background: var(--pp3); box-shadow: none
    }
    :root { --tab: 76px }
}
@media(max-width:380px) {
    .pubhero h1 { font-size: 26px }
    .ph-mark { width: 44px }
    .pubsheet .rt { grid-template-columns: 38px 56px minmax(0, 1fr) auto; gap: 4px 6px }
    .rt-ico { width: 38px; height: 38px }
    .pubsheet .rt-k b { font-size: 17px }
    .pubsheet .rt-in input { font-size: 18px }
    .pbadge { min-width: 58px; font-size: 17px }
    .pubgo { font-size: 22px }
}

/* ------------------------------------------------ desktop: keep it tidy beside the sidebar */
@media(min-width:901px) {
    body.pub #view { max-width: 1120px; padding: 24px 28px 60px }
    .pubhero {
        border-radius: 24px; padding-bottom: 54px; min-height: 0;
        background:
            linear-gradient(90deg, #1f1e1e 0, #1f1e1e calc(100% - 600px), rgba(31, 30, 30, 0) calc(100% - 440px)),
            #1f1e1e url(img/hero.webp) right bottom / auto 100% no-repeat
    }
    .pubhero p { max-width: none }
    .pubsheet { margin-top: -22px; border-radius: 24px; box-shadow: 0 10px 40px rgba(38, 37, 37, .10) }
    .pubbr { top: 22px }
    .ph-t { max-width: 56% }
}

/* silver row: the unit picker needs less room so the number stays readable */
.pubsheet .rt.silver .rt-in input { font-size: 18px }
.pubsheet .rt.silver .rt-unit select { font-size: 14px; padding: 0 22px 0 10px; min-height: 46px }
.pubsheet .rt.silver .rt-unit .ic { right: 6px; width: 14px; height: 14px }
.pubsheet .rt.silver .rt-k small { font-size: 11.5px }

/* Gold Rate ERP: "Home" screen, dark purple + gold redesign (same family as publish.css).
   Loaded after publish.css. Applies only while body has class "home" (set in route()). */

body.home { background: linear-gradient(180deg, #f9f8f6, #f0f0ec) fixed }
body.home #hd { display: none }
body.home #view { padding: 0 0 28px; max-width: 760px }
body.home .pg { display: none }

/* ---------- header + update line */
.homehero {
    padding: calc(14px + env(safe-area-inset-top, 0px)) 14px 12px;
    background: #1f1e1e url(img/home-hero.webp) center top / cover no-repeat; color: #ffffff;
}
.hbar { display: flex; align-items: center; gap: 12px; min-height: 56px }
.hlg { display: block; height: 46px; width: auto; flex: none }
.hdiv { width: 1px; align-self: stretch; margin: 6px 0; background: rgba(255, 255, 255, .28) }
.hbar h1 { display: flex; align-items: center; gap: 10px; margin: 0; font: 700 26px/1 var(--sans); color: #ffffff }
.hbar h1 .ic { width: 28px; height: 28px; color: #ffffff; fill: rgba(255, 255, 255, .15) }
.hbr {
    margin-left: auto; display: inline-flex; align-items: center; gap: 8px; max-width: 48%; min-height: 44px; padding: 0 16px;
    border-radius: 999px; color: #ffffff; font-weight: 600; font-size: 15px;
    background: linear-gradient(180deg, rgba(43, 42, 42, .85), rgba(36, 35, 35, .9)); border: 1px solid rgba(255, 255, 255, .16);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .3)
}
.hbr b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.hbr select {
    appearance: none; -webkit-appearance: none; background: transparent; border: 0; box-shadow: none; outline: 0; color: #ffffff;
    font: 600 15px var(--sans); padding: 0; min-height: 0; width: auto; max-width: 34vw; text-overflow: ellipsis
}
.hbr select option { color: #1e1d1d }
.hbr .ic.dn { width: 16px; height: 16px; transform: rotate(90deg); flex: none }
.hupd { display: flex; align-items: center; gap: 10px; margin-top: 34px }
.hclock { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; border: 2px solid #d0aa52; color: #dfbe72 }
.hclock .ic { width: 22px; height: 22px }
.hupd p { margin: 0; flex: 1; min-width: 0; color: #ffffff; font-size: 14px; line-height: 1.3 }
.hupd p b { color: #dfbe72; font-weight: 600 }
.hpub {
    flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 46px; padding: 0 18px; border-radius: 999px;
    color: #1f1e1e; font: 700 16px var(--sans); text-decoration: none;
    background: linear-gradient(180deg, #f5e0b0, #dab45d 60%, #c8a24b);
    box-shadow: 0 8px 20px rgba(220, 177, 78, .35), inset 0 1px 0 rgba(255, 255, 255, .7)
}
.hpub .ic { width: 20px; height: 20px }

/* ---------- rate tiles */
.homesheet { padding: 0 12px }
.hstrip {
    display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 8px; margin-bottom: 16px; border-radius: 28px;
    border: 1.5px solid rgba(217, 185, 110, .6); background: linear-gradient(180deg, #252424, #232222);
    box-shadow: 0 14px 30px rgba(37, 36, 36, .28), inset 0 0 0 1px rgba(255, 255, 255, .05)
}
.hstrip.hempty { display: block; padding: 22px; color: #f4f4f1; text-align: center }
.hc {
    position: relative; overflow: hidden; isolation: isolate; min-height: 118px; padding: 12px 12px 10px; border-radius: 20px;
    background: linear-gradient(135deg, #2a2929 0%, #282727 60%, #201f1f 100%); border: 1px solid rgba(255, 255, 255, .07);
    color: #ffffff
}
.hc.wide { grid-column: 1 / -1; min-height: 104px }
.hpill {
    display: inline-block; padding: 3px 11px; border-radius: 12px; color: #251c05; font: 800 15px/1.2 var(--sans);
    background: linear-gradient(180deg, #f5e0b0, #dfb451); box-shadow: 0 2px 8px rgba(220, 177, 78, .35)
}
.hlab { margin-left: 8px; font-size: 15px; font-weight: 500; color: #f7f6f4 }
.hprice {
    display: block; margin-top: 10px; font: 800 23px/1.15 var(--sans); letter-spacing: -.01em; white-space: nowrap;
    background: linear-gradient(180deg, #f7e7c0, #deb34f 70%, #c49831); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .35))
}
.hun { display: block; margin-top: 2px; font-style: normal; font-size: 14px; color: #f7f6f4 }
.hc.wide .hprice, .hc.wide .hun { display: inline-block }
.hc.wide .hun { margin-left: 12px }
.himg {
    position: absolute; z-index: -1; right: 0; bottom: 0; height: 74%; width: auto; max-width: 52%; object-fit: cover; object-position: right bottom;
    -webkit-mask-image: radial-gradient(ellipse 78% 78% at 62% 55%, #000000 52%, transparent 100%);
    mask-image: radial-gradient(ellipse 78% 78% at 62% 55%, #000000 52%, transparent 100%)
}
.hc.wide .himg { height: 96%; max-width: 46% }

/* ---------- cards below: cream like the "On your TV now" card */
body.home .card {
    background: #ffffff; border: 1px solid #ecebe6; border-radius: 24px;
    box-shadow: 0 10px 28px rgba(43, 42, 42, .12); color: #212020
}
body.home .card-h h2, body.home .card > h2 { color: #212020; font-size: 21px; font-weight: 700; display: flex; align-items: center; gap: 10px }
body.home .card .m, body.home .card .row .sp { color: #6b6862 }
body.home .card .chip { background: #ebd9b0; color: #503b0a; border: 1px solid rgba(169, 136, 60, .35) }
body.home .card .lnk { color: #373636 }
.htv { height: 44px; width: auto }
.tvcard .tvw { border-radius: 16px; overflow: hidden; box-shadow: 0 10px 26px rgba(20, 20, 20, .35) }

/* ---------- bottom nav: dark floating pill */
@media(max-width:900px) {
    body.home #tabs {
        left: 8px; right: 8px; bottom: calc(8px + env(safe-area-inset-bottom)); height: 72px; padding-bottom: 0;
        border-radius: 30px; border: 1px solid rgba(222, 185, 98, .35); backdrop-filter: none;
        background: linear-gradient(180deg, #242323, #201f1f); box-shadow: 0 12px 30px rgba(0, 0, 0, .5)
    }
    body.home #tabs a { color: #ffffff }
    body.home #tabs a.on { color: #dfbe72 }
    body.home #tabs a.on .ic { background: transparent; color: #dfbe72; filter: drop-shadow(0 2px 8px rgba(220, 177, 78, .6)) }
    body.home #tabs a.on:before { top: auto; bottom: 0; width: 56%; height: 3px; background: linear-gradient(90deg, #dfbe72, #c8a24b); border-radius: 3px 3px 0 0 }
    body.home #mn { padding-bottom: calc(var(--tab) + 14px + env(safe-area-inset-bottom)) }
}
@media(max-width:380px) {
    .hbar h1 { font-size: 22px }
    .hprice { font-size: 20px }
    .hpub { padding: 0 12px; font-size: 14px }
}

/* ---------- desktop */
@media(min-width:901px) {
    body.home #view { max-width: 1120px; padding: 24px 28px 60px }
    .homehero { border-radius: 24px }
    .hstrip { grid-template-columns: repeat(4, 1fr) }
    .hc { min-height: 150px }
    .hprice { font-size: 26px }
    .homesheet { padding: 0; margin-top: 14px }
}

/* tuning: keep prices readable above the product photos */
html:has(body.home) { background: linear-gradient(180deg, #f9f8f6, #f0f0ec) fixed }
.hprice { font-size: 20px }
.himg { height: 62%; max-width: 40% }
.hc.wide .himg { height: 100%; max-width: 38% }
.hc.wide .hprice { font-size: 22px }
@media(min-width:901px) { .hprice { font-size: 24px } .himg { height: 70%; max-width: 46% } .hc.wide .himg { max-width: 30% } }

/* product photos: fade the top and left edges into the tile */
.himg {
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000000 48%), linear-gradient(180deg, transparent 0, #000000 42%);
    mask-image: linear-gradient(90deg, transparent 0, #000000 48%), linear-gradient(180deg, transparent 0, #000000 42%);
    -webkit-mask-composite: source-in; mask-composite: intersect
}
.hc.wide .hlab::after { content: ""; display: block }
.hc.wide .hprice { margin-top: 12px }
.hc.wide .hun { margin-left: 10px }

/* header row must never overflow on narrow phones */
.hbar { gap: 8px; min-width: 0 }
.hlg { height: 40px }
.hdiv { flex: none }
.hbar h1 { font-size: 22px; gap: 8px; flex: none }
.hbar h1 .ic { width: 24px; height: 24px }
.hbr { min-width: 0; flex: 0 1 auto; padding: 0 12px; font-size: 14px }
.hbr b { min-width: 0 }

/* Sign-in / start-trial screen. One frame, no scrolling: everything is sized in em and the
   root font-size follows the window height, so the whole page scales to fit. */
#auth {
    --nv: #1a1919; --nv2: #232222; --gd: #d9b96e; --gd2: #b7923d;
    font-size: clamp(11px, min(1.6vh, 1.2vw), 17px);
    position: relative; height: 100vh; height: 100dvh; overflow: hidden;
    display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); grid-template-rows: 100%;
    background: radial-gradient(ellipse 50% 46% at 17% 30%, rgba(19, 19, 19, .78), rgba(19, 19, 19, .55) 55%, transparent 100%), linear-gradient(0deg, rgba(19, 19, 19, .75), transparent 17%), #1a1919 url(img/login-bg.webp) center / cover no-repeat;
    color: #212020;
}
#auth[hidden] { display: none }

/* ---------- left: navy story panel ---------- */
#auth .hero {
    position: relative; z-index: 1; grid-area: 1 / 1 / 2 / 3; min-width: 0; min-height: 0; overflow: hidden;
    display: flex; flex-direction: column; justify-content: flex-start; align-items: flex-start; gap: 0; text-align: left;
    padding: 3.2em 44% 2.6em 5em; background: none; color: #ffffff; isolation: isolate;
}
#auth .hero:before, #auth .hero:after { display: none }
#auth .hero > * { color: inherit }
#auth .brand { display: flex; align-items: center; gap: 1em; flex-direction: row; flex: none }
#auth .brand .logo { width: 3.8em; height: 3.8em; flex: none }
#auth .brand .lockup { display: block; width: 27em; max-width: 100%; height: auto }
#auth .brand b { display: block; font: 600 2.7em/1 'Prata', Georgia, serif; letter-spacing: .01em;
    background: linear-gradient(180deg, #f5e1b2, #d9b96e 70%, #c8a450); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent }
#auth .trk { display: flex !important; align-items: center; gap: .9em; margin-top: .55em; color: rgba(255, 255, 255, .85); font-size: 1.05em; letter-spacing: .32em; text-transform: none }
#auth .trk i { width: .35em; height: .35em; border-radius: 50%; background: var(--gd) }
#auth .hero h1 { margin: 2.2em 0 0; font: 300 3.2em/1.1 'Prata', Georgia, serif; color: #ffffff; max-width: 11em; text-shadow: none; flex: none }
#auth .hero h1:before { content: ""; display: block; width: 5.5em; height: 2px; margin-bottom: .7em; background: linear-gradient(90deg, var(--gd), rgba(217, 185, 110, .1)) }
#auth .hero h1 em { display: block; font-style: normal; font-weight: 700;
    background: linear-gradient(180deg, #f7e6bd, #d9b96e 60%, #b7923d); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent }
#auth .hero h1:after { display: none }
#auth .hero p { margin: 1.2em 0 0; max-width: 28em; font-size: 1.15em; line-height: 1.5; color: rgba(255, 255, 255, .88); flex: none }
#auth .feat { position: absolute; left: 5em; bottom: 2em; list-style: none; margin: 0; padding: 0; display: flex; align-items: center }
#auth .feat li { text-shadow: 0 1px 6px rgba(16, 16, 16, .9); display: flex; align-items: center; gap: .8em; padding: 0 2em; font-size: 1.15em; line-height: 1.2; text-align: left; color: #ffffff }
#auth .feat li:first-child { padding-left: 0 }
#auth .feat li + li { border-left: 1px solid rgba(217, 185, 110, .3) }
#auth .feat .fi { display: grid; place-items: center; width: 3.2em; height: 3.2em; border-radius: 50%; background: rgba(26, 25, 25, .75); box-shadow: 0 0 0 1px rgba(217, 185, 110, .45) }
#auth .feat svg { width: 1.7em; height: 1.7em; fill: none; stroke: var(--gd); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round }

/* ---------- right: sign-in card ---------- */
#auth .formside { position: relative; z-index: 2; grid-area: 1 / 2; min-width: 0; min-height: 0; background: none; padding: 4.6em 3em 1.2em 0; display: flex; justify-content: center; align-items: center }
#auth .trust { position: absolute; top: 1.7em; right: 3em; margin: 0; padding: 0; list-style: none; display: flex; align-items: center; color: #272626; font-size: .95em }
#auth .trust li { display: flex; align-items: center; gap: .6em; padding: 0 1.3em; white-space: nowrap }
#auth .trust li:last-child { padding-right: 0 }
#auth .trust li + li { border-left: 1px solid #d9cfba }
#auth .trust svg { width: 1.9em; height: 1.9em; fill: none; stroke: #b7923d; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round }
#auth .formbox { width: min(100%, 31em); max-width: none; max-height: 100%; overflow: visible; padding: 1.7em 2.4em 1.4em; border-radius: 1.8em; background: #fefdf9; text-align: center;
    box-shadow: 0 2em 4em rgba(26, 25, 25, .16), 0 0 0 1px rgba(183, 146, 61, .55) }
#auth .formbox .logo.bl { width: 3.6em; height: 3.6em; margin: 0 auto; display: block }
#auth .formbox .cbn { margin: .2em 0 0; font: 700 2.1em/1.1 'Prata', Georgia, serif; color: #212020 }
#auth .tagl { display: flex; align-items: center; gap: .8em; margin: .55em 0 1.3em; font-size: 1.05em; color: #272626 }
#auth .tagl:before, #auth .tagl:after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, transparent, #cbad68) }
#auth .tagl:after { background: linear-gradient(270deg, transparent, #cbad68) }
#auth .seg { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: .3em; border-radius: 999px; background: #eeeae0; box-shadow: none; margin: 0 0 1.3em }
#auth .seg button { display: flex; align-items: center; justify-content: center; gap: .6em; min-height: 3.1em; border: 0; border-radius: 999px; background: none; color: #272626; font: 600 1.05em/1 inherit; font-family: inherit; cursor: pointer }
#auth .seg button.on { background: linear-gradient(180deg, #383636, #252424); color: #ffffff; box-shadow: 0 .4em 1em rgba(37, 36, 36, .35) }
#auth .seg .ico, #auth .lf .ico { width: 1.5em; height: 1.5em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round }
#auth .seg button:not(.on) .ico { stroke: #c09530 }
#auth form { text-align: left }
#auth .formbox h2 { font: 700 1.9em/1.15 inherit; font-family: inherit; margin: 0 0 .25em; color: #212020; text-align: center }
#auth .formbox .sub { margin: 0 0 1.1em; text-align: center; font-size: 1.05em; color: #272626 }
#auth .formbox .m { color: #343333 }
#auth .lf { position: relative; display: flex; align-items: center; gap: .8em; height: 3.7em; padding: 0 1.3em; margin: 0 0 .9em; border: 1px solid #ddd6c6; border-radius: 999px; background: #fefdf9; color: #272626; font-weight: 400; font-size: 1em }
#auth .lf:focus-within { border-color: #b7923d; box-shadow: 0 0 0 .3em rgba(217, 185, 110, .28) }
#auth .lf input { flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; outline: 0; background: none; box-shadow: none; font-size: 1.2em; color: #212020; font-family: inherit }
#auth .pw-eye { border: 0; background: none; padding: .4em; margin-right: -.4em; cursor: pointer; color: #272626; display: grid }
#auth .pw-eye svg { width: 1.6em; height: 1.6em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round }
#auth .pw-eye .sl { display: block } #auth .pw-eye.on .sl { display: none }
#auth .frow { display: flex; justify-content: flex-end; margin: -.2em .4em .5em }
#auth .frow a { font-size: 1em; color: #272626; text-decoration: none }
#auth .frow a:hover { color: #8b6b21; text-decoration: underline }
#auth .err { margin: 0; min-height: 0; font-size: 1em; text-align: center } #auth .err:empty { display: none } #auth .err:not(:empty) { margin: .2em 0 .6em }
#auth #lb, #auth #fup .btn.gold { position: relative; inset: auto; width: 100%; height: 3.5em; min-height: 0; padding: 0; border-radius: 999px; font-size: 1.25em; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: .5em; border: 0; cursor: pointer; transition: transform .15s, box-shadow .2s;
    background: linear-gradient(180deg, #e8cb88, #c8a24b); color: #181307; box-shadow: 0 .5em 1.2em rgba(183, 146, 61, .4) }
#auth #lb:hover, #auth #fup .btn.gold:hover { transform: translateY(-1px) } #auth #lb:active, #auth #fup .btn.gold:active { transform: translateY(1px) }
#auth #lb:disabled, #auth #fup .btn.gold:disabled { opacity: .7; cursor: default }
#auth #lb svg { width: 1.3em; height: 1.3em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round }

/* sign-up form, compact enough to share the same frame */
#auth #fup h2 { font-size: 1.7em }
#auth #fup .sub { margin-bottom: .8em }
#auth #fup .fld { text-align: left; gap: .25em; margin-bottom: .6em; font-size: .95em; font-weight: 600; color: #272626 }
#auth #fup .two { gap: .8em; grid-template-columns: 1fr 1fr }
#auth #fup .two .fld { min-width: 0 }
#auth #fup .fld input { height: 2.7em; padding: 0 1.1em; border: 1px solid #ddd6c6; border-radius: 999px; background: #fefdf9; font-size: 1em; font-weight: 400; color: #212020; box-shadow: none }
#auth #fup .fld input:focus { outline: 0; border-color: #b7923d; box-shadow: 0 0 0 .25em rgba(217, 185, 110, .28) }
#auth #fup .legal { display: flex; gap: .6em; align-items: flex-start; margin: .1em 0 .5em; font-size: .95em; color: #272626 }
#auth #fup .legal a { color: #8b6b21 }
#auth #fup .btn.gold { margin-top: .3em }

#auth.up .formbox .logo.bl, #auth.up .formbox .cbn, #auth.up .tagl { display: none }
#auth.up .formbox { padding-top: 1.5em }
#auth.up .seg { margin-bottom: 1em }

/* footer row: support + TV display link */
#auth .tvgo { display: flex; flex-direction: column; align-items: center; gap: .55em; margin: 1.1em 0 0; padding: .9em 0 0; border-top: 1px solid #ebe5d7; font-size: .95em; color: #272626; text-align: center }
#auth .tvgo .help { display: flex; align-items: center; justify-content: center; gap: .6em; min-width: 0 }
#auth .tvgo svg { width: 1.5em; height: 1.5em; flex: none; fill: none; stroke: #272626; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round }
#auth #tvgo { display: inline-flex; align-items: center; gap: .5em; flex: none; width: auto; min-height: 0; padding: 0; border: 0; background: none; color: #8b6b21; font-weight: 600; text-decoration: none; white-space: nowrap }
#auth #tvgo:hover { text-decoration: underline }
#auth #tvgo svg { stroke: currentColor }
@media (prefers-reduced-motion: no-preference) { #auth .formbox { animation: rise .5s var(--ease) both } }

/* ---------- narrower laptops ---------- */
@media (max-width: 1180px) { #auth .trust li:nth-child(3) { display: none } }
@media (max-width: 1040px) { #auth .trust { display: none } #auth .formside { padding-top: 1.6em } }

/* ---------- phones and small tablets: same idea, stacked, still one frame ---------- */
@media (max-width: 900px) {
    #auth { font-size: clamp(11px, min(1.75vh, 3.1vw), 16px); display: flex; flex-direction: column; background: var(--nv) }
    #auth .hero { width: auto; flex: none; padding: calc(1.6em + env(safe-area-inset-top)) 1.6em 4.6em; background: linear-gradient(rgba(26, 25, 25,.3), rgba(26, 25, 25,.3)), url(img/login-bg.webp) 12% 20% / auto 640px no-repeat, var(--nv) }
    #auth .brand .logo { width: 3em; height: 3em } #auth .brand .lockup { width: 20em }
    #auth .hero h1 { display: block; margin-top: 1.1em; font-size: 2em; max-width: none }
    #auth .hero h1:before { margin-bottom: .5em; width: 4em }
    #auth .hero p, #auth .feat { display: none }
    #auth .formside { flex: 1; min-height: 0; display: flex; align-items: stretch; margin: -3.2em 0 0; padding: 0; background: none }
    #auth .trust { display: none }
    #auth .formbox { width: 100%; max-height: none; flex: 1; min-height: 0; overflow-y: auto; border-radius: 1.8em 1.8em 0 0; padding: 1.4em 1.4em calc(1em + env(safe-area-inset-bottom)); box-shadow: 0 -.8em 2.4em rgba(0, 0, 0, .3) }
    #auth .formbox .logo.bl, #auth .formbox .cbn, #auth .tagl { display: none }
    #auth .formbox h2 { font-size: 1.7em }
    #auth .tvgo { flex-wrap: wrap; justify-content: center; margin-top: .9em; padding-top: .8em; font-size: .9em }
}
@media (max-width: 900px) {
    #auth.up .hero h1 { display: none } #auth.up .hero { padding-bottom: 3.6em }
    #auth.up .formbox { padding-top: 1.1em } #auth.up .formbox h2 { font-size: 1.5em } #auth.up #fup .sub { margin-bottom: .6em }
    #auth.up .tvgo { margin-top: .6em; padding-top: .6em }
}
@media (max-width: 900px) and (max-height: 700px) { #auth .hero h1 { display: none } #auth .hero { padding-bottom: 4em } }
