/* ============================================
   APSAVI — Design System
   Tokens oficiales de marca
   ============================================ */

:root {
    /* Fondos */
    --bg-primary: #0A0A12;
    --bg-secondary: #12121C;

    /* Glass */
    --glass-surface: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.15);

    /* Marca */
    --brand-primary: #FFD700;
    --brand-pressed: #FFC400;
    --brand-glow: rgba(255, 215, 0, 0.35);

    /* Gradientes */
    --gradient-sunset: linear-gradient(135deg, #FFD700, #FF6B35);
    --gradient-night: linear-gradient(135deg, #7C3AED, #1E1B4B);
    --gradient-social: linear-gradient(135deg, #FF6B9D, #FFD700);

    /* Estado */
    --success: #4ADE80;
    --error: #F87171;
    --warning: #FB923C;
    --info: #60A5FA;

    /* Texto */
    --text-primary: #FFFFFF;
    --text-secondary: #A1A1B5;
    --text-on-gold: #0A0A12;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
}

/* ============================================
   Orbes de fondo (gradient-night difuminado)
   ============================================ */

.orbs {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    background: var(--gradient-night);
    filter: blur(120px);
    opacity: 0.45;
    animation: orbFloat 18s ease-in-out infinite alternate;
}

.orb-1 {
    width: 520px;
    height: 520px;
    top: -160px;
    left: -140px;
}

.orb-2 {
    width: 440px;
    height: 440px;
    top: 40%;
    right: -180px;
    animation-delay: -6s;
}

.orb-3 {
    width: 380px;
    height: 380px;
    bottom: -140px;
    left: 30%;
    animation-delay: -12s;
}

@keyframes orbFloat {
    from {
        transform: translate(0, 0) scale(1);
    }
    to {
        transform: translate(40px, -40px) scale(1.08);
    }
}

main, header, footer {
    position: relative;
    z-index: 1;
}

/* ============================================
   Header
   ============================================ */

header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(10, 10, 18, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.9rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    color: var(--text-primary);
}

.brand svg {
    width: 34px;
    height: 34px;
}

.brand span {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: 0.12em;
}

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

.nav-links {
    display: contents;
}

nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.3s;
    position: relative;
    white-space: nowrap;
}

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

nav a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--brand-primary);
    transition: width 0.3s;
}

nav a:hover::after {
    width: 100%;
}

/* ============================================
   Botones
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.9rem 1.9rem;
    border-radius: 14px;
    border: none;
    font-family: inherit;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.25s, box-shadow 0.25s, background 0.25s;
}

.btn-gold {
    background: var(--brand-primary);
    color: var(--text-on-gold);
    box-shadow: 0 0 40px var(--brand-glow);
}

.btn-gold:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 60px var(--brand-glow);
}

.btn-gold:active {
    background: var(--brand-pressed);
    transform: translateY(-1px);
}

.btn-glass {
    background: var(--glass-surface);
    color: var(--text-primary);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.14);
    transform: translateY(-3px);
}

.btn-sm {
    padding: 0.55rem 1.2rem;
    font-size: 0.9rem;
    border-radius: 12px;
}

/* ============================================
   Tarjetas glass
   ============================================ */

.glass-card {
    background: var(--glass-surface);
    border: 1px solid var(--glass-border);
    border-radius: 22px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 2rem;
}

/* ============================================
   Utilidades de texto
   ============================================ */

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

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

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

/* ============================================
   Secciones genéricas
   ============================================ */

.section {
    padding: 6rem 2rem;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 3.5rem;
}

.section-header h2 {
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.25;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

.eyebrow {
    display: inline-block;
    background: var(--glass-surface);
    border: 1px solid var(--glass-border);
    color: var(--brand-primary);
    padding: 0.4rem 1.1rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 1.2rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* Animación de entrada al hacer scroll */
.reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   Footer
   ============================================ */

footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--glass-border);
    padding: 4rem 2rem 2rem;
}

.footer-content {
    max-width: 1100px;
    margin: 0 auto 2.5rem;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
}

.footer-brand p {
    color: var(--text-secondary);
    margin-top: 1rem;
    max-width: 340px;
}

.footer-col h4 {
    font-size: 0.85rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--brand-primary);
    margin-bottom: 1.1rem;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 0.7rem;
}

.footer-col a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-col a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    max-width: 1100px;
    margin: 0 auto;
    border-top: 1px solid var(--glass-border);
    padding-top: 1.8rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.6rem;
    color: var(--text-secondary);
    font-size: 0.88rem;
}

