/* KP AI School — Niche Finder
   Palette, type and theme switch match the main kpaischool.com site (same "kp-theme" setting). */
:root {
  --surface: #FAF7F0; --raised: #FFFFFF; --raised-2: #F4F0E6; --line: #E3DDD0;
  --ink: #14211D; --muted: #56625C;
  --pine: #0F5C4A; --pine-2: #1F8F72; --pine-soft: #DCEEE7; --on-pine: #FFFFFF;
  --saffron: #E8A317; --saffron-2: #F7C65A; --saffron-soft: #FCEFCF; --saffron-ink: #7A5300; --on-saffron: #14211D;
  --deep: #0B3229; --deep-2: #0F3F34; --on-deep: #F3F7F4; --on-deep-muted: #B5CCC2;
  --err: #B42318; --err-soft: #FDECEA;
  --good: var(--pine); --warn: #C98908; --bad: var(--err); --neutral: #6B7A73;
  --good-bg: var(--pine-soft); --warn-bg: var(--saffron-soft); --bad-bg: var(--err-soft);
  --shadow-sm: 0 1px 2px rgba(20,40,33,.06), 0 2px 8px rgba(20,40,33,.05);
  --shadow-lg: 0 24px 60px -24px rgba(11,50,41,.35);
  --r-sm: 10px; --r-md: 16px; --r-lg: 24px;
  --sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --surface: #0F1714; --raised: #17221E; --raised-2: #1C2924; --line: #2A3832;
  --ink: #EEF3EF; --muted: #A3B2AA;
  --pine: #4CC3A0; --pine-2: #5BE3B8; --pine-soft: #1A4A3C; --on-pine: #0F1714;
  --saffron: #F2B83A; --saffron-2: #F7C65A; --saffron-soft: #3A2C0B; --saffron-ink: #F2B83A;
  --deep: #0A2620; --deep-2: #0E3029;
  --err: #F97066; --err-soft: #3A1714; --warn: #F2B83A; --neutral: #8FA198;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.3);
  --shadow-lg: 0 30px 60px -30px rgba(0,0,0,.7);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--surface); color: var(--ink); font: 15.5px/1.6 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: var(--pine); }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; letter-spacing: -.02em; }
