/* WhatAPI - Página de detalle */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

.wa-page {
    font-family: 'Inter', Arial, sans-serif;
    background: #ecf6fa;
    color: #0e2258;
    line-height: 1.6;
}

/* Header */
.wa-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid #dce8f5;
    box-shadow: 0 4px 20px rgba(5, 84, 242, 0.06);
}

.wa-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 12px 24px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
}

.wa-header-left { justify-self: start; }

.wa-header-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #5a6a85 !important;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    padding: 8px 14px;
    border-radius: 8px;
    background: #ecf6fa;
    border: 1px solid #dce8f5;
    transition: all 0.25s ease;
}

.wa-header-back:hover {
    color: #0554f2 !important;
    background: #ffffff;
    border-color: rgba(5, 84, 242, 0.3);
}

.wa-header-back i { font-size: 12px; }

.wa-header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    justify-self: center;
    transition: opacity 0.2s;
}

.wa-header-brand:hover { opacity: 0.9; }

.wa-brand-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.35);
    flex-shrink: 0;
}

.wa-brand-icon i { color: #fff; font-size: 20px; }

.wa-brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.wa-brand-text strong {
    color: #0e2258;
    font-size: 17px;
    font-weight: 800;
    letter-spacing: -0.3px;
}

.wa-brand-text small {
    color: #5a6a85;
    font-size: 11px;
    font-weight: 500;
    margin-top: 2px;
}

.wa-header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    justify-self: end;
}

