/*
 * TASEDAČKA - Admin CSS
 * Barevné schéma: Tyrkysová #21758c, Oranžová #f2795a
 */

/* ===== Reset & Základní styly ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #21758c;
    --primary-dark: #0d3d4d;
    --accent-color: #f2795a;
    --accent-light: #ff8b6d;
    --success: #28a745;
    --warning: #ffc107;
    --danger: #dc3545;
    --white: #ffffff;
    --text-dark: #333333;
    --text-light: #666666;
    --border-color: #dddddd;
    --bg-light: #f5f7fa;
    --sidebar-width: 260px;
}

body.admin-body {
    font-family: 'Roboto', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
    min-height: 100vh;
}

/* ===== Admin Wrapper Layout ===== */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ===== Admin Header ===== */
.admin-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.admin-header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.admin-header h1 {
    font-size: 24px;
    font-weight: 700;
}

.admin-header h1 span {
    font-weight: 300;
    font-size: 18px;
    opacity: 0.9;
}

.sidebar-toggle {
    background: none;
    border: none;
    color: var(--white);
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    transition: all 0.3s ease;
    border-radius: 4px;
}

.sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

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

.admin-user-menu {
    display: flex;
    align-items: center;
    gap: 15px;
}

.admin-user-name {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.btn-link {
    color: var(--white);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 4px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-link:hover {
    background: rgba(255, 255, 255, 0.1);
}

.btn-logout {
    background: var(--accent-color);
    color: var(--white);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 4px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}

.btn-logout:hover {
    background: var(--accent-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(242, 121, 90, 0.4);
}

/* ===== Admin Sidebar ===== */
.admin-sidebar {
    position: fixed;
    left: 0;
    top: 70px;
    width: var(--sidebar-width);
    height: calc(100vh - 70px);
    background: var(--white);
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.05);
    overflow-y: auto;
    transition: transform 0.3s ease;
    z-index: 999;
}

.sidebar-nav ul {
    list-style: none;
    padding: 20px 0;
}

.sidebar-nav li {
    margin: 0;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 25px;
    color: var(--text-dark);
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}

.sidebar-nav a:hover {
    background: var(--bg-light);
    color: var(--primary-color);
    border-left-color: var(--primary-color);
}

.sidebar-nav a.active {
    background: linear-gradient(90deg, rgba(33, 117, 140, 0.1) 0%, transparent 100%);
    color: var(--primary-color);
    border-left-color: var(--primary-color);
    font-weight: 600;
}

.sidebar-nav a i {
    width: 20px;
    text-align: center;
    font-size: 18px;
}

/* Submenu */
.sidebar-nav .has-submenu > a {
    position: relative;
}

.sidebar-nav .submenu-arrow {
    margin-left: auto;
    font-size: 12px;
    transition: transform 0.3s ease;
}

.sidebar-nav .submenu-toggle.active .submenu-arrow,
.sidebar-nav .has-submenu:hover > a .submenu-arrow {
    transform: rotate(180deg);
}

.sidebar-nav .submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: rgba(0, 0, 0, 0.02);
    list-style: none;
    padding: 0;
}

.sidebar-nav .submenu.open {
    max-height: 500px;
}

.sidebar-nav .submenu li {
    border-left: 4px solid transparent;
}

.sidebar-nav .submenu a {
    padding: 12px 25px 12px 45px;
    font-size: 14px;
    border-left: none;
}

.sidebar-nav .submenu a i {
    font-size: 14px;
    color: var(--text-light);
}

.sidebar-nav .submenu a:hover i,
.sidebar-nav .submenu a.active i {
    color: var(--primary-color);
}

/* ===== Sidebar Collapsed State (Desktop) ===== */
.admin-wrapper.sidebar-collapsed .admin-sidebar {
    transform: translateX(-100%);
}

.admin-wrapper.sidebar-collapsed .admin-content-wrapper {
    margin-left: 0;
    transition: margin-left 0.3s ease;
}

.admin-wrapper.sidebar-collapsed .admin-footer {
    margin-left: 0;
    transition: margin-left 0.3s ease;
}

/* Plynulý přechod pro content wrapper i bez collapsed stavu */
.admin-content-wrapper {
    transition: margin-left 0.3s ease;
}

/* ===== Admin Content ===== */
.admin-content-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    margin-top: 70px;
    padding: 30px;
    min-height: calc(100vh - 70px);
}

/* Timeline Filter Buttons */
.timeline-filter-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    padding: 15px;
    background: #f5f5f5;
    border-radius: 8px;
}

.timeline-filter-buttons .btn {
    flex: 1;
    max-width: 200px;
}

.admin-content {
    max-width: 1400px;
    margin: 0 auto;
}

/* ===== Page Header ===== */
.admin-page-header {
    margin-bottom: 30px;
}

.admin-page-header h1 {
    font-size: 32px;
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    gap: 15px;
}

