/* ==========================================================================
   Salon25 Back Office - Modern Design System (Ynex Inspired)
   ========================================================================== */

/* CSS Custom Properties (CSS Variables) */
:root {
    /* Primary Color Palette - Notion Neutral Theme */
    --primary-50: #f8fafc;
    --primary-100: #f1f5f9;
    --primary-200: #e2e8f0;
    --primary-300: #cbd5e1;
    --primary-400: #94a3b8;
    --primary-500: #2563eb;  /* Notion Blue */
    --primary-600: #1d4ed8;
    --primary-700: #1e40af;  /* Deep Blue */
    --primary-800: #1e3a8a;
    --primary-900: #1e293b;  /* Dark Slate */
    
    /* Secondary Color Palette - Neutral Grays */
    --secondary-50: #f8fafc;
    --secondary-100: #f1f5f9;
    --secondary-200: #e2e8f0;
    --secondary-300: #cbd5e1;
    --secondary-400: #94a3b8;
    --secondary-500: #64748b;  /* Neutral Gray */
    --secondary-600: #475569;
    --secondary-700: #334155;  /* Dark Gray */
    --secondary-800: #1e293b;
    --secondary-900: #0f172a;
    
    /* Accent Color Palette - Subtle Blue */
    --accent-50: #eff6ff;
    --accent-100: #dbeafe;
    --accent-200: #bfdbfe;
    --accent-300: #93c5fd;
    --accent-400: #60a5fa;
    --accent-500: #3b82f6;   /* Soft Blue */
    --accent-600: #2563eb;
    --accent-700: #1d4ed8;   /* Medium Blue */
    --accent-800: #1e40af;
    --accent-900: #1e3a8a;
    
    /* Neutral Color Palette - Ocean Grays */
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    /* Semantic Colors */
    --success-50: #f0fdf4;
    --success-500: #22c55e;
    --success-600: #16a34a;
    --warning-50: #fffbeb;
    --warning-500: #f59e0b;
    --warning-600: #d97706;
    --error-50: #fef2f2;
    --error-500: #ef4444;
    --error-600: #dc2626;
    --info-50: #eff6ff;
    --info-500: #3b82f6;
    --info-600: #2563eb;
    
    /* Background Colors */
    --bg-primary: #ffffff;
    --bg-secondary: var(--gray-50);
    --bg-tertiary: var(--gray-100);
    --bg-dark: var(--gray-900);
    --bg-sidebar: #ffffff;
    --bg-header: #ffffff;
    
    /* Text Colors */
    --text-primary: var(--gray-900);
    --text-secondary: var(--gray-600);
    --text-tertiary: var(--gray-500);
    --text-inverse: #ffffff;
    
    /* Border Colors */
    --border-primary: var(--gray-200);
    --border-secondary: var(--gray-300);
    --border-focus: var(--primary-500);
    
    /* Shadow System */
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    /* Spacing Scale */
    --spacing-xs: 0.25rem;    /* 4px */
    --spacing-sm: 0.5rem;     /* 8px */
    --spacing-md: 1rem;       /* 16px */
    --spacing-lg: 1.5rem;     /* 24px */
    --spacing-xl: 2rem;       /* 32px */
    --spacing-2xl: 2.5rem;    /* 40px */
    --spacing-3xl: 3rem;      /* 48px */
    
    /* Border Radius */
    --radius-sm: 0.375rem;    /* 6px */
    --radius-md: 0.5rem;      /* 8px */
    --radius-lg: 0.75rem;     /* 12px */
    --radius-xl: 1rem;        /* 16px */
    --radius-2xl: 1.5rem;     /* 24px */
    
    /* Typography Scale */
    --font-size-xs: 0.75rem;     /* 12px */
    --font-size-sm: 0.875rem;    /* 14px */
    --font-size-base: 1rem;      /* 16px */
    --font-size-lg: 1.125rem;    /* 18px */
    --font-size-xl: 1.25rem;     /* 20px */
    --font-size-2xl: 1.5rem;     /* 24px */
    --font-size-3xl: 1.875rem;   /* 30px */
    --font-size-4xl: 2.25rem;    /* 36px */
    
    /* Font Weights */
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    
    /* Transitions */
    --transition-fast: 0.15s ease-in-out;
    --transition-base: 0.2s ease-in-out;
    --transition-slow: 0.3s ease-in-out;
    
    /* Layout Dimensions */
    --sidebar-width: 280px;
    --header-height: 70px;
    --content-padding: var(--spacing-lg);
}

/* ==========================================================================
   Global Styles
   ========================================================================== */

