/*
 * GRACE M. STEELE — index.css
 * TIMBUKTU LLC, 2026
 *
 * HOW TO USE THIS FILE
 * --------------------
 * Colors:    Section 1 (Custom Properties)
 * Spacing:   Section 1 (Custom Properties)
 * Fonts:     Section 4 (Typography)
 * Buttons:   Section 5 (Buttons)
 * Each page section has its own labeled block below.
 */


/* ============================================================
   1. CUSTOM PROPERTIES  (edit colors, spacing, sizes here)
   ============================================================ */

:root {

    /* Brand colors */
    --wine:    #8A2C3B;
    --sienna:  #B5592F;
    --mustard: #C9960E;
    --jade:    #1D8A68;
    --navy:    #1C3A6E;
    --plum:    #7A3661;

    /* Page colors */
    --bg:      #0F0A0C;
    --surface: #1A1216;
    --border:  #2E2028;
    --white:   #FAF5EE;
    --dim:     rgba(250, 245, 238, 0.68);
    --muted:   #8E7E85;

    /* Fonts */
    --font-display: 'Bodoni Moda', Georgia, serif;
    --font-body:    'Crimson Pro', Georgia, serif;
    --font-ui:      'Jost', 'Helvetica Neue', sans-serif;
    --font-mono:    'Courier Prime', 'Courier New', monospace;

    /* Spacing scale */
    --xs:  0.5rem;
    --sm:  1rem;
    --md:  2rem;
    --lg:  4rem;
    --xl:  7rem;

    /* Layout */
    --max-width:     1200px;
    --gem-band-h:    3px;
    --header-height: 72px;
    --header-offset: calc(var(--header-height) + var(--gem-band-h));

    /* Transitions */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease:     cubic-bezier(0.4, 0, 0.2, 1);
    --t:        0.25s cubic-bezier(0.4, 0, 0.2, 1);

    /* Border radius */
    --r-sm: 4px;
    --r-md: 10px;
    --r-lg: 20px;
}


/* ============================================================
   2. RESET
   ============================================================ */

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    background-color: var(--bg);
    color: var(--white);
    font-family: var(--font-body);
    font-size: 1.15rem;
    line-height: 1.72;
    overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a        { color: inherit; text-decoration: none; }
ul, ol   { list-style: none; }

:focus-visible {
    outline: 2px solid var(--mustard);
    outline-offset: 3px;
    border-radius: var(--r-sm);
}


/* ============================================================
   3. TEXT SELECTION
   ============================================================ */

::selection,
::-moz-selection {
    background-color: var(--wine);
    color: var(--white);
}


/* ============================================================
   4. TYPOGRAPHY
   ============================================================ */

h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.01em;
}

p    { font-family: var(--font-body); line-height: 1.78; }
em   { font-style: italic; }
cite { font-style: normal; }


/* ============================================================
   5. BUTTONS
   ============================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--xs);
    padding: 0.78rem 2.1rem;
    font-family: var(--font-ui);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border: 1.5px solid transparent;
    border-radius: var(--r-sm);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: background-color var(--t), border-color var(--t), color var(--t), transform var(--t);
}

/* Shimmer sweep on hover */
.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,0.12) 50%, transparent 65%);
    transform: translateX(-150%);
    transition: transform 0.5s var(--ease-out);
    will-change: transform;
}

.btn:hover        { transform: translateY(-2px); }
.btn:hover::after { transform: translateX(150%); }
.btn:active       { transform: translateY(0); }

/* Primary (filled wine) */
.btn--primary {
    background-color: var(--wine);
    border-color: var(--wine);
    color: var(--white);
}
.btn--primary:hover {
    background-color: #9e3344;
    border-color: #9e3344;
}

/* Outline */
.btn--outline {
    border-color: rgba(250, 245, 238, 0.36);
    color: var(--white);
}
.btn--outline:hover {
    background-color: rgba(250, 245, 238, 0.06);
    border-color: var(--white);
}

