:root {
    --primary-color: #CC6CE6;
    --primary-hover: #b84dd9;
    --primary-light: rgba(204, 108, 230, 0.1);
    --text-main: #32325d;
    --text-light: #8898aa;
    --bg-body: #f6f9fc;
    --sidebar-bg: #ffffff;
    --border-color: #e3e8ee;
    --white: #ffffff;

    /* Status Colors */
    --confirmed: #2dce89;
    --confirmed-bg: #e0fbf4;
    --pending: #fb6340;
    --pending-bg: #fff5f3;
    --cancelled: #f5365c;
    --cancelled-bg: #fee7e7;
    --upcoming: #5e72e4;
    --upcoming-bg: #e8ecfa;
}

*,
body,
button,
input,
select,
textarea {
    font-family: 'Nunito', sans-serif;
}

body {
    background-color: var(--bg-body);
    margin: 0;
    color: var(--text-main);
}

/* Layout Structure */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
    padding: 20px;
    box-sizing: border-box;
    gap: 20px;
    position: relative;
    overflow: hidden;
}

.sidebar {
    width: 200px;
    background-color: var(--sidebar-bg);
    border-radius: 30px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    flex-shrink: 0;
    z-index: 1000;
}

.sidebar-close-btn {
    display: none;
}

.main-content {
    flex: 1;
    background: #fff;
    border-radius: 30px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.03);
    overflow-y: auto;
}

/* Sidebar Components */
.brand-section {
    margin-bottom: 40px;
}

.section-label {
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-light);
    margin: 25px 0 15px;
    font-weight: 800;
    letter-spacing: 0.8px;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 12px 18px;
    color: #525f7f;
    text-decoration: none;
    border-radius: 12px;
    margin-bottom: 5px;
    font-weight: 700;
    font-size: 0.95rem;
    transition: all 0.2s;
    gap: 12px;
}

.nav-item i {
    width: 20px;
    font-size: 1rem;
    color: #adb5bd;
}

.nav-item:hover,
.nav-item.active {
    background: var(--primary-light);
    color: var(--primary-color);
}

.nav-item.active i {
    color: var(--primary-color);
}

.nav-badge {
    background: #f5365c;
    color: white;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 50px;
    margin-left: auto;
    box-shadow: 0 4px 8px rgba(245, 54, 92, 0.3);
    min-width: 18px;
    text-align: center;
}

.logout-link {
    color: #f5365c;
}

.logout-link:hover {
    background: #fee7e7;
}

.user-profile-section {
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 15px;
    padding-top: 25px;
    border-top: 1px solid #f6f9fc;
}

.user-profile-section .avatar {
    width: 42px;
    height: 42px;
    border-radius: 12px;
}

.user-info h4 {
    margin: 0;
    font-size: 0.95rem;
    color: var(--text-main);
}

.user-info span {
    font-size: 0.8rem;
    color: var(--text-light);
    font-weight: 600;
}

/* Dashboard & Common Stats Cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.booking-card {
    background: white;
    border-radius: 20px;
    padding: 22px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    border: 2px solid transparent;
    transition: all 0.3s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 140px;
    position: relative;
    overflow: visible;
}

.booking-card::before {
    content: '';
    position: absolute;
    right: -10px;
    bottom: -10px;
    width: 100px;
    height: 100px;
    opacity: 0.15;
    background-size: contain;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: 0;
}

/* .card-purple::before {
    background-image: url('../images/bg-mountain-pattern.png');
    width: 150px;
    opacity: 0.1;
}

.card-yellow::before {
    background-image: url('../images/star-patttern.svg');
    transform: rotate(15deg);
}

.card-blue::before {
    background-image: url('../images/leaf-pattern.svg');
    transform: rotate(-10deg);
}

.card-green::before {
    background-image: url('../images/flower-patttern.svg');
} */

.booking-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
}

.booking-card.active {
    border-color: var(--primary-color);
    background: #fdfaff;
}

.booking-card.active::after {
    content: '\f0d7';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--primary-color);
    font-size: 40px;
}

.card-top {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
}

.card-icon-box {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: white;
    flex-shrink: 0;
}

.card-details h3 {
    font-size: 0.95rem;
    margin: 0 0 5px;
    color: var(--text-main);
    font-weight: 700;
}

.card-details p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-light);
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-main);
}

.card-purple .card-icon-box {
    background: linear-gradient(135deg, #CC6CE6 0%, #B84DD9 100%);
}

.card-yellow .card-icon-box {
    background: linear-gradient(135deg, #ffd600 0%, #ffca00 100%);
}

.card-blue .card-icon-box {
    background: linear-gradient(135deg, #11cdef 0%, #1171ef 100%);
}

.card-green .card-icon-box {
    background: linear-gradient(135deg, #2dce89 0%, #2dcecc 100%);
}

/* Common UI Elements */
.content-section {
    padding-bottom: 40px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0;
}

.section-subtitle {
    margin: 5px 0 0;
    color: var(--text-light);
    font-size: 0.95rem;
    font-weight: 500;
}

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

/* Forms & Inputs */
.search-input-wrapper {
    position: relative;
    width: 100%;
    max-width: 350px;
}

.search-input-wrapper i.fa-search {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 0.9rem;
    z-index: 2;
}

.premium-search-input {
    width: 100%;
    padding: 12px 15px 12px 40px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    font-size: 0.9rem;
    transition: all 0.2s;
    font-family: inherit;
    color: var(--text-main);
    box-sizing: border-box;
}

.premium-search-input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 4px rgba(204, 108, 230, 0.1);
}

.premium-select {
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-family: inherit;
    color: var(--text-main);
    font-weight: 600;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
}

.premium-select:focus {
    border-color: var(--primary-color);
    outline: none;
}

.premium-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-align: center;
    justify-content: center;
}

.premium-btn:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(204, 108, 230, 0.3);
}

.premium-btn.full-width {
    width: 100%;
}

/* Tables */
.premium-table-wrapper {
    background: white;
    border-radius: 20px;
    border: 1px solid #f0f0f0;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.02);
}

.modern-table {
    width: 100%;
    border-collapse: collapse;
}

.modern-table th {
    background: #fafbfd;
    padding: 12px 15px;
    text-align: left;
    font-size: 0.72rem;
    font-weight: 800;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #f6f9fc;
}

.modern-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #f6f9fc;
    vertical-align: middle;
    font-size: 0.8rem;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
}

