/* ===========================================================================
   EQT Club — Design Theme
   Single source of truth for tokens, base styles, typography, and reusable
   primitives. Page-specific layouts live with the page, not here.
   =========================================================================== */


/* ---------------------------------------------------------------------------
   1. Tokens
   --------------------------------------------------------------------------- */
:root {

    /* Surfaces — warm, paper-like, not stark white */
    --cream:        #faf8f3;   /* page background */
    --cream-soft:   #f3efe5;   /* recessed panels, subtle fills */
    --paper:        #ffffff;   /* cards, dialogs, anything elevated */

    /* Ink — slightly warm near-black, not pure #000 */
    --ink:          #1a1f2e;   /* primary text and headings */
    --ink-soft:     #2c3242;   /* body copy emphasis */
    --muted:        #6b7184;   /* secondary text, labels */
    --muted-soft:   #9aa0b1;   /* faintest text on dark surfaces */

    /* Rules — barely visible dividers in the warm range */
    --rule:         #e8e3d6;
    --rule-soft:    #f0ebdd;

    /* Accents */
    --forest:       #1f3a3d;   /* primary brand accent — buttons, dark surfaces */
    --forest-deep:  #15282a;   /* hover, deeper variants */
    --brass:        #b8956a;   /* warm highlight — progress, eyebrows, pills */
    --brass-deep:   #9a7a52;   /* hover, accessible text colour */

    /* Status colours — used sparingly */
    --green:        #3d6b4a;   /* positive performance */
    --amber:        #c2851f;   /* in-progress, warning */
    --quiet-red:    #a8483b;   /* negative — kept muted by design */

    /* Type stacks
       Cormorant Garamond is the intended display face. We do not load it
       from a CDN (privacy + reliability + no FOUT in offline contexts) —
       systems that have it installed will use it; everywhere else falls
       back to Georgia, which carries the same general character. */
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    --font-serif: 'Cormorant Garamond', 'Georgia', 'Times New Roman', serif;
}


/* ---------------------------------------------------------------------------
   2. Reset and base
   --------------------------------------------------------------------------- */
* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
    background: var(--cream);
    color: var(--ink);
    font-size: 15px;
    line-height: 1.55;
}

a { color: inherit; text-decoration: none; }


/* ---------------------------------------------------------------------------
   3. Typography
   --------------------------------------------------------------------------- */
h1, h2, h3, h4 {
    font-family: var(--font-serif);
    font-weight: 500;
    letter-spacing: 0.005em;
    color: var(--ink);
    line-height: 1.15;
}

/* Apply the serif face to any element — useful for inline display text */
.serif {
    font-family: var(--font-serif);
    font-weight: 400;
    letter-spacing: 0.005em;
}

/* Eyebrow / kicker — sits above headings to set context */
.eyebrow {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--brass-deep);
    font-weight: 500;
}
.eyebrow-muted {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--muted);
    font-weight: 500;
}


/* ---------------------------------------------------------------------------
   4. Layout containers
   --------------------------------------------------------------------------- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}
.container-narrow {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 32px;
}


/* ---------------------------------------------------------------------------
   5. Brand mark
   --------------------------------------------------------------------------- */
.brand { display: flex; align-items: baseline; gap: 10px; }

.brand-mark {
    font-family: var(--font-serif);
    font-size: 28px;
    font-weight: 500;
    letter-spacing: 0.08em;
    color: var(--ink);
}
.brand-divider {
    width: 1px;
    height: 18px;
    background: var(--rule);
}
.brand-tag {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--muted);
}


/* ---------------------------------------------------------------------------
   6. Buttons
   --------------------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: 2px;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.18s;
    border: 1px solid transparent;
    letter-spacing: 0.04em;
}
.btn-primary {
    background: var(--forest);
    color: var(--cream);
    border-color: var(--forest);
}
.btn-primary:hover { background: var(--forest-deep); border-color: var(--forest-deep); }

.btn-brass {
    background: var(--brass);
    color: var(--ink);
    border-color: var(--brass);
}
.btn-brass:hover { background: var(--brass-deep); border-color: var(--brass-deep); }

.btn-outline {
    background: transparent;
    color: var(--ink);
    border-color: var(--ink);
}
.btn-outline:hover { background: var(--ink); color: var(--cream); }

.btn-outline-light {
    background: transparent;
    color: var(--cream);
    border-color: var(--cream);
}
.btn-outline-light:hover { background: var(--cream); color: var(--ink); }

.btn-ghost {
    background: transparent;
    color: var(--ink);
    border-color: var(--rule);
}
.btn-ghost:hover { border-color: var(--ink); }

.btn-sm { padding: 7px 14px; font-size: 12px; }
.btn-lg { padding: 14px 28px; font-size: 14px; }


/* ---------------------------------------------------------------------------
   7. Pills (status tags)
   --------------------------------------------------------------------------- */
