/* ─── Variáveis e Reset ─────────────────────────────────────────────────── */
:root {
    --primary: #00A3B5;
    --secondary: #FFB81C;
    --navy: #003B5C;
    --text: #1a1a1a;
    --bg: #ffffff;
    --bg-alt: #f8f9fa;
    --border: #e1e4e8;
    --shadow: 0 4px 20px rgba(0,0,0,0.08);
}

[data-theme="dark"] {
    --text: #f0f0f0;
    --bg: #111827;
    --bg-alt: #1f2937;
    --border: #374151;
    --shadow: 0 4px 20px rgba(0,0,0,0.4);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    transition: background 0.3s, color 0.3s;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ─── Topbar ────────────────────────────────────────────────────────────── */
.topbar {
    background: var(--navy);
    color: white;
    padding: 10px 0;
    font-size: 0.9rem;
}

.topbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar-contacts {
    display: flex;
    gap: 25px;
}

.topbar-contacts a {
    color: rgba(255,255,255,0.9);
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    transition: color 0.2s;
}

.topbar-contacts a:hover {
    color: var(--secondary);
}

/* ─── Header / Nav ──────────────────────────────────────────────────────── */
.header {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 0;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    flex-shrink: 0;
}

/* Logo principal no header */
.logo-img {
    height: 58px;
    width: auto;
    display: block;
    object-fit: contain;
    /* Fundo branco arredondado para garantir legibilidade no dark mode */
    background: white;
    border-radius: 10px;
    padding: 4px 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
    transition: box-shadow 0.2s, transform 0.2s;
}

.logo-img:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.16);
    transform: translateY(-1px);
}

/* Logo no footer */
.footer-logo {
    height: 54px;
    width: auto;
    display: block;
    object-fit: contain;
    background: white;
    border-radius: 10px;
    padding: 4px 8px;
    margin-bottom: 16px;
}

.nav-menu {
    display: flex;
    gap: 30px;
    list-style: none;
    align-items: center;
}

.nav-link {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
}

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


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

/* ─── Seletor de Idioma ─────────────────────────────────────────────────── */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 3px;
    background: var(--bg-alt);
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 9px;
    background: none;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text);
    opacity: 0.55;
    transition: opacity 0.2s, background 0.2s;
    white-space: nowrap;
}

.lang-btn:hover {
    opacity: 0.85;
    background: var(--bg);
}

.lang-btn.active {
    opacity: 1;
    background: var(--bg);
    box-shadow: 0 1px 4px rgba(0,0,0,0.10);
    color: var(--primary);
}

.flag-img {
    border-radius: 2px;
    display: block;
    flex-shrink: 0;
}

.btn-theme {
    background: none;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 7px 10px;
    cursor: pointer;
    color: var(--text);
    font-size: 1rem;
    transition: background 0.2s;
}

.btn-theme:hover {
    background: var(--bg-alt);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text);
    padding: 5px;
}

/* ─── Botões ────────────────────────────────────────────────────────────── */
.btn-primary,
.btn-secondary {
    padding: 12px 28px;
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    opacity: 0.88;
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.12);
}

.btn-lg {
    padding: 15px 38px;
    font-size: 1rem;
}

.btn-sm {
    padding: 7px 18px;
    font-size: 0.85rem;
}

/* ─── Hero ──────────────────────────────────────────────────────────────── */
.hero {
    position: relative;
    height: 90vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-slider {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.2s ease;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-slide-bg {
    width: 100%;
    height: 100%;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 59, 92, 0.92) 0%, rgba(0, 163, 181, 0.72) 100%);
    z-index: -1;
}

.hero-content {
    color: white;
    width: 100%;
    max-width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto auto;
    column-gap: 60px;
    align-items: start;
}