.custom-table th {
    text-align: left;
    padding: 10px 15px;
    color: var(--text-light);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    border-bottom: 2px solid #f6f9fc;
}

.custom-table td {
    padding: 10px 15px;
    border-bottom: 1px solid #f6f9fc;
    vertical-align: middle;
    font-size: 0.8rem;
}

/* Table Cells */
.patient-cell,
.patient-info-box {
    display: flex;
    align-items: center;
    gap: 12px;
}

.avatar-circle,
.mini-avatar {
    width: 38px;
    height: 38px;
    background: #f3e5f5;
    color: var(--primary-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.mini-avatar {
    border-radius: 50%;
    width: 34px;
    height: 34px;
}

.patient-cell .name,
.p-name {
    font-weight: 700;
    color: var(--text-main);
    font-size: 0.82rem;
}

.sub-text {
    color: var(--text-light);
    font-size: 0.72rem;
    font-weight: 600;
}

.id-cell {
    font-weight: 800;
    color: var(--text-light);
}

.contact-box,
.dt-box {
    display: flex;
    flex-direction: column;
}

.contact-box span,
.dt-box .d-text {
    font-weight: 700;
    color: var(--text-main);
}

.contact-box small,
.dt-box .t-text {
    color: var(--text-light);
    font-size: 0.8rem;
    font-weight: 600;
}

/* Status Badges */
.status-badge,
.badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    display: inline-block;
}

.status-confirmed,
.badge-confirmed,
.status-active {
    background: var(--confirmed-bg);
    color: var(--confirmed);
}

.status-pending,
.badge-pending {
    background: var(--pending-bg);
    color: var(--pending);
}

.status-cancelled,
.badge-cancelled {
    background: var(--cancelled-bg);
    color: var(--cancelled);
}

.status-upcoming,
.badge-upcoming {
    background: var(--upcoming-bg);
    color: var(--upcoming);
}

/* Buttons & Links */
.view-btn {
    width: 35px;
    height: 35px;
    background: #f6f9fc;
    color: var(--primary-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    text-decoration: none;
}

.view-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.btn-sm-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    color: white;
    background: var(--primary-color);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    box-shadow: 0 2px 6px rgba(204, 108, 230, 0.25);
    white-space: nowrap;
}

.btn-sm-action:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(204, 108, 230, 0.4);
}

.btn-sm-action:focus {
    outline: none;
    box-shadow: 0 0 0 3px var(--primary-light);
}

.btn-sm-action i {
    font-size: 0.85rem;
}

/* Tabs */
.view-toggle-container,
.header-tabs {
    display: flex;
    gap: 8px;
    background: #f6f9fc;
    padding: 5px;
    border-radius: 12px;
}

.view-tab,
.nav-tab {
    padding: 10px 20px;
    border: none;
    border-radius: 9px;
    background: transparent;
    color: var(--text-light);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.view-tab.active,
.nav-tab.active {
    background: white;
    color: var(--primary-color);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.04);
}

/* Appointments Page Specific */
.calendar-controls-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 20px;
}

.nav-btns {
    display: flex;
    gap: 10px;
}

.ctrl-btn {
    padding: 10px 18px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid var(--border-color);
    color: var(--text-main);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.ctrl-btn:hover,
.ctrl-btn.active {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: var(--primary-light);
}

.calendar-glass-container {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    display: flex;
    overflow: hidden;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.04);
}

.time-column {
    width: 100px;
    border-right: 1px solid rgba(0, 0, 0, 0.05);
    background: rgba(255, 255, 255, 0.5);
}

.time-header-spacer {
    height: 70px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.session-indicator {
    padding: 15px 10px;
    font-size: 0.7rem;
    font-weight: 800;
    color: #adb5bd;
    text-align: center;
    letter-spacing: 1px;
}

.time-label-cell {
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #8898aa;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.break-spacer {
    height: 60px;
    background: rgba(0, 0, 0, 0.02);
}

.days-main-grid {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-x: auto;
}

.days-header-row {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    min-width: 800px;
    height: 70px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.day-head-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border-right: 1px solid rgba(0, 0, 0, 0.05);
}

.day-head-cell.is-today {
    background: var(--primary-light);
}

.day-head-cell .d-info {
    font-size: 0.75rem;
    font-weight: 800;
    color: #8898aa;
    text-transform: uppercase;
}

.day-head-cell .d-num {
    font-size: 1.2rem;
    font-weight: 800;
    color: #32325d;
}

.day-head-cell.is-today .d-num {
    color: var(--primary-color);
}

.grid-scroll-area {
    display: flex;
    flex-direction: column;
    min-width: 800px;
}

.grid-row {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    height: 50px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.grid-slot {
    border-right: 1px solid rgba(0, 0, 0, 0.03);
    padding: 4px;
    position: relative;
}

.grid-slot.today-slot {
    background: rgba(204, 108, 230, 0.02);
}

.day-divider {
    height: 60px;
    background: #fafbfd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 800;
    color: #adb5bd;
    gap: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.compact-event {
    height: 100%;
    border-radius: 8px;
    padding: 6px 8px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
}

.compact-event:hover {
    transform: scale(1.02);
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.compact-event.status-confirmed {
    background: #e0fbf4;
    color: #2dce89;
    border-left: 3px solid #2dce89;
}

.compact-event.status-pending {
    background: #fff5f3;
    color: #fb6340;
    border-left: 3px solid #fb6340;
}

.compact-event.status-cancelled {
    background: #fee7e7;
    color: #f5365c;
    border-left: 3px solid #f5365c;
}

/* Tooltip */
#booking-tooltip {
    position: fixed;
    display: none;
    background: white;
    border-radius: 16px;
    padding: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    width: 220px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    pointer-events: none;
}

#booking-tooltip h4 {
    margin: 0 0 10px 0;
    font-size: 0.95rem;
    color: #32325d;
    border-bottom: 1px solid #f6f9fc;
    padding-bottom: 8px;
}

#booking-tooltip p {
    margin: 5px 0;
    font-size: 0.8rem;
    color: #525f7f;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tooltip-badge {
    margin-top: 10px;
}

/* Notes Editing */
.notes-cell-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
}

