/* ============================================================
   RedKing OS — web pública (landing)
   Reutiliza los MISMOS tokens que la app para que web y app
   parezcan el mismo producto. Tema oscuro por defecto; el claro
   se activa con <html data-theme="light">.
   ============================================================ */
:root {
    color-scheme: dark;
    --bg-primary: #0f0f1a;
    --bg-secondary: #1a1a2e;
    --bg-card: rgba(255, 255, 255, 0.04);
    --bg-inset: rgba(255, 255, 255, 0.03);
    --border-glass: rgba(255, 255, 255, 0.08);
    --border-glass-hover: rgba(255, 255, 255, 0.15);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --shadow-soft: rgba(0, 0, 0, 0.2);
    --accent: #f59e0b;
    --accent-glow: rgba(245, 158, 11, 0.25);
    --gold-hi: #fff3c4;
    --gold-1: #f2cd68;
    --gold-2: #d9a02f;
    --gold-3: #a86a17;
    --gold-text: #b9a06a;
    --green: #10b981;
    --red: #ef4444;
    --font-brand: 'Cinzel', Georgia, 'Times New Roman', serif;
    --radius: 16px;
    --radius-sm: 10px;
}
:root[data-theme="light"] {
    color-scheme: light;
    --bg-primary: #eef1f6;
    --bg-secondary: #ffffff;
    --bg-card: rgba(16, 24, 40, 0.035);
    --bg-inset: rgba(16, 24, 40, 0.025);
    --border-glass: rgba(16, 24, 40, 0.12);
    --border-glass-hover: rgba(16, 24, 40, 0.22);
    --text-primary: #0f172a;
    --text-secondary: #46536b;
    --text-muted: #6b7891;
    --shadow-soft: rgba(16, 24, 40, 0.08);
    --gold-hi: #d2a12c;
    --gold-1: #b07c17;
    --gold-2: #96620f;
    --gold-3: #6d4407;
    --gold-text: #8a7443;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', -apple-system, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color .25s ease, color .25s ease;
}
a { color: var(--accent); }
.wrap { max-width: 1060px; margin: 0 auto; padding: 0 20px; }

/* ── Cabecera ─────────────────────────────────────────────── */
.cab {
    position: sticky; top: 0; z-index: 20;
    background: color-mix(in srgb, var(--bg-primary) 88%, transparent);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-glass);
}
.cab__fila { display: flex; align-items: center; gap: 14px; padding: 12px 0; }
.marca { display: flex; align-items: center; gap: 10px; font-family: var(--font-brand); font-weight: 700; letter-spacing: .04em; }
.marca__ico { font-size: 1.4rem; }
.cab nav { display: flex; align-items: center; gap: 18px; margin-left: auto; flex-wrap: wrap; }
.cab nav a { color: var(--text-secondary); text-decoration: none; font-size: .95rem; }
.cab nav a:hover { color: var(--accent); }
.cab__cta { margin-left: 0; }
.cab__menu {
    display: none; width: 44px; height: 44px; align-items: center; justify-content: center;
    border: 1px solid var(--border-glass); border-radius: 10px; background: transparent;
    color: var(--text-primary); font-size: 1.25rem; line-height: 1; cursor: pointer;
}
.tema {
    background: transparent; border: 1px solid var(--border-glass); color: var(--text-secondary);
    border-radius: 999px; padding: 6px 12px; cursor: pointer; font-size: .85rem;
}
.tema:hover { color: var(--accent); border-color: var(--accent); }