.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 2px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 500;
}
.pill-live { background: var(--forest); color: var(--cream); }
.pill-live::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--brass);
    box-shadow: 0 0 0 3px rgba(184, 149, 106, 0.25);
}
.pill-closed     { background: var(--cream-soft); color: var(--muted); border: 1px solid var(--rule); }
.pill-renovating { background: rgba(194, 133, 31, 0.12); color: var(--amber); }
.pill-operating  { background: rgba(61, 107, 74, 0.12);  color: var(--green); }
.pill-exited     { background: rgba(26, 31, 46, 0.06);   color: var(--ink-soft); }
.pill-watching   { background: var(--cream-soft); color: var(--muted); }


/* ---------------------------------------------------------------------------
   8. Form controls
   --------------------------------------------------------------------------- */
.form-group { margin-bottom: 18px; }

.form-group label {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted);
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid var(--rule);
    background: var(--paper);
    color: var(--ink);
    font-family: inherit;
    font-size: 14px;
    border-radius: 2px;
    transition: border-color 0.15s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--forest);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}


/* ---------------------------------------------------------------------------
   9. Reusable primitives
   --------------------------------------------------------------------------- */

/* Avatar — small initials chip used in member top bars */
.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--forest);
    color: var(--cream);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-serif);
    font-size: 16px;
    letter-spacing: 0.05em;
}

/* Commitment progress bar — used wherever an SPV close is in progress */
.commitment-bar {
    height: 6px;
    background: var(--cream-soft);
    border-radius: 3px;
    overflow: hidden;
}
.commitment-bar .fill {
    height: 100%;
    background: linear-gradient(to right, var(--brass), var(--brass-deep));
    border-radius: 3px;
}

/* Numbers table — financial / structured-data presentation
   Default behaviour: muted label on the left, serif numeric value on the right.
   Add tr.total to a row for a heavier rule above and larger figure. */
.numbers-table {
    width: 100%;
    border-collapse: collapse;
    margin: 8px 0 12px;
}
.numbers-table tr { border-bottom: 1px solid var(--rule-soft); }
.numbers-table tr:last-child { border-bottom: none; }
.numbers-table th, .numbers-table td {
    text-align: left;
    padding: 14px 0;
    font-size: 14px;
}
.numbers-table th {
    color: var(--muted);
    font-weight: 400;
    width: 50%;
}
.numbers-table td {
    color: var(--ink);
    font-family: var(--font-serif);
    font-size: 18px;
    text-align: right;
    font-variant-numeric: tabular-nums;
}
.numbers-table tr.total {
    border-top: 2px solid var(--ink);
    border-bottom: none;
}
.numbers-table tr.total th, .numbers-table tr.total td {
    font-weight: 600;
    color: var(--ink);
    padding-top: 16px;
}
.numbers-table tr.total td { font-size: 22px; }

/* Image placeholder — for prototyping before real photography is in place.
   Remove or replace with <img> when production assets arrive. */
.img-placeholder {
    background:
        linear-gradient(135deg, rgba(31, 58, 61, 0.78), rgba(21, 40, 42, 0.92)),
        radial-gradient(ellipse at 30% 30%, rgba(184, 149, 106, 0.4), transparent 60%),
        linear-gradient(180deg, #2d4548 0%, #1a2c2f 100%);
    color: var(--cream);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}
.img-placeholder::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(45deg, transparent 0 20px, rgba(255,255,255,0.012) 20px 21px),
        repeating-linear-gradient(-45deg, transparent 0 30px, rgba(0,0,0,0.04) 30px 31px);
    pointer-events: none;
}
.img-placeholder span {
    position: relative;
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 14px;
    opacity: 0.55;
    letter-spacing: 0.05em;
    z-index: 1;
}
