/*
   Maistech — Design System
   Paleta: Azul Escuro #101324 | Verde #4DB273 | Branco #FFFFFF
*/

:root {
    --navy:       #101324;
    --green:      #4DB273;
    --white:      #FFFFFF;
    --navy-80:    rgba(16,19,36,0.80);
    --navy-light: #1c2240;
    --gray-light: #f5f6f8;
    --gray-mid:   #6b7280;
    --gray-line:  #e2e5eb;
    --transition: all 0.28s ease;
    --radius:     4px;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.65;
    color: var(--navy);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ── Container ── */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

section { padding: 5rem 0; }

/* ── NAV ── */
nav {
    background: var(--navy);
    padding: 1rem 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 200;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
}

body { padding-top: 76px; }

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

.logo {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    line-height: 1;
}

.logo img {
    height: 44px;
    width: auto;
    display: block;
}

/* fallback texto (usado se imagem falhar) */
.logo-text {
    font-weight: 900;
    font-size: 1.4rem;
    letter-spacing: 1px;
    color: var(--white);
    text-transform: uppercase;
}
.logo-text span { color: var(--green); }

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: rgba(255,255,255,0.75);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active { color: var(--green); }

.nav-cta {
    background: var(--green) !important;
    color: var(--navy) !important;
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius);
    font-weight: 700 !important;
}

.nav-cta:hover { opacity: 0.88; }

/* ── HERO ── */
.hero {
    background: var(--navy);
    padding: 7rem 0 6rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -60px; right: -80px;
    width: 420px; height: 420px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(77,178,115,0.18) 0%, transparent 70%);
    pointer-events: none;
}

.hero h1 {
    font-size: 3.4rem;
    font-weight: 900;
    color: var(--white);
    line-height: 1.08;
    letter-spacing: -1.5px;
    max-width: 750px;
    margin-bottom: 1.2rem;
}

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

.hero p {
    color: rgba(255,255,255,0.7);
    font-size: 1.1rem;
    max-width: 560px;
    margin-bottom: 0;
}

.hero-actions {
    margin-top: 2.5rem;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ── BOTÕES ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.8rem 1.6rem;
    border: 2px solid var(--green);
    text-decoration: none;
    color: var(--navy);
    background: var(--green);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.82rem;
    letter-spacing: 0.5px;
    cursor: pointer;
    border-radius: var(--radius);
    transition: var(--transition);
}

.btn:hover {
    background: transparent;
    color: var(--green);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border-color: rgba(255,255,255,0.45);
}

.btn-outline:hover {
    border-color: var(--green);
    color: var(--green);
    background: transparent;
}

.btn-dark {
    background: var(--navy);
    color: var(--white);
    border-color: var(--navy);
}

.btn-dark:hover {
    background: var(--green);
    border-color: var(--green);
    color: var(--navy);
}

/* ── TIPOGRAFIA ── */
h1, h2, h3, h4 {
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 0.75rem;
}

h1 { font-size: 3.4rem; letter-spacing: -1.5px; }
h2 { font-size: 2.2rem; letter-spacing: -0.8px; }
h3 { font-size: 1.15rem; }

p {
    color: var(--gray-mid);
    margin-bottom: 1rem;
    max-width: 640px;
}

.section-label {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--green);
    margin-bottom: 0.75rem;
}

.section-header {
    margin-bottom: 3rem;
}

.section-header h2 { color: var(--navy); }

/* ── GRID ── */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

/* ── CARDS ── */
.card {
    background: var(--white);
    border: 1px solid var(--gray-line);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
    cursor: pointer;
}

.card:hover {
    border-color: var(--green);
    box-shadow: 0 8px 30px rgba(77,178,115,0.15);
    transform: translateY(-3px);
}

.card-img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    object-position: top;
    display: block;
    transition: var(--transition);
}

.card:hover .card-img { transform: scale(1.03); }

.card-img-wrap {
    overflow: hidden;
    position: relative;
    background: var(--gray-light);
}