.admin-page-header h1 i {
    color: var(--primary-color);
}

/* ===== Stats Grid ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--white);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    gap: 15px;
    transition: all 0.3s ease;
    align-items: center; /* Vycentrování obsahu karty */
    text-align: center; /* Vycentrování textu */
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(33, 117, 140, 0.15);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: var(--white);
}

.stat-icon.pending {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
}

.stat-icon.confirmed {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.stat-icon.users {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
}

.stat-icon.today {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--accent-light) 100%);
}

.stat-details h3 {
    font-size: 36px;
    font-weight: 700;
    color: var(--primary-dark);
    margin: 0;
}

.stat-details p {
    color: var(--text-light);
    font-size: 14px;
    margin: 0;
}

.stat-link {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
}

.stat-link:hover {
    color: var(--primary-dark);
    gap: 10px;
}

/* ===== Admin Section ===== */
.admin-section {
    background: var(--white);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--bg-light);
}

.section-header h2 {
    font-size: 24px;
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
}

.section-header h2 i {
    color: var(--accent-color);
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 117, 140, 0.3);
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-success:hover {
    background: #218838;
}

.btn-secondary {
    background: var(--text-light);
    color: var(--white);
}

.btn-secondary:hover {
    background: var(--text-dark);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

/* ===== Tables ===== */
.table-responsive {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
}

.admin-table thead {
    background: var(--bg-light);
}

.admin-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--border-color);
}

.admin-table td {
    padding: 15px;
    border-bottom: 1px solid var(--bg-light);
}

.admin-table tbody tr {
    transition: background 0.2s ease;
}

.admin-table tbody tr:hover {
    background: var(--bg-light);
}

/* Zarovnání sloupce s akcemi */
td.table-actions,
th.table-actions {
    text-align: right;
}

.table-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end; /* Zarovnání ikon akcí na pravou stranu */
}

/* ===== Timeline (Dnešní rezervace) ===== */
.bookings-timeline {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.timeline-item {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
    transition: all 0.3s ease;
}

.timeline-item:hover {
    background: #e8f4f8;
    transform: translateX(5px);
}

.timeline-item.status-pending {
    border-left-color: var(--warning);
}

.timeline-item.status-confirmed {
    border-left-color: var(--success);
}

.timeline-time {
    font-weight: 700;
    color: var(--primary-color);
    min-width: 150px;
    font-size: 16px;
}

.timeline-content {
    flex: 1;
}

.timeline-content h4 {
    font-size: 18px;
    color: var(--primary-dark);
    margin-bottom: 8px;
}

/* ===== Status Badge ===== */
.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.status-badge.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-badge.status-confirmed {
    background: #d4edda;
    color: #155724;
}

.status-badge.status-cancelled {
    background: #f8d7da;
    color: #721c24;
}

.status-badge.status-completed {
    background: #d1ecf1;
    color: #0c5460;
}

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-light);
}

.empty-state i {
    font-size: 64px;
    color: var(--border-color);
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 20px;
    color: var(--text-light);
}

/* ===== Admin Footer ===== */
.admin-footer {
    background: var(--white);
    padding: 20px;
    text-align: center;
    color: var(--text-light);
    border-top: 1px solid var(--border-color);
    margin-left: var(--sidebar-width);
}

/* ===== Mobile Overlay (tmavé pozadí za sidebarem) ===== */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

