/* ============================================================
   lupine.day -- cinematic dark-academia wolf field-guide
   Palette:
     #0c0a08  Wolf Night       (primary background)
     #1a1612  Den Brown        (secondary surface)
     #c4953a  Amber Eye        (primary accent)
     #d4c8b0  Bone White       (body text)
     #5a4a38  Bark Brown       (borders, subtle)
     #8b2500  Blood Rust       (sparse emphasis)
     #3a3a2a  Forest Floor     (tertiary surface)
   Fonts:
     Cinzel              (Display / Headings)
     EB Garamond         (Body)
     Permanent Marker    (Wilderness accent)
   ============================================================ */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'EB Garamond', Garamond, 'Times New Roman', serif;
    font-size: 1.05rem;
    line-height: 1.8;
    color: #d4c8b0;
    background-color: #0c0a08;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================================
   Decorative claw-mark navigation (top-right)
   ============================================================ */
.claw-nav {
    position: fixed;
    top: 28px;
    right: 32px;
    z-index: 50;
    display: flex;
    flex-direction: column;
    gap: 7px;
    pointer-events: none;
    opacity: 0;
    animation: emerge 3s ease-out 0.6s forwards;
}

.claw-line {
    display: block;
    width: 28px;
    height: 2px;
    background: #5a4a38;
    transform: rotate(15deg);
    transform-origin: right center;
    box-shadow: 0 0 4px rgba(90, 74, 56, 0.4);
}

.claw-line:nth-child(2) {
    width: 22px;
    margin-left: 6px;
}

.claw-line:nth-child(3) {
    width: 26px;
    margin-left: 2px;
}

/* ============================================================
   Atmospheric overlays
   ============================================================ */
.fog-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 5;
    background: radial-gradient(ellipse at 50% 100%, rgba(212, 200, 176, 0.04), transparent 60%);
}

.wolf-eyes {
    position: fixed;
    top: 40vh;
    left: -40px;
    z-index: 6;
    display: flex;
    gap: 12px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 2.4s ease-in-out;
    animation: drift 60s linear infinite;
}

.wolf-eyes.visible {
    opacity: 1;
}

.eye {
    display: block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #c4953a;
    box-shadow:
        0 0 12px rgba(196, 149, 58, 0.6),
        0 0 24px rgba(196, 149, 58, 0.3);
    animation: blink 7s ease-in-out infinite;
}

.eye:nth-child(2) {
    animation-delay: 0.05s;
}

@keyframes drift {
    0%   { left: -40px; }
    100% { left: calc(100vw + 40px); }
}

@keyframes blink {
    0%, 92%, 100% { opacity: 1; }
    94%, 96%      { opacity: 0.15; }
}

/* ============================================================
   Cinematic main container
   ============================================================ */
.cinematic {
    position: relative;
    z-index: 10;
}

/* ============================================================
   Full-bleed atmospheric panels
   ============================================================ */
.panel {
    position: relative;
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(3rem, 8vh, 6rem) 1.5rem;
    overflow: hidden;
}

.panel-content {
    max-width: 760px;
    text-align: center;
    position: relative;
    z-index: 2;
}

.atmosphere {
    background-color: #0c0a08;
}

.atmosphere::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 30% 20%, rgba(196, 149, 58, 0.08), transparent 50%),
        radial-gradient(ellipse at 70% 80%, rgba(58, 58, 42, 0.4), transparent 60%);
    pointer-events: none;
    z-index: 1;
}

.atmosphere.dawn::before {
    background:
        radial-gradient(ellipse at 80% 30%, rgba(196, 149, 58, 0.12), transparent 55%),
        radial-gradient(ellipse at 20% 90%, rgba(26, 22, 18, 0.9), transparent 60%);
}

.atmosphere.tracking::before {
    background:
        radial-gradient(ellipse at 50% 50%, rgba(58, 58, 42, 0.35), transparent 70%),
        linear-gradient(180deg, rgba(26, 22, 18, 0.4) 0%, rgba(12, 10, 8, 0.95) 100%);
}

.atmosphere.chase::before {
    background:
        radial-gradient(ellipse at 50% 60%, rgba(139, 37, 0, 0.18), transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(26, 22, 18, 0.6), transparent 80%);
}

.atmosphere.dusk::before {
    background:
        radial-gradient(ellipse at 90% 40%, rgba(196, 149, 58, 0.15), transparent 50%),
        radial-gradient(ellipse at 10% 80%, rgba(58, 58, 42, 0.5), transparent 60%);
}

.atmosphere.night::before {
    background:
        radial-gradient(ellipse at 50% 30%, rgba(212, 200, 176, 0.04), transparent 55%),
        radial-gradient(ellipse at 50% 100%, rgba(26, 22, 18, 0.95), transparent 70%);
}

