/* --- FONTS & BASE SETUP --- */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&display=swap');
/* Adding a serif font for the headers to match the screenshot */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@1,700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Orbitron', sans-serif;
    background-color: #050a0f; 
    color: #e0e0e0;
    line-height: 1.6;
    position: relative;
    min-height: 100vh;
    overflow-x: hidden; 
}

/* --- THE ORGANIC DATAMOSH LENS --- */
#glitch-lens {
    position: fixed;
    width: 250px; 
    height: 250px;
    margin-top: -125px;
    margin-left: -125px;
    pointer-events: none; 
    z-index: 9998; 
    -webkit-mask-image: radial-gradient(circle, black 15%, transparent 60%);
    mask-image: radial-gradient(circle, black 15%, transparent 60%);
    animation: organic-morph 4s infinite linear;
}

@keyframes organic-morph {
    0% { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; backdrop-filter: hue-rotate(0deg) contrast(200%) saturate(150%); transform: rotate(0deg) scale(1); }
    33% { border-radius: 60% 40% 30% 70% / 50% 60% 40% 50%; backdrop-filter: hue-rotate(90deg) contrast(300%) saturate(300%); transform: rotate(120deg) scale(1.1); }
    66% { border-radius: 50% 50% 60% 40% / 60% 40% 50% 60%; backdrop-filter: hue-rotate(180deg) contrast(250%) saturate(200%); transform: rotate(240deg) scale(0.9); }
    100% { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; backdrop-filter: hue-rotate(360deg) contrast(200%) saturate(150%); transform: rotate(360deg) scale(1); }
}

/* --- TINY PIXEL PARTICLES --- */
#pixel-container {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 9997; overflow: hidden;
}

.tiny-pixel {
    position: absolute; opacity: 0.9; border-radius: 1px;
    transition: transform 1s cubic-bezier(0.25, 1, 0.5, 1), opacity 1s ease-in;
    box-shadow: 0 0 4px currentColor; 
}

/* --- CRT SCANLINES --- */
.scanlines {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,0) 50%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.3));
    background-size: 100% 4px; pointer-events: none; z-index: 9999;
}

/* --- TOP BANNER --- */
.banner-container {
    width: 100%; height: 150px; position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden;
    border-bottom: 1px solid #333; /* Subdued border */
}

.glitch-banner {
    position: absolute; top: 50%; left: 50%; min-width: 100%; min-height: 100%; width: auto; height: auto;
    transform: translateX(-50%) translateY(-50%); z-index: 1; opacity: 0.4; filter: contrast(130%) saturate(150%) hue-rotate(-10deg); 
}

header {
    text-align: center; position: relative; z-index: 10; transform: scale(0.8); 
}

.chromatic-text {
    font-size: 3rem; font-weight: 700; color: #ffffff; text-transform: uppercase; letter-spacing: 5px;
    text-shadow: 4px 0px 0px rgba(138, 43, 226, 0.8), -4px 0px 0px rgba(0, 255, 255, 0.8); 
}

.neon-text {
    color: #8a2be2; text-transform: uppercase; letter-spacing: 2px;
}


/* --- DASHBOARD LAYOUT (Inspired by Screenshot) --- */
.dashboard {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 2rem;
    position: relative;
    z-index: 10;
}

.nav-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-style: italic;
    color: #e0e0e0;
    margin-bottom: 2rem;
}

/* Catalog Large Cards Grid */
.catalog-container {
    display: grid;
    /* Forces exactly 3 columns, perfectly aligning with the links below */
    grid-template-columns: repeat(3, 1fr); 
    gap: 2rem;
    margin-bottom: 3rem;
}

.catalog-card {
    display: block;
    background-color: #0a0e14;
    border: 1px solid #222;
    padding: 1.5rem;
    text-decoration: none;
    color: #fff;
    transition: transform 0.4s ease-out, filter 0.4s ease-out;
    transform-style: preserve-3d; 
    position: relative;
    overflow: hidden; 
}

.catalog-card:hover {
    border-color: #00ffff; /* Teal glow on hover */
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.2);
}

.card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.badge {
    border: 1px solid #444;
    padding: 2px 6px;
    font-size: 0.7rem;
    color: #888;
}