/* ============================================
   Páginas de contenido (help / legal)
   ============================================ */

.page-hero {
    padding: 9rem 2rem 3rem;
    text-align: center;
}

.page-hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.2rem);
    font-weight: 800;
    margin-bottom: 0.8rem;
}

.page-hero p {
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
}

.content-page {
    max-width: 820px;
    margin: 0 auto;
    padding: 1rem 2rem 5rem;
}

.content-block {
    margin-bottom: 2rem;
    scroll-margin-top: 100px;
}

.content-block h2 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.content-block h3 {
    font-size: 1.08rem;
    font-weight: 700;
    margin: 1.4rem 0 0.5rem;
    color: var(--brand-primary);
}

.content-block p,
.content-block li {
    color: var(--text-secondary);
    margin-bottom: 0.6rem;
}

.content-block ul,
.content-block ol {
    padding-left: 1.4rem;
    margin-bottom: 0.8rem;
}

.content-block strong {
    color: var(--text-primary);
}

.content-block a {
    color: var(--brand-primary);
    text-decoration: none;
}

.content-block a:hover {
    text-decoration: underline;
}

.notice {
    border-left: 3px solid var(--warning);
    background: rgba(251, 146, 60, 0.08);
    border-radius: 0 14px 14px 0;
    padding: 1rem 1.3rem;
    margin: 1.2rem 0;
}

.notice p {
    margin: 0;
}

.toc {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.7rem;
    margin: 2rem auto 3rem;
    max-width: 820px;
    padding: 0 2rem;
}

.toc a {
    background: var(--glass-surface);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    color: var(--text-primary);
    text-decoration: none;
    padding: 0.5rem 1.1rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: border-color 0.3s, color 0.3s;
}

.toc a:hover {
    border-color: var(--brand-primary);
    color: var(--brand-primary);
}

/* ============================================
   Páginas placeholder (deep links: evento / usuario)
   ============================================ */

.placeholder-wrap {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.2rem;
    padding: 7.5rem 1.5rem 4rem;
}

.placeholder-card {
    width: 100%;
    max-width: 480px;
    position: relative;
    overflow: hidden;
    text-align: center;
}

/* Contenido parcialmente visible (modo lectura) */
.blurred {
    filter: blur(7px);
    user-select: none;
    pointer-events: none;
}

.blur-soft {
    filter: blur(4px);
    user-select: none;
    pointer-events: none;
}

/* Difuminado inferior que "corta" el contenido */
.fade-lock {
    position: relative;
}

.fade-lock::after {
    content: '';
    position: absolute;
    inset: auto 0 0 0;
    height: 70%;
    background: linear-gradient(180deg, transparent, rgba(10, 10, 18, 0.92));
    pointer-events: none;
}

.lock-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: var(--glass-surface);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.ph-tag {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-on-gold);
    background: var(--brand-primary);
    border-radius: 999px;
    padding: 0.25rem 0.8rem;
    margin-bottom: 0.9rem;
}

.placeholder-card h1 {
    font-size: 1.7rem;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 0.5rem;
}

.ph-meta {
    color: var(--text-secondary);
    font-size: 0.92rem;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.4rem 1.1rem;
    margin-bottom: 1.2rem;
}

.ph-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.2rem;
}

.avatar-lg {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-on-gold);
    background: var(--gradient-sunset);
    box-shadow: 0 0 45px var(--brand-glow);
}

.ph-stats {
    display: flex;
    justify-content: center;
    gap: 2.2rem;
    margin: 1.2rem 0;
}

.ph-stats .stat b {
    display: block;
    font-size: 1.25rem;
}

.ph-stats .stat span {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.attendees {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 1.1rem 0;
}

.attendees .dot {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--gradient-night);
    border: 2px solid var(--bg-primary);
    margin-left: -10px;
}

.attendees .dot:first-child {
    margin-left: 0;
}

.attendees em {
    font-style: normal;
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-left: 0.7rem;
}

.ph-divider {
    height: 1px;
    background: var(--glass-border);
    margin: 1.4rem 0;
}

.ph-cta-note {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-top: 0.9rem;
}

.ph-actions {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    align-items: center;
}

.ph-actions .btn {
    width: 100%;
    max-width: 320px;
}

.ph-footer-link {
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-decoration: none;
}

.ph-footer-link:hover {
    color: var(--text-primary);
}

/* ============================================
   Responsive
   ============================================ */

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

    .section {
        padding: 4rem 1.4rem;
    }

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

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}
