/* ============================================
   MONSTER HUNTER RPG - Style Principal
   ============================================ */

:root {
    /* Couleurs néon */
    --neon-cyan: #00fff7;
    --neon-magenta: #ff00ff;
    --neon-yellow: #ffff00;
    --neon-green: #00ff88;
    --neon-orange: #ff6600;
    --neon-red: #ff3366;
    --neon-purple: #aa55ff;

    /* Couleurs de fond */
    --bg-dark: #050508;
    --bg-darker: #020203;
    --bg-card: rgba(13, 6, 24, 0.9);
    --bg-card-hover: rgba(26, 10, 48, 0.95);

    /* Texte */
    --text-light: #f0f0ff;
    --text-dim: rgba(255, 255, 255, 0.6);
    --text-dimmer: rgba(255, 255, 255, 0.4);

    /* Raretés */
    --rarity-common: #9d9d9d;
    --rarity-uncommon: #1eff00;
    --rarity-rare: #0070dd;
    --rarity-epic: #a335ee;
    --rarity-legendary: #ff8000;

    /* Classes */
    --class-warrior: #c79c6e;
    --class-mage: #69ccf0;
    --class-archer: #abd473;
    --class-priest: #ffffff;
    --class-rogue: #fff569;
    --class-paladin: #f58cba;

    /* Ombres néon */
    --glow-cyan: 0 0 10px var(--neon-cyan), 0 0 20px var(--neon-cyan), 0 0 40px var(--neon-cyan);
    --glow-magenta: 0 0 10px var(--neon-magenta), 0 0 20px var(--neon-magenta);
    --glow-green: 0 0 10px var(--neon-green), 0 0 20px var(--neon-green);

    /* Dimensions */
    --header-height: 60px;
}

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