/* ============================================================
   Hero section
   ============================================================ */
.hero {
    background: #0c0a08;
    position: relative;
}

.hero-content {
    position: relative;
    z-index: 3;
    text-align: center;
    max-width: 90vw;
}

.moon {
    position: absolute;
    top: 14vh;
    right: 8vw;
    width: 160px;
    height: 160px;
    border-radius: 50%;
    background: radial-gradient(circle, #d4c8b0 0%, #c4953a 40%, transparent 70%);
    opacity: 0;
    animation: moonRise 4s ease-out 0.4s forwards;
    z-index: 1;
    filter: blur(0.5px);
}

.moon::after {
    content: '';
    position: absolute;
    inset: -30px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(196, 149, 58, 0.18) 0%, transparent 70%);
}

.hero-vignette {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at center, transparent 30%, rgba(12, 10, 8, 0.7) 80%),
        linear-gradient(180deg, rgba(12, 10, 8, 0.4) 0%, transparent 30%, transparent 70%, rgba(12, 10, 8, 0.9) 100%);
    pointer-events: none;
    z-index: 2;
}

@keyframes moonRise {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.96);
    }
    to {
        opacity: 0.85;
        transform: translateY(0) scale(1);
    }
}

/* ============================================================
   Typography
   ============================================================ */
.display-title {
    font-family: 'Cinzel', 'Times New Roman', serif;
    font-weight: 700;
    font-size: clamp(2.5rem, 6vw, 5rem);
    color: #d4c8b0;
    letter-spacing: 0.12em;
    line-height: 1.1;
    text-transform: lowercase;
    opacity: 0.1;
    transform: translateY(8px);
    animation: emerge 2s ease-out 0.6s forwards;
    text-shadow:
        0 0 18px rgba(196, 149, 58, 0.18),
        0 0 4px rgba(212, 200, 176, 0.25);
}

.display-heading {
    font-family: 'Cinzel', 'Times New Roman', serif;
    font-weight: 600;
    font-size: clamp(1.8rem, 4vw, 3rem);
    color: #d4c8b0;
    letter-spacing: 0.04em;
    line-height: 1.25;
    margin: 1.2rem 0 1.6rem;
    text-transform: none;
}

.section-heading {
    font-family: 'Cinzel', 'Times New Roman', serif;
    font-weight: 600;
    font-size: clamp(1.4rem, 2.6vw, 1.9rem);
    color: #c4953a;
    letter-spacing: 0.06em;
    margin-bottom: 1.4rem;
    line-height: 1.3;
}

.chapter-label {
    font-family: 'Permanent Marker', 'Cinzel', cursive;
    font-weight: 400;
    font-size: clamp(0.95rem, 1.6vw, 1.2rem);
    color: #c4953a;
    letter-spacing: 0.18em;
    text-transform: lowercase;
    margin-bottom: 1.8rem;
    opacity: 0.85;
}

.marker-accent {
    font-family: 'Permanent Marker', 'Cinzel', cursive;
    font-weight: 400;
    font-size: clamp(1rem, 2vw, 1.5rem);
    letter-spacing: 0.08em;
    color: #c4953a;
    margin-top: 2rem;
    opacity: 0.9;
    text-transform: lowercase;
}

.marker-accent.danger {
    color: #8b2500;
    text-shadow: 0 0 8px rgba(139, 37, 0, 0.4);
}

.hero-tag {
    font-family: 'EB Garamond', serif;
    font-style: italic;
    font-size: clamp(1rem, 1.6vw, 1.25rem);
    color: #c4953a;
    letter-spacing: 0.18em;
    margin-top: 1.4rem;
    opacity: 0;
    animation: emerge 2.4s ease-out 1.6s forwards;
    text-transform: lowercase;
}

.panel-prose {
    font-size: clamp(1rem, 1.4vw, 1.18rem);
    line-height: 1.85;
    color: #d4c8b0;
    max-width: 640px;
    margin: 0 auto;
}

.panel-prose + .panel-prose {
    margin-top: 1.4rem;
}

/* ============================================================
   Narrow text blocks
   ============================================================ */
.text-block {
    max-width: 700px;
    margin: 0 auto;
    padding: clamp(4rem, 10vh, 8rem) 1.5rem;
    position: relative;
}

.text-block p {
    margin-bottom: 1.4rem;
    font-size: 1.08rem;
    line-height: 1.85;
    color: #d4c8b0;
}

.text-block p:last-of-type {
    margin-bottom: 0;
}

.text-block em {
    color: #c4953a;
    font-style: italic;
}

.dropcap::first-letter {
    font-family: 'Cinzel', serif;
    font-weight: 700;
    font-size: 4.4rem;
    float: left;
    line-height: 0.9;
    padding: 0.4rem 0.7rem 0 0;
    color: #c4953a;
    text-shadow: 0 0 12px rgba(196, 149, 58, 0.3);
}

