/* assets/css/highscore_block.css */
/* Version: RANK PRIORITY FIX 🥇 */

/* Utility: Sichtbarkeit steuern */
.hs-hidden { 
    display: none !important; 
}

/* --- CONTAINER --- */
.hs-wrapper {
    margin-top: 40px;
    border-top: 1px solid rgba(0,0,0,0.05);
    padding-top: 20px;
    width: 100%;
    font-family: var(--hs-font, inherit);
    box-sizing: border-box;
    display: block;
}

.hs-title {
    color: #64748b;
    margin-top: 0;
    text-align: center;
    margin-bottom: 20px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.9rem;
}

/* --- TABELLE --- */
.hs-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    line-height: normal; 
    font-size: 0.95rem;
}

/* --- KOPFZEILE --- */
.hs-table thead th {
    background-color: #f8fafc;
    color: #64748b;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid #e2e8f0;
    text-align: center;
    vertical-align: middle;
    padding: 12px 15px;
    height: auto;
    line-height: 1.4;
}

/* --- DATENZEILEN --- */
.hs-table tbody td {
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    text-align: center;
    vertical-align: middle;
    padding: 12px 15px;
    height: auto;
    line-height: 1.4;
}

/* Spalten */
.hs-col-rank { width: 60px; color: #94a3b8; font-weight: normal; }
.hs-col-left { text-align: left !important; padding-left: 20px !important; font-weight: 600; }

/* --- RANG-FARBEN (MIT PRIORITÄT) --- */
/* Wir nutzen !important, damit Rank-Farben IMMER gewinnen, 
   auch wenn es der 'current-user' (grün) ist. */

/* Gold */
.hs-table tr.rank-1 td {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%) !important;
    color: #92400e !important; /* Das gewünschte Rotbraun */
    font-weight: bold;
    border-top: 1px solid #fbbf24 !important;
    border-bottom: 1px solid #fbbf24 !important;
}
.hs-table tr.rank-1 td:first-child { font-size: 1.4em; }

/* Silber */
.hs-table tr.rank-2 td {
    background-color: #f1f5f9 !important;
    color: #334155 !important;
    font-weight: 600;
}
.hs-table tr.rank-2 td:first-child { font-size: 1.3em; }

/* Bronze */
.hs-table tr.rank-3 td {
    background-color: #fff7ed !important;
    color: #9a3412 !important;
    font-weight: 600;
}
.hs-table tr.rank-3 td:first-child { font-size: 1.3em; }

/* User Highlight (Nur Grün, wenn NICHT Rank 1-3) */
.hs-table tr.my-entry td, 
.hs-table tr.current-user td {
    background-color: #dcfce7;
    color: #166534;
    font-weight: bold;
    border-top: 1px solid #86efac;
    border-bottom: 1px solid #86efac;
}

/* --- INPUT FELD --- */
.hs-input-container {
    position: relative;
    margin: 30px auto;
    padding: 25px;
    background: #fff;
    border: 2px solid #3b82f6;
    border-radius: 16px;
    text-align: center;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 25px -5px rgba(59, 130, 246, 0.2);
    display: block;
    font-family: var(--hs-font, inherit);
    z-index: 100;
}

.hs-input-msg { display: block; margin-bottom: 15px; font-weight: 800; color: #2563eb; font-size: 1.2rem; }

.hs-input-text {
    padding: 10px 15px;
    border: 2px solid #cbd5e1;
    border-radius: 8px;
    width: 200px;
    max-width: 100%;
    margin-right: 10px;
    outline: none;
    font-size: 1rem;
}
.hs-input-text:focus { border-color: #3b82f6; }

.hs-btn-save {
    padding: 10px 20px;
    background-color: #2563eb;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.2s;
}
.hs-btn-save:hover { background-color: #1d4ed8; }

/* Responsive */
@media (max-width: 600px) {
    .hs-hide-mobile { display: none; }
    .hs-input-text { width: 100%; margin-bottom: 10px; margin-right: 0; }
}