/* ── Variables ─────────────────────────────────── */
:root {
    --teal:       #129b9b;
    --teal-dark:  #0c7a7a;
    --teal-light: #e0f5f5;
    --teal-mid:   #1fbfbf;
    --bg:         #f5fafa;
    --surface:    #ffffff;
    --text:       #0b2626;
    --text-muted: #527070;
    --border:     #cce8e8;
    --radius-lg:  20px;
    --radius-md:  12px;
    --radius-sm:  8px;
    --ease:       cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Reset ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Plus Jakarta Sans', 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* ── Navbar ────────────────────────────────────── */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    background: rgba(245, 250, 250, 0.82);
    border-bottom: 1px solid var(--border);
}

.navbar-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 14px 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.nav-logo {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.nav-name {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--teal);
    letter-spacing: -0.02em;
}

/* ── Hero ──────────────────────────────────────── */
.hero {
    position: relative;
    overflow: hidden;
    padding: 20px 28px 20px;
    text-align: center;
    background: linear-gradient(140deg, #d6f2f2 0%, #f5fafa 55%, #e0f5f2 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 560px;
    margin: 0 auto;
}

.hero-pill {
    display: inline-block;
    padding: 5px 14px;
    background: var(--teal-light);
    color: var(--teal-dark);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-radius: 999px;
    border: 1px solid var(--border);
    margin-bottom: 20px;
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.04em;
    color: var(--text);
    margin-bottom: 16px;
}

.hero h1 em {
    font-style: normal;
    color: var(--teal);
}

.hero p {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 400;
    line-height: 1.6;
}

/* Blobs decorativos */
.hero-bg { position: absolute; inset: 0; z-index: 1; pointer-events: none; }

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(70px);
    opacity: 0.35;
}
.blob-1 {
    width: 420px; height: 420px;
    background: radial-gradient(circle, #1fbfbf, transparent 70%);
    top: -120px; left: -80px;
}
.blob-2 {
    width: 320px; height: 320px;
    background: radial-gradient(circle, #7de8e8, transparent 70%);
    bottom: -100px; right: -60px;
}
.blob-3 {
    width: 200px; height: 200px;
    background: radial-gradient(circle, #a8f0f0, transparent 70%);
    top: 40%; left: 55%;
}

/* ── Secciones ───────────────────────────────────── */
main {
    padding: 52px 24px 80px;
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.template-section {}

.section-header {
    max-width: 1100px;
    margin: 0 auto 32px;
    padding: 20px 0 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.section-badge {
    display: inline-block;
    padding: 4px 14px;
    background: var(--teal-light);
    color: var(--teal-dark);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-radius: 999px;
    border: 1px solid var(--border);
}

.section-header h2 {
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
    margin: 0;
}

.section-header p {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin: 0;
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    padding: 52px 24px;
    border: 2px dashed var(--border);
    border-radius: var(--radius-lg);
    background: var(--teal-light);
    opacity: 0.75;
}

/* legacy cat-header (por si queda en uso) */
.cat-section {}
.cat-header { max-width: 1100px; margin: 0 auto 32px; padding: 20px 0 0; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.cat-header h2 { font-size: 1.35rem; font-weight: 800; letter-spacing: -0.02em; color: var(--text); }
.cat-header p { font-size: 0.9rem; color: var(--text-muted); }

/* ── Grid ──────────────────────────────────────── */
.container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto;
}

/* ── Card ──────────────────────────────────────── */
.card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: 0 2px 8px rgba(18, 155, 155, 0.06);
    cursor: pointer;
    transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease);
    display: flex;
    flex-direction: column;
    position: relative;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 48px rgba(18, 155, 155, 0.18);
}

/* Thumbnail */
.card-thumb {
    position: relative;
    overflow: hidden;
    height: 200px;
    background: var(--teal-light);
    flex-shrink: 0;
}

/* iframe escalado — tamaño y scale se calculan en JS */
.card-iframe {
    border: none;
    transform-origin: top left;
    pointer-events: none;
    position: absolute;
    top: 0;
    left: 0;
}

/* Capa invisible que captura el click de la card sin interferir con el iframe */
.iframe-blocker {
    position: absolute;
    inset: 0;
    z-index: 1;
    cursor: pointer;
}


/* Card body */
.card-info {
    padding: 18px 20px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.card-info h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.btn-ver {
    flex-shrink: 0;
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 7px 16px;
    border-radius: var(--radius-sm);
    background: var(--teal-light);
    color: var(--teal-dark);
    border: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.22s var(--ease), color 0.22s var(--ease), border-color 0.22s var(--ease);
}

.card:hover .btn-ver {
    background: var(--teal);
    color: #fff;
    border-color: var(--teal);
}


/* ── Responsive ────────────────────────────────── */
@media (max-width: 480px) {
    .hero { padding: 56px 16px 48px; }
    main { padding: 36px 16px 60px; gap: 48px; }
    .cat-header { margin-bottom: 16px; }
    .container { grid-template-columns: 1fr; gap: 16px; }
}
