/* gabs.cx - Sci-Fi Space Station */
:root {
    --void-indigo: #0f0a1e;
    --nebula-purple: #1a0f2e;
    --sunset-coral: #ff8a5b;
    --aurora-amber: #ffb366;
    --dawn-blush: #ffd4b8;
    --starlight: #f0e8f5;
    --haze-lavender: #b8a5cc;
    --signal-magenta: #e84393;
    --aurora-green: #43e89e;
    --aurora-violet: #a855f7;
}

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

body {
    font-family: 'Space Grotesk', sans-serif;
    background-color: var(--void-indigo);
    color: var(--starlight);
    overflow-x: hidden;
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
    line-height: 1.65;
    font-weight: 400;
}

#aurora-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    opacity: 0.25;
    pointer-events: none;
}

.station-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 12px;
    padding: 24px;
    max-width: 1400px;
    margin: 0 auto;
}

.module {
    background-color: var(--nebula-purple);
    border: 1px solid rgba(255, 138, 91, 0.2);
    border-radius: 2px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.3s, box-shadow 0.3s;
    opacity: 0;
    transform: translateY(15px);
}

.module.visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease-out, transform 0.4s ease-out, border-color 0.3s, box-shadow 0.3s;
}

.module:hover {
    transform: scale(1.03);
    border-color: rgba(255, 138, 91, 0.6);
    box-shadow: 0 0 35px rgba(255, 138, 91, 0.3);
}

.module:hover .iso-icon {
    transform: translateY(-4px);
}

.module.expanded {
    transform: scale(1.05);
    z-index: 10;
    border-color: rgba(255, 138, 91, 0.8);
    box-shadow: 0 0 50px rgba(255, 138, 91, 0.35);
}

.module.expanded .module-detail {
    max-height: 200px;
    opacity: 1;
    margin-top: 1rem;
}

.module.dimmed {
    opacity: 0.5;
    filter: blur(1px);
}

.module-inner {
    padding: 24px;
}

.module-warm {
    background-color: rgba(255, 138, 91, 0.12);
}

.module-2x2 {
    grid-column: span 2;
    grid-row: span 2;
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.module-2x1 { grid-column: span 2; }
.module-1x2 { grid-row: span 2; }
.module-full { grid-column: 1 / -1; }

.module-hero {
    background: radial-gradient(ellipse at 50% 50%, rgba(168, 85, 247, 0.1) 0%, var(--nebula-purple) 70%);
}

.hero-badge {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 700;
    font-size: clamp(3rem, 7vw, 5.5rem);
    letter-spacing: -0.015em;
    color: var(--starlight);
    text-shadow: 0 0 60px rgba(255, 138, 91, 0.2);
    text-align: center;
}

.hero-sub {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    font-style: italic;
    font-size: clamp(1rem, 2vw, 1.5rem);
    letter-spacing: 0.04em;
    color: var(--dawn-blush);
    text-align: center;
    margin-top: 1rem;
}

.iso-icon {
    width: 100px;
    height: 100px;
    float: right;
    margin: 0 0 12px 16px;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.module-title {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 700;
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    letter-spacing: -0.015em;
    color: var(--starlight);
    margin-bottom: 0.5rem;
}

.module-body {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(0.85rem, 1.1vw, 1rem);
    color: var(--starlight);
    opacity: 0.85;
    line-height: 1.6;
}

.module-detail {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    color: var(--haze-lavender);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.35s, margin-top 0.35s;
}

.module-label {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--haze-lavender);
    display: block;
    margin-bottom: 0.5rem;
}

.module-data {
    font-family: 'Space Mono', monospace;
    font-size: 0.8rem;
    color: var(--aurora-amber);
    letter-spacing: 0.06em;
    display: block;
    margin-bottom: 0.5rem;
}

.italic-fragment {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    font-style: italic;
    font-size: clamp(1rem, 2vw, 1.5rem);
    color: var(--dawn-blush);
    letter-spacing: 0.04em;
}

.module-engine {
    background: linear-gradient(90deg, var(--nebula-purple) 0%, rgba(168, 85, 247, 0.08) 50%, var(--nebula-purple) 100%);
    animation: enginePulse 4s ease-in-out infinite;
}

@keyframes enginePulse {
    0%, 100% { background-size: 200% 100%; background-position: 0% 50%; }
    50% { background-size: 200% 100%; background-position: 100% 50%; }
}

.engine-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    color: var(--haze-lavender);
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.signal-ring {
    position: fixed;
    width: 200px;
    height: 200px;
    pointer-events: none;
    z-index: 0;
}

.signal-ring-1 { top: 15%; left: 5%; }
.signal-ring-2 { bottom: 20%; right: 8%; }

@media (max-width: 768px) {
    .module-2x2 { grid-column: span 1; grid-row: span 1; min-height: 200px; }
    .module-2x1 { grid-column: span 1; }
    .station-grid { padding: 16px; }
    .module-inner { padding: 16px; }
}
