/* ============================================================
   EQUIPO — CSS REDISEÑADO
   Playbill de Teatro de Élite × Luxury Dark Editorial
   ============================================================ */

:root {
    --gold:       #d4af37;
    --gold-light: #ffe58f;
    --gold-dark:  #8a7322;
    --red:        #6a0f0f;
    --red-accent: #ff3c3c;
    --silver:     #c0c0c0;
    --rose:       #e8829a;
    --cyan:       #00cfff;
    --bg:         #000;
    --card-bg:    rgba(14, 10, 8, 0.88);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    cursor: none !important;
}

html {
    color-scheme: dark;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--bg);
    background-image: radial-gradient(circle at bottom right, #6a0f0f, #000 60%);
    color: #fff;
    overflow-x: hidden;
}

canvas {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* ── HEADER ── */
header {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    background: rgba(0, 0, 0, .9);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 50px;
    z-index: 3002;
    box-shadow: 0 2px 8px rgba(255,255,255,.05);
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo img { width: 40px; height: 40px; border-radius: 50%; }
.logo span { font-size: 1.3rem; font-weight: 700; color: #fff; }
nav ul { list-style: none; display: flex; gap: 20px; align-items: center; }
nav ul li { position: relative; }
nav ul li a {
    color: #fff; text-decoration: none; font-weight: 500;
    position: relative; padding: 5px; transition: .3s;
}
nav ul li a:hover { color: var(--red-accent); }
nav ul li a::after {
    content: ""; position: absolute; left: 0; bottom: -5px;
    width: 0; height: 2px; background: var(--red-accent); transition: width .3s;
}
nav ul li a:hover::after { width: 100%; }

.submenu {
    display: none; position: absolute; top: 100%; left: 0;
    background: rgba(0,0,0,.95); padding: 10px 0;
    border-radius: 8px; min-width: 200px;
    box-shadow: 0 2px 10px rgba(0,0,0,.5); z-index: 25;
}
nav ul li:hover .submenu { display: block; }
.submenu li { padding: 5px 20px; }
.submenu li a {
    display: block; color: #fff; padding: 8px 10px;
    transition: .3s; position: relative; white-space: nowrap;
}
.submenu li a:hover {
    background: rgba(65,11,11,.8); border-radius: 5px; transform: translateX(3px);
}

/* Active states */
nav ul li.parent-active > a { color: var(--gold) !important; font-weight: 700; }
nav ul li.parent-active > a::after {
    content: ""; width: 100%; background: var(--red-accent);
    height: 2px; position: absolute; left: 0; bottom: -5px;
}
.submenu li a.active-page {
    background: #5c0c0c; color: #fff !important;
    border-radius: 10px; border-left: 5px solid var(--gold);
    margin: 5px 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,.3);
}

/* ── SECTION ── */
section {
    padding: 130px 40px 90px;
    max-width: 1200px;
    margin: auto;
    position: relative;
    z-index: 5;
    flex-grow: 1;
}

/* ── TEAM HERO ── */
.team-hero {
    text-align: center;
    padding: 0 0 55px;
}

.team-hero-eyebrow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-bottom: 16px;
}
.th-line {
    display: block; height: 1px; width: 70px;
    background: linear-gradient(90deg, transparent, var(--gold));
}
.team-hero-eyebrow .th-line:last-child {
    background: linear-gradient(90deg, var(--gold), transparent);
}
.th-label {
    font-family: 'Cinzel', serif;
    font-size: 0.78rem; color: var(--gold);
    letter-spacing: 5px; text-transform: uppercase;
    opacity: 0.65; display: flex; align-items: center; gap: 8px;
}

.team-hero-title {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    line-height: 1;
    margin-bottom: 18px;
    /* override de cualquier h2 global */
    font-size: inherit;
    color: inherit;
    text-shadow: none;
    letter-spacing: normal;
}
.th-sub {
    font-family: 'Cinzel', serif;
    font-size: 1rem; color: rgba(255,255,255,.3);
    letter-spacing: 8px; text-transform: uppercase; font-weight: 400;
}
.th-main {
    font-family: 'Cinzel', serif;
    font-size: clamp(3.5rem, 7vw, 6.5rem);
    font-weight: 700; letter-spacing: 4px; text-transform: uppercase;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 40%, var(--gold-dark) 70%, var(--gold) 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.team-hero-desc {
    font-size: 0.9rem;
    color: rgba(255,255,255,.38);
    max-width: 460px; margin: 0 auto;
    line-height: 1.75; letter-spacing: 0.2px;
}

/* ── SECTION LABEL ── */
.founders-label {
    display: flex; align-items: center; gap: 18px;
    margin-bottom: 32px;
}
.fl-line {
    flex: 1; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212,175,55,.2));
}
.founders-label .fl-line:last-child {
    background: linear-gradient(90deg, rgba(212,175,55,.2), transparent);
}
.fl-text {
    font-family: 'Cinzel', serif;
    font-size: 0.72rem; letter-spacing: 4px;
    text-transform: uppercase;
    color: rgba(212,175,55,.45);
    white-space: nowrap;
    display: flex; align-items: center; gap: 8px;
}

