/* ==========================================================================
   Theme Name: INGELIFE Retro Arcade Theme
   Description: Tema retro con estilo neo-brutalismo para INGELIFE
   ========================================================================== */

:root {
    /* Retro Color Palette */
    --clr-bg-light: #F4F4F0;
    --clr-bg-dark: #0A0A0A;
    --clr-card-dark: #121212;
    
    --clr-magenta: #E51E60;
    --clr-orange: #E85117;
    --clr-yellow: #F7B801;
    --clr-cyan: #00B1D2;
    
    --clr-black: #000000;
    --clr-white: #FFFFFF;
    --clr-gray: #A0A0A0;

    /* Fonts */
    --font-pixel: 'Press Start 2P', cursive;
    --font-mono: 'Space Mono', monospace;

    /* Borders & Shadows */
    --border-thick: 3px solid var(--clr-black);
    --border-thin: 2px solid var(--clr-black);
    --shadow-solid: 4px 4px 0px var(--clr-black);
    --shadow-solid-hover: 2px 2px 0px var(--clr-black);
    --shadow-solid-light: 4px 4px 0px var(--clr-white);
    
    /* Layout */
    --container-width: 1300px;
}

/* ==========================================================================
   Base & Resets
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.retro-theme {
    font-family: var(--font-mono);
    background-color: var(--clr-bg-light);
    color: var(--clr-black);
    line-height: 1.5;
    /* Outer border for the whole page */
    border-left: var(--border-thick);
    border-right: var(--border-thick);
    max-width: 1600px;
    margin: 0 auto;
    position: relative;
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

/* Utilities */
.pixel-font { font-family: var(--font-pixel); }
.mono-font { font-family: var(--font-mono); }
.text-white { color: var(--clr-white); }
.text-black { color: var(--clr-black); }
.text-magenta { color: var(--clr-magenta); }
.text-yellow { color: var(--clr-yellow); }
.text-cyan { color: var(--clr-cyan); }
.text-gray { color: var(--clr-gray); }

.text-xs { font-size: 0.7rem; }
.text-sm { font-size: 0.85rem; }
.mt-2 { margin-top: 1rem; }

.dark-bg { background-color: var(--clr-bg-dark); }
.light-bg { background-color: var(--clr-bg-light); }

.border-bottom-thick { border-bottom: var(--border-thick); }
.border-top-thick { border-top: var(--border-thick); }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border: var(--border-thick);
    box-shadow: var(--shadow-solid);
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.8rem;
    transition: all 0.1s ease;
    cursor: pointer;
    line-height: 1.2;
}

.btn:active {
    transform: translate(2px, 2px);
    box-shadow: var(--shadow-solid-hover);
}

.btn-magenta {
    background-color: var(--clr-magenta);
    color: var(--clr-white);
}

.btn-white {
    background-color: var(--clr-white);
    color: var(--clr-black);
}

.btn-outline-magenta {
    background-color: var(--clr-bg-light);
    border-color: var(--clr-magenta);
    color: var(--clr-magenta);
    box-shadow: 4px 4px 0px var(--clr-magenta);
}

.btn-outline-magenta:active {
    box-shadow: 2px 2px 0px var(--clr-magenta);
}

.btn-outline-yellow {
    background-color: transparent;
    border-color: var(--clr-yellow);
    color: var(--clr-yellow);
    box-shadow: 4px 4px 0px var(--clr-yellow);
}

.btn-outline-yellow:active {
    box-shadow: 2px 2px 0px var(--clr-yellow);
}

.play-icon {
    font-size: 1rem;
    margin-right: 8px;
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
    background-color: var(--clr-bg-light);
    position: relative;
    z-index: 100;
}

.color-stripes {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.stripe {
    height: 6px;
    width: 100%;
}

.stripe.magenta { background-color: var(--clr-magenta); }
.stripe.orange { background-color: var(--clr-orange); }
.stripe.yellow { background-color: var(--clr-yellow); }
.stripe.cyan { background-color: var(--clr-cyan); }

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

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

.logo-stripes {
    display: flex;
    flex-direction: column;
    gap: 2px;
    height: 28px;
    justify-content: center;
}

.l-stripe {
    height: 4px;
    width: 30px;
}
.l-stripe.magenta { background-color: var(--clr-magenta); }
.l-stripe.orange { background-color: var(--clr-orange); }
.l-stripe.yellow { background-color: var(--clr-yellow); }
.l-stripe.cyan { background-color: var(--clr-cyan); }

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text .pixel-font {
    font-size: 1.5rem;
    line-height: 1;
}

.logo-text .small-text {
    font-size: 0.55rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.main-nav a {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--clr-black);
    text-decoration: none;
    text-transform: uppercase;
    position: relative;
}

.main-nav a:hover, .main-nav a.active {
    color: var(--clr-magenta);
}

.main-nav a.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--clr-magenta);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
    position: relative;
    padding: 4rem 0;
    overflow: hidden;
    background-image: radial-gradient(circle at 50% 50%, #1a1a2e 0%, var(--clr-bg-dark) 100%);
}

