/* ==========================================
   1. ESTILOS GLOBALES - MINIMALISMO PREMIUM & CHILL
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
}

body {
    background-color: #090d16;
    color: #f1f5f9;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.page-title {
    text-align: center;
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.subtitle {
    text-align: center;
    color: #64748b;
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 3.5rem;
}

/* ==========================================
   2. NAVBAR Y FOOTER (AFILADO Y MODERNO)
   ========================================== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #020617;
    padding: 1.2rem 3rem;
    border-bottom: 1px solid #1e293b;
}

.logo {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #ffffff;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: #94a3b8;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.nav-links a:hover, .nav-links a.active {
    color: #ffffff;
}

footer {
    text-align: center;
    padding: 2.5rem;
    background-color: #020617;
    color: #475569;
    border-top: 1px solid #1e293b;
    margin-top: 6rem;
    font-size: 0.85rem;
}

/* ==========================================
   3. PÁGINA DE INICIO (HOME / TARJETAS REFINADAS)
   ========================================== */
.hero {
    background: #0f172a;
    border: 1px solid #1e293b;
    padding: 4rem 2rem;
    text-align: center;
    border-radius: 0px;
    margin-bottom: 2rem;
}

.info-empresa {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    padding: 2rem 0;
    flex-wrap: wrap;
}

.card {
    background: #0f172a;
    padding: 2.5rem;
    border: 1px solid #1e293b;
    max-width: 500px;
    flex: 1 1 300px;
    transition: border-color 0.2s ease;
}

.card:hover {
    border-color: #475569;
}

.card h2 {
    color: #ffffff;
    font-size: 1.4rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.card p {
    color: #94a3b8;
    font-size: 0.95rem;
}

/* ==========================================
   4. INTERFAZ DEL JUEGO (SUDOKU NEUTRO PREMIUM)
   ========================================== */
.juegos-menu {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.btn-juego {
    padding: 0.8rem 1.8rem;
    font-size: 0.9rem;
    border: 1px solid #1e293b;
    background-color: transparent;
    color: #64748b;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-juego.active, .btn-juego:hover:not([disabled]) {
    background-color: #1e293b;
    color: #ffffff;
    border-color: #475569;
}

.juego-box {
    background: #020617;
    padding: 3rem 2rem;
    border: 1px solid #1e293b;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.dificultad-menu {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.btn-diff {
    padding: 0.5rem 1.2rem;
    border: 1px solid #1e293b;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.btn-diff.active, .btn-diff:hover {
    border-color: #475569;
    color: #ffffff;
    background: #0f172a;
}

.controles-sudoku {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: center;
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

.controles-sudoku button {
    padding: 0.7rem 1.4rem;
    background-color: #0f172a;
    color: #e2e8f0;
    border: 1px solid #1e293b;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.controles-sudoku button:hover {
    background-color: #1e293b;
    border-color: #475569;
    color: #ffffff;
}

#btn-nota.activo {
    background: #ffffff !important;
    color: #020617 !important;
    border-color: #ffffff !important;
}

#sudoku-status {
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.3px;
    margin-left: 0.5rem;
}

/* ==========================================
   5. EL TABLERO (MÁXIMO CONTRASTE Y VISIBILIDAD)
   ========================================== */
#sudoku-board {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    grid-template-rows: repeat(9, 1fr);
    width: 440px;  
    height: 440px;
    background-color: #334155;
    border: 2px solid #ffffff;
    margin: 0 auto;
}

.cell-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    background-color: #090d16;
    border: 1px solid #1e293b;
}

.cell-wrapper:nth-child(9n+3),
.cell-wrapper:nth-child(9n+6) {
    border-right: 2px solid #334155;
}

#sudoku-board > div:nth-child(n+19):nth-child(-n+27),
#sudoku-board > div:nth-child(n+46):nth-child(-n+54) {
    border-bottom: 2px solid #334155;
}

.sudoku-cell {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: transparent !important;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 1.4rem;
    font-weight: 500;
    color: #ffffff;
    z-index: 2;
}

.sudoku-cell.cell-correcto {
    color: #38bdf8 !important;
    font-weight: 700;
}

.sudoku-cell.cell-error {
    color: #f43f5e !important;
    background-color: rgba(244, 63, 94, 0.1) !important;
    font-weight: 700;
}

