/* ==========================================================================
   JOBITRA TEMPLATE #6: THE BIRTHDAY EXHIBITION
   Style Sheet - Light Contemporary Art Gallery Experience
   ========================================================================== */

/* 1. COLOR VARIABLES & THEME PRESETS */
:root {
    --bg-gallery: #FFFDF8;
    --bg-card: #FFF4E6;
    --soft-peach: #F6D7C9;
    --terracotta-light: #E6B7A5;
    --terracotta: #D98972;
    --warm-yellow: #E7B95A;
    --sage: #A8B99A;
    --sky-blue: #A9C8D8;
    --lavender: #D8C5DC;
    
    --text-primary: #403934;
    --text-secondary: #6B6058;
    --text-muted: #9E938B;
    
    --border-gallery: #EADECB;
    --border-gold: #E7B95A;
    
    --accent: var(--terracotta);
    
    --font-heading: 'Cinzel', 'Playfair Display', Georgia, serif;
    --font-body: 'Plus Jakarta Sans', -apple-system, sans-serif;
    --font-handwriting: 'Caveat', cursive;
    
    --shadow-gallery: 0 16px 45px rgba(64, 57, 52, 0.08);
    --shadow-frame: 0 10px 30px rgba(64, 57, 52, 0.12);
    
    --radius-sm: 6px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-door: 0.8s cubic-bezier(0.77, 0, 0.175, 1);
}

/* AGE THEME ACCENT PRESETS */
.theme-contemporary-star { --accent: var(--terracotta); --bg-card: #FFF4E6; }
.theme-baby-exhibition { --accent: var(--soft-peach); --bg-card: #FFF9F2; }
.theme-kids-fun { --accent: var(--warm-yellow); --bg-card: #FFF6E0; }
.theme-teen-youth { --accent: var(--sky-blue); --bg-card: #F2FAFD; }
.theme-milestone-jubilee { --accent: var(--sage); --bg-card: #F5F9F3; }

/* 2. BASE RESET & BODY */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-gallery);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

img { max-width: 100%; height: auto; display: block; }
button, input, textarea { font-family: inherit; font-size: inherit; }

/* 3. ENTRANCE CORRIDOR (DOOR OPENING SCREEN) */
.entrance-corridor {
    position: fixed;
    inset: 0;
    background-color: var(--bg-gallery);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.entrance-door-left,
.entrance-door-right {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 50%;
    background-color: var(--bg-card);
    border-right: 1px solid var(--border-gallery);
    transition: transform var(--transition-door);
    z-index: 1;
}

.entrance-door-left { left: 0; }
.entrance-door-right { right: 0; border-right: none; border-left: 1px solid var(--border-gallery); }

.entrance-corridor.opened .entrance-door-left { transform: translateX(-100%); }
.entrance-corridor.opened .entrance-door-right { transform: translateX(100%); }
.entrance-corridor.opened .entrance-content { opacity: 0; pointer-events: none; transition: opacity 0.4s ease; }

.entrance-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 30px 20px;
    max-width: 440px;
}

.entrance-kicker {
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.3em;
    color: var(--terracotta);
    display: block;
    margin-bottom: 8px;
}

.entrance-title {
    font-family: var(--font-heading);
    font-size: 3.2rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
    letter-spacing: 0.05em;
}

.entrance-subtitle {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    color: var(--text-secondary);
    margin-top: 6px;
}

.entrance-date-pill {
    display: inline-block;
    background-color: var(--bg-gallery);
    border: 1px solid var(--border-gold);
    border-radius: var(--radius-full);
    padding: 8px 22px;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 20px 0 28px 0;
}

.btn-enter-exhibition {
    background-color: var(--terracotta);
    color: #FFFFFF;
    border: none;
    border-radius: var(--radius-full);
    padding: 16px 36px;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(217, 137, 114, 0.35);
    transition: transform var(--transition-fast);
}

.btn-enter-exhibition:hover { transform: scale(1.05); }

/* 4. MAIN EXHIBITION STAGE & GALLERY FLOOR */
.exhibition-stage {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    padding: 20px 16px 90px 16px;
    position: relative;
}

@media (min-width: 960px) {
    .exhibition-stage {
        max-width: 900px;
    }
}

.gallery-spotlight-overlay {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at 50% 30%, rgba(255, 244, 230, 0.8) 0%, rgba(255, 253, 248, 0.95) 70%);
    pointer-events: none;
    z-index: -1;
}

.gallery-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-gallery);
    margin-bottom: 24px;
}

.logo-kicker { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.2em; color: var(--terracotta); display: block; }
.logo-name { font-family: var(--font-heading); font-size: 1.15rem; font-weight: 700; color: var(--text-primary); }

.gallery-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background-color: var(--bg-card);
    border: 1px solid var(--border-gold);
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.68rem;
    font-weight: 700;
}

