/* =========================================================
   CIFRA Forense — Tema WordPress
   Paleta: Negro + Rojo/Ámbar forense
   ========================================================= */

:root {
    --bg-primary: #0a0e17;
    --bg-secondary: #0f1624;
    --bg-tertiary: #141c2e;
    --bg-card: #111827;
    --border-color: #1e2d45;
    --border-accent: #00ff8833;

    --text-primary: #e8f0fe;
    --text-secondary: #a0b4cc;
    --text-muted: #5a7a99;

    --accent-red: #00ff88;
    --accent-red-dark: #00cc66;
    --accent-amber: #00ff88;
    --accent-amber-dark: #00cc66;
    --accent-glow: rgba(0, 255, 136, 0.35);

    --green: #00ff88;
    --green-dim: #00cc66;
    --green-glow: rgba(0, 255, 136, 0.15);
    --blue: #00aaff;
    --blue-glow: rgba(0, 170, 255, 0.15);

    --success: #00c853;
    --warning: #ffb300;
    --danger: #ff1744;

    --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, Monaco, monospace;
    --font-display: 'Rajdhani', 'Orbitron', sans-serif;
    --font-body: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;

    --shadow-sm: 0 2px 8px rgba(0,0,0,0.6);
    --shadow-md: 0 6px 20px rgba(0,0,0,0.7);
    --shadow-red: 0 0 20px rgba(225, 6, 0, 0.25);

    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;

    --container: 1200px;
    --container-wide: 1400px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    padding: 0;
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    background-image:
        radial-gradient(circle at 15% 20%, rgba(0, 255, 136, 0.05) 0%, transparent 35%),
        radial-gradient(circle at 85% 80%, rgba(0, 170, 255, 0.04) 0%, transparent 40%),
        linear-gradient(180deg, #0a0e17 0%, #060a12 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-amber); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--accent-red); }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    color: var(--text-primary);
    letter-spacing: 0.5px;
    margin: 0 0 .8em;
    font-weight: 700;
    line-height: 1.2;
}
h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.4rem; }

p { margin: 0 0 1em; color: var(--text-secondary); }

/* ---------- Layout ---------- */
.container { width: min(100% - 2rem, var(--container)); margin-inline: auto; }
.container-wide { width: min(100% - 2rem, var(--container-wide)); margin-inline: auto; }

.section { padding: 5rem 0; position: relative; }
.section-dark { background: var(--bg-secondary); }
.section-darker { background: #050505; }

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(10, 10, 10, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    padding: 0.8rem 0;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }

.site-branding { display: flex; align-items: center; gap: 0.8rem; }
.site-logo { height: 48px; width: auto; }
.site-title {
    font-family: 'Courier New', 'Consolas', monospace !important;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 2px;
    margin: 0;
    text-transform: uppercase;
}
.site-title a { color: inherit; text-decoration: none; }
.site-title a:hover { color: var(--green); }
.site-tagline {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    letter-spacing: 1px;
}

/* ---------- Navigation ---------- */
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 0; flex-wrap: nowrap; align-items: center; }
.main-nav a {
    display: inline-block;
    padding: 0.5rem 0.6rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    position: relative;
    white-space: nowrap;
}
.main-nav a:hover,
.main-nav .current-menu-item > a {
    color: var(--green);
    background: rgba(0, 255, 136, 0.08);
}
.main-nav a::before {
    content: '>';
    color: var(--green);
    margin-right: 3px;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.main-nav a:hover::before { opacity: 1; }

.nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--accent-amber);
    padding: 0.4rem 0.7rem;
    font-size: 1.2rem;
    cursor: pointer;
    border-radius: var(--radius-sm);
}

@media (max-width: 900px) {
    .nav-toggle { display: block; }
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-secondary);
        border-bottom: 1px solid var(--border-color);
        padding: 1rem;
    }
    .main-nav.open { display: block; }
    .main-nav ul { flex-direction: column; }
}

/* ---------- Hero ---------- */
.hero {
    min-height: 85vh;
    display: flex;
    align-items: center;
    padding: 4rem 0 5rem;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border-color);
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0, 255, 136, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 136, 0.025) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
    pointer-events: none;
    z-index: 1;
}