/* ── Botones ──────────────────────────────────────────────── */
.boton {
    display: inline-block; padding: 12px 22px; border-radius: var(--radius-sm);
    font-weight: 600; text-decoration: none; border: 1px solid transparent; cursor: pointer;
    font-family: inherit; font-size: 1rem;
}
.boton--principal { background: linear-gradient(135deg, var(--accent), #f97316); color: #fff; box-shadow: 0 4px 20px var(--accent-glow); }
.boton--principal:hover { transform: translateY(-2px); }
.boton--fantasma { border-color: var(--border-glass); color: var(--text-primary); background: transparent; }
.boton--fantasma:hover { border-color: var(--accent); color: var(--accent); }
.boton--grande { padding: 15px 28px; font-size: 1.05rem; }
.boton[disabled] { opacity: .55; cursor: not-allowed; transform: none; }

/* ── Hero ─────────────────────────────────────────────────── */
.hero { padding: 72px 0 56px; background: linear-gradient(180deg, var(--accent-glow) 0%, transparent 70%); }
.hero h1 { font-size: 2.7rem; line-height: 1.15; letter-spacing: -.02em; margin: 0 0 18px; }
.hero p.entrada { font-size: 1.15rem; color: var(--text-secondary); max-width: 46rem; margin: 0 0 26px; }
.acciones { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.nota-hero { font-size: .9rem; color: var(--text-muted); margin: 14px 0 0; }

/* ── Secciones ────────────────────────────────────────────── */
section { padding: 56px 0; }
section.alt { background: var(--bg-secondary); border-top: 1px solid var(--border-glass); border-bottom: 1px solid var(--border-glass); }
h2 { font-size: 1.8rem; margin: 0 0 10px; letter-spacing: -.01em; }
.sub { color: var(--text-secondary); margin: 0 0 26px; max-width: 46rem; }
.rejilla { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.tarjeta { border: 1px solid var(--border-glass); border-radius: var(--radius); padding: 22px; background: var(--bg-card); }
.tarjeta h3 { font-size: 1.05rem; margin: 0 0 8px; }
.tarjeta p { color: var(--text-secondary); font-size: .95rem; margin: 0; }
.paso__num {
    width: 34px; height: 34px; border-radius: 50%; margin-bottom: 10px;
    background: linear-gradient(135deg, var(--accent), #f97316); color: #fff;
    display: grid; place-items: center; font-weight: 800;
}

/* ── Demo del dashboard ───────────────────────────────────── */
.demo { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); max-width: 860px; margin: 0 auto; }
.demo__card { border: 1px solid var(--border-glass); border-radius: var(--radius); padding: 18px; background: var(--bg-card); }
.demo__label { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); font-weight: 700; }
.demo__valor { font-size: 1.7rem; font-weight: 800; margin-top: 4px; }
.v-green { color: var(--green); } .v-accent { color: var(--accent); }

/* ── Precios ──────────────────────────────────────────────── */
.precios { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); align-items: start; }
.plan { border: 1px solid var(--border-glass); border-radius: var(--radius); padding: 24px; background: var(--bg-card); position: relative; }
.plan--destacado { border-color: var(--accent); box-shadow: 0 12px 30px var(--accent-glow); }
.plan__cinta { position: absolute; top: -12px; left: 20px; background: var(--accent); color: #1a1a2e; font-size: .72rem; font-weight: 800; padding: 4px 10px; border-radius: 999px; }
.plan h3 { margin: 0 0 6px; font-size: 1.05rem; }
.plan__precio { font-size: 2rem; font-weight: 800; letter-spacing: -.02em; }
.plan__precio small { font-size: .95rem; font-weight: 500; color: var(--text-secondary); }
.plan ul { margin: 14px 0 20px; padding-left: 20px; color: var(--text-secondary); font-size: .95rem; }
.plan li { margin: 6px 0; }

/* Interruptor mensual / anual */
.periodo {
    display: inline-flex; gap: 4px; padding: 4px; margin: 0 0 22px;
    background: var(--bg-inset); border: 1px solid var(--border-glass); border-radius: 999px;
}
.periodo__btn {
    border: 0; background: transparent; color: var(--text-secondary);
    font: inherit; font-weight: 600; font-size: .92rem; cursor: pointer;
    padding: 8px 18px; border-radius: 999px;
}
.periodo__btn:hover { color: var(--accent); }
.periodo__btn--activo { background: var(--accent); color: #1a1a2e; }
.periodo__btn span { opacity: .85; font-weight: 600; }
.plan__mes { display: block; font-size: .85rem; font-weight: 500; color: var(--text-secondary); font-style: normal; margin-top: 2px; }

/* ── FAQ / legal ──────────────────────────────────────────── */
details.faq { border: 1px solid var(--border-glass); border-radius: var(--radius); padding: 14px 18px; margin-bottom: 10px; background: var(--bg-card); }
details.faq summary { cursor: pointer; font-weight: 600; }
details.faq p { margin: 10px 0 0; color: var(--text-secondary); }
.legal { max-width: 780px; }
.legal h1 { font-size: 2rem; margin-bottom: 6px; }
.legal h2 { font-size: 1.25rem; margin-top: 30px; }
.legal p, .legal li { color: var(--text-secondary); }
.legal .aviso { background: var(--accent-glow); border: 1px solid var(--accent); border-radius: 10px; padding: 14px 16px; color: var(--text-primary); font-size: .95rem; }

/* ── Pie ──────────────────────────────────────────────────── */
.pie { border-top: 1px solid var(--border-glass); padding: 34px 0 44px; color: var(--text-muted); font-size: .9rem; }
.pie__fila { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.pie a { color: var(--text-secondary); text-decoration: none; margin-right: 14px; }
.pie a:hover { color: var(--accent); }

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 640px) {
    .hero { padding: 48px 0 36px; }
    .hero h1 { font-size: 2rem; }
    .cab { position: relative; }
    .cab__fila { flex-wrap: wrap; }
    .cab__menu { display: inline-flex; }
    .cab nav { display: none; }
    .cab__tema { margin-left: auto; }
    .cab--abierto nav {
        display: flex; position: absolute; top: 100%; left: 0; right: 0; margin: 0;
        flex-direction: column; align-items: flex-start; gap: 12px;
        background: var(--bg-secondary); border-bottom: 1px solid var(--border-glass);
        padding: 14px 20px; box-shadow: 0 10px 24px var(--shadow-soft);
    }
    .cab--abierto nav a { font-size: 1rem; }
}