/* ── FOUNDERS ROW ── */
.founders-row {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

/* ── BASE CARD ── */
.member-card {
    background: var(--card-bg);
    border: 1px solid rgba(212,175,55,.12);
    border-radius: 18px;
    padding: 32px 24px 28px;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition:
        transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275),
        border-color 0.4s ease,
        box-shadow 0.4s ease;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    will-change: transform; /* Hardware Acceleration contra el Lag */
    transform: translateZ(0);
}

/* Light highlight en vez de ruido SVG (para no laguear el scroll) */
.member-card::before {
    content: "";
    position: absolute; inset: 0;
    background: radial-gradient(circle at top right, rgba(212,175,55,0.06), transparent 70%);
    border-radius: inherit;
    pointer-events: none; z-index: 0;
}
.member-card > * { position: relative; z-index: 1; }

.member-card:hover {
    transform: translateY(-10px);
    border-color: rgba(212,175,55,.45);
    box-shadow:
        0 22px 55px rgba(0,0,0,.65),
        0 0 0 1px rgba(212,175,55,.12),
        inset 0 1px 0 rgba(212,175,55,.08);
}

/* ── CARD FOUNDER (especial) ── */
.card-founder {
    width: 280px;
    border-color: rgba(212,175,55,.3);
    background: linear-gradient(160deg, rgba(25,18,8,.95), rgba(10,7,3,.98));
    box-shadow: 0 0 40px rgba(212,175,55,.08);
}
.card-founder:hover {
    box-shadow:
        0 22px 60px rgba(0,0,0,.7),
        0 0 50px rgba(212,175,55,.18),
        0 0 0 1px rgba(212,175,55,.3);
}

/* Anillo de glow animado en el fundador */
.card-glow-ring {
    position: absolute;
    inset: -1px;
    border-radius: 18px;
    background: conic-gradient(
        from 0deg,
        transparent 0deg,
        rgba(212,175,55,.5) 60deg,
        transparent 120deg,
        transparent 240deg,
        rgba(212,175,55,.3) 300deg,
        transparent 360deg
    );
    animation: spinRing 6s linear infinite;
    z-index: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
}
.card-founder:hover .card-glow-ring { opacity: 1; }

@keyframes spinRing {
    to { transform: rotate(360deg); }
}

/* Máscara interior para que el borde animado no tape el contenido */
.card-founder::after {
    content: "";
    position: absolute;
    inset: 1px;
    border-radius: 17px;
    background: linear-gradient(160deg, rgba(25,18,8,.98), rgba(10,7,3,1));
    z-index: 0;
}

/* Director */
.card-director {
    width: 260px;
    border-color: rgba(192,192,192,.2);
}
.card-director:hover {
    border-color: rgba(192,192,192,.5);
    box-shadow:
        0 22px 55px rgba(0,0,0,.65),
        0 0 30px rgba(192,192,192,.12);
}

/* ── FOTO WRAP ── */
.member-photo-wrap {
    position: relative;
    display: inline-flex;
    margin-bottom: 16px;
}

.member-photo {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid rgba(212,175,55,.3);
    background: #0a0a0a;
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
    display: block;
}

