/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    --bg-color: #0f0f13;
    --surface-color: #18181b;
    --surface-border: #27272a;
    --primary-color: #fbbf24;
    /* Gold/Amber */
    --primary-hover: #d97706;
    --text-primary: #f4f4f5;
    --text-secondary: #a1a1aa;
    --danger-color: #ef4444;
    --success-color: #22c55e;

    --glass-bg: rgba(24, 24, 27, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --blur: 12px;
}

/* Force Global White Text */
body,
h1,
h2,
h3,
h4,
h5,
h6,
p,
span,
div,
label,
.form-label,
.card-header,
th,
td,
.nav-link:not(.active) {
    color: #ffffff !important;
}

.text-muted {
    color: #d1d5db !important;
    /* Light gray instead of dark gray */
}

body {
    background-color: var(--bg-color);
    color: #ffffff;
    font-family: 'Outfit', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--text-primary);
    font-weight: 600;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.2s;
}

/* Navbar */
.navbar {
    background: var(--glass-bg) !important;
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    border-bottom: 1px solid var(--surface-border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--primary-color) !important;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Glassmorphism Cards */
.card {
    background: var(--surface-color);
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.card-header {
    background: transparent;
    border-bottom: 1px solid var(--surface-border);
    font-weight: 600;
    color: var(--text-primary);
    padding: 1.25rem;
}

/* Form Elements - Mobile Optimized */
.form-control,
.form-select {
    background-color: #27272a;
    border: 1px solid #3f3f46;
    color: #ffffff !important;
    /* Force white text */
    border-radius: 10px;
    padding: 0.8rem 1rem;
    font-size: 1rem;
    min-height: 48px;
    /* Mobile touch target */
}

.form-control::placeholder {
    color: #a1a1aa;
}

.form-control:focus,
.form-select:focus {
    background-color: #27272a;
    border-color: var(--primary-color);
    color: var(--text-primary);
    box-shadow: 0 0 0 2px rgba(251, 191, 36, 0.2);
}

.form-label {
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Buttons */
.btn {
    border-radius: 10px;
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    min-height: 48px;
    /* Mobile touch target */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #000;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    color: #000;
    transform: translateY(-1px);
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: #000;
}

/* Tabs */
.nav-tabs {
    border-bottom: 1px solid var(--surface-border);
}

.nav-tabs .nav-link {
    color: var(--text-secondary);
    border: none;
    border-bottom: 2px solid transparent;
    padding: 1rem 1.5rem;
}

.nav-tabs .nav-link.active {
    background: transparent;
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.nav-tabs .nav-link:hover {
    border-color: transparent;
    color: var(--text-primary);
}

/* Slot Grid */
.slot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: 12px;
}

.slot-btn {
    background: #27272a;
    border: 1px solid #3f3f46;
    border-radius: 10px;
    padding: 1rem 0.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}

.slot-btn:hover {
    border-color: var(--primary-color);
    background: #3f3f46;
}

.slot-btn.selected {
    background: var(--primary-color);
    color: #000;
    border-color: var(--primary-color);
    font-weight: 600;
}

/* Booked Slot Styling */
.slot-btn-booked {
    background: #dc2626 !important;
    border: 2px solid #ef4444 !important;
    color: #ffffff !important;
    border-radius: 10px;
    padding: 1rem 0.5rem;
    text-align: center;
    font-weight: 600;
    cursor: not-allowed;
    opacity: 0.9;
}

.slot-btn-booked:hover {
    opacity: 1;
}

/* Double-booked Slot (2 customers in same slot) */
.slot-btn-booked-full {
    background: rgba(14, 165, 233, 0.2) !important;
    border: 2px solid #0ea5e9 !important;
    color: #38bdf8 !important;
    border-radius: 10px;
    padding: 1rem 0.5rem;
    text-align: center;
    font-weight: 600;
    cursor: pointer;
    opacity: 0.9;
}

.slot-btn-booked-full:hover {
    opacity: 1;
}

/* Autocomplete Dropdown */
.autocomplete-dropdown {
    position: absolute;
    background: #27272a;
    border: 1px solid #3f3f46;
    border-radius: 10px;
    margin-top: 4px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    width: 100%;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
    display: none;
}

.autocomplete-item {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid #3f3f46;
    transition: background 0.2s;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.autocomplete-item:hover {
    background: #3f3f46;
}

.autocomplete-item .fw-bold {
    color: #ffffff;
    font-weight: 600;
}

.autocomplete-item .text-muted {
    color: #a1a1aa;
    font-size: 0.875rem;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .container {
        padding-left: 20px;
        padding-right: 20px;
    }

    .btn-lg {
        padding: 1rem;
        font-size: 1.1rem;
    }

    .slot-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 0.5rem;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    .card-body {
        padding: 1.25rem;
    }
    
    /* Larger touch targets for mobile */
    .btn-sm {
        min-height: 44px;
        padding: 0.5rem 1rem;
    }
    
    .slot-btn, .slot-btn-booked, .slot-btn-booked-full {
        min-height: 50px;
        font-size: 0.9rem;
    }
}