.sudoku-cell:focus {
    outline: none;
    box-shadow: inset 0 0 0 2px #ffffff;
}

.cell-wrapper:has(.sudoku-cell:focus) {
    background-color: #0f172a !important;
}

/* ==========================================
   6. LAS NOTAS (ALTA VISIBILIDAD)
   ========================================== */
.notes-grid {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    font-size: 0.7rem;
    color: #94a3b8;
    padding: 2px;
    pointer-events: none;
    z-index: 1;
}

.mini-note {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.cell-wrapper.highlight-axis {
    background-color: #0f172a !important;
}

.cell-wrapper.highlight-same {
    background-color: #1e293b !important;
}

/* ==========================================
   7. PANEL DE PROGRESO INFERIOR (MINIMAL)
   ========================================== */
#progreso-numeros {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 2.5rem;
    width: 100%;
    max-width: 440px;
}

.num-badge {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #090d16;
    border: 1px solid #1e293b;
    padding: 0.5rem 0rem;
    font-weight: 600;
    color: #64748b;
    font-size: 1rem;
    transition: all 0.2s;
}

.num-badge span {
    font-size: 0.65rem;
    color: #475569;
    margin-top: 1px;
}

.num-badge.completado {
    background-color: #1e293b;
    border-color: #475569;
    color: #ffffff;
}

.num-badge.completado span {
    color: #94a3b8;
}

/* ==========================================
   8. SECCIÓN DE RESEÑAS (AFILADA & MODERN)
   ========================================== */
.reseñas-section {
    margin-top: 5rem;
    width: 100%;
}

.section-title {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 2rem;
    letter-spacing: -0.3px;
    color: #ffffff;
}

.grid-reseñas {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    width: 100%;
}

.card-reseña {
    background: #020617;
    border: 1px solid #1e293b;
    padding: 2rem;
    flex: 1 1 340px;
    max-width: 520px;
}

.card-reseña .comentario {
    font-style: italic;
    color: #cbd5e1;
    font-size: 0.95rem;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.card-reseña .autor {
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ==========================================
   9. RESPONSIVO
   ========================================== */
@media (max-width: 480px) {
    #sudoku-board {
        width: 340px;
        height: 340px;
    }
    #progreso-numeros {
        max-width: 340px;
    }
}
/* ==========================================
   10. SECCIÓN DE PRODUCTOS (GRID PREMIUM)
   ========================================== */
.productos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.product-card {
    background: #0f172a;
    border: 1px solid #1e293b;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    text-align: center;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.product-card:hover {
    border-color: #475569;
}

.product-image-placeholder {
    width: 100%;
    height: 250px;
    background: #020617;
    border: 1px solid #1e293b;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #334155;
    font-weight: bold;
    margin-bottom: 1.5rem;
}

.product-card h3 {
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.product-card .price {
    color: #94a3b8;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.btn-comprar {
    display: block;
    background: #ffffff;
    color: #020617;
    padding: 0.8rem;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: background 0.2s;
}

.btn-comprar:hover {
    background: #e2e8f0;
}
/* ==========================================
   11. SECCIÓN DE ARTÍCULOS (BLOG MINIMAL)
   ========================================== */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.blog-post {
    display: flex;
    flex-direction: column;
}

.post-image-placeholder {
    width: 100%;
    height: 200px;
    background: #020617;
    border: 1px solid #1e293b;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #334155;
    margin-bottom: 1.5rem;
}

.post-date {
    font-size: 0.75rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
    display: block;
}

.blog-post h2 {
    color: #ffffff;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.blog-post p {
    color: #94a3b8;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.read-more {
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    border-bottom: 1px solid #ffffff;
    padding-bottom: 2px;
    align-self: flex-start;
}

.read-more:hover {
    color: #cbd5e1;
    border-color: #cbd5e1;
}
/* ==========================================
   12. PÁGINA LEGAL (LEGIBILIDAD PREMIUM)
   ========================================== */
.legal-section {
    margin-bottom: 3rem;
}

.legal-section h2 {
    color: #ffffff;
    font-size: 1.2rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #1e293b;
    padding-bottom: 0.5rem;
}

.legal-section p {
    color: #94a3b8;
    line-height: 1.8;
    font-size: 1rem;
}