/*
|--------------------------------------------------------------------------
| MAELTH - Tecnologia da Informação
| Folha de estilos principal
|--------------------------------------------------------------------------
*/

/*
|--------------------------------------------------------------------------
| 1. Variáveis
|--------------------------------------------------------------------------
*/

:root {

    --green: #39B54A;
    --green-dark: #168238;
    --green-soft: rgba(57, 181, 74, 0.12);

    --gray-950: #151719;
    --gray-900: #1D2023;
    --gray-800: #292D31;
    --gray-700: #343A40;
    --gray-600: #495057;
    --gray-500: #6C757D;
    --gray-300: #CED4DA;
    --gray-200: #DEE2E6;
    --gray-100: #F1F3F5;

    --white: #FFFFFF;

    --body-bg: #FFFFFF;
    --surface: #F7F8F9;
    --surface-strong: #FFFFFF;
    --text: #1D2023;
    --text-muted: #6C757D;
    --border: rgba(29, 32, 35, 0.10);

    --header-bg: rgba(255, 255, 255, 0.88);

    --container: 1180px;

    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;

    --shadow-soft:
        0 12px 40px rgba(29, 32, 35, 0.08);

    --transition:
        180ms ease;
}


/*
|--------------------------------------------------------------------------
| 2. Tema escuro
|--------------------------------------------------------------------------
*/

html[data-theme="dark"] {

    --body-bg: #101214;
    --surface: #171A1D;
    --surface-strong: #1D2023;
    --text: #F1F3F5;
    --text-muted: #AAB0B6;
    --border: rgba(255, 255, 255, 0.10);

    --header-bg: rgba(16, 18, 20, 0.88);

    --shadow-soft:
        0 12px 40px rgba(0, 0, 0, 0.28);
}


/*
|--------------------------------------------------------------------------
| 3. Reset
|--------------------------------------------------------------------------
*/

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 320px;

    background: var(--body-bg);
    color: var(--text);

    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    line-height: 1.6;

    transition:
        background-color var(--transition),
        color var(--transition);
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}


/*
|--------------------------------------------------------------------------
| 4. Estrutura
|--------------------------------------------------------------------------
*/

.container {
    width: min(
        calc(100% - 40px),
        var(--container)
    );

    margin-inline: auto;
}


/*
|--------------------------------------------------------------------------
| 5. Header
|--------------------------------------------------------------------------
*/

.site-header {

    position: sticky;
    top: 0;
    z-index: 1000;

    background: var(--header-bg);

    border-bottom:
        1px solid var(--border);

    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.nav-container {

    min-height: 82px;

    display: grid;

    grid-template-columns:
        minmax(180px, 1fr)
        auto
        minmax(180px, 1fr);

    align-items: center;

    gap: 24px;
}

.brand {
    display: inline-flex;
    width: fit-content;
}

.brand-logo {

    width: min(215px, 100%);
    height: auto;

    object-fit: contain;
}

.desktop-navigation {

    display: flex;
    align-items: center;
    gap: 28px;
}

.desktop-navigation a {

    position: relative;

    color: var(--text-muted);

    font-size: 0.94rem;
    font-weight: 600;

    transition:
        color var(--transition);
}

.desktop-navigation a::after {

    content: "";

    position: absolute;

    left: 0;
    bottom: -8px;

    width: 0;
    height: 2px;

    background: var(--green);

    transition:
        width var(--transition);
}

.desktop-navigation a:hover {
    color: var(--text);
}

.desktop-navigation a:hover::after {
    width: 100%;
}

.nav-actions {

    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}


/*
|--------------------------------------------------------------------------
| 6. WhatsApp
|--------------------------------------------------------------------------
*/

.whatsapp-button {

    margin-left: 50px;

    min-height: 44px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    padding:
        0 16px;

    border:
        1px solid rgba(57, 181, 74, 0.25);

    border-radius: 999px;

    background: var(--green-soft);

    color: var(--green-dark);

    font-size: 0.88rem;
    font-weight: 700;

    transition:
        transform var(--transition),
        background-color var(--transition),
        color var(--transition),
        box-shadow var(--transition);
}

html[data-theme="dark"] .whatsapp-button {
    color: #7BE487;
}

.whatsapp-button:hover {

    transform: translateY(-2px);

    background: var(--green);

    color: #FFFFFF;

    box-shadow:
        0 8px 24px rgba(57, 181, 74, 0.22);
}

.whatsapp-icon {

    width: 19px;
    height: 19px;

    fill: currentColor;
}


/*
|--------------------------------------------------------------------------
| 7. Controles
|--------------------------------------------------------------------------
*/

.theme-toggle,
.menu-toggle {

    width: 42px;
    height: 42px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 1px solid var(--border);
    border-radius: 50%;

    background: transparent;

    color: var(--text);

    cursor: pointer;

    transition:
        background-color var(--transition),
        border-color var(--transition),
        transform var(--transition);
}

.theme-toggle:hover,
.menu-toggle:hover {

    background: var(--surface);

    border-color:
        rgba(57, 181, 74, 0.35);
}

.theme-toggle {
    font-size: 1.1rem;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
}

.menu-toggle span {

    width: 17px;
    height: 2px;

    border-radius: 2px;

    background: currentColor;

    transition:
        transform var(--transition),
        opacity var(--transition);
}

.menu-toggle.is-active span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.menu-toggle.is-active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-active span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}


