
:root {
    /* Colores más vibrantes */
    --primary-color: #3b82f6;
    --primary-dark: #2563eb;
    --primary-light: #93c5fd;
    --primary-extra-light: #dbeafe;

    --secondary-color: #10b981;
    --secondary-light: #6ee7b7;
    --secondary-dark: #059669;

    --accent-color: #f59e0b;
    --accent-light: #fcd34d;
    --accent-dark: #d97706;

    --danger-color: #ef4444;
    --danger-light: #fca5a5;
    --danger-dark: #dc2626;

    --purple-color: #8b5cf6;
    --purple-light: #c4b5fd;
    --purple-dark: #7c3aed;

    --pink-color: #ec4899;
    --pink-light: #f9a8d4;
    --pink-dark: #db2777;

    /* Texto */
    --text-dark: #1e293b;
    --text-light: #64748b;
    --white: #ffffff;

    /* Sombras más pronunciadas */
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.2),
        0 4px 6px -2px rgba(0, 0, 0, 0.05);

    /* Bordes redondeados */
    --rounded-sm: 0.375rem;
    --rounded-md: 0.5rem;
    --rounded-lg: 0.75rem;
    --rounded-xl: 1rem;
    --rounded-full: 9999px;

    /* Gradientes */
    --gradient-primary: linear-gradient(135deg,
            var(--primary-color),
            var(--primary-dark));
    --gradient-accent: linear-gradient(135deg,
            var(--accent-color),
            var(--accent-dark));
    --gradient-danger: linear-gradient(135deg,
            var(--danger-color),
            var(--danger-dark));
    --gradient-success: linear-gradient(135deg,
            var(--secondary-color),
            var(--secondary-dark));

    /* Color principal (verde) */
    /* Versión oscura del primario */
    --primary-text: #065f46;
    /* Texto sobre fondo primario */

    --secondary: #3b82f6;
    /* Color secundario (azul) */
    --secondary-light: #dbeafe;
    /* Versión clara del secundario */
    --secondary-dark: #1e40af;
    /* Versión oscura del secundario */

    --correct: #10b981;
    /* Para elementos correctos (verde) */
    --correct-light: #d1fae5;
    /* Versión clara */
    --correct-dark: #065f46;
    /* Versión oscura */

    --wrong: #ef4444;
    /* Para errores (rojo) */
    --wrong-light: #fee2e2;
    /* Versión clara */
    --wrong-dark: #b91c1c;
    /* Versión oscura */

    --warning: #f59e0b;
    /* Amarillo para advertencias */
    --warning-light: #fef3c7;
    --warning-dark: #92400e;

    /* Colores neutros */
    --bg-color: #ffffff;
    /* Color de fondo principal */
    --bg-color-light: #f8f9fa;
    /* Fondos claros */
    --bg-color-dark: #f1f3f5;
    /* Fondos oscuros */

    --text-color: #1e293b;
    /* Texto principal */
    --text-muted: #64748b;
    /* Texto secundario */
    --text-light: #94a3b8;
    /* Texto claro */

    --border-color: #e2e8f0;
    /* Color de bordes */
    --border-radius: 8px;
    /* Radio de esquinas */
    --border-radius-sm: 6px;
    /* Radio pequeño */

    /* Sombras */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1),
        0 4px 6px -2px rgba(0, 0, 0, 0.05);

    /* Espaciado */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;

    /* Tipografía */
    --font-size-sm: 0.875rem;
    /* 14px */
    --font-size-base: 1rem;
    /* 16px */
    --font-size-md: 1.125rem;
    /* 18px */
    --font-size-lg: 1.25rem;
    /* 20px */
    --font-size-xl: 1.5rem;
    /* 24px */

    /* Colores específicos para el juego de matching */
    --match-selected-bg: var(--primary-light);
    --match-selected-border: var(--primary);
    --match-selected-text: var(--primary-text);

    --match-correct-bg: var(--correct-light);
    --match-correct-border: var(--correct);
    --match-correct-text: var(--correct-dark);

    --match-hover-bg: #e9ecef;
    --match-modal-bg: var(--bg-color);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f8fafc;
    color: var(--text-dark);
    min-height: 100vh;
    background-image: radial-gradient(circle at 10% 20%,
            var(--primary-extra-light) 0%,
            transparent 20%),
        radial-gradient(circle at 90% 80%,
            var(--secondary-light) 0%,
            transparent 20%);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

/* Header más colorido */
header {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 1rem;
    box-shadow: var(--shadow-lg);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid var(--accent-color);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.75rem;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

/* Botones más vibrantes */
.btn {
    padding: 0.75rem 1.5rem;
    border-radius: var(--rounded-full);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: var(--shadow-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.9rem;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
}

.btn-outline:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Tarjetas de grupos más coloridas */
.groups-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.group-card {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border-top: 4px solid var(--primary-color);
    position: relative;
    overflow: hidden;
}

.group-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.group-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--gradient-primary);
}

.group-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--primary-dark);
    position: relative;
    display: inline-block;
}

.group-title::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 50px;
    height: 3px;
    background: var(--accent-color);
}

.group-info {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
}

.group-actions {
    display: flex;
    justify-content: space-between;
    margin-top: auto;
    gap: 0.5rem;
}

/* Modal más colorido */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    width: 90%;
    max-width: 500px;
    padding: 2.5rem 2rem;
    position: relative;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--primary-color);
}