/* Ghost */
.btn--ghost {
    border-color: var(--border);
    color: var(--dim);
}
.btn--ghost:hover {
    border-color: var(--muted);
    color: var(--white);
    background-color: rgba(250, 245, 238, 0.04);
}

.btn--with-icon { gap: 0.6rem; }
.btn__icon      { flex-shrink: 0; }


/* ============================================================
   6. SHARED SECTION LAYOUT
   ============================================================ */

/*
 * Every section fills the viewport height.
 * To change padding/spacing for a section, edit the section
 * specific rule below (e.g. .section--works) rather than this shared rule.
 */
.section {
    position: relative;
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: calc(var(--header-offset) + var(--lg));
    padding-bottom: 5.5rem;  /* space for the Continue button */
}

/* Inner container — controls max-width and side padding */
.section__inner {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--md);
}

/* Two-column layout (About Preview) */
.section__inner--split {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: var(--lg);
}

/* Single centered column (Connect) */
.section__inner--centered {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

/* Section header block (centered heading group) */
.section__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: var(--lg);
}

/* Small label above headings */
.section__eyebrow {
    display: block;
    font-family: var(--font-ui);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--mustard);
    margin-bottom: 0.85rem;
    position: relative;
}

/* Ink-stroke underline that draws in when .is-in is added by JS */
.section__eyebrow::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, var(--wine), var(--mustard));
    border-radius: 1px;
    transform: translateX(-50%) scaleX(0);
    transform-origin: left;
    transition: transform 0.7s var(--ease-out);
}

.section__eyebrow.is-in::after {
    transform: translateX(-50%) scaleX(1);
}

/* Section title */
.section__title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--white);
    margin-bottom: var(--sm);
    position: relative;
}

/* Short ink stroke under section titles */
.section__title::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--wine), transparent);
    border-radius: 1px;
    transition: width 0.9s var(--ease-out);
}

/* Center the stroke when the title is inside .section__header */
.section__header .section__title::after {
    left: 50%;
    transform: translateX(-50%);
}

.section__title.is-in::after {
    width: 3.5rem;
}

/* Subtitle / intro paragraph */
.section__subtitle {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: var(--dim);
    max-width: 52ch;
    line-height: 1.7;
    font-style: italic;
    text-align: center;
}

/* Large faint chapter numeral watermark (decorative) */
.section__chapter {
    position: absolute;
    top: calc(var(--header-offset) + 1rem);
    right: var(--md);
    font-family: var(--font-display);
    font-size: clamp(5rem, 12vw, 9rem);
    font-style: italic;
    font-weight: 600;
    color: var(--wine);
    opacity: 0.04;
    pointer-events: none;
    user-select: none;
    line-height: 1;
    z-index: 0;
}

/* "Continue" button at the bottom of each section */
.section__next-btn {
    position: absolute;
    bottom: 1.75rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--muted);
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 0.75rem 1.25rem;
    transition: color var(--t);
    z-index: 5;
}

.section__next-btn:hover { color: var(--white); }

.section__next-icon {
    display: block;
    transition: transform 0.3s var(--ease-out);
    animation: bounce 2.4s ease-in-out infinite;
}

.section__next-btn:hover .section__next-icon {
    transform: translateY(4px);
}


/* ============================================================
   7. ANIMATION SYSTEM
   ============================================================
   Elements with .anim-write start hidden.
   JS adds .is-in to type them in (left to right).
   JS adds .is-out to erase them (right to left, like backspace).
   JS sets --write-delay per element for stagger timing.
   ============================================================ */

.anim-write {
    clip-path: inset(0 100% 0 0);
    opacity: 0;
}

.anim-write.is-in {
    animation: write-in 0.75s var(--ease-out) var(--write-delay, 0s) both;
}

.anim-write.is-out {
    animation: write-out 0.45s ease-in var(--write-delay, 0s) both;
}