.card-badge {
    position: absolute;
    top: 0.7rem;
    left: 0.7rem;
    background: var(--green);
    color: var(--navy);
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    padding: 0.2rem 0.6rem;
    border-radius: 2px;
}

.card-body {
    padding: 1.4rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-body h3 { color: var(--navy); margin-bottom: 0.4rem; }
.card-body p { font-size: 0.9rem; margin-bottom: 1rem; max-width: 100%; }

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
    align-self: flex-start;
}

/* ── PILARES (cards sem imagem) ── */
.pillar {
    padding: 2rem;
    border-left: 3px solid var(--green);
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.pillar h3 { color: var(--navy); margin-bottom: 0.5rem; }
.pillar p { max-width: 100%; }

/* ── SECÇÕES COM BG ESCURO ── */
.section-dark {
    background: var(--navy);
}

.section-dark h2,
.section-dark h3 { color: var(--white); }
.section-dark p { color: rgba(255,255,255,0.65); }
.section-dark .section-label { color: var(--green); }

/* ── SEÇÃO CINZA ── */
.section-gray { background: var(--gray-light); }

/* ── STATS ── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.stat-item { text-align: center; }
.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: var(--green);
    line-height: 1;
}
.stat-label {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.3rem;
}

/* ── SEPARADOR ── */
.divider {
    border: none;
    border-top: 1px solid var(--gray-line);
    margin: 0;
}

/* ── MODAL ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(16,19,36,0.88);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 500;
    padding: 1.5rem;
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--white);
    border-radius: 8px;
    max-width: 860px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 24px 80px rgba(0,0,0,0.4);
    animation: modalIn 0.25s ease;
}

@keyframes modalIn {
    from { opacity:0; transform: translateY(16px) scale(0.97); }
    to   { opacity:1; transform: translateY(0) scale(1); }
}

.modal-inner { display: flex; flex-direction: column; }

.modal-cover-wrap {
    width: 100%;
    height: 300px;
    background: var(--navy);
    border-radius: 8px 8px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* imagem de fundo desfocada para preencher espaço */
.modal-cover-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(18px) brightness(0.35) saturate(0.7);
    transform: scale(1.08);
    border-radius: 8px 8px 0 0;
}

/* imagem principal nítida, contida */
.modal-cover {
    position: relative;
    max-height: 280px;
    max-width: 55%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    border-radius: 4px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    z-index: 1;
}

.modal-body {
    padding: 2.5rem;
}

.modal-tag {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--green);
    margin-bottom: 0.6rem;
}

.modal-body h2 {
    font-size: 1.8rem;
    color: var(--navy);
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.modal-body .modal-desc {
    color: var(--gray-mid);
    font-size: 1rem;
    max-width: 100%;
    margin-bottom: 1.5rem;
}

.modal-specs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    background: var(--gray-light);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.spec-item label {
    display: block;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--green);
    margin-bottom: 0.2rem;
}

.spec-item span {
    font-size: 0.9rem;
    color: var(--navy);
    font-weight: 600;
}

.modal-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1.5rem;
}

.tag-pill {
    background: rgba(77,178,115,0.12);
    color: #2d8a55;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.3rem 0.7rem;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modal-footer-note {
    font-size: 0.72rem;
    color: var(--gray-mid);
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-line);
}

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--navy);
    color: var(--white);
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: var(--transition);
}

.close-modal:hover { background: var(--green); color: var(--navy); }

/* ── FORMULÁRIO ── */
form input,
form select,
form textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    border: 1.5px solid var(--gray-line);
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--navy);
    background: var(--white);
    transition: var(--transition);
    outline: none;
}

form input:focus,
form select:focus,
form textarea:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(77,178,115,0.15);
}

/* ── DISTRIBUIDORES LISTA ── */
.dist-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.dist-card {
    background: var(--white);
    border: 1px solid var(--gray-line);
    border-left: 3px solid var(--green);
    border-radius: var(--radius);
    padding: 1.5rem;
    transition: var(--transition);
}

