/* ============================================================
   GEEK THRIVE - STYLES
   Change brand colours / fonts in :root below.
   ============================================================ */

:root {
    --primary:      #4f46e5;   /* main brand colour */
    --primary-dark: #4338ca;
    --accent:       #06b6d4;   /* second brand colour */
    --text:         #0f172a;
    --muted:        #64748b;
    --bg:           #ffffff;
    --bg-alt:       #f5f7fb;
    --card:         #ffffff;
    --border:       #e2e8f0;
    --radius:       16px;
    --shadow:       0 10px 30px -12px rgba(15, 23, 42, .18);
    --font:         'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --max-width:    1180px;
}

/* Dark mode follows the visitor's device setting */
@media (prefers-color-scheme: dark) {
    :root {
        --text:   #e2e8f0;
        --muted:  #94a3b8;
        --bg:     #0b1120;
        --bg-alt: #111a2e;
        --card:   #131d33;
        --border: #1f2b45;
        --shadow: 0 10px 30px -12px rgba(0, 0, 0, .6);
    }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
h1, h2, h3, .h3 { line-height: 1.2; margin: 0 0 .6em; letter-spacing: -.02em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.5rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); font-weight: 800; }
h3, .h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
[x-cloak] { display: none !important; }

.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 16px; }
.container--narrow { max-width: 800px; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.center { text-align: center; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 640px; }
.center .lead, .page-hero .lead { margin-left: auto; margin-right: auto; }
.eyebrow {
    display: inline-block; font-size: .8rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: .08em; color: var(--primary); background: color-mix(in srgb, var(--primary) 10%, transparent);
    padding: 6px 12px; border-radius: 999px; margin-bottom: 1rem;
}
.gradient-text {
    background: linear-gradient(90deg, var(--primary), var(--accent));
    -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 22px; border-radius: 12px; font-weight: 600; font-size: 1rem;
    border: 2px solid transparent; cursor: pointer; transition: all .2s ease; font-family: inherit;
}
.btn--primary { background: var(--primary); color: #fff; }
.btn--primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn--outline { border-color: var(--border); color: var(--text); background: var(--card); }
.btn--outline:hover { border-color: var(--primary); color: var(--primary); }
.btn--light { background: #fff; color: var(--primary); }
.btn--ghost { border-color: rgba(255,255,255,.5); color: #fff; }
.btn--ghost:hover { background: rgba(255,255,255,.12); }
.btn--sm { padding: 8px 16px; font-size: .9rem; }
.btn--lg { padding: 15px 28px; font-size: 1.05rem; }
.btn--block { width: 100%; }
.btn:disabled { opacity: .6; cursor: wait; }

/* ---------- Navbar ---------- */
.navbar {
    position: sticky; top: 0; z-index: 50;
    background: color-mix(in srgb, var(--bg) 85%, transparent);
    backdrop-filter: blur(12px); border-bottom: 1px solid transparent; transition: border-color .2s;
}
.navbar--scrolled { border-bottom-color: var(--border); }
.navbar__inner { display: flex; align-items: center; justify-content: space-between; height: 70px; gap: 16px; }
.logo { display: flex; align-items: center; min-width: 0; min-height: 44px; }
.logo img { width: 211px; max-width: 100%; height: auto; }   /* width-based so it can shrink on tiny phones */
.logo--footer img { width: 211px; margin-bottom: 16px; }
/* The logo is black - turn it white in dark mode */
@media (prefers-color-scheme: dark) { .logo img { filter: invert(1); } }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--muted); font-weight: 500; padding: 8px 14px; border-radius: 10px; }
.nav a:hover, .nav a.active { color: var(--text); background: var(--bg-alt); }
.navbar__actions { display: flex; align-items: center; gap: 10px; }
.region-select {
    padding: 8px 10px; border-radius: 10px; border: 1px solid var(--border);
    background: var(--card); color: var(--text); font: inherit; font-size: .9rem; cursor: pointer;
}
.menu-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.menu-toggle span { display: block; width: 22px; height: 2px; background: var(--text); margin: 5px 0; border-radius: 2px; }

/* ---------- Hero ---------- */
.hero { padding: 80px 0 60px; background:
    radial-gradient(circle at 85% 10%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 45%),
    radial-gradient(circle at 10% 90%, color-mix(in srgb, var(--primary) 14%, transparent), transparent 45%); }
.hero__inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero__buttons { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 16px; }
.hero__note { color: var(--muted); font-size: .95rem; }

.mock-browser { background: var(--card); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow); overflow: hidden; animation: float 6s ease-in-out infinite; }
.mock-browser__bar { display: flex; gap: 6px; padding: 14px; border-bottom: 1px solid var(--border); }
.mock-browser__bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--border); }
.mock-browser__body { padding: 24px; position: relative; }
.mock-line { height: 12px; border-radius: 6px; background: var(--bg-alt); margin-bottom: 12px; }
.w-60 { width: 60%; } .w-75 { width: 75%; } .w-90 { width: 90%; }
.mock-chart { display: flex; align-items: flex-end; gap: 10px; height: 160px; margin-top: 24px; }
.mock-chart span { flex: 1; border-radius: 8px 8px 0 0; background: linear-gradient(180deg, var(--accent), var(--primary)); }
.mock-tag { position: absolute; top: 18px; right: 18px; background: var(--primary); color: #fff; font-weight: 600; font-size: .85rem; padding: 6px 12px; border-radius: 999px; }
@keyframes float { 50% { transform: translateY(-10px); } }

.page-hero { padding: 72px 0 40px; text-align: center; background: var(--bg-alt); }

/* ---------- Sections & grids ---------- */
.section { padding: 80px 0; }
.section--alt { background: var(--bg-alt); }
.section__title { text-align: center; }
.section__subtitle { text-align: center; color: var(--muted); margin: -6px auto 40px; max-width: 560px; }
.section__title + .grid { margin-top: 40px; }
.grid { display: grid; gap: 24px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.grid > *, .split > *, .form__row > * { min-width: 0; }   /* stops content stretching the page on phones */
body { overflow-x: clip; }

/* ---------- Cards ---------- */
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; }
.card + .card { margin-top: 0; }
.split > div > .card + .card { margin-top: 24px; }
.card--hover { transition: transform .25s, box-shadow .25s, border-color .25s; }
.card--hover:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--primary) 40%, var(--border)); }
.card--accent { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 6%, var(--card)); }
.card__icon { font-size: 2rem; margin-bottom: 12px; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags span { background: var(--bg-alt); border: 1px solid var(--border); padding: 6px 12px; border-radius: 999px; font-size: .875rem; }

.checklist { list-style: none; padding: 0; margin: 0 0 24px; }
.checklist li { padding: 6px 0 6px 28px; position: relative; }
.checklist li::before { content: '✓'; position: absolute; left: 0; color: var(--primary); font-weight: 800; }

/* ---------- Stats ---------- */
.stats { padding: 0 0 40px; }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat { text-align: center; padding: 24px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--border); }
.stat strong { display: block; font-size: 2rem; font-weight: 800; color: var(--primary); }
.stat span { color: var(--muted); font-size: .9rem; }