.status-dot { width: 8px; height: 8px; border-radius: 50%; background-color: #5F9EA5; animation: pulse 1.5s infinite; }
@keyframes pulse { 0% { opacity: 0.4; } 50% { opacity: 1; } 100% { opacity: 0.4; } }

/* 5. CENTRAL INSTALLATION: THE STAR */
.central-star-installation {
    position: relative;
    text-align: center;
    background-color: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 2px solid var(--border-gold);
    padding: 36px 20px;
    margin-bottom: 28px;
    box-shadow: var(--shadow-gallery);
    overflow: hidden;
}

.spotlight-circle {
    position: absolute;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(231, 185, 90, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.star-artwork-frame {
    position: relative;
    width: 170px;
    height: 170px;
    margin: 0 auto 20px auto;
    border-radius: 50%;
    border: 3px solid var(--border-gold);
    padding: 6px;
    background-color: var(--bg-gallery);
    box-shadow: var(--shadow-frame);
}

.star-artwork-frame img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.secret-star-trigger {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--terracotta);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.star-person-name {
    font-family: var(--font-heading);
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
}

.star-age-giant {
    font-family: var(--font-heading);
    font-size: 4.5rem;
    font-weight: 800;
    color: var(--terracotta);
    line-height: 0.95;
    margin: 6px 0;
}

.star-subtitle-tag {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    color: var(--text-secondary);
}

/* 6. ROOM CARDS & ASYMMETRIC GALLERY WALL */
.exhibition-room-card {
    background-color: var(--bg-gallery);
    border: 1px solid var(--border-gallery);
    border-radius: var(--radius-md);
    padding: 24px 20px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-gallery);
}

.exhibit-num-badge {
    font-family: var(--font-heading);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.25em;
    color: var(--terracotta);
    display: block;
    margin-bottom: 4px;
}

.room-title {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 14px;
}

/* BEGINNING ROOM */
.beginning-room-layout {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
}

.gallery-frame {
    background-color: #FFFFFF;
    padding: 10px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-frame);
}

.frame-wooden { border: 6px solid #C9A44C; }
.frame-cream { border: 6px solid #FFF8ED; }
.frame-colored { border: 6px solid var(--terracotta); }

.beginning-room-layout .gallery-frame { width: 180px; aspect-ratio: 1; }
.beginning-room-layout .gallery-frame img { width: 100%; height: 100%; object-fit: cover; }

.curator-note-plaque {
    background-color: var(--bg-card);
    border-left: 3px solid var(--border-gold);
    padding: 14px;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    text-align: left;
    width: 100%;
}

/* ASYMMETRIC GALLERY WALL */
.asymmetric-gallery-wall {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.wall-artwork-item {
    background-color: #FFFFFF;
    padding: 8px 8px 18px 8px;
    border-radius: 4px;
    box-shadow: var(--shadow-frame);
    cursor: pointer;
    transition: transform var(--transition-fast);
}

.wall-artwork-item:hover { transform: scale(1.03); }
.wall-artwork-item:nth-child(1) { transform: rotate(-2deg); }
.wall-artwork-item:nth-child(2) { transform: rotate(1.5deg); grid-row: span 2; }
.wall-artwork-item:nth-child(3) { transform: rotate(-1deg); }

.artwork-img-box { width: 100%; aspect-ratio: 1; overflow: hidden; }
.artwork-img-box img { width: 100%; height: 100%; object-fit: cover; }

.artwork-plaque-tag {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--terracotta);
    text-align: center;
    margin-top: 6px;
    display: block;
}

/* ROOM 03: PEOPLE PORTRAIT WALL */
.people-portrait-wall {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.people-portrait-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background-color: var(--bg-card);
    border: 1px solid var(--border-gallery);
    padding: 12px;
    border-radius: var(--radius-md);
}

.people-avatar-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--bg-gallery);
    border: 2px solid var(--border-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--terracotta);
}

.people-info-block { flex: 1; }
.people-rel-tag { font-size: 0.65rem; font-weight: 700; color: var(--terracotta); letter-spacing: 0.15em; }
.people-name { font-family: var(--font-heading); font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.people-curator-note { font-style: italic; font-size: 0.8rem; color: var(--text-secondary); }

/* ROOM 04: FAVORITES INSTALLATION */
.favorites-installation-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.fav-object-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-gallery);
    border-radius: var(--radius-md);
    padding: 16px 12px;
    text-align: center;
}

