/* =========================================================================
   Launcher — US Landing Page
   Tone: bold, direct, benefit-driven. US conventions (USD, en-US, "save X").
   ========================================================================= */

:root {
    /* Light pro theme — aligned with launcher-app.com */
    --bg: #f2f6f7;
    --bg-soft: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #e8f0f2;
    --border: #dde8eb;
    --border-strong: #c5d5da;

    --text: #151e36;
    --text-muted: #4a5c68;
    --text-dim: #5f7380;

    --accent: #389798;
    --accent-strong: #29768e;
    --accent-glow: rgba(56, 151, 152, 0.18);
    --accent-2: #79afbc;
    --accent-3: #ca8a04;

    --success: #16a34a;
    --danger: #dc2626;

    --gradient-hero: radial-gradient(70% 60% at 50% 0%, rgba(56, 151, 152, 0.12), transparent 70%);
    --gradient-cta: linear-gradient(135deg, #389798 0%, #29768e 100%);
    --gradient-text: none;

    --shadow-card: 0 1px 2px rgba(21, 30, 54, 0.06), 0 8px 24px rgba(21, 30, 54, 0.06);
    --shadow-cta: 0 8px 24px rgba(56, 151, 152, 0.28);

    --radius: 14px;
    --radius-lg: 22px;

    --container: 1180px;

    font-family:
        'Inter',
        -apple-system,
        BlinkMacSystemFont,
        'Segoe UI',
        sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family:
        'Inter',
        -apple-system,
        BlinkMacSystemFont,
        'Segoe UI',
        sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

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

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

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.4rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition:
        transform 0.12s ease,
        box-shadow 0.18s ease,
        background 0.18s ease,
        border-color 0.18s ease;
    white-space: nowrap;
}

.btn-secondary {
    background: var(--bg-soft);
    color: var(--text);
    border-color: var(--border-strong);
    box-shadow: 0 1px 2px rgba(21, 30, 54, 0.04);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent);
}

/* ---------- Navbar ---------- */
.navbar {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(18px);
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid var(--border);
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    row-gap: 10px;
    padding: 16px 24px;
    max-width: var(--container);
    margin: 0 auto;
}

/* flex-shrink: 0 — sinon le logo absorbe toute la compression et se déforme
   quand les libellés des boutons sont longs (de, es) */
.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    flex-shrink: 0;
}

@media (max-width: 600px) {
    .navbar-inner {
        padding: 12px 16px;
    }

    .nav-actions {
        gap: 0.35rem;
    }

    .nav-actions .btn {
        padding: 0.6rem 0.8rem;
        font-size: 0.82rem;
    }
}

/* Marge très serrée sous 480px, surtout pour les libellés longs (de, es) */
@media (max-width: 480px) {
    .nav-actions .btn {
        padding: 0.6rem 0.65rem;
        font-size: 0.78rem;
    }
}

@media (max-width: 400px) {
    .navbar-inner {
        padding: 12px 14px;
    }

    .nav-actions {
        gap: 0.25rem;
    }
}

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

/* Entre 861 et 1080px les liens et les actions se disputent la place : on compacte
   les boutons plutôt que de laisser la navbar passer sur deux lignes */
@media (min-width: 861px) and (max-width: 1080px) {
    .nav-links {
        gap: 0.6rem;
    }

    .nav-links a {
        font-size: 0.82rem;
    }

    .nav-actions .btn {
        padding: 0.7rem 1rem;
        font-size: 0.88rem;
    }
}

.nav-links a {
    color: var(--text-muted);
    font-size: 0.92rem;
    font-weight: 500;
    transition: color 0.15s ease;
}

.nav-links a:hover {
    color: var(--text);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: auto;
}

/* ---------- Menu mobile ---------- */
.nav-menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    flex: none;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-muted);
    cursor: pointer;
    transition:
        border-color 0.15s ease,
        color 0.15s ease,
        background 0.15s ease;
}

.nav-menu-toggle:hover {
    color: var(--text);
    border-color: var(--border-strong);
    background: var(--bg-card-hover);
}

.nav-menu-toggle:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.nav-menu-bars,
.nav-menu-bars::before,
.nav-menu-bars::after {
    display: block;
    width: 18px;
    height: 2px;
    border-radius: 1px;
    background: currentColor;
    transition:
        transform 0.2s ease,
        background 0.2s ease,
        top 0.2s ease;
}