/* ============================================================
   8. GRAIN OVERLAY  (fixed, decorative)
   ============================================================ */

.site-grain {
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 220px 220px;
    opacity: 0.025;
    animation: grain 0.2s steps(1) infinite;
}


/* ============================================================
   9. GEM BAND  (6-stripe color bar pinned to top of viewport)
   ============================================================ */

.site-gem-band {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--gem-band-h);
    display: flex;
    z-index: 1000;
}

.site-gem-band__stripe {
    flex: 1 1 0;
    animation: stripe-glow 6s ease-in-out infinite;
}

.site-gem-band__stripe--wine    { background-color: var(--wine);    animation-delay: 0s; }
.site-gem-band__stripe--sienna  { background-color: var(--sienna);  animation-delay: 1s; }
.site-gem-band__stripe--mustard { background-color: var(--mustard); animation-delay: 2s; }
.site-gem-band__stripe--jade    { background-color: var(--jade);    animation-delay: 3s; }
.site-gem-band__stripe--navy    { background-color: var(--navy);    animation-delay: 4s; }
.site-gem-band__stripe--plum    { background-color: var(--plum);    animation-delay: 5s; }


/* ============================================================
   10. SITE HEADER AND NAV
   ============================================================ */

.site-header {
    position: fixed;
    top: var(--gem-band-h);
    left: 0;
    right: 0;
    z-index: 900;
    height: var(--header-height);
    background-color: rgba(15, 10, 12, 0.60);
    border-bottom: 1px solid transparent;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: background-color 0.4s var(--ease), border-color 0.4s var(--ease);
    animation: hue-drift 20s ease-in-out infinite;
}

/* Rainbow sweep line at the bottom of the header */
.site-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(
        90deg,
        var(--wine)    0%,
        var(--sienna)  18%,
        var(--mustard) 36%,
        var(--jade)    54%,
        var(--navy)    72%,
        var(--plum)    90%,
        var(--wine)    100%
    );
    background-size: 200% 100%;
    opacity: 0.35;
    animation: rainbow-sweep 8s linear infinite;
    transition: opacity 0.6s var(--ease-out);
}

/* Nav: 3-column grid so the menu is always centered */
.nav {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    height: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--md);
    gap: var(--md);
}

/* Logo */
.nav__logo-link {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    transition: opacity var(--t);
}
.nav__logo-link:hover { opacity: 0.75; }

.nav__logo-first {
    font-family: var(--font-ui);
    font-size: 0.64rem;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--muted);
}

.nav__logo-last {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--white);
}

/* Nav links */
.nav__menu {
    display: flex;
    align-items: center;
    gap: var(--md);
}

.nav__item { position: relative; }

.nav__link {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-family: var(--font-ui);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--dim);
    padding: 0.3rem 0;
    position: relative;
    transition: color var(--t);
}

/* Animated underline on nav links */
.nav__link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 1.5px;
    background-color: var(--wine);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.28s var(--ease-out);
}

.nav__link:hover,
.nav__link--active { color: var(--white); }

.nav__link:hover::after,
.nav__link--active::after { transform: scaleX(1); }

/* Dropdown caret */
.nav__dropdown-caret {
    font-size: 0.55rem;
    transition: transform 0.22s var(--ease);
}

.nav__item--has-dropdown:hover .nav__dropdown-caret { transform: scaleY(-1); }

/* Dropdown panel */
.nav__dropdown {
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    min-width: 165px;
    background-color: rgba(26, 18, 22, 0.97);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    padding: 0.5rem 0;
    opacity: 0;
    visibility: hidden;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.55);
    transition: opacity 0.22s var(--ease), visibility 0.22s, transform 0.22s var(--ease-out);
}

/* Arrow tip on dropdown */
.nav__dropdown::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 8px;
    height: 8px;
    background-color: rgba(26, 18, 22, 0.97);
    border-top: 1px solid var(--border);
    border-left: 1px solid var(--border);
}