/* Canvas de humo — siempre al fondo */
#cifra-smoke-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    display: block;
}

/* Contenido del hero — siempre encima de todo */
.hero-inner {
    position: relative;
    z-index: 100;
    max-width: 860px;
}
.hero-terminal-prompt {
    display: inline-block;
    font-family: var(--font-mono);
    color: var(--accent-amber);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    padding: 0.3rem 0.7rem;
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-sm);
    background: rgba(225, 6, 0, 0.05);
}
.hero-terminal-prompt::before { content: '$ '; color: var(--accent-red); }
.hero h1 {
    font-size: clamp(2.4rem, 5vw, 4rem);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #ffffff 0%, var(--green) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero h1 .accent { color: var(--green); -webkit-text-fill-color: var(--green); }
.hero p.lead { font-size: 1.15rem; color: var(--text-secondary); max-width: 650px; margin-bottom: 1.2rem; }
.hero p.lead strong { color: var(--text-primary); font-weight: 600; }
.hero-onapi { color: var(--green); font-weight: 600; }
.hero p.lead em { color: var(--text-primary); font-style: italic; }

/* ── Versículo bíblico ── */
.hero-versiculo {
    margin: 0 0 1.8rem;
    padding: 0.75rem 1.2rem;
    border-left: 2px solid rgba(0, 255, 136, 0.5);
    background: rgba(0, 255, 136, 0.04);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-size: 0.92rem;
    color: var(--green-dim);
    font-style: italic;
    line-height: 1.6;
    max-width: 580px;
}

/* ── Estadísticas ── */
.hero-stats {
    display: flex;
    gap: 14px;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    max-width: 580px;
}
.hero-stat {
    flex: 1;
    min-width: 120px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-md);
    padding: 1rem 0.8rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.hero-stat--green { border: 1px solid rgba(0, 255, 136, 0.2); }
.hero-stat--blue  { border: 1px solid rgba(0, 170, 255, 0.2); }
.hero-stat__num {
    font-size: 2rem;
    font-weight: 800;
    font-family: var(--font-mono);
    line-height: 1;
}
.hero-stat--green .hero-stat__num { color: var(--green); }
.hero-stat--blue  .hero-stat__num { color: var(--blue); }
.hero-stat__label {
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-family: var(--font-mono);
}
@media (max-width: 600px) {
    .hero-stats { gap: 8px; }
    .hero-stat__num { font-size: 1.6rem; }
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    text-decoration: none;
    background: transparent;
}
.btn-primary {
    background: var(--accent-red);
    color: #fff;
    border-color: var(--accent-red);
}
.btn-primary:hover {
    background: var(--accent-red-dark);
    box-shadow: var(--shadow-red);
    color: #fff;
}
.btn-outline {
    border-color: var(--accent-amber);
    color: var(--accent-amber);
}
.btn-outline:hover {
    background: var(--accent-amber);
    color: #000;
}
.btn-group { display: flex; flex-wrap: wrap; gap: 0.8rem; }

/* ---------- Cards / Grid ---------- */
.grid { display: grid; gap: 1.5rem; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.8rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}
.card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 3px; height: 0;
    background: var(--accent-red);
    transition: height 0.3s ease;
}
.card:hover {
    border-color: var(--border-accent);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.card:hover::before { height: 100%; }
.card-icon {
    font-size: 2rem;
    color: var(--accent-red);
    margin-bottom: 0.8rem;
    display: inline-block;
}
.card h3 { color: var(--text-primary); margin-bottom: 0.5rem; }
.card p { color: var(--text-secondary); font-size: 0.95rem; }
.card-link {
    display: inline-block;
    margin-top: 1rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent-amber);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.card-link::after { content: ' →'; transition: transform 0.2s ease; display: inline-block; }
.card-link:hover::after { transform: translateX(4px); }

/* ---------- Section Headers ---------- */
.section-header { margin-bottom: 3rem; text-align: center; }
.section-header .kicker {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-red);
    margin-bottom: 0.5rem;
}
.section-header h2 {
    display: inline-block;
    position: relative;
    padding-bottom: 0.8rem;
}
.section-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: var(--accent-red);
}
.section-header p { max-width: 600px; margin: 1rem auto 0; }

