/* Global Vars */
:root {
    --primary-color: #0A192F;
    /* Deep Navy */
    --secondary-color: #FF6B00;
    /* Vivid Orange */
    --accent-color: #172a45;
    /* Lighter Navy for cards */
    --text-light: #ccd6f6;
    --text-white: #ffffff;
    --text-dim: #8892b0;
    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Inter', sans-serif;
    --transition: all 0.3s ease;

    /* Brand Colors */
    --brand-vweb-blue: #0C4678;
    --brand-tech-orange: #F26726;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--primary-color);
    color: var(--text-light);
    line-height: 1.6;
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
}

body.no-scroll {
    overflow: hidden;
    position: fixed;
    width: 100%;
    height: 100%;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography Helpers */
h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    color: var(--text-white);
    margin-bottom: 20px;
}

.highlight {
    color: var(--secondary-color);
}

.highlight-text {
    color: var(--secondary-color);
}

.highlight-orange {
    color: var(--secondary-color);
}

.brand-vweb {
    color: var(--brand-vweb-blue);
    font-weight: 700;
}

.brand-tech {
    color: var(--brand-tech-orange);
    font-weight: 700;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 5px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-heading);
    text-decoration: none;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--secondary-color);
    color: var(--text-white);
    border: 2px solid var(--secondary-color);
}

.btn-primary:hover {
    background-color: transparent;
    color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 0, 0.2);
}

.btn-secondary {
    background-color: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
    margin-left: 15px;
}

.btn-secondary:hover {
    background-color: rgba(255, 107, 0, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 0, 0.1);
}

/* Header */
.header {
    height: 80px;
    background-color: rgba(10, 25, 47, 0.95);
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
}

/* Ensure header has high z-index and proper background on mobile */
@media (max-width: 768px) {
    .header {
        height: 70px;
        /* Reduced specific height for mobile */
        padding: 0 10px;
    }
}

.header-container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 50px;
    width: auto;
    object-fit: contain;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-list li a {
    font-size: 0.95rem;
    font-weight: 500;
}

.nav-list li a:hover {
    color: var(--secondary-color);
}

.btn-nav {
    border: 1px solid var(--secondary-color);
    padding: 8px 20px;
    border-radius: 4px;
    color: var(--secondary-color) !important;
}

.btn-nav:hover {
    background-color: rgba(255, 107, 0, 0.1);
}

.menu-close-btn {
    display: none;
}

.mobile-menu-icon {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-white);
}

/* Hero Section */
.hero {
    height: 600px;
    min-height: 600px;
    padding-top: 5%;
    display: flex;
    align-items: center;
    position: relative;
    /* Subtle Grid Background with Gradient */
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.95), rgba(17, 34, 64, 0.95)),
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 100% 100%, 50px 50px, 50px 50px;
    animation: backgroundShift 30s ease-in-out infinite alternate;
}

@media (max-width: 768px) {
    .hero {
        height: auto;
        min-height: auto;
        /* Ensure full height but flexible */
        padding-top: 100px;
        /* Space for fixed header */
        padding-bottom: 40px;
        align-items: flex-start;
        /* Align to top */
    }
}

@keyframes backgroundShift {
    0% {
        background-position: 0% 0%;
    }

    100% {
        background-position: 10% 10%;
    }
}

.hero-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 50px;
    align-items: center;
}

@media (max-width: 768px) {
    .hero-container {
        display: flex;
        flex-direction: column;
        gap: 30px;
    }

    .hero-content {
        order: 1;
        /* Content first */
        text-align: center;
        margin-top: 20px;
    }

    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
        margin-left: 0;
        /* Remove margin from secondary btn */
    }

    .hero-visual {
        display: none;
        /* Remove residual space */
    }
}

.hero-content h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 25px;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-dim);
    margin-bottom: 40px;
    max-width: 540px;
}