/* Contenedor de dos columnas */
.modal-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (max-width: 600px) {
    .modal-content {
        width: 90%;
        max-width: 350px;
        /* Un poco más grande que los 300px originales */
        max-height: 80vh;
        /* En lugar de height fijo */
        padding: 1.5rem;
        overflow-y: auto;
        /* Permite scroll si el contenido es muy largo */
    }

    .modal-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.8rem;
        width: 100%;
    }

    /* Ajustes para los botones de ejercicio */
    .exercise-btn {
        padding: 1rem 0.5rem;
        font-size: 0.9rem;
        width: 100%;
        /* Ocupa todo el ancho disponible */
        min-width: 0;
        /* Permite que se ajuste al contenedor */
        box-sizing: border-box;
    }

    .modal-title {
        font-size: 1.4rem;
        margin-bottom: 1rem;
    }

    /* Ajustar íconos en móviles */
    .exercise-btn i {
        font-size: 1.5rem;
    }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.75rem;
    color: var(--danger-color);
    cursor: pointer;
    transition: transform 0.3s;
}

.modal-close:hover {
    transform: rotate(90deg);
    color: var(--danger-dark);
}

.modal-title {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    color: var(--primary-dark);
    text-align: center;
    position: relative;
    padding-bottom: 0.5rem;
}

.modal-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--gradient-accent);
    border-radius: 2px;
}

/* Botones de ejercicio más coloridos */
.exercise-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.exercise-btn {
    padding: 1.5rem 1rem;
    border-radius: var(--rounded-lg);
    border: none;
    color: var(--white);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    box-shadow: var(--shadow-md);
    font-size: 1.1rem;
}

.exercise-btn:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.exercise-btn i {
    font-size: 2rem;
}

/* Estilo individual para cada botón de ejercicio */
.exercise-btn:nth-child(1) {
    background: var(--gradient-primary);
}

.exercise-btn:nth-child(2) {
    background: var(--gradient-success);
}

.exercise-btn:nth-child(3) {
    background: var(--gradient-accent);
}

.exercise-btn:nth-child(4) {
    background: var(--gradient-danger);
}

/* Verbos - más colorido */
.search-container {
    margin: 2rem 0;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 1rem 1.5rem;
    border-radius: var(--rounded-full);
    border: 2px solid var(--primary-light);
    font-size: 1rem;
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    padding-left: 3rem;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2);
}

.search-container::before {
    content: "🔍";
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    color: var(--primary-color);
}

.verbs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.verb-card {
    background-color: var(--white);
    border-radius: var(--rounded-lg);
    padding: 1.75rem;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    cursor: pointer;
    border-left: 5px solid var(--secondary-color);
    position: relative;
    overflow: hidden;
}

.verb-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.verb-card::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 40px 40px 0;
    border-color: transparent var(--primary-light) transparent transparent;
}

.verb-infinitive {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.verb-infinitive::before {
    content: "•";
    color: var(--accent-color);
    font-size: 1.5rem;
}

.verb-partizip {
    color: var(--secondary-dark);
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 1.05rem;
}

.verb-translation {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
    font-style: italic;
}

.verb-auxiliar {
    color: var(--white);
    font-weight: bold;
    margin: 8px 0;
    font-size: 0.85em;
    background: var(--gradient-accent);
    padding: 4px 10px;
    border-radius: var(--rounded-full);
    display: inline-block;
}

/* Detalle de verbo más colorido */
.verb-detail {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2.5rem;
    margin-top: 2rem;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--primary-light);
    position: relative;
}

.verb-detail-title {
    font-size: 1.75rem;
    color: var(--primary-dark);
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--primary-light);
    position: relative;
}

.verb-detail-title::after {
    content: "";
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 100px;
    height: 3px;
    background: var(--gradient-accent);
}

.verb-detail-item {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
    border-left: 3px solid var(--primary-light);
}

