/* =========================================
   1. VARIABLES & RESET
   ========================================= */
:root {
    --eb-red: #D9232E;
    --eb-black: #111111;
    --eb-gray: #f4f4f4;
    --text-color: #333;
    --white: #ffffff;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* =========================================
   2. UTILITIES
   ========================================= */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

.bg-light {
    background-color: var(--eb-gray);
}

.bg-dark {
    background-color: var(--eb-black);
    color: var(--white);
}

.text-white {
    color: var(--white);
}

.eb-red {
    color: var(--eb-red);
    font-weight: 800;
}

.eb-light {
    font-weight: 300;
}

/* =========================================
   3. BUTTONS
   ========================================= */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 600;
    transition: var(--transition);
    text-align: center;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background-color: var(--eb-red);
    color: var(--white);
    border: 2px solid var(--eb-red);
}

.btn-primary:hover {
    background-color: transparent;
    color: var(--eb-red);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
    margin-left: 10px;
}

.btn-outline:hover {
    background-color: var(--white);
    color: var(--eb-black);
}

.full-width {
    width: 100%;
}

/* =========================================
   4. NAVBAR
   ========================================= */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    height: 80px;
    display: flex;
    align-items: center;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-links a:hover {
    color: var(--eb-red);
}

.mobile-cta {
    display: none;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.hamburger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--eb-black);
}

/* =========================================
   5. HERO & VIMEO BACKGROUND
   ========================================= */
.hero {
    position: relative;
    height: 100svh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    text-align: center;
    overflow: hidden;
    margin-top: 0;
    background-color: #111;
}

/* Layer 1: The Fallback Image */
.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    background: url('assets/hero-fallback.jpg') center/cover no-repeat;
}

/* Layer 2: The Video (Sits on top of the fallback image if it loads) */
.video-background iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100vw;
    height: 56.25vw;
    /* 16:9 Aspect Ratio */
    min-height: 100vh;
    min-width: 177.77vh;
    transform: translate(-50%, -50%);
}

/* Layer 3: The Dark Overlay (Darkened from 0.4 to 0.7 for better readability) */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 2;
}

