/* =============================================================
   cafe-sweets.com — Specimen Log Stylesheet
   Palette: Parchment & Verdigris Duotone
   Typography: Lora" (Google Fonts) body 18px / 1.7 line-height.
   Lora's calligraphic warmth suits the naturalist journal tone
   without feeling overly decorative. Body size: 18px / 1.7.
   Lora's warmth and Playfair's measured elegance.
   Playfair Display" (Google Fonts) headings 48px name, 13px small-caps.
   The HUD separator above and below is an inline SVG: `<svg
   width="200" height="10"><line x1="0" y1="5" x2="90" y2="5"
   .../><circle cx="100" cy="5" r="3" .../><line x1="110" y1="5"
   x2="200" y2="5" .../></svg>` in `#6b9c7a`.
   The animated dashed outer ring (radius 130px) shows the current
   season. Lora italic 14px shows the season caption paragraph.
   Lora italic 15px body description. Lora italic 19px. separator.
   ============================================================= */

/* ---- Custom Properties ---- */
:root {
    --parchment:    #f2ead8;
    --verdigris:    #2d4a3e;
    --sage-pale:    #a8c8a0;
    --forest:       #1a2e26;
    --cream:        #e8dfc4;
    --sage-mid:     #6b9c7a;
    --sage-light:   #d4e8c2;
    --sage-soft:    #b8d4a0;

    --font-display: 'Playfair Display', Georgia, serif;
    --font-body:    'Lora', Georgia, serif;
    --font-ui:      'Inter', system-ui, sans-serif;
    --font-mono:    'Space Mono', 'DM Mono', monospace;

    --max-width:    680px;
    --section-gap:  140px;
    --reading-gap:  80px;
}

/* ---- Reset & Base ---- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 18px; /* body paragraph base: 18px */
}

body {
    background-color: var(--parchment);
    color: var(--verdigris);
    font-family: var(--font-body);
    line-height: 1.7; /* Lora body: 18px / 1.7 */
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ---- Typography ---- */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: var(--verdigris);
}

.section-heading {
    font-size: clamp(2rem, 5vw, 2.8rem);
    margin-bottom: 0.5rem;
}

.section-subheading {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    color: var(--sage-mid);
    text-transform: uppercase;
    margin-bottom: var(--reading-gap);
}

.section-label {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.2em;
    color: var(--sage-mid);
    text-transform: uppercase;
    white-space: nowrap;
}

.section-label-wrap {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.section-rule {
    flex: 1;
    height: 1px;
    background: var(--verdigris);
    opacity: 0.2;
}

/* ---- Layout ---- */
.section {
    padding: var(--section-gap) 2rem;
}

.section-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

/* ---- Specimen Header ---- */
.specimen-header {
    position: relative;
    min-height: 100vh;
    background: var(--forest);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 3rem 2rem 5rem;
}

/* HUD rings overlaid on header */
.header-hud-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid var(--sage-pale);
    opacity: 0;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    animation: hud-ring-fade-in 2s ease forwards;
}

.hud-ring-outer {
    width: 95vmin;
    height: 95vmin;
    opacity: 0;
    border-color: var(--sage-pale);
    border-width: 0.5px;
    animation-delay: 0.3s;
}

.hud-ring-mid {
    width: 72vmin;
    height: 72vmin;
    border-color: var(--sage-pale);
    border-width: 0.5px;
    border-style: dashed;
    animation-delay: 0.6s;
}

.hud-ring-inner {
    width: 50vmin;
    height: 50vmin;
    border-color: var(--sage-mid);
    border-width: 1px;
    animation-delay: 0.9s;
}