.notes-cell {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.85rem;
    color: #525f7f;
}

.edit-note-btn {
    opacity: 0;
    background: var(--primary-light);
    color: var(--primary-color);
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.75rem;
}

.notes-cell-wrapper:hover .edit-note-btn {
    opacity: 1;
}

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

/* Availability Page Specific */
.availability-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    align-items: start;
}

.glass-card {
    background: white;
    border-radius: 20px;
    padding: 25px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.02);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.card-title {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    align-items: center;
    /* Better vertical alignment */
}

.card-title i {
    width: 42px;
    height: 42px;
    background: #fdfaff;
    color: var(--primary-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* Calendar Centering */
.picker-inner,
.mini-picker {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
    width: 100%;
}

.selection-meta {
    margin-top: auto;
    /* Push to bottom if card stretches */
    border-top: 1px solid #f6f9fc;
    padding-top: 20px;
}

.range-hint {
    color: #525f7f;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 15px;
    text-align: center;
    background: #fdfaff;
    padding: 10px;
    border-radius: 8px;
    border: 1px dashed #e3e8ee;
}

.slot-pill {
    padding: 12px 15px;
    background: white;
    border: 1px solid #DBDBDB;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    color: #4E4D4E;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
}

.slot-pill.unavailable {
    opacity: 0.4;
    cursor: not-allowed;
    background: #f5f5f5;
}

.slots-pill-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 12px;
    margin-top: 20px;
}

.premium-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 10px;
    background: #fdfdfd;
    border: 1px solid #f8f8f8;
    transition: all 0.2s;
}

.del-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: #fee7e7;
    color: #f5365c;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.del-btn:hover {
    background: #f5365c;
    color: white;
}

