/* ================================================================
   Koher Website System v0.1.1
   ----------------------------------------------------------------
   Scope: koher.app and any future "website-shaped" Koher property
          (a publication surface, an essay site, a practice index).

   This is NOT the system for Koher tools. Tools use koher-ui.css.
   See CLAUDE.md in this folder for the rule.

   Origin: extracted 30 April 2026 from website-beta-v2/public/css/
   site.css — the same file koher.app currently ships. Refined for
   portability so a sibling website project can adopt it by
   reference rather than by copy.

   Design language:
     - Cream + dark-ink-brown duotone, terracotta accent
     - Shared theme system (theme-light / theme-dark) via body class
     - Page-level theming: each page chooses its register
     - Same fonts as koher-ui.css (Fraunces / Source Serif 4 /
       IBM Plex Sans + Mono) so cross-property typography reads
       as one practice
   ================================================================ */


/* === DESIGN TOKENS ============================================ */
:root {
    /* Brand */
    --color-bg-dark: #2D3436;
    --color-bg-light: #F7F3ED;
    --color-accent: #C75B39;
    --color-highlight: #E8B86D;
    --color-solid: #6DBE6D;

    /* Light surface */
    --color-text-on-light: #2D3436;
    --color-muted-on-light: #6b6560;
    --color-border-light: #e5e2df;

    /* Dark surface */
    --color-text-on-dark: #F7F3ED;
    --color-muted-on-dark: #9A8F85;
    --color-border-dark: #4A4543;

    /* Typography (must match koher-ui.css so the practice reads
       as one across website + tools) */
    --font-display: 'Fraunces', serif;
    --font-body: 'Source Serif 4', serif;
    --font-ui: 'IBM Plex Sans', sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;

    /* Layout */
    --content-width: 720px;
}


/* === THEME SYSTEM =============================================
   Pages set body class to 'theme-light' or 'theme-dark'. Any
   component that uses --page-* vars adapts automatically.

   ----------------------------------------------------------------
   The light/dark split is content-coded, not decorative.
   ----------------------------------------------------------------

   DARK (theme-dark) — pages that DECLARE.
     The practice speaking outward. Canonical, monumental,
     authoritative. Used for: home, tools, positions, notes.
     The voice is third-person Koher; the page is a practice
     surface that takes a position and stands behind it.

   LIGHT (theme-light) — pages that LIST or RECORD.
     The practice speaking in a personal register. Slow-time,
     accumulating, list-shaped, biographical. Used for: about,
     values, reading-list, changelog, voice. The voice is
     first-person Prayas; the page collects, names, attends.

   The split is by content register, not by section type. A page
   that declares a position belongs in dark even if it is short.
   A page that names how the practice works (values), or accrues
   over time (changelog, reading-list), or speaks personally
   (about), belongs in light.

   Why this split exists. The website carries two voices at once.
   See koher-public-voice-split.md and koher-brand-guidelines for
   the full register split: third-person Koher (declarative,
   monumental, dark) vs. first-person Prayas (personal, slow,
   light). The dark/light surface choice is the visual register
   matched to the content register, page by page.

   When in doubt: ask whether the page is making a claim or
   keeping a record. Claims go dark. Records go light.
   ============================================================== */
body.theme-light {
    color: var(--color-text-on-light);
    background: var(--color-bg-light);
    --page-text: var(--color-text-on-light);
    --page-muted: var(--color-muted-on-light);
    --page-border: var(--color-border-light);
    --page-bg: var(--color-bg-light);
}

body.theme-dark {
    color: var(--color-text-on-dark);
    background: var(--color-bg-dark);
    --page-text: var(--color-text-on-dark);
    --page-muted: var(--color-muted-on-dark);
    --page-border: var(--color-border-dark);
    --page-bg: var(--color-bg-dark);
}


/* === RESET ==================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 18px;
    line-height: 1.7;
}


/* === SITE NAVIGATION ==========================================
   Standard Koher header: braid mark on the left (skipped on the
   home page where the page IS the brand), nav links on the
   right, hamburger collapse on mobile.
   ============================================================== */
