/* ==========================================================================
   EmergiQuantum - Shared Navigation & Footer Stylesheet (styles.css)
   Centralized header/navbar, branding, and footer styles for all pages.
   Any future edits to the navbar and footer will reflect on all pages.
   ========================================================================== */

/* --- Core Theme Variables (Fallback / Global) --- */
:root {
    --beige: #F5F5DC;
    --teal-start: #008080;
    --teal-end: #00A0A0;
    --dark-charcoal: #1a1a1a;
    --off-white: #FAFAFA;
    --glass-border: rgba(255, 255, 255, 0.2);
    --glass-bg: rgba(245, 245, 220, 0.6);

    /* Typography System */
    --font-display: 'Crimson Pro', Georgia, serif;
    --font-heading: var(--font-display);
    --font-body: 'Plus Jakarta Sans', 'DM Sans', sans-serif;
}

/* ==========================================================================
   1. FLOATING CAPSULE / PILL NAVBAR
   ========================================================================== */
/* Top Header Area with Beige Page Background */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: var(--beige);
    padding: 14px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    transition: padding 0.3s ease, box-shadow 0.3s ease;
}

.main-header.scrolled {
    padding: 10px 0;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
}

/* Floating Capsule / Pill Navbar inside the Top Beige Area */
.main-header .navbar {
    width: 92%;
    max-width: 1260px;
    margin: 0 auto;
    padding: 0.45rem 0.85rem 0.45rem 1.4rem;
    border-radius: 9999px;
    background: #ffffff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.07), 0 1px 3px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Ensure Hero Sections on all pages start cleanly BELOW the top beige header part */
.hero-section,
.about-hero-section,
.solutions-hero-section {
    margin-top: 86px !important;
}

/* --- Brand Logo & Typography (Shared Gradient) --- */
.brand-logo-container {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background-color: #ffffff;
    border: none;
    padding: 5px 14px 5px 10px;
    border-radius: 8px;
    text-decoration: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    z-index: 1001;
}

.main-header .brand-logo-container {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
}

.main-header .brand-logo-container:hover {
    opacity: 0.9;
    transform: none !important;
    box-shadow: none !important;
}

.main-header .brand-logo-img {
    height: 38px;
    width: 38px;
    object-fit: contain;
    display: block;
}

.brand-logo-text {
    font-family: var(--font-body);
    font-size: 1.42rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
    user-select: none;
    display: inline-flex;
    align-items: center;
    background: radial-gradient(circle at 15% 45%, #ff2a8d 0%, #90059e 28%, #161467 55%, #0284c7 80%, #00f0ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.main-header .brand-logo-text {
    font-family: var(--font-body);
    font-size: 1.38rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
    user-select: none;
    display: inline-flex;
    align-items: center;
}

.brand-emergi,
.brand-logo-text .brand-emergi {
    background: radial-gradient(circle at 25% 35%, #ff2a8d 0%, #a805b5 55%, #161467 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-quantum,
.brand-logo-text .brand-quantum {
    background: radial-gradient(circle at 75% 35%, #00f0ff 0%, #0284c7 45%, #161467 95%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Navigation Links --- */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 2.2rem;
}

.nav-link {
    text-decoration: none;
    color: #334155;
    font-family: var(--font-body);
    font-weight: 600;
    position: relative;
    padding: 6px 0;
    font-size: 0.98rem;
    transition: color 0.25s ease;
}

.nav-link:hover {
    color: var(--teal-start);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 2.5px;
    background: var(--teal-start);
    border-radius: 2px;
    transition: width 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link.active {
    color: var(--teal-start);
}

/* --- Contact Us Pill CTA Button --- */
.nav-contact-btn {
    background: var(--teal-start);
    color: #ffffff !important;
    padding: 9px 22px;
    border-radius: 9999px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0, 128, 128, 0.28);
    transition: all 0.25s ease;
    border: none;
    white-space: nowrap;
}

.nav-contact-btn:hover {
    background: #006666;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(0, 128, 128, 0.38);
    color: #ffffff !important;
}

.nav-contact-btn i {
    font-size: 0.82rem;
    transition: transform 0.25s ease;
}

.nav-contact-btn:hover i {
    transform: translateX(3px);
}

.nav-cta-mobile {
    display: none;
}

/* --- Mobile Hamburger Toggle --- */
.nav-toggle {
    display: none;
    cursor: pointer;
    background: transparent;
    border: 0;
    padding: 0.5em;
    z-index: 1001;
}

.hamburger {
    display: block;
    position: relative;
    width: 25px;
    height: 2px;
    background: var(--dark-charcoal);
    transition: transform 0.3s ease-in-out, background-color 0.3s ease-in-out;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--dark-charcoal);
    transition: transform 0.3s ease-in-out, top 0.3s ease-in-out;
}

.hamburger::before { top: -8px; }
.hamburger::after { top: 8px; }

.nav-open .hamburger {
    background-color: transparent;
}

.nav-open .hamburger::before {
    top: 0;
    transform: rotate(45deg);
}

.nav-open .hamburger::after {
    top: 0;
    transform: rotate(-45deg);
}


/* ==========================================================================
   2. UNIFIED 4-COLUMN FOOTER
   ========================================================================== */
.main-footer {
    background-color: #e0e0c8;
    padding: 1.5rem 0 1rem;
    border-top: 1px solid var(--glass-border);
}

.footer-brand-container {
    display: inline-flex !important;
    align-self: flex-start !important;
    width: fit-content !important;
    max-width: fit-content !important;
    padding: 0 5px 0 0 !important;
    gap: 10px;
    margin-bottom: 0.25rem;
    align-items: center;
    border-radius: 10px;
    background-color: #ffffff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.footer-brand-container .brand-logo-img {
    height: 48px;
    width: 48px;
    padding: 5px !important;
    box-sizing: border-box;
    margin: 0 !important;
    flex-shrink: 0;
    object-fit: contain;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

.footer-brand-container .brand-logo-text {
    font-family: var(--font-body);
    font-size: 1.6rem;
    font-weight: 800;
    padding: 0 !important;
    margin: 0 !important;
    white-space: nowrap;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1fr 1.15fr;
    gap: 1.5rem;
    align-items: start;
}

.footer-brand-col {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
}

.footer-brand-desc {
    color: #3b4554;
    font-size: 0.98rem;
    line-height: 1.6;
    padding: 2px 2px;
    margin: 0;
    text-align: left;
}

.footer-social-row {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-top: 0.25rem;
    flex-wrap: wrap;
}

.footer-social-row .social-icons {
    display: flex;
    gap: 0.55rem;
    flex-shrink: 0;
}

.social-icons {
    display: flex;
    gap: 0.55rem;
}

.social-icons a {
    font-size: 1.05rem;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--dark-charcoal);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.04);
    transition: all 0.25s ease;
    text-decoration: none;
}

.social-icons a:hover {
    color: #ffffff;
    background: linear-gradient(135deg, #ff2a8d, #00f0ff);
    transform: translateY(-2px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}

.footer-copyright {
    color: #475569;
    font-size: 0.82rem;
    font-weight: 500;
    margin: 0;
    line-height: 1.35;
}

.footer-column h4 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.85rem;
    color: #0c3672;
    letter-spacing: -0.01em;
    position: relative;
    padding-bottom: 0.35rem;
}

.footer-column h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 26px;
    height: 2px;
    background: radial-gradient(circle, #ff2a8d, #00f0ff);
    border-radius: 2px;
}

.footer-links-list {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.footer-column a {
    color: #334155;
    text-decoration: none;
    margin-bottom: 0;
    padding: 1px 0;
    display: inline-flex;
    align-items: center;
    font-size: 0.95rem;
    line-height: 1.35;
    transition: color 0.25s ease, transform 0.25s ease;
}

.footer-column a:hover {
    color: #0b5a81;
    transform: translateX(3px);
}

.footer-contact-list {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 0;
    color: #334155;
    font-size: 0.95rem;
    line-height: 1.4;
}

.footer-contact-item i {
    color: #0b5a81;
    margin-top: 3px;
    font-size: 1.05rem;
    flex-shrink: 0;
}

.footer-contact-item a {
    color: #334155;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-contact-item a:hover {
    color: #0b5a81;
}

.footer-bottom {
    display: none;
}


/* ==========================================================================
   3. RESPONSIVE MEDIA QUERIES (NAVBAR & FOOTER)
   ========================================================================== */
@media (max-width: 1024px) {
    .main-header {
        padding: 10px 0;
    }

    .main-header .navbar {
        width: 94%;
        padding: 0.4rem 0.8rem 0.4rem 1rem;
    }

    .hero-section,
    .about-hero-section,
    .solutions-hero-section {
        margin-top: 76px !important;
    }

    .nav-toggle {
        display: block;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: 100%;
        background-color: var(--beige);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        transform: translateX(100%);
        transition: transform 350ms ease-out;
        z-index: 1000;
    }

    .nav-menu.active {
        transform: translateX(0);
    }

    .nav-link {
        color: var(--dark-charcoal);
        font-size: 1.4rem;
    }

    .nav-link::after {
        background: linear-gradient(45deg, var(--teal-start), var(--teal-end));
    }

    .nav-cta {
        display: none;
    }

    .nav-cta-mobile {
        display: inline-block;
        margin-top: 1rem;
    }
}

@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem 1.25rem;
    }
}

@media (max-width: 600px) {
    .main-footer {
        padding: 1.25rem 0 0.85rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
        text-align: center;
    }

    .footer-brand-col {
        align-items: center;
    }

    .footer-brand-container {
        align-self: center !important;
    }

    .footer-brand-desc {
        text-align: center;
    }

    .footer-social-row {
        justify-content: center;
        text-align: center;
        gap: 0.65rem;
    }

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

    .footer-column h4::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-links-list a {
        justify-content: center;
    }

    .footer-contact-item {
        justify-content: center;
    }

    .footer-brand-col .social-icons,
    .social-icons {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .main-header {
        padding: 8px 0;
    }

    .main-header .navbar {
        width: 95%;
        padding: 0.35rem 0.75rem 0.35rem 0.85rem;
    }

    .hero-section,
    .about-hero-section,
    .solutions-hero-section {
        margin-top: 68px !important;
    }

    .main-header .brand-logo-img {
        height: 32px;
        width: 32px;
    }

    .main-header .brand-logo-text {
        font-size: 1.15rem;
    }

    .footer-social-row {
        flex-direction: column;
        align-items: center;
        gap: 0.45rem;
    }

    .footer-copyright {
        font-size: 0.78rem;
    }
}


/* ==========================================================================
   4. HERO SECTION & BACKGROUND VIDEO STYLING (UNIFIED ACROSS ALL PAGES)
   ========================================================================== */
.hero-section,
.about-hero-section,
.solutions-hero-section {
    margin-top: 86px !important;
    height: 72vh;
    min-height: 500px;
    max-height: 620px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 50px var(--spacing-sm);
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    background: #09151e;
}

.hero-bg-video,
.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        rgba(9, 21, 30, 0.94) 0%, 
        rgba(9, 21, 30, 0.84) 40%, 
        rgba(9, 21, 30, 0.45) 65%, 
        rgba(9, 21, 30, 0.12) 85%,
        rgba(9, 21, 30, 0.22) 100%
    );
    z-index: 1;
}

.hero-container,
.hero-content.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: left;
    max-width: 680px;
    width: 100%;
}

.hero-content h1,
.about-hero-section h1,
.solutions-hero-section h1,
.hero-section h1 {
    font-family: var(--font-heading);
    font-size: clamp(2.3rem, 3.8vw, 3.5rem); 
    font-weight: 700;
    line-height: 1.18;
    margin-bottom: 1.1rem;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
    letter-spacing: -0.015em;
    text-align: left;
}

.hero-content .tagline,
.hero-content h2,
.hero-content p {
    font-family: var(--font-body);
    font-size: clamp(1rem, 1.25vw, 1.18rem);
    font-weight: 400;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.88);
    margin: 0 0 1.5rem 0;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
    max-width: 620px;
    text-align: left;
}