/* Modals */
.note-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.note-modal-content {
    background: white;
    margin: 10% auto;
    padding: 30px;
    border-radius: 24px;
    width: 400px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.premium-textarea {
    width: 100%;
    height: 120px;
    padding: 15px;
    border: 1px solid #e3e8ee;
    border-radius: 12px;
    margin-bottom: 25px;
    resize: none;
    box-sizing: border-box;
    font-family: inherit;
}

.modal-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.btn-cancel {
    background: #f6f9fc;
    color: #8898aa;
    border: none;
    padding: 12px 25px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
}

.btn-save {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(204, 108, 230, 0.2);
}

/* Filter Styles */
.filters-container {
    background: white;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #e3e8ee;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.search-grid {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.search-select {
    padding: 10px 15px;
    border: 1px solid #e3e8ee;
    border-radius: 8px;
    background-color: white;
    color: #32325d;
    font-size: 0.9rem;
    min-width: 120px;
    cursor: pointer;
    transition: all 0.2s;
}

.search-select:focus {
    border-color: #CC6CE6;
    outline: none;
    box-shadow: 0 0 0 3px rgba(204, 108, 230, 0.1);
}

.btn-filter,
.btn-reset {
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    transition: all 0.2s;
}

.btn-filter {
    background: #CC6CE6;
    color: white;
}

.btn-filter:hover {
    background: #b84dd9;
    transform: translateY(-1px);
}

.btn-reset {
    background: #f6f9fc;
    color: #525f7f;
    text-decoration: none;
}

.btn-reset:hover {
    background: #e9ecef;
    color: #32325d;
}

/* Tabulator Custom Styles */
.tabulator {
    border: none;
    background-color: transparent;
    font-family: inherit;
}

.tabulator-header {
    background-color: transparent !important;
    border-bottom: 2px solid #e3e8ee !important;
    color: #32325d;
    font-weight: 700;
}

.tabulator-headers {
    background-color: transparent !important;
}

.tabulator-col {
    background-color: transparent !important;
    border-right: none !important;
    padding: 10px !important;
}

.tabulator-col-content {
    padding: 8px !important;
}

.tabulator-col-title {
    padding-right: 15px;
}

.tabulator-row {
    background-color: white !important;
    border-bottom: 1px solid #f6f9fc !important;
    color: #525f7f;
    transition: background-color 0.2s;
}

.tabulator-row:hover {
    background-color: #f8f9fa !important;
}

.tabulator-row.tabulator-row-even {
    background-color: white !important;
}

.tabulator-cell {
    border-right: none !important;
    padding: 15px 10px !important;
    display: inline-flex;
    align-items: center;
}

.tabulator-footer {
    background-color: transparent !important;
    border-top: none !important;
    padding: 20px 0 !important;
}

.tabulator-paginator {
    text-align: right;
}

.tabulator-page {
    border: 1px solid #e3e8ee !important;
    border-radius: 4px !important;
    background: white !important;
    color: #525f7f !important;
    padding: 6px 12px !important;
    margin: 0 2px !important;
    font-size: 14px;
}

.tabulator-page.active {
    background: #CC6CE6 !important;
    color: white !important;
    border-color: #CC6CE6 !important;
}

.tabulator-page:hover:not(.active) {
    background: #f6f9fc !important;
}

.tabulator-page[data-page="next"],
.tabulator-page[data-page="prev"],
.tabulator-page[data-page="first"],
.tabulator-page[data-page="last"] {
    color: #8898aa !important;
}

/* Flatpickr Theme Overrides */
.flatpickr-calendar {
    box-shadow: none !important;
    border: none !important;
    width: auto !important;
    max-width: 340px !important;
    margin: 0 auto !important;
    background: transparent !important;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
    background: #CC6CE6 !important;
    border-color: #CC6CE6 !important;
    color: white !important;
    border-radius: 8px !important;
}

.flatpickr-day.inRange {
    background: #f8e1ff !important;
    border-color: transparent !important;
    color: #CC6CE6 !important;
}

.flatpickr-months .flatpickr-month {
    color: #CC6CE6 !important;
}

.flatpickr-current-month .flatpickr-monthDropdown-months {
    font-weight: 700;
    color: #32325d;
    font-size: 18px;
}

.flatpickr-weekday {
    color: #8898aa !important;
    font-weight: 700 !important;
    font-size: 14px;
}

.flatpickr-day {
    color: #32325d !important;
    font-weight: 700 !important;
    border-radius: 8px;
}

.flatpickr-day.today {
    border-color: #CC6CE6 !important;
    color: #CC6CE6 !important;
}

.flatpickr-day.today.selected {
    color: #fff !important;
    background: #CC6CE6 !important;
}

.flatpickr-day.flatpickr-disabled,
.flatpickr-day.flatpickr-disabled:hover {
    cursor: not-allowed;
    color: #ccc !important;
    border-color: transparent;
}

.flatpickr-day {
    border-radius: 8px !important;
}

.time-slot::before,
.slot-pill::before {
    content: '';
    display: block;
    width: 18px;
    height: 18px;
    border: 2px solid #5F5F61;
    border-radius: 50%;
    flex-shrink: 0;
    box-sizing: border-box;
    position: relative;
    background: transparent;
    box-shadow: inset 0 0 0 3px white, inset 0 0 0 10px #5F5F61;
}

.slot-pill:hover {
    border-color: #CC6CE6;
    background: #FAF5FC;
}

.slot-pill.selected {
    border-color: #CC6CE6;
    background: #CC6CE6;
    color: white;
    box-shadow: 0 4px 12px rgba(204, 108, 230, 0.15);
}

.slot-pill.selected::before {
    border-color: white;
    background: #CC6CE6;
    box-shadow: inset 0 0 0 3px #fff;

}

.slot-pill.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #eee;
    border-color: #ddd;
    color: #999;
}

.slot-pill.disabled::before {
    border-color: #ccc;
    background-color: transparent;
    box-shadow: none;
}

/* Utility & Availability Helpers */
.mt-20 {
    margin-top: 20px;
}

.slot-manager {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mini-picker {
    border-bottom: 1px solid #f6f9fc;
    padding-bottom: 20px;
}

.mini-label {
    color: #32325d;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.empty-hint {
    padding: 40px;
    text-align: center;
    color: #adb5bd;
    background: #fdfdfd;
    border: 2px dashed #f0f0f0;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.empty-hint i {
    font-size: 1.5rem;
}

.dt-info {
    display: flex;
    flex-direction: column;
}

.dt-info .main {
    color: #32325d;
    font-weight: 700;
    font-size: 0.95rem;
}

.dt-info .sub {
    color: #8898aa;
    font-size: 0.8rem;
    font-weight: 600;
}

.loader-box {
    padding: 40px;
    text-align: center;
    color: #8898aa;
}

/* Search and Filter Buttons */
.search-form {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-search {
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-search:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(204, 108, 230, 0.3);
}

.btn-apply {
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.btn-apply:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(204, 108, 230, 0.3);
}

.btn-clear {
    padding: 12px 24px;
    background: #f6f9fc;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    white-space: nowrap;
}

.btn-clear:hover {
    background: #e3e8ee;
    border-color: var(--text-light);
    transform: translateY(-2px);
}

.clear-search {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s;
    z-index: 2;
}

.clear-search:hover {
    color: var(--primary-color);
}

.table-filters-card {
    background: white;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 0px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.02);
}

.advanced-filter-form {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.filter-inputs {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    flex: 1;
}

.selector-container {
    display: flex;
    gap: 12px;
    align-items: center;
}

.select-group {
    display: flex;
    gap: 12px;
}

.mobile-menu-toggle {
    display: none;
}

/* Responsive Adjustments */
/* Tablet & Mobile (iPad Landscape/Portrait) */
@media (max-width: 992px) {
    .admin-wrapper {
        flex-direction: column;
        padding: 0;
        overflow-x: hidden;
    }

    .mobile-menu-toggle {
        display: flex;
        position: fixed;
        top: 20px;
        left: 20px;
        z-index: 1001;
        width: 45px;
        height: 45px;
        border-radius: 12px;
        background: white;
        border: none;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
        color: var(--primary-color);
        font-size: 1.2rem;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
    }

    .mobile-menu-toggle:hover {
        transform: scale(1.05);
        color: var(--primary-hover);
    }

    .sidebar {
        position: fixed;
        left: -350px;
        /* Hide completely */
        top: 0;
        width: 280px;
        height: 100vh;
        z-index: 1000;
        border-radius: 0;
        box-shadow: 5px 0 25px rgba(0, 0, 0, 0.1);
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .sidebar.active {
        left: 0;
    }

    /* Overlay for sidebar */
    .sidebar.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 280px;
        width: calc(100vw - 280px);
        min-height: 100vh;
        background: rgba(255, 255, 255, 0.1);
        backdrop-filter: blur(2px);
        z-index: 999;
    }

    .main-content {
        border-radius: 0;
        padding: 80px 10px 40px;
        width: 90%;
        min-height: 100vh;
        overflow-y: hidden;
        margin: auto;
    }

    .custom-table td {
        padding: 10px 15px;
        border-bottom: 1px solid #f6f9fc;
        vertical-align: middle;
        font-size: 0.8rem;
    }

    .content-section {
        overflow-y: scroll;
    }

    /* Grids */
    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .availability-grid {
        grid-template-columns: 1fr;
    }

    .settings-grid {
        grid-template-columns: 1fr;
    }

    /* Tables */
    .premium-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 12px;
    }

    .premium-table {
        min-width: 800px;
        /* Force scroll */
    }

    .filter-inputs,
    .advanced-filter-form {
        flex-direction: column;
        align-items: stretch;
    }

    .selector-container,
    .select-group {
        flex-wrap: wrap;
        width: 100%;
    }

    .search-select,
    .btn-apply,
    .btn-clear {
        width: 100%;
        justify-content: center;
    }

}

/* Mobile Specific */
@media (max-width: 500px) {
    .cards-grid {
        grid-template-columns: 1fr;
    }

    .booking-card {
        min-height: 60px;
        flex-direction: row;
    }

    .card-title {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }

    .card-title i {
        margin-bottom: 10px;
    }

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

    .calendar-controls-wrapper {
        flex-direction: column;
        align-items: stretch;
    }

    .flatpickr-calendar {
        max-width: 100% !important;
        width: 100% !important;
    }

    .slot-pill {
        justify-content: center;
    }

    .picker-inner,
    .mini-picker {
        width: 100%;
    }
}

/* Manual Booking Modal & Form */
.manual-booking-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
}