.pull-quote {
    font-family: 'EB Garamond', serif;
    font-style: italic;
    font-size: clamp(1.2rem, 2vw, 1.55rem);
    line-height: 1.5;
    color: #d4c8b0;
    text-align: center;
    margin: 2.5rem 0;
    padding: 2rem 1rem;
    border-top: 1px solid #5a4a38;
    border-bottom: 1px solid #5a4a38;
    position: relative;
}

.quote-mark {
    font-family: 'Cinzel', serif;
    color: #c4953a;
    font-size: 1.4em;
    line-height: 0;
    position: relative;
    top: 0.18em;
    margin: 0 0.15em;
}

.quote-mark.closing {
    margin-left: 0.15em;
}

.signature {
    font-family: 'EB Garamond', serif;
    font-style: italic;
    margin-top: 2.5rem;
    color: #d4c8b0;
    letter-spacing: 0.04em;
    text-align: center;
}

.amber {
    color: #c4953a;
    font-style: normal;
    letter-spacing: 0.06em;
}

.footer-line {
    margin-top: 3rem;
    font-size: 0.92rem;
    color: #5a4a38;
    letter-spacing: 0.18em;
    text-align: center;
    text-transform: lowercase;
    font-style: italic;
}

/* ============================================================
   Claw-mark divider (three diagonal scratches)
   ============================================================ */
.claw-divider {
    position: relative;
    width: 100%;
    height: 60px;
    margin-top: 3rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.claw-divider::before,
.claw-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40px;
    height: 2px;
    background: #5a4a38;
    transform: rotate(15deg);
    box-shadow: 0 0 6px rgba(90, 74, 56, 0.35);
}

.claw-divider::before {
    left: calc(50% - 32px);
}

.claw-divider::after {
    left: calc(50% + 8px);
}

/* third scratch via a span trick using box-shadow */
.claw-divider {
    --scratch: #5a4a38;
}

.claw-divider span,
.claw-divider .scratch {
    display: none;
}

/* fake third line using outline trick on ::before via additional box-shadow line */
.claw-divider::before {
    box-shadow:
        0 0 6px rgba(90, 74, 56, 0.35),
        14px -6px 0 -1px var(--scratch);
}

.claw-divider.final::before,
.claw-divider.final::after {
    background: #c4953a;
    box-shadow:
        0 0 8px rgba(196, 149, 58, 0.5),
        14px -6px 0 -1px #c4953a;
}

/* ============================================================
   Scroll cue at hero
   ============================================================ */
.scroll-cue {
    position: absolute;
    bottom: 5vh;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    z-index: 3;
    opacity: 0;
    animation: emerge 2s ease-out 2.4s forwards;
}

.cue-line {
    display: block;
    width: 1px;
    height: 50px;
    background: linear-gradient(180deg, transparent, #c4953a);
    animation: cueDrop 3s ease-in-out infinite;
}

.cue-text {
    font-family: 'Permanent Marker', cursive;
    font-size: 0.85rem;
    color: #c4953a;
    letter-spacing: 0.3em;
    text-transform: lowercase;
    opacity: 0.7;
}

@keyframes cueDrop {
    0%, 100% { transform: scaleY(0.4); transform-origin: top; opacity: 0.4; }
    50%      { transform: scaleY(1); opacity: 1; }
}

/* ============================================================
   Reveal animation
   ============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 1000ms ease-in-out, transform 1000ms ease-in-out;
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes emerge {
    from {
        opacity: 0.1;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================================
   Colophon emphasis
   ============================================================ */
.colophon {
    border-top: 1px solid #3a3a2a;
    margin-top: 4rem;
    padding-top: clamp(4rem, 10vh, 8rem);
}

/* ============================================================
   Subtle vignette on every panel for cinematic edges
   ============================================================ */
.panel::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
        rgba(12, 10, 8, 0.6) 0%,
        transparent 12%,
        transparent 88%,
        rgba(12, 10, 8, 0.6) 100%);
    pointer-events: none;
    z-index: 2;
}

/* ============================================================
   Responsive tuning
   ============================================================ */
@media (max-width: 720px) {
    .moon {
        width: 110px;
        height: 110px;
        top: 8vh;
        right: 4vw;
    }

    .claw-nav {
        top: 20px;
        right: 22px;
    }

    .text-block {
        padding: clamp(3rem, 8vh, 5rem) 1.4rem;
    }

    .pull-quote {
        font-size: 1.15rem;
        padding: 1.4rem 0.6rem;
    }

    .dropcap::first-letter {
        font-size: 3.4rem;
    }
}

@media (max-width: 460px) {
    .display-title {
        letter-spacing: 0.08em;
    }

    .moon {
        width: 90px;
        height: 90px;
    }
}
