/* frontend/assets/css/style.css - VÉGLEGES ÉS TISZTA VERZIÓ */

:root {
    /* --- TE MÁRKA SZÍNEID --- */
    --brand-gold: #DDC272;    /* Fő arany szín */
    --brand-grey: #7E7E7E;    /* Másodlagos szürke */

    /* Háttér és alap színek */
    --bg-dark: #121212;       /* Fő háttér (Nagyon sötét) */
    --bg-card: #1e1e1e;       /* Kártya alap színe */

    /* Szöveg színek */
    --text-main: #ffffff;     /* Fő hófehér szöveg */
    --text-dark: #121212;     /* Sötét szöveg (pl. arany gombon) */

    /* A KÉRT MEZŐ: Világos szürke a kontrasztért */
    --text-muted: #cccccc;

    /* Funkcionális színek (Ezeket használja a kód: btn-success, text-info, stb.) */
    --primary: var(--brand-gold);
    --success: #66bb6a;       /* Zöld */
    --danger: #ef5350;        /* Piros */
    --info: #42a5f5;          /* Kék */
    --warning: var(--brand-gold); /* Figyelmeztetés */

    /* Effektek */
    --radius: 8px;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(20, 20, 25, 0.9);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* =========================================
   GLOBÁLIS BEÁLLÍTÁSOK ÉS HÁTTÉR
   ========================================= */

body {
    background: radial-gradient(circle at center, #252525 0%, #050505 100%);
    background-attachment: fixed;
    color: var(--text-main);
    font-family: 'Montserrat', 'Segoe UI', sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Szövegek olvashatósága (FIX: Bootstrap text-muted felülírása) */
.text-muted, .small, .form-text {
    color: #cccccc !important;
}

/* Tartalom rétegrend (Fix: ne bújjon a particles.js alá a tartalom) */
/* Sötétítő réteg - Kiemeljük a folyásból, de hátra küldjük */
.bg-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(10, 12, 18, 0.85);
    z-index: -100; /* FIX: Extrém alacsony érték! */
}

/* Részecskék (Particles) - A tartalom MÖGÖTT, az overlay felett/alatt */
#particles-js {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -99; /* FIX: Alacsony z-index az overlay felett */
    pointer-events: none;
    opacity: 0.6;
}

/* Tartalom kiemelése a részecskék fölé (FIX: Ez volt a lényeg) */
.container, .container-fluid {
    position: relative; /* Ez kell a z-index-hez! */
    z-index: 10;
}

.urgent-news-item {
    padding: 10px;
    margin-left: -15px !important; /* Hogy a border-bottom felülíródjon és látszódjon */
    margin-right: -15px !important;

    /* Vizuális Kiemelés */
    border-left: 4px solid var(--danger); /* Piros vonal a bal oldalon */
    background-color: rgba(239, 83, 80, 0.1); /* Halvány piros háttér tint */
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(239, 83, 80, 0.2);

    transition: all 0.3s ease;
}

.urgent-news-item .text-danger {
    color: var(--danger) !important;
}

/* =========================================
   NAVIGÁCIÓ (GLASS)
   ========================================= */
.navbar {
    background: rgba(20, 20, 20, 0.95) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
    position: relative;
    z-index: 9999 !important; /* Mindig felül legyen */
}

.navbar-brand {
    font-weight: 800;
    text-transform: uppercase;
    color: var(--brand-gold) !important;
    letter-spacing: 1.5px;
}

/* =========================================
   KÁRTYÁK (GLASSMORPHISM)
   ========================================= */
.card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08); /* Nagyon finom keret */
    border-radius: var(--radius);
    box-shadow: 0 5px 25px rgba(0,0,0,0.4);
    transition: var(--transition);
}

.card-header {
    background-color: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--brand-gold);
    font-weight: 700;
    text-transform: uppercase;
}

.card-title {
    color: var(--text-main) !important;
    font-weight: 700;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
    border-color: var(--brand-gold) !important;
    background: rgba(30, 30, 35, 0.9);
}

/* =========================================
   OVERLAYS (ÉRTESÍTÉS & TOOLTIP & MODAL)
   ========================================= */

/* Modal (Üveges Kártya) */
.modal-content {
    /* Glassmorphism Alapok */
    background: var(--glass-bg) !important; /* Erősítsük meg a sötét hátteret */
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);

    /* Vizuális elemek */
    border: 1px solid var(--brand-gold);
    border-radius: var(--radius);
    box-shadow: 0 0 50px rgba(0,0,0,0.8);

    color: var(--text-main);
}