.fav-icon-emoji { font-size: 2rem; margin-bottom: 4px; }
.fav-object-lbl { font-size: 0.68rem; font-weight: 700; color: var(--text-muted); letter-spacing: 0.12em; }
.fav-object-val { font-family: var(--font-heading); font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.fav-stars { color: var(--warm-yellow); font-size: 0.8rem; margin-top: 4px; }

/* ROOM 05: CURVED JOURNEY */
.curved-journey-path {
    display: flex;
    flex-direction: column;
    gap: 14px;
    position: relative;
    padding-left: 20px;
    border-left: 2px dashed var(--border-gold);
}

.journey-node-card {
    position: relative;
    background-color: var(--bg-card);
    padding: 12px 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-gallery);
}

.journey-node-card::before {
    content: '';
    position: absolute;
    top: 16px;
    left: -27px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--terracotta);
    border: 2px solid #FFFFFF;
}

.journey-year-tag { font-family: var(--font-heading); font-size: 0.75rem; font-weight: 700; color: var(--terracotta); }
.journey-node-title { font-family: var(--font-heading); font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.journey-node-desc { font-size: 0.8rem; color: var(--text-secondary); }

/* ROOM 06: COLLECTIBLE EVENT POSTER */
.collectible-event-poster {
    background-color: var(--bg-card);
    border: 2px dashed var(--border-gold);
    border-radius: var(--radius-md);
    padding: 24px 16px;
    text-align: center;
    box-shadow: var(--shadow-gallery);
}

.poster-kicker { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.25em; color: var(--terracotta); }
.poster-headline { font-family: var(--font-heading); font-size: 1.5rem; font-weight: 700; color: var(--text-primary); margin: 6px 0; }
.poster-name { font-family: var(--font-heading); font-size: 2.5rem; font-weight: 800; color: var(--terracotta); line-height: 1; }
.poster-turning { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.15em; color: var(--text-secondary); margin-bottom: 20px; }

.poster-details-box { display: flex; flex-direction: column; gap: 10px; background-color: var(--bg-gallery); padding: 16px; border-radius: var(--radius-sm); margin-bottom: 20px; }
.p-lbl { font-size: 0.65rem; font-weight: 700; color: var(--text-muted); display: block; }
.p-val { font-family: var(--font-heading); font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.p-sub { font-size: 0.8rem; color: var(--text-secondary); display: block; }

.poster-actions-row { display: flex; flex-direction: column; gap: 10px; }

/* COUNTDOWN INSTALLATION */
.giant-countdown-wall {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    text-align: center;
    margin-top: 14px;
}

.cd-unit { background-color: var(--bg-card); padding: 16px 4px; border-radius: var(--radius-md); border: 1px solid var(--border-gallery); }
.cd-number { font-family: var(--font-heading); font-size: 2.2rem; font-weight: 800; color: var(--terracotta); display: block; line-height: 1; }
.cd-label { font-size: 0.62rem; font-weight: 700; letter-spacing: 0.15em; color: var(--text-secondary); }

/* BUTTONS */
.btn-exhibition {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 24px;
    border-radius: var(--radius-full);
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all var(--transition-fast);
    width: 100%;
}

.btn-primary { background-color: var(--terracotta); color: #FFFFFF; }
.btn-secondary { background-color: var(--bg-card); border: 1px solid var(--border-gold); color: var(--text-primary); }

/* ROOM 08: RSVP & GUEST STAMP */
.exhibition-form { display: flex; flex-direction: column; gap: 12px; }
.exhibition-input { width: 100%; padding: 12px 14px; border-radius: var(--radius-md); border: 1px solid var(--border-gallery); background-color: var(--bg-gallery); color: var(--text-primary); outline: none; }
.exhibition-input:focus { border-color: var(--terracotta); background-color: #FFFFFF; }

.rsvp-options-grid { display: flex; gap: 8px; }
.rsvp-opt-btn { flex: 1; padding: 12px 6px; border-radius: var(--radius-md); border: 1px solid var(--border-gallery); background-color: var(--bg-card); font-size: 0.72rem; font-weight: 700; cursor: pointer; }
.rsvp-opt-btn.active { background-color: var(--terracotta); color: #FFFFFF; border-color: var(--terracotta); }

.rsvp-confirmed-stamp { text-align: center; padding: 20px; }
.stamp-circle { display: inline-block; padding: 8px 18px; border: 2px solid #D98972; color: #D98972; font-family: var(--font-heading); font-size: 1rem; font-weight: 800; border-radius: 4px; transform: rotate(-4deg); margin-bottom: 12px; }

.digital-guest-wall { margin-top: 20px; padding-top: 14px; border-top: 1px dashed var(--border-gallery); }
.guest-plaques-container { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.guest-plaque { background-color: var(--bg-card); border: 1px solid var(--border-gold); padding: 4px 10px; border-radius: var(--radius-full); font-size: 0.75rem; font-weight: 700; color: var(--terracotta); }

/* ROOM 09: WISHES LABELS */
.wishes-labels-grid { display: flex; flex-direction: column; gap: 8px; max-height: 200px; overflow-y: auto; }
.wish-label-card { background-color: var(--bg-card); border-left: 3px solid var(--terracotta); padding: 10px 14px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }

/* MODALS & FLOATING CONTROLS */
.modal-backdrop { display: none; position: fixed; inset: 0; background-color: rgba(64, 57, 52, 0.65); backdrop-filter: blur(6px); z-index: 10000; align-items: center; justify-content: center; padding: 20px; }
.modal-backdrop.active { display: flex; }

.modal-paper-card { width: 100%; max-width: 400px; background-color: var(--bg-gallery); border-radius: var(--radius-lg); border: 2px solid var(--border-gold); padding: 28px 20px; box-shadow: 0 20px 50px rgba(0,0,0,0.2); }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.btn-close-modal { background: none; border: none; font-size: 1.5rem; cursor: pointer; }

/* EXHIBIT LIGHTBOX */
.exhibit-label-card { width: 100%; max-width: 420px; background-color: var(--bg-gallery); border-radius: var(--radius-md); border: 2px solid var(--border-gold); padding: 16px; box-shadow: 0 20px 50px rgba(0,0,0,0.25); position: relative; }
.exhibit-img-frame { width: 100%; aspect-ratio: 4/3; border-radius: var(--radius-sm); overflow: hidden; margin-bottom: 14px; }
.exhibit-img-frame img { width: 100%; height: 100%; object-fit: cover; }
.exhibit-label-plaque { background-color: var(--bg-card); padding: 14px; border-radius: var(--radius-sm); border-left: 3px solid var(--terracotta); }

/* MAP BOTTOM SHEET */
.map-sheet-content { width: 100%; max-width: 460px; background-color: var(--bg-gallery); border-radius: var(--radius-lg) var(--radius-lg) 0 0; padding: 24px 20px; position: absolute; bottom: 0; max-height: 80vh; overflow-y: auto; }
.map-rooms-grid { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.map-room-btn { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; background-color: var(--bg-card); border: 1px solid var(--border-gallery); border-radius: var(--radius-md); font-family: var(--font-heading); font-size: 1.05rem; font-weight: 700; color: var(--text-primary); cursor: pointer; }

/* FLOATING BUTTONS */
.listening-room-fab, .map-fab, .share-fab {
    position: fixed;
    border-radius: var(--radius-full);
    background-color: var(--bg-card);
    border: 1.5px solid var(--border-gold);
    color: var(--terracotta);
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
}

.listening-room-fab { bottom: 20px; left: 16px; padding: 8px 16px; font-size: 0.72rem; font-weight: 700; gap: 6px; }
.map-fab { bottom: 20px; right: 16px; padding: 8px 16px; font-size: 0.72rem; font-weight: 700; }
.share-fab { bottom: 20px; right: 160px; width: 42px; height: 42px; }

/* DEMO PRESETS WIDGET */
.demo-widget { position: fixed; top: 16px; left: 16px; z-index: 999; }
.demo-widget-toggle { background-color: var(--text-primary); color: #FFFFFF; border: none; padding: 6px 12px; border-radius: var(--radius-full); font-size: 0.68rem; font-weight: 700; cursor: pointer; }
.demo-panel { display: none; position: absolute; top: 38px; left: 0; width: 300px; background-color: #FFFFFF; border-radius: var(--radius-md); border: 1px solid var(--border-gallery); box-shadow: 0 16px 40px rgba(0,0,0,0.15); padding: 14px; }
.demo-panel.active { display: block; }
.demo-panel-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.btn-close-demo { background: none; border: none; font-size: 1.2rem; cursor: pointer; }

.lang-selector-group { display: flex; gap: 6px; margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid var(--border-gallery); }
.lang-label { font-size: 0.68rem; font-weight: 700; }
.lang-btn { padding: 4px 8px; border-radius: 4px; border: 1px solid var(--border-gallery); background-color: var(--bg-card); font-size: 0.65rem; cursor: pointer; }
.lang-btn.active { background-color: var(--terracotta); color: #FFFFFF; border-color: var(--terracotta); }

.demo-preset-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; max-height: 200px; overflow-y: auto; }
.preset-btn { padding: 6px; border-radius: 4px; border: 1px solid var(--border-gallery); background-color: var(--bg-card); font-size: 0.68rem; cursor: pointer; text-align: left; }
.preset-btn.active { background-color: var(--soft-peach); border-color: var(--border-gold); }

#confetti-canvas { position: fixed; inset: 0; pointer-events: none; z-index: 9999; }
