/* ============================================
   LinkAPI Landing Page — Design System Styles
   Paleta: Indigo (#6366f1) + Cinza (#71717a)
   ============================================ */

/* --- CSS Custom Properties (Tokens) --- */
:root {
    /* Primária — Indigo/Roxo */
    --primary-50: #eef2ff;
    --primary-100: #e0e7ff;
    --primary-200: #c7d2fe;
    --primary-300: #a5b4fc;
    --primary-400: #818cf8;
    --primary-500: #6366f1;
    --primary-600: #4f46e5;
    --primary-700: #4338ca;
    --primary-800: #3730a3;
    --primary-900: #312e81;

    /* Cinza */
    --gray-50: #fafafa;
    --gray-100: #f4f4f5;
    --gray-200: #e4e4e7;
    --gray-300: #d4d4d8;
    --gray-400: #a1a1aa;
    --gray-500: #71717a;
    --gray-600: #52525b;
    --gray-700: #3f3f46;
    --gray-800: #27272a;
    --gray-900: #18181b;

    /* Status */
    --success: #059669;
    --error: #dc2626;
    --warning: #f59e0b;
    --info: #2563eb;

    /* Semânticas */
    --bg: #ffffff;
    --bg-alt: var(--gray-50);
    --surface: #ffffff;
    --text: var(--gray-900);
    --text-secondary: var(--gray-600);
    --text-tertiary: var(--gray-500);
    --border: var(--gray-200);

    /* Gradiente  */
    --gradient-primary: linear-gradient(135deg, var(--primary-500) 0%, var(--primary-700) 100%);
    --gradient-text: linear-gradient(135deg, var(--primary-400) 0%, var(--primary-600) 50%, var(--primary-400) 100%);
    --gradient-glow: radial-gradient(ellipse at center, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    --gradient-dark: linear-gradient(135deg, var(--gray-900) 0%, #0f0f23 50%, var(--gray-900) 100%);

    /* Sombras */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.3);

    /* Radii */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;

    /* Transições */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: 150ms var(--ease);
    --transition-base: 200ms var(--ease);
    --transition-slow: 300ms var(--ease);
    --transition-slower: 500ms var(--ease);

    /* Layout */
    --container-max: 1200px;
    --section-padding: 6rem 0;
    --navbar-height: 72px;
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul,
ol {
    list-style: none;
}

/* --- Layout --- */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* --- Section Headers --- */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 4rem;
}

.section-label {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--primary-500);
    background: var(--primary-50);
    padding: 0.375rem 1rem;
    border-radius: var(--radius-full);
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(1.875rem, 4vw, 2.75rem);
    font-weight: 800;
    line-height: 1.2;
    color: var(--gray-900);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* --- Text Helpers --- */
.text-primary {
    color: var(--primary-500);
}

.text-gradient {
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: inherit;
    font-size: 0.9375rem;
    font-weight: 600;
    padding: 0.625rem 1.5rem;
    border-radius: var(--radius-lg);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition-base);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0);
    transition: background var(--transition-fast);
}

.btn:hover::after {
    background: rgba(255, 255, 255, 0.1);
}

.btn--primary {
    background: var(--gradient-primary);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

.btn--outline {
    background: transparent;
    color: var(--primary-500);
    border-color: var(--primary-200);
}

.btn--outline:hover {
    background: var(--primary-50);
    border-color: var(--primary-400);
    transform: translateY(-1px);
}

.btn--glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: var(--primary-500);
    border-color: rgba(99, 102, 241, 0.2);
}

.btn--glass:hover {
    background: rgba(99, 102, 241, 0.08);
    border-color: rgba(99, 102, 241, 0.4);
    transform: translateY(-2px);
}

.btn--lg {
    padding: 0.875rem 2rem;
    font-size: 1rem;
}