/* ---------- Exercises / Lab ---------- */
.exercise-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--accent-red);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 1.2rem;
}
.exercise-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 0.8rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}
.exercise-badge {
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-sm);
    background: rgba(225, 6, 0, 0.15);
    color: var(--accent-amber);
    border: 1px solid var(--border-accent);
}
.exercise-badge.easy { color: #00c853; border-color: #00c85344; background: rgba(0, 200, 83, 0.1); }
.exercise-badge.medium { color: var(--accent-amber); }
.exercise-badge.hard { color: var(--danger); border-color: #ff174444; background: rgba(255, 23, 68, 0.1); }

/* ---------- Forms ---------- */
.form-group { margin-bottom: 1.2rem; }
.form-group label {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-amber);
    margin-bottom: 0.4rem;
}
.form-control {
    width: 100%;
    padding: 0.8rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.2s ease;
}
.form-control:focus {
    outline: none;
    border-color: var(--accent-red);
    box-shadow: 0 0 0 3px rgba(225, 6, 0, 0.15);
}
textarea.form-control { min-height: 140px; resize: vertical; }

/* ---------- Blog ---------- */
.post-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.3s ease;
}
.post-card:hover { border-color: var(--border-accent); transform: translateY(-3px); }
.post-thumb {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
}
.post-card-body { padding: 1.4rem; }
.post-meta {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}
.post-card h3 { font-size: 1.15rem; margin-bottom: 0.6rem; }
.post-card h3 a { color: var(--text-primary); }
.post-card h3 a:hover { color: var(--accent-amber); }

.single-post .entry-content { max-width: 780px; margin-inline: auto; }
.single-post .entry-content p,
.single-post .entry-content li { font-size: 1.05rem; color: var(--text-secondary); }
.single-post .entry-content pre {
    background: #000;
    border: 1px solid var(--border-accent);
    padding: 1rem;
    border-radius: var(--radius-sm);
    overflow-x: auto;
    font-family: var(--font-mono);
    color: var(--accent-amber);
}
.single-post .entry-content code {
    font-family: var(--font-mono);
    background: var(--bg-tertiary);
    padding: 0.15rem 0.4rem;
    border-radius: 3px;
    color: var(--accent-amber);
    font-size: 0.9em;
}
.single-post .entry-content blockquote {
    border-left: 3px solid var(--accent-red);
    padding: 0.6rem 1.2rem;
    margin: 1.5rem 0;
    background: rgba(225, 6, 0, 0.05);
    font-style: italic;
    color: var(--text-secondary);
}

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 0.5rem; justify-content: center; margin-top: 3rem; flex-wrap: wrap; }
.pagination a, .pagination span {
    padding: 0.5rem 0.9rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
}
.pagination a:hover,
.pagination .current {
    background: var(--accent-red);
    border-color: var(--accent-red);
    color: #fff;
}