/* ---------- Steps ---------- */
.step b { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--primary); color: #fff; margin-bottom: 14px; }

/* ---------- Testimonials ---------- */
.testimonial { margin: 0; }
.testimonial blockquote { margin: 0 0 16px; font-size: 1.05rem; }
.testimonial figcaption { color: var(--muted); font-size: .9rem; }

/* ---------- Pricing ---------- */
.price-card { position: relative; display: flex; flex-direction: column; }
.price-card .checklist { flex: 1; }
.price-card--featured { border: 2px solid var(--primary); box-shadow: var(--shadow); }
.badge { position: absolute; top: -12px; left: 28px; background: var(--primary); color: #fff; font-size: .75rem; font-weight: 700; padding: 4px 12px; border-radius: 999px; }
.price { font-size: 2.4rem; font-weight: 800; margin: 8px 0 16px; }
.price small { font-size: .95rem; font-weight: 500; color: var(--muted); }
.tabs { display: inline-flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 16px; padding: 6px; background: var(--card); border: 1px solid var(--border); border-radius: 14px; }
.tabs button { border: 0; background: none; padding: 10px 16px; border-radius: 10px; font: inherit; font-weight: 600; color: var(--muted); cursor: pointer; }
.tabs button.is-active { background: var(--primary); color: #fff; }
.tabs button { display: inline-flex; align-items: center; gap: 8px; }
.flag { display: inline-block; width: auto; border-radius: 3px; box-shadow: 0 0 0 1px rgba(0,0,0,.08); vertical-align: middle; }
.card__icon .flag { margin: 0 auto; border-radius: 6px; }

/* ---------- FAQ ---------- */
.faq__item { border: 1px solid var(--border); border-radius: 12px; margin-bottom: 12px; background: var(--card); }
.faq__q { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 20px; background: none; border: 0; font: inherit; font-weight: 600; color: var(--text); text-align: left; cursor: pointer; }
.faq__icon { font-size: 1.4rem; color: var(--primary); transition: transform .2s; }
.faq__item.is-open .faq__icon { transform: rotate(45deg); }
.faq__a { padding: 0 20px 6px; color: var(--muted); }

/* ---------- CTA ---------- */
.cta { text-align: center; color: #fff; padding: 56px 24px; border-radius: 24px; background: linear-gradient(135deg, var(--primary), var(--accent)); }
.cta p { opacity: .9; max-width: 520px; margin: 0 auto 24px; }
.cta__buttons { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/* ---------- Forms ---------- */
.form label { display: block; font-weight: 500; font-size: .95rem; margin-bottom: 16px; }
.form input, .form select, .form textarea {
    display: block; width: 100%; margin-top: 6px; padding: 12px 14px; font: inherit; color: var(--text);
    background: var(--bg); border: 1px solid var(--border); border-radius: 10px; transition: border-color .2s, box-shadow .2s;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 20%, transparent); }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form__msg { margin: 16px 0 0; padding: 12px 14px; border-radius: 10px; font-weight: 500; }
.form__msg--ok { background: #dcfce7; color: #166534; }
.form__msg--error { background: #fee2e2; color: #991b1b; }
.hp { position: absolute; left: -9999px; }

/* ---------- Footer ---------- */
.footer { background: var(--bg-alt); border-top: 1px solid var(--border); padding: 60px 0 24px; margin-top: 40px; }
.footer__grid { display: grid; grid-template-columns: 2fr 1fr 1.3fr 1fr; gap: 32px; }
.footer h4 { margin: 0 0 12px; }
.footer a, .footer span { display: block; color: var(--muted); padding: 3px 0; font-size: .95rem; }
.footer a:hover { color: var(--primary); }
.footer__address { font-style: normal; }
.whatsapp {
    position: fixed; right: 20px; bottom: 20px; z-index: 60; width: 56px; height: 56px; border-radius: 50%;
    display: grid; place-items: center; background: #25d366; color: #fff; box-shadow: 0 8px 24px rgba(0,0,0,.25);
    transition: transform .2s;
}
.whatsapp:hover { transform: scale(1.08); }
.address-card p { margin-bottom: .6em; }
.map { width: 100%; height: 240px; border: 0; border-radius: 12px; margin-top: 8px; }
.footer__bottom { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--border); color: var(--muted); font-size: .875rem; text-align: center; }

/* ---------- Scroll reveal (only when JavaScript is running) ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.js [data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .js [data-reveal] { opacity: 1; transform: none; transition: none; }
    .mock-browser { animation: none; }
}

/* ---------- Tablet ---------- */
@media (max-width: 960px) {
    .grid--3, .grid--4, .stats__grid { grid-template-columns: repeat(2, 1fr); }
    .hero__inner, .split { grid-template-columns: 1fr; }
    .hero__visual { max-width: 480px; width: 100%; margin: 0 auto; }
    .footer__grid { grid-template-columns: 1fr 1fr; }

    .menu-toggle { display: block; }
    .nav {
        display: none; position: absolute; top: 70px; left: 0; right: 0; flex-direction: column;
        padding: 12px 16px 20px; background: var(--bg); border-bottom: 1px solid var(--border);
    }
    .nav--open { display: flex; }
}

/* ---------- Mobile ---------- */
@media (max-width: 600px) {
    .grid--2, .grid--3, .grid--4, .form__row, .footer__grid { grid-template-columns: 1fr; }
    .hide-mobile { display: none; }
    .logo img { width: 141px; }
    .region-select { padding: 6px; }
    .hero__visual { display: none; }          /* decorative only - saves scrolling on phones */
    .whatsapp { width: 50px; height: 50px; right: 14px; bottom: 14px; }
    .tabs button { padding: 10px 12px; }
}

/* ---------- Very small phones (Galaxy Fold, iPhone SE 1st gen) ---------- */
@media (max-width: 360px) {
    .navbar__inner { gap: 8px; }
    .navbar__actions { gap: 4px; }
    .logo img { width: 120px; }
    h1 { font-size: 1.85rem; }
    .card { padding: 22px; }
    .price { font-size: 2rem; }
}

/* ---------- Touch screens: finger-friendly tap targets (44px+) ---------- */
@media (pointer: coarse), (max-width: 960px) {
    .region-select, .menu-toggle, .tabs button { min-height: 44px; }
    .nav a { padding: 12px 14px; }
    .footer a { padding: 10px 0; }
    .footer span { padding: 6px 0; }
    .section { padding: 56px 0; }
    .hero { padding: 48px 0 40px; }
}