/*
|--------------------------------------------------------------------------
| 8. Menu mobile
|--------------------------------------------------------------------------
*/

.mobile-navigation {
    display: none;
}


/*
|--------------------------------------------------------------------------
| 9. Hero
|--------------------------------------------------------------------------
*/

.hero {

    position: relative;

    overflow: hidden;

    padding:
        120px 0 130px;
}

.hero::before {

    content: "";

    position: absolute;

    width: 480px;
    height: 480px;

    right: -220px;
    top: -160px;

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            rgba(57, 181, 74, 0.16),
            transparent 68%
        );

    pointer-events: none;
}

.hero-placeholder .container {
    position: relative;
    z-index: 1;
}

.eyebrow {

    margin: 0 0 18px;

    color: var(--green-dark);

    font-size: 0.78rem;
    font-weight: 800;

    letter-spacing: 0.18em;
}

html[data-theme="dark"] .eyebrow {
    color: #6FDB7B;
}

.hero h1 {

    max-width: 850px;

    margin: 0;

    font-size:
        clamp(3rem, 7vw, 6.4rem);

    line-height: 0.98;

    letter-spacing: -0.055em;
}

.hero h1 span {
    color: var(--green);
}

.hero-description {

    max-width: 670px;

    margin:
        30px 0 0;

    color: var(--text-muted);

    font-size:
        clamp(1.05rem, 2vw, 1.25rem);

    line-height: 1.75;
}

.hero-actions {

    display: flex;
    flex-wrap: wrap;

    gap: 12px;

    margin-top: 36px;
}


/*
|--------------------------------------------------------------------------
| 10. Botões
|--------------------------------------------------------------------------
*/

.button {

    min-height: 52px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding:
        0 22px;

    border-radius: 999px;

    font-weight: 700;

    transition:
        transform var(--transition),
        background-color var(--transition),
        color var(--transition),
        border-color var(--transition),
        box-shadow var(--transition);
}

.button:hover {
    transform: translateY(-2px);
}

.button-primary {

    background: var(--green);

    color: #FFFFFF;

    box-shadow:
        0 10px 28px rgba(57, 181, 74, 0.20);
}

.button-primary:hover {
    background: var(--green-dark);
}

.button-secondary {

    border:
        1px solid var(--border);

    background: transparent;

    color: var(--text);
}

.button-secondary:hover {
    border-color: var(--green);
}


/*
|--------------------------------------------------------------------------
| 11. Seções
|--------------------------------------------------------------------------
*/