.verb-detail-label {
    font-weight: 700;
    color: var(--primary-dark);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.verb-detail-label::before {
    content: "→";
    color: var(--accent-color);
}

.verb-detail-value {
    margin-top: 0.5rem;
    padding-left: 1.5rem;
    color: var(--text-dark);
    line-height: 1.6;
}

.verb-example {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(to right,
            var(--primary-extra-light),
            var(--white));
    border-radius: var(--rounded-lg);
    border-left: 5px solid var(--accent-color);
    box-shadow: var(--shadow-sm);
}

/* Pantalla de ejercicio más colorida */
.exercise-screen {
    position: relative;
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 3rem 2rem;
    margin-top: 2rem;
    box-shadow: var(--shadow-lg);
    text-align: center;
    border: 3px solid var(--primary-light);
    background-image: radial-gradient(circle at 10% 20%,
            rgba(219, 234, 254, 0.3) 0%,
            transparent 30%),
        radial-gradient(circle at 90% 80%,
            rgba(110, 231, 183, 0.3) 0%,
            transparent 30%);
}

.exercise-title {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    color: var(--primary-dark);
    position: relative;
    display: inline-block;
}

.exercise-title::after {
    content: "";
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.exercise-description {
    font-size: 1.15rem;
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

/* Efectos de hover adicionales */
.btn,
.group-card,
.verb-card,
.exercise-btn {
    transition: transform 0.3s ease, box-shadow 0.3s ease,
        background-color 0.3s ease, border-color 0.3s ease;
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-content,
.group-card,
.verb-card,
.exercise-screen {
    animation: fadeIn 0.5s ease forwards;
}

.group-stars {
    margin: 0.5rem 0;
    color: #fbbf24;
    font-size: 0.9rem;
}

.star-filled {
    color: #f59e0b;
}

.group-completed {
    border-left: 4px solid #10b981;
    position: relative;
}

.group-completed::after {
    content: "✓";
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    color: #10b981;
    font-size: 1.2rem;
}

/* Estilo para botones de ejercicio completados */
.exercise-btn.completed-exercise {
    position: relative;
    background: var(--correct-light) !important;
    color: var(--correct-dark) !important;
    border: 2px solid var(--correct) !important;
}

.completed-check {
    position: absolute;
    top: 5px;
    right: 5px;
    color: var(--correct);
    font-size: 1rem;
}

/* Actualiza el media query para pantallas pequeñas */
@media (max-width: 600px) {
    .exercise-btn.completed-exercise {
        padding: 1rem 0.5rem;
        font-size: 0.9rem;
    }

    .completed-check {
        font-size: 0.8rem;
        top: 3px;
        right: 3px;
    }
}

/* Estilos para los modales de autenticación */
.auth-container {
    padding: 1.5rem;
    max-width: 400px;
    margin: 0 auto;
}

.auth-title {
    color: var(--primary-dark);
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    color: var(--text-light);
    font-weight: 500;
}

.form-control {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--rounded-md);
    font-size: 1rem;
    transition: all 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.auth-btn {
    padding: 0.75rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--rounded-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 0.5rem;
}

.auth-btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.auth-link {
    text-align: center;
    margin-top: 1rem;
    color: var(--text-light);
}

.auth-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.auth-link a:hover {
    text-decoration: underline;
}

/* Estilos para los botones de login/registro en el header */
.header-buttons {
    display: flex;
    gap: 0.5rem;
}

.header-btn {
    padding: 0.5rem 1rem;
    border-radius: var(--rounded-full);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.header-btn.login {
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
}

.header-btn.login:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.header-btn.register {
    background-color: var(--white);
    border: 2px solid var(--white);
    color: var(--primary-dark);
    font-weight: 600;
}

.header-btn.register:hover {
    background-color: rgba(255, 255, 255, 0.9);
}

/* match*/
.match-game-container {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    padding: 20px;
}

.match-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 300px;
    min-height: 400px;
}

.column-title {
    font-weight: bold;
    margin-bottom: 1rem;
    font-size: 1.2rem;
    color: #3b82f6;
}

.match-box {
    padding: 1rem;
    margin: 0.5rem;
    background-color: #f8fafc;
    border-radius: 0.5rem;
    cursor: pointer;
    text-align: center;
    width: 100%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
}

.match-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    background-color: #e2e8f0;
}

.match-box.selected {
    background-color: #dbeafe;
    border: 2px solid #3b82f6;
}

.match-box.matched {
    background-color: #d1fae5;
    color: #065f46;
    cursor: default;
    border: 1px solid #a7f3d0;
}

#match-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#match-modal .modal-content {
    background-color: white;
    padding: 2rem;
    border-radius: 0.5rem;
    text-align: center;
    max-width: 400px;
}

#match-modal h2 {
    color: #10b981;
    margin-bottom: 1rem;
}

.modal-button {
    background-color: #3b82f6;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 1rem;
    transition: background-color 0.3s;
}

.modal-button:hover {
    background-color: #2563eb;
}

@keyframes celebrate {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

/* Match game styles */
.match-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}

.match-card {
    aspect-ratio: 1;
    perspective: 1000px;
    cursor: pointer;
}

.match-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.match-card.flipped .match-card-inner {
    transform: rotateY(180deg);
}

.match-card.matched {
    opacity: 0.6;
    cursor: default;
}

.match-card-front,
.match-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
}

.match-card-front {
    background-color: #f8fafc;
    color: #64748b;
    font-size: 1.5rem;
}

.match-card-back {
    background-color: #ffffff;
    color: #1e293b;
    transform: rotateY(180deg);
    font-weight: 600;
    padding: 0.5rem;
    word-break: break-word;
}

/* Estilo para el modal del juego Memory */
#memory-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#memory-modal .modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--primary-color);
}

#memory-modal h2 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

#memory-modal p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

/* Asegurar que los botones del modal sean consistentes */
#memory-modal .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

#memory-modal .btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
}

#memory-modal .btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

/* Animación para cuando aparece el modal */
#memory-modal.active {
    animation: fadeIn 0.3s ease forwards;
}

/* Media query para pantallas pequeñas */
@media (max-width: 480px) {
    #memory-modal .modal-content {
        padding: 1.5rem;
    }

    #memory-modal .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

/* Estilo para el modal del juego Match */
#match-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#match-modal .modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--secondary-color);
}

#match-modal h2 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

#match-modal p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

/* Asegurar que los botones del modal sean consistentes */
#match-modal .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

#match-modal .btn-primary {
    background: var(--gradient-success);
    color: var(--white);
}

#match-modal .btn-outline {
    background-color: transparent;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-dark);
}

/* Animación para cuando aparece el modal */
#match-modal.active {
    animation: fadeIn 0.3s ease forwards;
}

/* Media query para pantallas pequeñas */
@media (max-width: 480px) {
    #match-modal .modal-content {
        padding: 1.5rem;
    }

    #match-modal .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }

    #match-modal .modal-buttons {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* Agrega esto en tu sección de estilos CSS */

/* Estilo para el modal del juego Wort */
#wort-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#wort-modal .modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--accent-color);
}

#wort-modal h2 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

#wort-modal p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

/* Asegurar que los botones del modal sean consistentes */
#wort-modal .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

#wort-modal .btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
}

#wort-modal .btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

/* Animación para cuando aparece el modal */
#wort-modal.active {
    animation: fadeIn 0.3s ease forwards;
}

/* Media query para pantallas pequeñas */
@media (max-width: 480px) {
    #wort-modal .modal-content {
        padding: 1.5rem;
    }

    #wort-modal .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