.nav__item--has-dropdown:hover .nav__dropdown,
.nav__item--has-dropdown:focus-within .nav__dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.nav__dropdown-link {
    display: block;
    padding: 0.58rem 1.3rem;
    font-family: var(--font-ui);
    font-size: 0.78rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--dim);
    transition: color var(--t), background-color var(--t);
}

.nav__dropdown-link:hover {
    color: var(--white);
    background-color: rgba(250, 245, 238, 0.05);
}

/* Instagram link (right column) */
.nav__utility { justify-self: end; }

.nav__social-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    color: var(--muted);
    transition: color var(--t);
}

.nav__social-link:hover { color: var(--white); }


/* ============================================================
   11. HERO SECTION
   ============================================================ */

.hero {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100svh;
    padding-top: var(--header-offset);
    overflow: hidden;
}

/* Radial gradient color blobs (static, no animation for performance) */
.hero__bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 65% 60% at 85% 10%,  rgba(138, 44,  59, 0.40) 0%, transparent 70%),
        radial-gradient(ellipse 55% 50% at 10% 85%,  rgba(28,  58, 110, 0.35) 0%, transparent 70%),
        radial-gradient(ellipse 40% 40% at 40% 55%,  rgba(122, 54,  97, 0.18) 0%, transparent 65%),
        radial-gradient(ellipse 30% 30% at 72% 70%,  rgba(201,150,  14, 0.10) 0%, transparent 60%);
    pointer-events: none;
}

/* SVG noise texture */
.hero__noise {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 180px 180px;
    opacity: 0.045;
    pointer-events: none;
}

/* Slow-spinning decorative ring */
.hero__ring {
    position: absolute;
    width: 660px;
    height: 660px;
    border-radius: 50%;
    border: 1px solid rgba(250, 245, 238, 0.05);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: ring-spin 70s linear infinite;
    pointer-events: none;
    will-change: transform;
}

.hero__ring::before {
    content: '';
    position: absolute;
    inset: 60px;
    border-radius: 50%;
    border: 1px solid rgba(250, 245, 238, 0.03);
}

.hero__ring::after {
    content: '';
    position: absolute;
    inset: -80px;
    border-radius: 50%;
    border: 1px solid rgba(138, 44, 59, 0.07);
}

/* Centered text content */
.hero__content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: var(--md);
    max-width: 920px;
}

/*
 * Hero entrance animations — each element writes in left to right.
 * Delays are staggered to create the impression of being typed out.
 */

.hero__eyebrow {
    font-family: var(--font-ui);
    font-size: 0.68rem;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--mustard);
    margin-bottom: 1.6rem;
    clip-path: inset(0 100% 0 0);
    animation: write-in 0.8s var(--ease-out) 0.15s forwards;
}

.hero__title {
    font-family: var(--font-display);
    font-size: clamp(5rem, 13vw, 11rem);
    font-weight: 600;
    line-height: 0.93;
    letter-spacing: -0.025em;
    margin-bottom: var(--sm);
}

.hero__title-name {
    display: block;
    color: var(--white);
    clip-path: inset(0 100% 0 0);
    animation: write-in 1.1s var(--ease-out) 0.55s forwards;
}

.hero__title-initials {
    display: block;
    color: var(--dim);
    clip-path: inset(0 100% 0 0);
    animation: write-in 1.0s var(--ease-out) 1.35s forwards;
}

/* Decorative rule between title and tagline */
.hero__rule {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: var(--md) auto;
    opacity: 0;
    animation: fade-in 0.7s var(--ease-out) 2.3s forwards;
}

.hero__rule-line {
    display: block;
    width: 55px;
    height: 1.5px;
    background: linear-gradient(90deg, transparent, var(--wine), transparent);
    border-radius: 99px;
}

.hero__rule-gem {
    display: block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background-color: var(--wine);
    flex-shrink: 0;
    animation: gem-pulse 3s ease-in-out 2.8s infinite;
}

