/* Enhanced Travel CRM Custom Styles */

:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --success-color: #10d876;
    --warning-color: #ffb946;
    --danger-color: #ff4757;
    --info-color: #3742fa;
    --light-color: #f1f2f6;
    --dark-color: #2f3542;
    --sidebar-width: 280px;
    --header-height: 70px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    color: var(--dark-color);
    line-height: 1.6;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: var(--sidebar-width);
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    z-index: 1000;
    transition: all 0.3s ease;
    overflow-y: auto;
    /* Force visibility for debugging */
    display: block !important;
    visibility: visible !important;
}

.sidebar-brand {
    padding: 1.5rem;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
}

.sidebar-brand h4 {
    margin: 0.5rem 0;
    font-weight: 600;
    font-size: 1.2rem;
}

.sidebar-brand i {
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.sidebar-brand small {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8rem;
}

.sidebar-nav {
    padding: 1rem 0;
}

.nav-item {
    margin: 0.25rem 0;
}

.nav-link {
    color: rgba(255, 255, 255, 0.8);
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: all 0.3s ease;
    border-radius: 0;
    font-size: 0.95rem;
    font-weight: 500;
}

.nav-link:hover,
.nav-link.active {
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
    transform: translateX(5px);
    text-decoration: none;
}

.nav-link i {
    margin-right: 0.75rem;
    width: 20px;
    text-align: center;
    font-size: 1rem;
}

/* Dropdown menu styling */
.nav-item .collapse {
    background: rgba(0, 0, 0, 0.1);
    margin-top: 0.25rem;
}

.nav-item .collapse .nav-link {
    padding: 0.5rem 1rem 0.5rem 3rem;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.nav-item .collapse .nav-link:hover {
    color: white;
    background-color: rgba(255, 255, 255, 0.1);
}

/* Main Content */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

.top-header {
    background: white;
    height: var(--header-height);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    position: sticky;
    top: 0;
    z-index: 999;
}

.content-area {
    padding: 2rem;
}

/* Dashboard Cards */
.stats-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e9ecef;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
}

.stats-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.stats-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.stats-card .icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.stats-card .value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.stats-card .label {
    font-size: 0.9rem;
    color: #6c757d;
    font-weight: 500;
}

/* Service Selection Cards */
.service-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.service-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.5s;
    opacity: 0;
}

.service-card:hover::before {
    animation: shine 0.5s ease-in-out;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); opacity: 0; }
    50% { opacity: 1; }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); opacity: 0; }
}

.service-card .service-icon {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin: 0 auto 1.5rem;
    color: white;
}

.service-card.flight .service-icon { background: linear-gradient(135deg, #667eea, #764ba2); }
.service-card.hotel .service-icon { background: linear-gradient(135deg, #f093fb, #f5576c); }
.service-card.cruise .service-icon { background: linear-gradient(135deg, #4facfe, #00f2fe); }
.service-card.train .service-icon { background: linear-gradient(135deg, #43e97b, #38f9d7); }
.service-card.car_rental .service-icon { background: linear-gradient(135deg, #fa709a, #fee140); }

.service-card h4 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.service-card p {
    color: #6c757d;
    font-size: 0.9rem;
}

/* Forms */
.form-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e9ecef;
}

.form-section {
    border-left: 4px solid var(--primary-color);
    padding-left: 1rem;
    margin-bottom: 2rem;
}

.form-section h5 {
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Passenger Management */
.passenger-card {
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    position: relative;
    transition: all 0.3s ease;
}

.passenger-card.filled {
    background: white;
    border: 2px solid var(--success-color);
    box-shadow: 0 2px 8px rgba(16, 216, 118, 0.1);
}

.passenger-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--danger-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.passenger-remove:hover {
    background: #ff3838;
    transform: scale(1.1);
}

/* Lead Score Badge */
.lead-score {
    position: relative;
    display: inline-block;
}

.lead-score .score-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.lead-score.high .score-circle { background: var(--success-color); }
.lead-score.medium .score-circle { background: var(--warning-color); }
.lead-score.low .score-circle { background: var(--danger-color); }

/* Data Tables */
.table-enhanced {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.table-enhanced thead th {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    padding: 1rem;
}

.table-enhanced tbody tr {
    transition: all 0.2s ease;
}

.table-enhanced tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05);
    transform: scale(1.001);
}

/* Status Badges */
.status-badge {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Buttons */
.btn-enhanced {
    border-radius: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-enhanced:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.btn-enhanced::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-enhanced:active::before {
    width: 300px;
    height: 300px;
}

/* Loading States */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Animations */
.fade-in {
    animation: fadeIn 0.6s ease-out;
}

.slide-in-right {
    animation: slideInRight 0.6s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.show {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .content-area {
        padding: 1rem;
    }
    
    .stats-card,
    .service-card {
        margin-bottom: 1rem;
    }
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.shadow-enhanced {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.border-radius-lg {
    border-radius: 12px;
}

.border-radius-xl {
    border-radius: 20px;
}

/* Welcome Card Styles - High Priority */
.welcome-card {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #ec4899 100%) !important;
    box-shadow: 0 15px 35px rgba(79, 70, 229, 0.4) !important;
    border: none !important;
    position: relative !important;
    overflow: hidden !important;
    min-height: 120px !important;
}

.welcome-card h2 {
    color: #ffffff !important;
    font-weight: 700 !important;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8) !important;
    font-size: 1.75rem !important;
    z-index: 10 !important;
    position: relative !important;
}

.welcome-card p {
    color: #e2e8f0 !important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6) !important;
    font-size: 1rem !important;
    font-weight: 400 !important;
    z-index: 10 !important;
    position: relative !important;
}

/* Override any conflicting Bootstrap or other styles */
.content-area .welcome-card h2,
.content-area .welcome-card h2.text-white,
.content-area .welcome-card h2.mb-2 {
    color: #ffffff !important;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8) !important;
}

.content-area .welcome-card p,
.content-area .welcome-card p.text-white-50,
.content-area .welcome-card p.mb-0 {
    color: #e2e8f0 !important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6) !important;
}