/* ---------- Footer ---------- */
.site-footer {
    background: #050505;
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1.5rem;
    margin-top: 5rem;
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}
.footer-col h4 {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-amber);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 0.5rem; }
.footer-col a { color: var(--text-secondary); font-size: 0.9rem; }
.footer-col a:hover { color: var(--accent-amber); }
.social-links { display: flex; gap: 0.8rem; margin-top: 1rem; }
.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px; height: 36px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    transition: all 0.2s ease;
}
.social-links a:hover { background: var(--accent-red); color: #fff; border-color: var(--accent-red); }
.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ---------- Chatbot ---------- */
.chatbot-toggle {
    position: fixed;
    bottom: 1.2rem;
    right: 1.2rem;
    width: 60px;
    height: 60px;
    background: var(--accent-red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.6rem;
    box-shadow: 0 4px 20px rgba(225, 6, 0, 0.5);
    cursor: pointer;
    border: none;
    z-index: 999;
    animation: pulse-red 2s infinite;
}
@keyframes pulse-red {
    0%, 100% { box-shadow: 0 0 0 0 rgba(225, 6, 0, 0.5); }
    50% { box-shadow: 0 0 0 12px rgba(225, 6, 0, 0); }
}
.chatbot-window {
    position: fixed;
    bottom: 5.5rem;
    right: 1.2rem;
    width: min(90vw, 360px);
    max-height: 520px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-md);
    display: none;
    flex-direction: column;
    box-shadow: var(--shadow-md);
    z-index: 999;
    overflow: hidden;
}
.chatbot-window.open { display: flex; }
.chatbot-header {
    background: var(--bg-tertiary);
    padding: 0.8rem 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.chatbot-header strong { font-family: var(--font-mono); color: var(--accent-amber); font-size: 0.9rem; }
.chatbot-close { background: transparent; border: none; color: var(--text-secondary); cursor: pointer; font-size: 1.2rem; }
.chatbot-body {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
    font-size: 0.9rem;
}
.chatbot-message { margin-bottom: 0.8rem; display: flex; gap: 0.5rem; }
.chatbot-message.bot { color: var(--text-secondary); }
.chatbot-message.user { color: var(--accent-amber); justify-content: flex-end; }
.chatbot-message .bubble {
    padding: 0.5rem 0.8rem;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    max-width: 80%;
    border: 1px solid var(--border-color);
}
.chatbot-message.user .bubble { background: rgba(225, 6, 0, 0.15); border-color: var(--border-accent); }
.chatbot-input {
    display: flex;
    gap: 0.4rem;
    padding: 0.7rem;
    border-top: 1px solid var(--border-color);
}
.chatbot-input input {
    flex: 1;
    padding: 0.5rem 0.7rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.9rem;
}
.chatbot-input input:focus { outline: none; border-color: var(--accent-red); }
.chatbot-input button {
    padding: 0.5rem 0.9rem;
    background: var(--accent-red);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.85rem;
}

/* ---------- YouTube embed ---------- */
.youtube-section { background: #000; padding: 4rem 0; }
.youtube-embed-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #000;
}
.youtube-embed-wrapper iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: 0;
}

/* ---------- Alerts / messages ---------- */
.alert {
    padding: 1rem 1.2rem;
    border-radius: var(--radius-sm);
    border-left: 3px solid;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}
.alert-success { background: rgba(0, 200, 83, 0.08); border-color: var(--success); color: #a3e9c0; }
.alert-error { background: rgba(255, 23, 68, 0.08); border-color: var(--danger); color: #f9b5c0; }
.alert-info { background: rgba(255, 179, 0, 0.08); border-color: var(--accent-amber); color: #f9dc9b; }

/* ---------- Accessibility ---------- */
.screen-reader-text {
    clip: rect(1px,1px,1px,1px);
    position: absolute !important;
    height: 1px; width: 1px; overflow: hidden;
}
:focus-visible {
    outline: 2px solid var(--accent-amber);
    outline-offset: 2px;
}

/* ---------- Utilities ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; }
.flex { display: flex; } .flex-center { display: flex; align-items: center; justify-content: center; }
.gap-1 { gap: 0.5rem; } .gap-2 { gap: 1rem; } .gap-3 { gap: 2rem; }

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
    .section { padding: 3rem 0; }
    .hero { min-height: 70vh; padding: 3rem 0; }
    .btn-group { flex-direction: column; }
    .btn { width: 100%; justify-content: center; }
}

/* ══════════════════════════════════════════════════════════
   FOOTER — Testimonios y Organizaciones
   ══════════════════════════════════════════════════════════ */

.footer-testimonios {
    margin: 3rem 0 2rem;
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.testimonios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.2rem;
}

.testimonio-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--green);
    border-radius: var(--radius-md);
    padding: 1.2rem 1.4rem;
    transition: border-color 0.2s;
}

.testimonio-card:hover {
    border-color: var(--border-accent);
}

.testimonio-text {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.7;
    font-style: italic;
    margin: 0 0 0.8rem;
}

.testimonio-text::before { content: '"'; color: var(--green); font-size: 1.4rem; line-height: 0; vertical-align: -0.4rem; margin-right: 2px; }

.testimonio-autor {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    letter-spacing: 0.05em;
}

/* Organizaciones / badges */
.footer-orgs {
    margin: 1.5rem 0 2rem;
}

.orgs-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.org-badge {
    font-size: 0.75rem;
    font-family: var(--font-mono);
    padding: 5px 14px;
    border: 1px solid var(--border-accent);
    border-radius: 4px;
    color: var(--text-muted);
    background: rgba(0,255,136,0.03);
    transition: all 0.2s;
}

.org-badge:hover {
    color: var(--green);
    border-color: var(--green);
    background: rgba(0,255,136,0.08);
}

@media (max-width: 600px) {
    .testimonios-grid { grid-template-columns: 1fr; }
    .orgs-grid { gap: 8px; }
    .org-badge { font-size: 0.7rem; padding: 4px 10px; }
}

/* ══════════════════════════════════════════════════════════
   BLOG — Tarjetas de artículos mejoradas
   ══════════════════════════════════════════════════════════ */

.post-card-img-wrap {
    display: block;
    overflow: hidden;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    text-decoration: none;
}

.post-thumb {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.post-card:hover .post-thumb {
    transform: scale(1.03);
}

.post-thumb-fallback {
    height: 180px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
    transition: background 0.2s;
}

.post-card:hover .post-thumb-fallback {
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, rgba(0,255,136,0.05) 100%);
}

.post-thumb-fallback span:first-child {
    font-size: 2.5rem;
}

.post-thumb-cat {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--green);
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 0.6rem;
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.post-cat-badge {
    background: rgba(0,255,136,0.08);
    border: 1px solid var(--border-accent);
    color: var(--green);
    padding: 1px 8px;
    border-radius: 3px;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* ══════════════════════════════════════════════════════════
   TOOLS STRIP — Franja de herramientas
   ══════════════════════════════════════════════════════════ */
.tools-strip {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 2rem 0;
}
.tools-label {
    text-align: center;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    margin-bottom: 1.5rem;
}
.tools-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}
.tool-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--text-secondary);
    transition: all 0.2s;
    cursor: default;
}
.tool-badge:hover {
    border-color: var(--border-accent);
    color: var(--green);
    background: rgba(0,255,136,0.04);
}
.tool-badge img {
    width: 20px;
    height: 20px;
    object-fit: contain;
    filter: grayscale(0.3);
}
.tool-badge .tool-icon {
    font-size: 1.1rem;
}

