/* =====================================================================
   Panel Gallery — Hermès-style
   Scoped under .pg-* so this file can be pasted into the live
   litfin501c.com index.html without colliding with existing styles.

   Two themes:
     .pg-theme-light  — warm cream background (Crown Room)
     .pg-theme-dark   — deep navy background (Theater)
   ===================================================================== */

:root {
    /* Light theme (Crown Room) */
    --pg-bg: #f8f7f4;
    --pg-bg-alt: #f0efe9;
    --pg-card: #ffffff;
    --pg-text-heading: #1a1a2e;
    --pg-text-body: #2d3748;
    --pg-text-muted: #4a5568;
    --pg-text-faint: #8a92a1;
    --pg-rule: #d5d2c9;
    --pg-shadow: 0 1px 2px rgba(26, 26, 46, 0.04), 0 12px 28px rgba(26, 26, 46, 0.06);

    --pg-gold: #c9a84c;

    --pg-content-max: 1280px;
    --pg-gutter: 60px;
}

/* Dark theme (Theater) */
.pg-theme-dark {
    --pg-bg: #0a1628;
    --pg-bg-alt: #0e1d33;
    --pg-card: #11243d;
    --pg-text-heading: #f5f3ec;
    --pg-text-body: #d4d0c7;
    --pg-text-muted: #a8a59a;
    --pg-text-faint: #6e7585;
    --pg-rule: #1f3556;
    --pg-shadow: 0 1px 2px rgba(0, 0, 0, 0.25), 0 22px 44px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--pg-bg);
    color: var(--pg-text-body);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================ ROOM (themed band) ============================ */
/* Each room is a full-width section that owns its background. The transition
   between rooms is just two adjacent <section>s with different theme classes. */

.pg-room {
    background: var(--pg-bg);
    color: var(--pg-text-body);
    transition: background 0.5s ease;
}

/* ============================ SPLASH ============================ */

.pg-splash {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 480px;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Sponsor slide — fits exactly one viewport, same as the hero splash */
.pg-sponsor-slide {
    width: 100%;
    height: 100vh;
    min-height: 480px;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 5%;
    box-sizing: border-box;
}
.pg-sponsor-slide-img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 24px rgba(26, 26, 46, 0.07));
}

.pg-splash-img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    /* soft shadow so the slide lifts off the white page */
    filter: drop-shadow(0 8px 32px rgba(26, 26, 46, 0.10));
}

/* Jelly wave — same colour as page bg, animates at the bottom border
   of the splash to create an organic, gelatinous boundary. */
.pg-splash::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: -8%;
    width: 116%;
    height: 100px;
    background: #ffffff;
    border-radius: 50% 50% 0 0 / 100% 100% 0 0;
    transform-origin: center bottom;
    animation: pg-jelly-wave 3.4s ease-in-out infinite;
    pointer-events: none;
}

@keyframes pg-jelly-wave {
    0%,  100% { transform: scaleY(1)    scaleX(1);    border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
    35%        { transform: scaleY(1.35) scaleX(1.02); border-radius: 54% 46% 0 0 / 110%  90% 0 0; }
    65%        { transform: scaleY(0.80) scaleX(0.99); border-radius: 46% 54% 0 0 /  85% 115% 0 0; }
}

/* Animated scroll hint */
.pg-splash-scroll {
    position: absolute;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    animation: pg-splash-bob 2.2s ease-in-out infinite;
}

.pg-splash-scroll-label {
    font-family: 'Inter', sans-serif;
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: rgba(201, 168, 76, 0.85);
}

.pg-splash-chevron {
    width: 10px;
    height: 10px;
    border-right: 1.5px solid rgba(201, 168, 76, 0.85);
    border-bottom: 1.5px solid rgba(201, 168, 76, 0.85);
    transform: rotate(45deg);
}

@keyframes pg-splash-bob {
    0%, 100% { transform: translateX(-50%) translateY(0);   opacity: 1; }
    50%       { transform: translateX(-50%) translateY(8px); opacity: 0.55; }
}

/* Scroll-reveal — spring easing gives the jelly/elastic bounce feel
   as each section pops into view. */
.pg-reveal {
    opacity: 0;
    transform: translateY(28px) scale(0.975);
    transition: opacity  0.85s cubic-bezier(0.34, 1.56, 0.64, 1),
                transform 0.85s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.pg-reveal.is-visible {
    opacity: 1;
    transform: none;
}

/* ============================ PAGE HEADER ============================ */

.pg-page-header {
    text-align: center;
    padding: 110px var(--pg-gutter) 60px;
    max-width: 900px;
    margin: 0 auto;
}

.pg-page-header-eyebrow {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--pg-text-faint);
    margin-bottom: 28px;
}

.pg-page-header-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.6rem, 5.5vw, 4rem);
    font-weight: 500;
    color: var(--pg-text-heading);
    margin: 0 0 22px 0;
    line-height: 1.1;
}