.site-nav {
    padding: 16px 24px;
    background: var(--page-bg);
    border-bottom: 1px solid var(--page-border);
}

.site-nav .nav-container {
    max-width: var(--content-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-nav .nav-container.nav-no-logo {
    justify-content: flex-end;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.nav-logo svg {
    width: 28px;
    height: 28px;
}

.nav-logo span {
    font-family: var(--font-ui);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.1em;
    color: var(--page-muted);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-links a {
    font-family: var(--font-ui);
    font-size: 13px;
    color: var(--page-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: var(--color-accent);
    text-decoration: none;
}

.nav-links a.active {
    color: var(--page-text);
}

.nav-links a.external::after {
    content: ' \2197';
    font-size: 11px;
    opacity: 0.6;
}

/* Hamburger button — hidden on desktop */
.nav-hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    -webkit-tap-highlight-color: transparent;
}

.nav-hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--page-muted);
    margin: 4px 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-hamburger.open span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.nav-hamburger.open span:nth-child(2) {
    opacity: 0;
}

.nav-hamburger.open span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

@media (max-width: 640px) {
    .nav-hamburger {
        display: block;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--page-bg);
        border-bottom: 1px solid var(--page-border);
        padding: 16px 24px;
        flex-direction: column;
        gap: 0;
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links a {
        font-size: 15px;
        padding: 12px 0;
        border-bottom: 1px solid var(--page-border);
    }

    .nav-links a:last-child {
        border-bottom: none;
    }

    .nav-links a.hide-mobile {
        display: none;
    }

    .site-nav {
        position: relative;
    }
}


/* === LAYOUT =================================================== */
main {
    padding: 60px 24px 100px;
}

.container {
    max-width: var(--content-width);
    margin: 0 auto;
}


/* === TYPOGRAPHY =============================================== */
h1 {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 36px;
    line-height: 1.2;
    margin-bottom: 32px;
}

h2 {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 24px;
    line-height: 1.3;
    margin-top: 48px;
    margin-bottom: 16px;
}

h3 {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 19px;
    line-height: 1.35;
    margin-top: 32px;
    margin-bottom: 12px;
}

p {
    margin-bottom: 20px;
}

p:last-child {
    margin-bottom: 0;
}

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

a:hover {
    text-decoration: underline;
}

.muted {
    color: var(--page-muted);
}


/* === COMMON COMPONENTS ======================================== */
.lead {
    font-size: 20px;
    line-height: 1.6;
    color: var(--page-muted);
    margin-bottom: 40px;
}

.page-subtitle {
    font-size: 17px;
    color: var(--page-muted);
    margin-bottom: 60px;
    max-width: 600px;
}

.pull-quote {
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 400;
    color: var(--color-accent);
    margin: 40px 0;
    padding: 24px 0;
    border-top: 1px solid var(--page-border);
    border-bottom: 1px solid var(--page-border);
}

.info-card {
    background: var(--color-bg-light);
    border: 1px solid var(--color-border-light);
    padding: 24px;
    margin: 32px 0;
    border-left: 3px solid var(--color-accent);
}

.info-card h3 {
    font-family: var(--font-ui);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-top: 0;
    margin-bottom: 12px;
}

.info-card p {
    margin-bottom: 0;
    font-size: 16px;
}

.simple-list {
    list-style: none;
    margin: 24px 0;
}

.simple-list li {
    padding: 8px 0;
    padding-left: 24px;
    position: relative;
}

.simple-list li::before {
    content: '\2014';
    position: absolute;
    left: 0;
    color: var(--page-muted);
}


/* === FOOTER =================================================== */
footer {
    padding: 20px 24px 28px;
    text-align: center;
    font-size: 13px;
    color: var(--page-muted);
    border-top: 1px solid var(--page-border);
}

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

footer a:hover {
    text-decoration: underline;
}


/* === RESPONSIVE =============================================== */
@media (max-width: 540px) {
    h1 {
        font-size: 28px;
    }

    h2 {
        font-size: 22px;
    }

    .lead {
        font-size: 18px;
    }

    .pull-quote {
        font-size: 20px;
    }
}