.nav-menu-bars {
    position: relative;
}

.nav-menu-bars::before,
.nav-menu-bars::after {
    content: '';
    position: absolute;
    left: 0;
}

.nav-menu-bars::before {
    top: -6px;
}

.nav-menu-bars::after {
    top: 6px;
}

.nav-menu-toggle.is-open .nav-menu-bars {
    background: transparent;
}

.nav-menu-toggle.is-open .nav-menu-bars::before {
    top: 0;
    transform: rotate(45deg);
}

.nav-menu-toggle.is-open .nav-menu-bars::after {
    top: 0;
    transform: rotate(-45deg);
}

.nav-menu {
    display: none;
}

@media (max-width: 860px) {
    .nav-links {
        display: none;
    }

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

    /* Repris dans le panneau par nav-menu.js */
    .nav-actions .nav-signin {
        display: none;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        display: flex;
        flex-direction: column;
        padding: 8px 16px 16px;
        background: var(--bg-soft);
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-card);
    }

    .nav-menu[hidden] {
        display: none;
    }

    .nav-menu a {
        display: flex;
        align-items: center;
        min-height: 44px;
        padding: 10px 8px;
        border-radius: 8px;
        color: var(--text-muted);
        font-size: 1rem;
        font-weight: 500;
    }

    .nav-menu a:hover,
    .nav-menu a:focus-visible {
        background: var(--bg-card-hover);
        color: var(--text);
    }

    .nav-menu .nav-menu-signin {
        margin-top: 8px;
        padding-top: 16px;
        border-top: 1px solid var(--border);
        color: var(--accent-strong);
        font-weight: 600;
    }
}

/* ---------- Language switcher ---------- */
.lang-switcher {
    position: relative;
}

.lang-switcher-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.6rem;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition:
        border-color 0.15s ease,
        color 0.15s ease,
        background 0.15s ease;
}

.lang-switcher-toggle:hover {
    color: var(--text);
    border-color: var(--border-strong);
    background: var(--bg-card-hover);
}

.lang-switcher-toggle:focus-visible,
.lang-switcher-option:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.lang-switcher-flag {
    font-size: 1.05rem;
    line-height: 1;
}

.lang-switcher-caret {
    font-size: 0.7rem;
    transition: transform 0.15s ease;
}

.lang-switcher-toggle[aria-expanded='true'] .lang-switcher-caret {
    transform: rotate(180deg);
}

.lang-switcher-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 60;
    min-width: 172px;
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-card);
}

.lang-switcher-menu[hidden] {
    display: none;
}

.lang-switcher-option {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    width: 100%;
    padding: 0.5rem 0.6rem;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition:
        background 0.15s ease,
        color 0.15s ease;
}

.lang-switcher-option:hover {
    background: var(--bg-card-hover);
    color: var(--text);
}

.lang-switcher-option[aria-current='true'] {
    color: var(--accent-strong);
    font-weight: 600;
    background: var(--accent-glow);
}

/* Sous 480px la navbar est déjà serrée : on garde le drapeau, on retire le code langue */
@media (max-width: 480px) {
    .lang-switcher-code {
        display: none;
    }

    .lang-switcher-toggle {
        padding: 0.5rem;
    }
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    padding: 96px 0 80px;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-hero);
    z-index: 0;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 6px 12px;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.02);
    margin-bottom: 24px;
}

.eyebrow .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18);
}

/* ---------- Sections ---------- */
section {
    padding: 96px 0;
}

.section-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 56px;
}

.section-header h2 {
    font-size: clamp(1.8rem, 3.6vw, 2.6rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin: 0 0 16px;
    font-weight: 800;
}

.section-header p,
.section-lead {
    font-size: 1.05rem;
    color: var(--text-muted);
    margin: 0;
}

@media (min-width: 768px) {
    .section-header p.section-lead {
        white-space: nowrap;
    }
}

/* ---------- How it works ---------- */
.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.step {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
    position: relative;
}

.step h3 {
    margin: 0 0 8px;
    font-size: 1.15rem;
    font-weight: 700;
}

.step p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0;
}