.pg-page-header-title em {
    font-style: italic;
    font-weight: 500;
}

.pg-page-header-sub {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    color: var(--pg-text-muted);
    line-height: 1.65;
    max-width: 540px;
    margin: 0 auto 36px;
}

/* Room nav: small jump links between Crown Room and Theater */
.pg-room-nav {
    display: inline-flex;
    align-items: center;
    gap: 28px;
    padding-top: 6px;
}

.pg-room-nav a {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 3.5px;
    text-transform: uppercase;
    color: var(--pg-text-muted);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    padding-bottom: 4px;
    transition: color 0.25s ease, border-color 0.25s ease;
}

.pg-room-nav a:hover,
.pg-room-nav a.is-active {
    color: var(--pg-text-heading);
    border-bottom-color: var(--pg-gold);
}

.pg-room-nav-sep {
    color: var(--pg-text-faint);
    font-size: 0.6rem;
    letter-spacing: 0.2em;
}

/* ============================ ROOM HEADER ============================ */

.pg-room-header {
    text-align: center;
    padding: 80px var(--pg-gutter) 30px;
    max-width: 720px;
    margin: 0 auto;
}

.pg-room-header-eyebrow {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--pg-gold);
    margin-bottom: 18px;
}

.pg-room-header-title {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-weight: 500;
    font-size: clamp(2.2rem, 4.5vw, 3.4rem);
    color: var(--pg-text-heading);
    margin: 0 0 18px 0;
    line-height: 1.1;
}

.pg-room-header-sub {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: var(--pg-text-muted);
    line-height: 1.65;
    max-width: 520px;
    margin: 0 auto;
}

/* ============================ PANEL UNIT ============================ */

.pg-panel {
    padding: 70px var(--pg-gutter) 90px;
    max-width: var(--pg-content-max);
    margin: 0 auto;
}

.pg-panel--upcoming {
    opacity: 0.55;
}

.pg-panel-head {
    text-align: center;
    max-width: 620px;
    margin: 0 auto 56px;
}

.pg-panel-eyebrow {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 3.5px;
    text-transform: uppercase;
    color: var(--pg-text-faint);
    margin-bottom: 22px;
}

.pg-panel-title {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-weight: 500;
    font-size: clamp(2rem, 3.6vw, 2.7rem);
    color: var(--pg-text-heading);
    margin: 0 0 22px 0;
    line-height: 1.18;
    letter-spacing: -0.005em;
}

.pg-panel-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--pg-text-muted);
    line-height: 1.65;
    max-width: 480px;
    margin: 0 auto 32px;
}

/* ============================ DOWNLOAD DROPDOWN ============================ */
/* Replaces the old "Explore the Panel" link. Native <details>/<summary>
   handles open/close — no JS needed for the toggle itself. */

.pg-download {
    display: inline-block;
    text-align: center;
}

.pg-download summary {
    list-style: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 3.5px;
    text-transform: uppercase;
    color: var(--pg-text-heading);
    border-bottom: 1px solid var(--pg-text-heading);
    padding: 0 0 5px 0;
    transition: color 0.25s ease, border-color 0.25s ease;
}
.pg-download summary::-webkit-details-marker { display: none; }