/* ── Hero texto Locard ── */
.hero-locard {
    color: var(--green);
    font-style: italic;
    font-weight: 600;
}
.hero p.lead + p.lead { margin-top: 1rem; }

/* ══════════════════════════════════════════════════════════
   HERO — Layout 2 columnas + Visual forense
   ══════════════════════════════════════════════════════════ */

.hero-text { position: relative; z-index: 2; }
.hero-visual { position: relative; z-index: 2; }

.hv-scene {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    padding: 1rem 0;
}

.hv-device {
    display: flex;
    flex-direction: column;
    gap: 6px;
    opacity: 0.85;
    transition: opacity 0.3s;
    filter: drop-shadow(0 0 12px rgba(0,255,136,0.15));
}
.hv-device:hover { opacity: 1; filter: drop-shadow(0 0 20px rgba(0,255,136,0.3)); }
.hv-device svg { width: 100%; height: auto; }
.hv-hdd { filter: drop-shadow(0 0 12px rgba(0,170,255,0.15)); }
.hv-hdd:hover { filter: drop-shadow(0 0 20px rgba(0,170,255,0.3)); }

.hv-label {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    color: var(--green);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.6;
    padding-left: 4px;
}

/* Terminal animada */
.hv-terminal {
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(0,255,136,0.15);
    border-radius: 6px;
    padding: 0.8rem 1rem;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.hv-term-line { color: var(--text-muted); }
.hv-prompt { color: var(--green); margin-right: 6px; }
.hv-blink .hv-prompt { animation: blink 1.2s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Responsive — stack en móvil */
@media (max-width: 900px) {
    .hero-inner { grid-template-columns: 1fr !important; gap: 2rem !important; }
    .hero-visual { display: none; }
    .hero h1 { font-size: clamp(1.8rem, 6vw, 3rem) !important; }
    .hero p.lead { font-size: 0.95rem !important; }
    .hero-stats { gap: 8px !important; }
    .hero-stat__num { font-size: 1.4rem !important; }
    .btn-group { flex-direction: column !important; gap: 10px !important; }
    .btn-group .btn { width: 100% !important; text-align: center !important; }
}

/* ── Hero foto real — responsive ── */
@media (max-width: 900px) {
    .hero { min-height: auto !important; }
    .hero .hero-inner {
        grid-template-columns: 1fr !important;
        min-height: auto !important;
    }
    .hero .hero-inner > div:last-child {
        min-height: 55vw !important;
        max-height: 420px;
    }
    .hero-text { padding: 4rem 1rem 2rem !important; }
}
@keyframes pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 6px #00ff88; }
    50% { opacity: 0.4; box-shadow: 0 0 2px #00ff88; }
}

/* ── Sticky CTA móvil — espacio para que no tape contenido ── */
@media (max-width: 900px) {
    body { padding-bottom: 72px; }
}

/* ══════════════════════════════════════════════════════════
   SUBMENÚ DESPLEGABLE
   ══════════════════════════════════════════════════════════ */
.main-nav li { position: relative; }

.main-nav ul ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 240px;
    background: #0a0e17;
    border: 1px solid rgba(0,255,136,0.2);
    border-radius: 6px;
    padding: 6px 0;
    z-index: 9999;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
    flex-direction: column;
    gap: 0;
}

.main-nav li:hover > ul,
.main-nav li:focus-within > ul {
    display: flex;
}

.main-nav ul ul li { width: 100%; }

.main-nav ul ul a {
    display: block;
    padding: 9px 16px;
    font-size: 0.72rem;
    color: #8899bb;
    white-space: nowrap;
    border-radius: 0;
    letter-spacing: 0.05em;
}

.main-nav ul ul a:hover {
    color: #00ff88;
    background: rgba(0,255,136,0.06);
}

.main-nav ul ul a::before { display: none; }

/* Indicador de submenú */
.main-nav li:has(> ul) > a::after {
    content: ' ▾';
    font-size: 0.65rem;
    opacity: 0.6;
    margin-left: 2px;
}

/* Móvil — submenú estático */
@media (max-width: 900px) {
    .main-nav ul ul {
        position: static;
        display: flex;
        border: none;
        border-left: 2px solid rgba(0,255,136,0.2);
        border-radius: 0;
        padding: 0 0 0 12px;
        box-shadow: none;
        background: transparent;
    }
}

/* ══════════════════════════════════════════════════════════
   SUBMENÚ — Clases reales de WordPress wp_nav_menu
   ══════════════════════════════════════════════════════════ */
.nav-menu li { position: relative; }

.nav-menu .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 260px;
    background: #0a0e17;
    border: 1px solid rgba(0,255,136,0.2);
    border-radius: 6px;
    padding: 6px 0;
    z-index: 9999;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    list-style: none;
    margin: 0;
    flex-direction: column;
}