/* ========================================
   NAVBAR
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1100;
    height: var(--navbar-height);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid transparent;
    transition: all var(--transition-slow);
}

.navbar--scrolled {
    background: rgba(255, 255, 255, 0.95);
    border-bottom-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.navbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.navbar__logo {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 1.25rem;
    font-weight: 700;
    z-index: 10;
}

.navbar__logo-text {
    color: var(--gray-900);
}

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

.navbar__link {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color var(--transition-fast);
    position: relative;
}

.navbar__link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-500);
    border-radius: 1px;
    transition: width var(--transition-base);
}

.navbar__link:hover {
    color: var(--primary-500);
}

.navbar__link:hover::after {
    width: 100%;
}

.navbar__actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.navbar__hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 10;
}

.navbar__hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--gray-700);
    border-radius: 2px;
    transition: all var(--transition-base);
}

/* ========================================
   HERO
   ======================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--navbar-height);
    overflow: hidden;
}

.hero__bg-shapes {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.hero__shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
}

.hero__shape--1 {
    width: 600px;
    height: 600px;
    background: var(--primary-100);
    top: -200px;
    right: -100px;
    animation: float-slow 20s ease-in-out infinite;
}

.hero__shape--2 {
    width: 400px;
    height: 400px;
    background: var(--primary-200);
    bottom: -100px;
    left: -100px;
    animation: float-slow 15s ease-in-out infinite reverse;
}

.hero__shape--3 {
    width: 300px;
    height: 300px;
    background: rgba(99, 102, 241, 0.08);
    top: 40%;
    left: 50%;
    animation: float-slow 18s ease-in-out infinite;
}

.hero__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--primary-600);
    background: var(--primary-50);
    border: 1px solid var(--primary-200);
    padding: 0.375rem 1rem;
    border-radius: var(--radius-full);
    margin-bottom: 1.5rem;
}

.hero__badge-dot {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse-dot 2s ease-in-out infinite;
}

.hero__title {
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--gray-900);
    margin-bottom: 1.5rem;
}

.hero__subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 2rem;
    max-width: 520px;
}

.hero__ctas {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.hero__trust {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.hero__trust-avatars {
    display: flex;
}

.hero__trust-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    border: 2px solid white;
    margin-left: -8px;
}

.hero__trust-avatar:first-child {
    margin-left: 0;
}

.hero__trust-text {
    font-size: 0.875rem;
    color: var(--text-tertiary);
}

/* Hero Visual / Image */
.hero__visual {
    position: relative;
    display: flex;
    justify-content: center;
}

.hero__image-wrapper {
    position: relative;
}

.hero__image {
    border-radius: var(--radius-2xl);
    max-width: 520px;
    width: 100%;
}

/* Floating cards */
.hero__float-card {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.8);
    animation: float 6s ease-in-out infinite;
}

.hero__float-card strong {
    font-size: 0.8125rem;
    display: block;
    color: var(--gray-900);
}

.hero__float-card small {
    font-size: 0.6875rem;
    color: var(--text-tertiary);
}

.hero__float-card--1 {
    bottom: 15%;
    left: -30px;
    animation-delay: 0s;
}

.hero__float-card--2 {
    top: 15%;
    right: -20px;
    animation-delay: -3s;
}

.hero__float-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    flex-shrink: 0;
}

/* Scroll indicator */
.hero__scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.hero__scroll-mouse {
    width: 24px;
    height: 38px;
    border: 2px solid var(--gray-300);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    padding-top: 6px;
}

.hero__scroll-wheel {
    width: 4px;
    height: 8px;
    background: var(--primary-400);
    border-radius: 2px;
    animation: scroll-wheel 2s ease-in-out infinite;
}

/* ========================================
   SERVICES
   ======================================== */
.services {
    padding: var(--section-padding);
    background: var(--bg);
}

.services__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.service-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    padding: 2.5rem;
    transition: all var(--transition-slow);
    overflow: hidden;
}

.service-card:hover {
    border-color: var(--primary-200);
    box-shadow: var(--shadow-xl);
    transform: translateY(-4px);
}

.service-card__glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: var(--gradient-glow);
    opacity: 0;
    transition: opacity var(--transition-slower);
    pointer-events: none;
}

.service-card:hover .service-card__glow {
    opacity: 1;
}

.service-card__icon-wrapper {
    margin-bottom: 1.5rem;
}

.service-card__icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-card__icon--whatsapp {
    background: #dcfce7;
    color: #16a34a;
}

.service-card__icon--dev {
    background: var(--primary-100);
    color: var(--primary-500);
}

.service-card__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
}

.service-card__description {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.service-card__features {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-bottom: 2rem;
}

.service-card__features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

.service-card__image {
    border-radius: var(--radius-xl);
    width: 100%;
    border: 1px solid var(--gray-100);
}

/* ========================================
   ADVANTAGES
   ======================================== */
.advantages {
    padding: var(--section-padding);
    background: var(--bg-alt);
}

.advantages__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.advantage-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    text-align: center;
    transition: all var(--transition-slow);
}

.advantage-card:hover {
    border-color: var(--primary-200);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.advantage-card__icon-bg {
    width: 56px;
    height: 56px;
    margin: 0 auto 1.25rem;
    background: var(--primary-50);
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-base);
}

.advantage-card:hover .advantage-card__icon-bg {
    background: var(--primary-100);
    transform: scale(1.1);
}