.manual-booking-content {
    background: #fff;
    margin: 20px auto;
    padding: 30px;
    border-radius: 20px;
    width: 85%;
    max-width: 1000px;
    max-height: 90vh;
    /* Prevents overflow of viewport */
    overflow-y: auto;
    /* Enables scrolling for content */
    position: relative;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

/* Custom scrollbar for better look */
.manual-booking-content::-webkit-scrollbar {
    width: 6px;
}

.manual-booking-content::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 10px;
}

.manual-booking-content h3 {
    margin-top: 0;
    color: var(--text-main);
    font-weight: 800;
    margin-bottom: 30px;
    font-size: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

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

.form-group label {
    font-size: 0.95rem;
    font-weight: 700;
    color: #444;
    margin-bottom: 5px;
}

.premium-input {
    padding: 12px 15px;
    background: #F3F3F5;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 0.95rem !important;
    color: #333;
    font-family: inherit;
    transition: all 0.2s;
}

.premium-input:focus {
    outline: 2px solid var(--primary-color);
    background: #fff;
    box-shadow: none;
}

/* Slot Selection for Manual Booking */
.availability-grid-container {
    margin-top: 30px;
    border-top: 1px solid #eee;
    padding-top: 30px;
}

.availability-split {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 50px;
    align-items: start;
}

/* Modal Flatpickr styling matching public site */
.manual-booking-modal .flatpickr-calendar {
    box-shadow: none !important;
    border: 1px solid #E0E0E0 !important;
    border-radius: 20px !important;
    margin: 0 auto !important;
    width: 320px !important;
    padding: 15px;
    background: #fff;
}

.manual-booking-modal .flatpickr-day {
    border-radius: 8px !important;
    margin-top: 5px;
}

.manual-booking-modal .flatpickr-day.selected,
.manual-booking-modal .flatpickr-day.selected:hover {
    background: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: #fff !important;
    box-shadow: 0 4px 10px rgba(204, 108, 230, 0.3);
}

.manual-booking-modal .flatpickr-day.today {
    border-color: var(--primary-color) !important;
}

.slots-grid-admin {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}

.slot-item-admin {
    padding: 12px 10px;
    border: 1px solid #CECECE;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    text-align: left;
    font-size: 12px;
    color: #515050;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    transition: all 0.2s;
    font-weight: 700;
    line-height: 1;
}

.filter-inputs {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    width: 100%;
}

.left-filters {
    display: flex;
    align-items: center;
    gap: 12px;
}

.export-actions {
    display: flex;
    gap: 10px;
    margin: 10px 0;
    justify-content: end;
    width: 100%;
}

button.modal-close-btn {
    width: 30px;
    position: sticky;
    top: 0px;
    background: #CC6CE6;
    color: white;
    border: #CC6CE6;
    border-radius: 5px;
    height: 30px;
    float: right;
    z-index: 9;
    cursor: pointer;
}

/* Fix Flatpickr Overlap/Transparency from screenshot */
.flatpickr-calendar {
    background: #fff !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
    z-index: 9999 !important;
    border: 1px solid #eee !important;
}

.range-picker-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #F3F3F5;
    border-radius: 8px;
    padding: 0 15px;
    width: 250px;
}

.range-picker-wrapper i {
    color: #999;
    margin-right: 10px;
}

.range-picker-wrapper .range-input {
    background: transparent !important;
    padding: 12px 0 !important;
    font-size: 0.9rem !important;
    border: none !important;
    width: 100%;
}

.range-picker-wrapper .range-input:focus {
    outline: none !important;
}