.nav-menu li:hover > .sub-menu {
    display: block;
}

.nav-menu .sub-menu li { width: 100%; }

.nav-menu .sub-menu a {
    display: block !important;
    padding: 10px 18px !important;
    font-size: 0.72rem !important;
    color: #8899bb !important;
    white-space: nowrap;
    border-radius: 0 !important;
    letter-spacing: 0.05em;
    font-family: monospace;
}

.nav-menu .sub-menu a:hover {
    color: #00ff88 !important;
    background: rgba(0,255,136,0.06);
}

.nav-menu .sub-menu a::before { display: none !important; }

/* Indicador ▾ en items con submenú */
.nav-menu .menu-item-has-children > a::after {
    content: ' ▾';
    font-size: 0.65rem;
    opacity: 0.5;
}

/* Móvil */
@media (max-width: 900px) {
    .nav-menu .sub-menu {
        position: static !important;
        display: block;
        border: none;
        border-left: 2px solid rgba(0,255,136,0.2);
        border-radius: 0;
        padding: 0 0 0 12px;
        box-shadow: none;
        background: transparent;
    }
}

/* ══════════════════════════════════════════════════════════
   FOTO HERO — Responsive mejorado
   ══════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
    .hero-photo-col {
        min-height: 65vw !important;
        max-height: 480px !important;
    }
    .hero-photo-col img {
        object-position: 55% 15% !important;
        height: 100% !important;
    }
    .hero-photo-col > div:last-child {
        background: linear-gradient(to bottom, rgba(10,14,23,0.2) 0%, rgba(10,14,23,0.7) 100%) !important;
    }
}

/* ══════════════════════════════════════════════════════════
   FONDOS SUTILES — Equipos siendo analizados
   ══════════════════════════════════════════════════════════ */

