/* 100x — Scripture × Systems Architecture
 *
 * Blue = architecture / systems (the blueprint). Gold = Scripture / sacred.
 * Mobile-first; semantic CSS variables; no gradients/glow/neon.
 */

:root {
    /* Base: deep near-black with navy undertone */
    --bg:           #0A0F1A;
    --bg-deep:      #070B12;

    /* Surface panels: subtly lifted navy */
    --surface:      #111A2A;
    --surface-2:    #182338;
    --hairline:     rgba(0, 176, 240, 0.10);  /* very faint blue */
    --hairline-2:   rgba(255, 255, 255, 0.06);

    /* PROMINENT BLUE — sampled from the 100x logo */
    --blue:         #00B0F0;
    --blue-soft:    #4FC2F2;
    --blue-deep:    #0079B0;

    /* GOLD — refined accent, used sparingly */
    --gold:         #E0A93C;
    --gold-soft:    #F5C76A;

    /* Text */
    --ink:          #F2EDDE;   /* warm off-white for Scripture + hero */
    --text:         #DDE3EE;   /* off-white sans for UI body */
    --muted:        #8A95A8;
    --muted-soft:   #5F6A7C;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
    margin: 0; padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--blue-soft); text-decoration: underline; text-underline-offset: 3px; }

/* === Typography === */
.serif {
    font-family: 'Source Serif 4', 'Source Serif Pro', Georgia, 'Times New Roman', serif;
    color: var(--ink);
    line-height: 1.45;
    letter-spacing: -0.01em;
}
.scripture {
    font-family: 'Source Serif 4', 'Source Serif Pro', Georgia, serif;
    color: var(--ink);
    line-height: 1.6;
}
.verse-num {
    color: var(--blue);
    font-weight: 700;
    margin-right: 0.45rem;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 0.85em;
    vertical-align: 0.1em;
}
.eyebrow {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--blue);
}

.wordmark { color: var(--ink); font-weight: 800; letter-spacing: 0.02em; }
.text-muted { color: var(--muted); }
.text-blue { color: var(--blue); }
.text-gold { color: var(--gold); }
.text-ink { color: var(--ink); }

/* === Buttons === */
.btn-primary {
    background: var(--blue);
    color: #051422;
    font-weight: 700;
    padding: 0.85rem 1.3rem;
    border-radius: 6px;
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 44px;
    border: 1px solid var(--blue);
    transition: filter .15s ease;
}
.btn-primary:hover {
    background: var(--blue-soft);
    border-color: var(--blue-soft);
    color: #051422;
    text-decoration: none;
}
.btn-ghost {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--surface-2);
    padding: 0.85rem 1.3rem;
    border-radius: 6px;
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 44px;
    transition: border-color .15s ease, color .15s ease;
}
.btn-ghost:hover {
    border-color: var(--blue);
    color: var(--blue);
    text-decoration: none;
}
.btn-gold {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
    padding: 0.85rem 1.3rem;
    border-radius: 6px;
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 44px;
}
.btn-gold:hover { color: var(--gold-soft); border-color: var(--gold-soft); text-decoration: none; }

/* === Cards (architecture panels) === */
.panel {
    background: var(--surface);
    border: 1px solid var(--hairline);
    border-radius: 10px;
    padding: 1.1rem;
    position: relative;
    transition: border-color .15s ease, transform .15s ease;
}
.panel:hover { border-color: rgba(0, 176, 240, 0.35); }
/* Architectural "node" dot in the top-left corner of each panel */
.panel::before {
    content: "";
    position: absolute;
    top: -3px; left: -3px;
    width: 7px; height: 7px;
    background: var(--blue);
    border-radius: 9999px;
    opacity: 0.65;
}
.panel-num {
    color: var(--blue);
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 0.2em;
    margin-bottom: 0.35rem;
}
.panel-title {
    color: var(--ink);
    font-family: 'Source Serif 4', serif;
    font-size: 1.2rem;
    line-height: 1.3;
    margin: 0 0 0.3rem 0;
}
.panel-body { color: var(--text); font-size: 0.92rem; line-height: 1.5; }

/* === Header === */
.site-header {
    position: sticky; top: 0; z-index: 40;
    background: var(--bg);
    border-bottom: 1px solid var(--hairline-2);
    backdrop-filter: blur(6px);
}
.brand-mark { display: inline-flex; align-items: center; gap: 0.7rem; }
.brand-mark img {
    height: 40px; width: auto;
    border-radius: 6px;            /* softens the logo's baked-in dark rectangle */
}
@media (min-width: 768px) { .brand-mark img { height: 48px; } }
.brand-sub {
    color: var(--muted);
    font-size: 0.78rem; letter-spacing: 0.08em;
    text-transform: uppercase;
    border-left: 1px solid var(--hairline);
    padding-left: 0.7rem;
}
.brand-sub b { color: var(--text); font-weight: 600; }

/* === Hero — blueprint motif (subtle, faint, never busy) === */
.hero {
    position: relative;
    overflow: hidden;
    padding: 3.5rem 0 3rem 0;
    border-bottom: 1px solid var(--hairline-2);
}
@media (min-width: 640px) { .hero { padding: 5.5rem 0 4.5rem 0; } }

