/* --- F76.online Main Stylesheet (v5.0 - Wasteland Clarity Protocol) --- */

/* ---------------------------------- */
/*      1. ROOT & FOUNDATION          */
/* ---------------------------------- */
:root {
    /* Color Palette: Refined for clarity and theme */
    --owl-bg-primary: #121212; 
    --owl-bg-secondary: #1A1A1A;
    --owl-bg-tertiary: #252525;
    --owl-border-color: rgba(255, 199, 44, 0.15);
    --owl-text-primary: #E0E0E0; 
    --owl-text-secondary: #A0A0A0; /* Softened for better contrast */
    --owl-accent-gold: #FFC72C;  
    --owl-accent-gold-rgb: 255, 199, 44;
    --owl-terminal-green: #45C453;
    --owl-status-active: #45C453;
    --owl-status-inactive: #333333;

    /* Typography: Now with dynamic scaling */
    --font-heading: 'Aldrich', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --font-mono: 'Share Tech Mono', monospace;

    /* Layout */
    --content-width: 1400px;
    --grid-gap: 1.25rem; /* Slightly tighter grid */
    --border-radius: 4px;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    font-weight: 400;
    background-color: var(--owl-bg-primary);
    color: var(--owl-text-primary);
    /* New: subtle scanlines for thematic texture */
    background-image: 
        linear-gradient(rgba(18, 18, 18, 0) 50%, rgba(0, 0, 0, 0.25) 50%), 
        linear-gradient(90deg, rgba(255, 0, 0, 0.03), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.03));
    background-size: 100% 4px, 100% 100%;
    overflow-x: hidden;
    padding-top: 64px;
    transition: opacity 0.5s ease-in-out;
}

.opacity-0 { opacity: 0; }
body::-webkit-scrollbar { width: 8px; }
body::-webkit-scrollbar-track { background: var(--owl-bg-primary); }
body::-webkit-scrollbar-thumb { background-color: var(--owl-bg-secondary); border: 1px solid var(--owl-border-color); }


/* ---------------------------------- */
/*      2. HEADER & NAVIGATION        */
/* ---------------------------------- */
.site-header {
    height: 64px;
    background-color: rgba(18, 18, 18, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--owl-border-color);
}

.header-container { max-width: var(--content-width); margin: 0 auto; padding: 0 1.5rem; height: 100%; display: flex; align-items: center; justify-content: space-between; }
.site-title-wrapper { display: inline-flex; align-items: center; text-decoration: none; }
.site-logo-star { width: 24px; height: 24px; margin-right: 10px; fill: var(--owl-accent-gold); transition: transform 0.3s ease; }
.site-title-wrapper:hover .site-logo-star { transform: rotate(180deg); }
.site-name { font-family: var(--font-heading); color: var(--owl-accent-gold); font-size: 1.5rem; letter-spacing: 1px; }

.header-nav { display: flex; gap: 0.5rem; }
.nav-link { font-family: var(--font-mono); padding: 0.5rem 1rem; font-size: 0.9rem; color: var(--owl-text-secondary); text-decoration: none; text-transform: uppercase; border: 1px solid transparent; border-radius: var(--border-radius); transition: all 0.2s ease-out; }
.nav-link:hover, .nav-link:focus-visible { color: var(--owl-text-primary); background-color: rgba(var(--owl-accent-gold-rgb), 0.1); outline: none; }

#mobile-menu-button { color: var(--owl-text-secondary); background: none; border: none; cursor: pointer; }
#mobile-menu-button .icon { height: 1.75rem; width: 1.75rem; }
#mobile-menu { background-color: #151515; border-top: 1px solid var(--owl-border-color); padding: 1rem; display: flex; flex-direction: column; gap: 0.5rem; }


/* ---------------------------------- */
/*      3. DASHBOARD & UNIFIED GRID   */
/* ---------------------------------- */
.page-section { max-width: var(--content-width); margin: 0 auto; padding: 0 1.5rem; }