/* Estilos para el modal de pago */
.payment-options {
    display: flex;
    margin-bottom: 1.5rem;
}

.payment-option {
    border: 2px solid #e2e8f0;
    border-radius: var(--rounded-lg);
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s;
    flex: 1;
    text-align: center;
}

.payment-option.selected {
    border-color: var(--primary-color);
    background-color: var(--primary-extra-light);
}

.payment-option h3 {
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.price {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-dark);
    margin-top: 0.5rem;
}

.payment-form {
    margin-top: 1.5rem;
}

.card-element {
    background: white;
    padding: 1rem;
    border-radius: var(--rounded-md);
    border: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.card-errors {
    color: var(--danger-color);
    min-height: 1.5rem;
    margin-bottom: 1rem;
}

.payment-methods {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
}

.payment-methods img {
    height: 30px;
    object-fit: contain;
}

.payment-success {
    text-align: center;
    padding: 1rem;
}

.success-icon {
    font-size: 3rem;
    color: var(--correct);
    margin-bottom: 1rem;
}

/* Hangman game styles */

/* Estilo para las letras correctas cuando se gana */
.word-display .correct-letter {
    color: #10b981;
    /* Verde para letras correctas */
    font-weight: bold;
}

/* Estilo para el botón de siguiente */
.next-btn {
    background-color: #8b5cf6;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-size: 1rem;
    cursor: pointer;
    margin-top: 1rem;
    transition: background-color 0.3s;
    display: none;
}

.next-btn:hover {
    background-color: #7c3aed;
}

/* Hangman Game Styles */
.hangman-container {
    width: 200px;
    height: 200px;
    margin: 1rem auto;
    position: relative;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: var(--rounded-lg);
    display: flex;
    justify-content: center;
    align-items: center;
}

.hangman-drawing {
    position: relative;
    width: 100%;
    height: 100%;
    background-color: var(--primary-color);
}

.hangman-part {
    position: absolute;
    background-color: var(--white);
    display: none;
}

/* Hangman parts */
.gallows-base {
    left: 20px;
    bottom: 0;
    width: 80px;
    height: 5px;
}

.gallows-post {
    left: 60px;
    bottom: 0;
    width: 5px;
    height: 160px;
}

.gallows-top {
    left: 60px;
    top: 20px;
    width: 60px;
    height: 5px;
}

.gallows-rope {
    left: 120px;
    top: 20px;
    width: 5px;
    height: 20px;
}

.head {
    left: 100px;
    top: 40px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 5px solid var(--white);
    background-color: transparent;
}

.body {
    left: 120px;
    top: 80px;
    width: 5px;
    height: 50px;
}

.left-arm {
    left: 120px;
    top: 90px;
    width: 30px;
    height: 5px;
    transform: rotate(-30deg);
    transform-origin: left;
}

.right-arm {
    left: 95px;
    top: 90px;
    width: 30px;
    height: 5px;
    transform: rotate(30deg);
    transform-origin: right;
}

.left-leg {
    left: 120px;
    top: 130px;
    width: 30px;
    height: 5px;
    transform: rotate(-30deg);
    transform-origin: left;
}

.right-leg {
    left: 95px;
    top: 130px;
    width: 30px;
    height: 5px;
    transform: rotate(30deg);
    transform-origin: right;
}

.verb-display {
    font-size: 1.5rem;
    margin: 0.5rem 0;
    font-weight: bold;
    text-align: center;
    min-height: 2rem;
    color: var(--accent-color);
}

.word-display {
    font-size: 2rem;
    letter-spacing: 0.5rem;
    margin: 0.5rem 0 1.5rem;
    font-weight: bold;
    text-align: center;
    min-height: 3rem;
}

.translation-display {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-light);
    text-align: center;
    font-style: italic;
}

.game-info {
    display: flex;
    justify-content: space-around;
    width: 100%;
    max-width: 300px;
    margin: 1rem auto;
    font-size: 1.1rem;
}

.game-info div {
    text-align: center;
}

.keyboard {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    position: relative;
    top: 10%;
    right: 50%;
    left: 50%;

    transform: translate(-50%, -9%);
    gap: 0.5rem;
    margin: 1rem 0;
    max-width: 500px
}

.letter-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: var(--white);
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: var(--shadow-sm);
}

.letter-btn:hover:not(:disabled) {
    transform: scale(1.1);
    box-shadow: var(--shadow-md);
}

.letter-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.letter-btn.correct {
    background-color: var(--correct);
}

.letter-btn.wrong {
    background-color: var(--wrong);
}

.game-over {
    text-align: center;
    margin-top: 1rem;
    font-size: 1.5rem;
    font-weight: bold;
    min-height: 4rem;
    color: var(--accent-color);
}

.next-word-info {
    font-size: 1rem;
    margin-top: 0.5rem;
    color: var(--accent-color);
    text-align: center;
}

.restart-btn {
    margin-top: 1rem;
    padding: 0.8rem 1.5rem;
    background-color: var(--accent-color);
    color: var(--white);
    border: none;
    border-radius: var(--rounded-full);
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: var(--shadow-sm);
}

.restart-btn:hover {
    transform: scale(1.05);
    background-color: var(--accent-dark);
    box-shadow: var(--shadow-md);
}

/* Modal específico para Hangman */
#hangman-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#hangman-modal .modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--accent-color);
}

#hangman-modal h2 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

#hangman-modal p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

#hangman-modal .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

#hangman-modal .btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
}

