/* Map Styles */
#map, #mapModalMap {
    height: 400px;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.map-container {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.map-info {
    position: absolute;
    top: 10px;
    right: 10px;
    background: white;
    padding: 10px 15px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    max-width: 300px;
    z-index: 10;
}

.map-info h4 {
    margin: 0 0 5px 0;
    color: var(--dark);
}

.map-info p {
    margin: 3px 0;
    font-size: 0.9rem;
}

.map-legend {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    font-size: 0.9rem;
    z-index: 10;
}

.map-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 5px;
}

.map-legend-icon {
    width: 20px;
    height: 20px;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.8rem;
}

.map-legend-icon.driver {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
}

.map-legend-icon.passenger {
    background: var(--info);
}

/* Marker styles */
.gm-style-iw {
    border-radius: 8px !important;
}

.marker-driver {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.marker-passenger {
    background: var(--info);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Ride Card */
.ride-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid var(--gray-light);
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 1rem;
}

.ride-card:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    transform: translateY(-3px);
    border-color: var(--primary-dark);
}

.ride-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}

.ride-driver {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.driver-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
}

.driver-info h4 {
    margin: 0 0 3px 0;
    color: var(--dark);
}

.driver-info .text-muted {
    font-size: 0.875rem;
}

.ride-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #f59e0b;
}

.ride-status {
    text-align: center;
}

.ride-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

.ride-detail-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.ride-detail-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: #f0f9ff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--info);
    font-size: 1.2rem;
}

.ride-detail-text small {
    color: var(--gray);
}

.ride-detail-text strong {
    display: block;
    color: var(--dark);
}

.ride-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-light);
}

.seats-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--gray);
    font-weight: 600;
}

.seats-indicator {
    display: flex;
    gap: 3px;
}

.seat {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    background: var(--gray-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
}

.seat.available {
    background: var(--success);
    color: white;
}

.seat.taken {
    background: var(--danger);
    color: white;
}

/* Ride Form */
.ride-form-section {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.form-section-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.form-section-title::before {
    content: '';
    width: 4px;
    height: 24px;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
    border-radius: 2px;
}

.location-picker {
    position: relative;
    margin-bottom: 1rem;
}

.location-input-group {
    position: relative;
}

.location-input-group input {
    padding-right: 40px;
}

.location-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--primary-dark);
    cursor: pointer;
    font-size: 1.2rem;
}

.location-btn:hover {
    color: var(--primary-darker);
}

.autocomplete-list {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    background: white;
    border: 1px solid var(--gray-light);
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    display: none;
}

.autocomplete-list.show {
    display: block;
}

.autocomplete-item {
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid var(--gray-light);
}

.autocomplete-item:hover {
    background: var(--light);
    padding-right: 1.5rem;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

/* Notifications */
.notifications-container {
    position: fixed;
    top: 80px;
    right: 20px;
    max-width: 350px;
    z-index: 999;
}

.notification {
    background: white;
    border-radius: 8px;
    padding: 1rem 1.5rem;
    margin-bottom: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    animation: slideInRight 0.3s ease;
    border-right: 4px solid;
}

.notification.success {
    border-right-color: var(--success);
}

.notification.error {
    border-right-color: var(--danger);
}

.notification.info {
    border-right-color: var(--info);
}

.notification-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 3px;
}

.notification-message {
    color: var(--gray);
    font-size: 0.9rem;
}

.notification-close {
    cursor: pointer;
    color: var(--gray);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.notification-close:hover {
    color: var(--dark);
}

/* Dashboard */
.dashboard-header {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 3rem 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    text-align: center;
}

.dashboard-header h1 {
    color: white;
    margin-bottom: 0.5rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.stat-card-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.stat-card-label {
    color: var(--gray);
    font-weight: 600;
}

/* Profile */
.profile-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2rem;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    font-weight: bold;
    flex-shrink: 0;
    position: relative;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.profile-avatar-upload {
    position: absolute;
    bottom: -5px;
    right: -5px;
    background: white;
    border: 3px solid var(--primary-dark);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--primary-dark);
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.profile-avatar-upload:hover {
    background: var(--primary-dark);
    color: white;
    transform: scale(1.1);
}

.profile-avatar input {
    display: none;
}

.profile-info {
    flex: 1;
}

.profile-info h2 {
    margin-bottom: 0.5rem;
}

.profile-info .text-muted {
    margin-bottom: 1rem;
}

.profile-stats {
    display: flex;
    gap: 2rem;
    margin-top: 1rem;
}

.profile-stat {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.profile-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.profile-stat-label {
    font-size: 0.9rem;
    color: var(--gray);
}

/* Review Card */
.review-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}

.review-rating {
    color: #f59e0b;
    font-size: 1.2rem;
}

.review-comment {
    color: var(--gray);
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.review-meta {
    font-size: 0.85rem;
    color: var(--gray);
}

/* Loading state */
.loading {
    text-align: center;
    padding: 2rem;
    color: var(--gray);
}

.loading .spinner {
    margin: 0 auto 1rem;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.empty-state h3 {
    color: var(--gray);
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--gray);
    margin-bottom: 1.5rem;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 1rem;
    border-bottom: 2px solid var(--gray-light);
    margin-bottom: 2rem;
}

.tab {
    padding: 1rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray);
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
}

.tab:hover {
    color: var(--dark);
}

.tab.active {
    color: var(--primary-dark);
}

.tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    right: 0;
    left: 0;
    height: 2px;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-dark) 100%);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
    #map, #mapModalMap {
        height: 300px;
    }

    .ride-details {
        grid-template-columns: 1fr;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
    }

    .profile-stats {
        justify-content: center;
    }

    .notifications-container {
        left: 10px;
        right: 10px;
        max-width: none;
    }

    .map-info {
        max-width: calc(100% - 20px);
    }
}