.wa-header-actions a {
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    padding: 9px 18px;
    border-radius: 25px;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.wa-btn-ghost {
    color: #0554f2 !important;
    border: 1px solid #dce8f5;
    background: #ffffff;
}

.wa-btn-ghost:hover {
    border-color: rgba(5, 84, 242, 0.35);
    color: #0446d0 !important;
    background: #ecf6fa;
}

.wa-btn-green {
    background: linear-gradient(90deg, #25D366, #128C7E);
    color: #fff !important;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.wa-btn-green:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
    color: #fff !important;
}

.wa-btn-green i {
    font-size: 11px;
    transition: transform 0.2s;
}

.wa-btn-green:hover i { transform: translateX(3px); }

/* Hero */
.wa-page-hero {
    padding-top: 100px;
    padding-bottom: 80px;
    margin: 0 !important;
    border-radius: 0 !important;
    border: none !important;
    box-shadow: none !important;
}

.wa-page-hero .whatapi-info h2 {
    font-size: 32px;
}

/* Secciones claras */
.wa-section {
    padding: 70px 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.wa-section-header {
    text-align: center;
    margin-bottom: 50px;
}

.wa-section-header .wa-label {
    display: inline-block;
    color: #0554f2;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.wa-section-header h2 {
    font-size: 32px;
    font-weight: 800;
    color: #0e2258;
    margin-bottom: 12px;
}

.wa-section-header p {
    color: #5a6a85;
    font-size: 16px;
    max-width: 600px;
    margin: 0 auto;
}

/* Tarjetas blancas de contenido */
.wa-section-card {
    background: #ffffff;
    border-radius: 24px;
    margin: 0 auto 24px;
    max-width: 1160px;
    border: 1px solid #dce8f5;
    box-shadow: 0 8px 32px rgba(5, 84, 242, 0.06);
}

.wa-section-compact {
    padding-top: 0;
}

/* Feature cards */
.wa-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.wa-feature-card {
    background: #fff;
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #eee;
    transition: all 0.3s ease;
}

.wa-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 35px rgba(37, 211, 102, 0.12);
    border-color: rgba(37, 211, 102, 0.3);
}

.wa-feature-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 18px;
}

.wa-feature-icon.green { background: rgba(37, 211, 102, 0.12); color: #25D366; }
.wa-feature-icon.blue { background: rgba(5, 84, 242, 0.1); color: #0554f2; }
.wa-feature-icon.orange { background: rgba(255, 152, 0, 0.12); color: #ff9800; }
.wa-feature-icon.purple { background: rgba(103, 58, 183, 0.1); color: #673ab7; }

.wa-feature-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #0e2258;
}

.wa-feature-card p {
    font-size: 14px;
    color: #5a6a85;
    margin-bottom: 14px;
}

.wa-feature-card code {
    display: inline-block;
    background: #f0f2f5;
    color: #128C7E;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 6px;
    font-family: monospace;
}

.wa-feature-card ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.wa-feature-card ul li {
    font-size: 13px;
    color: #555;
    padding: 5px 0 5px 20px;
    position: relative;
}

.wa-feature-card ul li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #25D366;
    font-weight: 700;
}

/* Endpoints */
.wa-endpoints {
    position: relative;
    overflow: hidden;
    background: linear-gradient(165deg, #0e2258 0%, #0a1845 55%, #061230 100%);
    margin: 0 20px 24px;
    padding: 64px 40px 70px;
    border-radius: 24px;
    border: 1px solid rgba(5, 84, 242, 0.22);
    box-shadow: 0 12px 40px rgba(5, 84, 242, 0.14);
}

.wa-endpoints::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #0554f2, #25D366, #0554f2);
    opacity: 0.9;
}

.wa-endpoints::after {
    content: "";
    position: absolute;
    top: -60px;
    right: -40px;
    width: 260px;
    height: 260px;
    background: rgba(37, 211, 102, 0.1);
    border-radius: 50%;
    filter: blur(50px);
    pointer-events: none;
}

.wa-endpoints .wa-section-header {
    position: relative;
    z-index: 1;
}

.wa-endpoints .wa-label-dark {
    color: #25D366;
    background: rgba(37, 211, 102, 0.12);
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid rgba(37, 211, 102, 0.28);
}

.wa-endpoints .wa-section-header h2 {
    color: #ffffff;
}

.wa-endpoints .wa-section-header p {
    color: rgba(255, 255, 255, 0.72);
}

.wa-endpoint-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.wa-endpoint-card {
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 16px;
    padding: 24px;
    transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}

.wa-endpoint-card:hover {
    border-color: rgba(37, 211, 102, 0.45);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.wa-endpoint-method {
    display: inline-block;
    background: rgba(37, 211, 102, 0.15);
    color: #25D366;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 4px;
    font-family: monospace;
    margin-bottom: 10px;
}

.wa-endpoint-card h3 {
    color: #fff;
    font-size: 16px;
    margin-bottom: 8px;
}

.wa-endpoint-card p {
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
    margin-bottom: 14px;
}

.wa-endpoint-card pre {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 14px;
    font-size: 12px;
    color: #9ecbff;
    overflow-x: auto;
    margin: 0;
    font-family: "Courier New", monospace;
}

/* Steps */
.wa-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.wa-step {
    text-align: center;
    padding: 20px;
}

.wa-step-num {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: #fff;
    font-size: 20px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.wa-step h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 8px;
}

.wa-step p {
    font-size: 14px;
    color: #666;
}

/* CTA */
.wa-cta {
    background: linear-gradient(135deg, #0554f2 0%, #128C7E 50%, #25D366 100%);
    margin: 0 20px 24px;
    padding: 70px 40px;
    border-radius: 24px;
    text-align: center;
    box-shadow: 0 12px 40px rgba(5, 84, 242, 0.18);
}

.wa-cta h2 {
    color: #fff;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 12px;
}

.wa-cta p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    margin-bottom: 30px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.wa-cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.wa-cta .wa-btn-white {
    background: #fff;
    color: #128C7E !important;
    padding: 14px 32px;
    border-radius: 30px;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.3s;
}

.wa-cta .wa-btn-white:hover {
    transform: translateY(-2px);
}

.wa-cta .wa-btn-outline-white {
    color: #fff !important;
    border: 2px solid rgba(255, 255, 255, 0.5);
    padding: 12px 32px;
    border-radius: 30px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
}

.wa-cta .wa-btn-outline-white:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: #fff;
}

/* Footer */
.wa-footer {
    background: #0e2258;
    padding: 30px 40px;
    text-align: center;
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
}

.wa-footer a {
    color: #25D366;
    text-decoration: none;
}

.wa-tech-badges {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.wa-tech-badges span {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.7);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

@media (max-width: 991px) {
    .wa-header-inner {
        padding: 10px 16px;
        grid-template-columns: auto 1fr auto;
        gap: 10px;
    }

    .wa-brand-text small { display: none; }

    .wa-header-actions .wa-btn-ghost span,
    .wa-btn-ghost { padding: 9px 12px; }

    .wa-page-hero {
        padding-top: 90px;
        padding-bottom: 50px;
    }

    .wa-endpoints {
        margin: 0 12px 20px;
        padding: 50px 20px;
        border-radius: 18px;
    }

    .wa-section-card {
        margin: 0 12px 20px;
        border-radius: 18px;
    }

    .wa-cta {
        margin: 0 12px 20px;
        border-radius: 18px;
        padding: 50px 24px;
    }

    .wa-footer {
        border-top-left-radius: 18px;
        border-top-right-radius: 18px;
    }

    .wa-section { padding: 50px 20px; }
}

@media (max-width: 576px) {
    .wa-header-back span { display: none; }

    .wa-header-actions .wa-btn-ghost {
        display: none;
    }

    .wa-brand-text strong { font-size: 15px; }
}