#hangman-modal .btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .hangman-container {
        width: 180px;
        height: 180px;
    }

    .letter-btn {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .word-display {
        font-size: 1.5rem;
        letter-spacing: 0.3rem;
    }

    .verb-display {
        font-size: 1.2rem;
    }

    .game-info {
        font-size: 0.9rem;
    }
}

@media (max-width: 400px) {
    .hangman-container {
        width: 150px;
        height: 150px;
    }

    .letter-btn {
        width: 30px;
        height: 30px;
        font-size: 0.9rem;
    }

    .word-display {
        font-size: 1.2rem;
    }

    .keyboard {
        gap: 0.3rem;
    }
}

/* Contenedor de botones de acción */
.hangman-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1rem;
}

/* Ajustes para los botones de reinicio y siguiente */
.restart-btn,
.next-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Estilo para el indicador de progreso */
.game-info div:nth-child(3) {
    font-weight: bold;
    color: #8b5cf6;
}

/* Ajustes para la pantalla del juego */
.hangman-container {
    margin: 1.5rem 0;
}

.word-display {
    font-size: 2rem;
    letter-spacing: 0.5rem;
    margin: 1.5rem 0;
    min-height: 3rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Estilos para el teclado */
.keyboard {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.5rem 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.letter-btn {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.5rem;
    background-color: white;
    cursor: pointer;
    transition: all 0.2s;
}

.letter-btn:hover:not(:disabled) {
    background-color: #f1f5f9;
    border-color: #cbd5e1;
}

.letter-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.letter-btn.correct {
    background-color: #10b981;
    color: white;
    border-color: #10b981;
}

.letter-btn.wrong {
    background-color: #ef4444;
    color: white;
    border-color: #ef4444;
}

/* Estilos para el dibujo del ahorcado */
.hangman-drawing {
    position: relative;
    width: 250px;
    height: 250px;
    margin: 0 auto;
}

.hangman-part {
    position: absolute;
    display: none;
    background-color: #334155;
}

/* Partes específicas del ahorcado */
.gallows-base {
    width: 150px;
    height: 10px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.gallows-post {
    width: 10px;
    height: 200px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.gallows-top {
    width: 100px;
    height: 10px;
    top: 0;
    left: 50%;
}

.gallows-rope {
    width: 5px;
    height: 30px;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
}

.head {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    top: 40px;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid #334155;
    background-color: transparent;
}

.body {
    width: 5px;
    height: 70px;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
}

.left-arm,
.right-arm {
    width: 50px;
    height: 5px;
    top: 100px;
}

.left-arm {
    left: calc(50% - 45px);
    transform: rotate(30deg);
    transform-origin: right;
}

.right-arm {
    left: calc(50% + 5px);
    transform: rotate(-30deg);
    transform-origin: left;
}

.left-leg,
.right-leg {
    width: 50px;
    height: 5px;
    top: 150px;
}

.left-leg {
    left: calc(50% - 45px);
    transform: rotate(-30deg);
    transform-origin: right;
}

.right-leg {
    left: calc(50% + 5px);
    transform: rotate(30deg);
    transform-origin: left;
}

/* Mensaje de fin de juego */
.game-over {
    font-size: 1.25rem;
    font-weight: bold;
    margin: 1rem 0;
    text-align: center;
    min-height: 2rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .keyboard {
        gap: 0.3rem;
    }

    .letter-btn {
        width: 2rem;
        height: 2rem;
        font-size: 0.9rem;
    }

    .word-display {
        font-size: 1.5rem;
        letter-spacing: 0.3rem;
    }
}

/* Back button */
.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 500;
}

.wort-game-container {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
    padding: 1rem;
}

.wort-infinitive {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.wort-translation {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-style: italic;
}

.wort-target-container,
.wort-letters-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    min-height: 60px;
}

.wort-letter-box {
    width: 50px;
    height: 50px;
    background-color: var(--primary-extra-light);
    border-radius: var(--rounded-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    user-select: none;
    border: 2px solid var(--primary-light);
    box-shadow: var(--shadow-sm);
}

.wort-letter-box.target-letter {
    background-color: white;
    cursor: default;
}

.wort-letter-box:hover:not(.target-letter) {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
}

/* Estilo para letras correctas */
.wort-letter-box.correct {
    background-color: var(--correct);
    color: white;
    border-color: var(--correct);
    transform: scale(1.05);
    animation: pop 0.3s ease;
}

/* Estilo para letras incorrectas */
.wort-letter-box.incorrect {
    background-color: var(--wrong);
    color: white;
    border-color: var(--wrong);
    animation: shake 0.5s, fadeOut 1s 0.5s forwards;
}

/* Animaciones */
@keyframes pop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1.05);
    }
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    20%,
    60% {
        transform: translateX(-5px);
    }

    40%,
    80% {
        transform: translateX(5px);
    }
}

@keyframes fadeOut {
    to {
        opacity: 0.7;
        background-color: var(--primary-extra-light);
        color: var(--text-dark);
        border-color: var(--primary-light);
    }
}

.wort-feedback {
    min-height: 1.5rem;
    margin: 1rem auto;
    font-size: 1.1rem;
    padding: 0.75rem;
    border-radius: var(--rounded-md);
    transition: all 0.3s ease;
    max-width: 80%;
}

.wort-feedback.wort-correct-feedback {
    background-color: rgba(76, 175, 80, 0.2);
    color: var(--correct);
    border-left: 4px solid var(--correct);
}

.wort-feedback.wort-incorrect-feedback {
    background-color: rgba(239, 68, 68, 0.2);
    color: var(--wrong);
    border-left: 4px solid var(--wrong);
}

/* Memory Game Styles */
.memory-game-container {
    max-width: 600px;
    margin: 1.5rem auto;
    text-align: center;
}

.memory-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(4, 1fr);
    gap: 0.8rem;
    margin-top: 1.5rem;
}