/* Modal Fejléc (Fehér maradt a háttér, ha nem adunk neki prioritást) */
.modal-header {
    background-color: rgba(255, 255, 255, 0.05); /* Nagyon sötétített, áttetsző */
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Modal Lábléc */
.modal-footer {
    background-color: rgba(255, 255, 255, 0.03);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* =========================================
   GOMBOK
   ========================================= */
.btn {
    border-radius: 6px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    padding: 10px 20px;
    letter-spacing: 0.8px;
    transition: var(--transition);
    position: relative;
    overflow: visible; /* FIX: Ne vágja le a szöveget */
}

/* Arany Gomb */
.btn-primary, .btn-gold {
    background: linear-gradient(135deg, var(--brand-gold) 0%, #b8860b 100%);
    border: none;
    color: #000;
    box-shadow: 0 4px 15px rgba(221, 194, 114, 0.3);
}

.btn-primary:hover {
    transform: scale(1.02);
    box-shadow: 0 0 25px rgba(221, 194, 114, 0.6);
    color: #000;
}

/* Outline Gombok (Glass) */
.btn-outline-primary, .btn-outline-light, .btn-outline-danger, .btn-outline-success, .btn-outline-info, .btn-outline-warning {
    background: rgba(0,0,0,0.2);
    backdrop-filter: blur(4px);
    border-width: 1px;
}
.btn-outline-primary { color: var(--brand-gold); border-color: var(--brand-gold); }
.btn-outline-primary:hover { background: var(--brand-gold); color: #000; box-shadow: 0 0 15px rgba(221, 194, 114, 0.5); }


/* =========================================
   INPUTOK ÉS ŰRLAPOK (FIX: WHITE TEXT)
   ========================================= */
.form-control, .form-select, .input-group-text {
    background-color: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff !important; /* FIX: Fehérre kényszerített szöveg */
    border-radius: 6px;
}

.form-control:focus, .form-select:focus {
    background-color: rgba(0, 0, 0, 0.6) !important;
    border-color: var(--brand-gold);
    box-shadow: 0 0 15px rgba(221, 194, 114, 0.2);
}

::placeholder { color: #888 !important; opacity: 1; }


/* =========================================
   TÁBLÁZATOK
   ========================================= */
.table { color: var(--text-main); border-color: rgba(255,255,255,0.1); }

/* Fejléc */
.table thead th {
    background-color: rgba(0,0,0,0.5);
    color: var(--brand-gold);
    border-bottom: 2px solid var(--brand-gold);
    text-transform: uppercase;
    font-size: 0.8rem;
}

.table tbody td {
    background-color: transparent !important;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.table-hover tbody tr:hover {
    color: #fff;
    background-color: rgba(221, 194, 114, 0.1); /* Halvány arany hover */
}

/* =========================================
   EGYÉB / UTILITY JAVÍTÁSOK
   ========================================= */

/* Heti Zárás Alert (FIX: Látja a háttérszínt) */
.alert-custom-dark {
    background-color: rgba(221, 194, 114, 0.25) !important;
    border: 1px solid var(--brand-gold);
    color: var(--text-main);
    border-radius: var(--radius);
    box-shadow: inset 0 0 20px rgba(221, 194, 114, 0.1);
}

/* Stat Box (FIX: Szöveg törés és Padding) */
.stat-box {
    background-color: rgba(0, 0, 0, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 12px 20px;
    border-radius: 8px;
    min-width: 140px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.stat-label {
    color: var(--text-muted) !important; /* Világosszürke */
    font-weight: 600;
}

.stat-value {
    font-size: 1.0rem !important; /* Kisebb, hogy kiférjen */
    font-weight: 800;
    white-space: normal !important; /* Engedjük a sortörést */
    word-wrap: break-word !important;
    line-height: 1.1 !important;
}

/* Tooltip (FIXED) */
#image-tooltip {
    position: fixed;
    display: none;
    z-index: 9999;
    background: rgba(20, 20, 20, 0.95);
    border: 2px solid var(--brand-gold);
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
    padding: 5px;
    border-radius: var(--radius);
    max-width: 350px;
    pointer-events: none;
}

/* KÉP MEGJELENÍTÉS FIX */
#image-tooltip img {
    display: block; /* Ez a fontos! */
    width: 100%;
    height: auto;
    border-radius: 4px;
}

.old-penalty-highlight {
    background-color: rgba(239, 83, 80, 0.15) !important;
}

import-item {
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.2s;
}
.import-item.late {
    border-left: 4px solid var(--danger);
    background-color: rgba(239, 83, 80, 0.1);
}
.import-item.done {
    opacity: 0.5;
    pointer-events: none;
    border-color: var(--success);
}
.import-item.duplicate {
    opacity: 0.6;
    border-left: 4px solid var(--brand-grey);
}

#toast-container {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%); /* Középre igazítás */
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
    width: 100%;
    max-width: 450px;
}

/* Maga a buborék */
.toast-custom {
    /* (A többi stílus változatlan) */
    background: rgba(30, 30, 35, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid var(--brand-gold);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    min-width: 300px;
    opacity: 0;
    transition: none;
    pointer-events: auto;
    animation-fill-mode: forwards;
    align-items: center;
}

.toast-custom.show-enter {
    animation: slide-in-bottom 1.0s ease-out forwards; /* Belépés: 1 másodperc */
}

.toast-custom.hide-exit {
    animation: slide-out-bottom 1.0s ease-in forwards; /* Kilépés: 1 másodperc */
}

/* =========================================
   ANIMÁCIÓK
   ========================================= */
@keyframes slide-in-bottom {
    from { transform: translateY(100px) translateX(-50%); opacity: 0; }
    to { transform: translateY(0) translateX(-50%); opacity: 1; }
}

@keyframes slide-out-bottom {
    from { transform: translateY(0) translateX(-50%); opacity: 1; }
    to { transform: translateY(100px) translateX(-50%); opacity: 0; }
}