@media (max-width: 860px) {
    .steps {
        grid-template-columns: 1fr;
    }
}

/* ---------- Pricing ---------- */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    align-items: start;
}

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

@media (max-width: 600px) {
    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 350px;
        margin: 0 auto;
    }
}

.pricing-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 24px;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
    box-shadow: var(--shadow-card);
}

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

.pricing-card.popular {
    border-color: var(--accent);
    box-shadow: 0 4px 20px var(--accent-glow);
    position: relative;
}

.pricing-card.popular::before {
    content: attr(data-popular);
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 12px;
    background: var(--accent);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    border-radius: 100px;
    white-space: nowrap;
}

.pricing-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.pricing-icon-free {
    background: rgba(56, 151, 152, 0.1);
}

.pricing-card.starter .pricing-icon {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
}

.pricing-card.pro .pricing-icon {
    background: linear-gradient(135deg, #389798 0%, #29768e 100%);
}

.pricing-card.enterprise .pricing-icon {
    background: linear-gradient(135deg, #29768e 0%, #25657d 100%);
}

.pricing-name {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text);
}

.pricing-price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 2px 4px;
    margin-bottom: 16px;
}

.pricing-amount {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.02em;
}

.pricing-period {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.pricing-amount-quote {
    font-size: 1.5rem;
    line-height: 2.5rem;
}

.pricing-was {
    font-size: 1rem;
    color: var(--text-muted);
}

.pricing-tagline {
    min-height: 2.6em;
    margin: 0 0 12px;
    font-size: 0.85rem;
    line-height: 1.3;
    color: var(--text-muted);
}

.pricing-note {
    margin: -12px 0 16px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Monthly / annual prices, switched by public/pricing-billing.js */
#pricing[data-billing='annual'] .is-monthly,
#pricing:not([data-billing='annual']) .is-annual {
    display: none;
}

.pricing-billing {
    display: flex;
    width: fit-content;
    margin: 0 auto 32px;
    padding: 4px;
    gap: 4px;
    border: 1px solid var(--border);
    border-radius: 100px;
    background: #fff;
}

.pricing-billing button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    border: 0;
    border-radius: 100px;
    background: transparent;
    color: var(--text-muted);
    font: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
}

.pricing-billing button[aria-pressed='true'] {
    background: var(--text);
    color: #fff;
}

.pricing-billing-save {
    padding: 2px 8px;
    border-radius: 100px;
    background: rgba(22, 163, 74, 0.12);
    color: var(--success);
    font-size: 0.75rem;
}

.pricing-billing button[aria-pressed='true'] .pricing-billing-save {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
}

.pricing-features {
    list-style: none;
    margin: 0 0 16px;
    padding: 0;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.pricing-features li {
    padding: 6px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pricing-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 600;
}

.pricing-cta {
    display: block;
    width: 100%;
    padding: 10px;
    text-align: center;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    text-decoration: none;
    transition:
        filter 0.2s ease,
        background 0.2s ease;
    box-sizing: border-box;
}

.pricing-card.free .pricing-cta {
    background: transparent;
    color: var(--accent-strong);
    border: 1px solid var(--border);
}

.pricing-card.starter .pricing-cta {
    background: rgba(22, 163, 74, 0.1);
    color: var(--success);
}

.pricing-card.pro .pricing-cta {
    background: var(--gradient-cta);
    color: #fff;
}

.pricing-card.enterprise .pricing-cta {
    background: rgba(41, 118, 142, 0.1);
    color: var(--accent-strong);
}

.pricing-card .pricing-cta:hover {
    filter: brightness(1.05);
}

.pricing-beta-banner {
    max-width: 720px;
    margin: -28px auto 36px;
    padding: 12px 18px;
    text-align: center;
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.45;
    color: #8a5a00;
    background: #fff8e8;
    border: 1px solid #f0d48a;
    border-radius: 12px;
}

/* ---------- Utilities & small tweaks ---------- */
.text-accent {
    color: var(--accent);
}

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

.center {
    text-align: center;
}

::selection {
    background: var(--accent-glow);
    color: var(--text);
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        animation-delay: 0ms !important;
        transition-duration: 0.01ms !important;
        transition-delay: 0ms !important;
        scroll-behavior: auto !important;
    }
}