.dist-card:hover {
    box-shadow: 0 6px 24px rgba(77,178,115,0.12);
    transform: translateY(-2px);
}

.dist-label {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--green);
    margin-bottom: 0.4rem;
}

.dist-card h3 {
    color: var(--navy);
    font-size: 1rem;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.dist-info {
    font-size: 0.88rem;
    color: var(--gray-mid);
    margin-bottom: 0.3rem;
    max-width: 100%;
}

.dist-info span {
    font-weight: 700;
    color: var(--navy);
}

.dist-info a {
    color: var(--green);
    text-decoration: none;
}

.dist-info a:hover { text-decoration: underline; }

/* ── DISTRIBUIDORES ── */
.feature-item {
    display: flex;
    gap: 1.2rem;
    align-items: flex-start;
    padding: 1.5rem;
    border-radius: var(--radius);
    background: var(--white);
    border: 1px solid var(--gray-line);
    margin-bottom: 1rem;
}

.feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(77,178,115,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: var(--green);
    font-size: 1.1rem;
}

/* ── INFO BOX ── */
.info-box {
    background: var(--navy);
    color: var(--white);
    border-radius: var(--radius);
    padding: 2.5rem;
}

.info-box h3 { color: var(--white); margin-bottom: 1rem; }
.info-box p { color: rgba(255,255,255,0.7); max-width: 100%; }
.info-box strong { color: var(--green); }

/* ── FOOTER ── */
footer {
    background: var(--navy);
    padding: 4rem 0 2rem;
    color: rgba(255,255,255,0.7);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 2rem;
}

footer h4 {
    color: var(--white);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.2rem;
}

footer p { color: rgba(255,255,255,0.55); max-width: 100%; font-size: 0.9rem; margin-bottom: 0.5rem; }

footer ul { list-style: none; }
footer ul li { margin-bottom: 0.6rem; }
footer ul li a {
    color: rgba(255,255,255,0.55);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}
footer ul li a:hover { color: var(--green); }

.footer-copy {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.footer-copy a {
    color: rgba(255,255,255,0.35);
    text-decoration: none;
    transition: var(--transition);
}

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

/* ── WHATSAPP FLOAT ── */
.btn-float {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: #25D366;
    color: white;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(37,211,102,0.4);
    z-index: 300;
    transition: var(--transition);
}

.btn-float:hover { transform: scale(1.1); }

/* ── PÁGINA DE HEADER INTERNO ── */
.page-header {
    background: var(--navy);
    padding: 4rem 0 3rem;
}

.page-header h1, .page-header h2 { color: var(--white); }
.page-header p { color: rgba(255,255,255,0.65); }

/* ── FILTROS ── */
.filter-bar {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 2.5rem;
}

.filter-btn {
    padding: 0.45rem 1rem;
    border: 1.5px solid var(--gray-line);
    background: transparent;
    color: var(--gray-mid);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 20px;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--green);
    border-color: var(--green);
    color: var(--navy);
}

/* ── MENU MOBILE CLOSE BUTTON ── */
.mobile-close {
    position: absolute;
    top: 1.2rem;
    right: 1.2rem;
    background: transparent;
    border: 2px solid rgba(255,255,255,0.3);
    color: var(--white);
    font-size: 1.4rem;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    line-height: 1;
    font-family: inherit;
}

.mobile-close:hover { border-color: var(--green); color: var(--green); }

/* ── HAMBÚRGUER ── */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 301;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--white);
    border-radius: 2px;
    transition: var(--transition);
    transform-origin: center;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Menu mobile (drawer) */