* {
    box-sizing: border-box;
}

html {
    height: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 
                 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-secondary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   Layout Components
   ========================================================================== */

.main-layout {
    min-height: 100vh;
    background: var(--bg-secondary);
}

/* App Bar Styling */
.app-bar {
    background: var(--bg-header) !important;
    border-bottom: 1px solid var(--border-primary);
    box-shadow: var(--shadow-sm);
    height: var(--header-height);
    z-index: 1100;
}

.app-bar .mud-appbar-content {
    padding: 0 var(--spacing-lg);
}

.menu-toggle {
    margin-right: var(--spacing-md);
    color: var(--text-secondary) !important;
}

.app-title-section {
    color: var(--primary-600);
}

.app-title {
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
}

/* Navigation Drawer */
.navigation-drawer {
    background: var(--bg-sidebar) !important;
    border-right: 1px solid var(--border-primary);
    box-shadow: var(--shadow-sm);
    width: var(--sidebar-width);
}

.drawer-header {
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--border-primary);
    background: linear-gradient(135deg, var(--primary-50) 0%, var(--secondary-50) 100%);
}

.brand-name {
    font-weight: var(--font-weight-bold);
    color: var(--primary-700);
}

/* Main Content */
.main-content {
    background: var(--bg-secondary);
    min-height: calc(100vh - var(--header-height));
}

.content-wrapper {
    padding: var(--content-padding);
    max-width: 100%;
    margin: 0 auto;
}

/* Footer */
.app-footer {
    background: var(--bg-primary);
    border-top: 1px solid var(--border-primary);
    padding: var(--spacing-lg) 0;
    margin-top: auto;
}

.footer-content {
    align-items: center;
}

.footer-links a {
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--primary-600) !important;
}

/* ==========================================================================
   Card Components
   ========================================================================== */

.modern-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
    overflow: hidden;
}

.modern-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.card-header {
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--border-primary);
    background: linear-gradient(135deg, var(--primary-50) 0%, var(--secondary-50) 100%);
}

.card-title {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    margin: 0;
}

.card-content {
    padding: var(--spacing-lg);
}

/* ==========================================================================
   Stat Cards (Dashboard Style)
   ========================================================================== */

.stat-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-500), var(--secondary-500));
}

.stat-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.stat-value {
    font-size: var(--font-size-3xl);
    font-weight: var(--font-weight-bold);
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-label {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: var(--spacing-xs);
}

.stat-change {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-sm);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
}

.stat-change.positive {
    color: var(--success-600);
}

.stat-change.negative {
    color: var(--error-600);
}

/* ==========================================================================
   Appointment/Diary Styling (Modernized)
   ========================================================================== */

.appointment-blocked {
    background: linear-gradient(135deg, var(--gray-100), var(--gray-200)) !important;
    color: var(--text-secondary) !important;
    border-left: 4px solid var(--gray-400) !important;
    font-style: italic;
}

.appointment-cut {
    background: linear-gradient(135deg, var(--error-50), var(--error-100)) !important;
    color: var(--error-600) !important;
    border-left: 4px solid var(--error-500) !important;
}

.appointment-color {
    background: linear-gradient(135deg, var(--warning-50), var(--warning-100)) !important;
    color: var(--warning-600) !important;
    border-left: 4px solid var(--warning-500) !important;
}

.appointment-extra {
    background: linear-gradient(135deg, var(--success-50), var(--success-100)) !important;
    color: var(--success-600) !important;
    border-left: 4px solid var(--success-500) !important;
}

.appointment-brush {
    background: linear-gradient(135deg, var(--info-50), var(--info-100)) !important;
    color: var(--info-600) !important;
    border-left: 4px solid var(--info-500) !important;
}

.appointment-default {
    background: linear-gradient(135deg, var(--primary-50), var(--primary-100)) !important;
    color: var(--primary-600) !important;
    border-left: 4px solid var(--primary-500) !important;
}

.slot-blocked {
    background: var(--gray-100) !important;
    color: var(--text-secondary) !important;
    font-style: italic;
    border-radius: var(--radius-sm);
}

/* Time slot styling */
.time-slot {
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    padding: var(--spacing-sm);
    margin: 2px 0;
    min-height: 40px;
    display: flex;
    align-items: center;
    transition: all var(--transition-base);
    background: var(--bg-primary);
}

.time-slot:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
    border-color: var(--primary-300);
}