.pg-download summary:hover {
    color: var(--pg-gold);
    border-bottom-color: var(--pg-gold);
}

/* small chevron after the label that rotates when open */
.pg-download-chevron {
    width: 8px;
    height: 8px;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.25s ease;
    margin-bottom: 3px;
}
.pg-download[open] .pg-download-chevron {
    transform: rotate(225deg);
    margin-bottom: 0;
    margin-top: 3px;
}

/* The form body that drops down */
.pg-download-body {
    margin-top: 26px;
    text-align: left;
    max-width: 460px;
    background: var(--pg-card);
    padding: 32px 34px;
    box-shadow: var(--pg-shadow);
    border-radius: 2px;
}

.pg-download-label {
    display: block;
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--pg-text-faint);
    margin: 0 0 10px 0;
}

.pg-download-label + .pg-download-label { margin-top: 22px; }

/* The note + signature inputs render in script — they preview exactly
   how they'll look on the downloaded photo. */
.pg-download-input,
.pg-download-textarea {
    width: 100%;
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--pg-rule);
    padding: 4px 0 10px 0;
    font-family: 'Pinyon Script', 'Playfair Display', serif;
    font-size: 1.6rem;
    line-height: 1.3;
    color: var(--pg-text-heading);
    outline: none;
    resize: none;
    transition: border-color 0.2s ease;
}

.pg-download-input:focus,
.pg-download-textarea:focus {
    border-bottom-color: var(--pg-gold);
}

.pg-download-textarea { min-height: 56px; }

.pg-download-hint {
    font-family: 'Inter', sans-serif;
    font-size: 0.72rem;
    color: var(--pg-text-faint);
    margin: 6px 0 0 0;
    line-height: 1.5;
}

.pg-download-submit {
    margin-top: 26px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    background: var(--pg-text-heading);
    color: var(--pg-bg);
    border: 1px solid var(--pg-text-heading);
    padding: 13px 28px;
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    transition: background 0.2s ease, color 0.2s ease;
}

.pg-download-submit:hover {
    background: var(--pg-gold);
    border-color: var(--pg-gold);
    color: #fff;
}

.pg-download-submit:disabled {
    opacity: 0.5;
    cursor: wait;
}

/* ============================ HERO PHOTO ============================ */

.pg-hero {
    width: 100%;
    background: var(--pg-bg-alt);
    margin: 0;
}

.pg-hero img {
    width: 100%;
    height: auto;
    display: block;
}

.pg-hero--placeholder {
    aspect-ratio: 16 / 6;
    background: linear-gradient(135deg, var(--pg-bg-alt) 0%, var(--pg-rule) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed var(--pg-rule);
}

.pg-hero--placeholder .pg-placeholder-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 3.5px;
    text-transform: uppercase;
    color: var(--pg-text-faint);
}

/* ============================ STAGGER ROW ============================ */
/* Each row holds at most ONE photo plus ONE text card. Photos never sit
   on the same horizontal — each secondary photo gets its own band. The
   class .pg-stagger--reversed flips photo + card so the wall alternates
   left/right as the user scrolls. */

.pg-stagger {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 8px;
    margin-top: 8px;
    align-items: start;
}

.pg-stagger--reversed {
    grid-template-columns: 0.9fr 1.1fr;
}

.pg-stagger-photo {
    width: 100%;
    background: var(--pg-bg-alt);
    margin: 0;
}

.pg-stagger-photo img {
    width: 100%;
    height: auto;
    display: block;
}

/* Standalone card — used when a panel only has a hero photo and the
   roster card needs a row of its own. Center the card narrowly so it
   reads like a Hermès caption block. */
.pg-standalone-card {
    margin: 32px auto 0;
    max-width: 540px;
    display: flex;
    justify-content: center;
}

.pg-standalone-card .pg-card {
    width: 100%;
}

/* Standalone photo — rare; renders a centered band when a row has a
   photo but no card. */