.badge {
    color: var(--secondary-color);
    font-family: var(--font-heading);
    font-size: 0.9rem;
    margin-bottom: 20px;
    display: block;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Hero Visual Animation Area */
.hero-visual {
    position: relative;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.floating-card {
    background: var(--accent-color);
    max-width: 260px;
    width: max-content;
    white-space: nowrap;
    padding: 20px 30px;
    border-radius: 12px;
    position: absolute;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px soli d rgba(255, 255, 255, 0.05);
    display: inline-flex;
    align-items: center;
    gap: 15px;
    font-weight: 600;
    color: var(--text-white);
    animation: float 6s ease-in-out infinite;
    z-index: 2;
}

/* Carousel Slots */
.balloon-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.balloon-slot {
    position: absolute;
    transition: all 0.5s ease-in-out;
    /* Ensure styles from floating-card apply if we use that class, 
       but we will inject floating-card inside or add the class. 
       Let's assume the JS adds "floating-card" class to this div 
       OR creates a child. The plan said "Each slot will be empty initially". 
       Let's style the child .floating-card to be relative. */
    z-index: 2;
}

/* Force floating-card to be relative inside the slot if needed, 
   or just let the slot handle positioning. */
.balloon-slot .floating-card {
    position: relative;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    margin: 0;
    /* Keep animation */
    animation: float 6s ease-in-out infinite;
}

/* Slot Positions Handled by JS */
.slot-1,
.slot-2,
.slot-3 {
    top: 50%;
    left: 50%;
    right: auto;
    bottom: auto;
    transform: translate(-50%, -50%);
    position: absolute;
}

/* Animation Classes for JS */
.fade-out-up {
    opacity: 0;
    transform: translateY(-20px);
}

.fade-in-up {
    opacity: 1;
    transform: translateY(0);
}

/* Specific Colors helper classes if not inline */
.text-blue {
    color: #4285F4;
}

.text-orange {
    color: var(--secondary-color);
}

.text-teal {
    color: #64FFDA;
}

.text-gold {
    color: #FFD700;
}

/* Responsive adjustments for balloons */
@media (max-width: 768px) {
    .floating-card {
        padding: 8px 12px;
        font-size: 0.75rem;
        z-index: 5;
    }

    .floating-card i {
        font-size: 1rem;
    }

    /* Reposition for mobile handled by JS */

}

.glow-effect {
    width: 300px;
    height: 300px;
    background: var(--secondary-color);
    filter: blur(150px);
    opacity: 0.15;
    border-radius: 50%;
    position: absolute;
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* Services Grid */
.services {
    padding: 60px 0;
    background-color: #0d213a;
}

.services h2 {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2.5rem;
    color: #fff;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.services h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: #FF6B00;
    margin: 10px auto 0;
    border-radius: 2px;
}

.section-header p {
    text-align: center;
    color: var(--text-dim);
    margin-top: -30px;
    margin-bottom: 30px;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.cards-grid>h3 {
    margin-top: 30px !important;
    margin-bottom: 15px !important;
    font-size: 1.2rem;
    opacity: 0.9;
}

.card {
    background: #172a45;
    padding: 30px 25px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    text-align: left;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.4s ease-out;
    position: relative;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 107, 0, 0.3);
}

.card-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    font-size: 2.5rem;
    color: #FF6B00;
    background: transparent;
}

.card:hover .card-icon i {
    transform: scale(1.1);
    transition: transform 0.3s ease;
}

.card h3 {
    color: #cbd6f6;
    margin-bottom: 12px;
    font-size: 1.35rem;
    font-weight: 600;
}

.card p {
    color: #8892b0;
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 25px;
}

.card-action {
    margin-top: auto;
    color: var(--secondary-color);
    font-weight: bold;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.3s;
}

.card:hover .card-action {
    gap: 12px;
}

/* About Section */
.about {
    padding: 100px 0;
    background-color: #0d203d;
}

.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
}

.about-text p {
    color: var(--text-dim);
    margin-bottom: 20px;
}

.check-list {
    margin-top: 30px;
}

.check-list li {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    font-weight: 500;
}

.check-list li i {
    color: var(--secondary-color);
    margin-right: 15px;
    font-size: 1.2rem;
}

.about-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.stat-item {
    background-color: var(--primary-color);
    padding: 40px 20px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.stat-number {
    display: block;
    font-size: 3rem;
    font-weight: 800;
    color: var(--secondary-color);
    font-family: var(--font-heading);
    margin-bottom: 10px;
}

.stat-label {
    color: var(--text-light);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Contact Section */
.contact {
    padding: 100px 0;
    text-align: center;
}

.contact-box {
    max-width: 600px;
    margin: 0 auto;
}

.contact h2 {
    font-size: 2.5rem;
}

.contact p {
    color: var(--text-dim);
    margin-bottom: 40px;
}

.contact-form {
    background-color: var(--accent-color);
    padding: 40px;
    border-radius: 10px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    background-color: var(--primary-color);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-white);
    border-radius: 5px;
    font-family: var(--font-body);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(255, 107, 0, 0.1);
    transition: all 0.3s ease;
}

.full-width {
    width: 100%;
}

/* Footer */
.footer {
    background-color: var(--accent-color);
    padding: 60px 0 20px;
    font-size: 0.9rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-links h4,
.footer-social h4 {
    color: var(--text-white);
    margin-bottom: 20px;
    font-family: var(--font-heading);
}

.footer-links ul li {
    margin-bottom: 10px;
}

.footer-links ul li a {
    color: var(--text-dim);
}

.footer-links ul li a:hover {
    color: var(--secondary-color);
}

.social-icons {
    display: flex;
    gap: 20px;
}

.social-icons a {
    color: var(--text-light);
    font-size: 1.5rem;
}

.social-icons a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-dim);
    font-size: 0.8rem;
}

/* MODAL STYLES */
.modal {
    display: none;
    /* Hidden by default */
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    opacity: 1;
}

.modal-content {
    background-color: #0d213a;
    margin: auto;
    padding: 0;
    border: 1px solid #FF6B00;
    width: 90%;
    max-width: 700px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4);
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal-content.show {
    transform: scale(1);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: 0.2s;
}

.close-modal:hover {
    color: #FF6B00;
}

.modal-header {
    padding: 5px 40px 10px;
    display: flex;
    align-items: center;
    gap: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.modal-icon {
    font-size: 2.5rem;
    color: var(--secondary-color);
}

/* Body Scroll Lock */
body.modal-open {
    overflow: hidden;
}

.modal-body {
    padding: 30px 40px;
    max-height: 910px;
    overflow-y: auto;
    padding-right: 8px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

/* Custom Scrollbar for Webkit */
.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track {
    background: transparent;
}

.modal-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    transition: background 0.3s ease;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.4);
}

.modal-desc {
    margin: 0px 10px 0px 0px;
    color: var(--text-light);
    font-size: 1.05rem;
    line-height: 1.7;
}

.modal-desc h4 {
    color: var(--text-white);
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.modal-desc ul {
    list-style: none;
    margin-left: 0;
}

.modal-desc ul li {
    margin-bottom: 10px;
    position: relative;
    padding-left: 20px;
}

.modal-desc ul li::before {
    content: '•';
    color: var(--secondary-color);
    position: absolute;
    left: 0;
    font-weight: bold;
}

.modal-footer {
    padding: 5px 10px 0px;
    text-align: right;
}

/* Responsive */
@media (max-width: 968px) {
    .hero-container {
        /* grid-template-columns overflow handled by flex above, but keep specific override if needed */
        display: flex;
        flex-direction: column;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 3rem;
    }

    .hero-content p {
        margin: 0 auto 40px auto;
    }

    .hero-visual {
        height: 300px;
        order: 2;
    }

    .about-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    body {
        overflow-x: hidden;
        /* Prevent horizontal scroll */
        position: relative;
        /* Ensure context */
    }

    .hero {
        height: auto;
        padding-top: 100px;
        padding-bottom: 50px;
        align-items: flex-start;
        overflow-x: hidden;
        /* Double safety */
    }

    .hero-container {
        display: flex;
        flex-direction: column;
        gap: 30px;
        max-width: 100vw;
        /* Strict width */
        overflow-x: hidden;
    }

    .hero-content {
        order: 1;
        text-align: center;
        margin-top: 20px;
        width: 100%;
        padding: 0 15px;
        /* Prevent text touching edges */
    }

    /* 
    1. REMOVE BALLOONS ON MOBILE 
    As requested: "Remover completamente os balões flutuantes no mobile." 
    */
    .hero-visual,
    .balloon-container,
    .balloon-slot {
        display: none !important;
    }

    /* 
    Alternative: If user decides they want *something* visual, we can show a static image,
    but prompt said "Remover completamente". The space is now free.
    */

    /* Ensure Nav List doesn't span full width */
    .nav-list {
        position: fixed;
        top: 0;
        right: -100%;
        background-color: rgba(10, 25, 47, 0.98);
        /* Higher opacity */
        backdrop-filter: blur(15px);
        height: 100vh;
        width: 80%;
        /* 80% Width */
        max-width: 350px;
        flex-direction: column;
        justify-content: flex-start;
        /* Start from top */
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
        z-index: 9999;
        /* Higher than everything else */
        border-left: 1px solid rgba(255, 255, 255, 0.05);
        padding-top: 80px;
        /* More space for close button */
    }

    /* DDI List Fix (Mobile Z-Index) */
    .iti__country-list {
        z-index: 10000 !important;
        background-color: var(--primary-color);
        border: 1px solid var(--secondary-color);
        color: var(--text-white);
        max-width: 90vw;
        white-space: normal;
    }

    /* Navigation Close Button (Mobile Only) */
    .menu-close-btn {
        display: block;
        position: absolute;
        top: 20px;
        right: 20px;
        font-size: 1.8rem;
        color: var(--text-white);
        cursor: pointer;
        z-index: 1001;
    }

    .menu-close-btn:hover {
        color: var(--secondary-color);
    }

    /* Adjust width to ~80% */
    .nav-list {
        width: 80%;
        max-width: 350px;
    }

    .nav-list.active {
        right: 0;
    }

    .mobile-menu-icon {
        display: block;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-brand p {
        margin: 20px auto;
    }

    .social-icons {
        justify-content: center;
    }

    .modal-content {
        width: 95%;
        margin: 10% auto;
    }

    .modal-header {
        flex-direction: column;
        text-align: center;
    }

    .modal-body {
        padding: 20px;
    }
}

/* Dashboard Visuals Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 15px;
}

.dashboard-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease;
}

.dashboard-item:hover {
    transform: scale(1.02);
    border-color: var(--secondary-color);
}

.dashboard-item img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.dashboard-item span {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(10, 25, 47, 0.85);
    color: #fff;
    padding: 8px 10px;
    font-size: 0.85rem;
    text-align: center;
    backdrop-filter: blur(2px);
}

@media (max-width: 600px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}