body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background: #0B0F14;
    color: #E6EDF3;
}

canvas {
    position: fixed;
    top: 0;
    left: 0;
    z-index: -1;
}

/* ── Navbar ── */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 60px;
    background: rgba(8,12,18,0.92);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(0,114,206,0.15);
    box-shadow: 0 1px 40px rgba(0,0,0,0.5);
}

.navbar::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #0072CE 40%, #4A9EFF 60%, transparent);
}

.logo {
    height: 40px;
    margin-right: 10px;
}

.logo-container {
    display: flex;
    align-items: center;
    font-weight: 600;
}

nav a {
    margin-left: 22px;
    color: #C8D4E0;
    text-decoration: none;
    transition: color 0.3s, text-shadow 0.3s, transform 0.2s;
    position: relative;
    font-size: 0.96rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    animation: nav-idle-glow 4s ease-in-out infinite;
    animation-delay: calc(var(--ni, 0) * 0.4s);
}

@keyframes nav-idle-glow {
    0%, 100% { color: #C8D4E0; text-shadow: none; }
    50%       { color: #E6EDF3; text-shadow: 0 0 10px rgba(0,114,206,0.35); }
}

nav a::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #0072CE, #4A9EFF);
    transition: width 0.3s ease;
    border-radius: 2px;
    box-shadow: 0 0 6px rgba(0,114,206,0.6);
}

nav a:hover {
    color: #FFFFFF;
    text-shadow: 0 0 16px rgba(0,114,206,0.9), 0 0 32px rgba(0,114,206,0.4);
    transform: translateY(-2px);
    animation: none;
}

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

/* ── Hero ── */
.hero {
    text-align: center;
    padding: 100px 20px 80px;
    min-height: 92vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
}

.hero-logo-wrap {
    position: relative;
}

.hero-logo {
    width: 76%;
    max-width: 520px;
    height: auto;
    display: block;
    animation: hero-logo-breathe 3.5s ease-in-out infinite;
}

@keyframes hero-logo-breathe {
    0%, 100% {
        opacity: 1;
        filter: drop-shadow(0 0 16px rgba(0,114,206,0.35))
                drop-shadow(0 0 40px rgba(0,114,206,0.12));
        transform: scale(1);
    }
    50% {
        opacity: 0.88;
        filter: drop-shadow(0 0 36px rgba(0,114,206,0.85))
                drop-shadow(0 0 80px rgba(0,114,206,0.4))
                drop-shadow(0 0 120px rgba(0,114,206,0.15));
        transform: scale(1.01);
    }
}

.hero-tagline-row {
    display: flex;
    align-items: center;
    gap: 14px;
}

.hero-bracket {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.6rem;
    color: rgba(0,114,206,0.5);
    font-weight: 300;
    animation: bracket-fade 3.5s ease-in-out infinite;
}

@keyframes bracket-fade {
    0%, 100% { opacity: 0.4; }
    50%       { opacity: 1; }
}

.hero-tagline {
    margin: 0;
    font-family: 'JetBrains Mono', monospace;
    font-size: clamp(1.3rem, 3vw, 2.1rem);
    font-weight: 700;
    letter-spacing: 0.18em;
    color: #E6EDF3;
    text-transform: uppercase;
    border-right: 3px solid #0072CE;
    white-space: nowrap;
    overflow: hidden;
    animation: tagline-cursor 0.7s step-end infinite;
    min-width: 2px;
    background: linear-gradient(135deg, #ffffff 0%, #80BFFF 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 20px rgba(0,114,206,0.6));
}

.hero-tagline.typed {
    animation: tagline-glow 2.5s ease-in-out infinite alternate;
    border-right: none;
}

@keyframes tagline-cursor {
    0%, 100% { border-color: #0072CE; }
    50%       { border-color: transparent; }
}

@keyframes tagline-glow {
    from { filter: drop-shadow(0 0 12px rgba(0,114,206,0.5)); }
    to   { filter: drop-shadow(0 0 28px rgba(0,114,206,0.9)) drop-shadow(0 0 50px rgba(0,114,206,0.4)); }
}

.hero-sub {
    display: flex;
    align-items: center;
    gap: 10px;
}

.hero-arrow {
    font-size: 1.4rem;
    color: #0072CE;
    font-family: 'JetBrains Mono', monospace;
    animation: arrow-pulse 1.8s ease-in-out infinite;
}

@keyframes arrow-pulse {
    0%, 100% { opacity: 0.4; transform: translateX(0); }
    50%       { opacity: 1;   transform: translateX(3px); }
}

.hero-sub-text {
    color: #6C7A89;
    font-size: 0.95rem;
    font-style: italic;
    letter-spacing: 0.02em;
}

.hero-badges {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.hero-badge {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    color: #AAB4C3;
    background: rgba(0,114,206,0.07);
    border: 1px solid rgba(0,114,206,0.2);
    padding: 5px 14px;
    border-radius: 20px;
    transition: background 0.3s, border-color 0.3s, color 0.3s;
}

.hero-badge:hover {
    background: rgba(0,114,206,0.15);
    border-color: rgba(0,114,206,0.5);
    color: #E6EDF3;
}

/* ── Sections ── */
.section-card {
    max-width: 1100px;
    margin: 60px auto;
    padding: 40px;
    background: #121821;
    border: 1px solid #1E2A38;
    border-radius: 12px;
}

.section-card h2 {
    margin-top: 0;
    font-size: 1.5rem;
    letter-spacing: 0.04em;
    color: #E6EDF3;
    border-left: 3px solid #0072CE;
    padding-left: 14px;
    margin-bottom: 24px;
}

/* ── Grid 2 (Misión/Visión flip cards) ── */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-top: 28px;
}

.sobre-flip {
    height: 290px;
    perspective: 900px;
    cursor: pointer;
}

.sobre-flip-inner {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}

.sobre-flip:hover .sobre-flip-inner {
    transform: rotateY(180deg);
}

.sobre-front,
.sobre-back {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 12px;
    padding: 28px 24px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 1px solid #1E2A38;
    background: #0F141B;
    gap: 14px;
}

.sobre-front {
    background: linear-gradient(160deg, #0F141B 60%, #101825 100%);
}

.sobre-back {
    transform: rotateY(180deg);
    align-items: flex-start;
    text-align: left;
    justify-content: flex-start;
    background: #0B0F14;
    border-color: rgba(0,114,206,0.3);
    box-shadow: inset 0 0 40px rgba(0,114,206,0.04);
    gap: 12px;
}

.sobre-icon {
    flex-shrink: 0;
    filter: drop-shadow(0 0 8px rgba(0,114,206,0.4));
    animation: icon-glow 3s ease-in-out infinite;
}

@keyframes icon-glow {
    0%, 100% { filter: drop-shadow(0 0 6px rgba(0,114,206,0.3)); }
    50%       { filter: drop-shadow(0 0 16px rgba(0,114,206,0.7)); }
}

.sobre-front h3,
.sobre-back h3 {
    margin: 0;
    font-size: 1.15rem;
    color: #E6EDF3;
    letter-spacing: 0.04em;
}

.sobre-back h3 {
    color: #4A9EFF;
    font-size: 0.95rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(0,114,206,0.2);
    padding-bottom: 10px;
    width: 100%;
}

.sobre-back p {
    margin: 0;
    font-size: 0.88rem;
    color: #AAB4C3;
    line-height: 1.7;
}

.sobre-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
}

.sobre-tags span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.62rem;
    letter-spacing: 0.08em;
    color: #0072CE;
    background: rgba(0,114,206,0.09);
    border: 1px solid rgba(0,114,206,0.2);
    padding: 3px 9px;
    border-radius: 20px;
}

.sobre-front .flip-hint {
    font-size: 0.68rem;
    color: #2A3A4E;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.05em;
    transition: color 0.3s;
}

.sobre-flip:hover .sobre-front .flip-hint {
    color: #0072CE;
}

/* ── Anuncios Pending ── */
.pending-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 40px 20px;
    border: 1px dashed #1E2A38;
    border-radius: 10px;
    text-align: center;
    color: #6C7A89;
}

.pending-icon-wrap {
    opacity: 0.7;
}

.pending-tag {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    color: #0072CE;
    background: rgba(0,114,206,0.08);
    padding: 4px 10px;
    border-radius: 4px;
    border: 1px solid rgba(0,114,206,0.2);
}

/* ── Events 3D Carousel ── */
.events-scene {
    perspective: 1100px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 440px;
    position: relative;
    gap: 24px;
}

.events-3d-carousel {
    width: 280px;
    height: 380px;
    position: relative;
    transform-style: preserve-3d;
}

.event-face {
    position: absolute;
    width: 280px;
    height: 380px;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #1E2A38;
    background: linear-gradient(135deg, #0F141B 0%, #121821 100%);
    transform: rotateY(calc(var(--i) * 90deg)) translateZ(370px);
}

.event-face img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.event-face:hover img {
    transform: scale(1.04);
}

.event-face.no-img {
    display: flex;
    align-items: center;
    justify-content: center;
}

.event-face.no-img::before {
    content: attr(data-caption);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    color: #0072CE;
    opacity: 0.5;
}

.event-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 32px 16px 16px;
    background: linear-gradient(transparent, rgba(11,15,20,0.92));
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #E6EDF3;
}

.carousel-nav-btn {
    background: rgba(18,24,33,0.9);
    border: 1px solid #1E2A38;
    color: #AAB4C3;
    font-size: 1.8rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s, color 0.3s, border-color 0.3s;
    flex-shrink: 0;
    line-height: 1;
    padding: 0;
    z-index: 10;
}

.carousel-nav-btn:hover {
    background: rgba(0,114,206,0.15);
    border-color: #0072CE;
    color: #0072CE;
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #1E2A38;
    cursor: pointer;
    transition: background 0.3s, transform 0.3s;
}

.dot.active {
    background: #0072CE;
    transform: scale(1.3);
}

/* ── Writeups ── */
.writeups-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
}