.export-btn {
    background: #fff !important;
    border: 1px solid #CECECE !important;
    color: #515050 !important;
    display: flex;
    align-items: center;
    justify-content: end;
    gap: 8px;
    padding: 10px 20px !important;
    height: 48px;
    cursor: pointer;

}

.export-btn-wrapper {
    display: flex;
    justify-content: end;
}

.export-btn:hover {
    background: #f8f9fa !important;
    border-color: var(--primary-color) !important;
    color: var(--primary-color) !important;
}

/* Radio Circle Icon matching public site */
.slot-item-admin::before {
    content: '';
    display: block;
    width: 18px;
    height: 18px;
    border: 2px solid #5F5F61;
    border-radius: 50%;
    flex-shrink: 0;
    box-sizing: border-box;
    position: relative;
    background: transparent;
    box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 10px #5F5F61;
}

.slot-item-admin.selected {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

.slot-item-admin.selected::before {
    border-color: #fff;
    box-shadow: inset 0 0 0 3px var(--primary-color), inset 0 0 0 10px #fff;
}

.slot-item-admin.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #eee;
    border-color: #ddd;
    color: #999;
}

.slot-item-admin.disabled::before {
    border-color: #ccc;
    background-color: transparent;
    box-shadow: none;
}

.slot-section-title {
    grid-column: 1 / -1;
    font-size: 0.8rem;
    font-weight: 800;
    color: #adb5bd;
    margin: 10px 0 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modal-footer {
    margin-top: 30px;
    display: flex;
    justify-content: flex-end;
    gap: 15px;
}

.manual-booking-modal .ctrl-btn {
    padding: 12px 25px;
    border-radius: 10px;
    border: 1px solid #ddd;
    background: #fff;
    color: #333;
    font-weight: 600;
    cursor: pointer;
}

.manual-booking-modal .premium-btn {
    padding: 12px 25px;
    border-radius: 10px;
    border: none;
    background: var(--primary-color);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(204, 108, 230, 0.2);
}

.manual-booking-modal .premium-btn:hover {
    filter: brightness(0.95);
}

#admin-slots-loader {
    display: none;
    padding: 20px;
    text-align: center;
    color: var(--text-light);
}


@media (max-width: 992px) {
    .filter-inputs {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .left-filters {
        flex-wrap: wrap;
        width: 100%;
        gap: 10px;
    }

    .range-picker-wrapper,
    .premium-select,
    .btn-apply,
    .btn-clear {
        flex: 1 1 calc(50% - 10px);
        min-width: 150px;
    }

    .export-actions {
        margin-left: 0;
        width: 100%;
    }

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

    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .availability-split {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .manual-booking-content {
        width: 95%;
        margin: 10px auto;
        padding: 20px;
        border-radius: 15px;
    }
}

@media (max-width: 768px) {
    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .section-title {
        font-size: 1.4rem;
    }

    .admin-header {
        padding: 15px;
    }

    .main-content {
        padding: 15px;
    }

    .left-filters .range-picker-wrapper,
    .left-filters .premium-select,
    .left-filters .btn-apply,
    .left-filters .btn-clear {
        flex: 1 1 100%;
    }

    .booking-card {
        min-height: 120px;
        padding: 15px;
    }

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

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

    .manual-booking-modal .flatpickr-calendar {
        width: 100% !important;
        min-width: unset !important;
    }

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

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

    .search-input-wrapper {
        max-width: 100%;
    }
}

/* Login Page Styles */
.login-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: url('../images/login-bg.png') no-repeat center center/cover;
    position: relative;
}

.login-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(2px);
}

.login-card {
    background: rgba(255, 255, 255, 0.9);
    padding: 40px;
    margin: auto;
    border-radius: 20px;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
    width: 100%;
    max-width: 400px;
    text-align: center;
    position: relative;
    z-index: 10;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.login-title {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
}

.form-input {
    width: 90%;
    padding: 12px 16px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    font-family: 'Nunito', sans-serif;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
}
span.arrowDown, span.arrowUp {
    display: none;
}
.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(198, 108, 202, 0.1);
}


.btn-login {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 12px;
    width: 100%;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 10px;
}

.btn-login:hover {
    filter: brightness(0.95);
}

.error-msg {
    color: #FF5F6D;
    font-size: 14px;
    margin-top: 5px;
}

.decoration {
    position: absolute;
    z-index: 5;
    pointer-events: none;
    animation: float 6s ease-in-out infinite;
}

.flower-1 {
    top: 10%;
    left: 10%;
    width: 80px;
    opacity: 0.8;
    animation-delay: 0s;
}

.star-1 {
    bottom: 20%;
    right: 15%;
    width: 50px;
    opacity: 0.9;
    animation-delay: 2s;
}

.leaf-1 {
    bottom: 10%;
    left: 15%;
    width: 100px;
    opacity: 0.7;
    transform: rotate(45deg);
    animation-delay: 4s;
}

@keyframes float {
    0% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(5deg);
    }

    100% {
        transform: translateY(0px) rotate(0deg);
    }
}


/* Settings & Logs */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-main);
    font-weight: 700;
    font-size: 0.9rem;
}

.mt-30 {
    margin-top: 30px;
}

