/* ============================================
   CarRentalPro — Soft UI / Premium SaaS
   Design System for CarRentalPro PHP Platform
   ============================================ */

:root {
    /* Core Palette */
    --primary: #2563EB;
    --primary-hover: #1d4ed8;
    --secondary: #7C3AED;
    --accent: #10B981;
    --background: #F8FAFC;
    --surface: #FFFFFF;
    --text-primary: #0F172A;
    --text-secondary: #64748B;
    --text-muted: #94A3B8;
    --border: #E2E8F0;
    --border-light: #F1F5F9;
    --error: #EF4444;
    --success: #10B981;
    --warning: #F59E0B;
    --info: #3B82F6;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);

    /* Transitions */
    --transition-fast: all 0.2s ease-in-out;
    --transition-medium: all 0.3s ease-in-out;
    --transition-premium: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============================================
   Global Base
   ============================================ */
* { box-sizing: border-box; }

body {
    background: var(--background);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    margin: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a { text-decoration: none; color: inherit; }

::selection {
    background: rgba(37, 99, 235, 0.1);
    color: var(--text-primary);
}

/* Hide Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }

/* ============================================
   Layout
   ============================================ */
.content-area {
    padding-top: 20px;
}

.main-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ============================================
   Navbar — Clean Sticky Header
   ============================================ */
.navbar-wrapper {
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 100;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.navbar {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0 24px;
    box-shadow: none;
    min-width: unset;
    transition: none;
    display: flex;
    align-items: center;
    height: 72px;
}

.navbar:hover {
    padding: 0 24px;
    border-color: transparent;
    transform: none;
    box-shadow: none;
}

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

.navbar-brand .brand-accent {
    color: var(--primary);
    font-weight: 700;
}

.navbar-toggler-icon {
    filter: none;
}

.nav-link {
    font-weight: 600;
    font-size: 0.875rem;
    padding: 8px 16px !important;
    border-radius: 8px;
    color: var(--text-secondary) !important;
    transition: var(--transition-fast);
    position: relative;
}

.nav-link:hover {
    background: transparent;
    color: var(--primary) !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80%;
    height: 2px;
    background: var(--primary);
    transition: transform 0.2s ease;
    transform-origin: center;
}

.nav-link:hover::after {
    transform: translateX(-50%) scaleX(1);
}

/* ============================================
   Buttons
   ============================================ */
.btn-accent, .btn-primary {
    padding: 14px 28px;
    border-radius: 10px;
    text-transform: none;
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    background: var(--primary);
    border: none;
    box-shadow: var(--shadow-sm);
    color: white !important;
    transition: var(--transition-fast);
}

.btn-accent:hover, .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
    background: var(--primary-hover);
}

.btn-accent:active, .btn-primary:active {
    transform: scale(0.97);
}

.btn-outline-accent {
    border: 2px solid var(--primary) !important;
    color: var(--primary) !important;
    background: transparent !important;
    transition: var(--transition-fast);
    border-radius: 10px;
    font-weight: 700;
}

.btn-outline-accent:hover {
    background: var(--primary) !important;
    color: white !important;
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.btn-outline-theme {
    border: 2px solid var(--border) !important;
    color: var(--text-primary) !important;
    background: transparent !important;
    transition: var(--transition-fast);
    border-radius: 10px;
    font-weight: 700;
}

.btn-outline-theme:hover {
    background: var(--border-light) !important;
    color: var(--text-primary) !important;
    transform: translateY(-1px);
}

.btn-complete {
    background: rgba(16, 185, 129, 0.08);
    color: var(--success) !important;
    border: 1px solid rgba(16, 185, 129, 0.2) !important;
    transition: var(--transition-fast);
    font-weight: 700;
    border-radius: 9999px;
}

.btn-complete:hover {
    background: var(--success) !important;
    color: white !important;
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.magnetic-btn {
    display: inline-block;
    transition: var(--transition-fast);
}

/* ============================================
   Cards — Clean White Surfaces
   ============================================ */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    transition: var(--transition-fast);
    overflow: hidden;
}

.card:hover {
    border-color: #CBD5E1;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.card-img-wrapper {
    overflow: hidden;
    height: 240px;
    background: var(--border-light);
}

.card:hover .card-img-top {
    transform: scale(1.03);
}

.card-img-top {
    transition: var(--transition-medium);
}

.card-title, .card-body h4, .card-body h5 {
    color: var(--text-primary) !important;
    font-weight: 800;
    text-shadow: none;
}

.card-body p.text-muted {
    color: var(--text-secondary) !important;
    font-weight: 500;
}

/* Glass Panel → Clean White Panel */
.glass-panel {
    background: var(--surface);
    border: 1px solid var(--border);
    backdrop-filter: none;
    border-radius: 16px;
}

/* ============================================
   Typography & Text Utilities
   ============================================ */
.glow-text {
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: none;
    font-weight: 800;
}

.glow-text-subtle {
    color: var(--text-primary) !important;
    text-shadow: none;
}

.text-accent {
    color: var(--primary) !important;
}

.text-main {
    color: var(--text-primary) !important;
}

/* Remove cyber-brand glitch effects */
.cyber-brand {
    position: relative;
    color: var(--text-primary);
    font-size: 4rem;
    font-weight: 900;
    text-transform: none;
    letter-spacing: -0.04em;
    animation: none;
    line-height: 1;
}

.cyber-brand::before,
.cyber-brand::after {
    display: none;
}

/* ============================================
   Stat & Highlight Boxes
   ============================================ */
.car-stat-box, .highlight-box {
    background: var(--border-light) !important;
    border: 1px solid var(--border) !important;
    border-radius: 12px;
    padding: 14px 10px;
    text-align: center;
    transition: var(--transition-fast);
}

.car-stat-box:hover, .highlight-box:hover {
    border-color: #CBD5E1 !important;
    background: white !important;
}

.stat-label {
    color: var(--text-secondary) !important;
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: 6px;
}

.stat-value, .car-stat-box span {
    color: var(--text-primary) !important;
    font-size: 0.875rem;
    font-weight: 800;
}

.car-stat-box span {
    font-size: 0.65rem;
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 6px;
    font-weight: 800;
    color: var(--text-secondary) !important;
}

.car-stat-box i {
    font-size: 1rem;
    margin-bottom: 4px;
}

/* ============================================
   Pricing
   ============================================ */
.pricing-badge {
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.price-hr {
    color: var(--text-secondary) !important;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ============================================
   Forms — Clean Slate Inputs
   ============================================ */
.form-label.text-muted {
    color: var(--text-secondary) !important;
    opacity: 1;
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.form-control, .form-select, .input-group-text {
    background-color: #F8FAFC !important;
    border: 1px solid var(--border) !important;
    color: var(--text-primary) !important;
    padding: 12px 18px !important;
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.875rem;
    transition: var(--transition-fast);
}

.form-control:focus, .form-select:focus {
    background-color: white !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12) !important;
}

.form-control::placeholder {
    color: var(--text-muted) !important;
    font-weight: 400;
}

select.form-select option {
    background-color: white !important;
    color: var(--text-primary) !important;
}

.input-group .input-group-text {
    border-right: none !important;
    background-color: #F8FAFC !important;
}

.input-group .form-control {
    border-left: none !important;
}

/* ============================================
   Tables — Clean Light Zebra
   ============================================ */
.table {
    --bs-table-bg: transparent !important;
    --bs-table-color: var(--text-primary) !important;
    --bs-table-border-color: var(--border) !important;
    --bs-table-hover-bg: rgba(37, 99, 235, 0.03) !important;
    --bs-table-hover-color: var(--text-primary) !important;
    color: var(--text-primary) !important;
    background-color: transparent !important;
}

.table > :not(caption) > * > * {
    background-color: transparent !important;
    color: inherit !important;
    box-shadow: none !important;
}

.table thead th {
    border-bottom: 1px solid var(--border) !important;
    color: var(--text-secondary) !important;
    font-weight: 800 !important;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding: 1rem 1rem !important;
    font-size: 0.625rem;
    background: var(--border-light) !important;
}

.table tbody td {
    padding: 1rem 1rem !important;
    border-bottom: 1px solid var(--border-light) !important;
    color: var(--text-primary) !important;
    font-weight: 500;
}

.table tbody tr:hover {
    background: rgba(37, 99, 235, 0.02) !important;
}

.table .text-muted {
    color: var(--text-secondary) !important;
    opacity: 1;
}

.table .text-white {
    color: var(--text-primary) !important;
}

.card .table-responsive, .glass-panel .table-responsive {
    background: transparent !important;
}

/* ============================================
   Dropdown
   ============================================ */
.theme-dropdown {
    background: var(--surface) !important;
    backdrop-filter: blur(12px);
    border: 1px solid var(--border) !important;
    border-radius: 12px;
    box-shadow: var(--shadow-lg) !important;
}

.theme-dropdown .dropdown-item {
    color: var(--text-primary) !important;
    font-weight: 600;
    font-size: 0.8rem;
    border-radius: 8px;
    transition: var(--transition-fast);
}

.theme-dropdown .dropdown-item:hover {
    background: var(--border-light) !important;
    color: var(--primary) !important;
}

/* ============================================
   Badges
   ============================================ */
.badge {
    font-weight: 800;
    letter-spacing: 0.05em;
}

.bg-accent {
    background-color: var(--primary) !important;
}

/* ============================================
   Animations — CSS Only
   ============================================ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

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

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.fade-in {
    animation: fadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hover-lift {
    transition: var(--transition-fast);
    cursor: pointer;
}

.hover-lift:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

/* Mini-glitch → Clean hover */
.mini-glitch {
    transition: var(--transition-fast);
}

.navbar-brand:hover .mini-glitch {
    color: var(--primary);
    text-shadow: none;
    animation: none;
}

/* ============================================
   Hero Section
   ============================================ */
.hero-section {
    background: var(--surface);
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -15%;
    left: -15%;
    width: 60vw;
    height: 60vw;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.04);
    pointer-events: none;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -15%;
    right: -15%;
    width: 60vw;
    height: 60vw;
    border-radius: 50%;
    background: rgba(124, 58, 237, 0.04);
    pointer-events: none;
}

/* ============================================
   Pagination — Clean Light
   ============================================ */
.page-link {
    background: var(--surface) !important;
    border: 1px solid var(--border) !important;
    color: var(--text-secondary) !important;
    font-weight: 700;
    font-size: 0.8rem;
    border-radius: 8px !important;
    padding: 8px 14px;
    transition: var(--transition-fast);
}

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

.page-item.active .page-link {
    background: var(--primary) !important;
    border-color: var(--primary) !important;
    color: white !important;
}

.page-item.disabled .page-link {
    opacity: 0.4;
}

/* ============================================
   Alert Overrides
   ============================================ */
.alert-danger {
    background: rgba(239, 68, 68, 0.06);
    border: 1px solid rgba(239, 68, 68, 0.15);
    color: var(--error);
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.875rem;
}

/* ============================================
   Responsive — Mobile Adjustments
   ============================================ */
@media (max-width: 991.98px) {
    .navbar {
        height: 64px;
        padding: 0 16px;
    }

    .navbar:hover {
        padding: 0 16px;
    }

    .content-area {
        padding-top: 16px;
    }

    .cyber-brand {
        font-size: 2.5rem;
    }
}

@media (max-width: 767.98px) {
    .hero-content h1 {
        font-size: 2rem !important;
    }
}

/* ============================================
   CarRentalPro Footer
   ============================================ */
.crp-footer {
    background: #020617;
    color: white;
    padding-top: 6rem;
    padding-bottom: 3rem;
    overflow: hidden;
    position: relative;
}

.crp-footer a {
    color: inherit;
    text-decoration: none;
}

.crp-footer .footer-brand {
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    display: flex;
    align-items: center;
    gap: 12px;
}

.crp-footer .footer-brand .brand-icon {
    width: 40px;
    height: 40px;
    background: var(--primary);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.crp-footer .footer-heading {
    font-size: 0.625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--primary);
    margin-bottom: 2rem;
}

.crp-footer .footer-link {
    font-size: 0.875rem;
    font-weight: 600;
    color: #94A3B8;
    transition: color 0.2s;
    display: block;
    margin-bottom: 1rem;
}

.crp-footer .footer-link:hover {
    color: white;
}

.crp-footer .social-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #0F172A;
    border: 1px solid #1E293B;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #94A3B8;
    transition: var(--transition-fast);
    font-size: 1rem;
}

.crp-footer .social-icon:hover {
    color: white;
    background: var(--primary);
    border-color: var(--primary);
}

.crp-footer .scroll-top-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: #0F172A;
    border: 1px solid #1E293B;
    padding: 14px 22px;
    border-radius: 16px;
    color: #CBD5E1;
    cursor: pointer;
    transition: var(--transition-fast);
    font-size: 0.625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.crp-footer .scroll-top-btn:hover {
    background: #1E293B;
    color: white;
}

.crp-footer .scroll-top-btn .arrow-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.crp-footer .scroll-top-btn:hover .arrow-circle {
    background: var(--primary);
    color: white;
}

.crp-footer .footer-bottom {
    padding-top: 3rem;
    margin-top: 0;
    border-top: 1px solid #0F172A;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.crp-footer .footer-bottom-text {
    font-size: 0.625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: #475569;
}

.crp-footer .footer-bottom-links {
    display: flex;
    gap: 2rem;
}

.crp-footer .footer-bottom-links a {
    font-size: 0.625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #475569;
    transition: color 0.2s;
}

.crp-footer .footer-bottom-links a:hover {
    color: var(--primary);
}

.crp-footer .contact-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: #0F172A;
    border: 1px solid #1E293B;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #475569;
    transition: var(--transition-fast);
    font-size: 0.8rem;
    flex-shrink: 0;
}

.crp-footer .contact-row:hover .contact-icon {
    color: var(--primary);
    border-color: var(--primary);
}

.crp-footer .contact-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    transition: var(--transition-fast);
}

.crp-footer .contact-text {
    font-size: 0.75rem;
    font-weight: 700;
    color: #94A3B8;
    transition: color 0.2s;
}

.crp-footer .contact-row:hover .contact-text {
    color: white;
}

.crp-footer .live-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--accent);
}