.hero__tagline {
    font-family: var(--font-body);
    font-size: clamp(1.1rem, 2.2vw, 1.4rem);
    font-weight: 300;
    font-style: italic;
    color: var(--dim);
    line-height: 1.65;
    margin-bottom: var(--md);
    clip-path: inset(0 100% 0 0);
    animation: write-in 1.0s var(--ease-out) 2.7s forwards;
    position: relative;
}

/* Blinking cursor after tagline (fades out after 5 blinks) */
.hero__tagline::after {
    content: '|';
    position: absolute;
    margin-left: 3px;
    color: var(--wine);
    font-style: normal;
    opacity: 0;
    animation:
        cursor-show  0s    3.7s  forwards,
        cursor-blink 0.75s 3.7s  5,
        cursor-hide  0.4s  7.45s forwards;
}

/* CTA buttons */
.hero__cta-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--sm);
    flex-wrap: wrap;
    opacity: 0;
    animation: fade-up 0.8s var(--ease-out) 3.8s forwards;
}

/* Hero "Continue" button appears after the entrance sequence */
.hero__next-btn {
    opacity: 0;
    animation: fade-in 0.8s ease 4.2s forwards;
}


/* ============================================================
   12. WORKS SECTION
   ============================================================
   To adjust spacing: change padding-top / padding-bottom on .section--works.
   To adjust the heading area: change margin-bottom on .section__header.
   To change card colors: edit .works__card-color-bar rules below.
   ============================================================ */

.section--works {
    background-color: var(--bg);
    /* Extra top padding so the subtitle text has breathing room */
    padding-top: calc(var(--header-offset) + var(--md)); 
}

/* Grid: two cards side by side */
.works__grid {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: var(--md);
    width: 100%;
}

/* Individual card */
.works__card {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    min-width: 0;
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    overflow: hidden;
    background-color: var(--surface);
    position: relative;
    transition: border-color 0.28s var(--ease-out);
}

/* Page-corner fold (decorative) */
.works__card::before {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 0 18px 18px;
    border-color: transparent transparent rgba(250, 245, 238, 0.06) transparent;
    transition: border-width 0.28s var(--ease-out), border-color 0.28s var(--ease-out);
    z-index: 2;
}

.works__card:hover { border-color: rgba(250, 245, 238, 0.14); }

.works__card:hover::before {
    border-width: 0 0 28px 28px;
    border-color: transparent transparent rgba(250, 245, 238, 0.1) transparent;
}

/* Thin color bar at top of card */
.works__card-color-bar {
    height: 4px;
    flex-shrink: 0;
    transition: opacity 0.28s var(--ease-out);
}

.works__card--fiction    .works__card-color-bar { background-color: var(--wine); }
.works__card--nonfiction .works__card-color-bar { background-color: var(--navy); }
.works__card:hover       .works__card-color-bar { opacity: 0.75; }

/* Card content area */
.works__card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: var(--md);
}

.works__card-eyebrow {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 0.8rem;
}

.works__card--fiction    .works__card-eyebrow { color: var(--wine); }
.works__card--nonfiction .works__card-eyebrow { color: #3c6db5;     }

.works__card-title {
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 3vw, 2.5rem);
    color: var(--white);
    margin-bottom: var(--sm);
}

.works__card-desc {
    font-family: var(--font-body);
    font-size: 1.08rem;
    color: var(--dim);
    line-height: 1.76;
    margin-bottom: var(--md);
    flex: 1;
}

/* "Read Fiction / Nonfiction" link */
.works__card-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-ui);
    font-size: 0.76rem;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--dim);
    align-self: flex-start;
    padding: 0.5rem 0.9rem;
    border: 1.5px solid var(--border);
    border-radius: var(--r-sm);
    transition: border-color var(--t), color var(--t), background-color var(--t);
}

