/* news.endpointr.com — public landing page styles.
   Mirrors the admin design system (admin/assets/app.css). Light + dark
   themes via [data-theme] on <html>; cookie-shared with the admin. */

:root {
    --ink-1: #1a1a1a;
    --ink-2: #2d2d2d;
    --ink-3: #6b6b6b;
    --paper-1: #fafaf7;
    --paper-2: #f4f1ea;
    --rule: #e6e3dc;
    --accent: #8b2c1d;
    --accent-soft: #f9ede9;
    --accent-light: #d4876a;
    --danger: #b13b2a;
    --ok: #2d6a4f;

    --bg: var(--paper-1);
    --bg-2: var(--paper-2);
    --fg: var(--ink-1);
    --fg-muted: var(--ink-3);
    --border: var(--rule);
    --card: #ffffff;

    --font-serif: 'Fraunces', Georgia, serif;
    --font-sans:  'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    --font-mono:  'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

    --radius: 6px;
    --maxw: 1100px;
}

html[data-theme='dark'] {
    --bg: #131311;
    --bg-2: #1c1c19;
    --fg: #fafaf7;
    --fg-muted: #9a9690;
    --border: #2c2c28;
    --card: #1a1a17;
    --accent: #d4876a;
    --accent-soft: rgba(212, 135, 106, 0.10);
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--fg);
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

code, pre, .mono { font-family: var(--font-mono); font-size: 0.92em; }
pre {
    background: var(--bg-2);
    padding: 1rem;
    border-radius: var(--radius);
    overflow: auto;
    border: 1px solid var(--border);
}

h1, h2, h3 { font-family: var(--font-serif); font-weight: 500; line-height: 1.15; margin: 0; }
h1 { font-size: 3rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.2rem; }
em { color: var(--accent); font-style: normal; }

.kicker {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
}
.muted { color: var(--fg-muted); }

/* ---- Topbar ---- */
.topbar {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 2rem;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 5;
}
.brand { color: var(--fg); font-family: var(--font-serif); font-size: 1.15rem; }
.brand-mark em { color: var(--accent); font-style: normal; }
.topbar-right { display: flex; align-items: center; gap: 1rem; justify-self: end; }
.theme-toggle {
    background: transparent; border: 1px solid var(--border); color: var(--fg);
    width: 32px; height: 32px; border-radius: 50%; cursor: pointer;
}
.signin-link {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--fg-muted);
    padding: 0.4rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.signin-link:hover { color: var(--accent); border-color: var(--accent); text-decoration: none; }

/* ---- Page chrome ---- */
.page { max-width: var(--maxw); margin: 0 auto; padding: 4rem 1.5rem 5rem; }

.section { display: flex; flex-direction: column; gap: 1.25rem; }
.section + .section { margin-top: 3.5rem; }

/* ---- Hero ---- */
.hero { display: flex; flex-direction: column; gap: 1.25rem; max-width: 760px; }
.hero-title { font-size: 3.2rem; line-height: 1.05; }
.hero-dek {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    color: var(--fg-muted);
    margin: 0;
    max-width: 64ch;
    line-height: 1.5;
}
.hero-cta { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 0.5rem; }

/* ---- Buttons ---- */
.btn {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    border: 0;
    border-radius: var(--radius);
    padding: 0.7rem 1.25rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 0.85rem;
    cursor: pointer;
    text-decoration: none;
}
.btn:hover { background: var(--accent-light); text-decoration: none; }
.btn-ghost {
    background: transparent;
    color: var(--fg);
    border: 1px solid var(--border);
}
.btn-ghost:hover { color: var(--accent); border-color: var(--accent); }

/* ---- Callouts ---- */
.callout {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem 1.75rem;
}
.callout-label {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--fg-muted);
    display: block;
    margin-bottom: 0.85rem;
}

/* ---- Pipeline grid ---- */
.pipeline {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}
.pipeline-step {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}
.pipeline-step .step-num {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--accent);
    letter-spacing: 0.08em;
}
.pipeline-step h3 { font-size: 1.05rem; }
.pipeline-step p { margin: 0; color: var(--fg-muted); font-size: 0.92rem; }

/* ---- API list ---- */
.endpoint-list { list-style: none; padding: 0; margin: 0; }
.endpoint-list li {
    padding: 0.7rem 0;
    border-bottom: 1px dashed var(--border);
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: baseline;
}
.endpoint-list li:last-child { border-bottom: 0; }
.endpoint-list code {
    background: var(--bg-2);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
}
.endpoint-list .endpoint-desc { color: var(--fg-muted); font-size: 0.92rem; }

/* ---- Footer ---- */
.footer {
    border-top: 1px solid var(--border);
    padding: 2rem 1.5rem;
    color: var(--fg-muted);
    font-family: var(--font-mono);
    font-size: 0.82rem;
    text-align: center;
}
.footer em { color: var(--accent); font-style: normal; }

/* ---- Responsive ---- */
@media (max-width: 640px) {
    .hero-title { font-size: 2.4rem; }
    .hero-dek { font-size: 1.05rem; }
    .page { padding: 2.5rem 1.25rem 3.5rem; }
}