html {
    font-size: 16px;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: var(--bg-dark);
    color: var(--text-light);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* ============================================
   EFFETS DE FOND
   ============================================ */

.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(0, 255, 247, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 247, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
    z-index: 0;
}

.bg-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(255, 0, 255, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(0, 255, 247, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.scanline {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.1) 2px,
        rgba(0, 0, 0, 0.1) 4px
    );
    pointer-events: none;
    z-index: 1000;
}

/* ============================================
   LAYOUT PRINCIPAL
   ============================================ */

.game-container {
    position: relative;
    z-index: 10;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.screen {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.screen.active {
    display: flex;
}

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

/* ============================================
   HEADER
   ============================================ */

.game-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: linear-gradient(180deg, rgba(5, 5, 8, 0.95), rgba(5, 5, 8, 0.8));
    border-bottom: 2px solid var(--neon-cyan);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 100;
    box-shadow: 0 0 20px rgba(0, 255, 247, 0.2);
}

.game-header.hidden {
    display: none;
}

.header-left, .header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-title {
    font-family: 'Orbitron', monospace;
    font-size: 1.2rem;
    color: var(--neon-cyan);
    text-shadow: var(--glow-cyan);
    letter-spacing: 0.1em;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.player-level {
    font-family: 'Orbitron', monospace;
    font-size: 0.9rem;
    color: var(--neon-yellow);
    background: rgba(255, 255, 0, 0.1);
    padding: 5px 12px;
    border: 1px solid var(--neon-yellow);
    border-radius: 4px;
}

.player-name {
    font-size: 1rem;
    color: var(--text-light);
}

/* ============================================
   BOUTONS
   ============================================ */

.btn {
    font-family: 'Orbitron', monospace;
    font-size: 1rem;
    font-weight: 700;
    padding: 12px 30px;
    border: 2px solid var(--neon-cyan);
    background: transparent;
    color: var(--neon-cyan);
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 247, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    background: var(--neon-cyan);
    color: var(--bg-dark);
    box-shadow: var(--glow-cyan);
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    border-color: var(--neon-magenta);
    color: var(--neon-magenta);
}

.btn-primary:hover {
    background: var(--neon-magenta);
    box-shadow: var(--glow-magenta);
}

.btn-success {
    border-color: var(--neon-green);
    color: var(--neon-green);
}

.btn-success:hover {
    background: var(--neon-green);
    box-shadow: var(--glow-green);
}

.btn-danger {
    border-color: var(--neon-red);
    color: var(--neon-red);
}

.btn-danger:hover {
    background: var(--neon-red);
    box-shadow: 0 0 10px var(--neon-red), 0 0 20px var(--neon-red);
}

.btn-small {
    font-size: 0.8rem;
    padding: 8px 16px;
}

.btn-large {
    font-size: 1.2rem;
    padding: 16px 40px;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn:disabled:hover {
    background: transparent;
    transform: none;
    box-shadow: none;
}

/* ============================================
   ÉCRAN TITRE
   ============================================ */

.title-screen {
    text-align: center;
}

.game-logo {
    margin-bottom: 40px;
}

.game-logo h1 {
    font-family: 'Orbitron', monospace;
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: 900;
    color: var(--neon-cyan);
    text-shadow: var(--glow-cyan);
    letter-spacing: 0.1em;
    line-height: 1.2;
    animation: neonPulse 2s ease-in-out infinite;
}

.game-logo h1 span {
    display: block;
    font-size: 0.5em;
    color: var(--neon-magenta);
    text-shadow: var(--glow-magenta);
    letter-spacing: 0.3em;
}

@keyframes neonPulse {
    0%, 100% {
        filter: brightness(1);
        text-shadow: var(--glow-cyan);
    }
    50% {
        filter: brightness(1.2);
        text-shadow: 0 0 20px var(--neon-cyan), 0 0 40px var(--neon-cyan), 0 0 60px var(--neon-cyan);
    }
}

.title-subtitle {
    font-size: 1.2rem;
    color: var(--text-dim);
    letter-spacing: 0.5em;
    margin-bottom: 60px;
    text-transform: uppercase;
}

.title-buttons {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

/* ============================================
   PANELS / CARDS
   ============================================ */

.panel {
    background: var(--bg-card);
    border: 2px solid var(--neon-cyan);
    padding: 30px;
    position: relative;
    clip-path: polygon(
        0 15px, 15px 0,
        calc(100% - 15px) 0, 100% 15px,
        100% calc(100% - 15px), calc(100% - 15px) 100%,
        15px 100%, 0 calc(100% - 15px)
    );
}

.panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 40%, rgba(0, 255, 247, 0.05) 50%, transparent 60%);
    pointer-events: none;
}

.panel-title {
    font-family: 'Orbitron', monospace;
    font-size: 1.3rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 10px var(--neon-cyan);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 255, 247, 0.3);
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

/* ============================================
   BARRES DE PROGRESSION
   ============================================ */

.progress-bar {
    width: 100%;
    height: 20px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    transition: width 0.3s ease;
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.progress-bar.health .progress-fill {
    background: linear-gradient(90deg, #ff3333, #ff6666);
}

.progress-bar.mana .progress-fill {
    background: linear-gradient(90deg, #3366ff, #66aaff);
}

.progress-bar.xp .progress-fill {
    background: linear-gradient(90deg, var(--neon-yellow), #ffaa00);
}

.progress-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'Orbitron', monospace;
    font-size: 0.75rem;
    color: white;
    text-shadow: 1px 1px 2px black;
    white-space: nowrap;
}

/* ============================================
   INPUTS
   ============================================ */

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-dim);
    margin-bottom: 8px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.input-text {
    width: 100%;
    padding: 12px 15px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.1rem;
    color: var(--text-light);
    background: rgba(0, 0, 0, 0.5);
    border: 2px solid rgba(0, 255, 247, 0.3);
    border-radius: 4px;
    outline: none;
    transition: all 0.3s ease;
}

.input-text:focus {
    border-color: var(--neon-cyan);
    box-shadow: 0 0 10px rgba(0, 255, 247, 0.3);
}

.input-text::placeholder {
    color: var(--text-dimmer);
}

/* ============================================
   TOOLTIPS
   ============================================ */

.tooltip {
    position: fixed;
    z-index: 2000;
    background: var(--bg-card);
    border: 2px solid var(--neon-cyan);
    padding: 15px;
    max-width: 300px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.tooltip.visible {
    opacity: 1;
}

.tooltip-title {
    font-family: 'Orbitron', monospace;
    font-size: 1rem;
    margin-bottom: 8px;
}

.tooltip-desc {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.4;
}

/* ============================================
   NOTIFICATIONS
   ============================================ */

.notification-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 1500;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.notification {
    background: var(--bg-card);
    border: 2px solid var(--neon-cyan);
    padding: 15px 20px;
    min-width: 250px;
    animation: slideInRight 0.3s ease-out, fadeOut 0.3s ease-in 2.7s forwards;
}

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

.notification.success {
    border-color: var(--neon-green);
}

.notification.error {
    border-color: var(--neon-red);
}

.notification.warning {
    border-color: var(--neon-orange);
}

.notification-text {
    font-size: 0.95rem;
    color: var(--text-light);
}

/* ============================================
   MODAL
   ============================================ */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-card);
    border: 2px solid var(--neon-cyan);
    padding: 30px;
    max-width: 500px;
    width: 90%;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal {
    transform: scale(1);
}

.modal-title {
    font-family: 'Orbitron', monospace;
    font-size: 1.5rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 10px var(--neon-cyan);
    margin-bottom: 20px;
    text-align: center;
}

.modal-content {
    margin-bottom: 25px;
}

.modal-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .game-header {
        padding: 0 10px;
    }

    .header-title {
        font-size: 1rem;
    }

    .screen {
        padding: 15px;
    }

    .panel {
        padding: 20px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .game-logo h1 {
        font-size: 2rem;
    }

    .title-subtitle {
        font-size: 0.9rem;
        letter-spacing: 0.2em;
    }
}