.memory-card {
    aspect-ratio: 1;
    perspective: 1000px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.memory-card:hover {
    transform: scale(1.05);
}

.memory-card.matched {
    cursor: default;
    animation: pulse 0.5s ease;
}

.memory-card.matched:hover {
    transform: none;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

.memory-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
    border-radius: var(--rounded-md);
    box-shadow: var(--shadow-md);
}

.memory-card.flipped .memory-card-inner {
    transform: rotateY(180deg);
}

.memory-card.matched .memory-card-inner {
    box-shadow: 0 0 15px rgba(0, 200, 0, 0.6);
}

.memory-card-front,
.memory-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--rounded-md);
    padding: 0.5rem;
}

.memory-card-front {
    background-color: var(--primary-color);
    color: white;
    font-size: 1.5rem;
    transition: background-color 0.3s;
}

.memory-card:hover .memory-card-front {
    background-color: var(--primary-dark);
}

.memory-card-back {
    background-color: var(--white);
    color: var(--text-dark);
    transform: rotateY(180deg);
    font-weight: 600;
    word-break: break-word;
    flex-direction: column;
    border: 2px solid var(--primary-light);
}

.memory-card-back .infinitive {
    font-weight: bold;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.memory-card-back .translation {
    font-size: 0.8rem;
    color: var(--text-light);
}

.memory-game-info {
    display: flex;
    justify-content: space-around;
    width: 100%;
    max-width: 300px;
    margin: 1rem auto;
    font-size: 1.2rem;
}

@media (max-width: 400px) {
    .memory-grid {
        gap: 0.2rem;
        /* Espacio mínimo entre cartas */
    }

    .memory-card-front {
        font-size: 0.8rem;
        /* Tamaño mínimo legible */
    }

    .memory-card-back .infinitive {
        font-size: 0.65rem;
    }

    .memory-card-back .partizip {
        font-size: 0.65rem;
    }

    .memory-card-back .translation {
        font-size: 0.55rem;
    }
}

/* Drag & Drop Styles - Versión Mejorada */
.dragdrop-container {
    max-width: 90%;
    margin: 0 auto;
    padding: 1rem;
    touch-action: none;
}

.dragdrop-columns {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .dragdrop-columns {
        flex-direction: row;
    }
}

/* Modificación para mostrar columnas una al lado de otra en móviles */
@media (max-width: 767px) {
    .dragdrop-columns {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }

    .dragdrop-column-title {
        font-size: 0.85rem;
    }
}

.dragdrop-column {
    flex: 1;
    background-color: #f8f9fa;
    border-radius: 0.75rem;
    padding: 0.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.dragdrop-column-title {
    font-weight: bold;
    margin-bottom: 0.75rem;
    text-align: center;
    color: #495057;
    font-size: 1rem;
}

.dragdrop-items {
    min-height: 120px;
    border: 2px dashed #adb5bd;
    border-radius: 0.5rem;
    padding: 0.75rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    transition: all 0.3s;
}

.dragdrop-items.drop-target-active {
    background-color: #e6f7ff;
    border-color: #1890ff;
    border-style: solid;
}

#verbs-container {
    min-height: 80px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

/* Estilo mejorado para los items */
.dragdrop-item {
    background-color: #3b82f6;
    /* Azul principal */
    color: white;
    border: 1px solid #2563eb;
    /* Borde azul más oscuro */
    border-radius: 0.5rem;
    padding: 0.5rem;
    text-align: center;
    cursor: grab;
    font-size: 0.8rem;
    transition: all 0.2s;
    user-select: none;
    touch-action: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    min-width: 80px;
    /* Tamaño fijo */
    min-height: 40px;
    /* Altura fija */
    display: flex;
    align-items: center;
    justify-content: center;
}

.dragdrop-item.dragging {
    opacity: 0.8;
    transform: scale(1.05);
}

.drag-clone {
    background-color: #3b82f6;
    color: white;
    border: 2px solid #1d4ed8;
    border-radius: 0.5rem;
    padding: 0.5rem;
    text-align: center;
    font-size: 0.8rem;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.5);
    min-width: 80px;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Resultados - Manteniendo colores de feedback */
.dragdrop-item.dragdrop-correct {
    background-color: #10b981;
    border-color: #059669;
}

.dragdrop-item.dragdrop-incorrect {
    background-color: #ef4444;
    border-color: #dc2626;
}

.dragdrop-item.dragdrop-missing {
    background-color: #f59e0b;
    border-color: #d97706;
    animation: pulse 1.5s infinite;
}

.dragdrop-feedback {
    margin: 1rem 0;
    padding: 0.75rem;
    border-radius: 0.5rem;
    text-align: center;
    font-size: 0.9rem;
}

.dragdrop-results {
    background-color: #e0e7ff;
    color: #3730a3;
}

.dragdrop-results .missing-verbs {
    color: #d97706;
    font-weight: bold;
}

.btn-check {
    display: block;
    margin: 1rem auto;
    padding: 0.75rem 1.5rem;
    background-color: #4f46e5;
    color: white;
    border: none;
    border-radius: 0.75rem;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.2s;
}

.btn-check:hover {
    background-color: #4338ca;
    transform: translateY(-2px);
}

/* Animaciones */
@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

.drop-target-active {
    animation: pulse 1.5s infinite;
}

/* Ajustes para pantallas muy pequeñas */
@media (max-width: 480px) {
    .dragdrop-container {
        max-width: 100%;
        padding: 0.5rem;
    }

    .dragdrop-item,
    .drag-clone {
        min-width: 70px;
        font-size: 0.75rem;
        padding: 0.4rem;
    }

    #verbs-container {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    }
}

/* Estilos base existentes (conservando tus variables CSS) */
.match-columns-container {
    display: flex;
    justify-content: center;
    gap: 1rem;
    /* Reducido de 2rem a 1rem para acercar las columnas */
    margin: 1.5rem auto;
    /* Centrado horizontal */
    max-width: 500px;
    /* Limitar el ancho máximo para mantener la proximidad */
    padding: 0 1rem;
    /* Padding para evitar que toquen los bordes en móviles */
}

.match-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 45%;
    min-width: 200px;
    /* Reducido de 250px para pantallas más pequeñas */
}

.match-column h3 {
    margin-bottom: 1rem;
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: 600;
}

.match-item {
    width: 170px;
    padding: 0.8rem;
    margin: 0.4rem 0;
    background-color: var(--bg-color-light);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    text-align: center;
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.match-item:hover {
    background-color: var(--hover-color-light);
    transform: translateY(-1px);
}

.match-item.selected {
    background-color: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary-dark);
    font-weight: 500;
}

.match-item.matched {
    background-color: var(--correct-light);
    border-color: var(--correct);
    color: var(--correct-dark);
    cursor: default;
}

/* Feedback y progreso (estilo original mejorado) */
.match-feedback {
    margin: 1rem 0;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    min-height: 1.5rem;
    color: var(--text-color);
}

.match-progress {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* Modal (nuevo, pero con estilos coherentes) */
.match-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.match-modal-content {
    background-color: var(--bg-color);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    text-align: center;
    max-width: 350px;
    width: 90%;
    box-shadow: var(--shadow-md);
}

.match-modal h2 {
    color: var(--primary);
    margin-bottom: 0.8rem;
    font-size: 1.3rem;
}

.match-modal p {
    color: var(--text-muted);
    margin-bottom: 1.2rem;
    font-size: 0.95rem;
}

.match-modal-button {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: var(--border-radius-sm);
    font-size: 0.9rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.match-modal-button:hover {
    background-color: var(--primary-dark);
}

/* Animaciones (nuevas pero discretas) */
@keyframes match-celebrate {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

.match-celebrate {
    animation: match-celebrate 0.3s ease;
}

/* Ajustes para pantallas pequeñas - AHORA MANTIENE 2 COLUMNAS */
@media (max-width: 640px) {
    .match-columns-container {
        flex-wrap: wrap;
        /* Permite que las columnas se mantengan en línea */
        gap: 0.8rem;
        /* Espacio más reducido */
    }

    .match-column {
        width: 48%;
        /* Ajuste para mantener 2 columnas */
        min-width: 150px;
        /* Más pequeño para pantallas estrechas */
    }

    .match-item {
        width: 90px;
        /* Más compacto en móviles */
        padding: 0.6rem;
        font-size: 0.9rem;
    }
}

/* Ajuste adicional para pantallas muy pequeñas */
@media (max-width: 400px) {
    .match-column {
        width: 46%;
        /* Un poco más estrecho */
        min-width: 120px;
    }

    .match-item {
        width: 130px;
        padding: 0.5rem;
        font-size: 0.85rem;
    }
}

/* Estilos para los botones de sonido */
.sound-btn {
    background: none;
    border: none;
    color: #3b82f6;
    cursor: pointer;
    font-size: 1rem;
    padding: 0.25rem;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    background-color: rgba(59, 130, 246, 0.1);
}

.sound-btn:hover {
    color: #2563eb;
    background-color: rgba(59, 130, 246, 0.2);
    transform: scale(1.1);
}

.sound-btn:active {
    transform: scale(0.95);
}

/* Feedback visual durante reproducción */
.sound-btn .fa-volume-high {
    color: #10b981;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

/* Hangman Game Styles */
.hangman-container {
    width: 200px;
    height: 200px;
    margin: 1rem auto;
    position: relative;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: var(--rounded-lg);
    display: flex;
    justify-content: center;
    align-items: center;
}

.hangman-drawing {
    position: relative;
    width: 100%;
    height: 100%;
}

.hangman-part {
    position: absolute;
    background-color: var(--white);
    display: none;
}

/* Hangman parts */
.gallows-base {
    left: 20px;
    bottom: 0;
    width: 80px;
    height: 5px;
}

.gallows-post {
    left: 60px;
    bottom: 0;
    width: 5px;
    height: 160px;
}

.gallows-top {
    left: 60px;
    top: 20px;
    width: 60px;
    height: 5px;
}

.gallows-rope {
    left: 120px;
    top: 20px;
    width: 5px;
    height: 20px;
}

.head {
    left: 100px;
    top: 40px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 5px solid var(--white);
    background-color: transparent;
}

.body {
    left: 120px;
    top: 80px;
    width: 5px;
    height: 50px;
}

.left-arm {
    left: 120px;
    top: 90px;
    width: 30px;
    height: 5px;
    transform: rotate(-30deg);
    transform-origin: left;
}

.right-arm {
    left: 95px;
    top: 90px;
    width: 30px;
    height: 5px;
    transform: rotate(30deg);
    transform-origin: right;
}

.left-leg {
    left: 120px;
    top: 130px;
    width: 30px;
    height: 5px;
    transform: rotate(-30deg);
    transform-origin: left;
}

.right-leg {
    left: 95px;
    top: 130px;
    width: 30px;
    height: 5px;
    transform: rotate(30deg);
    transform-origin: right;
}

.verb-display {
    font-size: 1.5rem;
    margin: 0.5rem 0;
    font-weight: bold;
    text-align: center;
    min-height: 2rem;
    color: var(--accent-color);
}

.word-display {
    font-size: 2rem;
    letter-spacing: 0.5rem;
    margin: 0.5rem 0 1.5rem;
    font-weight: bold;
    text-align: center;
    min-height: 3rem;
}

.translation-display {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-light);
    text-align: center;
    font-style: italic;
}

.game-info {
    display: flex;
    justify-content: space-around;
    width: 100%;
    max-width: 300px;
    margin: 1rem auto;
    font-size: 1.1rem;
}

.game-info div {
    text-align: center;
}

.keyboard {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin: 1rem 0;
    max-width: 500px;
}

.letter-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: var(--white);
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: var(--shadow-sm);
}

.letter-btn:hover:not(:disabled) {
    transform: scale(1.1);
    box-shadow: var(--shadow-md);
}

.letter-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.letter-btn.correct {
    background-color: var(--correct);
}

.letter-btn.wrong {
    background-color: var(--wrong);
}

.game-over {
    text-align: center;
    margin-top: 1rem;
    font-size: 1.5rem;
    font-weight: bold;
    min-height: 4rem;
    color: var(--accent-color);
}

.next-word-info {
    font-size: 1rem;
    margin-top: 0.5rem;
    color: var(--accent-color);
    text-align: center;
}

.restart-btn {
    margin-top: 1rem;
    padding: 0.8rem 1.5rem;
    background-color: var(--accent-color);
    color: var(--white);
    border: none;
    border-radius: var(--rounded-full);
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: var(--shadow-sm);
}

.restart-btn:hover {
    transform: scale(1.05);
    background-color: var(--accent-dark);
    box-shadow: var(--shadow-md);
}

/* Modal específico para Hangman */
#hangman-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#hangman-modal .modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--accent-color);
}

#hangman-modal h2 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

#hangman-modal p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

#hangman-modal .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

#hangman-modal .btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
}

#hangman-modal .btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .hangman-container {
        width: 180px;
        height: 180px;
    }

    .letter-btn {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .word-display {
        font-size: 1.5rem;
        letter-spacing: 0.3rem;
    }

    .verb-display {
        font-size: 1.2rem;
    }

    .game-info {
        font-size: 0.9rem;
    }
}

