/* Root Variables */
:root {
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --glass-hover: rgba(255, 255, 255, 0.15);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --shadow-color: rgba(0, 0, 0, 0.3);
    --success-color: rgba(40, 167, 69, 0.3);
    --danger-color: rgba(220, 53, 69, 0.3);
    --warning-color: rgba(255, 193, 7, 0.3);
    --info-color: rgba(23, 162, 184, 0.3);
}

/* Dark Theme */
body.dark-theme {
    --glass-bg: rgba(0, 0, 0, 0.4);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-hover: rgba(0, 0, 0, 0.5);
    --shadow-color: rgba(0, 0, 0, 0.6);
}

/* Base Styles */
html,
body {
    height: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
    user-select: none;
    overflow-x: hidden;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-primary);
}

/* Glass Effect Components */
.glass-card {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border) !important;
    border-radius: 16px;
    box-shadow: 0 8px 32px 0 var(--shadow-color);
    transition: all 0.3s ease;
    overflow: hidden;
}

.glass-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px 0 var(--shadow-color);
}

.glass-header {
    background: rgba(255, 255, 255, 0.05) !important;
    border-bottom: 1px solid var(--glass-border) !important;
    backdrop-filter: blur(10px);
    padding: 1rem;
    color: var(--text-primary);
    font-weight: 600;
}

.glass-item {
    background: var(--glass-bg) !important;
    border: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
    color: var(--text-primary);
    transition: all 0.2s ease;
    animation: slideIn 0.3s ease;
}

.glass-item:hover {
    background: var(--glass-hover) !important;
    transform: translateX(4px);
}

.glass-item:last-child {
    border-bottom: none !important;
}

/* Navbar */
.glass-navbar {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: 0 4px 16px 0 var(--shadow-color);
    padding: 1rem 0;
}

.navbar-brand {
    font-size: 1.4rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Statistics Cards */
.stat-card {
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    cursor: default;
    animation: fadeIn 0.5s ease;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.stat-content {
    flex-grow: 1;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--text-primary);
    line-height: 1;
}

/* Badges */
.badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
}

.admin-badge {
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    background: var(--success-color);
    border: 1px solid rgba(40, 167, 69, 0.5);
}

.info-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.7rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Search Box */
.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box i {
    position: absolute;
    left: 12px;
    color: var(--text-secondary);
    pointer-events: none;
}

.search-box input {
    padding-left: 36px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.search-box input:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.05);
    outline: none;
    color: var(--text-primary);
}

.search-box input::placeholder {
    color: var(--text-secondary);
}

/* Buttons */
.btn-glass {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.btn-glass:hover {
    background: var(--glass-hover);
    border-color: rgba(255, 255, 255, 0.3);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.action-btn {
    border: none;
    font-weight: 600;
    padding: 0.6rem 0.8rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    backdrop-filter: blur(10px);
}

.btn-success {
    background: var(--success-color);
    border: 1px solid rgba(40, 167, 69, 0.5);
    color: white;
}

.btn-success:hover {
    background: rgba(40, 167, 69, 0.5);
    border-color: rgba(40, 167, 69, 0.7);
    transform: scale(1.02);
}

.btn-danger {
    background: var(--danger-color);
    border: 1px solid rgba(220, 53, 69, 0.5);
    color: white;
}

.btn-danger:hover {
    background: rgba(220, 53, 69, 0.5);
    border-color: rgba(220, 53, 69, 0.7);
    transform: scale(1.02);
}

.btn-warning {
    background: var(--warning-color);
    border: 1px solid rgba(255, 193, 7, 0.5);
    color: white;
}

.btn-warning:hover {
    background: rgba(255, 193, 7, 0.5);
    border-color: rgba(255, 193, 7, 0.7);
    transform: scale(1.02);
}

/* Text Styles */
.email-text {
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.95rem;
}

.song-title {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1rem;
}

/* Scrollbar */
.custom-scrollbar {
    max-height: 450px;
    overflow-y: auto;
    overflow-x: hidden;
}

.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Toast Notifications */
.toast {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 24px var(--shadow-color);
}

.toast-body {
    color: var(--text-primary);
    font-weight: 500;
}

.toast.success {
    border-left: 4px solid #28a745;
}

.toast.error {
    border-left: 4px solid #dc3545;
}

.toast.info {
    border-left: 4px solid #17a2b8;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Responsive */
@media (max-width: 768px) {
    .stat-card {
        padding: 1rem;
        gap: 1rem;
    }

    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }

    .stat-value {
        font-size: 1.5rem;
    }

    .custom-scrollbar {
        max-height: 350px;
    }

    .navbar-brand {
        font-size: 1.2rem;
    }
}

@media (max-width: 576px) {
    .glass-card {
        border-radius: 12px;
    }

    .stat-card {
        flex-direction: column;
        text-align: center;
    }

    .stat-icon {
        margin: 0 auto;
    }
}

/* Loading State */
.loading-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Utility Classes */
.min-w-0 {
    min-width: 0 !important;
}

.text-truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Hidden class for filtering */
.d-none-filter {
    display: none !important;
}

/* ── Csengetési Glass Táblázat ── */
.glass-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.glass-table thead tr {
    background: rgba(255, 255, 255, 0.08);
}

.glass-table thead th {
    padding: 0.85rem 1.1rem;
    font-weight: 600;
    font-size: 0.78rem;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--glass-border);
    text-align: center;
    white-space: nowrap;
}

.glass-table thead th:first-child {
    text-align: center;
    padding-left: 1.4rem;
}

.glass-table tbody tr {
    transition: background 0.18s ease;
    animation: slideIn 0.3s ease both;
}

.glass-table tbody tr:nth-child(odd) {
    background: rgba(255, 255, 255, 0.04);
}

.glass-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}

