:root {
  --forest-950: #06271f;
  --forest-900: #083529;
  --forest-800: #0d4b36;
  --forest-700: #126348;
  --forest-100: #dff1e9;
  --lime: #bdfb2d;
  --gold: #c69d4f;
  --gold-soft: #f6ecd9;
  --ink: #10201b;
  --muted: #5f6f68;
  --line: #d9e1dc;
  --surface: #ffffff;
  --canvas: #f4f7f4;
  --danger: #a33a36;
  --warning: #9a651b;
  --success: #167351;
  --shadow: 0 18px 50px rgba(6, 39, 31, .09);
  --radius: 18px;
}

* { box-sizing: border-box; }
html { color-scheme: light; scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--canvas); font: 16px/1.55 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: var(--forest-700); text-decoration-thickness: 1px; text-underline-offset: 3px; }
button, input, textarea, select { font: inherit; }
button, .button { cursor: pointer; }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.12; margin-top: 0; letter-spacing: -.025em; }
h1 { font-size: clamp(2rem, 5vw, 4.4rem); }
h2 { font-size: clamp(1.45rem, 2.5vw, 2.2rem); }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1rem; }
.muted { color: var(--muted); }
.eyebrow { color: var(--gold); font-weight: 800; letter-spacing: .1em; text-transform: uppercase; font-size: .78rem; }
.skip-link { position: absolute; left: -999px; }

