@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap');

:root {
    /* Sophisticated Color Palette */
    --primary: #002347;
    --primary-light: #003a75;
    --accent: #8dc63f;
    /* Lettuce Green */
    --accent-glow: rgba(141, 198, 63, 0.3);
    --secondary: #0056b3;
    --dark: #050a12;
    --text: #1a1a1a;
    --text-muted: #64748b;
    --bg-white: #ffffff;
    --bg-soft: #f8fafc;
    --border: rgba(0, 0, 0, 0.08);
    --glass-white: rgba(255, 255, 255, 0.8);
    --glass-dark: rgba(5, 10, 18, 0.8);

    /* Spacing & Borders */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 32px;

    /* Transitions */
    --transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text);
    background-color: var(--bg-white);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--primary);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* --- Layout Utilities --- */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 4rem;
}

.grid-2,
.grid-3,
.grid-4 {
    display: grid;
    gap: 3rem;
}

.grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

@media (max-width: 768px) {
    .flex-between {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
}

.flex-center {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

ul {
    list-style: none;
}

/* --- Navigation --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0.5rem 0;
    transition: var(--transition);
    background: transparent;
}

.header.scrolled {
    padding: 0.4rem 0;
    background: var(--glass-white);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 4rem;
}

.logo img {
    height: 180px;
    width: auto;
    transition: var(--transition);
}

.nav-menu {
    display: flex;
    gap: 1.6rem;
    align-items: center;
}

.nav-link {
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: white;
    /* Default for transparent header */
    position: relative;
    padding: 0.5rem 0;
    white-space: nowrap;
}

.header.scrolled .nav-link {
    color: var(--primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-item-dropdown {
    position: relative;
}

.nav-dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: white;
    min-width: 280px;
    padding: 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    border: 1px solid var(--border);
    display: grid;
    gap: 0.5rem;
}

.nav-item-dropdown:hover .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(10px);
}

.nav-dropdown a {
    padding: 0.8rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    transition: var(--transition);
    border-left: 2px solid transparent;
}

.nav-dropdown a:hover {
    background: var(--bg-soft);
    color: var(--accent);
    border-left: 2px solid var(--accent);
    padding-left: 1.5rem;
}

/* --- Language Selector --- */
.lang-selector {
    position: relative;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    color: white;
}

.header.scrolled .lang-selector {
    background: rgba(0, 0, 0, 0.04);
    color: var(--primary);
}

.lang-dropdown {
    position: absolute;
    top: 130%;
    right: 0;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    padding: 1rem;
    border: 1px solid var(--border);
}

.lang-selector:hover .lang-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    padding: 0.8rem 1rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 0.8rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--primary);
    transition: var(--transition);
}

.lang-option:hover {
    background: var(--bg-soft);
    color: var(--accent);
}

/* --- Consulting Card V2 (Services Page) --- */
.consulting-card-v2 {
    display: flex;
    gap: 3rem;
    align-items: flex-start;
    padding: 3.5rem;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    border: 1px solid var(--border);
}

.consulting-card-v2:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    border-color: var(--accent);
}

.card-icon-v2 {
    flex-shrink: 0;
    background: var(--bg-soft);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--accent);
    font-size: 2rem;
    transition: var(--transition);
}

.consulting-card-v2:hover .card-icon-v2 {
    background: var(--primary);
    color: white;
}