.card-founder .member-photo {
    width: 140px;
    height: 140px;
    border-color: rgba(212,175,55,.5);
    box-shadow: 0 0 25px rgba(212,175,55,.15);
}

.member-card:hover .member-photo {
    transform: scale(1.06);
    border-color: rgba(212,175,55,.7);
    box-shadow: 0 0 20px rgba(212,175,55,.2);
}

/* Overlay foto (ícono lupa al hover) */
.photo-overlay {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: rgba(0,0,0,.55);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: var(--gold);
    font-size: 1.2rem;
}
.member-photo-wrap:hover .photo-overlay { opacity: 1; }
.member-photo-wrap { cursor: pointer !important; }

/* ── BADGE DE ROL ── */
.member-badge {
    display: inline-block;
    font-family: 'Poppins', sans-serif;
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 3px 12px;
    border-radius: 20px;
    margin-bottom: 10px;
}
.badge-founder {
    background: rgba(212,175,55,.12);
    color: var(--gold);
    border: 1px solid rgba(212,175,55,.35);
}
.badge-director {
    background: rgba(192,192,192,.08);
    color: var(--silver);
    border: 1px solid rgba(192,192,192,.25);
}
.badge-actor {
    background: rgba(232,130,154,.08);
    color: var(--rose);
    border: 1px solid rgba(232,130,154,.22);
}
.badge-tech {
    background: rgba(0,207,255,.08);
    color: var(--cyan);
    border: 1px solid rgba(0,207,255,.22);
}

/* ── TEXTOS ── */
.member-name {
    font-family: 'Cinzel', serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
    line-height: 1.3;
}
.card-founder .member-name { font-size: 1.2rem; }

.member-role {
    font-family: 'Poppins', sans-serif;
    font-size: 0.78rem;
    color: rgba(212,175,55,.65);
    margin-bottom: 8px;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.member-title {
    font-family: 'Poppins', sans-serif;
    font-size: 0.8rem;
    color: rgba(255,255,255,.3);
    line-height: 1.5;
    font-style: italic;
}

/* ── BARRA INFERIOR ACENTO ── */
.card-bottom-accent {
    position: absolute;
    bottom: 0; left: 15%; right: 15%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    border-radius: 2px;
    opacity: 0.4;
    transition: opacity 0.4s ease, left 0.4s ease, right 0.4s ease;
}
.member-card:hover .card-bottom-accent { opacity: 1; left: 5%; right: 5%; }
.card-bottom-accent.accent-silver {
    background: linear-gradient(90deg, transparent, var(--silver), transparent);
}
.card-bottom-accent.accent-rose {
    background: linear-gradient(90deg, transparent, var(--rose), transparent);
}
.card-bottom-accent.accent-cyan {
    background: linear-gradient(90deg, transparent, var(--cyan), transparent);
}

/* ── ELENCO GRID ── */
.elenco-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    justify-items: stretch;
    align-items: start;
}