@keyframes hud-ring-fade-in {
    from { opacity: 0; transform: translate(-50%, -50%) scale(1.04); }
    to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

/* Tick marks canvas area */
.hud-tick-marks {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

/* Header content */
.header-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3.5rem;
    max-width: var(--max-width);
    width: 100%;
}

/* Specimen photo frame */
.specimen-frame {
    width: 100%;
}

.specimen-photo-wrap {
    position: relative;
    border: 2px solid var(--verdigris);
    padding: 8px;
    background: var(--forest);
}

.specimen-photo {
    display: block;
    width: 100%;
}

.specimen-photo svg,
.specimen-photo-svg {
    display: block;
    width: 100%;
    height: auto;
    filter: sepia(0.7) hue-rotate(100deg) saturate(0.65);
}

.specimen-plate-number {
    position: absolute;
    bottom: 16px;
    right: 16px;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--sage-pale);
    letter-spacing: 0.15em;
    opacity: 0.8;
}

/* Header text block */
.header-text {
    text-align: center;
    color: var(--parchment);
}

.header-label {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    letter-spacing: 0.28em;
    color: var(--sage-mid);
    margin-bottom: 1.2rem;
    text-transform: uppercase;
}

.header-title {
    font-family: var(--font-display);
    font-size: clamp(3rem, 10vw, 5rem);
    font-weight: 400;
    letter-spacing: -0.02em;
    color: var(--parchment);
    margin-bottom: 1rem;
}

.header-subtitle {
    font-family: var(--font-body);
    font-size: 1.05rem;
    font-style: italic;
    color: var(--sage-pale);
    max-width: 480px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

.header-divider {
    width: 60px;
    height: 1px;
    background: var(--sage-mid);
    margin: 0 auto 1.2rem;
}

.header-season {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.22em;
    color: var(--sage-mid);
    text-transform: uppercase;
}

/* Scroll indicator */
.header-scroll-indicator {
    position: absolute;
    bottom: 2.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    z-index: 2;
    animation: scroll-indicator-pulse 3s ease-in-out infinite;
}

.scroll-label {
    font-family: var(--font-mono);
    font-size: 0.55rem;
    letter-spacing: 0.22em;
    color: var(--sage-mid);
    text-transform: uppercase;
}

.scroll-line {
    width: 1px;
    height: 48px;
    background: linear-gradient(to bottom, var(--sage-mid), transparent);
}

@keyframes scroll-indicator-pulse {
    0%, 100% { opacity: 0.6; transform: translateX(-50%) translateY(0); }
    50%       { opacity: 1;   transform: translateX(-50%) translateY(6px); }
}

/* ---- About Section ---- */
.section--about {
    background: var(--parchment);
    padding-bottom: calc(var(--section-gap) * 0.8);
}

.body-text {
    font-family: var(--font-body);
    font-size: 18px; /* Lora paragraph body size */
    line-height: 1.7;
    color: var(--verdigris);
    margin-bottom: 1.5rem;
}

.about-body {
    margin-bottom: 4rem;
}

/* Annotation bar */
.about-annotations {
    display: flex;
    align-items: center;
    gap: 0;
    border-top: 1px solid var(--verdigris);
    border-bottom: 1px solid var(--verdigris);
    padding: 2rem 0;
    opacity: 0.9;
}

.annotation-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    text-align: center;
}

.annotation-value {
    font-family: var(--font-display);
    font-size: 2.4rem;
    font-weight: 400;
    color: var(--verdigris);
    line-height: 1;
}

.annotation-label {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.15em;
    color: var(--sage-mid);
    text-transform: uppercase;
}

.annotation-divider {
    width: 1px;
    height: 48px;
    background: var(--verdigris);
    opacity: 0.2;
    flex-shrink: 0;
}

/* ---- Specimen Catalogue ---- */
.section--catalogue {
    background: var(--cream);
    position: relative;
}