.badge-type {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-type.otp_request {
    background: #e3f2fd;
    color: #1976d2;
}

.badge-type.otp_verify {
    background: #f3e5f5;
    color: #7b1fa2;
}

.badge-type.booking_submit {
    background: #e8f5e9;
    color: #388e3c;
}

.badge-type.email_sent {
    background: #fffde7;
    color: #fbc02d;
}

.badge-type.error {
    background: #ffebee;
    color: #d32f2f;
}

.badge-level {
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: bold;
    text-transform: uppercase;
    border: 1px solid currentColor;
}

.badge-level.info {
    color: #2196f3;
}

.badge-level.warning {
    color: #ff9800;
}

.badge-level.error {
    color: #f44336;
}

.btn-view-details {
    background: none;
    border: 1px solid #ddd;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    color: #666;
    font-size: 12px;
}

.btn-view-details:hover {
    background: #f5f5f5;
    border-color: #ccc;
}

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

/* Confirmation Modal Styling */
.confirm-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.confirm-content {
    background: white;
    padding: 30px;
    border-radius: 20px;
    max-width: 350px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.3s ease;
}

.confirm-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.confirm-content h3 {
    margin: 0 0 25px;
    font-size: 1.2rem;
    color: var(--text-main);
    font-weight: 700;
}

.confirm-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.confirm-btn {
    padding: 10px 20px;
    border-radius: 12px;
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}

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

.confirm-btn.primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(204, 108, 230, 0.3);
}

.confirm-btn.secondary {
    background: #f6f9fc;
    color: var(--text-light);
}

.confirm-btn.secondary:hover {
    background: #eef2f7;
    color: var(--text-main);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

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


/* Added via script */
.status-upcoming,
.badge-upcoming {
    background: var(--upcoming-bg);
    color: var(--upcoming);
}

/* Pagination Styling */
.pagination-container {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.pagination-container.mini {
    margin-top: 15px;
    gap: 5px;
}

.pagination-container .page-link {
    padding: 8px 16px;
    border: 1px solid #e3e8ee;
    background: white;
    color: #525f7f;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.pagination-container.mini .page-link {
    padding: 5px 10px;
    font-size: 0.75rem;
}

.pagination-container .page-link:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: var(--primary-light);
}

.pagination-container .page-link.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.pagination-container .page-link:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #f6f9fc;
}

.page-dots {
    display: flex;
    align-items: center;
    padding: 0 5px;
    color: #8898aa;
}

/* Fix for Laravel default pagination conflicts */
.pagination-container nav {
    width: 100%;
    display: flex;
    justify-content: center;
}

.pagination-container .pagination {
    display: flex;
    gap: 5px;
    list-style: none;
    padding: 0;
}

.pagination-container .page-item .page-link {
    display: flex;
}

/* Premium Follow-up Picker Style (Global) */
.followup-date-picker {
    border: 1px solid rgba(204, 108, 230, 0.35);
    padding: 10px 14px 10px 36px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--primary-color);
    background: var(--primary-light) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23CC6CE6'%3E%3Cpath d='M19 4h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V10h14v10zM9 14H7v-2h2v2zm4 0h-2v-2h2v2zm4 0h-2v-2h2v2zm-8 4H7v-2h2v2zm4 0h-2v-2h2v2zm4 0h-2v-2h2v2z'/%3E%3C/svg%3E") no-repeat 12px center;
    background-size: 16px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 160px;
    text-align: left;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-sizing: border-box;
    box-shadow: 0 2px 5px rgba(204, 108, 230, 0.05);
}

.followup-date-picker:hover {
    background-color: var(--primary-color);
    color: white !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M19 4h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V10h14v10zM9 14H7v-2h2v2zm4 0h-2v-2h2v2zm4 0h-2v-2h2v2zm-8 4H7v-2h2v2zm4 0h-2v-2h2v2zm4 0h-2v-2h2v2z'/%3E%3C/svg%3E");
    border-color: var(--primary-color);
    box-shadow: 0 5px 15px rgba(204, 108, 230, 0.35);
    transform: translateY(-2px);
}

.followup-date-picker:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.flatpickr-input.followup-date-picker {
    border-style: dashed;
}