/* ── ZOOM MODAL ── */
.zoom-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.92);
    justify-content: center;
    align-items: center;
    z-index: 5000;
    backdrop-filter: blur(8px);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.zoom-modal.active {
    display: flex;
    opacity: 1;
}
.zoom-content {
    max-width: 85%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 14px;
    box-shadow: 0 0 60px rgba(212,175,55,.6), 0 0 30px rgba(212,175,55,.3);
    border: 4px solid var(--gold) !important;
    transform: scale(0.85);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.zoom-modal.active .zoom-content { transform: scale(1); }

.close-zoom {
    position: absolute;
    top: 28px; right: 35px;
    color: rgba(255,255,255,.6);
    font-size: 2.5rem;
    cursor: pointer !important;
    transition: color .3s, transform .3s;
    z-index: 5001;
    line-height: 1;
}
.close-zoom:hover { color: var(--gold); transform: rotate(90deg) scale(1.1); }

/* ── SOCIAL + FOOTER ── */
.social-links {
    position: fixed; bottom: 30px; left: 30px;
    display: flex; flex-direction: column;
    gap: 15px; z-index: 100;
}
.social-links a {
    width: 45px; height: 45px;
    background: rgba(255,255,255,.12); color: #fff;
    border-radius: 50%; display: flex; align-items: center;
    justify-content: center; text-decoration: none;
    font-size: 20px; transition: .3s; backdrop-filter: blur(5px);
}
.social-links a:hover {
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    color: #000; transform: scale(1.1);
    box-shadow: 0 0 15px var(--gold), 0 0 30px var(--gold-light);
}
footer {
    text-align: center; padding: 25px 10px;
    color: var(--gold); font-size: .9rem;
    width: 100%; margin-top: auto;
}

/* ── CURSOR ── */
.custom-cursor {
    position: fixed; top: 0; left: 0;
    width: 20px; height: 20px;
    pointer-events: none; z-index: 9999;
    transform: translate(-50%, -50%);
    display: flex; justify-content: center; align-items: center;
    transition: transform 0.1s linear;
}
.custom-cursor svg {
    width: 100%; height: 100%;
    filter: drop-shadow(0 0 5px rgba(212,175,55,.8));
}
@media (pointer: coarse) { .custom-cursor { display: none !important; } }

/* ── MAGIA / PARTÍCULA ── */
.magic-star {
    position: fixed; pointer-events: none;
    background: var(--gold); width: 4px; height: 4px;
    border-radius: 50%; box-shadow: 0 0 10px var(--gold-light);
    animation: fadeOut 1s linear forwards; z-index: 9999;
}
@keyframes fadeOut {
    0%  { opacity: 1; transform: scale(1) translateY(0); }
    100%{ opacity: 0; transform: scale(0) translateY(20px); }
}

/* ── SELECTION ── */
::selection {
    background: rgba(106,15,15,.8); color: #fff;
    text-shadow: 0 0 5px var(--gold), 0 0 10px var(--gold);
}
::-moz-selection {
    background: rgba(106,15,15,.8); color: #fff;
}

/* ── ANIMACIONES DE ENTRADA ── */
@keyframes cardRevealUp {
    from { opacity: 0; transform: translateY(30px); filter: blur(4px); }
    to   { opacity: 1; transform: translateY(0);    filter: blur(0); }
}

.team-hero { animation: cardRevealUp 0.7s cubic-bezier(0.2,.8,.2,1) both; }
.founders-label { animation: cardRevealUp 0.7s cubic-bezier(0.2,.8,.2,1) 0.1s both; }

.card-founder    { animation: cardRevealUp 0.7s cubic-bezier(0.2,.8,.2,1) 0.2s both; }
.card-director   { animation: cardRevealUp 0.7s cubic-bezier(0.2,.8,.2,1) 0.3s both; }

.elenco-grid .member-card:nth-child(1) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.35s both; }
.elenco-grid .member-card:nth-child(2) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.45s both; }
.elenco-grid .member-card:nth-child(3) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.55s both; }
.elenco-grid .member-card:nth-child(4) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.65s both; }
.elenco-grid .member-card:nth-child(5) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.75s both; }
.elenco-grid .member-card:nth-child(6) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.85s both; }
.elenco-grid .member-card:nth-child(7) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 0.95s both; }
.elenco-grid .member-card:nth-child(n+8) { animation: cardRevealUp 0.6s cubic-bezier(0.2,.8,.2,1) 1.05s both; }

/* ── RESPONSIVE ── */
@media (min-width: 768px) and (max-width: 1100px) {
    header { padding: 15px 20px; }
    nav ul { gap: 12px; }
    nav ul li a { font-size: 0.9rem; }
}

@media (max-width: 900px) {
    nav { display: none; }
    header { padding: 15px 20px; }
    section { padding: 100px 20px 70px; }

    .founders-row { gap: 20px; }
    .card-founder, .card-director { width: 100%; max-width: 320px; }

    .elenco-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}

@media (max-width: 600px) {
    .th-main { font-size: 3rem; }
    .team-hero-desc { font-size: 0.82rem; padding: 0 8px; }

    .founders-row { flex-direction: column; align-items: center; }
    .card-founder, .card-director { width: 100%; max-width: 100%; }

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

    .member-photo { width: 100px; height: 100px; }
    .card-founder .member-photo { width: 115px; height: 115px; }

    .social-links { display: none; }
    footer { padding: 20px 15px 28px; }
}