.advantage-card__title {
    font-size: 1.0625rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.advantage-card__text {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ========================================
   HOW IT WORKS
   ======================================== */
.how-it-works {
    padding: var(--section-padding);
    background: var(--bg);
}

.steps {
    position: relative;
    max-width: 700px;
    margin: 0 auto 3rem;
}

.steps__line {
    position: absolute;
    left: 28px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary-200), var(--primary-400), var(--primary-200));
}

.step {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    padding: 1.5rem 0;
    position: relative;
}

.step__number {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: white;
    font-size: 1.25rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
    position: relative;
    z-index: 1;
}

.step__content {
    padding-top: 0.5rem;
}

.step__title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.375rem;
}

.step__text {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.how-it-works__image {
    max-width: 600px;
    margin: 0 auto;
    border-radius: var(--radius-2xl);
    overflow: hidden;
}

.how-it-works__image img {
    width: 100%;
    border-radius: var(--radius-2xl);
}

/* ========================================
   METRICS
   ======================================== */
.metrics {
    padding: 4rem 0;
    background: var(--gradient-dark);
    position: relative;
    overflow: hidden;
}

.metrics::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(99, 102, 241, 0.2) 0%, transparent 70%);
    pointer-events: none;
}

.metrics__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    position: relative;
    z-index: 1;
}

.metric {
    text-align: center;
}

.metric__number {
    display: block;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: #ffffff;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
    margin-bottom: 0.375rem;
}

.metric__label {
    font-size: 0.9375rem;
    color: var(--gray-400);
}

/* ========================================
   CTA SECTION
   ======================================== */
.cta-section {
    padding: var(--section-padding);
    background: var(--bg-alt);
}

.cta-section__inner {
    position: relative;
    background: var(--gradient-dark);
    border-radius: var(--radius-2xl);
    padding: 4rem 3rem;
    text-align: center;
    overflow: hidden;
}

.cta-section__glow {
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(99, 102, 241, 0.2) 0%, transparent 70%);
    pointer-events: none;
}

.cta-section__title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.cta-section__text {
    font-size: 1.125rem;
    color: var(--gray-400);
    max-width: 560px;
    margin: 0 auto 2rem;
    line-height: 1.7;
    position: relative;
    z-index: 1;
}

.cta-section__actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    position: relative;
    z-index: 1;
}

.cta-section__actions .btn--glass {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.2);
}

.cta-section__actions .btn--glass:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
    background: var(--gray-900);
    padding: 4rem 0 2rem;
}

.footer__grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer__brand .navbar__logo-text {
    color: #ffffff;
}

.footer__description {
    color: var(--gray-400);
    font-size: 0.875rem;
    line-height: 1.7;
    margin-top: 1rem;
    max-width: 320px;
}

.footer__col-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.footer__link {
    display: block;
    font-size: 0.875rem;
    color: var(--gray-400);
    padding: 0.375rem 0;
    transition: color var(--transition-fast);
}

.footer__link:hover {
    color: var(--primary-400);
}

.footer__bottom {
    border-top: 1px solid var(--gray-800);
    padding-top: 1.5rem;
    text-align: center;
    font-size: 0.8125rem;
    color: var(--gray-500);
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 1024px) {
    .hero__inner {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero__subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .hero__ctas {
        justify-content: center;
    }

    .hero__trust {
        justify-content: center;
    }

    .hero__float-card--1 {
        left: 10px;
    }

    .hero__float-card--2 {
        right: 10px;
    }

    .services__grid {
        grid-template-columns: 1fr;
    }

    .advantages__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .metrics__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem 1rem;
    }

    .footer__grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 4rem 0;
        --navbar-height: 64px;
    }

    .navbar__links {
        display: none;
        flex-direction: column;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        justify-content: center;
        align-items: center;
        gap: 2rem;
        z-index: 5;
    }

    .navbar__links.active {
        display: flex;
    }

    .navbar__links .navbar__link {
        font-size: 1.25rem;
    }

    .navbar__actions {
        display: none;
    }

    .navbar__hamburger {
        display: flex;
    }

    .navbar__hamburger.active span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .navbar__hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .navbar__hamburger.active span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

    .hero__ctas {
        flex-direction: column;
    }

    .hero__ctas .btn {
        width: 100%;
        justify-content: center;
    }

    .advantages__grid {
        grid-template-columns: 1fr;
    }

    .cta-section__inner {
        padding: 3rem 1.5rem;
    }

    .cta-section__actions {
        flex-direction: column;
        align-items: center;
    }

    .cta-section__actions .btn {
        width: 100%;
        justify-content: center;
    }

    .steps__line {
        left: 20px;
    }

    .step__number {
        width: 42px;
        height: 42px;
        font-size: 1rem;
    }
}