p { margin: 0; }
code { background: var(--raised-2); border: 1px solid var(--line); padding: 1px 7px; border-radius: 6px; font-size: 13px; }
:focus-visible { outline: 2px solid var(--saffron); outline-offset: 2px; border-radius: 6px; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.hidden { display: none !important; }

/* ---------- Header ---------- */
.topbar { position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.topbar-inner { display: flex; align-items: center; gap: 14px; min-height: 70px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.kp-mark { width: 40px; height: 40px; flex: none; }
.kp-eyes { transform-origin: 32px 34.5px; animation: blink 5s ease-in-out infinite; }
@keyframes blink { 0%, 46%, 50%, 100% { transform: scaleY(1); } 48% { transform: scaleY(.1); } }
.kp-word { display: flex; flex-direction: column; line-height: 1; }
.kp-word b { font-weight: 800; font-size: 1.3rem; letter-spacing: -.035em; }
.kp-word b i { font-style: normal; color: var(--saffron); }
.kp-word small { margin-top: 4px; font-size: .62rem; font-weight: 700; letter-spacing: .34em; text-transform: uppercase; color: var(--muted); }
.tool-chip { font-size: 12px; font-weight: 700; letter-spacing: .02em; color: var(--saffron-ink); background: var(--saffron-soft); border: 1px solid color-mix(in srgb, var(--saffron) 35%, transparent); padding: 4px 10px; border-radius: 999px; }
.tabs { display: flex; gap: 2px; margin-left: 8px; background: var(--raised-2); border: 1px solid var(--line); padding: 3px; border-radius: 12px; }
.tab { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 14px; font-weight: 600; padding: 7px 12px; border-radius: 9px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: background .2s, color .2s; }
.tab:hover { color: var(--ink); }
.tab.active { background: var(--raised); color: var(--ink); box-shadow: var(--shadow-sm); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-on { background: var(--pine-2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--pine-2) 25%, transparent); }
.dot-off { background: var(--err); }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.top-link { color: var(--ink); text-decoration: none; font-weight: 500; font-size: 14px; padding: 8px 10px; border-radius: 10px; }
.top-link:hover { color: var(--pine); background: var(--raised-2); }
.icon-btn { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: var(--raised); color: var(--ink); cursor: pointer; }
.icon-btn svg { width: 18px; height: 18px; }
:root[data-theme="dark"] .i-moon, :root:not([data-theme="dark"]) .i-sun { display: none; }
.user-menu { display: flex; align-items: center; gap: 8px; padding-left: 8px; margin-left: 4px; border-left: 1px solid var(--line); }
.avatar { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, var(--pine), var(--pine-2)); color: #fff; font-weight: 800; font-size: 13px; }
.user-name { font-size: 13px; font-weight: 600; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Buttons & inputs ---------- */
.btn { font: inherit; font-weight: 700; font-size: 15px; border-radius: 12px; padding: 11px 20px; border: 1px solid transparent; background: var(--raised); color: var(--ink); cursor: pointer; white-space: nowrap; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: transform .15s ease, box-shadow .2s ease, filter .2s; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn.gold, .btn.primary { background: linear-gradient(180deg, var(--saffron-2), var(--saffron)); color: #14211D; box-shadow: 0 8px 20px -10px rgba(232,163,23,.8), inset 0 1px 0 rgba(255,255,255,.35); }
.btn.gold:hover, .btn.primary:hover { filter: brightness(1.04); }
.btn.pine { background: var(--pine); color: var(--on-pine); }
.btn.ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn:disabled { opacity: .6; cursor: progress; transform: none; }
.btn.small { padding: 7px 13px; font-size: 13px; border-radius: 10px; }
.link-btn { border: 0; background: none; color: var(--pine); font: inherit; font-weight: 700; cursor: pointer; padding: 0; }
input[type=text], input[type=password], input[type=email], select {
  font: inherit; color: var(--ink); background: var(--raised); border: 1px solid var(--line); border-radius: 12px; padding: 11px 13px; min-width: 0; transition: border-color .2s, box-shadow .2s;
}
input:focus, select:focus { outline: none; border-color: var(--pine); box-shadow: 0 0 0 4px color-mix(in srgb, var(--pine) 18%, transparent); }

/* ---------- Hero ---------- */
.panel { padding-bottom: 24px; }
.hero-band { position: relative; padding: 56px 0 40px; background:
    radial-gradient(900px 380px at 85% -10%, rgba(232,163,23,.22), transparent 60%),
    radial-gradient(700px 360px at 0% 0%, rgba(91,227,184,.16), transparent 60%),
    linear-gradient(160deg, var(--deep), var(--deep-2)); color: var(--on-deep); overflow: hidden; }
.hero-band .wrap { position: relative; z-index: 1; }
.hero { max-width: 780px; margin-bottom: 26px; }
.kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; color: var(--saffron-2); background: rgba(232,163,23,.12); border: 1px solid rgba(232,163,23,.35); padding: 5px 12px; border-radius: 999px; }
.kicker i { width: 7px; height: 7px; border-radius: 50%; background: var(--saffron-2); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(247,198,90,.6); } 70% { box-shadow: 0 0 0 9px rgba(247,198,90,0); } 100% { box-shadow: 0 0 0 0 rgba(247,198,90,0); } }
.hero h1, .auth-pitch h1 { font-size: clamp(2rem, 4.6vw, 3.25rem); font-weight: 800; letter-spacing: -.035em; margin: 16px 0 12px; color: #fff; }
.hero h1 span, .auth-pitch h1 span { background: linear-gradient(90deg, var(--saffron-2), #FFE3A3); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-sub { color: var(--on-deep-muted); font-size: 1.07rem; max-width: 62ch; }
.hero-band .banner.warn { background: rgba(232,163,23,.12); border-color: rgba(232,163,23,.45); color: var(--on-deep); }
.hero-band .banner .link-btn { color: var(--saffron-2); }

/* ---------- Cards ---------- */
.card { background: var(--raised); border: 1px solid var(--line); border-radius: var(--r-md); padding: 22px; margin-bottom: 18px; box-shadow: var(--shadow-sm); }
.card h3 { font-size: 17px; font-weight: 700; margin-bottom: 14px; }
.search-card { padding: 20px; margin-bottom: 0; box-shadow: var(--shadow-lg); color: var(--ink); }
.search-row { display: flex; gap: 10px; }
.search-row > input { flex: 1; }
.search-input { flex: 1; position: relative; display: flex; }
.search-input svg { position: absolute; left: 15px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search-input input { flex: 1; font-size: 17px; padding: 14px 16px 14px 46px; border-radius: 14px; }
.search-row .btn.gold { padding: 0 26px; font-size: 16px; border-radius: 14px; }
.options-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.options-row label, .filters-grid label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--muted); font-weight: 700; letter-spacing: .02em; text-transform: uppercase; }
.options-row select, .filters-grid select { text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 14px; }
.options-row select { min-width: 160px; }
.advanced { margin-top: 16px; border-top: 1px dashed var(--line); padding-top: 12px; }
.advanced summary { cursor: pointer; font-weight: 700; font-size: 14px; }
.filters-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-top: 12px; }

.page-pad { padding-top: 36px; }
.page-h { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; margin-bottom: 8px; }
.page-pad > .muted { margin-bottom: 18px; max-width: 70ch; }
.block-label { display: block; font-weight: 700; margin-bottom: 8px; }
.key-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; flex-wrap: wrap; gap: 8px; }
.check { display: inline-flex; gap: 6px; align-items: center; font-size: 14px; }
.key-status { margin-top: 12px; }
.quota { margin-top: 22px; }
.quota-head { display: flex; justify-content: space-between; font-weight: 700; margin-bottom: 6px; font-size: 14px; }
.quota .muted { margin-top: 8px; }
.guide ol { padding-left: 20px; margin: 0; }
.guide li { margin-bottom: 9px; }

/* ---------- Banners ---------- */
.banner { border-radius: var(--r-sm); padding: 12px 16px; margin: 0 0 16px; border: 1px solid transparent; font-size: 14.5px; }
.banner.warn { background: var(--warn-bg); border-color: color-mix(in srgb, var(--saffron) 50%, transparent); }
.banner.bad { background: var(--bad-bg); border-color: color-mix(in srgb, var(--err) 50%, transparent); }
.banner.good { background: var(--good-bg); border-color: color-mix(in srgb, var(--pine) 50%, transparent); }
.banner .help { margin-top: 4px; color: var(--muted); font-size: 14px; }
#error-box { margin-top: 20px; }

/* ---------- Progress ---------- */
.progress { margin-top: 22px; }
.progress-label { font-weight: 700; margin-bottom: 10px; }
.progress-track { height: 8px; background: var(--raised-2); border-radius: 99px; overflow: hidden; }
.progress-fill { height: 100%; width: 0; background: linear-gradient(90deg, var(--pine), var(--pine-2), var(--saffron)); transition: width .4s ease; border-radius: 99px; }

/* ---------- Report ---------- */
#report { margin-top: 26px; }
#report > .card:first-child { background:
    radial-gradient(500px 220px at 100% 0%, color-mix(in srgb, var(--saffron) 14%, transparent), transparent 70%), var(--raised); }
.report-head { display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; }
.ring { --v: 0; --c: var(--neutral); width: 148px; height: 148px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--c) calc(var(--v) * 1%), var(--raised-2) 0); box-shadow: 0 10px 30px -12px var(--c); }
.ring-inner { width: 120px; height: 120px; border-radius: 50%; background: var(--raised); display: grid; place-items: center; text-align: center; }
.ring-num { font-size: 40px; font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.ring-sub { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-top: 4px; }
.report-head h2 { font-size: 26px; font-weight: 800; }
.verdict { font-size: 22px; font-weight: 800; margin: 0 0 4px; }
.tone-good { color: var(--good); } .tone-warn { color: var(--warn); } .tone-bad { color: var(--bad); } .tone-neutral { color: var(--neutral); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.pill { background: var(--raised-2); border: 1px solid var(--line); border-radius: 99px; padding: 4px 12px; font-size: 13px; font-weight: 600; }
.report-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.report-actions .btn { background: var(--raised-2); border-color: var(--line); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid-2 > .card { margin-bottom: 18px; }
.scores { display: grid; gap: 16px; }
.score-row .score-top { display: flex; justify-content: space-between; font-weight: 700; font-size: 14px; }
.score-row .why { font-size: 13px; color: var(--muted); margin-top: 4px; }
.bar { height: 8px; background: var(--raised-2); border-radius: 99px; overflow: hidden; margin-top: 7px; }
.bar > span { display: block; height: 100%; border-radius: 99px; }

.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.stat { background: var(--raised-2); border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.stat-num { font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.stat-label { font-size: 12.5px; color: var(--muted); }
.buckets { display: grid; gap: 10px; margin-top: 10px; }
.bucket { display: grid; grid-template-columns: 90px 1fr 36px; align-items: center; gap: 10px; font-size: 13px; }
.bucket .bar > span { background: linear-gradient(90deg, var(--pine), var(--pine-2)) !important; }

.prediction { border-color: color-mix(in srgb, var(--pine) 35%, var(--line)); }
.prediction ul { margin: 6px 0 0; padding-left: 20px; }
.prediction li { margin-bottom: 5px; }
.prediction .label { font-weight: 800; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-top: 16px; }

.section-title { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.section-title h3 { margin-bottom: 4px; }
.table-wrap { overflow-x: auto; margin-top: 10px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 11px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); white-space: nowrap; font-weight: 700; }
tbody tr:hover { background: color-mix(in srgb, var(--raised-2) 60%, transparent); }
td.num, th.num { text-align: right; white-space: nowrap; }
.vid { display: flex; gap: 12px; align-items: flex-start; min-width: 260px; }
.vid img { width: 104px; height: 58px; object-fit: cover; border-radius: 8px; flex: none; background: var(--raised-2); }
.vid a, .chan a { color: var(--ink); text-decoration: none; font-weight: 700; }
.vid a:hover, .chan a:hover { color: var(--pine); text-decoration: underline; }
.chan { min-width: 150px; }
.chan .sub { display: block; font-size: 12px; color: var(--muted); font-weight: 500; }
.tag { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: 12px; font-weight: 800; }
.tag.High { background: var(--good-bg); color: var(--good); }
.tag.Medium { background: var(--warn-bg); color: var(--warn); }
.tag.Low { background: var(--raised-2); color: var(--muted); }
.flags { margin: 4px 0 0; padding-left: 20px; }
.compare { font-size: 14px; }
.up { color: var(--good); font-weight: 800; } .down { color: var(--bad); font-weight: 800; }
.empty { color: var(--muted); font-style: italic; padding: 8px 0; }

/* ---------- Courses ---------- */
.courses { margin: 44px 0 20px; }
.courses-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.courses-head h2 { font-size: clamp(1.6rem, 3.2vw, 2.3rem); font-weight: 800; letter-spacing: -.03em; }
.courses-head h2 span { color: var(--saffron); }
.courses-head p { color: var(--muted); max-width: 60ch; margin-top: 8px; }
.course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.course { position: relative; display: flex; flex-direction: column; background: var(--raised); border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; box-shadow: var(--shadow-sm); transition: transform .2s ease, box-shadow .2s ease, border-color .2s; }
.course:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--pine) 40%, var(--line)); }
.course.featured { grid-column: 1 / -1; display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; align-items: center; color: var(--on-deep); border: 1px solid rgba(232,163,23,.45); padding: 26px;
  background: radial-gradient(600px 260px at 100% 0%, rgba(232,163,23,.22), transparent 60%), linear-gradient(150deg, var(--deep), var(--deep-2)); }
.course.featured .course-what { color: var(--on-deep-muted); }
.course.featured h3 { color: #fff; font-size: 26px; }
.course.featured .course-sub { color: var(--saffron-2); }
.course.featured .course-tools span { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.14); color: var(--on-deep); }
.course.featured .btn.ghost { color: var(--on-deep); border-color: rgba(255,255,255,.3); }
.course.featured .fee { color: #fff; }
.course.featured .fee small { color: var(--on-deep-muted); }
.course-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.clabel { font-size: 12px; font-weight: 700; color: var(--saffron-ink); background: var(--saffron-soft); padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.course.featured .clabel { background: var(--saffron); color: #14211D; }
.course h3 { font-size: 19px; font-weight: 800; letter-spacing: -.02em; }
.course-sub { font-size: 13.5px; font-weight: 600; color: var(--pine); margin-top: 3px; }
.course-what { font-size: 14px; color: var(--muted); margin-top: 10px; }
.course-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12.5px; font-weight: 600; color: var(--muted); margin-top: 12px; }
.course.featured .course-meta { color: var(--on-deep-muted); }
.course-tools { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.course-tools span { font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 8px; background: var(--raised-2); border: 1px solid var(--line); }
.course-foot { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 16px; flex-wrap: wrap; }
.course.featured .course-foot { margin-top: 0; padding-top: 0; }
.fee { font-size: 20px; font-weight: 800; letter-spacing: -.02em; margin-right: auto; line-height: 1.1; }
.fee small { display: block; font-size: 11px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.featured-side { display: grid; gap: 16px; }
.featured-why { display: grid; gap: 8px; font-size: 14px; color: var(--on-deep); }
.featured-why div { display: flex; gap: 8px; }
.featured-why div::before { content: "✓"; color: var(--saffron-2); font-weight: 800; }

/* ---------- History ---------- */
.history-item { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.history-score { font-size: 26px; font-weight: 800; min-width: 56px; }
.history-main { flex: 1; min-width: 200px; }

/* ---------- Login ---------- */
.auth-screen { min-height: calc(100vh - 70px); display: grid; align-items: center; padding: 48px 0; color: var(--on-deep);
  background: radial-gradient(900px 420px at 90% 0%, rgba(232,163,23,.2), transparent 60%), radial-gradient(700px 400px at 0% 100%, rgba(91,227,184,.14), transparent 60%), linear-gradient(160deg, var(--deep), var(--deep-2)); }
.auth-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.pitch-sub { color: var(--on-deep-muted); font-size: 1.07rem; max-width: 52ch; }
.pitch-list { list-style: none; padding: 0; margin: 24px 0; display: grid; gap: 12px; }
.pitch-list li { display: flex; gap: 10px; color: var(--on-deep-muted); }
.pitch-list li::before { content: ""; flex: none; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%; background: rgba(91,227,184,.16) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235BE3B8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/12px no-repeat; }
.pitch-list b { color: #fff; }
.pitch-course { border: 1px solid rgba(232,163,23,.35); background: rgba(232,163,23,.08); border-radius: var(--r-md); padding: 16px 18px; display: grid; gap: 8px; justify-items: start; }
.pitch-course p { color: var(--on-deep); }
.pitch-course .clabel { background: var(--saffron); color: #14211D; }
.text-link { color: var(--saffron-2); font-weight: 700; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.auth-card { padding: 30px; color: var(--ink); box-shadow: var(--shadow-lg); margin: 0; border-radius: var(--r-lg); }
.auth-title { font-size: 26px; font-weight: 800; margin-bottom: 6px; }
.google-btn { width: 100%; margin-top: 18px; padding: 12px; background: var(--raised); border: 1px solid var(--line); color: var(--ink); }
.google-btn:hover { border-color: var(--pine); }
.auth-or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 18px 0; }
.auth-or::before, .auth-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: var(--raised-2); border: 1px solid var(--line); border-radius: 12px; padding: 4px; margin-bottom: 16px; }
.auth-mode { border: 0; background: transparent; font: inherit; font-weight: 700; font-size: 14px; color: var(--muted); padding: 9px; border-radius: 9px; cursor: pointer; }
.auth-mode.active { background: var(--raised); color: var(--ink); box-shadow: var(--shadow-sm); }
.auth-field { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 700; color: var(--muted); margin-bottom: 12px; }
.auth-field input { font-size: 16px; }
.auth-submit { width: 100%; padding: 13px; margin-top: 4px; }
.auth-forgot { display: block; margin: 14px auto 0; font-size: 14px; }
.auth-msg { margin-top: 14px; }
.auth-msg .banner { margin: 0; }
.auth-loading { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 120px 16px; color: var(--muted); font-weight: 600; }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--saffron); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Footer ---------- */
.site-foot { margin-top: 40px; background: linear-gradient(160deg, var(--deep), #071E19); color: var(--on-deep-muted); padding: 48px 0 24px; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 32px; }
.foot-logo { display: flex; align-items: center; gap: 10px; color: #fff; }
.foot-logo .kp-word small { color: var(--on-deep-muted); }
.foot-slogan { font-size: 22px; font-weight: 800; color: #fff; margin: 16px 0 18px; letter-spacing: -.02em; line-height: 1.25; }
.foot-slogan span { color: var(--saffron-2); }
.foot-col { display: grid; gap: 8px; align-content: start; font-size: 14px; }
.foot-col h4 { color: #fff; font-size: 14px; margin-bottom: 6px; }
.foot-col a { color: var(--on-deep-muted); text-decoration: none; }
.foot-col a:hover { color: var(--saffron-2); }
.foot-legal { margin-top: 32px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.1); font-size: 12.5px; display: grid; gap: 6px; }
.foot-legal a { color: var(--on-deep); }

/* ---------- Responsive ---------- */
@media (max-width: 1060px) {
  .top-link { display: none; }
}
@media (max-width: 980px) {
  .tabs { order: 5; width: 100%; margin: 0 0 10px; justify-content: space-between; }
  .tab { flex: 1; justify-content: center; }
  .auth-grid { grid-template-columns: 1fr; gap: 28px; }
  .course.featured { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .grid-2 { grid-template-columns: 1fr; }
  .report-head { grid-template-columns: 1fr; justify-items: start; }
  .search-row { flex-direction: column; }
  .search-row .btn.gold { padding: 13px; }
  .options-row select { min-width: 0; width: 100%; }
  .options-row label { flex: 1 1 140px; }
  .foot-grid { grid-template-columns: 1fr; }
  .tool-chip, .user-name { display: none; }
  .hero-band { padding-top: 36px; }
}
@media (max-width: 440px) {
  .top-actions .btn.gold { display: none; }
}
@media print {
  .topbar, .search-card, .report-actions, .site-foot, #no-key-banner, .hero-band, #courses-block { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; break-inside: avoid; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
.course:not(.featured) .fee { flex-basis: 100%; margin-bottom: 8px; }
.course:not(.featured) .course-foot .btn { flex: 1; }