.section {

    padding:
        100px 0;
}

.section-placeholder {
    background: var(--surface);
}

.section h2 {

    max-width: 760px;

    margin: 0;

    font-size:
        clamp(2rem, 4vw, 3.5rem);

    line-height: 1.05;

    letter-spacing: -0.035em;
}


/*
|--------------------------------------------------------------------------
| 12. Footer
|--------------------------------------------------------------------------
*/

.site-footer {

    padding:
        70px 0 30px;

    border-top:
        1px solid var(--border);

    background: var(--surface);
}

.footer-grid {

    display: grid;

    grid-template-columns:
        2fr
        1fr
        1fr
        1fr;

    gap: 50px;
}

.footer-brand p {

    max-width: 330px;

    color: var(--text-muted);
}

.footer-logo {

    width: 190px;
}

.footer-column {

    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-column h2 {

    margin: 0 0 8px;

    font-size: 0.82rem;

    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.footer-column a {

    color: var(--text-muted);

    transition:
        color var(--transition);
}

.footer-column a:hover {
    color: var(--green);
}

.footer-bottom {

    display: flex;
    justify-content: space-between;
    gap: 20px;

    margin-top: 60px;
    padding-top: 25px;

    border-top:
        1px solid var(--border);

    color: var(--text-muted);

    font-size: 0.82rem;
}

.footer-bottom p {
    margin: 0;
}


/*
|--------------------------------------------------------------------------
| 13. Responsividade
|--------------------------------------------------------------------------
*/

@media (max-width: 1100px) {

    .nav-container {
        grid-template-columns:
            1fr
            auto;
    }

    .desktop-navigation {
        display: none;
    }

    .nav-actions {
        grid-column: 2;
    }

    .menu-toggle {
        display: inline-flex;
    }

    /*
    |--------------------------------------------------------------------------
    | Mobile: logo à esquerda, WhatsApp centralizado, menu à direita
    |--------------------------------------------------------------------------
    */

    .nav-container {
        position: relative;
    }

    .brand {
        grid-column: 1;
        grid-row: 1;
    }

    .nav-actions {
        display: flex;
        grid-column: 2;
        grid-row: 1;
    }

    .nav-actions .whatsapp-button {
        position: absolute;

        left: 50%;
        transform: translateX(-50%);

        white-space: nowrap;
    }

    .nav-actions .whatsapp-button:hover {
        transform: translateX(-50%) translateY(-2px);
    }

    .theme-toggle {
        display: none;
    }

    .mobile-navigation {

        display: flex;
        flex-direction: column;

        max-height: 0;
        overflow: hidden;

        border-top: 0 solid var(--border);

        background: var(--header-bg);

        transition:
            max-height 250ms ease,
            border-color 250ms ease;
    }

    .mobile-navigation.is-open {

        max-height: 100%;

        border-top-width: 1px;
    }

    .mobile-navigation a {

        padding: 15px 20px;

        color: var(--text-muted);

        font-weight: 600;

        border-bottom:
            1px solid var(--border);
    }

    .mobile-navigation a:hover {
        color: var(--green);
    }
}


@media (max-width: 650px) {

    .container {
        width: min(
            calc(100% - 28px),
            var(--container)
        );
    }

    .nav-container {
        min-height: 70px;
    }

    .brand-logo {
        width: 145px;
    }

    .whatsapp-button {

        min-height: 40px;

        padding:
            0 12px;

        font-size: 0.78rem;
    }

    .whatsapp-icon {
        width: 17px;
        height: 17px;
    }

    .hero {
        padding:
            90px 0 100px;
    }

    .hero-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .button {
        width: 100%;
    }

    .section {
        padding:
            75px 0;
    }

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

    .footer-bottom {
        flex-direction: column;
    }
}


/*
|--------------------------------------------------------------------------
| 14. Redução de movimento
|--------------------------------------------------------------------------
*/

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}