/* --- CSS VARIABLES & RESET --- */
:root {
    /* Palette */
    --mv-blue: #006bab;
    --mv-red: #ed1b24;
    --mv-tertiary: #849483;
    --mv-accent: #C7F2A7;

    /* Neutrals */
    --text-dark: #101820;
    --text-body: #4a5568;
    --bg-light: #f7f9fa;
    --bg-white: #ffffff;
    --border-color: #e2e8f0;

    /* Spacing & Sizing */
    --container-width: 1200px;
    --header-height: 72px;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-pill: 50px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1 {
    font-size: 4.5rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

h2 {
    font-size: 2.5rem;
    font-weight: 700;
}

p {
    color: var(--text-body);
    font-size: 1.25rem;
    margin-bottom: 2rem;
}

a {
    text-decoration: none;
    transition: 0.3s ease;
}

ul {
    list-style: none;
}

/* --- UTILITIES --- */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.flex {
    display: flex;
}

.grid {
    display: grid;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.text-center {
    text-align: center;
}

.section-spacer {
    padding: 100px 0;
}

.section-spacer-sm {
    padding: 60px 0;
}

/* --- BUTTONS --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 36px;
    font-weight: 600;
    border-radius: var(--radius-pill);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
}

.btn-primary {
    background-color: var(--mv-blue);
    color: white;
    border: 2px solid var(--mv-blue);
}

.btn-primary:hover {
    background-color: #005a91;
    border-color: #005a91;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--mv-blue);
    border: 2px solid var(--mv-blue);
}

.btn-secondary:hover {
    background-color: #f0f7ff;
}

.arrow-circle {
    background: rgba(255, 255, 255, 0.2);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}



/* --- NEW FLOATING HEADER --- */
header {
    position: fixed;
    top: 24px;
    /* Increased from 20px to match concept2 */
    left: 50%;
    transform: translateX(-50%);
    width: 95%;
    max-width: var(--container-width);
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Glassmorphism Container */
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px 10px 28px;
    /* Specific padding from concept2 */
    background: rgba(255, 255, 255, 0.65);
    /* More translucent for better glass effect */
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    /* Low opacity border for "edge" light */
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

/* Scroll State */
header.scrolled {
    top: 12px;
}

header.scrolled .nav-container {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--mv-blue);
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.logo-text {
    width: 120px;
    height: auto;
}

.logo-icon {
    width: 60px;
    height: auto;
}

.logo-footer {
    width: 200px;
    height: auto;
}

.logo span {
    color: var(--mv-tertiary);
}

.nav-links {
    display: flex;
    gap: 32px;
    /* Adjusted to concept2 spacing */
    align-items: center;
}

.nav-links a {
    color: var(--text-dark);
    font-weight: 500;
    font-size: 0.95rem;
    text-decoration: none;
}

.nav-links a:hover {
    color: var(--mv-blue);
}

.nav-cta {
    background-color: var(--mv-red);
    color: white !important;
    padding: 10px 24px;
    border-radius: var(--radius-pill);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.nav-cta:hover {
    background-color: #c4131b;
}

/* --- RESPONSIVE HEADER STYLES --- */

/* 1. Desktop Layout (Default) */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 32px; /* Matches your original spacing */
}

.mobile-toggle {
    display: none; /* Hidden on desktop */
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.mobile-toggle .bar {
    width: 100%;
    height: 3px;
    background-color: var(--mv-blue);
    border-radius: 3px;
    transition: all 0.3s ease-in-out;
}

/* 2. Mobile/Tablet Layout */
@media (max-width: 968px) {
    .mobile-toggle {
        display: flex;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-top: 1px solid rgba(0, 0, 0, 0.05);
        border-bottom-left-radius: var(--radius-md);
        border-bottom-right-radius: var(--radius-md);
        padding: 24px;
        flex-direction: column;
        align-items: center;
        gap: 24px;
        box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
        
        /* Animation State: Hidden */
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Active State (Toggled via JS) */
    .nav-menu.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(12px); /* Pushes it down slightly for spacing */
    }

    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: 20px;
        width: 100%;
    }

    .nav-links a {
        font-size: 1.1rem;
        width: 100%;
        text-align: center;
        padding: 8px 0;
    }

    .nav-cta {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    /* Hamburger Animation to 'X' */
    .mobile-toggle.active .bar:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    
    .mobile-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-toggle.active .bar:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
}

/* --- FOOTER CTA --- */

.textured-footer-area {
    /* Sets the solid brand blue as the base */
    background-color: var(--mv-blue);
    /* Layers a subtle repeating 'ledger' grid on top */
    background-image: url("data:image/svg+xml,%3Csvg width='150' height='150' viewBox='0 0 150 150' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.08' fill-rule='evenodd'%3E%3C!-- Agricultural Doodle --%3E%3Cpath d='M20 20c2 5 8 5 10 0-2-5-8-5-10 0zM120 30c1 3 4 3 5 0-1-3-4-3-5 0z'/%3E%3C!-- Financial/Math Doodle --%3E%3Cpath d='M50 40h6v2h-6zM52 38v6h2v-6zM100 110h8v1h-8z'/%3E%3Ccircle cx='80' cy='20' r='2'/%3E%3Ccircle cx='30' cy='110' r='3'/%3E%3C!-- Abstract Shapes --%3E%3Cpath d='M10 80l3 6h-6zM130 90l4-4 4 4-4 4zM70 60l2 2-2 2-2-2z'/%3E%3Cpath d='M110 60q5 0 5 5t-5 5-5-5 5-5z' stroke='white' fill='none' stroke-width='0.5'/%3E%3Cpath d='M10 130a15 15 0 0 1 10-5' stroke='white' fill='none' stroke-width='1'/%3E%3C/g%3E%3C/svg%3E");
    padding-bottom: 60px;
    /* Space for the floating footer to breathe at the bottom */
}



.footer-cta {
    background-color: var(--mv-blue);
    color: white;
    text-align: center;
    padding: 100px 0;
}

.footer-cta h2 {
    margin-bottom: 32px;
    color: white;
}

.footer-cta .btn {
    background-color: var(--bg-white);
    color: var(--mv-blue);
    border: none;
}

/* --- FOOTER MAIN --- */

/* Container for the floating effect */
.footer-wrapper {
    background-color: var(--mv-blue);
    /* Same as footer-cta */
    padding: 0 0 40px 0;
    /* Creates the bottom "float" space */
}

footer {
    background-color: #0b1e2b;
    color: #8899a6;
    padding: 60px 0 30px;
    font-size: 0.9rem;
    /* Floating styles */
    width: 95%;
    max-width: var(--container-width);
    margin: 0 auto;
    border-radius: var(--radius-md);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-brand h5 {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 16px;
}

.footer-col h6 {
    color: white;
    margin-bottom: 20px;
    font-size: 1rem;
}

.footer-col li {
    margin-bottom: 12px;
}

.footer-col a {
    color: #8899a6;
}

.footer-col a:hover {
    color: var(--mv-accent);
}

.copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    display: flex;
    justify-content: space-between;
}

@media (max-width: 968px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}