/* Sección servicios */
#servicios {
    position: relative;
    overflow: hidden;
}
#servicios::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 500'%3E%3Crect width='800' height='500' fill='none'/%3E%3Crect x='50' y='80' width='320' height='220' rx='8' fill='none' stroke='%2300ff88' stroke-width='1' opacity='0.12'/%3E%3Crect x='70' y='100' width='280' height='160' rx='4' fill='none' stroke='%2300ff88' stroke-width='0.8' opacity='0.1'/%3E%3Cline x1='70' y1='120' x2='350' y2='120' stroke='%2300ff88' stroke-width='0.6' opacity='0.09'/%3E%3Cline x1='70' y1='140' x2='280' y2='140' stroke='%2300ff88' stroke-width='0.5' opacity='0.08'/%3E%3Cline x1='70' y1='160' x2='310' y2='160' stroke='%2300ff88' stroke-width='0.5' opacity='0.08'/%3E%3Cline x1='70' y1='180' x2='260' y2='180' stroke='%2300ff88' stroke-width='0.4' opacity='0.07'/%3E%3Crect x='430' y='40' width='220' height='150' rx='6' fill='none' stroke='%2300aaff' stroke-width='1' opacity='0.1'/%3E%3Crect x='450' y='60' width='70' height='50' rx='2' fill='none' stroke='%2300aaff' stroke-width='0.7' opacity='0.09'/%3E%3Crect x='530' y='60' width='70' height='50' rx='2' fill='none' stroke='%2300aaff' stroke-width='0.7' opacity='0.09'/%3E%3Ccircle cx='650' cy='320' r='90' fill='none' stroke='%2300ff88' stroke-width='0.8' opacity='0.08'/%3E%3Ccircle cx='650' cy='320' r='60' fill='none' stroke='%2300ff88' stroke-width='0.6' opacity='0.07'/%3E%3Ccircle cx='650' cy='320' r='20' fill='none' stroke='%2300ff88' stroke-width='1' opacity='0.1'/%3E%3Cline x1='614' y1='320' x2='694' y2='260' stroke='%2300ff88' stroke-width='0.8' opacity='0.09'/%3E%3C/svg%3E");
    background-size: cover;
    background-position: center;
    pointer-events: none;
    z-index: 0;
    opacity: 1;
}
#servicios .container { position: relative; z-index: 1; }

#blog {
    position: relative;
    overflow: hidden;
}
#blog::before {
    content: '01101100 10110001 00110101 11001010\A 11001001 01010011 10110100 00101101\A 00110110 11010011 01101001 10100110';
    white-space: pre;
    position: absolute;
    top: 30px;
    right: 30px;
    font-family: monospace;
    font-size: 0.8rem;
    color: rgba(0,255,136,0.08);
    letter-spacing: 0.2em;
    line-height: 2.2;
    pointer-events: none;
    z-index: 0;
}
#blog .container { position: relative; z-index: 1; }

/* ── YouTube lazy load ── */
.yt-lazy-wrap {
    position: relative;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    background: #000;
    aspect-ratio: 16/9;
}
.yt-lazy-wrap:hover .yt-play-btn svg path:first-child { opacity: 1; }
.yt-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: transform 0.15s;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.5));
}
.yt-lazy-wrap:hover .yt-play-btn { transform: translate(-50%, -50%) scale(1.1); }