.works__card-cta:hover {
    border-color: var(--muted);
    color: var(--white);
    background-color: rgba(250, 245, 238, 0.04);
}

.works__card-arrow {
    display: inline-block;
    transition: transform 0.22s var(--ease-out);
}

.works__card-cta:hover .works__card-arrow { transform: translateX(4px); }

/* "View All Works" row */
.works__footer {
    display: flex;
    justify-content: center;
    margin-top: var(--lg);
}


/* ============================================================
   13. ABOUT PREVIEW SECTION
   ============================================================ */

.section--about-preview {
    background-color: var(--surface);
    border-top: 1px solid var(--border);
    background-image: linear-gradient(
        225deg,
        rgba(122, 54,  97, 0.08) 0%,
        transparent               50%,
        rgba(28,  58, 110, 0.06) 100%
    );
}

/* Text column */
.about-preview__text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--sm);
    flex: 1 1 0;
}

.about-preview__body {
    font-family: var(--font-body);
    font-size: 1.12rem;
    color: var(--dim);
    line-height: 1.82;
    max-width: 52ch;
}

/* Portrait column */
.about-preview__portrait-wrap {
    flex: 0 0 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Portrait card */
.portrait-frame {
    position: relative;
    width: 300px;
    border-radius: var(--r-lg);
    overflow: hidden;
    background-color: var(--bg);
    border: 1px solid var(--border);
    box-shadow:
        0 0 0 1px rgba(138, 44, 59, 0.25),
        0 24px 60px rgba(138, 44, 59, 0.30),
        0  8px 24px rgba(122, 54, 97, 0.25);
    transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
    will-change: transform;
}

.portrait-frame:hover {
    transform: scale(1.02) translateY(-3px);
    box-shadow:
        0 0 0 1px rgba(138, 44, 59, 0.35),
        0 32px 72px rgba(138, 44, 59, 0.38),
        0 10px 30px rgba(122, 54, 97, 0.30);
}

/* Three-color accent bar at top of portrait */
.portrait-frame__gem-bar {
    display: flex;
    height: 4px;
    width: 100%;
}

.portrait-frame__gem-stripe        { flex: 1 1 0; }
.portrait-frame__gem-stripe--wine  { background-color: var(--wine); }
.portrait-frame__gem-stripe--plum  { background-color: var(--plum); }
.portrait-frame__gem-stripe--navy  { background-color: var(--navy); }

/* The photo — fades to transparent at the bottom */
.portrait-frame__img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
    -webkit-mask-image: linear-gradient(to bottom, black 55%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 55%, transparent 100%);
}

/* Warm glow beneath the photo */
.portrait-frame__halo {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 60% at 50% 100%, rgba(138,44,59,0.35) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

/* Italic name caption beneath photo */
.portrait-frame__caption {
    font-family: var(--font-display);
    font-size: 0.82rem;
    font-style: italic;
    color: var(--muted);
    text-align: center;
    padding: 0.6rem var(--sm) 0.75rem;
    letter-spacing: 0.04em;
    position: relative;
    z-index: 2;
}


/* ============================================================
   14. CONNECT SECTION
   ============================================================ */

.section--connect {
    background-color: var(--bg);
    border-top: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

/* Background color blobs */
.connect__bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 55% 90% at 20% 50%,  rgba(138, 44,  59, 0.16) 0%, transparent 70%),
        radial-gradient(ellipse 45% 75% at 80% 50%,  rgba(122, 54,  97, 0.13) 0%, transparent 70%),
        radial-gradient(ellipse 35% 50% at 50% 100%, rgba(28,  58, 110, 0.12) 0%, transparent 60%);
    pointer-events: none;
}

/* Content sits above the color blobs */
.section--connect .section__inner {
    position: relative;
    z-index: 1;
    gap: var(--sm);
}