/* --- Mobile Optimization --- */
@media (max-width: 991px) {
    .admin-wrapper {
        flex-direction: column;
        padding: 0;
        height: 100vh;
        overflow: hidden;
    }

    .main-content {
        padding: 24px 16px;
        border-radius: 0;
        margin-top: 70px;
        /* Matches header bar height */
        overflow-y: auto;
        height: calc(100vh - 70px);
        width: 100%;
        margin-left: 0;
        background: var(--bg-body);
        /* Consistency */
    }

    /* Mobile Sidebar */
    .mobile-menu-toggle {
        display: flex !important;
        align-items: center;
        justify-content: center;
        position: fixed;
        top: 15px;
        left: 15px;
        z-index: 3000;
        width: 45px;
        height: 45px;
        background: white;
        border: none;
        border-radius: 12px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
        color: var(--primary-color);
        font-size: 1.4rem;
        cursor: pointer;
    }

    .sidebar {
        position: fixed;
        left: -100%;
        top: 0;
        bottom: 0;
        width: 280px;
        height: 100%;
        z-index: 2800;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border-radius: 0 20px 20px 0;
        box-shadow: none;
        background: white !important;
    }

    .sidebar.active {
        left: 0;
        box-shadow: 10px 0 50px rgba(0, 0, 0, 0.15);
    }

    /* Overlay for sidebar */
    .sidebar.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 280px;
        right: -100vw;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(4px);
        z-index: -1;
    }

    /* Sidebar Branding Refinement */
    .sidebar .brand-section {
        margin-bottom: 30px;
        text-align: center;
    }



    /* Dashboard Cards - Premium Refresh */
    .cards-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .booking-card {
        padding: 20px;
        min-height: 120px;
        border: 1px solid rgba(0, 0, 0, 0.05);
        display: flex;
        flex-direction: row;
        /* Horizontal layout looks better for single column */
        align-items: center;
        justify-content: space-between;
    }

    .booking-card .card-top {
        margin-bottom: 0;
        flex: 1;
    }

    .card-icon-box {
        width: 44px;
        height: 44px;
        font-size: 1.1rem;
    }

    .stat-value {
        font-size: 1.8rem;
        margin-left: 15px;
    }

    .card-details h3 {
        font-size: 0.95rem;
    }

    .card-details p {
        font-size: 0.75rem;
    }

    /* Tables */
    .bookings-table-wrapper,
    .premium-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -15px;
        padding: 0 15px;
        border-radius: 0;
        border-left: none;
        border-right: none;
        box-shadow: none;
        width: calc(100% + 30px);
    }

    .custom-table,
    .modern-table {
        min-width: 600px;
    }

    /* Ensure table content doesn't wrap awkwardly */
    .custom-table th,
    .custom-table td,
    .modern-table th,
    .modern-table td {
        white-space: nowrap;
    }

    /* Fix calendar bleeding through */
    .flatpickr-calendar {
        z-index: 2000 !important;
    }

    /* Modals */
    .manual-booking-modal,
    .confirm-modal,
    #noteModal,
    #logDetailsModal {
        padding: 0;
        align-items: flex-end;
        /* Bottom sheet style */
    }

    .manual-booking-content,
    .confirm-content,
    .modal-content {
        width: 100%;
        max-width: 100%;
        border-radius: 20px 20px 0 0;
        max-height: 90vh;
        overflow-y: auto;
        margin: 0;
        animation: slideUp 0.3s ease-out;
    }

    @keyframes slideUp {
        from {
            transform: translateY(100%);
        }

        to {
            transform: translateY(0);
        }
    }

    .availability-split {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    /* Calendar & Availability */
    .availability-grid-container {
        padding: 0;
    }

    .flatpickr-calendar.inline {
        width: 100% !important;
        max-width: unset !important;
    }

    .flatpickr-rContainer,
    .flatpickr-days {
        width: 100% !important;
    }

    .dayContainer {
        width: 100% !important;
        min-width: unset !important;
        max-width: unset !important;
        justify-content: space-around;
    }

    /* Filters */
    .calendar-controls-wrapper {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

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

    .header-actions {
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }

    .view-toggle-container {
        width: 100%;
        justify-content: space-between;
    }

    .view-tab {
        flex: 1;
        justify-content: center;
    }

    /* Appointment Filter Card Refinement */
    .table-filters-card .filter-inputs {
        flex-direction: column;
        gap: 15px;
    }

    .left-filters,
    .right-filters {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 10px;
        width: 100%;
    }

    .range-picker-wrapper {
        width: 100%;
    }

    .range-input {
        width: 100% !important;
    }

    .btn-apply,
    .btn-clear,
    .btn-search {
        width: 100%;
        justify-content: center;
    }

    /* Header Bar for Mobile */
    .admin-wrapper::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        height: 70px;
        background: white;
        z-index: 1100;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    }
}

/* Very small screens */
@media (max-width: 480px) {
    .cards-grid {
        grid-template-columns: 1fr;
    }

    .premium-btn {
        width: 100%;
    }

    .section-title {
        font-size: 1.4rem;
    }
}

/* Desktop cleanup */
@media (min-width: 992px) {
    .mobile-menu-toggle {
        display: none !important;
    }
}

/* --- Premium Notification Modal Styles --- */
.notification-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 9999;
    pointer-events: none;
    width: 100%;
    max-width: 450px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.notification-toast.premium-modal-notification {
    pointer-events: auto;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25), 0 0 40px rgba(204, 108, 230, 0.1);
    width: 100%;
    overflow: hidden;
    border: 1px solid rgba(204, 108, 230, 0.1);
    animation: modalPopIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

@keyframes modalPopIn {
    0% {
        opacity: 0;
        transform: scale(0.8) translateY(30px);
    }

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

.notif-header {
    padding: 20px 24px;
    background: #fdf8ff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f1e4f5;
}

.notif-badge {
    background: var(--primary-color);
    color: white;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 10px rgba(204, 108, 230, 0.2);
}

.notif-close-icon {
    color: #999;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1.1rem;
}

.notif-close-icon:hover {
    color: var(--primary-color);
    transform: rotate(90deg);
}

.notif-body {
    padding: 24px;
}

.notif-patient-card {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.notif-avatar {
    width: 54px;
    height: 54px;
    background: linear-gradient(135deg, var(--primary-color), #8e44ad);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    font-size: 1.5rem;
    font-weight: 800;
    box-shadow: 0 8px 16px rgba(204, 108, 230, 0.2);
}

.notif-patient-meta h4 {
    margin: 0;
    font-size: 1.2rem;
    color: var(--text-main);
    font-weight: 800;
}

.notif-patient-meta p {
    margin: 4px 0 0;
    font-size: 0.9rem;
    color: #777;
    font-weight: 600;
}

.notif-details-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 24px;
    background: #f8f9fc;
    padding: 15px;
    border-radius: 16px;
}

.notif-data-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.notif-data-item .label {
    font-size: 0.65rem;
    color: #999;
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.notif-data-item .value {
    font-size: 0.85rem;
    color: var(--text-main);
    font-weight: 700;
}

.notif-action-btn {
    width: 100%;
    padding: 14px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 800;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.notif-action-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(204, 108, 230, 0.3);
    background: var(--primary-hover);
}

.notif-timer-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background: var(--primary-color);
    width: 100%;
    animation: notifCountdown 60s linear forwards;
}

@keyframes notifCountdown {
    from {
        width: 100%;
    }

    to {
        width: 0%;
    }
}

.notification-toast.hide {
    animation: modalPopOut 0.4s ease-in forwards;
}

@keyframes modalPopOut {
    0% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }

    100% {
        opacity: 0;
        transform: scale(0.9) translateY(40px);
    }
}

/* Mobile responsive for notification modal */
@media (max-width: 500px) {
    .notification-container {
        width: 90%;
        max-width: unset;
    }
}