.dashboard-header { display: flex; align-items: center; gap: 1.5rem; margin: 2.5rem 0; padding: 1.5rem; border: 1px solid var(--owl-border-color); background-color: var(--owl-bg-secondary); border-radius: var(--border-radius); }
.hero-logo-image { display: block; width: 100px; height: auto; align-self: flex-start; }
/* DYNAMIC TYPOGRAPHY: Better scaling on all devices */
.hero-headline-main { font-family: var(--font-heading); font-size: clamp(2rem, 5vw, 2.5rem); margin: 0; color: var(--owl-text-primary); line-height: 1.1; }
.hero-paragraph { font-size: clamp(0.9rem, 2vw, 1rem); margin: 0.75rem 0 0; color: var(--owl-text-secondary); max-width: 60ch; }

/* DEPRECATED: .bento-grid. UPGRADED TO: .unified-grid */
.unified-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: var(--grid-gap);
}

.grid-item {
    background-color: var(--owl-bg-secondary);
    border: 1px solid var(--owl-border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

/* Priority items can span more space on larger screens */
@media (min-width: 992px) {
    .priority-card { grid-column: span 2; }
    .bulletins-container { grid-column: span 2; }
}


/* ---------------------------------- */
/*      4. COMPONENT STYLES (CARDS)   */
/* ---------------------------------- */

/* Priority Card (Replaces News Card) */
.priority-card {
    padding: 0; 
    background: linear-gradient(145deg, var(--owl-bg-tertiary), #1a1a1a);
}
.priority-card-header { padding: 1.5rem 1.5rem 1rem; border-bottom: 1px solid var(--owl-border-color); }
.priority-card-tag { font-family: var(--font-mono); font-size: 0.8rem; text-transform: uppercase; color: var(--owl-terminal-green); }
.priority-card-title { font-family: var(--font-heading); font-size: clamp(1.5rem, 4vw, 2rem); color: var(--owl-accent-gold); margin: 0.25rem 0 0; }
.priority-card-body { padding: 1.5rem; }
.priority-card-subtitle { font-size: 1.1rem; color: var(--owl-text-primary); margin: 0 0 1.5rem; }
.priority-card-body ul { list-style-type: "■ "; margin: 0 0 1.5rem; padding-left: 1.5rem; }
.priority-card-body li { margin-bottom: 0.5rem; padding-left: 0.5rem; color: var(--owl-text-secondary); }

/* Unified Intel Cards */
.intel-card-title { font-family: var(--font-heading); font-size: 1.3rem; color: var(--owl-accent-gold); margin: 0 0 0.5rem; }
.intel-card-intro { font-size: 0.9rem; color: var(--owl-text-secondary); margin-bottom: 1.5rem; flex-grow: 1; }
.event-status-item { display: flex; justify-content: space-between; align-items: center; padding: 0.75rem 0; border-bottom: 1px solid var(--owl-bg-primary); }
.event-status-item:last-child { border-bottom: none; }
.status-indicator { font-family: var(--font-mono); font-weight: bold; padding: 0.25rem 0.5rem; border-radius: var(--border-radius); font-size: 0.8rem; }
.status-indicator.status-active { background-color: var(--owl-status-active); color: var(--owl-bg-primary); }
.status-indicator.status-inactive { background-color: var(--owl-status-inactive); color: #888; }

/* Minerva Specifics */
.minerva-status { padding: 1rem; border-radius: var(--border-radius); text-align: center; border: 1px solid; }
.minerva-status.available { background-color: rgba(69, 196, 83, 0.1); border-color: var(--owl-status-active); }
.minerva-status.upcoming { background-color: rgba(var(--owl-accent-gold-rgb), 0.1); border-color: var(--owl-accent-gold); }
.minerva-countdown { display: flex; justify-content: space-around; margin-top: 0.75rem; }
.time-block span:first-child { font-family: var(--font-mono); font-size: 1.5rem; color: var(--owl-accent-gold); }
.time-block .time-label { font-size: 0.6rem; text-transform: uppercase; color: var(--owl-text-secondary); display: block; }

/* Enlistment Links (Community Hub) */
.pointer-link { display: block; text-align:center; transition: all 0.2s ease-out; background-color: var(--owl-bg-primary); border: 1px solid transparent; padding: 1rem; border-radius: var(--border-radius); text-decoration: none; margin-top: 0.75rem; }
.pointer-link:hover { transform: translateY(-3px); border-color: var(--owl-accent-gold); background-color: var(--owl-bg-tertiary); box-shadow: 0 4px 10px rgba(0,0,0,0.3); }
.pointer-link h3 { font-size: 1.1rem; margin: 0 0 0.25rem; color: var(--owl-text-primary); }
.pointer-link p { font-size: 0.8rem; color: var(--owl-text-secondary); margin: 0; }

/* Broadcasts & Twitter */
.twitter-grid { display: grid; grid-template-columns: 1fr; gap: var(--grid-gap); }
.twitter-fallback-grid { display: grid; grid-template-columns: 1fr; gap: 1rem; margin-top: 1rem; }
.twitter-fallback-card { display: flex; justify-content: space-between; align-items: center; text-decoration: none; padding: 1rem; background-color: var(--owl-bg-primary); border: 1px solid transparent; border-radius: var(--border-radius); transition: all 0.2s ease-out; }
.twitter-fallback-card:hover { transform: translateY(-2px); border-color: var(--owl-accent-gold); }
.fallback-link { font-family: var(--font-mono); font-size: 0.8rem; color: var(--owl-accent-gold); }


/* ---------------------------------- */
/*      5. UTILITIES & FOOTER         */
/* ---------------------------------- */
.btn-hero { font-family: var(--font-mono); padding: 0.75rem 1.5rem; text-transform: uppercase; transition: all 150ms ease-out; font-size: 0.9rem; border-radius: var(--border-radius); border: 1px solid; text-decoration: none; display: inline-block; }
.btn-hero:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(0,0,0,0.3); }
.btn-hero-gold { border-color: var(--owl-accent-gold); color: var(--owl-accent-gold); }
.btn-hero-gold:hover { background-color: var(--owl-accent-gold); color: var(--owl-bg-primary); }

.hidden { display: none !important; }
*:focus-visible { outline: 2px solid var(--owl-accent-gold) !important; outline-offset: 2px; }

#preloader { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background-color: var(--owl-bg-primary); display: flex; justify-content: center; align-items: center; z-index: 10000; transition: opacity 0.4s ease-out; }
#preloader .preloader-icon-spinner { width: 40px; height: 40px; border: 3px solid rgba(var(--owl-accent-gold-rgb), 0.2); border-left-color: var(--owl-accent-gold); border-radius: 50%; animation: spin-loader 0.9s infinite linear; }
@keyframes spin-loader { to { transform: rotate(360deg); } }

.animatable-panel { opacity: 0; transform: translateY(20px); transition: opacity 0.5s ease-out, transform 0.5s ease-out; }
.animatable-panel.is-visible { opacity: 1; transform: translateY(0); }

.site-footer { padding: 2rem 1rem; border-top: 1px solid var(--owl-border-color); text-align: center; background-color: #0A0A0A; margin-top: 3rem; }
.footer-container { max-width: var(--content-width); margin: auto; }
.footer-tagline { font-family: var(--font-heading); font-size: 1rem; margin: 0 0 1.5rem; }
.footer-terminal-line { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem; font-family: var(--font-mono); color: var(--owl-terminal-green); text-transform: uppercase; font-size: 0.8rem; margin-bottom: 1.5rem; }
.disclaimer { color: #777; font-size: 0.75rem; }


/* ---------------------------------- */
/*      6. RESPONSIVE FORTIFICATION   */
/* ---------------------------------- */
@media (min-width: 768px) {
    .twitter-grid, .twitter-fallback-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 767px) {
    .hidden-on-mobile { display: none !important; }
    .md-hidden { display: block !important; }

    .dashboard-header {
        flex-direction: column;
        text-align: center;
    }
    .hero-logo-image { align-self: center; }
}