.writeup-card {
    background: #0F141B;
    border: 1px solid #1E2A38;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s;
    display: flex;
    flex-direction: column;
}

.writeup-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(0, 114, 206, 0.14);
    border-color: rgba(0, 114, 206, 0.35);
}

.pdf-cover {
    height: 160px;
    background: linear-gradient(135deg, #0B0F14 0%, #121821 100%);
    border-bottom: 1px solid #1E2A38;
    position: relative;
    overflow: hidden;
}

.pdf-cover.preview {
    height: 180px;
}

.pdf-cover.preview iframe {
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.pdf-cover-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 8px;
}

.cover-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.15em;
    color: #0072CE;
    background: rgba(0,114,206,0.1);
    padding: 3px 8px;
    border-radius: 4px;
    border: 1px solid rgba(0,114,206,0.2);
}

.cover-topic {
    font-size: 0.78rem;
    color: #6C7A89;
}

.writeup-info {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.writeup-tag {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    color: #6C7A89;
}

.writeup-info h4 {
    margin: 0;
    font-size: 0.95rem;
    color: #E6EDF3;
    line-height: 1.3;
}

.writeup-desc {
    font-size: 0.8rem;
    color: #6C7A89;
    margin: 0;
    flex: 1;
    line-height: 1.5;
}

.writeup-actions {
    display: flex;
    gap: 8px;
    margin-top: 4px;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 0.78rem;
    background: #0072CE;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s, transform 0.2s;
    font-weight: 600;
}

.btn-sm:hover {
    background: #0059a0;
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border: 1px solid #0072CE;
    color: #0072CE;
}

.btn-outline:hover {
    background: rgba(0,114,206,0.12);
}

/* ── Team Flip Cards ── */
.team-carousel {
    overflow: hidden;
    margin: 0 -20px;
    padding: 20px 0;
    cursor: default;
}

.team-track {
    display: flex;
    gap: 20px;
    animation: team-scroll 50s linear infinite;
    width: max-content;
}

.team-track:hover {
    animation-play-state: paused;
}

@keyframes team-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.member-card {
    width: 240px;
    height: 340px;
    flex-shrink: 0;
    perspective: 900px;
    cursor: pointer;
}

.member-inner {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

.member-card:hover .member-inner {
    transform: rotateY(180deg);
}

.member-front,
.member-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 12px;
    padding: 20px;
    box-sizing: border-box;
    background: #0F141B;
    border: 1px solid #1E2A38;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
}

.member-back {
    transform: rotateY(180deg);
    align-items: flex-start;
    text-align: left;
    overflow-y: auto;
    gap: 0;
    background: #0B0F14;
    border-color: rgba(0,114,206,0.25);
}

.member-back::-webkit-scrollbar { width: 3px; }
.member-back::-webkit-scrollbar-track { background: transparent; }
.member-back::-webkit-scrollbar-thumb { background: #0072CE; border-radius: 2px; }

.member-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(0,114,206,0.2), rgba(0,114,206,0.05));
    border: 1.5px solid rgba(0,114,206,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: 700;
    color: #0072CE;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.member-role-tag {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    letter-spacing: 0.1em;
    color: #0072CE;
    background: rgba(0,114,206,0.1);
    padding: 3px 8px;
    border-radius: 4px;
    border: 1px solid rgba(0,114,206,0.2);
    text-transform: uppercase;
}

.member-front h4,
.member-back h4 {
    margin: 4px 0 2px;
    font-size: 1rem;
    color: #E6EDF3;
}

.member-handle {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    color: #6C7A89;
}

.member-preview {
    font-size: 0.75rem;
    color: #AAB4C3;
    margin: 4px 0 0;
    line-height: 1.5;
}

.flip-hint {
    margin-top: auto;
    font-size: 0.68rem;
    color: #1E2A38;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.05em;
    transition: color 0.3s;
}

.member-card:hover .flip-hint {
    color: #0072CE;
}

.bio-block {
    padding: 10px 0;
    border-bottom: 1px solid #1E2A38;
    width: 100%;
}

.bio-block:last-child {
    border-bottom: none;
}

.bio-label {
    display: block;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    letter-spacing: 0.12em;
    color: #0072CE;
    margin-bottom: 5px;
}

.bio-block p {
    margin: 0;
    font-size: 0.78rem;
    color: #AAB4C3;
    line-height: 1.55;
}

/* ── Join Section ── */
.center {
    text-align: center;
}

.btn {
    background: #003B70;
    padding: 13px 28px;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    display: inline-block;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s;
    font-weight: 600;
    letter-spacing: 0.03em;
    margin-top: 8px;
}

.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(0, 59, 112, 0.5);
    background: #0059a0;
}

