/* ══════════════════════════════════════════
   categorias.css — Explora Ibagué
   ══════════════════════════════════════════ */

:root {
    --gold: #d4af37;
    --gold-dark: #b8860b;
    --copper: #977a5a;
    --dark: #0d0906;
    --cream: #f9e3ba;
    --white: #EEEDEB;
}

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

body {
    font-family: 'Jost', sans-serif;
    background: var(--dark);
    color: var(--white);
    overflow-x: hidden;
}

/* ── FONDO ── */
.bg-scene {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(212, 175, 55, 0.06) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 20%, rgba(151, 122, 90, 0.08) 0%, transparent 50%),
        var(--dark);
    z-index: 0;
}

.bg-scene::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
    opacity: 0.4;
    pointer-events: none;
    z-index: 1;
}

/* ── HERO HEADER ── */
.hero {
    position: relative;
    z-index: 10;
    text-align: center;
    padding: 100px 20px 80px;
}

.hero-tag {
    display: inline-block;
    font-family: 'Jost', sans-serif;
    font-size: 0.68rem;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: var(--copper);
    border: 1px solid rgba(151, 122, 90, 0.4);
    padding: 6px 20px;
    border-radius: 30px;
    margin-bottom: 24px;
    animation: fadeUp 0.8s ease forwards;
    opacity: 0;
}

.hero h1 {
    font-family: 'Cinzel', serif;
    font-size: clamp(2.8rem, 6vw, 5.5rem);
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 0.05em;
    line-height: 1.1;
    text-shadow: 0 0 60px rgba(212, 175, 55, 0.25);
    animation: fadeUp 0.8s 0.15s ease forwards;
    opacity: 0;
}

.hero-sub {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 1.25rem;
    color: var(--copper);
    margin-top: 16px;
    animation: fadeUp 0.8s 0.3s ease forwards;
    opacity: 0;
}

/* ── Ornamento central ── */
.ornament-center {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin: 36px auto 0;
    max-width: 300px;
    animation: fadeUp 0.8s 0.45s ease forwards;
    opacity: 0;
}

.ornament-center .line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--copper));
}

.ornament-center .line.r {
    background: linear-gradient(90deg, var(--copper), transparent);
}

.ornament-center .diamond {
    width: 7px;
    height: 7px;
    background: var(--gold);
    transform: rotate(45deg);
}

/* ── GRID DE CATEGORÍAS ── */
.grid-section {
    position: relative;
    z-index: 10;
    padding: 20px 5% 100px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.cat-card:nth-child(1),
.cat-card:nth-child(2),
.cat-card:nth-child(3) {
    grid-column: span 1;
    height: 420px;
}

.cat-card:nth-child(4),
.cat-card:nth-child(5),
.cat-card:nth-child(6),
.cat-card:nth-child(7) {
    height: 300px;
}

@media (min-width: 900px) {
    .categories-grid {
        grid-template-columns: repeat(12, 1fr);
    }

    .cat-card:nth-child(1) {
        grid-column: 1 / 6;
        height: 460px;
    }

    .cat-card:nth-child(2) {
        grid-column: 6 / 10;
        height: 460px;
    }

    .cat-card:nth-child(3) {
        grid-column: 10 / 13;
        height: 460px;
    }

    .cat-card:nth-child(4) {
        grid-column: 1 / 4;
        height: 320px;
    }

    .cat-card:nth-child(5) {
        grid-column: 4 / 7;
        height: 320px;
    }

    .cat-card:nth-child(6) {
        grid-column: 7 / 10;
        height: 320px;
    }

    .cat-card:nth-child(7) {
        grid-column: 10 / 13;
        height: 320px;
    }
}

/* ── CARD ── */
.cat-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(212, 175, 55, 0.12);
    transition:
        transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
        border-color 0.4s ease,
        box-shadow 0.5s ease;
    animation: cardIn 0.7s ease forwards;
    opacity: 0;
    text-decoration: none;
    display: block;
    color: inherit;
}

.cat-card:nth-child(1) {
    animation-delay: 0.1s;
}

.cat-card:nth-child(2) {
    animation-delay: 0.2s;
}

.cat-card:nth-child(3) {
    animation-delay: 0.3s;
}

.cat-card:nth-child(4) {
    animation-delay: 0.4s;
}

.cat-card:nth-child(5) {
    animation-delay: 0.5s;
}

.cat-card:nth-child(6) {
    animation-delay: 0.6s;
}

.cat-card:nth-child(7) {
    animation-delay: 0.7s;
}

.cat-card:hover {
    transform: translateY(-8px) scale(1.01);
    border-color: rgba(212, 175, 55, 0.45);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(212, 175, 55, 0.12);
}

/* Imagen de fondo */
.card-img {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.cat-card:hover .card-img {
    transform: scale(1.08);
}

/* Overlay degradado */
.card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
            rgba(13, 9, 6, 0.95) 0%,
            rgba(13, 9, 6, 0.5) 40%,
            rgba(13, 9, 6, 0.1) 70%,
            transparent 100%);
    transition: background 0.4s ease;
}

.cat-card:hover .card-overlay {
    background: linear-gradient(to top,
            rgba(13, 9, 6, 0.98) 0%,
            rgba(13, 9, 6, 0.6) 45%,
            rgba(13, 9, 6, 0.2) 75%,
            transparent 100%);
}

