/* Aventuras en París - Estilos Globales y Diseño Premium */

:root {
    --font-sans: 'Nunito', system-ui, -apple-system, sans-serif;
    --font-display: 'Fredoka', cursive, system-ui, sans-serif;

    --paris-blue: #1E3A8A;
    --paris-blue-light: #2563EB;
    --paris-gold: #F59E0B;
    --paris-gold-light: #FBBF24;
    --paris-red: #EF4444;
    --paris-green: #10B981;
    --paris-bg: #F8FAFC;
    --paris-card-bg: #FFFFFF;
}

body {
    font-family: var(--font-sans);
    background-color: var(--paris-bg);
    color: #1E293B;
    min-height: 100vh;
    margin: 0;
}

.font-display {
    font-family: var(--font-display);
}

.fw-black {
    font-weight: 900;
}

/* Sidebar & Brand */
.french-sidebar-header {
    background: linear-gradient(135deg, #1E3A8A 0%, #1D4ED8 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar {
    background: #0F172A;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.05);
}

.sidebar .nav-link {
    color: #94A3B8;
    font-weight: 600;
    transition: all 0.2s ease;
    padding: 0.65rem 1rem;
}

.sidebar .nav-link:hover {
    color: #FFFFFF;
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateX(4px);
}

.sidebar .nav-link.active {
    color: #FFFFFF;
    background: linear-gradient(90deg, #2563EB 0%, #3B82F6 100%);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
}

.nav-icon {
    display: inline-block;
    width: 24px;
    margin-right: 6px;
    text-align: center;
}

/* Student Header Bar */
.student-header-bar {
    background: linear-gradient(135deg, #FFFFFF 0%, #F1F5F9 100%);
    border: 1px solid #E2E8F0;
}

.avatar-circle {
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
    border-radius: 50%;
}

/* 3D Flip Card System (Tema 1, Tema 2, etc.) */
.flip-card-wrapper {
    background-color: transparent;
    perspective: 1000px;
    height: 320px;
    cursor: pointer;
}

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

.flip-card-wrapper.flipped .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 1.25rem;
    box-sizing: border-box;
}

.flip-card-front {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.flip-card-wrapper:hover .flip-card-front {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.12) !important;
}

.flip-card-back {
    transform: rotateY(180deg);
    background: #F8FAFC;
    border: 2px solid #3B82F6;
}

.card-svg-box {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Speaker Audio Button */
.audio-speaker-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #EFF6FF;
    color: #2563EB;
    border: 1px solid #BFDBFE;
    border-radius: 9999px;
    padding: 0.4rem 0.75rem;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.audio-speaker-btn:hover {
    background: #2563EB;
    color: #FFFFFF;
    border-color: #2563EB;
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.audio-speaker-btn:active {
    transform: scale(0.95);
}

/* Star Rating */
.star-icon.filled {
    filter: drop-shadow(0 2px 4px rgba(245, 158, 11, 0.4));
}

.star-icon.empty {
    opacity: 0.45;
}

/* Paint Pot Cards & Interactive Colors (Tema 2) */
.paint-pot-card {
    background: #FFFFFF;
    transition: all 0.25s ease;
}

.paint-pot-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.08) !important;
}

.cursor-pointer {
    cursor: pointer;
}

.scale-up {
    transform: scale(1.04);
}

/* Number Key Buttons (Tema 2 Ábaco) */
.number-key-btn {
    background: #FFFFFF;
    color: #1E293B;
    border: 2px solid #E2E8F0 !important;
    transition: all 0.2s ease;
}

.number-key-btn:hover {
    background: #FEF3C7;
    border-color: #F59E0B !important;
    transform: translateY(-3px);
}

.number-key-btn.active-number-btn {
    background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
    color: #FFFFFF;
    border-color: #B45309 !important;
    box-shadow: 0 8px 16px rgba(217, 119, 6, 0.35);
    transform: scale(1.05);
}

.count-object-item {
    font-size: 1.8rem;
    user-select: none;
}

/* Canvas Zones (Tema 2 Misión) */
.canvas-zone {
    transition: fill 0.35s ease, stroke-width 0.2s ease;
}

.canvas-zone:hover {
    stroke: #2563EB;
    stroke-width: 3.5;
}

/* Diploma Styles */
.bg-cream {
    background-color: #FFFDF9;
}

.diploma-frame {
    border: 8px double #D97706;
    background-image: radial-gradient(#FDE68A 1px, transparent 1px);
    background-size: 18px 18px;
}

.french-ribbon-bar {
    width: 90px;
    height: 8px;
    background: linear-gradient(90deg, #1E3A8A 33.3%, #FFFFFF 33.3%, #FFFFFF 66.6%, #EF4444 66.6%);
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.student-diploma-name {
    font-size: 2.2rem;
    font-family: var(--font-display);
    color: #1E3A8A;
    border-bottom: 3px solid #F59E0B;
    letter-spacing: 0.5px;
}

.diploma-seal {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: radial-gradient(circle, #FDE047 0%, #D97706 100%);
    box-shadow: 0 6px 16px rgba(217, 119, 6, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px dashed #FFFBEB;
}

.seal-inner {
    text-align: center;
    line-height: 1;
}

.seal-star {
    display: block;
    font-size: 14px;
    color: #78350F;
}

.seal-text {
    display: block;
    font-size: 8px;
    font-weight: 900;
    color: #78350F;
    letter-spacing: 1px;
}

.seal-sub {
    display: block;
    font-size: 7px;
    font-weight: 800;
    color: #78350F;
}

.font-signature {
    font-family: 'Brush Script MT', cursive, sans-serif;
    font-size: 1.4rem;
    color: #1E3A8A;
}

/* Animations */
@keyframes bounce-gentle {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.bounce-gentle {
    animation: bounce-gentle 3s ease-in-out infinite;
}

@keyframes pop {
    0% { transform: scale(0.9); opacity: 0; }
    70% { transform: scale(1.05); }
    100% { transform: scale(1); opacity: 1; }
}

.animate-pop {
    animation: pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fadeIn 0.35s ease-out forwards;
}

.hover-translate-up:hover {
    transform: translateY(-5px);
}

.transition-all {
    transition: all 0.25s ease;
}

.scale-up {
    transform: scale(1.05);
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-8px); }
    40%, 80% { transform: translateX(8px); }
}

.animate-shake {
    animation: shake 0.4s ease-in-out;
}

@keyframes bounceShort {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

.animate-bounce-short {
    animation: bounceShort 0.5s ease-in-out 3;
}

/* Custom Theme Color Utilities */
.btn-pink {
    background-color: #EC4899;
    border-color: #EC4899;
    color: #FFFFFF;
}
.btn-pink:hover {
    background-color: #DB2777;
    border-color: #DB2777;
    color: #FFFFFF;
}
.bg-pink {
    background-color: #EC4899 !important;
}
.bg-pink-50 {
    background-color: #FDF2F8 !important;
}
.text-pink {
    color: #BE185D !important;
}
.border-pink {
    border-color: #F472B6 !important;
}

.btn-teal {
    background-color: #14B8A6;
    border-color: #14B8A6;
    color: #FFFFFF;
}
.btn-teal:hover {
    background-color: #0D9488;
    border-color: #0D9488;
    color: #FFFFFF;
}
.bg-teal {
    background-color: #14B8A6 !important;
}
.bg-teal-50 {
    background-color: #F0FDFA !important;
}
.text-teal {
    color: #0F766E !important;
}
.border-teal {
    border-color: #2DD4BF !important;
}

.btn-purple {
    background-color: #8B5CF6;
    border-color: #8B5CF6;
    color: #FFFFFF;
}
.btn-purple:hover {
    background-color: #7C3AED;
    border-color: #7C3AED;
    color: #FFFFFF;
}
.bg-purple {
    background-color: #8B5CF6 !important;
}
.bg-purple-50 {
    background-color: #FAF5FF !important;
}
.text-purple {
    color: #6D28D9 !important;
}
.border-purple {
    border-color: #A78BFA !important;
}

/* Tarjetas de opciones de la misión (Tema 1) */
.option-card {
    transition: all 0.25s ease-in-out;
    background-color: #FFFFFF;
}

.option-card .option-text {
    color: #2563EB;
    transition: color 0.2s ease-in-out;
}

.option-card .option-sub {
    color: #64748B;
    transition: color 0.2s ease-in-out;
}

.option-card:hover {
    background-color: #2563EB !important;
    border-color: #2563EB !important;
    transform: translateY(-4px);
    box-shadow: 0 10px 20px -5px rgba(37, 99, 235, 0.35) !important;
}

.option-card:hover .option-text,
.option-card:hover .option-sub,
.option-card:hover span,
.option-card:hover small,
.option-card:hover * {
    color: #FFFFFF !important;
}

@keyframes pulseBorder {
    0%, 100% { box-shadow: 0 0 0 0 rgba(236, 72, 153, 0.4); }
    50% { box-shadow: 0 0 0 10px rgba(236, 72, 153, 0); }
}
.pulse-border {
    animation: pulseBorder 1.8s infinite;
}

.school-image-option:hover {
    transform: translateY(-6px) scale(1.03);
    border-color: #10B981 !important;
    box-shadow: 0 12px 24px -6px rgba(16, 185, 129, 0.25) !important;
}

/* Print Diploma */
@media print {
    body * {
        visibility: hidden;
    }
    .diploma-frame, .diploma-frame * {
        visibility: visible;
    }
    .diploma-frame {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        border: 4px double #000;
    }
}