/* Text Reveal Animation */
.text-reveal > *,
.hero-text-reveal > * {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}
.text-reveal > *:nth-child(1), .hero-text-reveal > *:nth-child(1) { transition-delay: 0.1s; }
.text-reveal > *:nth-child(2), .hero-text-reveal > *:nth-child(2) { transition-delay: 0.25s; }
.text-reveal > *:nth-child(3), .hero-text-reveal > *:nth-child(3) { transition-delay: 0.45s; }
.text-reveal > *:nth-child(4), .hero-text-reveal > *:nth-child(4) { transition-delay: 0.65s; }
.text-reveal > *:nth-child(5), .hero-text-reveal > *:nth-child(5) { transition-delay: 0.85s; }

.text-reveal.visible > *,
.hero-text-reveal.visible > * {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 992px) {
    .hero-section,
    .about-hero-section,
    .solutions-hero-section {
        height: auto;
        min-height: 500px;
        padding: 50px var(--spacing-sm);
    }
    .hero-overlay {
        background: linear-gradient(90deg, 
            rgba(9, 21, 30, 0.96) 0%, 
            rgba(9, 21, 30, 0.88) 55%, 
            rgba(9, 21, 30, 0.65) 100%
        );
    }
    .hero-content {
        max-width: 100%;
        text-align: left;
    }
    .hero-content h2,
    .hero-content .tagline,
    .hero-content p {
        margin-left: 0;
        margin-right: 0;
    }
}

@media (max-width: 768px) {
    .hero-section,
    .about-hero-section,
    .solutions-hero-section {
        padding: 40px var(--spacing-sm);
    }
}

@media (max-width: 480px) {
    .hero-content h1,
    .about-hero-section h1,
    .solutions-hero-section h1,
    .hero-section h1 {
        font-size: 1.95rem;
    }
}


.hero-cyan-accent,
.hero-highlight {
    background: linear-gradient(135deg, #00f0ff 0%, #00c4cc 50%, #00a0a0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    color: #00c4cc;
    font-weight: 700;
    display: inline;
}


/* ==========================================================================
   5. COMPACT SECTION SPACING (REDUCED BY 70%)
   ========================================================================== */
.content-section {
    padding: 1.15rem 0 !important;
}

.cta-section {
    padding: 1.15rem 0 !important;
}

.section-title {
    margin-bottom: 0.85rem !important;
    padding-bottom: 0.6rem !important;
}