.brand { display: inline-flex; align-items: center; gap: .75rem; color: inherit; text-decoration: none; }
.brand span { display: grid; line-height: 1.1; }
.brand strong { font-size: 1.12rem; }
.brand small { color: var(--muted); margin-top: .24rem; }
.brand-inverse { color: white; }
.brand-inverse small { color: #b7cec5; }
.public-header { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 2rem; padding: .8rem clamp(1rem, 5vw, 5rem); background: rgba(255,255,255,.94); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(14px); }
.public-header nav { display: flex; align-items: center; gap: 1.3rem; }
.public-header nav a { color: var(--ink); text-decoration: none; font-weight: 700; }
.public-main { min-height: 75vh; }
.public-footer { display: flex; justify-content: space-between; gap: 2rem; padding: 2.2rem clamp(1rem, 5vw, 5rem); background: var(--forest-950); color: #dce9e4; }
.public-footer a { color: var(--lime); }

.hero { min-height: 580px; display: grid; grid-template-columns: 1.2fr .8fr; align-items: center; gap: clamp(2rem, 6vw, 7rem); padding: clamp(4rem, 9vw, 8rem) clamp(1rem, 7vw, 7rem); color: white; background: radial-gradient(circle at 80% 10%, rgba(189,251,45,.24), transparent 28%), linear-gradient(140deg, var(--forest-950), var(--forest-700)); overflow: hidden; }
.hero h1 { max-width: 14ch; margin-bottom: 1.25rem; }
.hero p { max-width: 62ch; color: #d8e9e2; font-size: 1.12rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.hero-panel { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.22); padding: 1.4rem; border-radius: 28px; backdrop-filter: blur(10px); }
.hero-panel .mini-card { padding: 1.1rem; background: rgba(6,39,31,.52); border-radius: 15px; margin-top: .7rem; }

.section { padding: clamp(3.5rem, 7vw, 7rem) clamp(1rem, 7vw, 7rem); }
.section-heading { max-width: 720px; margin-bottom: 2.2rem; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.1rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.35rem; box-shadow: 0 8px 30px rgba(8,53,41,.04); }
.card h3 { margin-bottom: .45rem; }
.card-accent { border-top: 4px solid var(--gold); }
.feature-number { display: inline-grid; place-items: center; min-width: 2.3rem; height: 2.3rem; border-radius: 50%; background: var(--forest-100); color: var(--forest-800); font-weight: 900; }

.button { appearance: none; border: 0; border-radius: 999px; display: inline-flex; justify-content: center; align-items: center; gap: .45rem; padding: .82rem 1.2rem; color: var(--forest-950); background: var(--lime); text-decoration: none; font-weight: 850; box-shadow: none; }
.button:hover { filter: brightness(.96); transform: translateY(-1px); }
.button-secondary { color: white; background: var(--forest-700); }
.button-ghost { color: inherit; background: transparent; border: 1px solid currentColor; }
.button-small { padding: .58rem .95rem; font-size: .9rem; }
.button-danger { color: white; background: var(--danger); }
.text-button { border: 0; padding: 0; background: transparent; color: var(--lime); font-weight: 750; }

.auth-shell { display: grid; grid-template-columns: .9fr 1.1fr; min-height: calc(100vh - 76px); }
.auth-aside { padding: clamp(2rem, 7vw, 6rem); color: white; background: radial-gradient(circle at 30% 20%, rgba(189,251,45,.18), transparent 30%), var(--forest-900); }
.auth-aside h1 { font-size: clamp(2.3rem, 5vw, 4.2rem); margin-top: 2rem; }
.auth-panel { display: grid; place-items: center; padding: 2rem 1rem; }
.form-card { width: min(560px, 100%); background: white; border: 1px solid var(--line); border-radius: 24px; padding: clamp(1.3rem, 4vw, 2.4rem); box-shadow: var(--shadow); }
.form-card .button { width: 100%; margin-top: .4rem; }
.field { display: grid; gap: .42rem; margin-bottom: 1rem; }
.field label { font-weight: 760; }
.field input, .field textarea, .field select, .filter-bar input { width: 100%; border: 1px solid #bccbc4; border-radius: 12px; padding: .8rem .9rem; color: var(--ink); background: #fff; }
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { outline: 3px solid rgba(198,157,79,.25); border-color: var(--gold); }
.field-help { color: var(--muted); font-size: .86rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.sidebar { width: 270px; position: fixed; inset: 0 auto 0 0; z-index: 30; display: flex; flex-direction: column; padding: 1.35rem; color: white; background: var(--forest-950); }
.sidebar nav { display: grid; gap: .25rem; margin: 2rem 0; }
.sidebar nav a { color: #c8ddd4; text-decoration: none; padding: .72rem .8rem; border-radius: 10px; font-weight: 700; }
.sidebar nav a:hover, .sidebar nav a.active { color: var(--forest-950); background: var(--lime); }
.sidebar-footer { margin-top: auto; display: grid; gap: .25rem; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,.16); overflow-wrap: anywhere; }
.sidebar-footer small { color: #a8c4b8; margin-bottom: .65rem; }
.dashboard-main { min-height: 100vh; margin-left: 270px; padding: clamp(1rem, 4vw, 3rem); }
.mobile-menu { display: none; position: fixed; right: 1rem; top: 1rem; z-index: 40; border: 0; border-radius: 999px; padding: .7rem 1rem; background: var(--lime); font-weight: 800; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin: .4rem 0 2rem; }
.page-head h1 { font-size: clamp(2rem, 4vw, 3.4rem); margin-bottom: .3rem; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.metric { background: white; border: 1px solid var(--line); border-radius: 16px; padding: 1.2rem; }
.metric strong { display: block; font-size: 2rem; color: var(--forest-800); }
.metric span { color: var(--muted); }
.split { display: grid; grid-template-columns: 1.2fr .8fr; gap: 1.2rem; }

.table-wrap { overflow-x: auto; background: white; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .82rem .9rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-size: .76rem; letter-spacing: .04em; text-transform: uppercase; background: #f8faf8; }
tr:last-child td { border-bottom: 0; }
.table-actions { display: flex; flex-wrap: wrap; gap: .45rem; align-items: center; }
.table-actions select, .table-actions input { padding: .45rem .55rem; border: 1px solid var(--line); border-radius: 8px; }
.filter-bar { display: flex; gap: .7rem; margin-bottom: 1rem; }
.filter-bar input { max-width: 420px; }

.badge { display: inline-flex; align-items: center; border-radius: 999px; padding: .26rem .58rem; font-size: .76rem; font-weight: 800; background: #edf1ef; color: var(--muted); }
.badge-success { background: #dff3e9; color: #0f6848; }
.badge-warning { background: #f9ecd3; color: #805115; }
.badge-danger { background: #f8dfdc; color: #8e302d; }
.badge-gold { background: var(--gold-soft); color: #775716; }
.alert { margin: 0 0 1rem; border-radius: 12px; padding: .85rem 1rem; border: 1px solid var(--line); background: white; }
.alert-success { border-color: #8ac9aa; background: #e9f7ef; }
.alert-error { border-color: #dfa8a2; background: #fff0ee; }
.alert-warning { border-color: #dec28a; background: #fff8e8; }
.notice { border-left: 4px solid var(--gold); background: var(--gold-soft); padding: 1rem; border-radius: 0 12px 12px 0; }
.stack { display: grid; gap: 1rem; }
.empty { padding: 2rem; text-align: center; color: var(--muted); }
.video-frame { aspect-ratio: 16 / 9; width: 100%; border: 0; border-radius: 14px; background: var(--forest-950); }

@media (max-width: 1050px) {
  .metric-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .hero, .auth-shell, .split { grid-template-columns: 1fr; }
  .hero-panel { max-width: 650px; }
}
@media (max-width: 780px) {
  .public-header { align-items: flex-start; }
  .public-header nav { gap: .75rem; flex-wrap: wrap; justify-content: flex-end; }
  .public-header nav a:not(.button) { display: none; }
  .grid, .grid-2, .form-row { grid-template-columns: 1fr; }
  .sidebar { transform: translateX(-102%); transition: transform .2s ease; }
  .sidebar.open { transform: translateX(0); }
  .mobile-menu { display: block; }
  .dashboard-main { margin-left: 0; padding-top: 4.8rem; }
  .page-head { align-items: flex-start; flex-direction: column; }
  .public-footer { flex-direction: column; }
}
@media (max-width: 520px) {
  .metric-grid { grid-template-columns: 1fr; }
  .hero { min-height: auto; }
  .auth-aside { min-height: 280px; }
}

