/* CSS Reset & Variable Definitions */
:root {
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --color-bg: #07090e;
    --color-white: #ffffff;
    --color-white-translucent: rgba(255, 255, 255, 0.8);
    --color-border-grid: rgba(255, 255, 255, 0.15);
    
    /* Responsive Box Padding */
    --box-padding-y: clamp(1.5rem, 4vw, 3rem);
    --box-padding-x: clamp(2rem, 6vw, 5rem);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: var(--color-bg);
    font-family: var(--font-body);
    color: var(--color-white);
}

/* Screen Reader Only class for SEO headings */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* Background Video Styling */
.video-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    overflow: hidden;
}

#bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.85; /* Soft background video blend */
    z-index: 1;
    transform: scale(1.3); /* Zoom in to crop baked-in black pillarbox bars */
    transform-origin: center center;
    transition: opacity 1s ease-in-out;
}

/* Hide all default webkit/safari video playback controls and start overlays */
#bg-video::-webkit-media-controls {
    display: none !important;
}
#bg-video::-webkit-media-controls-play-button {
    display: none !important;
}
#bg-video::-webkit-media-controls-panel {
    display: none !important;
}
#bg-video::-webkit-media-controls-start-playback-button {
    display: none !important;
}

.overlay-filter {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        circle at center,
        rgba(7, 9, 14, 0.45) 0%,
        rgba(7, 9, 14, 0.78) 100%
    );
    z-index: 2;
}

/* Interactive Canvas Grid */
#grid-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 2;
    pointer-events: none; /* Allows click-through and smooth hover capture from window */
}

/* Centered Branding Card Box */
.center-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 3;
    pointer-events: none; /* Let background canvas get events if needed, box overrides */
}

.brand-box {
    pointer-events: auto;
    border: 2px solid var(--color-white);
    background: rgba(7, 9, 14, 0.35);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: var(--box-padding-y) var(--box-padding-x);
    text-align: center;
    box-shadow: 
        0 15px 45px rgba(0, 0, 0, 0.5), 
        inset 0 0 15px rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    animation: revealBox 1.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 0.4s;
    transition: 
        transform 0.8s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.5s ease,
        box-shadow 0.5s ease;
}

.brand-box:hover {
    background: rgba(7, 9, 14, 0.55);
    transform: translateY(0px) scale(1.02);
    box-shadow: 
        0 25px 60px rgba(0, 0, 0, 0.7),
        0 0 20px rgba(255, 255, 255, 0.1),
        inset 0 0 20px rgba(255, 255, 255, 0.1);
}

/* Scaling font based on device. 24pt (32px) starting point */
.title {
    font-family: var(--font-heading);
    font-size: clamp(32px, 5.5vw, 56px); /* 32px is 24pt base */
    font-weight: 300;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--color-white);
    margin-right: -0.25em; /* Correct for letter-spacing offset on center alignment */
    line-height: 1.1;
}

.post-title {
    font-family: var(--font-body);
    font-size: clamp(0.7rem, 1.5vw, 0.85rem);
    font-weight: 400;
    letter-spacing: 0.5em;
    color: var(--color-white-translucent);
    margin-right: -0.5em;
    opacity: 0.8;
}

/* Premium Footer */
#main-footer {
    position: fixed;
    bottom: 2rem;
    left: 0;
    width: 100vw;
    display: flex;
    justify-content: center;
    z-index: 3;
    pointer-events: none;
    opacity: 0;
    animation: fadeIn 1s ease-out forwards;
    animation-delay: 1.2s;
}

.footer-content {
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 400;
    letter-spacing: 0.3em;
    color: rgba(255, 255, 255, 0.4);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.footer-content .bullet {
    color: rgba(255, 255, 255, 0.2);
}

/* Entrance Animations */
@keyframes revealBox {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

/* Responsive adjustments for mobile touch targets */
@media (max-width: 480px) {
    .brand-box {
        border-width: 1.5px;
    }
}
