/* Extraido de application/views/reseller.php.
   Estaba en linea, asi que viajaba en cada visita sin poder cachearse. */

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
        html { scroll-behavior: smooth; }
        body { font-family: 'Montserrat', sans-serif; color: #1e293b; background: #f8fafc; -webkit-font-smoothing: antialiased; }
        a { text-decoration: none; color: inherit; }
        img { max-width: 100%; height: auto; display: block; }

        /* --- Topbar --- */
        .rs-topbar {
            position: fixed; top: 0; left: 0; right: 0; z-index: 100;
            height: 56px; padding: 0 clamp(16px, 4vw, 40px);
            background: rgba(255,255,255,0.95); backdrop-filter: blur(10px);
            border-bottom: 1px solid #e2e8f0;
            display: flex; align-items: center; justify-content: space-between;
        }
        .rs-topbar-logo { height: 28px; }
        .rs-topbar-nav { display: flex; align-items: center; gap: 24px; }
        .rs-topbar-link { font-size: 0.8rem; font-weight: 600; color: #475569; transition: color 0.2s; }
        .rs-topbar-link:hover { color: #0071d8; }
        .rs-topbar-cta {
            font-size: 0.8rem; font-weight: 600; color: #fff;
            background: linear-gradient(108deg, #0071d8 24%, #00d0ff 106%);
            padding: 8px 20px; border-radius: 50px; transition: opacity 0.2s;
        }
        .rs-topbar-cta:hover { opacity: 0.9; }

        /* --- Funcionalidades Dropdown --- */
        .rs-dropdown { position: relative; }
        .rs-dropdown-trigger {
            font-size: 0.8rem; font-weight: 600; color: #475569;
            cursor: pointer; display: flex; align-items: center; gap: 4px;
            transition: color 0.2s; background: none; border: none; font-family: inherit;
        }
        .rs-dropdown-trigger:hover { color: #0071d8; }
        .rs-dropdown-trigger .rs-chevron {
            font-size: 14px; transition: transform 0.25s;
        }
        .rs-dropdown.active .rs-chevron { transform: rotate(180deg); }
        .rs-mega {
            position: fixed; top: 56px; left: 0; width: 100vw;
            background: #fff; border-top: 2px solid #0071d8;
            box-shadow: 0 12px 40px rgba(0,0,0,0.12);
            padding: 20px 40px 24px;
            opacity: 0; visibility: hidden; transform: translateY(-8px);
            transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease;
            z-index: 998;
        }
        .rs-dropdown.active .rs-mega {
            opacity: 1; visibility: visible; transform: translateY(0);
        }
        .rs-mega-grid {
            max-width: 900px; margin: 0 auto;
            display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px;
        }
        .rs-mega-item {
            display: flex; align-items: center; gap: 10px;
            padding: 10px 14px; border-radius: 8px;
            transition: background 0.2s; text-decoration: none;
        }
        .rs-mega-item:hover { background: #f0f7ff; }
        .rs-mega-item i {
            font-size: 18px; color: #0071d8; width: 22px;
            text-align: center; flex-shrink: 0;
        }
        .rs-mega-item span {
            font-size: 13px; font-weight: 600; color: #334155;
            line-height: 1.3; white-space: nowrap;
        }
        .rs-mega-item:hover span { color: #0071d8; }
        .rs-mega-separator {
            max-width: 900px; margin: 8px auto 0;
            border-top: 1px solid #e8edf3; padding-top: 8px;
            display: flex; align-items: center; justify-content: flex-end; gap: 10px;
        }
        .rs-mega-separator .rs-mega-item { opacity: 0.75; }
        .rs-mega-separator .rs-mega-item:hover { opacity: 1; }
        /* --- Urgency Banner --- */
        .rs-urgency {
            margin-top: 56px;
            background: linear-gradient(90deg, #ff4d4f 0%, #ff7043 100%);
            padding: 10px 20px;
            text-align: center;
            color: #fff;
            font-size: 0.82rem;
            font-weight: 700;
            letter-spacing: 0.02em;
        }
        .rs-urgency i { vertical-align: middle; margin-right: 4px; font-size: 1rem; }

        /* --- Hero --- */
        .rs-hero {
            padding: 60px clamp(20px, 5vw, 60px) 56px;
            background: linear-gradient(160deg, #0a1628 0%, #0d2847 40%, #0071d8 100%);
            position: relative; overflow: hidden;
        }
        .rs-hero::before {
            content: ''; position: absolute; top: 5%; right: -8%;
            width: 700px; height: 700px;
            background: radial-gradient(circle, rgba(0,208,255,0.15) 0%, transparent 70%);
            border-radius: 50%;
        }
        .rs-hero-inner {
            max-width: 900px; margin: 0 auto; text-align: center;
            position: relative; z-index: 1;
        }
        .rs-hero-badge {
            display: inline-flex; align-items: center; gap: 6px;
            background: rgba(255,77,79,0.15); border: 1px solid rgba(255,77,79,0.4);
            padding: 6px 16px; border-radius: 50px;
            font-size: 0.72rem; font-weight: 700; color: #ff7043;
            text-transform: uppercase; letter-spacing: 0.08em;
            margin-bottom: 24px;
        }
        .rs-hero-badge i { font-size: 1rem; }
        .rs-hero h1 {
            font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 900;
            color: #fff; line-height: 1.15; margin-bottom: 20px;
        }
        .rs-hero h1 span {
            background: linear-gradient(90deg, #00d0ff, #00ff88);
            -webkit-background-clip: text; -webkit-text-fill-color: transparent;
        }
        .rs-hero-sub {
            font-size: 1.05rem; line-height: 1.7; color: rgba(255,255,255,0.75);
            max-width: 650px; margin: 0 auto 32px;
        }
        .rs-hero-stats {
            display: flex; justify-content: center; gap: 40px;
            margin-bottom: 36px;
        }
        .rs-hero-stat {
            text-align: center;
        }
        .rs-hero-stat strong {
            display: block; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 900;
            background: linear-gradient(90deg, #00d0ff, #00ff88);
            -webkit-background-clip: text; -webkit-text-fill-color: transparent;
        }
        .rs-hero-stat small {
            font-size: 0.75rem; color: rgba(255,255,255,0.5); font-weight: 600;
            text-transform: uppercase; letter-spacing: 0.05em;
        }
        .rs-hero-cta {
            display: inline-flex; align-items: center; gap: 8px;
            font-size: 1rem; font-weight: 700; color: #0a1628;
            background: linear-gradient(90deg, #00d0ff, #00ff88);
            padding: 16px 40px; border-radius: 50px;
            transition: transform 0.2s, box-shadow 0.2s;
        }
        .rs-hero-cta:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0,208,255,0.35); }
        .rs-hero-cta i { font-size: 1.2rem; }

        /* --- How it Works --- */
        .rs-how {
            max-width: 1000px; margin: 0 auto;
            padding: 64px clamp(20px, 5vw, 40px);
        }
        .rs-section-label {
            font-size: 0.7rem; font-weight: 700; letter-spacing: 0.1em;
            text-transform: uppercase; color: #0071d8; margin-bottom: 8px;
            text-align: center;
        }
        .rs-section-title {
            font-size: clamp(1.3rem, 2.5vw, 1.8rem); font-weight: 800;
            color: #0f172a; margin-bottom: 40px; text-align: center;
        }
        .rs-steps {
            display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
        }
        .rs-step {
            text-align: center; padding: 32px 20px; border-radius: 12px;
            border: 1px solid #e8edf3; background: #fff;
            transition: border-color 0.2s, box-shadow 0.2s;
        }
        .rs-step:hover {
            border-color: #0071d8; box-shadow: 0 6px 24px rgba(0,113,216,0.1);
        }
        .rs-step-num {
            width: 48px; height: 48px; margin: 0 auto 16px;
            background: linear-gradient(135deg, #0071d8, #00d0ff);
            border-radius: 50%; display: flex; align-items: center; justify-content: center;
            font-size: 1.2rem; font-weight: 800; color: #fff;
        }
        .rs-step h3 {
            font-size: 1rem; font-weight: 700; color: #0f172a; margin-bottom: 8px;
        }
        .rs-step p {
            font-size: 0.85rem; line-height: 1.6; color: #64748b;
        }

        /* --- Commission Tiers --- */
        .rs-tiers {
            background: #fff; border-top: 1px solid #e8edf3; border-bottom: 1px solid #e8edf3;
        }
        .rs-tiers-inner {
            max-width: 1000px; margin: 0 auto;
            padding: 64px clamp(20px, 5vw, 40px);
        }
        .rs-tiers-grid {
            display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
            margin-bottom: 48px;
        }
        .rs-tier {
            text-align: center; padding: 28px 16px; border-radius: 12px;
            border: 2px solid #e8edf3; background: #fff;
            transition: all 0.3s ease; position: relative;
        }
        .rs-tier:hover { transform: translateY(-4px); box-shadow: 0 8px 30px rgba(0,113,216,0.12); }
        .rs-tier--hot {
            border-color: #0071d8; background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%);
        }
        .rs-tier--hot::before {
            content: 'MÁS POPULAR';
            position: absolute; top: -11px; left: 50%; transform: translateX(-50%);
            background: linear-gradient(90deg, #0071d8, #00d0ff);
            color: #fff; font-size: 0.6rem; font-weight: 800; letter-spacing: 0.08em;
            padding: 3px 12px; border-radius: 50px;
        }
        .rs-tier-clients {
            font-size: 0.72rem; font-weight: 700; text-transform: uppercase;
            letter-spacing: 0.05em; color: #94a3b8; margin-bottom: 12px;
        }
        .rs-tier-percent {
            font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 900;
            background: linear-gradient(135deg, #0071d8, #00d0ff);
            -webkit-background-clip: text; -webkit-text-fill-color: transparent;
            line-height: 1; margin-bottom: 4px;
        }
        .rs-tier-label {
            font-size: 0.75rem; color: #64748b; font-weight: 600; margin-bottom: 16px;
        }
        .rs-tier-bar {
            height: 8px; background: #e8edf3; border-radius: 4px; overflow: hidden;
            margin-bottom: 12px;
        }
        .rs-tier-bar-fill {
            height: 100%; border-radius: 4px;
            background: linear-gradient(90deg, #0071d8, #00d0ff);
            transition: width 1s ease;
        }
        .rs-tier-earning {
            font-size: 0.8rem; font-weight: 700; color: #0f172a;
        }
        .rs-tier-earning small {
            font-size: 0.68rem; color: #94a3b8; font-weight: 500;
        }

        /* --- Revenue Chart --- */
        .rs-chart-section {
            max-width: 1000px; margin: 0 auto;
            padding: 64px clamp(20px, 5vw, 40px);
        }
        .rs-chart-container {
            background: #fff; border: 1px solid #e8edf3; border-radius: 12px;
            padding: 32px; margin-bottom: 32px;
        }
        .rs-chart-header {
            display: flex; justify-content: space-between; align-items: center;
            margin-bottom: 32px;
        }
        .rs-chart-header h3 {
            font-size: 1rem; font-weight: 700; color: #0f172a;
        }
        .rs-chart-legend {
            display: flex; gap: 16px;
        }
        .rs-chart-legend span {
            display: flex; align-items: center; gap: 6px;
            font-size: 0.72rem; font-weight: 600; color: #64748b;
        }
        .rs-chart-legend span::before {
            content: ''; width: 10px; height: 10px; border-radius: 2px;
        }
        .rs-chart-legend .legend-revenue::before { background: linear-gradient(135deg, #0071d8, #00d0ff); }
        .rs-chart-legend .legend-clients::before { background: #00d084; }
        .rs-chart {
            display: flex; align-items: flex-end; gap: 8px;
            height: 220px; padding-bottom: 32px;
            border-bottom: 1px solid #e8edf3;
            position: relative;
        }
        .rs-chart-col {
            flex: 1; display: flex; flex-direction: column;
            align-items: center; gap: 6px; height: 100%;
            justify-content: flex-end;
        }
        .rs-chart-val {
            font-size: 0.65rem; font-weight: 700; color: #0071d8;
        }
        .rs-chart-bar {
            width: 100%; max-width: 40px; border-radius: 4px 4px 0 0;
            background: linear-gradient(180deg, #0071d8, #00d0ff);
            transition: height 1s ease;
            position: relative;
        }
        .rs-chart-bar-clients {
            width: 60%; max-width: 24px; border-radius: 4px 4px 0 0;
            background: #00d084; position: absolute;
            right: -14px; bottom: 0;
        }
        .rs-chart-month {
            font-size: 0.68rem; font-weight: 600; color: #94a3b8;
            margin-top: 8px;
        }

        /* --- Revenue Examples --- */
        .rs-examples {
            display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
        }
        .rs-example {
            border: 1px solid #e8edf3; border-radius: 12px;
            padding: 24px; background: #fff;
        }
        .rs-example-header {
            display: flex; align-items: center; gap: 10px; margin-bottom: 16px;
        }
        .rs-example-icon {
            width: 40px; height: 40px; border-radius: 10px;
            display: flex; align-items: center; justify-content: center;
            font-size: 1.2rem; color: #fff;
        }
        .rs-example:nth-child(1) .rs-example-icon { background: linear-gradient(135deg, #64748b, #94a3b8); }
        .rs-example:nth-child(2) .rs-example-icon { background: linear-gradient(135deg, #0071d8, #00d0ff); }
        .rs-example:nth-child(3) .rs-example-icon { background: linear-gradient(135deg, #00d084, #00f5a0); }
        .rs-example-header h4 {
            font-size: 0.85rem; font-weight: 700; color: #0f172a;
        }
        .rs-example-header small {
            display: block; font-size: 0.7rem; color: #94a3b8; font-weight: 500;
        }
        .rs-example-rows { display: flex; flex-direction: column; gap: 8px; }
        .rs-example-row {
            display: flex; justify-content: space-between; align-items: center;
            padding: 8px 12px; border-radius: 6px; background: #f8fafc;
            font-size: 0.8rem;
        }
        .rs-example-row span:first-child { color: #64748b; font-weight: 500; }
        .rs-example-row span:last-child { color: #0f172a; font-weight: 700; }
        .rs-example-total {
            display: flex; justify-content: space-between; align-items: center;
            padding: 12px; border-radius: 8px; margin-top: 8px;
            background: linear-gradient(135deg, rgba(0,113,216,0.06), rgba(0,208,255,0.08));
            border: 1px solid rgba(0,113,216,0.15);
        }
        .rs-example-total span:first-child {
            font-size: 0.78rem; font-weight: 700; color: #0071d8;
        }
        .rs-example-total span:last-child {
            font-size: 1.1rem; font-weight: 900; color: #0071d8;
        }

        /* --- Benefits --- */
        .rs-benefits {
            background: linear-gradient(160deg, #0a1628 0%, #0d2847 40%, #0071d8 100%);
            padding: 64px clamp(20px, 5vw, 40px);
        }
        .rs-benefits-inner {
            max-width: 1000px; margin: 0 auto;
        }
        .rs-benefits .rs-section-label { color: #00d0ff; }
        .rs-benefits .rs-section-title { color: #fff; }
        .rs-benefits-grid {
            display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
        }
        .rs-benefit {
            padding: 28px 20px; border-radius: 12px;
            background: rgba(255,255,255,0.06);
            border: 1px solid rgba(255,255,255,0.1);
            transition: background 0.2s, border-color 0.2s;
        }
        .rs-benefit:hover {
            background: rgba(255,255,255,0.1);
            border-color: rgba(0,208,255,0.3);
        }
        .rs-benefit-icon {
            width: 44px; height: 44px; margin-bottom: 14px;
            background: linear-gradient(135deg, rgba(0,208,255,0.2), rgba(0,113,216,0.2));
            border-radius: 10px;
            display: flex; align-items: center; justify-content: center;
        }
        .rs-benefit-icon i { font-size: 1.3rem; color: #00d0ff; }
        .rs-benefit h4 {
            font-size: 0.92rem; font-weight: 700; color: #fff; margin-bottom: 6px;
        }
        .rs-benefit p {
            font-size: 0.82rem; line-height: 1.6; color: rgba(255,255,255,0.6);
        }

        /* --- FAQ --- */
        .rs-faq {
            max-width: 700px; margin: 0 auto;
            padding: 64px clamp(20px, 5vw, 40px);
        }
        .rs-faq-item {
            border-bottom: 1px solid #e8edf3;
            padding: 20px 0;
        }
        .rs-faq-q {
            font-size: 0.92rem; font-weight: 700; color: #0f172a;
            margin-bottom: 8px;
        }
        .rs-faq-a {
            font-size: 0.85rem; line-height: 1.7; color: #64748b;
        }

        /* --- Final CTA --- */
        .rs-final-cta {
            background: linear-gradient(135deg, #0071d8 0%, #00b4ff 100%);
            padding: 56px clamp(20px, 5vw, 40px);
            text-align: center;
        }
        .rs-final-cta h3 {
            font-size: clamp(1.3rem, 2.5vw, 1.8rem); font-weight: 900;
            color: #fff; margin-bottom: 12px;
        }
        .rs-final-cta p {
            font-size: 0.95rem; color: rgba(255,255,255,0.8); margin-bottom: 28px;
            max-width: 550px; margin-left: auto; margin-right: auto;
        }
        .rs-final-btn {
            display: inline-flex; align-items: center; gap: 8px;
            font-size: 1rem; font-weight: 700; color: #0071d8;
            background: #fff; padding: 16px 40px; border-radius: 50px;
            transition: transform 0.2s, box-shadow 0.2s;
        }
        .rs-final-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.15); }

        /* --- Footer --- */
        .rs-footer {
            background: linear-gradient(31deg, #0071d8 49%, #00d0ff 100%);
            padding: 24px; text-align: center;
        }
        .rs-footer p { color: rgba(255,255,255,0.85); font-size: 0.8rem; }
        .rs-footer a { color: #fff; font-weight: 600; }

        /* --- Responsive --- */
        @media (max-width: 820px) {
            .rs-steps { grid-template-columns: 1fr; gap: 16px; }
            .rs-tiers-grid { grid-template-columns: repeat(2, 1fr); }
            .rs-examples { grid-template-columns: 1fr; }
            .rs-benefits-grid { grid-template-columns: 1fr; }
            .rs-hero-stats { gap: 24px; }
            /* Doce columnas no caben en una pantalla estrecha. Que el grafico
               se desplace dentro de su propia caja en lugar de empujar toda
               la pagina: el desborde horizontal movia la portada entera.
               Solo aqui, para no sacar una barra de scroll en escritorio. */
            .rs-chart { height: 160px; overflow-x: auto; }
            .rs-topbar-nav .rs-topbar-link { display: none; }
            /* La barra pedia 468px en un movil de 390 y desbordaba la pagina.
               Se aprieta el espaciado y se reduce el logo; en ingles y
               portugues las etiquetas son mas largas que en espanol, asi que
               el margen tiene que salir de aqui, no del texto. */
            .rs-topbar { padding: 0 14px; }
            .rs-topbar-nav { gap: 14px; }
            .rs-topbar-logo { height: 24px; }
            .rs-topbar-cta { padding: 7px 14px; }
            .rs-mega {
                position: fixed; top: 56px; left: 0; right: 0;
                padding: 12px 16px; max-height: 70vh; overflow-y: auto;
            }
            .rs-mega-grid { grid-template-columns: 1fr; gap: 2px; }
            .rs-mega-item span { font-size: 14px; }
            .rs-mega-separator { margin: 4px 0 0; padding-top: 4px; }
        }
        @media (max-width: 480px) {
            .rs-tiers-grid { grid-template-columns: 1fr; }
            .rs-hero-stats { flex-direction: column; gap: 12px; }
            .rs-hero { padding-top: 40px; }
            .rs-chart { height: 130px; }
        }
        @media (prefers-reduced-motion: reduce) {
            *, *::before, *::after {
                animation-duration: 0.01ms !important;
                transition-duration: 0.01ms !important;
            }
        }