/* Diary Grid System */
.diary-container {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.diary-header {
    background: linear-gradient(135deg, var(--primary-500), var(--secondary-500));
    color: var(--text-inverse);
    padding: var(--spacing-lg);
    text-align: center;
}

.diary-controls {
    background: var(--bg-tertiary);
    padding: var(--spacing-md);
    border-bottom: 1px solid var(--border-primary);
}

/* Team Member Diary Styles - Notion Calendar Style */
.team-member-diary {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.team-diary-card {
    height: 100%;
    min-height: 70vh; /* Ensure minimum height to stretch full column */
    border-radius: 6px;
    border: 1px solid #e5e5e5;
    transition: all 0.1s ease;
    background: #ffffff;
    box-shadow: none;
    display: flex;
    flex-direction: column;
}

.team-diary-card:hover {
    border-color: #d1d1d1;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.team-diary-header {
    padding: 12px 16px;
    border-bottom: 1px solid #e5e5e5;
    background: #fafafa;
    border-radius: 6px 6px 0 0;
    flex-shrink: 0;
}

.team-member-name {
    font-weight: 500;
    color: #2c2c2c;
    font-size: 14px;
    line-height: 1.4;
}

/* Diary page specific styles for full height alignment */
.team-diaries {
    min-height: 70vh; /* Ensure minimum height for the grid */
    overflow: hidden; /* Prevent content overflow */
    width: 100%; /* Ensure full width */
}

.full-width-grid {
    width: 100% !important;
    margin: 0 !important;
}

.full-width-item {
    padding: 0 4px !important; /* Minimal padding for tight layout */
}

.team-diaries .mud-item {
    display: flex;
    align-items: stretch; /* Make all items same height */
    min-height: 70vh; /* Ensure all columns stretch to full height */
    padding: 0 4px; /* Minimal horizontal padding */
    margin-bottom: 16px; /* Add bottom margin for small screens */
}

.team-diary-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    overflow: hidden; /* Prevent content overflow */
}

/* Responsive adjustments to prevent overlap */
@media (max-width: 768px) {
    .team-diaries .mud-item {
        min-height: auto; /* Allow natural height on mobile */
        margin-bottom: 24px; /* More spacing on mobile */
    }
    
    .team-diary-card {
        min-height: auto; /* Allow natural height on mobile */
    }
}

@media (min-width: 769px) and (max-width: 1200px) {
    .team-diaries .mud-item {
        padding: 0 12px; /* More padding on tablet sizes */
    }
}

/* ==========================================================================
   Button System
   ========================================================================== */

.btn-primary {
    background: linear-gradient(135deg, var(--primary-600), var(--primary-700)) !important;
    border: none !important;
    color: var(--text-inverse) !important;
    border-radius: var(--radius-md) !important;
    font-weight: var(--font-weight-medium) !important;
    padding: var(--spacing-sm) var(--spacing-lg) !important;
    transition: all var(--transition-base) !important;
    box-shadow: var(--shadow-sm) !important;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-700), var(--primary-800)) !important;
    box-shadow: var(--shadow-md) !important;
    transform: translateY(-1px) !important;
}

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary-600), var(--secondary-700)) !important;
    border: none !important;
    color: var(--text-inverse) !important;
    border-radius: var(--radius-md) !important;
    font-weight: var(--font-weight-medium) !important;
    padding: var(--spacing-sm) var(--spacing-lg) !important;
    transition: all var(--transition-base) !important;
    box-shadow: var(--shadow-sm) !important;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, var(--secondary-700), var(--secondary-800)) !important;
    box-shadow: var(--shadow-md) !important;
    transform: translateY(-1px) !important;
}

/* ==========================================================================
   Form Controls
   ========================================================================== */

.form-control:focus {
    border-color: var(--border-focus) !important;
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.25) !important;
}

.form-select:focus {
    border-color: var(--border-focus) !important;
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.25) !important;
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */

.gradient-bg {
    background: linear-gradient(135deg, var(--primary-500), var(--secondary-500));
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary-600), var(--secondary-600));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.glass-effect {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

/* ==========================================================================
   Navigation Menu Styling
   ========================================================================== */

.mud-nav-menu {
    padding: var(--spacing-md);
}

.mud-nav-item {
    margin-bottom: var(--spacing-xs);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.mud-nav-item:hover {
    background: var(--primary-50);
}

.mud-nav-item.mud-nav-item-active {
    background: linear-gradient(135deg, var(--primary-500), var(--secondary-500));
    color: var(--text-inverse);
}

.mud-nav-link {
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    font-weight: var(--font-weight-medium);
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    .content-wrapper {
        padding: var(--spacing-md);
    }
    
    .stat-card {
        padding: var(--spacing-lg);
    }
    
    .stat-value {
        font-size: var(--font-size-2xl);
    }
    
    .footer-links {
        display: none !important;
    }
}

@media (max-width: 480px) {
    .app-title {
        font-size: var(--font-size-base);
    }
    
    .content-wrapper {
        padding: var(--spacing-sm);
    }
}

/* ==========================================================================
   Dark Mode Support (Future Enhancement)
   ========================================================================== */

@media (prefers-color-scheme: dark) {
    :root {
        --bg-primary: var(--gray-900);
        --bg-secondary: var(--gray-800);
        --bg-tertiary: var(--gray-700);
        --bg-sidebar: var(--gray-900);
        --bg-header: var(--gray-900);
        --text-primary: var(--gray-100);
        --text-secondary: var(--gray-300);
        --text-tertiary: var(--gray-400);
        --border-primary: var(--gray-700);
        --border-secondary: var(--gray-600);
    }
}

/* ==========================================================================
   Animation Keyframes
   ========================================================================== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.5s ease-out;
}

.animate-slide-in-right {
    animation: slideInRight 0.3s ease-out;
}

/* ==========================================================================
   Blazor/MudBlazor Specific Overrides
   ========================================================================== */

.mud-paper {
    box-shadow: var(--shadow-sm) !important;
    border-radius: var(--radius-lg) !important;
}

.mud-card {
    box-shadow: var(--shadow-sm) !important;
    border-radius: var(--radius-lg) !important;
    border: 1px solid var(--border-primary) !important;
}

.mud-card:hover {
    box-shadow: var(--shadow-lg) !important;
    transform: translateY(-2px);
}

.mud-button-filled-primary {
    background: linear-gradient(135deg, var(--primary-600), var(--primary-700)) !important;
    box-shadow: var(--shadow-sm) !important;
}

.mud-button-filled-primary:hover {
    background: linear-gradient(135deg, var(--primary-700), var(--primary-800)) !important;
    box-shadow: var(--shadow-md) !important;
    transform: translateY(-1px);
}

.mud-button-filled-secondary {
    background: linear-gradient(135deg, var(--secondary-600), var(--secondary-700)) !important;
    box-shadow: var(--shadow-sm) !important;
}

.mud-button-filled-secondary:hover {
    background: linear-gradient(135deg, var(--secondary-700), var(--secondary-800)) !important;
    box-shadow: var(--shadow-md) !important;
    transform: translateY(-1px);
}

/* ==========================================================================
   Team Member Diary Booking Styles & Grid Separators
   ========================================================================== */

/* Time slots grid layout with separators */
.time-slots-container {
    padding: 16px;
    flex: 1; /* Take remaining space in the card */
    display: flex;
    flex-direction: column;
    min-height: 0; /* Allow flex to work properly */
}

.time-slots-grid {
    gap: 0 !important;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    overflow: hidden;
    flex: 1; /* Fill remaining space */
    min-height: 500px; /* Minimum height for content */
}

/* Ensure MudGrid rows have consistent heights */
.time-slots-grid .mud-grid-item {
    display: flex !important;
    align-items: stretch !important;
}

/* Make sure time slot pairs stay together */
.time-slots-grid .mud-item {
    display: flex !important;
    flex-direction: column !important;
}

.time-slot-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 32px; /* Notion-like height */
    padding: 0 12px; /* Clean horizontal padding */
    border-right: 1px solid #e5e5e5;
    border-bottom: 1px solid #e5e5e5;
    background: #fafafa;
    position: relative;
    flex-shrink: 0;
    font-size: 12px;
    color: #6b6b6b;
    font-weight: 400;
}

.time-slot-cell:last-of-type {
    border-bottom: none;
}

.time-slot-cell.working-slot {
    background: #ffffff;
    border-right: 1px solid #e5e5e5;
}

.time-slot-cell.non-working-slot {
    background: #f6f6f6;
    color: #9b9b9b;
    opacity: 0.8;
}

.booking-cell {
    display: flex;
    align-items: center;
.booking-cell {
    display: flex;
    align-items: center;
    height: 32px; /* Matching height */
    padding: 0 8px; /* Compact horizontal padding */
    flex-shrink: 0;
    overflow: hidden;
    border-bottom: 1px solid #e5e5e5;
    background: #ffffff;
    position: relative;
}

.booking-cell:last-of-type {
    border-bottom: none;
}

.booking-cell.working-slot {
    background: #ffffff;
}

.booking-cell.non-working-slot {
    background: #f6f6f6;
    opacity: 0.8;
}

/* Booking items - Notion style */
.bookings-container {
    width: 100%;
    height: 100%;
    max-height: 32px; /* Enforce same height as parent cell */
    display: flex;
    flex-direction: row; /* Change to horizontal layout */
    gap: 2px; /* Small gap between bookings */
    justify-content: flex-start; /* Start from left */
    align-items: center; /* Center vertically */
    overflow-x: auto; /* Allow horizontal scrolling for multiple bookings */
    overflow-y: hidden;
    padding: 0 2px; /* Small horizontal padding */
}

/* Custom scrollbar for booking container - horizontal */
.bookings-container::-webkit-scrollbar {
    height: 4px; /* Height for horizontal scrollbar */
    width: 4px; /* Keep width for potential vertical scrollbar */
}

.bookings-container::-webkit-scrollbar-track {
    background: transparent;
}

.bookings-container::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 2px;
}

.bookings-container::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

.booking-item {
    padding: 4px 24px 4px 8px; /* Padding with space for delete button */
    border-radius: 2px;
    transition: all 0.1s ease;
    cursor: pointer;
    border: none;
    background: #f6f6f6; /* Default light background */
    border-left: 3px solid #e5e5e5; /* Default subtle border */
    flex-shrink: 0; /* Don't shrink */
    min-height: 24px; /* Increased height for better readability */
    max-height: 24px;
    height: 24px; /* Fixed height for consistency */
    display: flex;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    font-size: 11px; /* Font size */
    color: #2c2c2c;
    margin-right: 2px; /* Small margin between horizontal items */
    min-width: 120px; /* Minimum width to ensure readable text */
    white-space: nowrap; /* Prevent text wrapping */
}

.booking-item:last-child {
    margin-right: 0; /* Remove margin from last item */
}

/* Override the background and border when color is applied via style attribute */
.booking-item[style*="background"] {
    color: rgba(255, 255, 255, 0.95) !important;
}

.booking-item:hover {
    filter: brightness(0.95);
    transform: none;
}

.booking-content {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.booking-description {
    font-weight: 500;
    color: #2c2c2c;
    font-size: 11px; /* Match the booking item font size */
    line-height: 1.2; /* Tighter line height */
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* When booking has colored background, make text white */
.booking-item[style*="background"] .booking-description {
    color: rgba(255, 255, 255, 0.95) !important;
}
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.time-text {
    font-size: 11px;
    font-weight: 500;
    color: var(--gray-600);
}

.delete-btn {
    opacity: 0;
    transition: opacity 0.2s ease;
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    background-color: transparent !important;
    color: #dc2626 !important; /* Red color for X */
    border: none !important;
    border-radius: 50% !important; /* Make it circular */
    width: 20px !important;
    height: 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer;
    z-index: 10;
    font-size: 16px !important;
    font-weight: bold;
    min-width: 20px !important; /* Override MudBlazor min-width */
    padding: 0 !important; /* Remove any padding */
}

.delete-btn:hover {
    background-color: rgba(220, 38, 38, 0.1) !important; /* Light red background on hover */
    color: #dc2626 !important;
}

/* Hide the MudIconButton content and replace with X */
.delete-btn .mud-button-label,
.delete-btn .mud-icon-button-label,
.delete-btn svg,
.delete-btn .mud-icon-root {
    display: none !important; /* Hide MudBlazor icon */
}

/* Create X icon using CSS */
.delete-btn::before {
    content: "×"; /* Unicode multiplication sign that looks like X */
    font-size: 18px !important;
    font-weight: bold;
    line-height: 1;
    color: #dc2626;
}

.booking-item:hover .delete-btn {
    opacity: 1;
}

/* Empty slot styling - Notion clean style */
.empty-slot {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 0;
    cursor: pointer;
    transition: background-color 0.1s ease;
    background: transparent;
}

.empty-slot:hover {
    background-color: #f6f6f6;
}

.available-text {
    font-size: 12px;
    color: #9b9b9b;
    font-weight: 400;
}

/* No schedule state */
.no-schedule {
    padding: var(--spacing-2xl);
    text-align: center;
    color: var(--text-secondary);
}

/* Grid row separators - enhance the agenda look */
.time-slots-grid .mud-item:nth-child(2n) {
    border-right: none; /* Remove right border from booking cells */
}

/* Add subtle hover effect for entire time slot row */
.time-slots-grid .mud-item:nth-child(2n-1):hover + .mud-item,
.time-slots-grid .mud-item:nth-child(2n-1):hover {
    background-color: var(--primary-50);
}

/* ==========================================================================
   End of Stylesheet
   ========================================================================== */
