/* StoreMyCar.com Custom Styles */

:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --dark-bg: #1a1a2e;
    --card-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    --card-shadow-hover: 0 8px 25px rgba(0, 0, 0, 0.12);
    --transition: all 0.2s ease;
}

/* General */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #2d3748;
}

main {
    flex: 1;
}

/* Navigation */
.navbar {
    padding: 0.75rem 0;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: -0.5px;
}

.navbar-dark .nav-link {
    color: rgba(255, 255, 255, 0.8);
    padding: 0.5rem 0.85rem;
    border-radius: 6px;
    transition: var(--transition);
    font-size: 0.9rem;
}

.navbar-dark .nav-link:hover,
.navbar-dark .nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.navbar .dropdown-menu {
    border: none;
    box-shadow: var(--card-shadow-hover);
    border-radius: 10px;
    padding: 0.5rem;
}

.navbar .dropdown-item {
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
}

.navbar .dropdown-item:hover {
    background: #f1f5f9;
}

/* Footer */
.footer-dark {
    background: var(--dark-bg);
    color: #a0aec0;
}

.footer-dark a:hover {
    color: #fff !important;
}

.footer-dark h5,
.footer-dark h6 {
    font-weight: 600;
}

/* Forms */
.form-control,
.form-select {
    border-radius: 8px;
    padding: 0.6rem 0.85rem;
    border-color: #e2e8f0;
}

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

.form-label {
    font-weight: 500;
    font-size: 0.875rem;
    color: #4a5568;
    margin-bottom: 0.35rem;
}

/* Buttons */
.btn {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.55rem 1.25rem;
    transition: var(--transition);
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

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

.btn-outline-primary:hover {
    transform: translateY(-1px);
}

/* Cards */
.card {
    border: 1px solid #e8edf3;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
}

.card-header {
    background: #f8fafc;
    border-bottom: 1px solid #e8edf3;
    border-radius: 12px 12px 0 0 !important;
    padding: 1rem 1.25rem;
}

/* Alerts */
.alert {
    border-radius: 10px;
    border: none;
}

.alert-danger {
    background: #fef2f2;
    color: #dc2626;
}

.alert-success {
    background: #f0fdf4;
    color: #16a34a;
}

.alert ul {
    margin: 0;
    padding-left: 1rem;
}

/* Badges */
.badge {
    font-weight: 500;
    padding: 0.4em 0.7em;
    border-radius: 6px;
    font-size: 0.75em;
}

/* Hero Section (Index) */
.hero-section {
    background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%);
    color: white;
    padding: 5rem 0;
}

/* Marketplace: Listing Cards */
.listing-card {
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}

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

.listing-card .card-img-top {
    transition: transform 0.3s ease;
}

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

.listing-card .card-body {
    padding: 1rem;
}

.listing-card .stretched-link {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

/* Star ratings */
.star-icon {
    color: #f59e0b;
    font-style: normal;
}

.star-rating {
    font-size: 1.1em;
    letter-spacing: 1px;
}

.star-rating .text-warning {
    color: #f59e0b !important;
}

/* Booking card */
.booking-card {
    border-radius: 12px;
    transition: var(--transition);
}

.booking-card:hover {
    box-shadow: var(--card-shadow-hover);
    border-color: #cbd5e1;
}

/* Sticky sidebar cards */
.sticky-top.card {
    border-radius: 12px;
}

/* Price display */
.fs-3.fw-bold.text-primary {
    color: var(--primary-color) !important;
}

/* Search page */
#search-map {
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

/* Listing detail carousel */
.carousel-inner {
    border-radius: 12px;
    overflow: hidden;
}

/* Messages layout */
#messages-container {
    scroll-behavior: smooth;
    background: #f8fafc;
}

#messages-container .bg-primary {
    border-radius: 16px 16px 4px 16px;
}

#messages-container .bg-light {
    border-radius: 16px 16px 16px 4px;
    background: #e8edf3 !important;
}

/* Host dashboard stats */
.card.text-center h4 {
    font-size: 1.75rem;
    font-weight: 700;
}

/* Profile page */
.rounded-circle {
    border: 3px solid #e2e8f0;
}

/* Feature checks on listing detail */
.text-success {
    font-weight: bold;
}

/* Pricing card */
.pricing-card {
    border-radius: 12px;
    transition: var(--transition);
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--card-shadow-hover);
}

.pricing-card.featured {
    border: 2px solid var(--primary-color);
}

/* Payment form */
#card-element {
    border: 1px solid #e2e8f0;
    padding: 0.75rem;
    border-radius: 8px;
}

/* Loading spinner */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

/* Utility classes */
.hidden {
    display: none !important;
}

/* Tab navigation */
.nav-tabs {
    border-color: #e2e8f0;
}

.nav-tabs .nav-link {
    color: #64748b;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 0.75rem 1.25rem;
    font-weight: 500;
}

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

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

/* Page headings */
h3 {
    font-weight: 700;
    color: #1a202c;
}

h4 {
    font-weight: 600;
    color: #2d3748;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

h5.card-title {
    font-weight: 600;
    color: #2d3748;
}

/* Dropdown menu scrollable */
.dropdown-menu {
    max-height: 300px;
    overflow-y: auto;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Navbar badge for unread messages */
.nav-badge {
    position: relative;
}

.nav-badge .badge {
    position: absolute;
    top: 0;
    right: -5px;
    font-size: 0.65em;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .display-3 {
        font-size: 2.25rem;
    }

    .display-4 {
        font-size: 2rem;
    }

    .booking-card .row {
        gap: 0.5rem;
    }

    .booking-card .col-md-1 {
        text-align: start !important;
    }

    .navbar-brand {
        font-size: 1.1rem;
    }

    .footer-dark .row {
        text-align: center;
    }

    .footer-dark .col-6 {
        text-align: left;
    }
}

@media (max-width: 576px) {
    .card {
        border-radius: 10px;
    }

    .btn-lg {
        font-size: 0.9rem;
        padding: 0.65rem 1.25rem;
    }
}