.icon { color: #888; }

.catalog-card h2 {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 1.5rem;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.catalog-card p {
    font-size: 0.7rem;
    color: #888;
    text-transform: uppercase;
}

/* Horizontal Line */
.section-divider {
    border: 0;
    height: 1px;
    background: #222;
    margin-bottom: 3rem;
}

/* Links Columns Grid */
.links-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.category-header {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    color: #fdfaa3; /* Pale Yellow instead of green to match your palette */
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    font-weight: 400;
}

.link-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #0a0e14;
    border: 1px solid #222;
    padding: 1rem;
    margin-bottom: 0.8rem;
    text-decoration: none;
    color: #ccc;
    font-size: 0.85rem;
    transition: transform 0.4s ease-out, filter 0.4s ease-out;
    transform-style: preserve-3d;
}

.link-box span {
    color: #555;
    font-family: monospace; /* For the arrow */
}

.link-box:hover {
    color: #ff6600; /* Orange highlight */
    border-color: #ff6600;
}
.link-box:hover span { color: #ff6600; }

/* --- SYSTEM STATUS BAR (Replaces Floating Music Box) --- */
.system-status-bar {
    max-width: 1200px;
    margin: 0 auto 3rem auto; /* Centers it and pushes the dashboard down */
    background-color: rgba(10, 14, 20, 0.8); /* Slight transparency */
    border-bottom: 1px dashed #333;
    border-top: 1px dashed #333;
    padding: 12px 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: monospace;
    font-size: 0.8rem;
    color: #888;
    position: relative;
    z-index: 10;
    
    /* Connects it to the Javascript bending math */
    transition: transform 0.4s ease-out, filter 0.4s ease-out;
    transform-style: preserve-3d;
}

.system-status-bar:hover {
    border-color: #00ffff; /* Subtle teal glow on the borders when hovered */
    box-shadow: inset 0 0 15px rgba(0, 255, 255, 0.05);
}

.status-left, .status-center, .status-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.status-btn {
    background: transparent;
    border: 1px solid #00ffff; /* Teal */
    color: #00ffff;
    padding: 6px 15px;
    cursor: pointer;
    font-family: monospace;
    transition: all 0.3s ease;
}

.status-btn:hover {
    background: rgba(0, 255, 255, 0.1);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.4);
    color: #fff;
}

.now-playing {
    color: #666;
}

.music-title {
    color: #e0e0e0;
    letter-spacing: 1px;
}

.music-status {
    color: #fdfaa3; /* Pale Yellow */
    font-weight: bold;
}

.disc-icon { 
    font-size: 1.2rem; 
    color: #444; 
}

.spinning { 
    color: #8a2be2; /* Deep Purple */
    animation: spin 2s linear infinite; 
}

@keyframes spin { 
    100% { transform: rotate(360deg); } 
}

/* Ensure responsiveness on smaller screens */
@media (max-width: 768px) {
    .system-status-bar {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

/* --- CARD VIDEO BACKGROUND STYLES --- */
.card-video-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures the video fills the box without stretching weirdly */
    z-index: 0;
    pointer-events: none; /* Prevents the video from blocking your clicks */
    filter: contrast(120%) saturate(150%) hue-rotate(-10deg); /* Vaporwave tint */
}

.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 14, 20, 0.6); /* Dark tint so the text pops */
    z-index: 1;
    pointer-events: none;
}

.card-content {
    position: relative;
    z-index: 2; /* Puts the text physically above the video and overlay */
}


/* --- MINIMAL SYSTEM FOOTER --- */
.site-footer {
    max-width: 1200px;
    margin: 4rem auto 2rem auto; /* Pushes it down from the dashboard links */
    padding: 2rem 2rem 0 2rem;
    border-top: 1px dashed #333; /* Retro terminal separator */
    text-align: center;
    font-family: monospace; 
    font-size: 0.75rem;
    letter-spacing: 1px;
    color: #666; /* Subdued gray so it stays minimal */
    position: relative;
    z-index: 10;
    
    /* Prepares the footer for the JS datamosh math */
    transition: transform 0.4s ease-out, filter 0.4s ease-out, color 0.3s ease;
    transform-style: preserve-3d;
}

.site-footer:hover {
    color: #fdfaa3; /* Illuminates in your pale yellow palette on hover */
    text-shadow: 0 0 8px rgba(253, 250, 163, 0.4);
}

.footer-dim {
    color: #444; /* Makes the secondary text even darker */
    margin-left: 10px;
}

/* --- EKATO MARBLE THEME --- */