.crp-footer .live-status .pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    animation: pulse-dot 2s infinite;
}

/* ============================================
   Stat Card (Dashboard)
   ============================================ */
.stat-card-crp {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    transition: var(--transition-fast);
}

.stat-card-crp:hover {
    box-shadow: var(--shadow-md);
    border-color: #CBD5E1;
}

/* ============================================
   Feature Card (Homepage)
   ============================================ */
.feature-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2.5rem 2rem;
    text-align: center;
    transition: var(--transition-fast);
}

.feature-card:hover {
    box-shadow: var(--shadow-md);
    border-color: #CBD5E1;
    transform: translateY(-2px);
}

.feature-card .feature-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    font-size: 1.5rem;
}

/* ============================================
   Auth Page Overrides
   ============================================ */
.auth-page-wrapper {
    background: var(--background);
}

.auth-page-wrapper .card {
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
}

.auth-page-wrapper .card:hover {
    transform: none;
}

/* ============================================
   Preview Card (Add Car Photo)
   ============================================ */
.preview-card {
    position: relative;
    cursor: pointer;
    transition: var(--transition-fast);
    border-radius: 12px;
    overflow: hidden;
}

.preview-card img {
    height: 140px;
    width: 100%;
    object-fit: cover;
    border: 3px solid transparent;
    border-radius: 12px;
}

.preview-card.selected img {
    border-color: var(--primary);
    transform: scale(1.02);
}

.primary-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    display: none;
    background: var(--primary) !important;
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 800;
}

.preview-card.selected .primary-badge {
    display: block;
    animation: fadeIn 0.3s ease;
}

.preview-radio {
    position: absolute;
    opacity: 0;
}

/* ============================================
   Trust Badge (Homepage)
   ============================================ */
.trust-badge {
    text-align: center;
}

.trust-badge .trust-number {
    font-size: 2rem;
    font-weight: 900;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 6px;
}

.trust-badge .trust-label {
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--text-secondary);
}

/* ============================================
   Pill Badge (Hero)
   ============================================ */
.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    font-size: 0.625rem;
    font-weight: 900;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--primary);
    background: rgba(37, 99, 235, 0.06);
    border: 1px solid rgba(37, 99, 235, 0.12);
    border-radius: 9999px;
    margin-bottom: 2rem;
}

.hero-pill .ping-dot {
    position: relative;
    width: 8px;
    height: 8px;
}

.hero-pill .ping-dot::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--primary);
    animation: pulse-dot 2s infinite;
}

.hero-pill .ping-dot::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--primary);
}