/* ===== Responzivita ===== */
@media (max-width: 1024px) {
    /* OPRAVENO: Na mobilu musí mít sidebar šířku, aby byl vidět když je open */
    .admin-sidebar {
        width: 260px; /* Pevná šířka místo proměnné */
        transform: translateX(-100%);
        z-index: 1000; /* Zvýšený z-index pro zobrazení přes obsah (nad overlay) */
    }

    .admin-sidebar.open {
        transform: translateX(0);
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3); /* Výraznější stín při otevření */
    }

    .admin-content-wrapper {
        margin-left: 0;
    }

    .admin-footer {
        margin-left: 0;
    }

    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    /* GLOBÁLNÍ OPRAVA: Prevence horizontálního scrollu */
    body,
    .admin-wrapper,
    .admin-content-wrapper {
        overflow-x: hidden;
        max-width: 100vw;
    }

    /* Všechny modály a kontejnery */
    .modal-content,
    .admin-section,
    .bookings-section,
    .users-filters,
    .table-responsive {
        max-width: 100%;
        overflow-x: auto;
    }

    .admin-header {
        padding: 0 15px;
    }

    .admin-header h1 {
        font-size: 18px;
    }

    .admin-header h1 span {
        display: none;
    }

    .admin-user-name {
        display: none;
    }

    /* Skrýt text u tlačítek v headeru, zobrazit jen ikony */
    .btn-link .btn-text,
    .btn-logout .btn-text {
        display: none;
    }

    /* Zmenšit padding u tlačítek s jen ikonami */
    .btn-link,
    .btn-logout {
        padding: 10px;
        gap: 0;
        min-width: 40px;
        justify-content: center;
    }

    /* Zvětšit ikony pro lepší klikatelnost */
    .btn-link i,
    .btn-logout i {
        font-size: 18px;
    }

    .admin-content-wrapper {
        padding: 15px;
    }

    /* Admin page header - responzivní pro mobily */
    .admin-page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .admin-page-header .btn {
        width: 100%;
    }

    /* Timeline filter buttons - pod sebou na mobilu */
    .timeline-filter-buttons {
        flex-direction: column;
        gap: 8px;
        padding: 10px;
    }

    .timeline-filter-buttons .btn {
        max-width: none;
        font-size: 14px;
        padding: 10px 15px;
    }

    /* Responzivní tabulka rezervací - skrytí méně důležitých sloupců */
    .bookings-table th:nth-child(1), /* ID */
    .bookings-table td:nth-child(1),
    .bookings-table th:nth-child(5), /* Kontakt */
    .bookings-table td:nth-child(5),
    .bookings-table th:nth-child(6), /* Účastníci */
    .bookings-table td:nth-child(6) {
        display: none;
    }

    /* Zmenšení fontů a paddingu v tabulce */
    .admin-table th,
    .admin-table td {
        padding: 10px 8px;
        font-size: 13px;
    }

    .admin-table th {
        font-size: 12px;
    }

    /* Akční tlačítka v řádku místo vedle sebe */
    .table-actions {
        display: flex;
        flex-direction: column;
        gap: 5px;
        align-items: stretch;
    }

    .table-actions .btn {
        width: 100%;
        justify-content: center;
        font-size: 11px;
        padding: 6px 8px;
    }

    /* OPRAVA: Všechny gridy na 1 sloupec na mobilech - řeší overflow */
    .stats-grid,
    .form-grid,
    .settings-grid {
        grid-template-columns: 1fr !important;
    }

    .admin-section {
        padding: 20px;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .table-actions {
        flex-direction: column;
    }

    .timeline-item {
        flex-direction: column;
        gap: 10px;
    }

    .timeline-time {
        min-width: auto;
    }

    /* View toggle buttons (Seznam/Kalendář) - na mobilu */
    .view-toggle-wrapper {
        flex-direction: column;
        gap: 8px;
    }

    .view-toggle-btn {
        max-width: none;
        width: 100%;
        padding: 12px 15px;
    }
}

/* Header s tlačítkem */
.admin-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    gap: 20px;
}

.admin-page-header h1 {
    margin: 0 0 5px 0;
}

.admin-page-header p {
    margin: 0;
    color: #666;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-size: 14px;
}

.btn-primary {
    background: #21758c;
    color: white;
}