/* Small gradient bar above the "Follow Along" eyebrow */
.section--connect .section__eyebrow::before {
    content: '';
    display: block;
    width: 40px;
    height: 1.5px;
    background: linear-gradient(90deg, transparent, var(--wine), var(--plum), transparent);
    margin: 0 auto var(--sm);
}

/* Suppress the ink-stroke underline here (the bar above replaces it) */
.section--connect .section__eyebrow::after {
    display: none;
}

.connect__body {
    font-family: var(--font-body);
    font-size: 1.12rem;
    /* font-style: italic; */
    color: var(--dim);
    max-width: 44ch;
    text-align: center;
    margin-bottom: var(--md);
}


/* ============================================================
   15. FOOTER
   ============================================================ */

.site-footer {
    background-color: var(--surface);
    border-top: 1px solid var(--border);
}

/* Six-color stripe at top of footer */
.footer__gem-band {
    display: flex;
    height: 2px;
}

.footer__gem-stripe          { flex: 1 1 0; }
.footer__gem-stripe--wine    { background-color: var(--wine);    }
.footer__gem-stripe--sienna  { background-color: var(--sienna);  }
.footer__gem-stripe--mustard { background-color: var(--mustard); }
.footer__gem-stripe--jade    { background-color: var(--jade);    }
.footer__gem-stripe--navy    { background-color: var(--navy);    }
.footer__gem-stripe--plum    { background-color: var(--plum);    }

/* Footer columns */
.footer__inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--md);
    max-width: var(--max-width);
    margin: 0 auto;
    padding: var(--lg) var(--md);
    flex-wrap: wrap;
}

.footer__brand {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.footer__name {
    font-family: var(--font-display);
    font-size: 1.45rem;
    font-weight: 600;
    color: var(--white);
}

.footer__descriptor {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted);
}

.footer__nav-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

/* Color-only hover — no size change, no layout shift */
.footer__nav-link {
    display: inline-block;
    font-family: var(--font-ui);
    font-size: 0.76rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
    transition: color var(--t);
}

.footer__nav-link:hover { color: var(--white); }

/* Instagram handle */
.footer__social-link {
    font-family: var(--font-ui);
    font-size: 0.82rem;
    color: var(--muted);
    letter-spacing: 0.06em;
    position: relative;
    padding-bottom: 2px;
    transition: color var(--t);
}

/* Underline draws in on hover */
.footer__social-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background-color: var(--wine);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.28s var(--ease-out);
}

.footer__social-link:hover            { color: var(--white); }
.footer__social-link:hover::after     { transform: scaleX(1); }

/* Copyright bar */
.footer__bottom {
    border-top: 1px solid var(--border);
    padding: var(--sm) var(--md);
    text-align: center;
}

.footer__copyright {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    color: var(--muted);
}


/* ============================================================
   16. KEYFRAMES
   ============================================================ */

/* Write in: left to right (used on hero and .anim-write elements) */
@keyframes write-in {
    from { clip-path: inset(0 100% 0 0); opacity: 1; }
    to   { clip-path: inset(0 0%   0 0); opacity: 1; }
}

/* Write out / erase: right to left (backspace effect) */
@keyframes write-out {
    from { clip-path: inset(0 0%   0 0); opacity: 1; }
    to   { clip-path: inset(0 100% 0 0); opacity: 0; }
}

@keyframes fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes fade-up {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0);    }
}