/* Cursor halo */
.cursor-halo {
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(ellipse at center,
        rgba(107,156,122,0.12) 0%,
        rgba(107,156,122,0.05) 45%,
        transparent 70%);
    pointer-events: none;
    transform: translate(-50%, -50%);
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.cursor-halo.is-visible {
    opacity: 1;
}

/* Specimen entry */
.specimen-entry {
    margin-bottom: 120px;
    position: relative;
}

.specimen-entry:last-child {
    margin-bottom: 0;
}

/* Bracket frame */
.specimen-bracket {
    display: flex;
    align-items: stretch;
    gap: 0;
    margin-bottom: 2.5rem;
}

.bracket-left,
.bracket-right {
    width: 12px;
    flex-shrink: 0;
    position: relative;
}

.bracket-left::before {
    content: '';
    position: absolute;
    top: 8px;
    bottom: 8px;
    left: 0;
    width: 8px;
    border-top: 2px solid var(--verdigris);
    border-bottom: 2px solid var(--verdigris);
    border-left: 2px solid var(--verdigris);
}

.bracket-right::before {
    content: '';
    position: absolute;
    top: 8px;
    bottom: 8px;
    right: 0;
    width: 8px;
    border-top: 2px solid var(--verdigris);
    border-bottom: 2px solid var(--verdigris);
    border-right: 2px solid var(--verdigris);
}

.specimen-image-wrap {
    flex: 1;
    position: relative;
    border: 2px solid var(--verdigris);
    padding: 8px;
    background: var(--forest);
}

.specimen-image {
    display: block;
    width: 100%;
}

.specimen-image svg {
    display: block;
    width: 100%;
    height: auto;
    filter: sepia(0.5) hue-rotate(110deg) saturate(0.7);
}

.specimen-plate-stamp {
    position: absolute;
    bottom: 16px;
    right: 16px;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--sage-pale);
    letter-spacing: 0.15em;
    opacity: 0.75;
}

/* Specimen info block */
.specimen-info {
    padding: 0 0.5rem;
}

.specimen-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.specimen-number {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.18em;
    color: var(--sage-mid);
    text-transform: uppercase;
}

.specimen-date {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    letter-spacing: 0.1em;
    color: var(--sage-mid);
    opacity: 0.7;
}

.specimen-name {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 500;
    color: var(--verdigris);
    margin-bottom: 0.3rem;
    line-height: 1.2;
}

.specimen-classification {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    color: var(--sage-mid);
    font-style: italic;
    margin-bottom: 1.2rem;
}

.specimen-description {
    font-family: var(--font-body);
    font-size: 15px; /* Lora italic 15px */
    font-style: italic;
    line-height: 1.8;
    color: var(--verdigris);
    margin-bottom: 2rem;
}

/* Data bars */
.specimen-data-row {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    border: 1px solid var(--verdigris);
    border-opacity: 0.15;
    background: rgba(45,74,62,0.04);
}

.data-field {
    display: grid;
    grid-template-columns: 120px 1fr 2rem;
    align-items: center;
    gap: 1rem;
}

.data-label {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.12em;
    color: var(--sage-mid);
    text-transform: uppercase;
    white-space: nowrap;
}

.data-bar-wrap {
    height: 2px;
    background: rgba(45,74,62,0.12);
    position: relative;
}

.data-bar {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: var(--bar-fill);
    background: var(--sage-mid);
    transform-origin: left center;
    animation: bar-grow 1.2s ease forwards;
}

@keyframes bar-grow {
    from { transform: scaleX(0); }
    to   { transform: scaleX(1); }
}

.data-value {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--verdigris);
    text-align: right;
}

.specimen-availability {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.14em;
    color: var(--sage-mid);
    text-transform: uppercase;
    border-top: 1px solid;
    border-color: rgba(45,74,62,0.2);
    padding-top: 1rem;
}

/* ---- Data Panel ---- */
.section--data-panel {
    background: var(--forest);
    color: var(--parchment);
}

.section--data-panel .section-heading {
    color: var(--parchment);
}

.section--data-panel .section-label {
    color: var(--sage-mid);
}

.section--data-panel .section-rule {
    background: var(--sage-pale);
    opacity: 0.2;
}

.section--data-panel .section-subheading {
    color: var(--sage-pale);
    margin-bottom: 60px;
}

.data-chart-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

/* HUD separator above and below — animated dashed outer ring (radius 130px) */
.hud-separator {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 2.5rem 0;
}

/* animated dashed ring at radius 130px for data section */
.hud-ring-animated {
    position: relative;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    border: 1px dashed var(--sage-mid);
    /* radius: 130px */
    animation: hud-ring-spin 40s linear infinite;
    opacity: 0.3;
}