@media (max-width: 768px) {
    .consulting-card-v2 {
        flex-direction: column;
        gap: 1.5rem;
        padding: 2rem;
    }

    .card-icon-v2 {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
}

/* --- Virtual Assistant - HC --- */
.assistant-btn {
    position: fixed;
    bottom: 40px;
    left: 40px;
    z-index: 999;
    width: 60px;
    height: 60px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border: 2px solid var(--accent);
    transition: var(--transition);
}

.assistant-btn:hover {
    transform: scale(1.1) rotate(15deg);
}

.assistant-drawer {
    position: fixed;
    bottom: 110px;
    left: 40px;
    width: 380px;
    height: 600px;
    max-height: calc(100vh - 150px);
    background: white;
    border-radius: var(--radius-md);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(20px);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

@media (max-width: 768px) {
    .assistant-drawer {
        width: calc(100% - 40px);
        left: 20px;
        bottom: 110px;
        height: 70vh;
    }
}

@media (max-width: 480px) {
    .assistant-drawer {
        width: 100%;
        left: 0;
        bottom: 0;
        height: 80vh;
        border-radius: var(--radius-md) var(--radius-md) 0 0;
    }

    .assistant-btn {
        bottom: 20px;
        left: 20px;
    }
}

.assistant-drawer.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.assistant-header {
    background: var(--primary);
    padding: 1.5rem;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.assistant-body {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.assistant-footer {
    padding: 1rem;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 0.5rem;
}

.assistant-input {
    flex: 1;
    padding: 0.8rem 1.2rem;
    border-radius: 50px;
    border: 1px solid var(--border);
    outline: none;
    font-size: 0.9rem;
}

.assistant-options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 1rem;
    padding: 1rem 0;
}

.option-btn {
    background: white;
    border: 1px solid var(--accent);
    color: var(--primary);
    padding: 0.6rem 1rem;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.option-btn:hover {
    background: var(--accent);
    color: white;
    transform: translateY(-2px);
}

.footer-logo img {
    height: 180px;
    filter: brightness(0) invert(1);
    margin-bottom: 2.5rem;
    transition: var(--transition);
}

/* --- Shared Sections --- */
.hero-section {
    padding-top: 250px !important;
    padding-bottom: 150px !important;
}

@media (max-width: 1024px) {
    .hero-section {
        padding-top: 200px !important;
        padding-bottom: 120px !important;
    }
}

@media (max-width: 768px) {
    .hero-section {
        padding-top: 150px !important;
        padding-bottom: 100px !important;
    }
}

@media (max-width: 480px) {
    .hero-section {
        padding-top: 120px !important;
        padding-bottom: 80px !important;
    }
}

.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    background: var(--dark);
    color: white;
    overflow: hidden;
}

.hero-media-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.5;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(0, 35, 71, 0.4) 0%, rgba(5, 10, 18, 0.95) 100%);
    z-index: 2;
}

.hero .container {
    position: relative;
    z-index: 3;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 4rem;
}

.hero-content {
    max-width: 950px;
    margin: 0 auto;
    text-align: center;
}

.hero-headline {
    font-size: 5rem;
    font-weight: 800;
    margin-bottom: 2rem;
    line-height: 1.1;
    color: white;
}

.hero-subheadline {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 3.5rem;
    max-width: 750px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.8;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 2.8rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--accent);
    color: var(--primary);
}

.btn-primary:hover {
    background: white;
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 40px rgba(141, 198, 63, 0.4);
}

.btn-glass {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* --- Sections --- */
.section {
    padding: 150px 0;
}

.bg-soft {
    background: var(--bg-soft);
}

.section-tag {
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 4px;
    font-weight: 800;
    font-size: 0.85rem;
    display: block;
    margin-bottom: 1.5rem;
}

.section-title {
    font-size: 3.5rem;
    margin-bottom: 2.5rem;
}

/* --- Cards --- */
.card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.consulting-card {
    background: white;
    padding: 4rem 3rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.consulting-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition);
}