/* Hero ring rotation */
@keyframes ring-spin {
    from { transform: translate(-50%, -50%) rotate(0deg);   }
    to   { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Pulsing gem dot in the hero rule */
@keyframes gem-pulse {
    0%, 100% { opacity: 1;   }
    50%       { opacity: 0.4; }
}

/* Cursor blink for hero tagline */
@keyframes cursor-show  { to { opacity: 1; } }
@keyframes cursor-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
@keyframes cursor-hide  { to { opacity: 0; } }

/* Gem band stripe glow */
@keyframes stripe-glow {
    0%, 50%, 100% { opacity: 0.75; }
    25%            { opacity: 1;    }
}

/* Header rainbow line sweep */
@keyframes rainbow-sweep {
    from { background-position: 0%   center; }
    to   { background-position: 200% center; }
}

/* Header subtle background hue drift */
@keyframes hue-drift {
    0%   { background-color: rgba(15, 10, 12, 0.82); }
    25%  { background-color: rgba(18, 10, 13, 0.82); }
    50%  { background-color: rgba(12, 10, 15, 0.82); }
    75%  { background-color: rgba(14, 11, 12, 0.82); }
    100% { background-color: rgba(15, 10, 12, 0.82); }
}

/* Grain texture shifts */
@keyframes grain {
    0%  { background-position:   0px   0px; }
    12% { background-position: -48px -76px; }
    25% { background-position:  38px -28px; }
    37% { background-position: -26px  58px; }
    50% { background-position:  64px  38px; }
    62% { background-position: -54px  18px; }
    75% { background-position:  28px -66px; }
    87% { background-position: -18px  78px; }
}

/* "Continue" button bounce */
@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(5px); }
}


/* ============================================================
   17. SCROLL-DRIVEN HEADER  (Chrome / Edge only, safe fallback)
   ============================================================
   When the user scrolls, the header darkens and the rainbow line
   brightens. Falls back gracefully in Safari / Firefox.
   ============================================================ */

@supports (animation-timeline: scroll()) {

    .site-header {
        animation:
            hue-drift   20s ease-in-out infinite,
            header-fill linear both;
        animation-timeline: auto, scroll(root);
        animation-range:    auto, 0px 140px;
    }

    @keyframes header-fill {
        from { background-color: rgba(15, 10, 12, 0.30); border-bottom-color: transparent; }
        to   { background-color: rgba(15, 10, 12, 0.94); border-bottom-color: var(--border); }
    }

    .site-header::after {
        animation:
            rainbow-sweep   8s linear infinite,
            rainbow-fade    linear both;
        animation-timeline: auto, scroll(root);
        animation-range:    auto, 60px 160px;
    }

    @keyframes rainbow-fade {
        from { opacity: 0.35; }
        to   { opacity: 1;    }
    }
}


/* ============================================================
   18. RESPONSIVE
   ============================================================ */

/* Works cards stack vertically at 740px */
@media (max-width: 740px) {
    .works__grid {
        flex-direction: column;
        align-items: stretch;
    }
    .works__card {
        flex: 0 0 auto;
        width: 100%;
    }
}

/* Tablet layout changes at 900px */
@media (max-width: 900px) {

    .nav__social-label { display: none; }

    /* About Preview: portrait above text */
    .section__inner--split {
        flex-direction: column-reverse;
        gap: var(--md);
    }

    .about-preview__portrait-wrap {
        flex: 0 0 auto;
        width: 100%;
        justify-content: center;
    }

    .portrait-frame { width: min(300px, 80vw); }

    .about-preview__text {
        align-items: center;
        text-align: center;
    }

    .about-preview__body { text-align: center; max-width: 60ch; }

    /* Center the ink stroke on centered title */
    .about-preview__text .section__title::after {
        left: 50%;
        transform: translateX(-50%);
    }

    /* Footer stacks */
    .footer__inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: var(--md);
    }

    .footer__nav-list {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: var(--sm) var(--md);
    }
}

/* Mobile at 600px */
@media (max-width: 600px) {

    :root {
        --xl: 4rem;
        --lg: 2.5rem;
    }

    .section { padding-bottom: 5rem; }

    .nav       { padding: 0 var(--sm); gap: var(--sm); }
    .nav__menu { gap: var(--sm); }

    .section__inner { padding: 0 var(--sm); }

    .hero__cta-group { flex-direction: column; align-items: center; gap: 0.75rem; }

    .hero__cta-group .btn {
        width: 100%;
        justify-content: center;
        max-width: 300px;
    }

    .portrait-frame { width: min(260px, 85vw); }
}