@media (max-width: 400px) {
    .hangman-container {
        width: 150px;
        height: 150px;
    }

    .letter-btn {
        width: 30px;
        height: 30px;
        font-size: 0.9rem;
    }

    .word-display {
        font-size: 1.2rem;
    }

    .keyboard {
        gap: 0.3rem;
    }
}

/* Estilo específico para el modal de Auxiliar DragDrop */
/* Estilos para el modal de Auxiliar DragDrop */
#auxiliar-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    /* Mayor que otros elementos */
    animation: fadeIn 0.3s ease-out;
}

#auxiliar-modal.active {
    display: flex;
}

#auxiliar-modal .modal-content {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    max-width: 90%;
    width: 400px;
    padding: 2rem;
    border: 3px solid #8b5cf6;
    text-align: center;
    position: relative;
    transform: translateY(0);
    opacity: 1;
    transition: all 0.3s ease;
}

#auxiliar-modal h2 {
    color: #8b5cf6;
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
}

.modal-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

/* Para pantallas pequeñas */
@media (max-width: 480px) {
    #auxiliar-modal .modal-content {
        padding: 1.5rem;
        width: 90%;
    }

    .modal-buttons {
        flex-direction: column;
        gap: 0.5rem;
    }

    #auxiliar-modal h2 {
        font-size: 1.5rem;
    }
}

