*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --bg: #09090b; --bg2: #111113; --bg3: #1c1c1e;
  --border: #27272a; --text: #e4e4e7; --muted: #71717a;
  --accent: #3b82f6; --accent2: #6366f1; --green: #22c55e; --red: #ef4444; --yellow: #f59e0b;
  --radius: 8px; --max: 1100px;
}
html { scroll-behavior: smooth; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; background: var(--bg); color: var(--text); line-height: 1.7; font-size: 16px; }

/* NAV */
.topnav { background: var(--bg2); border-bottom: 1px solid var(--border); padding: 0 2rem; display: flex; align-items: center; gap: 2rem; position: sticky; top: 0; z-index: 100; height: 56px; }
.topnav .brand { font-weight: 700; font-size: 1.1rem; color: var(--accent); white-space: nowrap; }
.topnav .links { display: flex; gap: 0.25rem; flex-wrap: wrap; }
.topnav a { color: var(--muted); text-decoration: none; padding: 0.4rem 0.75rem; border-radius: var(--radius); font-size: 0.875rem; transition: color 0.15s, background 0.15s; }
.topnav a:hover, .topnav a.active { color: var(--text); background: var(--bg3); }

/* HERO */
.hero { background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%); padding: 5rem 2rem 4rem; text-align: center; border-bottom: 1px solid var(--border); }
.hero h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; line-height: 1.1; margin-bottom: 1rem; background: linear-gradient(135deg, #fff 0%, #a5b4fc 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { color: var(--muted); font-size: 1.125rem; max-width: 600px; margin: 0 auto 2rem; }
.hero .badges { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; }
.badge { display: inline-block; font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase; background: var(--bg3); border: 1px solid var(--border); color: var(--muted); padding: 0.3rem 0.75rem; border-radius: 999px; }
.badge.green { border-color: var(--green); color: var(--green); }
.badge.blue { border-color: var(--accent); color: var(--accent); }
.badge.yellow { border-color: var(--yellow); color: var(--yellow); }

/* LAYOUT */
.container { max-width: var(--max); margin: 0 auto; padding: 3rem 2rem; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.5rem; }

/* SECTIONS */
section { margin-bottom: 4rem; }
section h2 { font-size: 1.75rem; font-weight: 700; margin-bottom: 0.5rem; }
section h3 { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.5rem; color: var(--text); }
section h4 { font-size: 1rem; font-weight: 600; margin-bottom: 0.4rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; }
.section-lead { color: var(--muted); margin-bottom: 2rem; font-size: 1.05rem; }
.divider { border: none; border-top: 1px solid var(--border); margin: 3rem 0; }

/* CARDS */
.card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; }
.card h3 { margin-bottom: 0.75rem; }
.card p { color: var(--muted); font-size: 0.9rem; }
.card .tag { display: inline-block; font-size: 0.7rem; background: var(--bg3); border: 1px solid var(--border); color: var(--muted); padding: 0.2rem 0.5rem; border-radius: 4px; margin-right: 0.25rem; margin-bottom: 0.5rem; }