/* Layer 4: The Text and Buttons */
.hero-content {
    position: relative;
    z-index: 3;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    line-height: 1.1;
    font-weight: 700;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* =========================================
   6. GRID & SECTIONS
   ========================================= */
.two-col-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.box-gray {
    background: #ddd;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    color: #666;
}

.feature-list {
    margin-top: 20px;
    padding-left: 20px;
}

.feature-list li {
    margin-bottom: 10px;
    list-style-type: disc;
}

/* SocialBites Feature Boxes */
/* This forces BOTH the Advantage section and the Brands section into a perfect 3x2 grid on desktop */
.features-grid,
.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-box {
    background: #f9f9f9;
    padding: 30px;
    border-radius: 8px;
    border-top: 4px solid var(--eb-red);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.feature-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.feature-box h3 {
    margin-bottom: 15px;
    color: var(--eb-black);
    font-size: 1.25rem;
}

/* Brands Grid */
/*.brands-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px; margin-top: 40px; }*/
.brand-card {
    background: var(--white);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    text-align: center;
    transition: var(--transition);
}

.brand-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.brand-logo-place {
    height: 80px;
    background: #eee;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    border-radius: 4px;
}

.link-text {
    color: var(--eb-red);
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: 15px;
    display: inline-block;
}

/* Subtle Dot Pattern for the Brand Ecosystem Section */
#ecosystem {
    background-color: var(--eb-gray);
    /* Keeps the light gray base */
    background-image: radial-gradient(#cccccc 1px, transparent 1px);
    background-size: 20px 20px;
    /* Controls how far apart the dots are */
}


/* =========================================
   7. NEWSROOM & FORM
   ========================================= */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.news-item {
    background: #222;
    padding: 20px;
    border-radius: 8px;
}

.news-thumb {
    height: 150px;
    background: #444;
    margin-bottom: 15px;
    border-radius: 4px;
}
/* Forces the new image tags to act like background-cover images */
.news-thumb {
    overflow: hidden; /* Keeps the image from breaking out of the box */
    position: relative;
}

.news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* This is the magic rule that prevents stretching */
    display: block;
    transition: transform 0.3s ease; /* Optional: sets up a hover zoom effect */
}

/* Optional: Adds a subtle zoom effect when hovering over a news article */
.news-item:hover .news-thumb img {
    transform: scale(1.05);
}

.news-item h4 {
    margin-bottom: 10px;
}

.news-item a {
    color: var(--eb-red);
    font-size: 0.9rem;
    font-weight: 600;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-form input,
.contact-form select {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
}

.form-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 20px;
    font-size: 0.8rem;
}

.form-check input {
    width: auto;
    margin-top: 4px;
}

/* =========================================
   8. FOOTER & RESPONSIVE
   ========================================= */
footer {
    background: #111;
    color: #777;
    padding: 40px 0;
    text-align: center;
    font-size: 0.9rem;
    border-top: 1px solid #222;
}

.footer-links {
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.footer-links a:hover {
    color: var(--white);
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--white);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        text-align: center;
    }

    .nav-links.active {
        display: flex;
    }

    .header-btn {
        display: none;
    }

    .mobile-cta {
        display: block;
        margin-top: 20px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .two-col-grid,
    .contact-container {
        grid-template-columns: 1fr;
    }
}

/* =========================================
   9. SCROLL ANIMATIONS
   ========================================= */
.fade-in {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* =========================================
   10. LOGO TICKER & CTA BANNER
   ========================================= */

/* Logo Ticker */
.trusted-ticker-wrap {
    background: var(--white);
    padding: 40px 0 30px;
    border-bottom: 1px solid #eee;
    text-align: center;
    overflow: hidden;
}

.ticker-title {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #888;
    margin-bottom: 25px;
    font-weight: 600;
}

.ticker-container {
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.ticker-track {
    display: inline-flex;
    gap: 80px;
    align-items: center;
    padding-right: 80px;
    /* Changed from 30s to 60s to cut the speed in half */
    animation: scrollTicker 90s linear infinite;
}

.ticker-track img { 
    height: 40px; 
    width: auto; 
    max-width: 160px; /* NEW: This stops SVGs from stretching too wide */
    filter: grayscale(100%) opacity(50%); 
    transition: var(--transition); 
    object-fit: contain; 
}

.ticker-track img:hover {
    filter: grayscale(0%) opacity(100%);
}

/* Pause the ticker animation when the user hovers over it */
.ticker-container:hover .ticker-track {
    animation-play-state: paused;
}

@keyframes scrollTicker {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Mid-Page CTA */
.bg-red {
    background-color: var(--eb-red);
}

.text-center {
    text-align: center;
}

.cta-banner h2 {
    font-size: 2.2rem;
    margin-bottom: 15px;
}

.btn-outline-light {
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
    font-weight: 600;
    padding: 12px 30px;
    display: inline-block;
    border-radius: 4px;
    transition: var(--transition);
}

.btn-outline-light:hover {
    background-color: var(--white);
    color: var(--eb-red);
}

/* =========================================
   11. BACK TO TOP BUTTON
   ========================================= */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--eb-red, #cc0000);
    color: #ffffff;
    border: none;
    /* Changed to a pill shape instead of a circle */
    border-radius: 30px;
    /* Added horizontal padding for the text */
    padding: 0 24px;
    height: 50px;
    font-size: 1rem;
    font-weight: 800;
    /* Made the font bolder */
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    /* Adds perfect spacing between the arrow and the text */
    letter-spacing: 0.5px;
}

/* This class gets added by JavaScript when the user scrolls down */
.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* =========================================
   Brand Ecosystem Background Pattern (JPEG Toning)
   ========================================= */
#ecosystem {
    /* Set a standard light gray base for the whole section */
    background-color: #f8f9fa;

    /* NEW: We stack a 92% white overlay ON TOP OF the JPEG pattern */
    background-image:
        linear-gradient(rgba(248, 249, 250, 0.97), rgba(248, 249, 250, 0.97)),
        url('assets/your-pattern.jpg');
    /* Make sure this is .jpg now! */

    background-repeat: repeat;

    /* This ensures the image tiles at a nice, visible scale */
    background-size: 1600px;
}
/* Hero Text Enhancements */
.hero-content h1 {
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.hero-subtitle {
    max-width: 800px; /* Keeps the text from stretching too wide */
    margin: 0 auto; /* Centers it perfectly */
    line-height: 1.7; /* Adds breathing room between the lines */
    font-size: 1.1rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6); /* Forces the text to stand out from the bright background */
}

/* =========================================
   12. BUTTON ATTENTION ANIMATION
   ========================================= */

@keyframes attentionPop {
    0%, 80%, 100% { 
        transform: scale(1) translateY(0); 
    }
    85% { 
        transform: scale(1.05) translateY(-4px); 
    }
    90% { 
        transform: scale(1) translateY(0); 
    }
    95% { 
        transform: scale(1.02) translateY(-2px); 
    }
}

.btn-bounce {
    /* Runs the animation every 4 seconds indefinitely */
    animation: attentionPop 4s infinite; 
    /* Ensures smooth transitions when hovering */
    transition: transform 0.2s ease, background-color 0.3s ease; 
    display: inline-block;
}

/* Stops the animation immediately when the user hovers to click */
.btn-bounce:hover {
    animation: none; 
    transform: scale(1.05); /* Keeps it slightly enlarged on hover */
}
/* Mobile Responsiveness Tweaks */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.2rem; /* Shrinks the massive headline to fit beautifully */
        margin-bottom: 15px;
    }
    .hero-subtitle {
        font-size: 1rem; /* Adjusts paragraph for easy mobile reading */
    }
    .trusted-ticker-wrap {
        padding: 20px 0 15px; /* Tightens up the spacing on mobile */
    }
}