/* Responsive Header Style */
.flex-header-responsive {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .flex-header-responsive {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

/* Global Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    color: black;
}

/* Compatibility fallbacks for broader browser support */
html {
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
    -webkit-user-select: text;
    user-select: text;
    /* Provide safe default for backdrop-filter for Safari */
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
}

body.prevent-pull-to-refresh {
    overscroll-behavior-y: contain;
}

footer {
    margin-top: auto;
    background-color: #585858ff;
    padding: 10px;
    text-align: center;
    color: white;
}

/* Impersonating indicator */
.impersonating {
    background: linear-gradient(45deg, #ff6b6b, #fbc02d);
    color: white !important;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: bold;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    flex: 1;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    box-sizing: border-box;
    margin-bottom: 30px;
}

header {
    background-color: #333;
    color: white;
    padding: 10px 0;
}

.admin-sticky {
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: #333;
}

.server-time {
    text-align: left;
    font-size: 14px;
    margin: 0;
    color: #ccc;
}

.week-number {
    font-size: 12px;
    margin-top: 2px;
    color: #ccc;
}

.app-version {
    font-size: 12px;
    margin-top: 2px;
    color: #ccc;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: right;
    position: relative;
}

nav ul li {
    display: inline-block;
    margin: 0 15px;
    position: relative;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    padding: 10px 15px;
    display: block;
    transition: background-color 0.3s;
}

nav ul li a:hover {
    background-color: #ccc;
    border-radius: 4px;
}

/* Dropdown menu styles */
.dropdown-trigger {
    position: relative;
}

.dropdown-toggle {
    cursor: pointer;
    border: 1px solid white;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
}

.dropdown {
    /* Side panel instead of dropdown */
    display: block;
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 260px; /* Made narrower for desktop */
    background-color: #f9f9f9;
    box-shadow: -8px 0 16px rgba(0,0,0,0.2);
    z-index: 1005;
    border-left: 1px solid #ccc;
    transform: translateX(100%);
    transition: transform 0.25s ease-in-out;
    overflow-y: auto;
    overflow-x: hidden;
    /* Ensure dropdown appears above footer */
    margin-top: 0;
    padding-bottom: 20px; /* Extra space at bottom */
}

.dropdown li a {
    padding: 10px 14px; /* Reduced padding for more compact look */
    text-align: left;
    white-space: nowrap;
    color: #333 !important;
    font-size: 14px; /* Slightly smaller font */
}

.dropdown.open {
    transform: translateX(0);
}

    /* Side panel link layout improvements */
    .dropdown {
        width: 320px; /* Keep wider for mobile */
        padding-top: 18px;
        box-sizing: border-box;
    }
    .dropdown .group {
        padding: 12px 20px; /* Better touch targets for mobile */
        font-weight: 600;
        color: #233041;
        font-size: 14px; /* Slightly larger for mobile readability */
        border-bottom: 1px solid rgba(0,0,0,0.06);
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    .dropdown li a {
        display: block;
        padding: 16px 20px; /* Larger touch targets for mobile (44px min recommended) */
        color: #0b2b45;
        font-size: 16px; /* Prevent zoom on iOS, good readability */
        text-decoration: none;
        border-bottom: 1px solid rgba(0,0,0,0.03);
    }
    .dropdown li a:hover { background: rgba(0,0,0,0.02); color: #001522; }
    .dropdown .spacer { height: 10px; }
    .dropdown .footer-links { padding: 12px 20px; font-size: 12px; color: #557089; }

    /* Enhanced mobile and desktop dropdown handling */
    .dropdown {
        max-height: 100vh;
        -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
        /* Better mobile touch handling */
        -webkit-tap-highlight-color: rgba(0,0,0,0.1);
    }

    .dropdown li a {
        font-size: 16px; /* Prevent zoom on iOS */
        padding: 16px 20px; /* Consistent with above, good touch targets */
        min-height: 44px; /* Minimum touch target size */
        display: flex;
        align-items: center;
    }

    /* Ensure logout button is always visible and prominent */
    .dropdown li:last-child {
        border-top: 2px solid #e0e0e0;
        margin-top: 20px;
        padding-top: 10px;
        position: sticky;
        bottom: 0;
        background-color: #f9f9f9;
    }

    .dropdown li:last-child a {
        background-color: #dc3545;
        color: white !important;
        font-weight: bold;
        text-align: center;
        margin: 8px 14px; /* More compact margins for desktop */
        border-radius: 6px;
        display: block;
        font-size: 13px; /* Smaller font to match other links */
    }

    .dropdown li:last-child a:hover {
        background-color: #c82333;
        color: white !important;
    }

    /* Mobile-specific logout button improvements */
    @media (max-width: 768px) {
        .dropdown li:last-child a {
            margin: 12px 20px; /* Better margins for mobile */
            border-radius: 8px; /* More rounded for mobile */
            min-height: 48px; /* Larger touch target for mobile */
            font-size: 16px; /* Better readability on mobile */
            display: flex;
            align-items: center;
            justify-content: center;
        }

        /* Better mobile touch targets for all links */
        .dropdown li a {
            min-height: 44px; /* Minimum recommended touch target */
            padding: 14px 20px;
        }

        /* Better mobile group styling */
        .dropdown .group {
            padding: 14px 20px;
            font-size: 15px;
        }

        /* Better mobile color coding for groups */
        .dropdown .group.c20 {
            background-color: rgba(21, 101, 192, 0.12);
            border-left: 4px solid #1565c0;
        }

        .dropdown .group.c30 {
            background-color: rgba(102, 26, 154, 0.12);
            border-left: 4px solid #6a1b9a;
        }
    }
    .table-responsive { overflow-x: auto; }
    .table-site-overview-c20-vinyl { overflow-x: auto; background-color: #fefaf4; }
    .table-site-overview-c30-vinyl { overflow-x: auto; }
    table.vinyl-table { width: 100%; border-collapse: collapse; margin-top: 12px; }
    table.vinyl-table th, table.vinyl-table td { padding: 10px 12px; border: 1px solid #d0d0d0; border-bottom: none; text-align: left; vertical-align: middle; }
    table.vinyl-table thead th { border-bottom: 1px solid #e0e0e0; }
    table.vinyl-table tbody tr { border-bottom: 1px solid #e0e0e0; }
    table.vinyl-table thead th { background: #f6f9fc; font-weight: 700; font-size: 13px; }
    table.vinyl-table tbody tr:nth-child(even) { background: #fbfeff; }
    table.vinyl-table .small { font-size: 12px; color: #6b7d8a; }
    @media (max-width: 600px) {
        table.vinyl-table th, table.vinyl-table td { padding: 8px 10px; font-size: 13px; }
    }
    /* Enhanced styling */
    table.vinyl-table { border-radius: 8px; overflow: hidden; box-shadow: 0 2px 6px rgba(16,24,40,0.06); }
    /* Make buttons inside Bemaning (h) cells stack / allow line breaks */
    .bg-c30-cell { white-space: normal !important; }
    .bg-c30-cell .uk-button,
    .bg-c30-cell button,
    .bg-c30-cell .btn {
        display: block !important;
        width: auto !important;
        margin: 4px 0 !important;
        white-space: normal !important;
    }
    /* Force the .uk-width-auto column to break onto its own row inside the cell */
    .bg-c30-cell .uk-width-auto {
        flex-basis: 100% !important;
        width: 100% !important;
        display: block !important;
        margin-top: 6px !important;
    }
    table.vinyl-table thead th { background: linear-gradient(180deg,#f8fafc,#eef6fb); color: #0b2b45; }
    table.vinyl-table tbody tr:hover { background: #f1f7fb; }
    .status-badge { display:inline-block; padding:4px 8px; border-radius:12px; font-size:12px; color:#fff; }
    .status-prepared { background:#f59e0b; }
    .status-released { background:#10b981; }
    .status-closed { background:#6b7280; }
    .vinyl-title-cell { max-width:540px; white-space:normal; overflow-wrap:break-word; word-break:break-word; font-size:14px; line-height:1.35; color:#0b2b45; }
    /* Admin dashboard vinyl title cell line breaking */
    .c20-vinyl-widget .vinyl-title-cell {
        word-break: break-all;
        overflow-wrap: anywhere;
        max-width: none;
    }

    .c30-vinyl-widget .vinyl-title-cell {
        word-break: break-all;
        overflow-wrap: anywhere;
        max-width: none;
    }

    /* Center text in buttons within vinyl-card rows */
    .vinyl-card .btn {
        display: flex;
        align-items: center;
        justify-content: center;
        text-align: center;
    }

    /* Alternating background colors for vinyl-card rows to distinguish campaigns */
    .table-site-overview-c20-vinyl .campaign-bg-0 {
        background-color: #ffffff !important;
    }
    .table-site-overview-c30-vinyl .campaign-bg-0 {
        background-color: #ffffff !important;
    }
    .table-site-overview-c20-vinyl .campaign-bg-1 {
        background-color: #f8f9fa !important;
    }
    .table-site-overview-c30-vinyl .campaign-bg-1 {
        background-color: #f8f9fa !important;
    }
    .table-site-overview-c20-vinyl .campaign-bg-2 {
        background-color: #e9ecef !important;
    }
    .table-site-overview-c30-vinyl .campaign-bg-2 {
        background-color: #e9ecef !important;
    }
    .table-site-overview-c20-vinyl .campaign-bg-3 {
        background-color: #dee2e6 !important;
    }
    .table-site-overview-c30-vinyl .campaign-bg-3 {
        background-color: #dee2e6 !important;
    }

/* Improved layout for side panel links */
.dropdown {
    padding: 12px 0;
    box-sizing: border-box;
    /* Better desktop handling */
    width: 260px; /* Even more compact for desktop */
    scrollbar-width: thin; /* Firefox */
    scrollbar-color: #ccc #f9f9f9; /* Firefox */
}

.dropdown::-webkit-scrollbar { /* Chrome, Safari, Edge */
    width: 8px;
}

.dropdown::-webkit-scrollbar-track {
    background: #f9f9f9;
}

.dropdown::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.dropdown::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

.dropdown .group.c20, .dropdown .group.c30 {
    padding: 8px 14px; /* More compact for desktop */
    font-size: 12px; /* Smaller font */
    text-transform: uppercase;
    letter-spacing: 0.6px;
    border-bottom: 1px solid #eee;
    margin-bottom: 4px; /* Less margin */
}

.dropdown .group.c20 {
    background-color: rgba(21, 101, 192, 0.08);
    border-left: 2px solid #1565c0;
}

.dropdown .group.c30 {
    background-color: rgba(102, 26, 154, 0.08);
    border-left: 2px solid #6a1b9a;
}
.dropdown li { display: block; }
.dropdown li a {
    display: block;
    padding: 8px 14px; /* More compact for desktop */
    font-size: 13px; /* Smaller font */
    color: #333 !important;
    border-bottom: 1px solid rgba(0,0,0,0.04);
}
.dropdown li a:hover {
    background: #f1f1f1;
    color: #000 !important;
}
.dropdown .c20-item a { color: #1565c0 !important; }
.dropdown .c30-item a { color: #6a1b9a !important; }
.dropdown .spacer { height: 10px; }
.dropdown .footer-links { padding: 12px 20px; font-size: 13px; color: #666; }

.dropdown li a:hover {
    background-color: #eee;
    color: black !important;
}

.dropdown .group.c20 {
    background: #ddd;
    font-weight: bold;
    padding: 8px 16px;
    color: #1976d2;
}

.dropdown .group.c30 {
    background: #ddd;
    font-weight: bold;
    padding: 8px 16px;
    color: #7b1fa2;
}

.dropdown .c20-item a {
    color: #1976d2 !important;
}

.dropdown .c30-item a {
    color: #7b1fa2 !important;
}

h1, h2 {
    color: black;
}

form {
    margin-bottom: 20px;
}

.edit-form {
    width: 1150px;
    max-width: 100%;
    margin: 0 auto;
    padding: 20px;
    background-color: #f4f4f4;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    box-sizing: border-box;
}

.add-user-form {
    width: 1150px;
    max-width: 100%;
    margin: 20px auto;
    padding: 20px;
    background-color: #f4f4f4;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    box-sizing: border-box;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

/* Ensure readable text inside add user form */
.add-user-form,
.add-user-form label,
.add-user-form p,
.add-user-form h1,
.add-user-form h2,
.add-user-form .form-group,
.add-user-form .form-actions,
.add-user-form input,
.add-user-form select,
.add-user-form textarea {
    color: #000 !important;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: white;
    box-shadow: 0 0 5px rgba(51,51,51,0.3);
}

.form-actions {
    text-align: center;
    margin-top: 20px;
}

.btn-primary {
    background-color: white;
    color: black;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    margin-right: 10px;
    text-decoration: none;
    display: inline-block;
}

.btn-primary:hover {
    background-color: #ccc;
}

.btn-secondary {
    background-color: #ccc;
    color: black;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    text-decoration: none;
    display: inline-block;
}

/* Ensure Apply Filter button text is readable */
#applyFilterBtn {
    color: black !important;
}

.btn-secondary:hover {
    background-color: #ccc;
}

/* Reset-selected button: ensure readable text on gray background */
.btn-reset-selected,
#reset-selected {
    background-color: #CCCCCC !important;
    color: black !important;
    border: none !important;
    padding: 10px 20px !important;
    border-radius: 4px !important;
    cursor: pointer !important;
}

.btn-reset-selected:hover,
#reset-selected:hover {
    background-color: #bfbfbf !important;
}

/* Selected campaign badge on register pages */
.selected-campaign {
    display: inline-block;
    padding: 6px 10px;
    background: #fff8c6;
    color: #333;
    border-radius: 4px;
    margin-top: 8px;
    font-weight: 600;
}

.selected-campaign.flash {
    animation: flashHighlight 2s ease;
}

@keyframes flashHighlight {
    0% { background: #fff8c6; }
    50% { background: #ffd54f; }
    100% { background: #fff8c6; }
}

/* Layout for sticky button rows on vinyl registration pages */
.sticky-buttons-v1,
.sticky-buttons-v2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px;
    width: 100%;
    box-sizing: border-box;
}

.sticky-buttons-v1 .search-input-vinyl {
    flex: 1 1 320px;
    max-width: 520px;
}

.sticky-buttons-v1 .mb-10 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sticky-buttons-v1 .btn-bulk-add-cyan {
    margin-left: 8px;
}

.sticky-buttons-v2 .flex-center-gap-15,
.sticky-buttons-v2 .flex-center-gap-10 {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Make buttons stack on small screens */
@media (max-width: 700px) {
    .sticky-buttons-v1,
    .sticky-buttons-v2 {
        flex-direction: column;
        align-items: stretch;
    }
    .sticky-buttons-v1 .search-input-vinyl,
    .sticky-buttons-v1 .btn-bulk-add-cyan,
    .sticky-buttons-v2 .flex-center-gap-15,
    .sticky-buttons-v2 .flex-center-gap-10 {
        width: 100%;
    }
    .sticky-buttons-v2 .flex-center-gap-15,
    .sticky-buttons-v2 .flex-center-gap-10 {
        justify-content: space-between;
    }
}

.error-message {
    background-color: #f8d7da;
    color: #721c24;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid #f5c6cb;
}

.dashboard-container {
    width: 1200px;
    max-width: 100%;
    margin: 0;
}

.welcome-card {
    background: linear-gradient(135deg, #1976d2 0%, #7b1fa2 100%);
    color: white;
    padding: 30px;
    border-radius: 10px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    display: none;
}

.welcome-card h1 {
    margin: 0 0 10px 0;
    font-size: 2.5em;
}

.welcome-text {
    font-size: 1.1em;
    margin: 0;
    opacity: 0.9;
}

.profile-card {
    background-color: #f4f4f4;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.profile-card h2 {
    margin-top: 0;
    color: white;
    border-bottom: 2px solid #1976d2;
    padding-bottom: 10px;
}

.profile-details {
    margin: 20px 0;
}

.profile-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
}

.profile-item:last-child {
    border-bottom: none;
}

.label {
    font-weight: bold;
    color: #ccc;
    flex: 0 0 150px;
}

.value {
    color: white;
    text-align: right;
    flex: 1;
}

.dashboard-actions {
    text-align: center;
    margin-top: 30px;
}

button {
    background-color: white;
    color: white;
    cursor: pointer;
}

button:hover {
    background-color: #ccc;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table th, table td {
    padding: 10px;
    border: 1px solid #ddd;
    text-align: left;
}

table th {
    background-color: #f2f2f2;
}

/* ################ */

/* Grundläggande stil för hela formuläret */
.edit-form {
    width: 1150px;
    max-width: 100%;
    margin: 50px auto;
    padding: 20px;
    background-color: #f4f4f4;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    font-family: Arial, sans-serif;
    box-sizing: border-box;
}

/* Ensure readable text on white backgrounds in admin edit form */
.edit-form,
.edit-form label,
.edit-form p,
.edit-form h1,
.edit-form h2,
.edit-form .form-group,
.edit-form .form-actions,
.edit-form input,
.edit-form select,
.edit-form textarea {
    color: #000 !important;
}

/* Stil för varje formulärgrupp */
.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-weight: bold;
  color: white;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
  font-size: 14px;
  transition: border-color 0.2s;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="password"]:focus {
  border-color: #1976d2;
  outline: none;
}

/* Stil för password-toggle container */
.password-toggle {
  display: flex;
  align-items: center;
  margin-top: 6px;
}

/* Göm checkboxen */
.password-toggle input[type="checkbox"] {
  display: none;
}

/* Snygg switch styling */
.password-toggle label.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
  background-color: #ccc;
  border-radius: 34px;
  cursor: pointer;
  transition: background-color 0.2s;
  margin-right: 10px;
}

/* Knappen inuti switchen */
.password-toggle label.switch::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.2s;
}

/* Ändra färg och flytta knappen när checkbox är ikryssad */
.password-toggle input[type="checkbox"]:checked + label.switch {
  background-color: #1976d2;
}

.password-toggle input[type="checkbox"]:checked + label.switch::before {
  transform: translateX(26px);
}

/* Stil för "Show password" text */
.password-toggle span {
  font-size: 14px;
  color: white;
}

/* Stil för knappen i formuläret */
.form-actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
}

.btn-primary {
  background-color: #1976d2;
  color: #fff;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s;
}

.btn-primary:hover {
  background-color: #0056b3;
}

/* Login Page Styles */
.login-page .server-time { display: none; }
.login-page #nav-menu { display: none; }
.login-page .header-container { position: static; }

.login-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 30px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form .form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: black;
}

.login-form .form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
    color: black;
}

.login-form .form-group label input[type="checkbox"] {
    width: auto;
    margin-right: 5px;
}

.edit-form .form-group label input[type="checkbox"] {
    width: auto;
    margin-right: 5px;
}

.login-form .form-actions {
    text-align: center;
}

.login-form .form-actions .btn-primary {
    padding: 12px 30px;
    background: #1976d2;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.login-form .form-actions .btn-primary:hover {
    background: #0056b3;
}

/* C20 view table specific styles */
.dashboard-container table th,
.dashboard-container table td {
    width: 100px;
}

.dashboard-container table th:nth-child(5),
.dashboard-container table td:nth-child(5) {
    width: 40px;
}

.hidden-column {
    display: none !important;
}

.c20-widget-full-access .btn-primary, .c20-widget-full-access .btn-secondary {
    width: 120px;
    display: inline-block;
    margin-right: 10px;
    margin-bottom: 0;
}

@keyframes rainbowShift {
    0% { --angle: 0deg; }
    100% { --angle: 360deg; }
}

#planned.c20-column, #completed.c20-column {
    padding: 10px;
    border-radius: 5px;
    background: transparent;
    border: 1px solid;
    border-image: linear-gradient(var(--angle), #800080, #38f9d7, #ff69b4, #43e97b, #ffff00) 1;
    animation: rainbowShift 4s ease-in-out infinite;
    z-index: 0;
    --angle: 0deg;
}
/* Register C20 Page Styles */
.register-c20-container {
    background-color: var(--register-c20-bg, #c8d4ee) !important;
    color: var(--register-c20-color, #000) !important;
}

.sticky-nav-menu {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #333;
}

.sticky-buttons-1 {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #f0f0f0;
    padding: 0px 0;
    border-bottom: 20px solid #ddd;
    outline: 1px solid #e0e0e0;
    outline-offset: -1px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.sticky-column {
    position: sticky;
    z-index: 99;
}

#completed h2 {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #f0f0f0;
    padding: 10px;
    margin: -10px -10px 10px -10px;
    border-bottom: 1px solid #ddd;
}

/* .sticky-buttons-2 {
    position: sticky;
    top: 0;
    z-index: 100;
    background: white;
    padding: 15px 0;
    border-bottom: 2px solid #ddd;
    outline: 1px solid #e0e0e0;
    outline-offset: -1px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
} */

.sticky-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2px 5px;
    background: rgba(255,255,255,0.95);
    border-radius: 0px;
    margin-bottom: 0px;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    margin: 0;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 10px;
    order: 1;
    flex: 1;
}

.button-group-right {
    display: flex;
    align-items: center;
    gap: 5px;
    order: 2;
}

.btn-group-left {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 110px;
    padding: 4px 8px;
    border-radius: 4px;
    background: rgba(0,0,0,0.05);
}

.btn-group-center {
    width: 115px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 4px 8px;
    border-radius: 4px;
    background: rgba(0,0,0,0.05);
}

.btn-group-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-width: 100px;
    padding: 4px 8px;
    border-radius: 4px;
    background: rgba(0,0,0,0.05);
}

.nav-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 10px;
    order: 6;
}

/* Position nav-row buttons: left (back), center (move), right (submit) */
.nav-row {
    position: relative;
}
.nav-row > .btn-back-dashboard {
    position: absolute;
    left: 0;
}
.nav-row > .btn-submit-c20 {
    position: absolute;
    right: 0;
}
.nav-row > .btn-move-selected {
    margin: 0 auto;
}

.search-input-c20 {
    width: 100%;
    max-width: 200px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.btn-bulk-add {
    padding: 10px 20px;
    background: #17a2b8;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.btn-refresh {
    padding: 10px 20px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.button-group-right {
    display: flex;
    gap: 10px;
}

.btn-back-dashboard {
    padding: 10px 20px;
    background: #ddd;
    color: black;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

.btn-move-selected {
    padding: 10px 20px;
    background: #1976d2;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.btn-submit-c20 {
    padding: 10px 20px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.c20-flex-layout, .c30-flex-layout, .c20-container-flex {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.mobile-scroll-divider {
    display: none;
}

.c20-column, .c30-column, .c20-column-flex {
    flex: 1;
    min-width: 0;
}

/* Ensure legacy c20-flex-layout / c20-column (used by C30 pages) also stretch like the container-flex variant */
.c20-flex-layout, .c30-flex-layout {
    align-items: stretch;
}
.c20-column, .c30-column {
    display: flex;
    flex-direction: column;
}
.c20-column .list-none-p0, .c20-column-flex .list-none-p0,
.c20-column .c20-list-reset, .c20-column-flex .c20-list-reset {
    flex: 1;
    min-height: 400px;
    overflow: auto;
}

@media (max-width: 768px) {
    /* Side-by-side columns on mobile as requested */
    .c20-flex-layout, .c30-flex-layout {
        flex-direction: row !important;
        flex-wrap: nowrap !important;
    }

    /* Smaller navigation elements on mobile */
    .dropdown-toggle {
        padding: 5px 10px !important;
        font-size: 14px !important;
    }

    #theme-toggle {
        padding: 5px !important;
        font-size: 14px !important;
        width: auto !important;
        height: auto !important;
    }

    .server-time {
        font-size: 11px !important;
        padding: 2px 5px !important;
    }
}

.c20-list-reset {
    list-style: none;
    padding: 0;
    min-height: 400px;
}

.planned-item-style {
    padding: 5px;
    margin: 5px 0;
    background: #f4f4f4;
    border: 1px solid #ddd;
    border-radius: 3px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.planned-item-style.submitted {
    opacity: 0.5;
    background: #ffcccc;
}

.checkbox-margin {
    margin-right: 10px;
}

.red-text-small {
    color: red;
    font-size: 12px;
}

/* Status Modal Styles */
.status-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.status-modal-content {
    background: white;
    padding: 20px;
    border-radius: 10px;
    max-width: 300px;
    width: 90%;
}

.status-label-avstalld { background-color: #ffcccc; }
.status-label-nej { background-color: lightyellow; }
.status-label-ej-na { background-color: lightyellow; }
.status-label-fardig { background-color: lightgreen; }

/* Dynamic Item Backgrounds */
.item-bg-fardig { background-color: #d4edda !important; }
.item-bg-avstalld { background-color: #ffcccc !important; }
.item-bg-other { background-color: #ddd3cd !important; }
.item-bg-default { background-color: #f4f4f4 !important; }

/* Register C30 Page Styles */
.c30-flex-layout {
    display: flex;
    gap: 20px;
}

.c30-column {
    flex: 1;
    border: 1px solid #ddd;
    padding: 10px;
    border-radius: 5px;
}

.item-bg-blocked {
    opacity: 0.5;
    background-color: #e0e0e0 !important;
}

.grey-text-small {
    color: #ccc;
    font-size: 12px;
}

.label-block {
    display: block;
    margin-bottom: 10px;
}

.btn-margin-right {
    margin-right: 10px;
}

/* View Pages Styles */
.white-container {
    background-color: #ddd !important;
    color: #000 !important;
}

.c20-widget-full-access {
    background: #c8d4ee;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.c20-stat-widget {
    background: #ffffff;
    border-radius: 12px;
    padding: 0;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid #ddd;
    overflow: hidden;
}

.c20-stat-widget .stat-container {
    display: flex;
    gap: 20px;
    padding: 15px;
    flex-wrap: wrap;
}

.c20-stat-widget .stat-group {
    flex: 1;
    min-width: 300px;
    background: rgba(255, 160, 0, 0.1);
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #ffa000;
}

.c20-stat-widget .stat-group h3 {
    margin-top: 0;
    color: #e65100;
    display: flex;
    justify-content: space-between;
}

.c20-stat-widget .stat-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 15px;
}

.c20-stat-widget .progress-container {
    background: rgba(0,0,0,0.1);
    height: 20px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    margin-top: 5px;
}

.c20-stat-widget .progress-bar {
    background: #ffa000;
    height: 100%;
    transition: width 0.3s;
}

.c20-stat-widget .progress-text {
    position: absolute;
    width: 100%;
    text-align: center;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    line-height: 1;
    color: #000;
    font-weight: bold;
    text-shadow: 0 0 3px rgba(255, 255, 255, 0.8);
    z-index: 2;
}

.c20-stat-widget .button-container {
    padding: 10px 15px;
    text-align: right;
    background: rgba(0,0,0,0.02);
}

.c20-stat-widget .button-container a.btn-primary {
    background: #ffa000 !important;
    border-color: #ff8f00 !important;
    color: #fff !important;
}

.c20-stat-widget .widget-header {
    background: #fff4e5;
    padding: 15px 20px;
    border-bottom: 1px solid #ffe0b2;
}

.c20-stat-widget h2 {
    margin: 0;
    font-size: 1.25rem;
    color: #e65100;
}



.status-stats-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    border: 1px solid #ddd;
    width: 1160px;
    max-width: 100%;
}

.status-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.status-stat {
    padding: 15px;
    border-radius: 6px;
    text-align: center;
    border: 1px solid #ddd;
}

.status-stat-value {
    font-size: 24px;
    font-weight: bold;
    color: black;
}

.status-stat-label {
    font-size: 14px;
    color: black;
    margin: 5px 0;
}

.status-stat-percentage {
    font-size: 12px;
    color: black;
}

.total-reported-box {
    margin-top: 15px;
    padding: 10px;
    background: white;
    border-radius: 4px;
    text-align: center;
}

.btn-group-left {
    margin-bottom: 20px;
    text-align: left;
}

.search-input-full {
    padding: 8px;
    margin-right: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    display: block;
    margin-bottom: 10px;
}

.sort-select {
    padding: 8px;
    margin-right: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.filter-container-flex {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.filter-label-flex {
    display: flex;
    align-items: center;
}

.btn-save-settings {
    padding: 10px 15px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    flex: 1;
    min-width: 120px;
}

.btn-reset-settings {
    padding: 10px 15px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    flex: 1;
    min-width: 120px;
}

.btn-danger-flex {
    padding: 10px 15px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    flex: 1;
    min-width: 120px;
}

.btn-return-small {
    padding: 5px 10px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 3px;
    cursor: pointer;
}
.item-bg-default { background-color: #f4f4f4 !important; }
.btn-back-dashboard { padding: 10px 20px; background: #ddd; color: black; border: none; border-radius: 5px; cursor: pointer; } .mr-1 { margin-right: 5px; }

.c30-widget-full-access {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}


.btn-view-records { padding: 10px 20px; background: #1976d2; color: white; border: none; border-radius: 5px; cursor: pointer; }

/* Vinyl Registration Styles */
.bg-c20-vinyl { background-color: #c8d4ee !important; color: #000 !important; }
.nav-menu-sticky { position: sticky; top: 0; z-index: 100; background: #333; }
.sticky-buttons-v1 {
    position: sticky;
    top: 0;
    z-index: 100;
    background: white;
    padding: 8px 10px;
    border-bottom: 1px solid #ccc;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    box-sizing: border-box;
}
.sticky-buttons-v2 {
    position: sticky;
    top: 60px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    z-index: 1;
    padding: 8px 10px;
}
.search-input-small { width: 100%; max-width: 200px; padding: 8px; margin-bottom: 10px; border: 1px solid #ddd; border-radius: 3px; }
.btn-bulk-add-cyan { padding: 10px 20px; background: #17a2b8; color: white; border: none; border-radius: 5px; cursor: pointer; }
.btn-move-selected { padding: 10px 20px; background: #1976d2; color: white; border: none; border-radius: 5px; cursor: pointer; }
.btn-submit-vinyl { padding: 10px 20px; background: #28a745; color: white; border: none; border-radius: 5px; cursor: pointer; }
.sticky-buttons-v2 .btn-submit-vinyl { margin-left: auto; }
.border-right-gray { border-right: 1px solid #ccc; padding-right: 10px; }
.flex-center-gap-15 { display: flex; align-items: center; gap: 15px; }
.flex-center-gap-10 { display: flex; gap: 10px; justify-content: center; }

/* Vinyl Registration Specifics */
.form-container-vinyl { padding: 20px; }
.search-input-vinyl { width: 100%; max-width: 200px; padding: 8px; margin-bottom: 10px; border: 1px solid #ddd; border-radius: 3px; }
.c20-container-flex { display: flex; gap: 20px; align-items: stretch; }
.c20-column-flex { flex: 1; display: flex; flex-direction: column; }
/* Ensure the lists inside columns expand to fill column height so completed matches planned */
.c20-column-flex .list-none-p0 { flex: 1; min-height: 400px; overflow:auto; }
.planned-item-vinyl { padding: 5px; margin: 5px 0; background: #f4f4f4; border: 1px solid #ddd; border-radius: 3px; display: flex; justify-content: center; align-items: center; cursor: pointer; }
.registered-item { opacity: 0.5; background: #ffcccc !important; }
.text-red-small { color: red; font-size: 12px; }
.m-0 { margin: 0 !important; }
.mb-10 { margin-bottom: 10px !important; }
.mr-5 { margin-right: 5px !important; }
.list-none-p0 { list-style: none; padding: 0; min-height: 400px; }

.mr-10 { margin-right: 10px !important; }
.d-block { display: block !important; }


.widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.widget-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
}
.stat-item {
    background: rgba(255,255,255,0.1);
    padding: 10px;
    border-radius: 8px;
    text-align: center;
    color: black;
}
.progress-bar-container {
    background: #e0e0e0;
    height: 20px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}
.progress-bar-fill {
    height: 100%;
}
.progress-container {
    position: relative;
    margin: 10px 0;
}
.progress-bar {
    background: #e0e0e0;
    height: 25px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
    position: relative;
}
.progress-fill {
    height: 100%;
    transition: width 0.5s ease;
}
.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-weight: bold;
    color: black;
    text-shadow: 0 0 3px rgba(255, 255, 255, 0.8);
    z-index: 2;
    width: 100%;
    text-align: center;
}
.button-container {
    display: flex;
    gap: 10px;
    justify-content: center;
    position: relative;
    z-index: 2;
    width: 250px;
    margin: 0 auto;
}

/* Status and Summary Cards */
.reset-status-card {
    background: white;
    border: 1px solid #28a745;
    padding: 10px;
    border-radius: 8px;
    margin: 10px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    flex: 1;
}

.time-status-card {
    background: white;
    border: 1px solid #007bff;
    padding: 10px;
    border-radius: 8px;
    margin: 10px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    flex: 1;
}

.time-status-card h3 {
    color: #007bff;
    margin: 0 0 10px 0;
}

.time-status-card p {
    color: #333;
    margin: 0;
    font-size: 14px;
}

.status-cards-container {
    display: flex;
    gap: 20px;
    margin: 10px 0;
}

@media (max-width: 768px) {
    .status-cards-container {
        flex-direction: column;
    }
}

.reset-status-card h3 {
    color: #28a745;
    margin: 0 0 10px 0;
}
.reset-status-card p {
    color: #28a745;
    margin: 0;
}

.user-summary-widget {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.user-summary-widget h2 {
    margin-top: 0;
}
.user-summary-widget table {
    width: 100%;
    border-collapse: collapse;
}
.user-summary-widget table th, .user-summary-widget table td {
    padding: 8px;
    border: 1px solid #dee2e6;
}
.user-summary-widget table th:nth-child(1), .user-summary-widget table td:nth-child(1) { width: 50px; }
.user-summary-widget table th:nth-child(9), .user-summary-widget table td:nth-child(9) { width: 50px; }
.user-summary-widget table th:nth-child(n+2):nth-child(-n+8), .user-summary-widget table td:nth-child(n+2):nth-child(-n+8) { width: 40px; }
.user-summary-widget table thead tr {
    background: #e9ecef;
}
.restrict-weekends th:nth-child(6),
.restrict-weekends td:nth-child(6),
.restrict-weekends th:nth-child(7),
.restrict-weekends td:nth-child(7),
.restrict-weekends th:nth-child(8),
.restrict-weekends td:nth-child(8) {
    background-color: #f8f9fa !important;
    color: #6c757d !important;
}

.impersonation-text { color: #ccc; font-size: 14px; margin-top: 5px; }

/* Statistics Page Styles */
.stats-container {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}
.stats-table-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    background: white;
}
.stats-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    gap: 15px;
}
@media (max-width: 768px) {
    .stats-header {
        flex-direction: column;
        text-align: center;
    }
}
.filter-container {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #dee2e6;
}
.filter-form {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}
.filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}
.filter-group label {
    font-weight: bold;
    color: #333;
}
.filter-group select {
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: white;
    min-width: 100px;
}
.btn-filter {
    background: #007bff;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}
.btn-filter:hover {
    background: #0056b3;
}
.btn-clear-filter {
    background: #6c757d;
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
}
.btn-clear-filter:hover {
    background: #545b62;
}
@media (max-width: 768px) {
    .filter-form {
        flex-direction: column;
        align-items: stretch;
    }
    .filter-group {
        justify-content: space-between;
    }
}
.stats-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    margin: 0;
}
.stats-table th, .stats-table td {
    padding: 10px 8px;
    text-align: center;
    border: 1px solid #ddd;
    font-size: 13px;
}
.hour-input {
    width: 60px;
    padding: 4px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
}
.btn-save-hours {
    background: #28a745;
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
}
.kpi-box {
    font-size: 11px;
    color: #ccc;
    margin-top: 4px;
    line-height: 1.2;
}
.kpi-value {
    font-weight: bold;
    color: white;
}
.stats-table thead th {
    background-color: #333;
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 13px;
}
.stats-table tbody tr:hover {
    background-color: #f4f4f4;
}
.bg-c20-header { background-color: #1976d2 !important; color: white !important; }
.bg-c30-header { background-color: #f57f17 !important; color: white !important; }
.bg-c20-cell { background-color: #1976d2; color: white !important; }
.bg-c30-cell { background-color: #fbc02d; color: black !important; }
th.bg-c30-cell { color: white !important; }
.bg-c30-cell .kpi-value { color: black !important; }
.bg-c30-cell .kpi-box { color: #333 !important; }
.btn-stats {
    display: inline-block;
    padding: 10px 20px;
    background: #ddd;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
}
.btn-stats:hover {
    background: #5a6268;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
}
.badge-success { background-color: #28a745; color: white; }
.badge-info { background-color: #17a2b8; color: white; }

/* User Management Styles (moved from users.php) */
.table-container {
    max-width: 1300px;
    overflow-x: auto;
    margin: 20px auto 0 auto;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.table-container tr:nth-child(even) {
    background-color: #f2f2f2;
}
.admin-users-table {
    width: 100%;
    min-width: 1127.78px;
    border-collapse: collapse;
    font-size: 12px;
}
.admin-users-table th,
.admin-users-table td {
    padding: 6px 8px;
    border: 1px solid #ddd;
    text-align: left;
    white-space: nowrap;
}
.admin-users-table th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: black;
}
.admin-users-table td:nth-child(1) { width: 35px; }
.admin-users-table td:nth-child(2) { width: 80px; }
.admin-users-table td:nth-child(3) { width: 50px; }
.admin-users-table td:nth-child(4) { width: 30px; }
.admin-users-table td:nth-child(5),
.admin-users-table td:nth-child(6),
.admin-users-table td:nth-child(7),
.admin-users-table td:nth-child(8),
.admin-users-table td:nth-child(9),
.admin-users-table td:nth-child(10),
.admin-users-table td:nth-child(11),
.admin-users-table td:nth-child(12),
.admin-users-table td:nth-child(13),
.admin-users-table td:nth-child(14),
.admin-users-table td:nth-child(15),
.admin-users-table td:nth-child(16) { width: 30px; }
.admin-users-table td:nth-child(17) { width: 80px; }
.admin-users-table td:nth-child(18) { width: 100px; }
.admin-users-table td:nth-child(19) { width: 100px; }
.admin-users-table td:nth-child(20) { width: 50px; }
.admin-users-table td:nth-child(21) { width: 60px; }
.admin-users-table td:nth-child(22) { width: 50px; }

.access-options {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 10px;
}
.access-category {
    flex: 1;
    min-width: 200px;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #f8f9fa;
    color: black;
}
.access-category h4 {
    margin: 0 0 10px 0;
    color: #495057;
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.access-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: normal;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #ffffff;
    transition: all 0.2s ease;
    cursor: pointer;
    margin-bottom: 8px;
    color: black;
}
.access-checkbox:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}
.access-checkbox input[type="checkbox"] {
    margin: 0;
    width: 16px;
    height: 16px;
}
.access-checkbox span {
    transition: color 0.2s ease;
}
.access-checkbox input[type="checkbox"]:checked + span {
    font-weight: bold;
    color: #007bff;
}

.permissions-section {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    color: black;
}

.permissions-section h3 {
    margin: 0 0 15px 0;
    color: #495057;
    font-size: 16px;
    font-weight: 600;
    border-bottom: 2px solid #007bff;
    padding-bottom: 5px;
}

.permissions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

/* Column Filters (New classes for users.php) */
.column-filters-card {
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    color: black;
}
.filter-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
}
.toggle-icon {
    font-size: 14px;
    color: #666;
    transition: transform 0.3s ease;
}
.filter-card-body {
    display: none;
    margin-top: 15px;
}
.filter-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    border-top: 1px solid #dee2e6;
    padding-top: 15px;
}
.column-filters-card h3 {
    margin-top: 0;
    margin-bottom: 10px;
    color: black;
}
.column-filters-card p {
    margin-bottom: 15px;
    font-size: 14px;
    color: #666;
}
.filter-groups-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}
.filter-category-box {
    flex: 1;
    min-width: 250px;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #ffffff;
    color: black;
}
.filter-category-box h4 {
    margin: 0 0 10px 0;
    color: #495057;
    font-size: 14px;
    font-weight: bold;
}
.filter-inputs-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.filter-options-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.filter-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: black;
}

.access-yes {
    background-color: #d2d8be !important;
}

.access-no {
    background-color: #dcc7c8 !important;
}

.c20-vinyl-widget {
    background: rgba(76, 175, 80, 0.05);
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
    margin-bottom: 25px;
    border-left: 5px solid #4CAF50;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    color: black;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.c30-vinyl-widget {
    background: rgba(33, 150, 243, 0.05);
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
    margin-bottom: 25px;
    border-left: 5px solid #2196F3;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    color: black;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Vinyl Management Styles */
.vinyl-management {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.add-vinyl-section {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.add-vinyl-section h2 {
    margin-top: 0;
    color: #333;
}

.vinyl-form-group {
    margin-bottom: 15px;
}

.vinyl-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.vinyl-form-group input,
.vinyl-form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.vinyl-form-group input:focus,
.vinyl-form-group select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 5px rgba(81, 203, 238, 0.3);
}

/* Color option styles */
.color-option-blue {
    background-color: #007bff !important;
    color: white !important;
}

.color-option-green {
    background-color: #28a745 !important;
    color: white !important;
}

.color-option-red {
    background-color: #dc3545 !important;
    color: white !important;
}

.color-option-yellow {
    background-color: #ffc107 !important;
    color: black !important;
}

.color-option-purple {
    background-color: #6f42c1 !important;
    color: white !important;
}

.color-option-orange {
    background-color: #fd7e14 !important;
    color: white !important;
}

.color-option-pink {
    background-color: #e83e8c !important;
    color: white !important;
}

.color-option-teal {
    background-color: #20c997 !important;
    color: white !important;
}

.color-option-indigo {
    background-color: #6610f2 !important;
    color: white !important;
}

/* Title input group */
.title-input-group {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.title-input-group input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.remove-title-btn {
    display: none;
    margin-left: 10px;
    padding: 8px 12px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.remove-title-btn:hover {
    background: #c82333;
}

/* Week range flex layout */
.week-range-container {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.week-range-container select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    min-width: 80px;
}

/* Modal styles */
.vinyl-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
}

.vinyl-modal-content {
    position: relative;
    background: white;
    margin: 5% auto;
    padding: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.close-modal:hover {
    color: #333;
}

/* Remove title button visibility based on single title */
.remove-title-btn[data-single="true"] {
    display: none;
}

.remove-title-btn[data-single="false"] {
    display: inline-block;
}

/* Vinyl item border colors based on data-color attribute */
.vinyl-item[data-color="blue"] {
    border-left-color: #007bff;
}

.vinyl-item[data-color="green"] {
    border-left-color: #28a745;
}

.vinyl-item[data-color="red"] {
    border-left-color: #dc3545;
}

.vinyl-item[data-color="yellow"] {
    border-left-color: #ffc107;
}

.vinyl-item[data-color="purple"] {
    border-left-color: #6f42c1;
}

.vinyl-item[data-color="orange"] {
    border-left-color: #fd7e14;
}

.vinyl-item[data-color="pink"] {
    border-left-color: #e83e8c;
}

.vinyl-item[data-color="teal"] {
    border-left-color: #20c997;
}

.vinyl-item[data-color="indigo"] {
    border-left-color: #6610f2;
}

/* Complete Vinyl Management Styles for Light Mode */
.vinyl-management {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.add-vinyl-section, .existing-vinyl-section {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn {
    background: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.btn:hover {
    background: #0056b3;
}

.btn-danger {
    background: #dc3545;
}

.btn-danger:hover {
    background: #c82333;
}

.vinyl-item {
    background: #f8f9fa;
    padding: 15px;
    margin: 10px 0;
    border-radius: 6px;
    border-left: 4px solid #007bff;
}

.vinyl-item.inactive {
    border-left-color: #6c757d;
    opacity: 0.7;
}

.vinyl-item.prepared {
    border-left-color: #ffc107; /* Default yellow, can be overridden by inline styles */
    background: #fff3cd;
}

.vinyl-main-title {
    font-size: 16px;
    font-weight: bold;
    color: #856404;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vinyl-title {
    font-weight: bold;
    margin-bottom: 5px;
}

.vinyl-meta {
    font-size: 12px;
    color: #666;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.vinyl-file-info {
    font-size: 12px;
    margin-bottom: 10px;
}

.file-indicator {
    color: #28a745;
    font-weight: bold;
}

.no-file-indicator {
    color: #6c757d;
    font-style: italic;
}

.vinyl-type-select {
    padding: 2px 4px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 11px;
    background: white;
}

.vinyl-type-select:disabled {
    background: #f8f9fa;
    color: #6c757d;
}

.vinyl-description {
    margin-bottom: 10px;
    font-size: 14px;
}

.vinyl-actions {
    display: flex;
    gap: 10px;
}

.title-input-group {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.title-input-group input {
    flex: 1;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.remove-title-btn {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    margin-left: 8px;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.remove-title-btn:hover {
    background: #c82333;
}

#addTitleBtn {
    margin-top: 10px;
    background: #28a745 !important;
}

#addTitleBtn:hover {
    background: #218838 !important;
}

/* Button variants */
.btn-success {
    background: #28a745;
    color: white;
}
.btn-success:hover {
    background: #218838;
}
.btn-warning {
    background: #ffc107;
    color: #212529;
}
.btn-warning:hover {
    background: #e0a800;
}

/* Delete confirmation spacing */
.delete-confirm {
    display: block;
    margin: 12px 0 8px 0;
    font-size: 13px;
    color: #333;
}

.vinyl-actions {
    display: flex;
    gap: 10px;
    margin-top: 6px;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    color: #333;
}

.close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: #000;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    max-height: calc(90vh - 140px);
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

@media (max-width: 768px) {
    .vinyl-management {
        grid-template-columns: 1fr;
    }
}

/* User Panel Vinyl Widgets */
.c20-vinyl-widget {
    margin-top: 16px;
    border: 1px solid #e0e0e0;
    padding: 12px;
    border-radius: 6px;
    background: #f0e0b4;
}

.c30-vinyl-widget {
    margin-top: 16px;
    border: 1px solid #e0e0e0;
    padding: 12px;
    border-radius: 6px;
    background: #f0e0b4;
}

/* Alternating row colors in vinyl widget tables */
.c20-vinyl-widget .vinyl-widget-table tbody tr:nth-child(even) {
    background-color: rgba(248, 249, 250, 1.0) !important;
}

.c30-vinyl-widget .vinyl-widget-table tbody tr:nth-child(even) {
    background-color: rgba(248, 249, 250, 1.0) !important;
}

.c20-vinyl-widget .vinyl-widget-table tbody tr:nth-child(odd) {
    background-color: rgba(255, 255, 255, 1.0) !important;
}

.c30-vinyl-widget .vinyl-widget-table tbody tr:nth-child(odd) {
    background-color: rgba(255, 255, 255, 1.0) !important;
}

/* Vinyl widget table styling */
.c20-vinyl-widget .vinyl-widget-table th,
.c20-vinyl-widget .vinyl-widget-table td {
    text-align: left;
    padding: 4px 6px;
    border-bottom: 1px solid #eee;
    vertical-align: top;
    font-size: 13px;
}

.c30-vinyl-widget .vinyl-widget-table th,
.c30-vinyl-widget .vinyl-widget-table td {
    text-align: left;
    padding: 4px 6px;
    border-bottom: 1px solid #eee;
    vertical-align: top;
    font-size: 13px;
}

/* Compact table layout for vinyl widgets */
.c20-vinyl-widget .vinyl-widget-table {
    table-layout: fixed;
    width: 100%;
}

.c30-vinyl-widget .vinyl-widget-table {
    table-layout: fixed;
    width: 100%;
}

.c20-vinyl-widget .vinyl-widget-table th:nth-child(1),
.c20-vinyl-widget .vinyl-widget-table td:nth-child(1) {
    width: 8%;
    text-align: center;
}

.c30-vinyl-widget .vinyl-widget-table th:nth-child(1),
.c30-vinyl-widget .vinyl-widget-table td:nth-child(1) {
    width: 8%;
    text-align: center;
}

.c20-vinyl-widget .vinyl-widget-table th:nth-child(2),
.c20-vinyl-widget .vinyl-widget-table td:nth-child(2) {
    width: 35%;
}

.c30-vinyl-widget .vinyl-widget-table th:nth-child(2),
.c30-vinyl-widget .vinyl-widget-table td:nth-child(2) {
    width: 35%;
}

.c20-vinyl-widget .vinyl-widget-table th:nth-child(3),
.c20-vinyl-widget .vinyl-widget-table td:nth-child(3) {
    width: 20%;
    text-align: center;
}

.c30-vinyl-widget .vinyl-widget-table th:nth-child(3),
.c30-vinyl-widget .vinyl-widget-table td:nth-child(3) {
    width: 20%;
    text-align: center;
}

.c20-vinyl-widget .vinyl-widget-table th:nth-child(4),
.c20-vinyl-widget .vinyl-widget-table td:nth-child(4) {
    width: 18%;
    text-align: center;
}

.c30-vinyl-widget .vinyl-widget-table th:nth-child(4),
.c30-vinyl-widget .vinyl-widget-table td:nth-child(4) {
    width: 18%;
    text-align: center;
}

.c20-vinyl-widget .vinyl-widget-table th:nth-child(5),
.c20-vinyl-widget .vinyl-widget-table td:nth-child(5) {
    width: 19%;
    text-align: center;
}

.c30-vinyl-widget .vinyl-widget-table th:nth-child(5),
.c30-vinyl-widget .vinyl-widget-table td:nth-child(5) {
    width: 19%;
    text-align: center;
}

/* Progress bar styling for vinyl widgets */
.progress-cell {
    min-width: 120px;
    text-align: center;
}

/* Vinyl progress bar container */
.vinyl-progress-container {
    background: #eee;
    border-radius: 4px;
    overflow: hidden;
    height: 8px;
    width: 100%;
    max-width: 140px;
    display: block;
    margin: 0 auto;
}

/* Vinyl progress bar fill (dynamic background and width) */
.vinyl-progress-fill {
    height: 8px;
}

/* Vinyl progress text */
.vinyl-progress-text {
    margin-top: 6px;
    font-size: 0.95em;
    text-align: center;
}

/* Vinyl widget buttons */
.btn-view {
    background: #6c757d;
    color: #fff;
    padding: 6px 12px;
    border-radius: 4px;
    text-decoration: none;
}

.btn-register {
    background: #007bff;
    color: #fff;
    padding: 6px 12px;
    border-radius: 4px;
    text-decoration: none;
}

.btn-view:hover, .btn-register:hover {
    opacity: 0.8;
}

/* Alternating button colors in vinyl widget tables */
.c20-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-primary,
.c20-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-secondary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-primary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-secondary {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
}

.c20-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-primary,
.c20-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-secondary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-primary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-secondary {
    background-color: #007bff !important;
    border-color: #007bff !important;
}

/* Alternating button colors in vinyl widget tables */
.c20-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-primary,
.c20-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-secondary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-primary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(even) .btn-secondary {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
}

.c20-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-primary,
.c20-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-secondary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-primary,
.c30-vinyl-widget .table-responsive tbody tr:nth-child(odd) .btn-secondary {
    background-color: #007bff !important;
    border-color: #007bff !important;
}