.hero-retro-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3rem;
    line-height: 1.4;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 0px var(--clr-black);
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

.hero-cta {
    display: flex;
    gap: 1.5rem;
}

.hero-image {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.lives-counter {
    position: absolute;
    top: -20px;
    right: 20px;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 10;
}

.heart { font-size: 1.5rem; }

.arcade-img {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 0 20px rgba(229, 30, 96, 0.3));
    z-index: 5;
    border-radius: 8px; /* Remove if actual image is pixel art without borders */
}

/* Fallback if image isn't generated yet */
#arcade-placeholder:empty {
    width: 400px;
    height: 500px;
    background: linear-gradient(to bottom, #2b1055, #7597de);
    border: var(--border-thick);
    border-color: var(--clr-white);
    display: flex;
    align-items: center;
    justify-content: center;
}

.level-box {
    position: absolute;
    bottom: 20px;
    right: 0;
    border: 2px solid var(--clr-white);
    padding: 1.5rem;
    background-color: rgba(10, 10, 10, 0.9);
    border-radius: 4px;
    z-index: 10;
}

.level-box h3 {
    font-size: 0.8rem;
    margin-bottom: 1rem;
    border-bottom: 1px dashed var(--clr-white);
    padding-bottom: 0.5rem;
}

.level-box ul {
    list-style: none;
    font-size: 0.8rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.blink {
    animation: blinker 1.5s linear infinite;
}
@keyframes blinker {
    50% { opacity: 0; }
}

/* ==========================================================================
   Features Banner
   ========================================================================== */
.features-banner {
    padding: 2rem 0;
}

.features-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
    padding: 0 1rem;
}

.pixel-icon {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.feature-text h3 {
    line-height: 1.4;
    margin-bottom: 0.25rem;
}

.feature-text p {
    color: #444;
}

.feature-separator {
    width: 2px;
    height: 60px;
    background-color: var(--clr-black);
}

/* ==========================================================================
   Courses Section (WooCommerce Carousel)
   ========================================================================== */
.courses-section {
    padding: 5rem 0;
    overflow: hidden; /* Important for Swiper */
}

.relative { position: relative; }
.m-0 { margin: 0; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.w-100 { width: 100%; }
.text-center { text-align: center; }
.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: var(--border-thick);
    padding-bottom: 0.5rem;
    margin-bottom: 2rem;
}

.bg-magenta { background-color: var(--clr-magenta); }
.bg-cyan { background-color: var(--clr-cyan); }

/* Swiper Navigation Retro */
.swiper-nav-retro {
    display: flex;
    gap: 10px;
}

.swiper-button-prev-retro,
.swiper-button-next-retro {
    width: 40px;
    height: 40px;
    background-color: var(--clr-white);
    border: var(--border-thick);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 2px 2px 0px var(--clr-black);
    transition: all 0.1s ease;
}

.swiper-button-prev-retro:active,
.swiper-button-next-retro:active {
    transform: translate(2px, 2px);
    box-shadow: 0px 0px 0px var(--clr-black);
}

.swiper-button-prev-retro.swiper-button-disabled,
.swiper-button-next-retro.swiper-button-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Course Card (WooCommerce Style) */
.course-card {
    border: var(--border-thick);
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-solid);
    transition: transform 0.2s ease;
    background-color: var(--clr-card-dark);
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 6px 6px 0px var(--clr-black);
}

.course-img-wrapper {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.course-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.course-card:hover .course-img {
    transform: scale(1.05);
}

.course-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border: 2px solid var(--clr-black);
    z-index: 2;
}

.course-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.course-cat {
    margin-bottom: 0.5rem;
    display: inline-block;
}

