/* Ruzivo Educore platform. Brand: ink #0A1E27, teal #16A394 / #3FC7B4 / #0B6E63, gold #F4B740, paper #F5F3EE. */
:root {
  --ink: #0A1E27; --ink-2: #0E2A33; --ink-3: #123641; --line-dk: #1C3B44;
  --teal: #16A394; --teal-lt: #3FC7B4; --teal-dk: #0B6E63; --gold: #F4B740; --gold-lt: #FFD277; --clay: #CE6A3E;
  --paper: #F5F3EE; --paper-2: #EDEBE3; --card: #fff; --text: #12262C; --slate: #3C4C52; --mute: #5d6e74; --line: #E3E0D6;
  --good: #1F9D6B; --warn: #B76E14; --bad: #C2402A;
  --r: 14px; --shadow: 0 1px 2px rgba(10,30,39,.06), 0 8px 24px rgba(10,30,39,.07);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font: 16px/1.6 var(--font); color: var(--text); background: var(--paper); }
img, svg, canvas { max-width: 100%; }
a { color: var(--teal-dk); }
a:hover { color: var(--teal); }
h1, h2, h3 { line-height: 1.2; color: var(--ink); margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); }
h2 { font-size: clamp(1.3rem, 2.6vw, 1.8rem); }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--mute); }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.sr, .hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--gold); color: var(--ink); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 12px; }
.inline { display: inline; }
.grow { flex: 1; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 999px; padding: 10px 20px; font: 600 .95rem/1.2 var(--font); cursor: pointer; text-decoration: none; transition: background .15s, transform .15s, box-shadow .15s; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
.btn-sm { padding: 7px 14px; font-size: .85rem; }
.btn-lg { padding: 14px 26px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn-teal { background: var(--teal-dk); color: #fff; }
.btn-teal:hover { background: var(--teal); color: #fff; }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-lt); color: var(--ink); }
.btn-line { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-line:hover { border-color: var(--teal); color: var(--teal-dk); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.35); }
.btn-ghost:hover { border-color: #fff; color: #fff; }
.btn-ghost-dark { background: transparent; color: var(--slate); }
.btn-danger { background: var(--bad); color: #fff; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: underline; }

/* navigation */
.nav { position: sticky; top: 0; z-index: 40; background: rgba(245,243,238,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav-dark { background: rgba(10,30,39,.94); border-color: var(--line-dk); }
.nav-in { display: flex; align-items: center; gap: 18px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: 1.08rem; }
.brand b { color: var(--teal-dk); }
.nav-dark .brand, .nav-dark .brand b { color: #fff; }
.nav-dark .brand b { color: var(--teal-lt); }
.nav-links { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.nav-links a, .nav-links .link-btn { color: var(--slate); text-decoration: none; font-weight: 500; font-size: .94rem; }
.nav-links a:hover { color: var(--teal-dk); }
.nav-dark .nav-links a, .nav-dark .nav-links .link-btn { color: #cfe0e2; }
.nav-dark .nav-links a:hover { color: #fff; }
.nav-links .btn-gold { color: var(--ink); }
.nav-toggle { display: none; margin-left: auto; background: none; border: 0; width: 44px; height: 44px; cursor: pointer; }
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after { display: block; width: 22px; height: 2px; background: currentColor; position: relative; margin: auto; content: ""; }
.nav-toggle span::before { position: absolute; top: -7px; } .nav-toggle span::after { position: absolute; top: 7px; }
.nav-dark .nav-toggle { color: #fff; }
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-links { display: none; position: absolute; left: 0; right: 0; top: 64px; flex-direction: column; align-items: stretch; gap: 0; background: var(--card); border-bottom: 1px solid var(--line); padding: 8px 20px 16px; }
  .nav-dark .nav-links { background: var(--ink); border-color: var(--line-dk); }
  .nav-links.open { display: flex; }
  .nav-links a, .nav-links form { padding: 10px 0; }
}

/* hero */
.hero { background: radial-gradient(1200px 500px at 80% 0%, #123b45 0%, var(--ink) 60%); color: #d8e6e8; padding: 56px 0 28px; overflow: hidden; }
.hero-in { display: grid; grid-template-columns: 1.05fr 1fr; gap: 40px; align-items: center; }
.hero h1 { color: #fff; font-size: clamp(2.1rem, 5vw, 3.4rem); }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero .lead { font-size: 1.12rem; color: #c4d6d9; max-width: 38em; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--teal-lt); }
.pulse { width: 9px; height: 9px; border-radius: 50%; background: var(--teal-lt); display: inline-block; box-shadow: 0 0 0 0 rgba(63,199,180,.6); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(63,199,180,0); } 100% { box-shadow: 0 0 0 0 rgba(63,199,180,0); } }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 12px; }
.hero-note { font-size: .9rem; color: #9fb7bb; }
.hero-map { position: relative; }
.hero-map canvas { width: 100%; height: auto; display: block; }
.map-legend { font-size: .78rem; color: #9fb7bb; display: flex; gap: 8px; align-items: center; justify-content: center; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; } .dot-teal { background: var(--teal-lt); } .dot-gold { background: var(--gold); margin-left: 10px; }
.live-strip { margin: 28px 0 6px; display: grid; grid-template-columns: repeat(5, 1fr); border: 1px solid var(--line-dk); border-radius: var(--r); background: rgba(14,42,51,.7); }
.live-strip > div { padding: 16px 18px; border-left: 1px solid var(--line-dk); }
.live-strip > div:first-child { border-left: 0; }
.live-strip dt { font-size: .76rem; text-transform: uppercase; letter-spacing: .1em; color: #8fb0b4; }
.live-strip dd { margin: 4px 0 0; font-size: clamp(1.3rem, 2.6vw, 1.9rem); font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.live-time { font-size: .8rem; color: #8fb0b4; } .live-time a { color: var(--teal-lt); }
@media (max-width: 900px) { .hero-in { grid-template-columns: 1fr; } .live-strip { grid-template-columns: repeat(2, 1fr); } .live-strip > div { border-left: 0; border-top: 1px solid var(--line-dk); } .live-strip > div:nth-child(-n+2) { border-top: 0; } }

.band-ticker { background: var(--ink-2); color: #b9d0d3; border-top: 1px solid var(--line-dk); }
.ticker { display: flex; gap: 36px; overflow-x: auto; padding: 12px 20px; font-size: .9rem; scrollbar-width: none; }
.ticker span { white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; }

/* sections */
.sec { padding: 72px 0; }
.sec-paper { background: var(--paper-2); }
.sec-dark { background: var(--ink); color: #c4d6d9; }
.sec-dark h2, .sec-dark h3 { color: #fff; }
.kicker { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--teal-dk); margin-bottom: 8px; }
.kicker-gold { color: var(--gold); }
.sec-lead { font-size: 1.08rem; color: var(--slate); max-width: 46em; }
.sec-dark .sec-lead { color: #b9d0d3; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 960px) { .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid3 { grid-template-columns: 1fr 1fr; } .split { grid-template-columns: 1fr; gap: 28px; } }
@media (max-width: 640px) { .grid2, .grid3, .grid4 { grid-template-columns: 1fr; } .sec { padding: 52px 0; } }
.feat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 22px; }
.feat svg { width: 30px; height: 30px; fill: none; stroke: var(--teal-dk); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 10px; }
.feat p { color: var(--slate); font-size: .94rem; margin: 0; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: s; display: grid; gap: 10px; }
.steps li { display: flex; gap: 14px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; font-weight: 500; }
.steps li span { flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--teal-dk); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .85rem; }
.ticks { list-style: none; padding: 0; margin: 0 0 1em; }
.ticks li { padding-left: 28px; position: relative; margin: 8px 0; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .35em; width: 16px; height: 16px; border-radius: 50%; background: var(--teal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%23fff' stroke-width='2'/%3E%3C/svg%3E") center/12px no-repeat; }

.ai-demo { display: grid; grid-template-columns: 1fr auto 1.4fr; align-items: center; gap: 14px; }
.ai-demo-photo { background: #f8f4e6; transform: rotate(-3deg); border-radius: 8px; padding: 16px; box-shadow: 0 10px 30px rgba(0,0,0,.35); color: #3a3a3a; font: italic 600 .85rem Georgia, serif; }
.ai-demo-photo i { display: block; height: 2px; background: #b9b2a0; margin: 14px 0; }
.ai-demo-arrow { font-size: 2rem; color: var(--gold); }
.ai-demo-table { width: 100%; border-collapse: collapse; background: var(--ink-2); border-radius: 10px; overflow: hidden; font-size: .88rem; }
.ai-demo-table th, .ai-demo-table td { padding: 8px 10px; border-bottom: 1px solid var(--line-dk); text-align: left; color: #d8e6e8; }
.ai-demo-table th { color: #8fb0b4; font-weight: 600; font-size: .78rem; text-transform: uppercase; }
.ai-demo-table .ok { color: var(--teal-lt); } .ai-demo-table .warn { color: var(--gold); }

.group-demo { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: var(--shadow); }
.gd-head { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; } .gd-head span { color: var(--mute); font-size: .88rem; }
.gd-row { display: grid; grid-template-columns: 130px 1fr 44px 80px; gap: 10px; align-items: center; font-size: .9rem; padding: 7px 0; border-top: 1px solid var(--line); }
.gd-row em { color: var(--mute); font-style: normal; font-size: .82rem; }
.gd-bar { height: 8px; background: var(--paper-2); border-radius: 99px; overflow: hidden; } .gd-bar i { display: block; height: 100%; background: var(--teal); border-radius: 99px; width: 0; transition: width 1s; }
.gd-alert { margin: 12px 0 0; background: #fff4e0; color: var(--warn); border-radius: 10px; padding: 8px 12px; font-size: .88rem; }

.trust article { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 22px; }
.trust p { color: var(--slate); margin: 0; font-size: .94rem; }

.prices .price { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 26px 22px; display: flex; flex-direction: column; }
.price .amt { font-size: 1rem; color: var(--slate); margin: 0; } .price .amt b { font-size: 2.1rem; color: var(--ink); }
.price .ticks { flex: 1; font-size: .92rem; }
.price-hot { border: 2px solid var(--teal); box-shadow: var(--shadow); }
.price-dark { background: var(--ink); color: #c4d6d9; border-color: var(--ink); } .price-dark h3, .price-dark .amt b { color: #fff; }
.tag { position: absolute; top: -12px; left: 22px; background: var(--teal-dk); color: #fff; font-size: .75rem; font-weight: 700; padding: 3px 10px; border-radius: 99px; }

.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; margin: 10px 0; }
.faq summary { cursor: pointer; font-weight: 600; } .faq details p { margin: 10px 0 0; color: var(--slate); }

.enquiry { background: var(--ink-2); border: 1px solid var(--line-dk); border-radius: var(--r); padding: 22px; display: grid; gap: 10px; }
.enquiry label { color: #b9d0d3; font-size: .88rem; display: grid; gap: 4px; }
.enquiry input { background: var(--ink); border-color: var(--line-dk); color: #fff; }
.form-note { margin: 0; font-size: .9rem; color: var(--teal-lt); }

/* forms */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 24px; box-shadow: var(--shadow); margin-bottom: 20px; min-width: 0; }
.form { display: grid; gap: 14px; }
.form label { display: grid; gap: 5px; font-weight: 600; font-size: .9rem; color: var(--ink); }
.form-h { font-size: 1rem; margin: 10px 0 -2px; padding-top: 10px; border-top: 1px solid var(--line); }
input, select, textarea { font: 400 1rem/1.4 var(--font); color: var(--text); background: #fff; border: 1px solid #cfd6d4; border-radius: 10px; padding: 10px 12px; width: 100%; min-width: 0; }
input:focus, select:focus, textarea:focus { border-color: var(--teal); outline: 3px solid rgba(22,163,148,.2); outline-offset: 0; }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--bad); background: #fff8f6; }
.f-err { color: var(--bad); font-size: .84rem; font-weight: 500; margin: 0; }
.hint { color: var(--mute); font-weight: 400; font-size: .82rem; }
.hint.ok { color: var(--good); } .hint.bad { color: var(--bad); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; } .row3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 640px) { .row2, .row3 { grid-template-columns: 1fr; } }
.addr { display: flex; align-items: stretch; } .addr input { border-radius: 10px 0 0 10px; } .addr b { display: flex; align-items: center; padding: 0 12px; background: var(--paper-2); border: 1px solid #cfd6d4; border-left: 0; border-radius: 0 10px 10px 0; font-weight: 500; color: var(--slate); font-size: .9rem; white-space: nowrap; }
.check { display: flex !important; grid-auto-flow: column; align-items: flex-start; gap: 10px !important; font-weight: 400 !important; }
.check input { width: auto; margin-top: 4px; }
.seg { display: flex; border: 0; padding: 0; margin: 0; gap: 8px; }
.seg label { flex: 1; } .seg input { position: absolute; opacity: 0; }
.seg span { display: block; text-align: center; padding: 10px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 600; }
.seg input:checked + span { border-color: var(--teal); background: #e9f7f5; color: var(--teal-dk); }
.seg input:focus-visible + span { outline: 3px solid var(--gold); }
.code-in { font-size: 1.6rem; letter-spacing: .5em; text-align: center; font-variant-numeric: tabular-nums; }
.secret { display: block; font-size: 1.15rem; letter-spacing: .08em; margin: 8px 0; padding: 10px; background: var(--paper-2); border-radius: 8px; word-break: break-all; }
.short { max-width: 280px; }
.flash { border-radius: 12px; padding: 12px 16px; margin: 16px 0; font-weight: 500; }
.flash-ok { background: #e7f6ef; color: #145f43; } .flash-warn { background: #fff4e0; color: #7a4a0c; } .flash-bad { background: #fdecea; color: #8c2a1b; }

.auth { max-width: 460px; margin: 48px auto; padding: 0 20px; }
.auth-wide { max-width: 1060px; display: grid; grid-template-columns: 1fr 1.4fr; gap: 40px; align-items: start; }
@media (max-width: 860px) { .auth-wide { grid-template-columns: 1fr; } }
.auth-side { padding-top: 20px; }
.page { padding-top: 32px; padding-bottom: 48px; }
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 20px; }

/* pills, kpis */
.pill { display: inline-block; font-size: .75rem; font-weight: 700; padding: 3px 10px; border-radius: 99px; background: var(--paper-2); color: var(--slate); text-transform: capitalize; }
.pill-ok, .pill-active, .pill-done { background: #e2f5ec; color: #146046; }
.pill-warn, .pill-setup, .pill-provisioning, .pill-queued, .pill-running { background: #fff1d6; color: #7a4a0c; }
.pill-bad, .pill-failed, .pill-suspended { background: #fde7e3; color: #8c2a1b; }
.kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 0 0 20px; }
.kpi-row > div { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; }
.kpi-row dt, .mini-kpis dt { font-size: .76rem; color: var(--mute); text-transform: uppercase; letter-spacing: .08em; }
.kpi-row dd { margin: 4px 0 0; font-size: 1.6rem; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .kpi-row { grid-template-columns: 1fr 1fr; } }
.mini-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 14px 0; }
.mini-kpis dd { margin: 0; font-weight: 700; font-size: 1.15rem; }
.mini-kpis.big { grid-template-columns: repeat(3, 1fr); } .mini-kpis.big dd { font-size: 1.5rem; }

.school-card header { display: flex; gap: 12px; align-items: flex-start; }
.school-card header div { flex: 1; min-width: 0; } .school-card h2 { font-size: 1.1rem; margin: 0; }
.school-card footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.swatch { width: 14px; height: 40px; border-radius: 6px; background: var(--teal); flex: none; }
.group-card { display: flex; align-items: center; justify-content: space-between; text-decoration: none; color: inherit; }
.group-card:hover { border-color: var(--teal); } .arrow { font-size: 1.6rem; color: var(--teal-dk); }
.celebrate { background: linear-gradient(120deg, #e8f7f4, #fff6e0); border-color: var(--teal-lt); }
.progress { height: 8px; border-radius: 99px; background: var(--paper-2); overflow: hidden; margin-top: 14px; }
.progress i { display: block; height: 100%; background: var(--teal); width: 0; transition: width .6s; }

/* setup wizard */
.setup { display: grid; grid-template-columns: 280px 1fr; gap: 24px; padding-top: 28px; padding-bottom: 48px; align-items: start; }
@media (max-width: 900px) { .setup { grid-template-columns: 1fr; } }
.stepper { position: sticky; top: 84px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; }
.stepper-school { font-weight: 700; color: var(--ink); margin: 0 0 12px; } .stepper-school span { display: block; font-weight: 400; color: var(--mute); font-size: .82rem; }
.stepper ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.stepper li > a, .stepper li > span { display: flex; }
.stepper li a, .stepper li { border-radius: 10px; text-decoration: none; color: var(--slate); }
.stepper li { display: flex; gap: 10px; padding: 8px; align-items: flex-start; }
.stepper li a { display: flex; gap: 10px; align-items: flex-start; width: 100%; }
.stepper .num { flex: none; width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; font-size: .78rem; font-weight: 700; }
.stepper .lbl { font-weight: 600; font-size: .9rem; color: var(--ink); } .stepper small { display: block; font-weight: 400; color: var(--mute); font-size: .78rem; }
.stepper li.done .num { background: var(--teal); border-color: var(--teal); color: #fff; }
.stepper li.here { background: #e9f7f5; } .stepper li.here .num { border-color: var(--teal-dk); color: var(--teal-dk); }
@media (max-width: 900px) { .stepper { position: static; } .stepper small { display: none; } .stepper ol { grid-template-columns: repeat(4, 1fr); } .stepper li { flex-direction: column; align-items: center; text-align: center; padding: 6px 2px; } .stepper li a { flex-direction: column; align-items: center; } .stepper .lbl { font-size: .72rem; } }
.step-form h1 { font-size: 1.6rem; }
.step-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 16px; margin-top: 6px; }
.swatches { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.swatches legend { font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.sw { display: grid !important; justify-items: center; gap: 4px !important; cursor: pointer; font-weight: 400 !important; }
.sw input { position: absolute; opacity: 0; }
.sw span { width: 40px; height: 40px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.sw input:checked + span { box-shadow: 0 0 0 3px var(--ink); } .sw input:focus-visible + span { outline: 3px solid var(--gold); }
.sw em { font-style: normal; font-size: .75rem; color: var(--mute); }
.subjects { border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin: 0; display: grid; gap: 10px; }
.subjects legend { font-weight: 700; padding: 0 6px; }
.chk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px; }
.chk { display: flex !important; align-items: center; gap: 8px !important; font-weight: 400 !important; padding: 6px 8px; border-radius: 8px; cursor: pointer; }
.chk:hover { background: var(--paper); } .chk input { width: auto; }
.etable-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.etable { border-collapse: collapse; width: 100%; min-width: 640px; font-size: .9rem; }
.etable th { background: var(--paper); text-align: left; font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--slate); padding: 8px; white-space: nowrap; }
.etable td { padding: 4px; border-top: 1px solid var(--line); vertical-align: top; }
.etable input, .etable select { padding: 7px 8px; font-size: .9rem; border-radius: 8px; min-width: 90px; }
.etable .f-err { font-size: .76rem; }
.row-x { border: 0; background: none; color: var(--mute); font-size: 1.3rem; cursor: pointer; width: 32px; height: 34px; border-radius: 8px; }
.row-x:hover { background: #fde7e3; color: var(--bad); }
.etable-empty { padding: 18px; margin: 0; color: var(--mute); text-align: center; }
.etable-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.paste-dlg { border: 0; border-radius: var(--r); padding: 22px; width: min(640px, 94vw); box-shadow: 0 30px 80px rgba(0,0,0,.3); }
.paste-dlg::backdrop { background: rgba(10,30,39,.55); }
.review { display: grid; gap: 8px; }
.review-row { display: grid; grid-template-columns: 200px 1fr auto; gap: 12px; align-items: center; padding: 12px; border: 1px solid var(--line); border-radius: 10px; }
.review-row .muted span { margin-right: 12px; font-size: .88rem; }
@media (max-width: 640px) { .review-row { grid-template-columns: 1fr; } }
.ai-import { border: 2px dashed var(--teal-lt); background: #f2fbf9; border-radius: 12px; padding: 14px; }
.ai-import p { margin: 0 0 8px; }

/* build progress */
.build .spinner { width: 46px; height: 46px; margin: 0 auto 14px; border-radius: 50%; border: 4px solid var(--paper-2); border-top-color: var(--teal); animation: spin 1s linear infinite; }
.build.done .spinner { animation: none; border-color: var(--teal); }
@keyframes spin { to { transform: rotate(360deg); } }
.build-steps { text-align: left; display: inline-grid; gap: 6px; margin: 8px auto 16px; padding-left: 20px; color: var(--mute); }
.build-steps li.done { color: var(--good); } .build-steps li.now { color: var(--ink); font-weight: 600; }

/* data tables, charts */
.table-wrap { overflow-x: auto; }
.data { width: 100%; border-collapse: collapse; font-size: .9rem; }
.data th, .data td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.data thead th { font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--mute); }
.data tbody th small { display: block; font-weight: 400; color: var(--mute); }
.data .clip { max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.meter { font-variant-numeric: tabular-nums; font-weight: 600; }
.meter.lo { color: var(--bad); } .meter.mid { color: var(--warn); } .meter.hi { color: var(--good); }
.spark svg { width: 90px; height: 26px; display: block; }
.hbars { display: grid; gap: 10px; }
.hbars div { display: grid; grid-template-columns: 140px 1fr 56px; gap: 10px; align-items: center; font-size: .9rem; }
.hbars i { height: 10px; border-radius: 99px; background: var(--teal); width: 0; transition: width .8s; }
.hbars-gold i { background: var(--gold); }
.hbars b { text-align: right; font-variant-numeric: tabular-nums; }
.alerts ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.alerts li { padding: 9px 12px; border-radius: 10px; font-size: .92rem; }
.al-bad { background: #fdecea; color: #8c2a1b; } .al-warn { background: #fff4e0; color: #7a4a0c; } .al-info { background: #eaf4f6; color: #22505a; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; } .filters input { max-width: 320px; } .filters select { max-width: 180px; }
.danger { margin-top: 14px; padding: 12px; border: 1px solid #f3c7bf; border-radius: 10px; background: #fff8f6; }

/* status */
.status-banner { border-radius: var(--r); padding: 18px 20px; font-weight: 700; margin-bottom: 18px; }
.status-banner.ok { background: #e2f5ec; color: #146046; } .status-banner.bad { background: #fde7e3; color: #8c2a1b; }
.status-top { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.days { display: grid; grid-template-columns: repeat(30, 1fr); gap: 3px; }
.days i { height: 28px; border-radius: 3px; background: var(--paper-2); }
.days i.ok { background: var(--teal); } .days i.bad { background: var(--bad); }

.prose { max-width: 820px; } .prose h2 { margin-top: 1.6em; } .prose li { margin: 6px 0; }
.plain { padding-left: 20px; } .plain li { margin: 8px 0; }

/* footer */
.foot { background: var(--ink); color: #9fb7bb; padding: 48px 0 20px; margin-top: 0; }
.foot-in { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 28px; }
.foot h3 { color: #fff; font-size: .9rem; } .foot a { display: block; color: #b9d0d3; text-decoration: none; margin: 6px 0; font-size: .92rem; }
.foot a:hover { color: #fff; } .brand-foot, .brand-foot b { color: #fff !important; } .brand-foot b { color: var(--teal-lt) !important; }
.foot-base { border-top: 1px solid var(--line-dk); margin-top: 28px; padding-top: 16px; font-size: .8rem; }
@media (max-width: 760px) { .foot-in { grid-template-columns: 1fr 1fr; } }

/* AI helper, bottom-left */
.ai { position: fixed; left: 18px; bottom: 18px; z-index: 60; }
.ai-fab { display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 999px; padding: 12px 18px 12px 14px; background: linear-gradient(135deg, var(--teal-dk), var(--teal)); color: #fff; font: 700 .92rem var(--font); cursor: pointer; box-shadow: 0 10px 30px rgba(11,110,99,.4); }
.ai-fab svg { width: 22px; height: 22px; fill: var(--gold-lt); }
.ai-fab:hover { transform: translateY(-2px); }
.ai-panel { position: absolute; left: 0; bottom: 62px; width: min(400px, calc(100vw - 36px)); height: min(560px, calc(100vh - 110px)); background: var(--card); border-radius: 18px; box-shadow: 0 24px 70px rgba(10,30,39,.35); display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line); }
.ai-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--ink); color: #fff; }
.ai-head span { display: block; font-size: .78rem; color: #9fb7bb; }
.ai-x { background: none; border: 0; color: #fff; font-size: 1.6rem; cursor: pointer; width: 36px; height: 36px; border-radius: 8px; }
.ai-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--paper); }
.ai-msg { max-width: 88%; padding: 10px 13px; border-radius: 14px; font-size: .93rem; white-space: pre-wrap; word-wrap: break-word; }
.ai-msg.bot { background: #fff; border: 1px solid var(--line); align-self: flex-start; border-bottom-left-radius: 4px; }
.ai-msg.me { background: var(--teal-dk); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.ai-msg img { max-width: 160px; border-radius: 8px; display: block; margin-bottom: 6px; }
.ai-msg .ai-rows { margin-top: 8px; font-size: .85rem; }
.ai-msg .btn { margin-top: 8px; }
.ai-typing span { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--mute); margin-right: 3px; animation: blink 1.2s infinite; }
.ai-typing span:nth-child(2) { animation-delay: .2s; } .ai-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 50% { opacity: .2; } }
.ai-chips { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 12px 8px; background: var(--paper); }
.ai-chips button { border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 5px 11px; font: .8rem var(--font); cursor: pointer; color: var(--slate); }
.ai-chips button:hover { border-color: var(--teal); color: var(--teal-dk); }
.ai-form { display: flex; gap: 8px; align-items: flex-end; padding: 10px; border-top: 1px solid var(--line); background: #fff; }
.ai-form textarea { resize: none; max-height: 120px; border-radius: 12px; }
.ai-cam, .ai-send { flex: none; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; cursor: pointer; border: 0; }
.ai-cam { background: var(--paper-2); } .ai-cam svg { width: 20px; height: 20px; fill: none; stroke: var(--teal-dk); stroke-width: 2; }
.ai-send { background: var(--teal-dk); } .ai-send svg { width: 18px; height: 18px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 520px) { .ai { left: 12px; bottom: 12px; } .ai-fab span { display: none; } .ai-fab { padding: 14px; } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
@media print { .nav, .foot, .ai { display: none !important; } body { background: #fff; } }
