/* ============================================================
   WATT ALLIANCE — Shared Styles
   Used by: wa1.html, article.html, get-started.html
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,ital,wght@9..144,0,300;9..144,0,400;9..144,0,500;9..144,1,300;9..144,1,400&family=Inter:wght@300;400;500;600&display=swap');

/* ---- Variables ---- */
:root {
    --bg: #0a0a0a;
    --bg-white: #fafaf7;
    --ink: #111111;
    --ink-dim: #666666;
    --ink-soft: #999999;
    --accent: #C41E1E;
    --accent-dark: #9A1818;
    --border: rgba(255,255,255,0.1);
    --border-dark: rgba(0,0,0,0.1);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', -apple-system, sans-serif;
    font-weight: 400;
    background: var(--bg-white);
    color: var(--ink);
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
img, video { max-width: 100%; display: block; }

/* ---- Typography ---- */
.display {
    font-family: 'Fraunces', serif;
    font-weight: 400;
    font-optical-sizing: auto;
    line-height: 1.02;
    letter-spacing: -0.02em;
}

/* ---- Layout ---- */
.container {
    max-width: 1600px;
    margin-inline: auto;
    padding-inline: 1.5rem;
}
@media (min-width: 768px)  { .container { padding-inline: 3rem; } }
@media (min-width: 1280px) { .container { padding-inline: 4rem; } }

/* ---- Header / Navbar ---- */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    padding: 1.25rem 0;
    transition: background 0.3s ease, backdrop-filter 0.3s ease, padding 0.3s ease, border-color 0.3s ease;
    border-bottom: 1px solid transparent;
}
.site-header.scrolled {
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 0.875rem 0;
    border-bottom-color: rgba(255,255,255,0.08);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; }
.logo { display: flex; align-items: center; z-index: 10; }
.logo img { height: 36px; width: auto; }
.site-nav { display: none; gap: 2.5rem; }
@media (min-width: 1024px) { .site-nav { display: flex; } }
.site-nav a { color: #fff; font-size: 0.875rem; font-weight: 400; transition: opacity .2s; }
.site-nav a:hover { opacity: 0.6; }
.site-cta {
    color: #fff; font-size: 0.875rem;
    display: inline-flex; align-items: center; gap: 0.5rem;
    border-bottom: 1px solid #fff; padding-bottom: 2px; transition: opacity .2s;
}
.site-cta:hover { opacity: 0.7; }

/* ---- Buttons ---- */
.btn-primary {
    display: inline-flex; align-items: center; gap: 0.75rem;
    background: var(--accent); color: #fff;
    padding: 1rem 2rem;
    font-size: 0.8125rem; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 600;
    transition: background .2s, gap .3s;
}
.btn-primary:hover { background: var(--accent-dark); gap: 1.25rem; }
.btn-primary::after { content: '→'; font-family: serif; }

.btn-ghost {
    display: inline-flex; align-items: center; gap: 0.75rem;
    border: 1px solid rgba(255,255,255,0.4); color: #fff;
    padding: 1rem 2rem;
    font-size: 0.8125rem; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 600;
    transition: border-color .2s, gap .3s;
}
.btn-ghost:hover { border-color: #fff; gap: 1.25rem; }

.arrow-link {
    display: inline-flex; align-items: center; gap: 0.75rem;
    font-size: 1rem; padding-bottom: 4px; border-bottom: 1px solid currentColor; transition: gap .3s;
}
.arrow-link:hover { gap: 1.25rem; }
.arrow-link::after { content: '→'; display: inline-block; font-family: serif; }

/* ---- Section labels ---- */
.section-label {
    font-size: 0.75rem; letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--ink-dim); margin-bottom: 3rem;
    display: flex; align-items: center; gap: 1rem;
}
.section-label::before { content: ''; display: block; width: 1.5rem; height: 1px; background: currentColor; }
.section-label.accent { color: var(--accent); }
.section-heading {
    font-size: clamp(1.75rem, 4.5vw, 4rem);
    max-width: 22ch; line-height: 1.08; margin-bottom: 3rem;
}
.section-heading em { font-style: italic; font-weight: 300; color: var(--ink-dim); }

/* ---- Mobile nav ---- */
.menu-toggle {
    display: none; background: transparent; border: none;
    color: #fff; font-size: 0.875rem; cursor: pointer; font-family: inherit;
}
@media (max-width: 1023px) {
    .site-nav, .site-cta { display: none; }
    .menu-toggle { display: block; }
}
.mobile-nav {
    position: fixed; inset: 0; background: #000; z-index: 99;
    padding: 6rem 1.5rem 2rem;
    transform: translateY(-100%);
    transition: transform .6s cubic-bezier(0.19, 1, 0.22, 1);
}
.mobile-nav.open { transform: translateY(0); }
.mobile-nav nav { display: flex; flex-direction: column; gap: 1.5rem; }
.mobile-nav a { font-family: 'Fraunces', serif; font-size: 2.5rem; color: #fff; font-weight: 400; line-height: 1; }

/* ---- Scroll reveal ---- */
.reveal {
    opacity: 0; transform: translateY(30px);
    transition: opacity .9s cubic-bezier(0.19, 1, 0.22, 1), transform .9s cubic-bezier(0.19, 1, 0.22, 1);
}
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* ---- Footer ---- */
.site-footer { background: var(--bg-white); padding: 6rem 0 2rem; border-top: 1px solid var(--border-dark); }
.footer-top { display: grid; grid-template-columns: 1fr; gap: 3rem; margin-bottom: 5rem; }
@media (min-width: 768px) { .footer-top { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-col h4 {
    font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--ink-dim); margin-bottom: 1.5rem; font-weight: 600;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 0.85rem; }
.footer-col a { color: var(--ink); font-size: 0.9375rem; transition: color .2s; }
.footer-col a:hover { color: var(--accent); }
.footer-brand img { height: 48px; width: auto; margin-bottom: 1.25rem; }
.footer-brand p { font-size: 0.9375rem; color: var(--ink-dim); line-height: 1.55; max-width: 32ch; }
.footer-bottom {
    padding-top: 2rem; border-top: 1px solid var(--border-dark);
    display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between;
    font-size: 0.8125rem; color: var(--ink-dim);
}
.footer-bottom a { color: var(--ink-dim); transition: color .2s; }
.footer-bottom a:hover { color: var(--accent); }

/* ---- Scroll navbar JS hook ---- */
/* Triggered by wa-nav.js */
