:root {
    --bg-color: #000000;
    --text-color: #A0D8EF;
    /* Light Blue */
    --accent-color: #A0D8EF;
    --font-main: 'Cinzel', serif;
}

[data-theme="light"] {
    --bg-color: #A0D8EF;
    --text-color: #000000;
    --accent-color: #000000;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    overflow: hidden;
    transition: background-color 0.5s ease, color 0.5s ease;
    height: 100vh;
    width: 100vw;
    display: flex;
    justify-content: center;
    align-items: center;
}

.theme-toggle {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
}

#toggle-theme {
    background: none;
    border: 1px solid var(--text-color);
    color: var(--text-color);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

#toggle-theme:hover {
    background-color: var(--text-color);
    color: var(--bg-color);
}

.container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.logo-container {
    position: relative;
    z-index: 10;
    margin-bottom: 5vh;
    /* Adjust based on wave position */
}

.exodos-logo-svg {
    width: 60vw;
    max-width: 800px;
    /* SVG native is 650, allowing scale up/down */
    height: auto;
    display: block;
    margin: 0 auto;
    /* Essential for centering display:block */
    position: relative;
    z-index: 10;
}

/* Target all paths inside the SVG to use the theme text color */
.exodos-logo-svg path {
    fill: var(--text-color) !important;
    /* Override inline fill colors */
    transition: fill 0.5s ease;
}

.delta {
    display: inline-block;
    font-size: 0.6em;
    /* Significantly smaller */
    vertical-align: middle;
    /* Align middle or baseline? */
    transform: translateY(-0.1em);
    /* Fine tune position */
    opacity: 0.8;
    /* Slightly dimmer? */
}

/* sea of pixels effect */
.pixel-sea {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50%;
    /* Cover bottom half */
    background: var(--bg-color);
    z-index: 2;
    /* Create a pixelated dissolve mask */
    mask-image: linear-gradient(to bottom, transparent 0%, black 100%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 100%);

    /* We can use a pseudo-element to draw "pixels" or noise */
    display: flex;
    flex-wrap: wrap;
    overflow: hidden;
    opacity: 0.9;
}

/* Alternative: Pixelated distortion on the text itself using clamp/clip-path? 
   Let's try a visual trick. We duplicate the text, crop it to the bottom half, 
   and apply a pixelation filter/effect.
*/

.logo-container {
    position: relative;
}

.exodos-logo {
    position: relative;
    z-index: 1;
}

/* The element effectively hiding the bottom half with "pixels" */
.logo-container::after {
    content: attr(data-text);
    /* This won't work on container, need structure tweak or JS */
}

/* Let's refine the "emerging from sea of pixels" */
/* We will use a backdrop filter or a pattern overlay on the bottom half */
.pixel-sea {
    position: absolute;
    bottom: -10%;
    /* Extend a bit lower */
    left: -10%;
    width: 120%;
    height: 60%;
    /* Cover more than half to be safe */
    background-image:
        linear-gradient(45deg, var(--text-color) 25%, transparent 25%),
        linear-gradient(-45deg, var(--text-color) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, var(--text-color) 75%),
        linear-gradient(-45deg, transparent 75%, var(--text-color) 75%);
    background-size: 10px 10px;
    background-position: 0 0, 0 5px, 5px -5px, -5px 0px;
    mask-image: linear-gradient(to bottom, transparent 0%, black 80%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 40%, black 100%);
    opacity: 0.2;
    /* Just a texture */
    z-index: 0;
    pointer-events: none;
    display: none;
    /* Re-evaluating this approach */
}

/* Better approach for "Mer de pixels": 
   The bottom half of the letters is dissolved into blocks.
*/
.exodos-logo {
    /* Gradient to fade out bottom */
    mask-image: linear-gradient(to bottom, black 40%, transparent 80%);
    -webkit-mask-image: linear-gradient(to bottom, black 40%, transparent 80%);
}

#waves-canvas {
    position: absolute;
    bottom: 0px;
    /* Align to bottom of screen? Or center? Joy Division is center. */
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    /* Max width */
    max-width: 100%;
    height: 600px;
    z-index: 1;
}

@media (max-width: 600px) {
    .exodos-logo {
        font-size: 18vw;
    }

    #waves-canvas {
        width: 100%;
        height: 50vh;
    }
}