.course-title {
    font-size: 1rem;
    line-height: 1.4;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.course-price-wrap {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    border-top: 1px dashed #444;
    padding-top: 1rem;
}

.btn-block {
    display: block;
    width: 100%;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
    padding: 2rem 0;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-stripes.horizontal {
    flex-direction: row;
    height: auto;
    width: 28px;
    flex-wrap: wrap;
    gap: 2px;
}

.logo-stripes.horizontal .l-stripe {
    width: 100%;
    height: 4px;
}

.footer-slogan {
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-copy {
    text-align: right;
}

/* ==========================================================================
   Header Actions & Cart
   ========================================================================== */
.header-actions {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.cart-link {
    text-decoration: none;
    position: relative;
    transition: transform 0.2s ease;
    display: inline-block;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -12px;
    padding: 4px;
    border: 2px solid var(--clr-black);
    border-radius: 0;
    min-width: 24px;
    text-align: center;
    box-shadow: 2px 2px 0px var(--clr-black);
    transition: transform 0.2s;
}

/* Hamburger Button */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    gap: 5px;
}

.hamburger span {
    display: block;
    height: 3px;
    background-color: var(--clr-black);
    border-radius: 0;
    transition: all 0.3s ease;
    transform-origin: center;
}

.hamburger.is-active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.hamburger.is-active span:nth-child(2) {
    opacity: 0;
}
.hamburger.is-active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* ==========================================================================
   Responsive — Tablet (≤ 1024px)
   ========================================================================== */
@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: 1fr;
    }
    .hero-image {
        display: none;
    }
    .features-inner {
        flex-wrap: wrap;
        gap: 2rem;
    }
    .feature-separator {
        display: none;
    }
    .feature-item {
        min-width: calc(50% - 1rem);
    }
    .about-inner {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    .about-image {
        display: none; /* Ocultar en tablet para simplificar */
    }
}

/* ==========================================================================
   Responsive — Mobile (≤ 768px)
   ========================================================================== */
@media (max-width: 768px) {

    /* --- Header / Nav --- */
    .header-inner {
        padding: 0.75rem 1rem;
        flex-wrap: wrap;
        position: relative;
    }

    .brand-logo .logo-text .small-text {
        display: none; /* Ocultar subtítulo en móvil */
    }

    .main-nav {
        display: none; /* Oculto por defecto, JS lo muestra */
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--clr-bg-light);
        border-top: var(--border-thick);
        border-bottom: var(--border-thick);
        z-index: 1000;
        box-shadow: 0 4px 0px var(--clr-black);
    }

    .main-nav.is-open {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        padding: 1rem 0;
    }

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

    .main-nav ul li a {
        display: block;
        padding: 0.85rem 1.5rem;
        border-bottom: 1px dashed #ccc;
        font-size: 0.75rem;
    }

    .main-nav ul li:last-child a {
        border-bottom: none;
    }

    .hamburger {
        display: flex; /* Mostrar botón hamburguesa */
    }

    /* Ocultar botón INSCRÍBETE en móvil pequeño */
    .wc-my-account-btn {
        display: none;
    }

    /* --- Hero --- */
    .hero-title {
        font-size: 1.4rem !important;
        line-height: 1.6;
    }

    .hero-description {
        font-size: 0.8rem;
    }

    .hero-cta {
        flex-direction: column;
        gap: 1rem;
    }

    /* --- Features Banner --- */
    .features-inner {
        flex-direction: column;
        gap: 1.5rem;
    }

    .feature-item {
        min-width: 100%;
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }

    /* --- Courses Swiper --- */
    .courses-section .flex-between {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    /* --- About Section --- */
    .about-inner {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    .about-image {
        display: none;
    }

    .about-stats {
        flex-wrap: wrap;
        gap: 1.5rem !important;
    }

    /* --- Footer --- */
    .footer-inner {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
        padding: 2rem 1rem;
    }

    .footer-slogan {
        font-size: 0.7rem;
        line-height: 1.8;
    }

    /* --- Mentores Grid --- */
    .mentors-grid-section > .container > div {
        grid-template-columns: 1fr !important;
    }

    .character-card-container {
        height: auto !important;
        min-height: 580px;
    }

    /* Mentors hero title */
    .mentors-hero h1 {
        font-size: 1.5rem !important;
    }

    /* --- General padding reduction --- */
    .container {
        padding: 0 1rem;
    }

    section {
        padding: 3rem 0 !important;
    }
}

/* ==========================================================================
   Responsive — Small Mobile (≤ 480px)
   ========================================================================== */
@media (max-width: 480px) {
    .hero-title {
        font-size: 1.1rem !important;
    }

    .pixel-font.section-title,
    h2.pixel-font {
        font-size: 0.9rem;
    }

    .btn {
        font-size: 0.65rem;
        padding: 10px 16px;
    }

    .about-stats h3.pixel-font {
        font-size: 1.5rem !important;
    }
}

/* ==========================================================================
   Mentor Character Cards (Flip 3D)
   ========================================================================== */
.character-card-container {
    perspective: 1000px;
    background-color: transparent;
    height: 620px;
}

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

.character-card-front,
.character-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    top: 0;
    left: 0;
    border: 4px solid var(--clr-white);
    background-color: var(--clr-bg-dark);
    padding: 1.5rem;
    box-shadow: 8px 8px 0px var(--clr-black);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.character-card-front {
    transform: rotateY(0deg);
    z-index: 2;
}

.character-card-back {
    transform: rotateY(180deg);
    align-items: flex-start;
    text-align: left;
    border-color: var(--clr-magenta);
    box-shadow: -8px 8px 0px var(--clr-magenta);
}

.character-avatar {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border: 2px solid var(--clr-white);
    margin-bottom: 1rem;
    filter: grayscale(0.5) contrast(1.2);
    transition: filter 0.3s ease;
}

.character-card-container:hover .character-avatar {
    filter: grayscale(0) contrast(1.1);
}

.character-name  { font-size: 1.2rem; margin-bottom: 0.5rem; }
.character-class { font-size: 0.8rem; margin-bottom: 1rem; color: var(--clr-yellow); }

.character-stats {
    width: 100%;
    text-align: left;
    border-top: 2px dashed #444;
    padding-top: 1rem;
    margin-top: auto;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
    color: var(--clr-yellow);
}

.stat-bar {
    width: 50%;
    height: 10px;
    background-color: #333;
    border: 1px solid var(--clr-white);
}

.stat-fill          { height: 100%; }
.stat-fill.magenta  { background-color: var(--clr-magenta); }
.stat-fill.cyan     { background-color: var(--clr-cyan); }
.stat-fill.yellow   { background-color: var(--clr-yellow); }

.select-btn { width: 100%; margin-top: 1rem; }

/* Mobile: tarjetas apiladas */
@media (max-width: 768px) {
    .character-card-container {
        height: auto !important;
        min-height: 580px;
    }
}

/* ==========================================================================
   WooCommerce — Estilo Retro
   ========================================================================== */

/* Precio */
.woocommerce .price,
.woocommerce-Price-amount {
    font-family: var(--font-pixel) !important;
    color: var(--clr-yellow) !important;
    font-size: 1.1rem !important;
}

/* Botón añadir al carrito estándar de WooCommerce */
.woocommerce .button,
.woocommerce button.button,
.woocommerce a.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
    font-family: var(--font-pixel) !important;
    background-color: var(--clr-magenta) !important;
    color: var(--clr-white) !important;
    border: var(--border-thick) !important;
    box-shadow: var(--shadow-solid) !important;
    border-radius: 0 !important;
    padding: 12px 24px !important;
    text-transform: uppercase !important;
    transition: all 0.1s ease !important;
}

.woocommerce .button:hover,
.woocommerce a.button:hover {
    background-color: #c01550 !important;
    color: var(--clr-white) !important;
}

/* Tabla del carrito */
.woocommerce-cart table.cart {
    border: var(--border-thick);
    background-color: var(--clr-bg-light);
    font-family: var(--font-mono);
}

.woocommerce-cart table.cart th {
    font-family: var(--font-pixel);
    font-size: 0.7rem;
    background-color: var(--clr-black);
    color: var(--clr-white);
    padding: 1rem;
}

.woocommerce-cart table.cart td {
    border-bottom: 1px dashed #ccc;
    padding: 1rem;
    vertical-align: middle;
}

/* Mensajes de notificación */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
    font-family: var(--font-mono) !important;
    border-top: 3px solid var(--clr-magenta) !important;
    background-color: var(--clr-bg-light) !important;
}

/* ==========================================================================
   Mentors Hero Section
   ========================================================================== */
.mentors-hero {
    padding: 4rem 0;
    text-align: center;
    background-image: radial-gradient(circle at 50% 50%, #2a0a2e 0%, var(--clr-bg-dark) 100%);
}

@media (max-width: 768px) {
    .mentors-hero h1 { font-size: 1.5rem !important; }
}