.btn-primary:hover {
    background: #0d3d4d;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(33, 117, 140, 0.3);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

/* Modály */
.modal {
    /* CRITICAL: Use visibility instead of display:none to keep content in DOM for CSRF tokens */
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    display: flex;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease, visibility 0s 0.3s;
}

.modal.active {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transition: opacity 0.3s ease;
}

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

.modal-content {
    background: white;
    border-radius: 12px;
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s;
}

.modal-content.modal-lg {
    max-width: 900px;
}

.modal-content.modal-xl {
    max-width: 1100px;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    background: linear-gradient(135deg, #21758c 0%, #0d3d4d 100%);
    color: white;
    padding: 25px 30px;
    border-radius: 12px 12px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 22px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 32px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

/* Modal body - obsahuje formulář */
.modal-body {
    padding: 30px;
}

/* User form class - pouze pro identifikaci, padding je na .modal-body */
.user-form {
    /* padding se přesunul do .modal-body */
}

.modern-form {
    padding: 25px 30px;
}

.modern-form .form-group {
    margin-bottom: 20px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.form-row-2cols {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.form-row-3cols {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.form-row-4cols {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .form-row-2cols,
    .form-row-3cols,
    .form-row-4cols {
        grid-template-columns: 1fr;
    }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-group label i {
    color: #21758c;
}

.form-control {
    padding: 10px 12px;
    border: 2px solid #e5e5e5;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
    width: 100%;
    background: white;
    color: #333;
    font-family: inherit;
    line-height: 1.5;
}

.form-control:focus {
    outline: none;
    border-color: #21758c;
}

/* Specifické styly pro date a time inputy */
input[type="date"].form-control,
input[type="time"].form-control {
    cursor: pointer;
}

input[type="date"].form-control::-webkit-calendar-picker-indicator,
input[type="time"].form-control::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s;
}

input[type="date"].form-control::-webkit-calendar-picker-indicator:hover,
input[type="time"].form-control::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

.form-group small {
    color: #999;
    font-size: 12px;
}

/* Read-only form control display - pro zobrazení dat v modálech */
.form-control-static {
    padding: 10px 12px;
    font-size: 14px;
    line-height: 1.5;
    color: #333;
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    min-height: 42px;
    display: flex;
    align-items: center;
}

/* Badge styling - pro označení stavů a kategorií */
.badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
    text-align: center;
    white-space: nowrap;
    border-radius: 4px;
    vertical-align: middle;
}

.badge-info {
    background: #17a2b8;
    color: white;
}

.badge-warning {
    background: #ffc107;
    color: #333;
}

.badge-secondary {
    background: #6c757d;
    color: white;
}

.badge-success {
    background: #28a745;
    color: white;
}

.badge-danger {
    background: #dc3545;
    color: white;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 2px solid #e5e5e5;
    transition: all 0.3s;
}

.checkbox-label:hover {
    border-color: #21758c;
    background: white;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.checkbox-label span {
    flex: 1;
    font-weight: normal !important;
}

.modal-footer {
    padding: 20px 30px;
    border-top: 2px solid #e5e5e5;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    background: #f8f9fa;
    border-radius: 0 0 12px 12px;
}

/* Statistiky */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: white;
    background: linear-gradient(135deg, #21758c 0%, #0d3d4d 100%);
}

.stat-icon.active {
    background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
}

.stat-icon.inactive {
    background: linear-gradient(135deg, #ffc107 0%, #d39e00 100%);
}

.stat-icon.bookings {
    background: linear-gradient(135deg, #f2795a 0%, #d35a3c 100%);
}

.stat-details h3 {
    margin: 0;
    font-size: 32px;
    color: #21758c;
}

.stat-details p {
    margin: 5px 0 0 0;
    color: #666;
    font-size: 14px;
}

/* Filtry */
.users-filters {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.filters-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-group label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-group label i {
    color: #21758c;
}

.filter-group select,
.filter-group input[type="date"],
.filter-group input[type="time"],
.filter-group input[type="text"],
.search-input {
    padding: 10px 12px;
    border: 2px solid #e5e5e5;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
    width: 100%;
    background: white;
    color: #333;
    font-family: inherit;
    line-height: 1.5;
}

.filter-group input[type="date"],
.filter-group input[type="time"] {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.filter-group input[type="date"]::-webkit-calendar-picker-indicator,
.filter-group input[type="time"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s;
}

.filter-group input[type="date"]::-webkit-calendar-picker-indicator:hover,
.filter-group input[type="time"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

.filter-group select:focus,
.filter-group input[type="date"]:focus,
.filter-group input[type="time"]:focus,
.filter-group input[type="text"]:focus,
.search-input:focus {
    outline: none;
    border-color: #21758c;
}

.search-group {
    position: relative;
}

.btn-clear-search {
    position: absolute;
    right: 10px;
    bottom: 10px;
    background: #dc3545;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-clear-search:hover {
    background: #c82333;
    transform: scale(1.1);
}

/* Tabulka uživatelů */
.users-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.users-table {
    width: 100%;
    font-size: 14px;
}

.users-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    font-weight: 600;
    color: #333;
    text-align: left;
    border-bottom: 2px solid #e5e5e5;
}

.users-table td {
    padding: 15px 12px;
    border-bottom: 1px solid #f0f0f0;
    vertical-align: top;
}

.user-row.inactive-row {
    opacity: 0.6;
    background: #f9f9f9;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #21758c 0%, #0d3d4d 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 13px;
}

.contact-info i {
    color: #21758c;
    margin-right: 5px;
    width: 15px;
}

.user-stats {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 13px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.stat-item i {
    color: #21758c;
    width: 15px;
}

.text-muted {
    color: #999;
}

.table-summary {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e5e5e5;
    text-align: center;
    color: #666;
}

/* Responzivita */
@media (max-width: 1200px) {
    .users-table {
        font-size: 12px;
    }

    .users-table th,
    .users-table td {
        padding: 10px 8px;
    }
}

@media (max-width: 768px) {
    .filters-form {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== Booking specific styles ===== */
.bookings-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.bookings-table {
    width: 100%;
    font-size: 14px;
}

.bookings-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    font-weight: 600;
    color: #333;
    text-align: left;
    border-bottom: 2px solid #e5e5e5;
}

.bookings-table td {
    padding: 15px 12px;
    border-bottom: 1px solid #f0f0f0;
    vertical-align: top;
}

.booking-row:hover {
    background: #f9f9f9;
}

/* Type badges */
.type-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.type-badge.type-customer {
    background: rgba(33, 117, 140, 0.15);
    color: #0d3d4d;
}

.type-badge.type-maintenance {
    background: rgba(255, 193, 7, 0.15);
    color: #d39e00;
}

.type-badge.type-own_use {
    background: rgba(23, 162, 184, 0.15);
    color: #117a8b;
}

.type-badge.type-holiday {
    background: rgba(220, 53, 69, 0.15);
    color: #bd2130;
}

.type-badge.type-other {
    background: rgba(108, 117, 125, 0.15);
    color: #545b62;
}

/* Status badges */
.status-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge.status-pending {
    background: rgba(242, 121, 90, 0.15);
    color: #d85d3f;
}

.status-badge.status-confirmed {
    background: rgba(40, 167, 69, 0.15);
    color: #218838;
}

.status-badge.status-cancelled {
    background: rgba(108, 117, 125, 0.15);
    color: #545b62;
}

.status-badge.status-completed {
    background: rgba(23, 162, 184, 0.15);
    color: #117a8b;
}

.status-badge.status-active {
    background: rgba(40, 167, 69, 0.15);
    color: #218838;
}

.status-badge.status-inactive {
    background: rgba(108, 117, 125, 0.15);
    color: #545b62;
}

/* Status icons (jen ikony bez textu) */
.status-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: help;
}

.status-icon.status-active {
    color: #28a745; /* Zelená */
}

.status-icon.status-inactive {
    color: #dc3545; /* Červená */
}

/* Stat icon colors for bookings */
.stat-icon.pending {
    background: linear-gradient(135deg, #f2795a 0%, #d35a3c 100%);
}

.stat-icon.confirmed {
    background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
}

.stat-icon.completed {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
}

/* Form sections in modals */
.form-section {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e5e5e5;
}

.form-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.form-section h3 {
    color: #21758c;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.form-row .form-group {
    flex: 1;
}

.form-group.col-md-4 {
    flex: 0 0 calc(33.333% - 10px);
}

.form-group.col-md-6 {
    flex: 0 0 calc(50% - 7.5px);
}

/* Radio groups */
.radio-group {
    display: flex;
    gap: 20px;
    margin-top: 10px;
}

.radio-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 6px;
    transition: background 0.2s ease;
}

.radio-inline:hover {
    background: #f8f9fa;
}

.radio-inline input[type="radio"] {
    cursor: pointer;
    width: 18px;
    height: 18px;
    accent-color: #21758c;
}

/* Modern radio cards */
.radio-group-modern {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-top: 10px;
}

.radio-card {
    position: relative;
    cursor: pointer;
    border: 2px solid #e5e5e5;
    border-radius: 8px;
    padding: 0;
    transition: all 0.3s ease;
    background: white;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.radio-card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    gap: 10px;
    text-align: center;
}

.radio-card-content i {
    font-size: 28px;
    color: #666;
    transition: all 0.3s ease;
}

.radio-card-content span {
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

.radio-card:hover {
    border-color: #21758c;
    background: #f8f9fa;
}

.radio-card:hover .radio-card-content i {
    color: #21758c;
    transform: scale(1.1);
}

.radio-card:has(input[type="radio"]:checked) {
    border-color: #21758c;
    box-shadow: 0 0 0 3px rgba(33, 117, 140, 0.1);
}

.radio-card input[type="radio"]:checked + .radio-card-content {
    background: linear-gradient(135deg, #21758c 0%, #0d3d4d 100%);
    color: white;
    border-radius: 6px;
}

.radio-card input[type="radio"]:checked + .radio-card-content i,
.radio-card input[type="radio"]:checked + .radio-card-content span {
    color: white;
}

/* Client section box - vizuální seskupení klientských informací */
.client-section-box {
    background: #f8f9fa;
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    padding: 0;
    margin-bottom: 25px;
    overflow: visible; /* Změněno z hidden - aby byl vidět searchable dropdown */
    transition: all 0.3s ease;
}

.client-section-box:hover {
    border-color: #21758c;
    box-shadow: 0 4px 12px rgba(33, 117, 140, 0.1);
}

.client-section-header {
    background: linear-gradient(135deg, #21758c 0%, #0d3d4d 100%);
    color: white;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 15px;
    border-radius: 10px 10px 0 0; /* Zaoblení jen nahoře, protože overflow: visible */
}

.client-section-header i {
    font-size: 18px;
}

.client-section-content {
    padding: 25px;
    background: white;
    overflow: visible; /* Pro viditelnost searchable dropdown */
    position: relative; /* Pro správné pozicování dropdownu */
}

.client-fields-container {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px dashed #e5e5e5;
    animation: fadeInDown 0.3s ease;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Action buttons - ikonková tlačítka v tabulce */
.action-buttons {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: right;
    flex-wrap: wrap;
}

.btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
}

.btn-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

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

.btn-icon i {
    margin: 0;
}

/* Button group vertical */
.btn-group-vertical {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.btn-group-vertical .btn {
    width: 100%;
    justify-content: center;
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-success:hover {
    background: #218838;
}

.btn-info {
    background: #17a2b8;
    color: white;
}

.btn-info:hover {
    background: #138496;
}

.btn-warning {
    background: #ffc107;
    color: #333;
}

.btn-warning:hover {
    background: #e0a800;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.empty-state i {
    font-size: 64px;
    color: #ccc;
    margin-bottom: 20px;
}

.empty-state h3 {
    margin: 0 0 10px 0;
    color: #333;
}

.empty-state p {
    margin: 0 0 20px 0;
}

/* Admin table */
.admin-table {
    width: 100%;
    font-size: 14px;
    background: white;
}

.admin-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    font-weight: 600;
    color: #333;
    text-align: left;
    border-bottom: 2px solid #e5e5e5;
}

.admin-table td {
    padding: 15px 12px;
    border-bottom: 1px solid #f0f0f0;
    vertical-align: middle;
}

.admin-table tbody tr:hover {
    background: #f9f9f9;
}

/* Responsive */
@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 0;
    }

    .form-group.col-md-4,
    .form-group.col-md-6 {
        flex: 0 0 100%;
    }

    .radio-group {
        flex-direction: column;
        gap: 10px;
    }

    .btn-group-vertical {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .btn-group-vertical .btn {
        flex: 1 1 45%;
    }
}

/* ===== TOAST NOTIFIKACE - Pravý dolní roh ===== */
.notification-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 100000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 400px;
    pointer-events: none;
}

.notification-toast {
    background: white;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    min-width: 320px;
    max-width: 400px;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    pointer-events: auto;
    border-left: 4px solid #ccc;
}

.notification-toast.show {
    opacity: 1;
    transform: translateX(0);
}

.notification-toast.hide {
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease-in;
}

/* Typy notifikací - barevné schéma */
.notification-success {
    border-left-color: #28a745;
}

.notification-success .notification-icon {
    color: #28a745;
}

.notification-error {
    border-left-color: #dc3545;
}

.notification-error .notification-icon {
    color: #dc3545;
}

.notification-warning {
    border-left-color: #ffc107;
}

.notification-warning .notification-icon {
    color: #ffc107;
}

.notification-info {
    border-left-color: #17a2b8;
}

.notification-info .notification-icon {
    color: #17a2b8;
}

/* Ikona notifikace */
.notification-icon {
    font-size: 24px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Obsah notifikace */
.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-message {
    color: #333;
    font-size: 14px;
    line-height: 1.5;
    word-wrap: break-word;
}

/* Tlačítko zavření */
.notification-close {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
    flex-shrink: 0;
}

.notification-close:hover {
    color: #333;
}

/* Responsivní design pro mobily */
@media (max-width: 768px) {
    .notification-container {
        right: 10px;
        left: 10px;
        bottom: 10px;
        max-width: none;
    }

    .notification-toast {
        min-width: auto;
        max-width: none;
        width: 100%;
    }
}

/* Progress bar pro automatické zavření (volitelné) */
.notification-toast.with-progress::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: currentColor;
    opacity: 0.3;
    animation: notificationProgress 5s linear;
}

@keyframes notificationProgress {
    from {
        width: 100%;
    }
    to {
        width: 0%;
    }
}

/* ========================================
   TOGGLE SWITCH PRO TYP KLIENTA
   ======================================== */

.client-type-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.toggle-label {
    font-size: 13px;
    color: white;
    font-weight: 500;
    transition: color 0.3s;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #21758c;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: #f2795a;
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 0 2px rgba(33, 117, 140, 0.2);
}

/* Zvýraznění aktivního labelu */
.toggle-switch input:not(:checked) ~ #add_toggle_label_registered,
.toggle-switch input:not(:checked) ~ #calendar_add_toggle_label_registered {
    color: #21758c;
    font-weight: 600;
}

.toggle-switch input:checked ~ #add_toggle_label_guest,
.toggle-switch input:checked ~ #calendar_add_toggle_label_guest {
    color: #f2795a;
    font-weight: 600;
}

/* Responsive - menší na mobilech */
@media (max-width: 768px) {
    .client-type-toggle {
        margin-left: 0;
        margin-top: 10px;
    }

    .toggle-label {
        font-size: 12px;
    }

    .toggle-switch {
        width: 44px;
        height: 22px;
    }

    .toggle-slider:before {
        height: 16px;
        width: 16px;
    }

    .toggle-switch input:checked + .toggle-slider:before {
        transform: translateX(22px);
    }
}

/* Form text helper */
.form-text {
    display: block;
    margin-top: 5px;
    font-size: 13px;
    color: #666;
    font-style: italic;
}

/* ===== SETTINGS PAGE STYLES ===== */
.settings-form {
    max-width: 1200px;
}

.settings-section {
    background: white;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.settings-section .section-header {
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e5e5e5;
}

.settings-section .section-header h2 {
    color: #21758c;
    font-size: 22px;
    margin-bottom: 5px;
}

.settings-section .section-header h2 i {
    margin-right: 10px;
}

.section-description {
    color: #666;
    font-size: 14px;
    margin: 0;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.form-group-full {
    grid-column: 1 / -1;
}

.info-box {
    background: #e8f4f8;
    border-left: 4px solid #21758c;
    padding: 15px 20px;
    border-radius: 6px;
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.info-box i {
    color: #21758c;
    font-size: 24px;
    flex-shrink: 0;
}

.info-box strong {
    display: block;
    margin-bottom: 5px;
    color: #21758c;
}

.info-box p {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.info-box a {
    color: #21758c;
    text-decoration: underline;
}

.info-box-warning {
    background: #fff9e6;
    border-left: 4px solid #ffc107;
}

.info-box-warning i {
    color: #ffc107;
}

.info-box-warning strong {
    color: #d39e00;
}

.system-info {
    background: #f9f9f9;
    border-radius: 6px;
    padding: 20px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #e5e5e5;
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: #333;
}

.info-value {
    color: #666;
    font-family: monospace;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-start;
    padding: 20px 0;
}

.btn-large {
    padding: 12px 24px;
    font-size: 16px;
}

/* Alert boxes */
.alert {
    padding: 15px 20px;
    border-radius: 6px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert i {
    font-size: 20px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

@media (max-width: 768px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }

    .settings-section {
        padding: 20px;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn {
        width: 100%;
    }
}

/* ================================================
   Administrators Page Styles
   ================================================ */

/* Info Box - Warning */
.info-box {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 30px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.info-box-warning {
    border-left: 4px solid #ffc107;
}

.info-box > i {
    font-size: 24px;
    color: #ffc107;
    margin-top: 3px;
}

.info-box strong {
    display: block;
    margin-bottom: 5px;
    color: #333;
}

.info-box p {
    margin: 0;
    color: #666;
    line-height: 1.6;
}

/* Administrators Grid */
.admins-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.admins-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.admin-card {
    border: 2px solid #e5e5e5;
    border-radius: 8px;
    background: white;
    transition: all 0.3s;
}

.admin-card:hover {
    border-color: #21758c;
    box-shadow: 0 4px 12px rgba(33, 117, 140, 0.15);
}

.admin-card.current-user {
    border-color: #f2795a;
    background: #fff8f6;
}

.admin-card.inactive {
    opacity: 0.6;
    background: #f8f9fa;
}

.admin-card-header {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    border-bottom: 2px solid #e5e5e5;
    position: relative;
}

.admin-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #21758c 0%, #0d3d4d 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 20px;
    flex-shrink: 0;
}

.admin-card.current-user .admin-avatar {
    background: linear-gradient(135deg, #f2795a 0%, #d35a3c 100%);
}

.admin-info {
    flex: 1;
}

.admin-info h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #333;
}

.admin-info p {
    margin: 0;
    color: #666;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.badge-you {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #f2795a;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.admin-card-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.admin-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.admin-detail label {
    color: #666;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.admin-detail label i {
    color: #21758c;
    width: 16px;
}

.admin-detail span {
    color: #333;
    font-weight: 600;
    font-size: 13px;
}

.admin-card-footer {
    padding: 15px 20px;
    border-top: 2px solid #e5e5e5;
    display: flex;
    gap: 10px;
}

/* Administrators Page - Responsive */
@media (max-width: 768px) {
    .admins-grid {
        grid-template-columns: 1fr;
    }

    .admin-card-footer {
        flex-direction: column;
    }

    .admin-card-footer .btn {
        width: 100%;
        justify-content: center;
    }
}

/* ===== BULK BLOCKING (Hromadná blokace) ===== */

.bulk-blocking-section {
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.bulk-blocking-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0;
    padding-bottom: 20px;
    border-bottom: 2px solid #e5e5e5;
}

.bulk-blocking-section .section-header h2 {
    margin: 0;
    color: #21758c;
    font-size: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.bulk-blocking-section #bulkBlockingForm {
    padding-top: 20px;
}

/* Info box pro hromadnou blokaci */
.info-box-info {
    background: #d1ecf1;
    border-left: 4px solid #17a2b8;
}

.info-box-info i {
    color: #17a2b8;
}

/* Checkbox group pro hromadnou blokaci */
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Form actions (tlačítka) */
.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* Preview container */
#bulkBlockPreview {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Badge styly pro náhled dnů */
.badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
    text-align: center;
    white-space: nowrap;
    border-radius: 4px;
    vertical-align: middle;
}

.badge-success {
    background: #28a745;
    color: white;
}

.badge-warning {
    background: #ffc107;
    color: #333;
}

/* Bulk Blocking - Responsive */
@media (max-width: 768px) {
    .bulk-blocking-section .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions button {
        width: 100%;
    }

    #bulkBlockPreview {
        padding: 15px;
    }

    .checkbox-group {
        gap: 8px;
    }
}

/* ========================================
   SEARCHABLE USER DROPDOWN
   Vlastní vyhledávací dropdown pro výběr uživatelů v rezervačním formuláři
   ======================================== */

.searchable-select-wrapper {
    position: relative;
    width: 100%;
}

.searchable-select-input {
    width: 100%;
    padding-right: 35px;
    cursor: text;
}

/* Ikona vyhledávání v inputu */
.searchable-select-input::before {
    content: '\f002';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    pointer-events: none;
}

/* Dropdown container */
.searchable-select-dropdown {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-height: 400px;
    overflow-y: auto;
    z-index: 9999; /* Zvýšeno z 1000 - musí být nad modály */
    animation: dropdownSlideDown 0.2s ease-out;
}

@keyframes dropdownSlideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Seznam možností */
.searchable-select-options {
    padding: 5px 0;
}

/* Jedna možnost v dropdownu */
.searchable-select-option {
    padding: 12px 15px;
    cursor: pointer;
    transition: background 0.2s ease;
    border-bottom: 1px solid #f5f5f5;
}

.searchable-select-option:last-child {
    border-bottom: none;
}

.searchable-select-option:hover {
    background: #f0f7fa;
}

/* Jméno uživatele (hlavní text) */
.user-option-name {
    font-weight: 600;
    color: #0d3d4d;
    margin-bottom: 5px;
    font-size: 14px;
}

/* Detaily (firma + email) */
.user-option-details {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 12px;
    color: #666;
    margin-top: 5px; /* Přidána mezera mezi jménem a detaily */
}

.user-option-company,
.user-option-email {
    display: flex;
    align-items: center;
    gap: 5px;
}

.user-option-company i {
    color: #21758c;
    font-size: 12px;
}

.user-option-email i {
    color: #999;
    font-size: 12px;
}

/* Prázdný stav (žádné výsledky) */
.searchable-select-option.no-results {
    padding: 20px 15px;
    text-align: center;
    color: #999;
    font-style: italic;
    cursor: default;
}

.searchable-select-option.no-results:hover {
    background: white;
}

/* Scrollbar pro dropdown */
.searchable-select-dropdown::-webkit-scrollbar {
    width: 8px;
}

.searchable-select-dropdown::-webkit-scrollbar-track {
    background: #f5f5f5;
    border-radius: 0 6px 6px 0;
}

.searchable-select-dropdown::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.searchable-select-dropdown::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* Responzivita */
@media (max-width: 768px) {
    .searchable-select-dropdown {
        max-height: 300px;
    }

    .user-option-details {
        flex-direction: column;
        gap: 5px;
    }

    .searchable-select-option {
        padding: 10px 12px;
    }
}

/* ===== NOVÉ: Kalendářové zobrazení blokací ===== */

/* View toggle wrapper */
.view-toggle-wrapper {
    display: flex;
    gap: 10px;
    justify-content: center;
}

/* Toggle tlačítka pro přepínání zobrazení */
.view-toggle-btn {
    padding: 10px 20px;
    font-size: 14px;
    transition: all 0.3s ease;
    flex: 1;
    max-width: 200px;
}

.view-toggle-btn.active {
    background-color: var(--primary-color, #21758c);
    color: white;
    border-color: var(--primary-color, #21758c);
}

.view-toggle-btn:not(.active):hover {
    background-color: #f0f7fa;
}

/* Kalendář - hlavička dnů */
.calendar-day-header {
    padding: 10px;
    text-align: center;
    font-weight: 600;
    color: #666;
    background: #f5f5f5;
    border-radius: 4px;
    font-size: 13px;
}

/* Kalendář - den */
.calendar-day {
    min-height: 100px;
    padding: 8px;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    position: relative;
    transition: all 0.2s ease;
}

.calendar-day:not(.empty):hover {
    border-color: #21758c;
    box-shadow: 0 2px 8px rgba(33, 117, 140, 0.2);
}

.calendar-day.empty {
    background: #fafafa;
    border-color: transparent;
}

/* Den - číslo dne */
.calendar-day .day-number {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

/* Den - popisek (důvod) */
.calendar-day .day-label {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 6px;
    border-radius: 3px;
    margin-bottom: 4px;
    line-height: 1.2;
}

/* Den - čas (pro částečné blokace) */
.calendar-day .day-time {
    font-size: 10px;
    color: #666;
    margin-top: 4px;
}

/* Blokovaný celý den */
.calendar-day.blocked-full {
    background: #ffebee;
    border-color: #ef5350;
}

.calendar-day.blocked-full .day-label {
    background: #ef5350;
    color: white;
}

/* Částečně blokovaný */
.calendar-day.blocked-partial {
    background: #fff3e0;
    border-color: #ff9800;
}

.calendar-day.blocked-partial .day-label {
    background: #ff9800;
    color: white;
}

/* Responzivita kalendáře */
@media (max-width: 1024px) {
    .calendar-grid {
        gap: 5px;
    }

    .calendar-day {
        min-height: 80px;
        padding: 5px;
    }

    .calendar-day .day-number {
        font-size: 14px;
    }

    .calendar-day .day-label {
        font-size: 10px;
    }
}

@media (max-width: 768px) {
    .calendar-day {
        min-height: 60px;
    }

    .calendar-day .day-label,
    .calendar-day .day-time {
        font-size: 9px;
    }
}