/* ── Terminal ── */
.terminal-desc {
    font-size: 0.82rem;
    color: #6C7A89;
    margin-bottom: 16px;
}

.terminal-desc code {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    color: #0072CE;
    background: rgba(0,114,206,0.08);
    padding: 2px 6px;
    border-radius: 4px;
}

.terminal {
    background: #080C10;
    border-radius: 10px;
    border: 1px solid #1E2A38;
    overflow: hidden;
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.terminal:focus-within {
    box-shadow: 0 0 0 2px rgba(0, 114, 206, 0.25);
    border-color: rgba(0, 114, 206, 0.45);
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: #0B0F14;
    border-bottom: 1px solid #1E2A38;
}

.terminal-dots {
    display: flex;
    gap: 6px;
}

.dot-red   { width: 11px; height: 11px; border-radius: 50%; background: #FF5F56; }
.dot-yellow{ width: 11px; height: 11px; border-radius: 50%; background: #FFBD2E; }
.dot-green { width: 11px; height: 11px; border-radius: 50%; background: #27C93F; }

.terminal-title {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.72rem;
    color: #6C7A89;
    letter-spacing: 0.05em;
    flex: 1;
    text-align: center;
}

.terminal-output {
    padding: 16px 20px 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    line-height: 1.7;
    min-height: 160px;
    max-height: 280px;
    overflow-y: auto;
    color: #AAB4C3;
}

.terminal-output::-webkit-scrollbar { width: 4px; }
.terminal-output::-webkit-scrollbar-track { background: transparent; }
.terminal-output::-webkit-scrollbar-thumb { background: #1E2A38; border-radius: 2px; }

.terminal-input-line {
    display: flex;
    align-items: center;
    padding: 8px 20px 14px;
    gap: 10px;
}

.prompt-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    color: #0072CE;
    white-space: nowrap;
    font-weight: 600;
}

.terminal-input-line input {
    flex: 1;
    background: transparent;
    border: none;
    color: #E6EDF3;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    padding: 0;
    outline: none;
    caret-color: #0072CE;
}

/* Terminal output colors */
.t-blue   { color: #4A9EFF; }
.t-green  { color: #3DDC84; }
.t-yellow { color: #FFD166; }
.t-red    { color: #FF5F56; }
.t-gray   { color: #6C7A89; }
.t-cmd    { color: #E6EDF3; }
.t-prompt { color: #0072CE; font-weight: 600; }
.t-dim    { color: #3A4758; }
.t-flag   { color: #3DDC84; font-weight: 700; letter-spacing: 0.05em; }

/* ── Footer ── */
footer {
    text-align: center;
    padding: 48px 40px 36px;
    color: #6C7A89;
    border-top: 1px solid #1E2A38;
}

.socials {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 28px;
}

.social-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #6C7A89;
    text-decoration: none;
    transition: color 0.3s, transform 0.3s, filter 0.3s;
    width: 60px;
}

.social-link svg {
    width: 28px;
    height: 28px;
    transition: transform 0.3s ease;
}

.social-link span {
    font-size: 0.65rem;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.06em;
    color: #3A4758;
    transition: color 0.3s;
}

.social-link:hover {
    transform: translateY(-5px);
}

.social-link:hover span {
    color: currentColor;
}

/* Colores por red social al hover */
.social-link[aria-label="Instagram"]:hover {
    color: #E1306C;
    filter: drop-shadow(0 0 8px rgba(225,48,108,0.5));
}
.social-link[aria-label="LinkedIn"]:hover {
    color: #0A66C2;
    filter: drop-shadow(0 0 8px rgba(10,102,194,0.5));
}
.social-link[aria-label="GitHub"]:hover {
    color: #E6EDF3;
    filter: drop-shadow(0 0 8px rgba(230,237,243,0.3));
}
.social-link[aria-label="Discord"]:hover {
    color: #5865F2;
    filter: drop-shadow(0 0 8px rgba(88,101,242,0.5));
}
.social-link[aria-label="WhatsApp"]:hover {
    color: #25D366;
    filter: drop-shadow(0 0 8px rgba(37,211,102,0.5));
}

/* ── Scroll reveal ── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

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

/* ── Responsive ── */
/* ── Hamburger (oculto en desktop) ── */
.nav-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    z-index: 110;
}

.nav-hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: #AAB4C3;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s;
}

.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); background: #0072CE; }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); background: #0072CE; }

/* ── Tap-to-flip en touch ── */
@media (hover: none) {
    .member-card:hover .member-inner      { transform: none; }
    .sobre-flip:hover .sobre-flip-inner   { transform: none; }
    .member-card.flipped .member-inner    { transform: rotateY(180deg); }
    .sobre-flip.flipped .sobre-flip-inner { transform: rotateY(180deg); }

    .flip-hint,
    .sobre-front .flip-hint {
        content: "toca para ver";
        color: #2A3A4E;
    }
}

/* ── Tablet (≤ 900px) ── */
@media (max-width: 900px) {
    .navbar {
        padding: 14px 24px;
        position: relative;
    }

    .nav-hamburger {
        display: flex;
    }

    nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(8,12,18,0.98);
        border-bottom: 1px solid rgba(0,114,206,0.2);
        padding: 8px 0 16px;
        backdrop-filter: blur(14px);
        z-index: 100;
        box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    }

    nav.open {
        display: flex;
    }

    nav a {
        margin: 0;
        padding: 12px 28px;
        font-size: 0.9rem;
        border-bottom: 1px solid rgba(30,42,56,0.5);
        animation: none;
        letter-spacing: 0.08em;
        width: 100%;
        box-sizing: border-box;
    }

    nav a:last-child { border-bottom: none; }

    .hero {
        min-height: 85vh;
        padding: 80px 20px 60px;
    }

    .hero-logo {
        width: 85%;
        max-width: 340px;
    }

    .hero-tagline {
        font-size: clamp(1rem, 4vw, 1.6rem);
        letter-spacing: 0.12em;
    }

    .hero-bracket { font-size: 1.3rem; }

    .section-card {
        margin: 24px 14px;
        padding: 22px;
    }

    .section-card h2 {
        font-size: 1.25rem;
    }

    .grid-2 {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .sobre-flip { height: 280px; }

    .team-carousel { margin: 0 -10px; }
    .team-track    { animation-duration: 60s; }

    .member-card { width: 220px; height: 330px; }

    .events-scene {
        height: 380px;
        gap: 12px;
    }

    .events-3d-carousel { width: 250px; height: 320px; }

    .event-face {
        width: 250px;
        height: 320px;
        transform: rotateY(calc(var(--i) * 90deg)) translateZ(310px);
    }

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

    .socials { gap: 12px; }
}

/* ── Mobile (≤ 600px) ── */
@media (max-width: 600px) {
    .navbar { padding: 12px 18px; }

    .hero {
        min-height: auto;
        padding: 72px 16px 50px;
        gap: 20px;
    }

    .hero-content { gap: 20px; }

    .hero-logo {
        width: 88%;
        max-width: 280px;
    }

    .hero-tagline-row { gap: 8px; }

    .hero-tagline {
        font-size: clamp(0.85rem, 5.5vw, 1.2rem);
        letter-spacing: 0.08em;
    }

    .hero-bracket { font-size: 1rem; }

    .hero-sub { gap: 6px; }
    .hero-sub-text { font-size: 0.82rem; }

    .hero-badges { gap: 7px; }
    .hero-badge  { font-size: 0.62rem; padding: 4px 10px; }

    .section-card {
        margin: 16px 10px;
        padding: 18px 16px;
    }

    .section-card h2 { font-size: 1.1rem; }

    /* Sobre flip — más alto para que el texto quepa */
    .sobre-flip { height: 310px; }

    .sobre-front, .sobre-back { padding: 20px 16px; }

    .sobre-back p { font-size: 0.83rem; }

    /* Team */
    .team-carousel { margin: 0 -8px; }
    .team-track    { animation-duration: 75s; }
    .member-card   { width: 195px; height: 315px; }

    .member-front, .member-back { padding: 16px 14px; }
    .member-avatar { width: 48px; height: 48px; font-size: 0.78rem; }
    .member-front h4, .member-back h4 { font-size: 0.9rem; }
    .bio-block p { font-size: 0.74rem; }

    /* Eventos */
    .events-scene {
        height: 300px;
        gap: 8px;
    }

    .events-3d-carousel { width: 200px; height: 260px; }

    .event-face {
        width: 200px;
        height: 260px;
        transform: rotateY(calc(var(--i) * 90deg)) translateZ(245px);
    }

    .carousel-nav-btn {
        width: 34px;
        height: 34px;
        font-size: 1.3rem;
    }

    .event-caption { font-size: 0.78rem; padding: 24px 12px 12px; }

    /* Writeups */
    .writeups-grid { grid-template-columns: 1fr; }
    .pdf-cover     { height: 130px; }

    /* Terminal */
    .terminal-output {
        font-size: 0.72rem;
        min-height: 120px;
        max-height: 220px;
    }

    .terminal-input-line {
        flex-wrap: wrap;
        gap: 4px;
        padding: 8px 14px 12px;
    }

    .prompt-label { font-size: 0.72rem; }

    .terminal-input-line input { font-size: 0.72rem; min-width: 0; }

    /* Footer */
    .socials { gap: 10px; }
    .social-link { width: 50px; }
    .social-link svg { width: 24px; height: 24px; }
}

/* ── Muy pequeño (≤ 400px) ── */
@media (max-width: 400px) {
    .hero-tagline { font-size: 0.78rem; letter-spacing: 0.05em; }
    .hero-bracket { display: none; }

    .member-card { width: 175px; height: 300px; }

    .events-3d-carousel { width: 175px; height: 230px; }
    .event-face {
        width: 175px;
        height: 230px;
        transform: rotateY(calc(var(--i) * 90deg)) translateZ(215px);
    }

    .sobre-flip { height: 320px; }
}

/* ── PDF Modal ── */
.pdf-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(5,8,12,0.88);
    backdrop-filter: blur(6px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.pdf-modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.pdf-modal-box {
    background: #0B0F14;
    border: 1px solid rgba(0,114,206,0.3);
    border-radius: 14px;
    width: 100%;
    max-width: 900px;
    height: 85vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(0,0,0,0.7), 0 0 0 1px rgba(0,114,206,0.1);
    transform: scale(0.96) translateY(10px);
    transition: transform 0.25s ease;
}

.pdf-modal-overlay.active .pdf-modal-box {
    transform: scale(1) translateY(0);
}

.pdf-modal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    background: #080C10;
    border-bottom: 1px solid #1E2A38;
    flex-shrink: 0;
}

.pdf-modal-dots {
    display: flex;
    gap: 6px;
}

.pdf-modal-title {
    flex: 1;
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    color: #6C7A89;
    letter-spacing: 0.05em;
}

.pdf-modal-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255,95,86,0.12);
    border: 1px solid rgba(255,95,86,0.3);
    color: #FF5F56;
    cursor: pointer;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
    padding: 0;
}

.pdf-modal-close:hover {
    background: rgba(255,95,86,0.25);
    transform: scale(1.1);
}

.pdf-modal-body {
    flex: 1;
    overflow: hidden;
}

.pdf-modal-body iframe {
    width: 100%;
    height: 100%;
    display: block;
}

@media (max-width: 600px) {
    .pdf-modal-box {
        height: 90vh;
        border-radius: 10px;
    }

    .hero-tagline {
        font-size: 1rem;
        letter-spacing: 0.1em;
    }

    .hero-bracket {
        font-size: 1.1rem;
    }
}