/* Línea dorada superior al hover */
.card-glow {
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.cat-card:hover .card-glow {
    opacity: 1;
}

/* Contenido de la tarjeta */
.card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px 28px;
}

.card-icon {
    font-size: 1.8rem;
    margin-bottom: 10px;
    display: block;
    filter: drop-shadow(0 0 8px rgba(212, 175, 55, 0.4));
    transform: translateY(6px);
    transition: transform 0.4s ease;
}

.cat-card:hover .card-icon {
    transform: translateY(0);
}

.card-name {
    font-family: 'Cinzel', serif;
    font-size: clamp(1.1rem, 2vw, 1.55rem);
    font-weight: 600;
    color: var(--white);
    letter-spacing: 0.06em;
    line-height: 1.2;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8);
    margin-bottom: 8px;
}

.card-desc {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 0.95rem;
    color: var(--copper);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    line-height: 1.5;
}

.cat-card:hover .card-desc {
    opacity: 1;
    transform: translateY(0);
}

.card-arrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 14px;
    font-family: 'Jost', sans-serif;
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
    opacity: 0;
    transform: translateX(-10px);
    transition: opacity 0.4s 0.05s ease, transform 0.4s 0.05s ease;
}

.card-arrow::after {
    content: '→';
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.cat-card:hover .card-arrow::after {
    transform: translateX(4px);
}

.cat-card:hover .card-arrow {
    opacity: 1;
    transform: translateX(0);
}

/* Número decorativo */
.card-number {
    position: absolute;
    top: 20px;
    right: 22px;
    font-family: 'Cinzel', serif;
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    color: rgba(212, 175, 55, 0.4);
}

/* ── ANIMACIONES GLOBALES ── */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes cardIn {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ── HEADER ── */
.encabezado {
    position: relative;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 4%;
    border-bottom: 1px solid rgba(212, 175, 55, 0.15);
    background: linear-gradient(to bottom, rgba(13, 9, 6, 0.92), transparent);
}

.logo {
    width: 180px;
    height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 0 12px rgba(212, 175, 55, 0.3));
}

nav ul {
    list-style: none;
    display: flex;
    gap: 10px;
    align-items: center;
}

nav ul li a {
    color: var(--white);
    text-decoration: none;
    font-family: 'Cinzel', 'sub', serif;
    font-size: 0.78rem;
    letter-spacing: 0.12em;
    padding: 8px 18px;
    border-radius: 30px;
    transition: all 0.4s ease;
    position: relative;
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background: var(--gold);
    transition: width 0.3s ease;
}

nav ul li a:hover {
    color: var(--gold);
}

nav ul li a:hover::after {
    width: 60%;
}

footer {
    position: relative;
    z-index: 5;
    background: linear-gradient(to bottom, transparent 0%, rgba(13, 9, 6, 0.75) 30%, rgba(13, 9, 6, 0.92) 100%);
    border-top: 1px solid rgba(212, 175, 55, 0.12);
    padding: 48px 8% 24px;
    font-family: 'Jost', sans-serif;
}

.footer-contenido {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 32px;
    margin-bottom: 36px;
}

.footer-col h3 {
    font-family: 'Cinzel', serif;
    color: var(--gold);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    margin-bottom: 14px;
}

.footer-col p,
.footer-col a {
    color: var(--white);
    font-size: 0.88rem;
    line-height: 2;
    text-decoration: none;
    display: block;
    transition: color 0.3s;
}

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

.footer-copy {
    text-align: center;
    border-top: 1px solid rgba(212, 175, 55, 0.1);
    padding-top: 20px;
    color: rgba(238, 237, 235, 0.4);
    font-size: 0.8rem;
    letter-spacing: 0.05em;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .hero {
        padding: 80px 16px 60px;
    }
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .cat-card {
        height: 260px !important;
    }
    .card-content {
        padding: 20px 18px;
    }
    .card-desc {
        display: none;
    }
    .card-number {
        font-size: 0.6rem;
        top: 14px;
        right: 16px;
    }
    .card-arrow {
        margin-top: 8px;
        font-size: 0.65rem;
    }
    .bloque,
    .bloque.invertido {
        flex-direction: column;
    }
    .lugar-img-wrapper {
        flex: 0 0 auto;
        width: 100%;
        height: 220px;
    }
    .texto {
        width: 100%;
    }
    nav ul {
        gap: 4px;
    }
    nav ul li a {
        font-size: 0.68rem;
        padding: 6px 10px;
    }
    .footer-contenido {
        flex-direction: column;
    }
}

@media (max-width: 600px) {
    .hero h1 {
        font-size: clamp(2rem, 10vw, 2.8rem);
    }
    .hero-sub {
        font-size: 1rem;
    }
    .categories-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .cat-card {
        height: 200px !important;
    }
    .card-content {
        padding: 16px 14px;
    }
    .card-name {
        font-size: 1rem;
    }
    .card-icon {
        font-size: 1.4rem;
        margin-bottom: 6px;
    }
    .grid-section {
        padding: 10px 4% 60px;
    }
}

@media (max-width: 360px) {
    .cat-card {
        height: 170px !important;
    }
}