.glass-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.11);
}

.glass-table tbody td {
    padding: 0.7rem 1.1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    vertical-align: middle;
}

.glass-table tbody tr:last-child td {
    border-bottom: none;
}

/* Óra sorszám badge */
.glass-table tbody td:first-child b {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-primary);
}

/* Idő cellák */
.glass-table .time-cell {
    font-family: 'Courier New', monospace;
    font-size: 0.92rem;
    font-weight: 500;
    letter-spacing: 0.03em;
}

.glass-table .time-jelzo {
    color: rgba(255, 193, 7, 0.9);
}

.glass-table .time-be {
    color: rgba(40, 220, 120, 0.9);
}

.glass-table .time-ki {
    color: rgba(255, 100, 100, 0.9);
}

/* Szünet badge */
.glass-table .szunet-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 0.25rem 0.7rem;
    background: rgba(23, 162, 184, 0.18);
    border: 1px solid rgba(23, 162, 184, 0.35);
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 600;
    color: rgba(100, 220, 240, 0.95);
    white-space: nowrap;
}

.glass-table .szunet-badge::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(100, 220, 240, 0.8);
    flex-shrink: 0;
}


#logoutbutton {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: width 0.3s cubic-bezier(.4, 0, .2, 1), border-radius 0.3s;
    box-shadow: 0 2px 12px rgba(255, 80, 80, 0.35);
    background: linear-gradient(135deg, #ff5252, #d63031);
    padding: 0;
}

#logoutbutton .sign {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: width 0.3s, padding 0.3s;
    flex-shrink: 0;
}

#logoutbutton .sign svg {
    width: 15px;
    height: 15px;
}

#logoutbutton .sign svg path {
    fill: white;
}

#logoutbutton .text {
    position: absolute;
    right: 0;
    width: 0;
    opacity: 0;
    color: white;
    font-size: 0.85em;
    font-weight: 600;
    transition: width 0.3s, opacity 0.3s;
    white-space: nowrap;
    padding-right: 10px;
    font-family: 'Outfit', sans-serif;
}

#logoutbutton:hover {
    width: 115px;
    border-radius: 40px;
}

#logoutbutton:hover .sign {
    width: 30%;
    padding-left: 14px;
}

#logoutbutton:hover .text {
    width: 70%;
    opacity: 1;
}

#logoutbutton:active {
    transform: scale(0.96);
}





/* ─── ANIMATED BACKGROUND ─── */
.background {
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(circle at 15% 25%, #4a8fd4 0%, transparent 45%),
        radial-gradient(circle at 85% 20%, #2a6fbb 0%, transparent 45%),
        radial-gradient(circle at 70% 75%, #8a7abf 0%, transparent 50%),
        linear-gradient(135deg, #3a7fd0, #7a6ab8);
    animation: bgShift 12s ease-in-out infinite alternate;
}

@keyframes bgShift {
    0% {
        filter: hue-rotate(0deg) brightness(1);
    }

    100% {
        filter: hue-rotate(15deg) brightness(1.05);
    }
}