.mobile-menu {
    display: none;
    position: fixed;
    inset: 0;
    background: var(--navy);
    z-index: 299;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

@keyframes menuBubble {
    from { clip-path: circle(0% at calc(100% - 2.5rem) 2.5rem); }
    to   { clip-path: circle(170% at calc(100% - 2.5rem) 2.5rem); }
}

@keyframes menuBubbleOut {
    from { clip-path: circle(170% at calc(100% - 2.5rem) 2.5rem); }
    to   { clip-path: circle(0% at calc(100% - 2.5rem) 2.5rem); }
}

@keyframes menuItemsIn {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

.mobile-menu.open {
    display: flex;
    animation: menuBubble 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.mobile-menu.open > * {
    animation: menuItemsIn 0.35s ease forwards;
    animation-delay: 0.25s;
    opacity: 0;
}

.mobile-menu.closing {
    display: flex;
    animation: menuBubbleOut 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.mobile-menu.closing > * {
    opacity: 0;
    transition: opacity 0.1s ease;
}

.mobile-menu a {
    color: var(--white);
    text-decoration: none;
    font-size: 1.4rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
}

.mobile-menu a:hover,
.mobile-menu a.active { color: var(--green); }

.mobile-menu .mobile-cta {
    margin-top: 1rem;
    padding: 0.9rem 2.5rem;
    background: var(--green);
    color: var(--navy) !important;
    border-radius: var(--radius);
    font-size: 1rem !important;
}

/* ── RESPONSIVO ── */
html, body { overflow-x: hidden; }

@media (max-width: 1024px) {
    .hero h1 { font-size: 3rem; }
}

@media (max-width: 900px) {
    .grid-2 { grid-template-columns: 1fr; gap: 2rem; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
    .modal-specs { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    /* Logo menor no mobile */
    .logo img { height: 36px; }

    /* Tipografia */
    h1 { font-size: 2rem !important; letter-spacing: -0.8px; }
    h2 { font-size: 1.6rem; letter-spacing: -0.4px; }
    .hero h1 { font-size: 2rem !important; letter-spacing: -0.8px; line-height: 1.12; }

    /* Nav */
    body { padding-top: 66px; }
    .nav-links { display: none; }
    .hamburger { display: flex; }

    /* Hero */
    .hero { padding: 4.5rem 0 3.5rem; }
    .hero::before { display: none; }
    .hero-actions { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
    .hero-actions .btn { width: 100%; justify-content: center; }

    /* Sections */
    section { padding: 3rem 0; }
    .container { padding: 0 1.25rem; }

    /* Page header */
    .page-header { padding: 3rem 0 2rem; }

    /* Stats */
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
    .stat-number { font-size: 2.2rem; }

    /* Grid de cards */
    .grid { grid-template-columns: 1fr; }

    /* Filtros */
    .filter-bar { gap: 0.35rem; }
    .filter-btn { font-size: 0.72rem; padding: 0.4rem 0.8rem; }

    /* Modal — quase fullscreen */
    .modal-overlay { padding: 0; align-items: flex-end; }
    .modal-content {
        max-height: 92vh;
        border-radius: 16px 16px 0 0;
        width: 100%;
    }
    .modal-cover-wrap { height: 220px; border-radius: 16px 16px 0 0; }
    .modal-cover-bg { border-radius: 16px 16px 0 0; }
    .modal-cover { max-height: 200px; max-width: 60%; }
    .modal-body { padding: 1.25rem 1.25rem 2rem; }
    .modal-body h2 { font-size: 1.4rem; }
    .modal-specs { grid-template-columns: 1fr 1fr; }

    /* Footer */
    .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
    .footer-copy { flex-direction: column; gap: 0.3rem; text-align: center; }

    /* Feature items */
    .feature-item { padding: 1rem; }

    /* Info box */
    .info-box { padding: 1.5rem; }

    /* Formulário */
    form input, form select, form textarea { font-size: 16px; /* evita zoom no iOS */ }
}

@media (max-width: 480px) {
    .hero h1 { font-size: 1.75rem !important; }
    h2 { font-size: 1.4rem; }
    .stat-number { font-size: 1.9rem; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
    .modal-specs { grid-template-columns: 1fr; }
    .filter-bar { gap: 0.3rem; }
    .close-modal { top: 0.75rem; right: 0.75rem; }
}