/* The Bright Marble Music Bar */
.marble-status-bar {
    max-width: 1200px;
    margin: 0 auto 3rem auto;
    background: linear-gradient(135deg, #f4f7f6, #dcdedd); /* Pale marble gradient */
    border: 1px solid #aeb2b5;
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.05);
    padding: 12px 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: monospace;
    font-size: 0.8rem;
    color: #1a1a1a; /* Dark text for readability */
    position: relative;
    z-index: 10;
    transition: transform 0.4s ease-out, filter 0.4s ease-out;
}

.marble-status-bar .status-btn {
    border-color: #1a1a1a;
    color: #1a1a1a;
}
.marble-status-bar .status-btn:hover {
    background: rgba(0,0,0,0.1);
    color: #000;
}
.marble-status-bar .music-status {
    color: #b89814; /* Tarnished Gold */
}

/* The Expanding Accordion Gallery */
.accordion-container {
    display: flex;
    gap: 10px;
    max-width: 1200px;
    margin: 0 auto 4rem auto;
    height: 600px; /* Base height */
}

.accordion-card {
    flex: 1; /* Default state: narrow vertical strip */
    background-color: #0a0e14;
    border: 1px solid #333;
    position: relative;
    overflow: hidden;
    /* Smooth, heavy easing for the push effect */
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1), filter 0.4s ease;
    cursor: crosshair;
}

.accordion-card:hover {
    flex: 2; /* Expands to take up exactly 600px of width, creating a perfect 1:1 square */
    border-color: #fdfaa3; /* Pale gold glow */
}

.accordion-card video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.5;
    /* Extremely heavy grayscale when inactive */
    filter: grayscale(100%) contrast(120%) brightness(0.6);
    transition: opacity 0.6s ease, filter 0.6s ease;
    pointer-events: none; /* Crucial so hover works on the card itself */
}

.accordion-card:hover video {
    opacity: 1;
    /* Full color wakes up on hover */
    filter: grayscale(0%) contrast(110%) brightness(1);
}

.accordion-title {
    position: absolute;
    bottom: 30px;
    left: 30px;
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 2rem;
    color: #fff;
    z-index: 2;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    text-shadow: 2px 2px 5px rgba(0,0,0,0.8);
}

.accordion-card:hover .accordion-title {
    opacity: 1;
    transform: translateY(0);
}

/* Jagged Marble Shard Particles */
.marble-shard {
    position: absolute;
    opacity: 0.9;
    /* Uses clip-path to make them look like sharp, broken shards instead of squares */
    clip-path: polygon(0% 15%, 15% 15%, 15% 0%, 85% 0%, 85% 15%, 100% 15%, 100% 85%, 85% 85%, 85% 100%, 15% 100%, 15% 85%, 0% 85%);
    transition: transform 1.2s cubic-bezier(0.5, 0, 1, 1), opacity 1.2s ease-in;
}

/* --- THE GLITCH COLOR-SHIFTING TITLE --- */
@keyframes glitch-color-flow {
    0%   { color: #00ffff; text-shadow: 2px 0 #8a2be2, -2px 0 #ff6600; } /* Teal with Purple/Orange aberration */
    20%  { color: #8a2be2; text-shadow: 2px 0 #ff6600, -2px 0 #fdfaa3; } /* Purple with Orange/Pale Yellow aberration */
    40%  { color: #ff6600; text-shadow: 2px 0 #00ffff, -2px 0 #0a0a8c; } /* Orange with Teal/Deep Blue aberration */
    60%  { color: #fdfaa3; text-shadow: 2px 0 #ff6600, -2px 0 #8a2be2; } /* Pale Yellow with Orange/Purple aberration */
    80%  { color: #0a0a8c; text-shadow: 2px 0 #00ffff, -2px 0 #ff6600; } /* Deep Blue with Teal/Orange aberration */
    100% { color: #00ffff; text-shadow: 2px 0 #8a2be2, -2px 0 #ff6600; } /* Loop back to start */
}

/* We apply this class to the title in the HTML */
.song-title-glitch {
    font-weight: bold;
    letter-spacing: 1px;
    animation: glitch-color-flow 1.5s infinite linear; /* Fast, chaotic shifting */
}

/* --- THE NEW ELECTRIFIED MARBLE CHIPS --- */
/* We replace the old .marble-shard rule with this one */
.marble-chip {
    position: absolute;
    opacity: 0.9;
    /* This clip-path creates a sharp, random triangular fragment */
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%); 
    transition: transform 1.2s cubic-bezier(0.5, 0, 1, 1), opacity 1.2s ease-in;
    /* Add a strong electric neon glow */
    box-shadow: 0 0 10px currentColor; 
}