.hero-tag {
    grid-column: 1 / -1;
    display: inline-block;
    justify-self: start;
    background: rgba(255,184,28,0.2);
    border: 1px solid var(--secondary);
    color: var(--secondary);
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.hero-title {
    grid-column: 1 / 2;
    font-size: 3.8rem;
    font-weight: 800;
    line-height: 1.12;
    margin-bottom: 0;
}

.gradient-text {
    background: linear-gradient(135deg, var(--secondary) 0%, #FF8C42 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    grid-column: 2 / 3;
    grid-row: 2 / 4;
    font-size: 1.15rem;
    opacity: 0.9;
    margin-bottom: 0;
    align-self: center;
    padding-top: 10px;
}

.hero-ctas {
    grid-column: 1 / 2;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 30px;
}

.hero-ctas {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* ─── Seções gerais ─────────────────────────────────────────────────────── */
.section {
    padding: 90px 0;
}

.section-alt {
    background: var(--bg-alt);
}

.section-title {
    font-size: 2.4rem;
    text-align: center;
    margin-bottom: 16px;
    color: var(--navy);
    font-weight: 700;
}

[data-theme="dark"] .section-title {
    color: #90caf9;
}

.section-intro {
    text-align: center;
    max-width: 750px;
    margin: 0 auto 55px;
    font-size: 1.1rem;
    color: var(--text);
    opacity: 0.8;
}

/* ─── Destaques / Highlights ────────────────────────────────────────────── */
.highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

/* Grid das 4 frentes de atuação — força 4 colunas em telas largas */
.areas-overview {
    grid-template-columns: repeat(4, 1fr);
    margin-bottom: 70px;
}

@media (max-width: 1100px) {
    .areas-overview {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .areas-overview {
        grid-template-columns: 1fr;
    }
}

.highlight-card {
    background: var(--bg);
    padding: 38px 35px;
    border-radius: 14px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    transition: transform 0.2s;
}

.highlight-card:hover {
    transform: translateY(-4px);
}

.highlight-icon {
    color: var(--primary);
    margin-bottom: 20px;
}

.highlight-card h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    color: var(--navy);
    font-weight: 700;
}

[data-theme="dark"] .highlight-card h3 {
    color: #90caf9;
}

/* ─── Serviços ──────────────────────────────────────────────────────────── */
.service-categories {
    margin-top: 50px;
}

.category-section {
    margin-bottom: 80px;
}

.category-section:last-child {
    margin-bottom: 0;
}

.category-header {
    margin-bottom: 12px;
}

.category-header h3 {
    font-size: 2rem;
    text-align: center;
    color: var(--navy);
    font-weight: 700;
}

[data-theme="dark"] .category-header h3 {
    color: #90caf9;
}

.category-description {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.05rem;
    opacity: 0.8;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 28px;
}

.service-card {
    background: var(--bg);
    padding: 32px;
    border-radius: 14px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    position: relative;
    transition: transform 0.2s;
}

.service-card:hover {
    transform: translateY(-3px);
}

.service-card.featured {
    border: 2px solid var(--primary);
}

/* ─── Cards Expansíveis ─────────────────────────────────────────────────── */
.service-card.expandable {
    display: flex;
    flex-direction: column;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.card-emoji {
    font-size: 1.5rem;
    line-height: 1;
    flex-shrink: 0;
}

.service-card-desc {
    font-size: 0.88rem;
    opacity: 0.72;
    margin-bottom: 16px;
    line-height: 1.55;
}

.service-extra {
    display: none;
}

.service-card.expanded .service-extra {
    display: block;
    animation: fadeSlideDown 0.28s ease forwards;
}

@keyframes fadeSlideDown {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.expand-btn {
    margin-top: auto;
    padding-top: 14px;
    background: none;
    border: none;
    border-top: 1px solid var(--border);
    font-size: 0.83rem;
    font-weight: 600;
    cursor: pointer;
    color: var(--primary);
    text-align: left;
    transition: color 0.2s;
    width: 100%;
}

.expand-btn:hover {
    color: var(--navy);
}

[data-theme="dark"] .expand-btn:hover {
    color: #90caf9;
}

.badge {
    position: absolute;
    top: 14px;
    right: 14px;
    background: var(--primary);
    color: white;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.service-card h4 {
    font-size: 1.2rem;
    margin-bottom: 14px;
    color: var(--navy);
    font-weight: 700;
}

[data-theme="dark"] .service-card h4 {
    color: #90caf9;
}

.service-list {
    list-style: none;
}

.service-list li {
    padding: 7px 0 7px 24px;
    position: relative;
    font-size: 0.95rem;
    border-bottom: 1px solid var(--border);
}

.service-list li:last-child {
    border-bottom: none;
}

.service-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: 700;
}

/* ─── Formulário de Contato ─────────────────────────────────────────────── */
.contact-wrapper {
    max-width: 680px;
    margin: 0 auto;
}

.contact-form {
    background: var(--bg);
    padding: 45px;
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.95rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 13px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    background: var(--bg);
    color: var(--text);
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 163, 181, 0.15);
}

.form-group textarea {
    resize: vertical;
    min-height: 130px;
}

/* Feedback */
.form-feedback {
    margin-top: 16px;
    padding: 14px 18px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.5;
}

.form-feedback--success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.form-feedback--error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

[data-theme="dark"] .form-feedback--success {
    background: #064e3b;
    color: #6ee7b7;
    border-color: #065f46;
}

[data-theme="dark"] .form-feedback--error {
    background: #7f1d1d;
    color: #fca5a5;
    border-color: #991b1b;
}

#btnEnviar:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

/* ─── Footer ────────────────────────────────────────────────────────────── */
.footer {
    background: var(--navy);
    color: rgba(255,255,255,0.85);
    padding: 50px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand .logo-name {
    color: white;
    font-size: 1.3rem;
    margin-bottom: 10px;
    display: block;
}

.footer-brand p {
    font-size: 0.9rem;
    opacity: 0.7;
    line-height: 1.7;
}

.footer h4 {
    color: white;
    font-size: 1rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

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

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    margin-bottom: 10px;
    color: rgba(255,255,255,0.8);
}

.footer-contact-item a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
}

.footer-location-sub {
    font-size: 0.82rem;
    opacity: 0.6;
    margin-top: -6px;
    margin-bottom: 14px;
    padding-left: 4px;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.12);
    padding-top: 25px;
    text-align: center;
    font-size: 0.85rem;
    opacity: 0.6;
}

/* ─── Seletor de Idioma ─────────────────────────────────────────────────── */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 3px;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    background: transparent;
    border: none;
    border-radius: 6px;
    padding: 5px 9px;
    cursor: pointer;
    color: var(--text);
    font-size: 0.82rem;
    font-weight: 500;
    transition: background 0.18s, color 0.18s, box-shadow 0.18s;
    line-height: 1;
    white-space: nowrap;
    opacity: 0.6;
}

.lang-btn:hover {
    background: var(--bg);
    opacity: 0.85;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.lang-btn.active {
    background: var(--primary);
    color: white;
    opacity: 1;
    box-shadow: 0 2px 6px rgba(0, 163, 181, 0.30);
}

.lang-btn .flag {
    font-size: 1.1rem;
    line-height: 1;
}

.lang-btn .lang-code {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* ─── Responsivo ────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .hero-content {
        grid-template-columns: 1fr;
    }

    .hero-tag,
    .hero-title,
    .hero-description,
    .hero-ctas {
        grid-column: 1 / -1;
        grid-row: auto;
    }

    .hero-title {
        font-size: 2.4rem;
        margin-bottom: 18px;
    }

    .hero-description {
        padding-top: 0;
        margin-bottom: 28px;
    }

    .hero-ctas {
        margin-top: 0;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        padding: 20px;
        flex-direction: column;
        gap: 15px;
        box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    }

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

    .mobile-menu-btn {
        display: block;
    }

    .nav-actions .btn-primary {
        display: none;
    }

    .lang-btn .lang-code {
        display: none;
    }

    .lang-btn {
        padding: 5px 7px;
    }

    .topbar-contacts {
        display: none;
    }

    .contact-form {
        padding: 28px 22px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-ctas {
        flex-direction: column;
    }

    .btn-lg {
        text-align: center;
        width: 100%;
    }
}
