:root {
  color-scheme: dark;
  --bg: #0b0b0c;
  --surface: #151517;
  --surface-2: #1d1d20;
  --line: #2d2d31;
  --text: #f7f7f5;
  --muted: #96969f;
  --yellow: #ffd51e;
  --yellow-soft: #2f290d;
  --red: #ff6b6b;
  --green: #63dfa4;
  --radius: 24px;
  --max: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 16px; line-height: 1.5; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, .button, select { cursor: pointer; }

.site-header, .site-footer, main { width: min(calc(100% - 48px), var(--max)); margin-inline: auto; }
.site-header { height: 92px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 1.25rem; font-weight: 800; letter-spacing: -.04em; }
.brand-mark { width: 36px; height: 36px; display: grid; place-items: center; border: 2px solid var(--yellow); border-radius: 50%; position: relative; }
.brand-mark::before, .brand-mark::after, .brand-mark i { content: ""; position: absolute; background: var(--yellow); height: 2px; border-radius: 2px; transform: rotate(-12deg); }
.brand-mark::before { width: 8px; left: 4px; }
.brand-mark i { width: 11px; left: 11px; }
.brand-mark::after { width: 8px; right: 4px; }
.site-nav, .admin-nav { display: flex; align-items: center; gap: 32px; }
.site-nav > a:not(.button) { color: var(--muted); }
.site-nav > a:hover, .site-footer a:hover { color: var(--yellow); }

.button { min-height: 52px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 999px; padding: 0 24px; font-weight: 750; transition: transform .2s ease, background .2s ease, border-color .2s ease; }
.button:hover { transform: translateY(-2px); }
.button-primary { background: var(--yellow); color: #0a0a0a; }
.button-ghost { border-color: var(--line); color: var(--text); background: transparent; }
.button-small { min-height: 42px; padding-inline: 20px; }
.button-wide { width: 100%; }

.hero { min-height: 680px; padding: 100px 0 84px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 80px; align-items: center; }
.eyebrow, .kicker { color: var(--yellow); font-size: .83rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.eyebrow { display: flex; align-items: center; gap: 10px; }
.eyebrow span { width: 8px; height: 8px; border-radius: 50%; background: var(--yellow); box-shadow: 0 0 20px var(--yellow); }
.hero h1, .auth-copy h1 { margin: 20px 0 26px; font-size: clamp(4rem, 7.2vw, 7rem); line-height: .91; letter-spacing: -.075em; }
h1 em, h2 em { color: var(--yellow); font-style: normal; }
.hero-lead { max-width: 620px; margin: 0; font-size: 1.25rem; color: #b7b7bd; line-height: 1.65; }
.hero-actions { margin-top: 38px; display: flex; gap: 22px; align-items: center; }
.release-note { color: var(--muted); font-size: .9rem; max-width: 180px; }

.pulse-panel { min-height: 480px; padding: 32px; border: 1px solid var(--line); border-radius: 36px; background: linear-gradient(145deg, #202023, #111113); box-shadow: 0 36px 100px rgba(0,0,0,.32); display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; }
.pulse-top { display: flex; justify-content: space-between; color: var(--muted); }
.pulse-top strong { color: var(--yellow); letter-spacing: .12em; }
.pulse-visual { height: 160px; display: flex; align-items: end; gap: 12px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.pulse-visual span { flex: 1; height: 30%; background: var(--yellow); border-radius: 8px 8px 2px 2px; opacity: .3; }
.pulse-visual span:nth-child(2) { height: 46%; opacity: .45; }
.pulse-visual span:nth-child(3) { height: 38%; }
.pulse-visual span:nth-child(4) { height: 72%; opacity: .7; }
.pulse-visual span:nth-child(5) { height: 54%; opacity: .55; }
.pulse-visual span:nth-child(6) { height: 88%; opacity: .9; }
.pulse-visual span:nth-child(7) { height: 100%; opacity: 1; }
.pulse-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.pulse-stats div { display: flex; flex-direction: column; gap: 8px; }
.pulse-stats strong { font-size: 2.25rem; letter-spacing: -.06em; }
.pulse-stats span { color: var(--muted); font-size: .82rem; line-height: 1.35; }

.section { padding: 110px 0; border-top: 1px solid var(--line); }
.section-heading, .data-section { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: end; }
.section-heading h2, .feature-intro h2, .data-section h2 { font-size: clamp(2.4rem, 4.8vw, 4.5rem); line-height: 1; letter-spacing: -.065em; margin: 16px 0 0; }
.section-heading > p, .data-copy p { color: var(--muted); font-size: 1.08rem; max-width: 540px; margin: 0; }
.event-grid { margin-top: 54px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.event-card, .empty-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 28px; }
.event-head { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.event-head div { display: flex; flex-direction: column; }
.event-head strong { font-size: 1.25rem; }
.event-head div span { color: var(--muted); margin-top: 3px; }
.status { display: inline-flex; align-items: center; width: fit-content; min-height: 30px; border-radius: 999px; padding: 4px 10px; font-size: .78rem; font-weight: 800; white-space: nowrap; }
.status-approved { background: #123528; color: var(--green); }
.status-recommended { background: var(--yellow-soft); color: var(--yellow); }
.status-forecast, .status-unknown { background: #26262a; color: #b4b4bc; }
.status-rejected, .status-cancelled { background: #3a1b1b; color: #ff9797; }
.event-money { margin: 40px 0; display: flex; align-items: baseline; justify-content: space-between; }
.event-money strong { font-size: 2.6rem; letter-spacing: -.05em; }
.event-money span { font-size: 1.35rem; color: var(--yellow); font-weight: 800; }
.event-card dl { margin: 0; padding-top: 22px; border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.event-card dl div:last-child { text-align: right; }
.event-card dt { color: var(--muted); font-size: .84rem; }
.event-card dd { margin: 6px 0 0; font-weight: 700; }

.feature-section { display: grid; grid-template-columns: .8fr 1.2fr; gap: 100px; align-items: start; }
.feature-intro { position: sticky; top: 30px; }
.feature-list article { display: grid; grid-template-columns: 50px 1fr; gap: 20px; padding: 32px 0; border-bottom: 1px solid var(--line); }
.feature-list article:first-child { padding-top: 0; }
.feature-list article > span { color: var(--yellow); font-size: .82rem; font-weight: 800; }
.feature-list h3 { font-size: 1.45rem; margin: 0 0 8px; }
.feature-list p { color: var(--muted); margin: 0; max-width: 520px; }
.data-section { align-items: start; }
.data-copy { display: grid; gap: 24px; }
.data-copy p { padding-left: 24px; border-left: 2px solid var(--yellow); }
.site-footer { min-height: 110px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: .85rem; }

.auth-shell { min-height: calc(100vh - 202px); padding: 76px 0; display: grid; grid-template-columns: 1fr 460px; gap: 100px; align-items: center; }
.auth-copy h1 { font-size: clamp(3.5rem, 6.5vw, 6rem); }
.auth-copy p { color: var(--muted); max-width: 450px; font-size: 1.1rem; }
.auth-card { padding: 38px; background: var(--surface); border: 1px solid var(--line); border-radius: 28px; }
.auth-card h2 { margin: 0; font-size: 2rem; letter-spacing: -.04em; }
.auth-card > p { color: var(--muted); margin: 8px 0 28px; }
form label { display: flex; flex-direction: column; gap: 8px; color: #c9c9ce; font-weight: 650; }
.auth-card form { display: grid; gap: 18px; }
input, select, textarea { width: 100%; color: var(--text); background: #101012; border: 1px solid #35353a; border-radius: 12px; min-height: 50px; padding: 0 14px; outline: none; }
textarea { min-height: 130px; padding-top: 12px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--yellow); box-shadow: 0 0 0 3px rgba(255,213,30,.12); }
.back-link { display: inline-block; margin-top: 24px; color: var(--muted); }
.back-link:hover { color: var(--yellow); }
.form-error, .form-success { padding: 14px 16px; border-radius: 12px; margin: 18px 0; }
.form-error { background: #351919; color: #ffabab; border: 1px solid #5a2929; }
.form-success { background: #123528; color: var(--green); border: 1px solid #245b47; }
.single-auth { min-height: calc(100vh - 92px); }

.admin-page .site-header { width: calc(100% - 64px); max-width: none; }
.admin-nav { font-size: .9rem; }
.admin-nav > span { color: var(--muted); }
.admin-nav form { margin: 0; }
.admin-nav button { border: 0; background: none; color: var(--text); padding: 8px; }
.admin-nav button:hover { color: var(--yellow); }
.admin-page .site-footer { display: none; }
.admin-shell { width: min(calc(100% - 64px), 1500px); padding: 54px 0 80px; }
.admin-title { display: flex; align-items: end; justify-content: space-between; gap: 30px; }
.admin-title h1 { margin: 10px 0 0; font-size: clamp(2.6rem, 5vw, 4.5rem); letter-spacing: -.06em; line-height: 1; }
.live-badge { color: var(--muted); display: flex; gap: 9px; align-items: center; }
.live-badge i { width: 8px; height: 8px; background: var(--green); border-radius: 50%; box-shadow: 0 0 12px var(--green); }
.admin-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 42px 0 22px; }
.admin-stats article { min-height: 130px; padding: 22px; border: 1px solid var(--line); background: var(--surface); border-radius: 18px; display: flex; flex-direction: column; justify-content: space-between; }
.admin-stats span { color: var(--muted); }
.admin-stats strong { font-size: 2.3rem; letter-spacing: -.05em; }
.admin-panel { border: 1px solid var(--line); border-radius: 20px; background: var(--surface); overflow: hidden; }
.filters { padding: 18px; display: grid; grid-template-columns: minmax(260px, 1fr) 220px auto; gap: 12px; border-bottom: 1px solid var(--line); }
.filters input, .filters select { min-height: 44px; }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; min-width: 1050px; }
.admin-table th { text-align: left; color: var(--muted); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.admin-table td { padding: 17px 18px; border-bottom: 1px solid #252528; vertical-align: middle; }
.admin-table tr:last-child td { border-bottom: 0; }
.admin-table td:first-child strong, .admin-table td:first-child span { display: block; }
.admin-table td:first-child span { color: var(--muted); font-size: .82rem; margin-top: 2px; }
.published { color: var(--green); }
.draft { color: var(--yellow); }
.edit-link { color: var(--yellow); font-weight: 750; }
.empty-cell { text-align: center; color: var(--muted); padding: 50px !important; }
.audit-panel { margin-top: 22px; padding: 26px; border: 1px solid var(--line); border-radius: 20px; }
.audit-panel h2 { margin: 0 0 18px; font-size: 1.25rem; }
.audit-panel p { display: grid; grid-template-columns: 200px 1fr auto; gap: 20px; margin: 0; padding: 12px 0; border-top: 1px solid #242427; color: var(--muted); }
.audit-panel strong { color: var(--text); font-weight: 600; }

.form-shell { max-width: 1050px; }
.event-form { display: grid; gap: 20px; margin-top: 36px; }
.event-form section { padding: 28px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.form-section-title { display: flex; gap: 14px; align-items: center; margin-bottom: 24px; }
.form-section-title span { color: var(--yellow); font-weight: 800; font-size: .8rem; }
.form-section-title h2 { margin: 0; font-size: 1.35rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid-3 { grid-template-columns: repeat(3, 1fr); }
.span-2 { grid-column: span 2; }
.check-field { grid-column: span 2; flex-direction: row; align-items: center; }
.check-field input { width: 20px; min-height: 20px; accent-color: var(--yellow); }
.form-actions { display: flex; justify-content: end; gap: 12px; }

.legal-page, .error-page { padding: 90px 0 120px; min-height: calc(100vh - 202px); max-width: 840px; }
.legal-page h1, .error-page h1 { font-size: clamp(3rem, 6vw, 5.5rem); line-height: .96; letter-spacing: -.065em; margin: 20px 0; }
.legal-date { color: var(--muted); }
.legal-page section { margin-top: 54px; }
.legal-page h2 { margin: 38px 0 10px; }
.legal-page p, .error-page p { color: var(--muted); font-size: 1.05rem; }
.error-page .button { margin-top: 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

@media (max-width: 900px) {
  .hero, .auth-shell, .feature-section, .section-heading, .data-section { grid-template-columns: 1fr; }
  .hero { gap: 54px; padding-top: 70px; }
  .pulse-panel { min-height: 400px; }
  .section-heading, .data-section { gap: 28px; }
  .feature-section { gap: 54px; }
  .feature-intro { position: static; }
  .auth-shell { gap: 48px; }
  .auth-card { max-width: 560px; }
  .admin-stats { grid-template-columns: repeat(2, 1fr); }
  .form-grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .site-header, .site-footer, main { width: min(calc(100% - 30px), var(--max)); }
  .site-header { height: 76px; }
  .site-nav { gap: 12px; }
  .site-nav > a:not(.button) { display: none; }
  .hero { min-height: 0; padding: 62px 0; }
  .hero h1, .auth-copy h1 { font-size: 3.65rem; }
  .hero-actions { align-items: start; flex-direction: column; }
  .pulse-panel { padding: 24px; border-radius: 26px; min-height: 390px; }
  .pulse-stats { gap: 10px; }
  .pulse-stats strong { font-size: 1.75rem; }
  .section { padding: 76px 0; }
  .event-grid { grid-template-columns: 1fr; }
  .event-head { flex-direction: column; }
  .feature-list article { grid-template-columns: 40px 1fr; }
  .site-footer { padding: 28px 0; align-items: start; min-height: 160px; flex-direction: column; }
  .auth-shell { padding: 54px 0 80px; }
  .auth-card { padding: 26px; }
  .admin-page .site-header, .admin-shell { width: calc(100% - 28px); }
  .admin-nav > span { display: none; }
  .admin-nav { gap: 8px; }
  .admin-title { align-items: start; flex-direction: column; }
  .admin-stats { grid-template-columns: 1fr 1fr; }
  .admin-stats article { min-height: 110px; padding: 18px; }
  .filters { grid-template-columns: 1fr; }
  .audit-panel p { grid-template-columns: 1fr; gap: 2px; }
  .form-grid, .form-grid-3 { grid-template-columns: 1fr; }
  .span-2, .check-field { grid-column: span 1; }
  .form-actions { flex-direction: column-reverse; }
  .form-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