.pg-standalone-photo {
    margin: 8px auto 0;
    max-width: 720px;
    background: var(--pg-bg-alt);
}

/* ============================ TEXT CARD ============================ */

.pg-card {
    background: var(--pg-card);
    color: var(--pg-text-body);
    padding: 36px 38px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    box-shadow: var(--pg-shadow);
}

.pg-card-eyebrow {
    font-family: 'Inter', sans-serif;
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 3.5px;
    text-transform: uppercase;
    color: var(--pg-text-faint);
    margin-bottom: 18px;
}

.pg-card-name {
    font-family: 'Playfair Display', serif;
    font-weight: 500;
    font-size: 1.4rem;
    color: var(--pg-text-heading);
    line-height: 1.25;
    margin: 0 0 6px 0;
}

.pg-card-role {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--pg-text-muted);
    line-height: 1.5;
    margin: 0;
}

.pg-card-rule {
    width: 28px;
    height: 1px;
    background: var(--pg-gold);
    margin: 22px 0 18px;
}

.pg-card-quote {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-weight: 400;
    font-size: 0.98rem;
    color: var(--pg-text-muted);
    line-height: 1.55;
    margin: 0;
}

.pg-card-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.pg-card-list li { margin-bottom: 14px; }
.pg-card-list li:last-child { margin-bottom: 0; }

.pg-card-list-name {
    font-family: 'Playfair Display', serif;
    font-weight: 500;
    font-size: 1.05rem;
    color: var(--pg-text-heading);
    line-height: 1.3;
    display: block;
}

.pg-card-list-role {
    font-family: 'Inter', sans-serif;
    font-size: 0.78rem;
    color: var(--pg-text-muted);
    line-height: 1.45;
    display: block;
}

/* ============================ PAGE FOOTER ============================ */

.pg-page-footer {
    text-align: center;
    padding: 60px var(--pg-gutter) 80px;
    max-width: 900px;
    margin: 0 auto;
}

.pg-page-footer-rule {
    width: 60px;
    height: 1px;
    background: var(--pg-gold);
    margin: 0 auto 28px;
}

.pg-page-footer-closing {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 1.05rem;
    color: var(--pg-text-muted);
    line-height: 1.7;
    margin: 0 0 28px;
}

.pg-page-footer-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.78rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    color: var(--pg-text-faint);
    margin: 0 0 14px;
}

.pg-page-footer-credit {
    font-family: 'Inter', sans-serif;
    font-size: 0.72rem;
    font-weight: 400;
    color: var(--pg-text-faint);
    letter-spacing: 0.3px;
    margin: 0 0 36px;
}

.pg-page-footer-back {
    display: inline-block;
    font-family: 'Inter', sans-serif;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--pg-text-muted);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    padding-bottom: 3px;
    transition: color 0.25s ease, border-color 0.25s ease;
}

.pg-page-footer-back:hover {
    color: var(--pg-gold);
    border-bottom-color: var(--pg-gold);
}

/* Half-width photo modifier — used when a secondary photo should render
   at 50% to avoid overwhelming a small or low-resolution image. */
.pg-stagger-photo--half {
    max-width: 50%;
}

/* ============================ RESPONSIVE ============================ */

@media (max-width: 900px) {
    :root { --pg-gutter: 36px; }

    /* Stagger row collapses: card stacks below photo. */
    .pg-stagger,
    .pg-stagger--reversed {
        grid-template-columns: 1fr;
        grid-auto-rows: auto;
        min-height: 0;
        gap: 0;
    }

    .pg-card { padding: 32px 28px; }
}

@media (max-width: 700px) {
    :root { --pg-gutter: 22px; }

    .pg-page-header { padding-top: 70px; padding-bottom: 40px; }
    .pg-room-header { padding-top: 50px; padding-bottom: 18px; }
    .pg-panel { padding: 50px var(--pg-gutter) 70px; }
    .pg-panel-head { margin-bottom: 36px; }

    .pg-download-input,
    .pg-download-textarea { font-size: 1.4rem; }
}