.consulting-card:hover {
    transform: translateY(-20px);
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

.consulting-card:hover::before {
    transform: scaleX(1);
}

.card-icon {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 2.5rem;
}

.card-title {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
}

.card-text {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

/* --- Floating Elements --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- Footer --- */
.footer {
    background: var(--dark);
    color: white;
    padding: 120px 0 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 6rem;
    margin-bottom: 80px;
}

.footer-title {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    position: relative;
    display: inline-block;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--accent);
}

.footer-link {
    display: block;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 1.2rem;
    font-size: 1rem;
}

.footer-link:hover {
    color: var(--accent);
    transform: translateX(10px);
}

.whatsapp-float {
    position: fixed;
    bottom: 40px;
    right: 40px;
    z-index: 100;
    width: 70px;
    height: 70px;
    background: #25d366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    box-shadow: 0 20px 40px rgba(37, 211, 102, 0.4);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    color: var(--primary);
    cursor: pointer;
    background: white;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    z-index: 1001;
}

.header:not(.scrolled) .mobile-toggle {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

/* --- Responsive Adjustments --- */

@media (max-width: 1200px) {
    .hero-headline {
        font-size: 4rem;
    }
}

@media (max-width: 1024px) {
    .header .container {
        padding: 0 2rem;
    }

    .hero-headline {
        font-size: 3.5rem;
    }

    .card-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 80px 0;
    }

    .section-title {
        font-size: 2.4rem;
    }

    .mobile-toggle {
        display: flex;
    }

    .logo img {
        height: 140px;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 340px;
        height: 100vh;
        background: rgba(6, 18, 34, 0.97);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 1.6rem;
        padding: 3rem 2rem;
        transition: 0.5s cubic-bezier(0.77, 0, 0.18, 1);
        z-index: 1001;
        display: flex !important;
        border-left: 1px solid rgba(255, 255, 255, 0.08);
        box-shadow: -20px 0 60px rgba(0, 0, 0, 0.4);
    }

    .nav-menu.active {
        right: 0;
    }

    /* Language selector inside mobile nav */
    .lang-selector-nav {
        display: flex !important;
        margin-top: 1rem;
        background: rgba(255, 255, 255, 0.1);
        color: white;
        border-radius: 50px;
        padding: 0.6rem 1.2rem;
        font-size: 1rem;
        align-self: center;
    }

    .lang-selector-nav .lang-dropdown {
        bottom: 130%;
        top: auto;
        left: 50%;
        right: auto;
        transform: translateX(-50%) translateY(10px);
        background: var(--dark);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    .lang-selector-nav:hover .lang-dropdown {
        transform: translateX(-50%) translateY(0);
    }

    .lang-selector-nav .lang-option {
        color: rgba(255, 255, 255, 0.85);
        font-size: 1rem;
        padding: 0.8rem 1.2rem;
    }

    .lang-selector-nav .lang-option:hover {
        background: rgba(255, 255, 255, 0.08);
        color: var(--accent);
    }

    .nav-link {
        color: white !important;
        font-size: 1.5rem;
        text-align: center;
        width: 100%;
    }

    .nav-dropdown {
        position: static;
        transform: none;
        opacity: 1;
        visibility: visible;
        background: rgba(255, 255, 255, 0.05);
        padding: 1rem;
        border: none;
        display: none;
        width: 100%;
    }

    .nav-dropdown a {
        color: rgba(255, 255, 255, 0.7);
        text-align: center;
        font-size: 1rem;
    }

    .nav-item-dropdown.active .nav-dropdown {
        display: flex;
        flex-direction: column;
    }

    .hero-headline {
        font-size: 3rem;
    }

    .hero-subheadline {
        font-size: 1.1rem;
        margin-bottom: 2.5rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .container {
        padding: 0 1.5rem !important;
    }

    .header-actions {
        display: none !important;
    }

    /* Mobile toggle sits neatly at top-right */
    .mobile-toggle {
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        font-size: 1.1rem;
    }

    /* Nav overlay backdrop (outside drawer) */
    .nav-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1000;
        display: none;
        backdrop-filter: blur(2px);
    }

    .nav-overlay.active {
        display: block;
    }

    /* Show the lang selector floating on mobile */
    .lang-selector-mobile {
        display: none !important;
    }


    /* Assistant Drawer Mobile */
    .assistant-drawer {
        left: 20px;
        right: 20px;
        width: calc(100% - 40px);
        bottom: 100px;
    }

    .assistant-btn {
        bottom: 20px;
        left: 20px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding-top: 80px;
        height: auto;
        min-height: 100vh;
    }

    .logo img {
        height: 55px;
    }

    .hero-headline {
        font-size: 2.5rem;
    }

    .btn {
        width: 100%;
        justify-content: center;
        padding: 1rem 1.5rem;
    }

    .section-title {
        font-size: 2.2rem;
    }

    .section {
        padding: 80px 0;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .footer {
        padding: 80px 0 40px;
    }

    /* Fix for inline grids */
    [style*="grid-template-columns: repeat(4, 1fr)"],
    [style*="grid-template-columns: repeat(2, 1fr)"],
    [style*="grid-template-columns: 2fr 1fr 1fr 1fr"],
    [style*="grid-template-columns: 1fr 1fr"],
    [style*="display: grid; grid-template-columns: 1fr 1.5fr"] {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    .newsletter-container {
        text-align: center;
        align-items: center !important;
    }

    .newsletter-container form {
        width: 100%;
        flex-direction: column;
    }

    [style*="display: flex; justify-content: space-between"],
    [style*="display: flex; gap: 2rem; align-items: center"] {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 1.5rem !important;
    }
}