/* TYPOGRAPHY */
p { margin-bottom: 1rem; color: var(--muted); }
strong { color: var(--text); font-weight: 600; }
em { color: #a5b4fc; }
mark { background: #854d0e; color: #fef08a; padding: 0.1em 0.3em; border-radius: 3px; }
small { font-size: 0.8rem; color: var(--muted); }
h1,h2,h3,h4,h5,h6 { color: var(--text); line-height: 1.3; }
h5 { font-size: 0.9rem; font-weight: 600; color: var(--muted); }
h6 { font-size: 0.8rem; font-weight: 600; color: var(--muted); }

/* BLOCKQUOTE */
blockquote { border-left: 3px solid var(--accent); padding: 1rem 1.5rem; background: var(--bg2); border-radius: 0 var(--radius) var(--radius) 0; margin: 1.5rem 0; }
blockquote p { color: var(--text); font-size: 1.05rem; font-style: italic; margin: 0; }
blockquote cite { display: block; margin-top: 0.5rem; font-size: 0.85rem; color: var(--muted); }

/* LISTS */
ul.styled, ol.styled { padding-left: 1.5rem; margin-bottom: 1rem; }
ul.styled li, ol.styled li { color: var(--muted); margin-bottom: 0.4rem; }
dl { margin-bottom: 1rem; }
dt { color: var(--text); font-weight: 600; margin-top: 0.75rem; }
dd { color: var(--muted); padding-left: 1.5rem; }

/* TABLE */
.table-wrap { overflow-x: auto; margin: 1.5rem 0; }
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
thead { background: var(--bg3); }
th { text-align: left; padding: 0.75rem 1rem; color: var(--text); font-weight: 600; border-bottom: 2px solid var(--border); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em; }
td { padding: 0.75rem 1rem; border-bottom: 1px solid var(--border); color: var(--muted); }
tr:hover td { background: var(--bg2); }
.status { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.8rem; font-weight: 500; }
.status::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status.active { color: var(--green); }
.status.pending { color: var(--yellow); }
.status.inactive { color: var(--red); }

/* CODE */
code { font-family: 'JetBrains Mono', 'Fira Code', monospace; font-size: 0.85em; background: var(--bg3); border: 1px solid var(--border); padding: 0.15em 0.4em; border-radius: 4px; color: #86efac; }
pre { background: var(--bg3); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; overflow-x: auto; margin: 1.5rem 0; }
pre code { background: none; border: none; padding: 0; font-size: 0.85rem; color: #e4e4e7; line-height: 1.6; }

/* FORM */
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
label { font-size: 0.85rem; font-weight: 500; color: var(--text); }
input, textarea, select { background: var(--bg3); border: 1px solid var(--border); color: var(--text); padding: 0.6rem 0.9rem; border-radius: var(--radius); font-size: 0.9rem; font-family: inherit; outline: none; transition: border-color 0.15s; }
input:focus, textarea:focus, select:focus { border-color: var(--accent); }
textarea { resize: vertical; min-height: 120px; }
select option { background: var(--bg3); }
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.65rem 1.4rem; border-radius: var(--radius); font-size: 0.9rem; font-weight: 500; cursor: pointer; border: none; transition: opacity 0.15s; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-secondary { background: var(--bg3); color: var(--text); border: 1px solid var(--border); }
.btn:hover { opacity: 0.85; }
.checkbox-group { display: flex; flex-direction: column; gap: 0.6rem; }
.checkbox-group label { display: flex; align-items: center; gap: 0.6rem; font-size: 0.875rem; color: var(--muted); cursor: pointer; }
input[type="checkbox"], input[type="radio"] { width: 16px; height: 16px; accent-color: var(--accent); }

/* PROGRESS */
.progress-wrap { margin-bottom: 0.75rem; }
.progress-label { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--muted); margin-bottom: 0.3rem; }
.progress { background: var(--bg3); border-radius: 999px; height: 6px; overflow: hidden; }
.progress-bar { height: 100%; border-radius: 999px; background: var(--accent); }

/* ALERT */
.alert { padding: 1rem 1.25rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: 0.9rem; border-left: 3px solid; }
.alert-info { background: #1e3a5f; border-color: var(--accent); color: #93c5fd; }
.alert-success { background: #14532d; border-color: var(--green); color: #86efac; }
.alert-warning { background: #451a03; border-color: var(--yellow); color: #fde68a; }
.alert-error { background: #450a0a; border-color: var(--red); color: #fca5a5; }

/* STATS */
.stat { text-align: center; padding: 1.5rem; }
.stat .value { font-size: 2.5rem; font-weight: 800; color: var(--text); line-height: 1; }
.stat .unit { font-size: 1rem; color: var(--accent); }
.stat .label { font-size: 0.85rem; color: var(--muted); margin-top: 0.25rem; }

/* TIMELINE */
.timeline { position: relative; padding-left: 2rem; }
.timeline::before { content: ''; position: absolute; left: 7px; top: 0; bottom: 0; width: 2px; background: var(--border); }
.timeline-item { position: relative; margin-bottom: 2rem; }
.timeline-item::before { content: ''; position: absolute; left: -1.75rem; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); border: 2px solid var(--bg); }
.timeline-item .date { font-size: 0.75rem; color: var(--muted); margin-bottom: 0.25rem; text-transform: uppercase; letter-spacing: 0.05em; }
.timeline-item h4 { font-size: 0.95rem; font-weight: 600; color: var(--text); margin-bottom: 0.4rem; }

/* AVATAR */
.team-card { display: flex; align-items: flex-start; gap: 1rem; }
.avatar { width: 48px; height: 48px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent2)); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.1rem; color: #fff; flex-shrink: 0; }

/* FOOTER */
footer { background: var(--bg2); border-top: 1px solid var(--border); padding: 3rem 2rem; margin-top: 4rem; }
.footer-grid { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; }
.footer-col h5 { color: var(--text); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 1rem; }
.footer-col a { display: block; color: var(--muted); text-decoration: none; font-size: 0.875rem; margin-bottom: 0.5rem; transition: color 0.15s; }
.footer-col a:hover { color: var(--text); }
.footer-bottom { max-width: var(--max); margin: 2rem auto 0; padding-top: 1.5rem; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; font-size: 0.8rem; color: var(--muted); }