/* Animación de entrada */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Efecto al aparecer */
#auxiliar-modal .modal-content {
    animation: modalSlideIn 0.4s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}


/* Perfekt Game Styles */
.perfekt-game-container {
    max-width: 600px;
    margin: 2rem auto;
    text-align: center;
}

.progress-bar {
    width: 100%;
    height: 20px;
    background-color: #e0e0e0;
    border-radius: 10px;
    margin: 1rem 0;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.sentence-container {
    min-height: 60px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 1rem;
    border-bottom: 2px solid var(--primary-light);
}

.word-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.word-box {
    padding: 0.5rem 1rem;
    background-color: var(--primary-light);
    border-radius: var(--rounded-md);
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.word-box:hover {
    background-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

.word-box.incorrect {
    background-color: var(--wrong);
    color: var(--white);
    animation: shake 0.5s;
}

.perfekt-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.perfekt-modal-content {
    background-color: var(--white);
    border-radius: var(--rounded-xl);
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--accent-color);
}

.perfekt-modal-button {
    margin: 0.5rem;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: var(--rounded-md);
    background-color: var(--primary-color);
    color: var(--white);
    cursor: pointer;
    transition: all 0.2s;
}

.perfekt-modal-button:hover {
    background-color: var(--primary-dark);
}

/* Mobile optimizations */
@media (max-width: 600px) {
    .dragdrop-column {
        width: 100%;
    }

    .dragdrop-item {
        padding: 0.5rem 0.7rem;
        font-size: 0.85rem;
    }
}

/* Responsive */
@media (max-width: 768px) {

    .groups-grid,
    .verbs-grid {
        grid-template-columns: 1fr;
    }

    .exercise-buttons {
        grid-template-columns: 1fr;
    }

    .letter-btn {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .word-display {
        font-size: 1.5rem;
        letter-spacing: 0.3rem;
    }

    .match-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .match-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
