/* xity.quest - Swiss International Typographic Style Generative Archive */

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

:root {
    --sand-light: #f5ede1;
    --sand-mid: #e8ddd0;
    --warm-tan: #d4a67d;
    --brown: #8a6f5e;
    --rust: #c4693d;
    --teal: #5b7e8a;
    --charcoal: #4a4a42;
    --near-black: #2c2c2c;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--sand-light);
    color: var(--near-black);
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Navigation */
#top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    border-bottom: 1px solid var(--charcoal);
    background-color: rgba(245, 237, 225, 0.95);
    backdrop-filter: blur(4px);
}

.nav-domain {
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--near-black);
}

.nav-circle {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--near-black);
    cursor: pointer;
    line-height: 1;
    padding: 4px;
    transition: color 0.3s ease;
}

.nav-circle:hover {
    color: var(--rust);
}

/* Overlay Menu */
.overlay-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2000;
    background-color: rgba(44, 44, 44, 0.96);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.overlay-menu.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.overlay-inner {
    text-align: center;
    position: relative;
}

.overlay-link {
    display: block;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 48px;
    letter-spacing: 0.08em;
    color: var(--sand-light);
    text-decoration: none;
    margin: 24px 0;
    transition: color 0.3s ease;
}

.overlay-link:hover {
    color: var(--rust);
}

.overlay-close {
    position: absolute;
    top: -80px;
    right: -60px;
    background: none;
    border: none;
    color: var(--sand-light);
    font-size: 24px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.overlay-close:hover {
    color: var(--rust);
}

/* Entry Manifesto */
.entry-manifesto {
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    background-color: var(--sand-light);
    overflow: hidden;
}

.hero-word {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(100px, 20vw, 300px);
    font-weight: 400;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--near-black);
    line-height: 0.9;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.hero-word.visible {
    opacity: 1;
    transform: translateY(0);
}

.hero-definition {
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    color: var(--teal);
    letter-spacing: 0.05em;
    margin-top: 20px;
    opacity: 0;
    transition: opacity 1s ease 0.4s;
}

.hero-definition.visible {
    opacity: 1;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.scroll-line {
    display: block;
    width: 1px;
    height: 60px;
    background: var(--charcoal);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(0.6); }
    50% { opacity: 1; transform: scaleY(1); }
}

/* Exhibit Grid Section */
.exhibit-grid-section {
    padding: 80px 24px 120px;
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 60px;
}

.section-label {
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--charcoal);
    white-space: nowrap;
}

.section-rule {
    flex: 1;
    height: 1px;
    background-color: var(--charcoal);
    opacity: 0.3;
}

/* 12-column grid */
.exhibit-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 16px;
}

/* Card base styles */
.exhibit-card {
    background-color: var(--sand-mid);
    border: 1px solid rgba(74, 74, 66, 0.15);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 280px;
    position: relative;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.3s ease;
    cursor: default;
}

.exhibit-card.revealed {
    opacity: 1;
    transform: translateY(0);
}

.exhibit-card:hover {
    box-shadow: 0 4px 20px rgba(44, 44, 44, 0.1);
}

/* Card span variations for staggered grid */
.exhibit-card.span-4 { grid-column: span 4; }
.exhibit-card.span-6 { grid-column: span 6; }
.exhibit-card.span-8 { grid-column: span 8; }
.exhibit-card.span-3 { grid-column: span 3; }
.exhibit-card.span-5 { grid-column: span 5; }

.card-pattern {
    flex: 1;
    margin-bottom: 16px;
}

.card-pattern svg {
    width: 100%;
    height: 100%;
    display: block;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.card-index {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    color: var(--charcoal);
    letter-spacing: 0.1em;
}

.card-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 18px;
    letter-spacing: 0.04em;
    color: var(--near-black);
}

/* Dark background cards */
.exhibit-card.dark {
    background-color: var(--near-black);
}

.exhibit-card.dark .card-index {
    color: var(--sand-mid);
}

.exhibit-card.dark .card-title {
    color: var(--sand-light);
}

/* Accent background cards */
.exhibit-card.accent {
    background-color: var(--teal);
}

.exhibit-card.accent .card-index {
    color: var(--sand-light);
}

.exhibit-card.accent .card-title {
    color: var(--sand-light);
}

/* Colophon */
.colophon-section {
    background-color: var(--near-black);
    padding: 80px 24px;
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.colophon-inner {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.colophon-timestamp {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.colophon-label {
    font-family: 'Inter', sans-serif;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.2em;
    color: var(--brown);
}

.colophon-time {
    font-family: 'Space Mono', monospace;
    font-size: 14px;
    color: var(--sand-mid);
    letter-spacing: 0.05em;
}

.colophon-sigil svg {
    opacity: 0.7;
}

.colophon-domain {
    display: block;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 28px;
    letter-spacing: 0.08em;
    color: var(--sand-light);
    margin-bottom: 8px;
}

.colophon-note {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 300;
    color: var(--brown);
    letter-spacing: 0.04em;
}

/* Responsive */
@media (max-width: 768px) {
    .exhibit-grid {
        grid-template-columns: repeat(6, 1fr);
    }
    .exhibit-card.span-8 {
        grid-column: span 6;
    }
    .exhibit-card.span-6 {
        grid-column: span 6;
    }
    .exhibit-card.span-5 {
        grid-column: span 6;
    }
    .exhibit-card.span-4 {
        grid-column: span 6;
    }
    .exhibit-card.span-3 {
        grid-column: span 3;
    }
    .overlay-link {
        font-size: 32px;
    }
}

@media (max-width: 480px) {
    .exhibit-grid {
        grid-template-columns: 1fr;
    }
    .exhibit-card.span-4,
    .exhibit-card.span-6,
    .exhibit-card.span-8,
    .exhibit-card.span-3,
    .exhibit-card.span-5 {
        grid-column: span 1;
    }
}