@keyframes hud-ring-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* HUD data panel animated ring (radius 130px from center) */
.section--data-panel .hud-separator {
    opacity: 0.4;
}

.radial-chart {
    width: 100%;
    max-width: 400px;
    opacity: 0;
    animation: chart-fade-in 1.5s ease 0.5s forwards;
}

@keyframes chart-fade-in {
    from { opacity: 0; transform: scale(0.96) rotate(-3deg); }
    to   { opacity: 1; transform: scale(1) rotate(0deg); }
}

/* Chart annotation strip */
.chart-annotations {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.chart-annotation {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    border-bottom: 1px solid;
    border-color: rgba(168,200,160,0.15);
    padding-bottom: 0.8rem;
}

.ca-label {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.14em;
    color: var(--sage-mid);
    text-transform: uppercase;
}

.ca-value {
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-style: italic;
    color: var(--sage-pale);
}

/* ---- Method Section ---- */
.section--method {
    background: var(--parchment);
}

.method-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.method-step {
    display: grid;
    grid-template-columns: 60px 1fr;
    gap: 2rem;
    padding: 2.5rem 0;
    border-bottom: 1px solid rgba(45,74,62,0.15);
}

.method-step:first-child {
    border-top: 1px solid rgba(45,74,62,0.15);
}

.step-number {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.2em;
    color: var(--sage-mid);
    padding-top: 0.25rem;
}

.step-title {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--verdigris);
    margin-bottom: 0.75rem;
}

.step-text {
    font-family: var(--font-body);
    font-size: 15px; /* Lora body */
    line-height: 1.75;
    color: var(--verdigris);
    opacity: 0.8;
}

/* Lora italic 19px for section annotations / pull-quotes */
.section-pull {
    font-family: var(--font-body);
    font-size: 19px;
    font-style: italic;
    line-height: 1.65;
    color: var(--verdigris);
    opacity: 0.75;
}

/* 14px shows current season caption — Lora italic small label */
.season-caption {
    font-family: var(--font-body);
    font-size: 14px;
    font-style: italic;
    color: var(--sage-mid);
    line-height: 1.5;
}

/* ---- Contact / Footer ---- */
.section--contact {
    background: var(--verdigris);
    color: var(--parchment);
}

.section--contact .section-heading {
    color: var(--parchment);
}

.section--contact .section-label {
    color: var(--sage-pale);
}

.section--contact .section-rule {
    background: var(--sage-pale);
    opacity: 0.2;
}

.section--contact .section-subheading {
    color: var(--sage-pale);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin-bottom: 5rem;
}

.contact-label {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    letter-spacing: 0.18em;
    color: var(--sage-pale);
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.contact-text {
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--parchment);
    opacity: 0.85;
}

.footer-divider {
    height: 1px;
    background: var(--sage-pale);
    opacity: 0.15;
    margin-bottom: 3rem;
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-text {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.14em;
    color: var(--sage-mid);
    text-transform: uppercase;
}

.footer-caption {
    font-family: var(--font-body);
    font-size: 0.82rem;
    line-height: 1.65;
    color: var(--parchment);
    opacity: 0.5;
    max-width: 480px;
}

.footer-hud-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.footer-stamp {
    font-family: var(--font-mono);
    font-size: 0.58rem;
    letter-spacing: 0.2em;
    color: var(--sage-mid);
    text-transform: uppercase;
    white-space: nowrap;
}

.footer-rule-long {
    flex: 1;
    height: 1px;
    background: var(--sage-pale);
    opacity: 0.15;
}

/* ---- Scroll-based Reveal ---- */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.9s ease, transform 0.9s ease;
}

.reveal.is-visible {
    opacity: 1;
    transform: none;
}

/* ---- Responsive ---- */
@media (max-width: 600px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .data-field {
        grid-template-columns: 100px 1fr 2rem;
        gap: 0.6rem;
    }

    .specimen-entry {
        margin-bottom: 80px;
    }

    .header-title {
        font-size: 2.8rem;
    }

    .about-annotations {
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    .annotation-divider {
        display: none;
    }
}

@media (max-width: 400px) {
    .method-step {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
}