/* Grid lines — 40px square grid, very low opacity blue */
.hero::before {
    content: "";
    position: absolute; inset: 0;
    background-image:
        linear-gradient(to right, rgba(0, 176, 240, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 176, 240, 0.05) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: radial-gradient(ellipse at center top, black 30%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse at center top, black 30%, transparent 75%);
    pointer-events: none;
}
/* Node-and-line trace overlay */
.hero::after {
    content: "";
    position: absolute; inset: 0;
    background-image: url("/static/traces.svg");
    background-repeat: no-repeat;
    background-position: right center;
    background-size: clamp(380px, 60%, 700px) auto;
    opacity: 0.55;
    pointer-events: none;
}
.hero-content { position: relative; z-index: 2; }

.hero h1 {
    font-family: 'Source Serif 4', serif;
    color: var(--ink);
    font-weight: 600;
    font-size: 2.4rem;     /* mobile */
    line-height: 1.08;
    letter-spacing: -0.02em;
    margin: 0.5rem 0 1rem 0;
}
@media (min-width: 640px) { .hero h1 { font-size: 3.4rem; } }
@media (min-width: 1024px) { .hero h1 { font-size: 4.2rem; } }

.hero-sub {
    color: var(--text);
    font-size: 1.05rem; line-height: 1.55;
    max-width: 38rem;
}
.hero-support {
    color: var(--muted);
    margin-top: 0.7rem; font-size: 0.95rem;
}

/* === Forms === */
input[type=text], input[type=email], input[type=password], textarea, select {
    width: 100%;
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--surface-2);
    border-radius: 6px;
    padding: 0.85rem 0.95rem;
    font-size: 1rem;
    min-height: 44px;
}
input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--blue);
    box-shadow: 0 0 0 3px rgba(0, 176, 240, 0.18);
}

button, .tap { min-height: 44px; }

/* === Hairline divider === */
hr.soft { border: none; border-top: 1px solid var(--hairline-2); margin: 1.25rem 0; }

/* === Floating chat widget === */
#chat-fab {
    position: fixed;
    bottom: 1rem; right: 1rem;
    width: 56px; height: 56px;
    border-radius: 9999px;
    background: var(--gold);             /* sacred accent for the "ask Scripture" function */
    color: #1a1100;
    display: grid; place-items: center;
    font-size: 1.55rem; font-weight: 800;
    box-shadow: 0 6px 22px rgba(224, 169, 60, 0.30);
    cursor: pointer; border: none;
    z-index: 50;
}
#chat-fab:hover { background: var(--gold-soft); }

#chat-panel {
    position: fixed;
    left: 0.5rem; right: 0.5rem; bottom: 4.5rem;
    max-height: 80vh;
    background: var(--surface);
    border: 1px solid var(--blue);
    border-radius: 10px;
    z-index: 50;
    display: flex; flex-direction: column;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}
@media (min-width: 640px) { #chat-panel { left: auto; right: 1rem; width: 380px; } }
#chat-panel .messages { flex: 1; overflow-y: auto; padding: 0.85rem; }
.msg {
    margin-bottom: 0.75rem;
    padding: 0.65rem 0.85rem;
    border-radius: 8px;
    line-height: 1.5;
}
.msg-user { background: var(--surface-2); color: var(--ink); }
.msg-asst { background: #0d1f33; color: var(--ink); border-left: 2px solid var(--blue); }
.msg-asst .refs { color: var(--gold); font-size: 0.85rem; margin-top: 0.4rem; }
.msg-error { background: #3b1e1e; color: #ffb8b8; }
#chat-panel .input-row {
    border-top: 1px solid var(--hairline-2);
    padding: 0.55rem; display: flex; gap: 0.5rem;
}
#chat-panel input[type=text] { flex: 1; min-height: 40px; padding: 0.55rem 0.7rem; }
#chat-panel button.send {
    background: var(--blue); color: #051422; font-weight: 700;
    padding: 0 1rem; border-radius: 6px; border: none; min-height: 40px;
}

/* === Verse lists === */
.verse-list { padding-left: 0; list-style: none; margin: 0; }
.verse-list li { margin-bottom: 0.85rem; }

/* === Badges === */
.badge {
    display: inline-block;
    font-size: 0.72rem;
    padding: 0.15rem 0.55rem;
    border-radius: 9999px;
    background: var(--surface-2);
    color: var(--muted);
    margin-right: 0.4rem;
}
.badge.blue { background: rgba(0, 176, 240, 0.14); color: var(--blue); }
.badge.gold { background: rgba(224, 169, 60, 0.15); color: var(--gold); }

/* === Section divider for big page sections === */
.section { padding: 2.5rem 0; }
.section + .section { border-top: 1px solid var(--hairline-2); }

/* === Page headings === */
.page-h1 {
    font-family: 'Source Serif 4', serif;
    color: var(--ink);
    font-size: 1.9rem;
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 1rem 0;
}
@media (min-width: 640px) { .page-h1 { font-size: 2.3rem; } }
.page-eyebrow {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--blue);
    margin-bottom: 0.4rem;
}
