/* Custom CSS for TimTro.xyz */

/* General Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.main-content {
    padding-bottom: 80px; /* Space for bottom navigation on mobile */
}

@media (min-width: 992px) {
    .main-content {
        padding-bottom: 20px;
    }
}

/* Bottom Navigation */
.bottom-nav {
    z-index: 1030;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    padding: 8px 0;
}

.bottom-nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #6c757d;
    padding: 8px 4px;
    transition: color 0.3s ease;
}

.bottom-nav-link:hover,
.bottom-nav-link.active {
    color: #0d6efd;
    text-decoration: none;
}

.bottom-nav-link i {
    font-size: 1.2rem;
    margin-bottom: 2px;
}

.bottom-nav-link small {
    font-size: 0.7rem;
    font-weight: 500;
}

/* Search Form Styles */
.search-form {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.search-form .form-control {
    border-radius: 25px;
    border: none;
    padding: 12px 20px;
    font-size: 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.search-form .btn {
    border-radius: 25px;
    padding: 12px 30px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Quick Filters */
.quick-filters {
    margin: 1rem 0;
}

.quick-filters .btn {
    border-radius: 20px;
    margin: 0.25rem;
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
}

/* Location Button */
.location-btn {
    background: none;
    border: none;
    color: #fff;
    text-decoration: underline;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.location-btn:hover {
    color: #f8f9fa;
}

/* Listing Cards */
.listing-card {
    border: none;
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
}

.listing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.listing-card .card-img-top {
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

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

.listing-card .card-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.listing-card .price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #e74c3c;
    margin-bottom: 0.5rem;
}

.listing-card .location {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.listing-card .amenities {
    font-size: 0.8rem;
    color: #95a5a6;
}

.listing-card .save-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255,255,255,0.9);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.listing-card .save-btn:hover {
    background: #fff;
    transform: scale(1.1);
}

.listing-card .save-btn.saved {
    color: #e74c3c;
}

/* Filter Panel */
.filter-panel {
    background: #fff;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin-bottom: 2rem;
}

.filter-panel .form-label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

/* Range Slider */
.range-slider {
    margin: 1rem 0;
}

.range-slider input[type="range"] {
    width: 100%;
    margin: 10px 0;
    background: transparent;
    -webkit-appearance: none;
}

.range-slider input[type="range"]::-webkit-slider-track {
    background: #ddd;
    height: 6px;
    border-radius: 3px;
}

.range-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    background: #0d6efd;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    cursor: pointer;
}

.range-values {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: #6c757d;
}

/* Map Styles */
.map-container {
    height: 400px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
}

@media (min-width: 768px) {
    .map-container {
        height: 500px;
    }
}

.map-fullscreen {
    height: calc(100vh - 120px);
}

/* Amenities */
.amenities-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.amenity-tag {
    background: #e9ecef;
    color: #495057;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.amenity-tag i {
    font-size: 0.9rem;
}

/* Image Gallery */
.image-gallery {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.image-gallery .carousel-item img {
    height: 300px;
    object-fit: cover;
    width: 100%;
}

@media (min-width: 768px) {
    .image-gallery .carousel-item img {
        height: 400px;
    }
}

.image-gallery .carousel-indicators {
    bottom: 10px;
}

.image-gallery .carousel-control-prev,
.image-gallery .carousel-control-next {
    width: 5%;
}

/* Contact Actions */
.contact-actions {
    position: fixed;
    bottom: 80px; /* Above bottom nav on mobile */
    left: 0;
    right: 0;
    background: #fff;
    padding: 1rem;
    box-shadow: 0 -2px 15px rgba(0,0,0,0.1);
    z-index: 1020;
}

@media (min-width: 992px) {
    .contact-actions {
        position: static;
        box-shadow: none;
        background: transparent;
        padding: 1rem 0;
    }
}

.contact-actions .btn {
    border-radius: 25px;
    font-weight: 600;
    padding: 12px 20px;
    margin: 0 0.25rem;
}

/* Pagination */
.pagination {
    justify-content: center;
    margin: 2rem 0;
}

.pagination .page-link {
    border-radius: 8px;
    margin: 0 2px;
    border: none;
    color: #0d6efd;
}

.pagination .page-item.active .page-link {
    background: #0d6efd;
    border-color: #0d6efd;
}

/* Loading States */
.loading {
    text-align: center;
    padding: 2rem;
}

.loading .spinner-border {
    width: 3rem;
    height: 3rem;
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.empty-state i {
    font-size: 4rem;
    color: #dee2e6;
    margin-bottom: 1rem;
}

.empty-state h4 {
    color: #6c757d;
    margin-bottom: 1rem;
}

.empty-state p {
    color: #adb5bd;
    margin-bottom: 2rem;
}

/* Form Styles */
.form-floating {
    margin-bottom: 1rem;
}

.form-floating .form-control {
    border-radius: 10px;
    border: 2px solid #e9ecef;
    transition: border-color 0.3s ease;
}

.form-floating .form-control:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.form-floating label {
    color: #6c757d;
}

/* Buttons */
.btn {
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.btn-outline-primary {
    border: 2px solid #0d6efd;
    color: #0d6efd;
}

.btn-outline-primary:hover {
    background: #0d6efd;
    border-color: #0d6efd;
    transform: translateY(-2px);
}

/* Alerts */
.alert {
    border: none;
    border-radius: 10px;
    padding: 1rem 1.5rem;
}

.alert-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
}

.alert-danger {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
}

.alert-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    color: #856404;
}

/* Badges */
.badge {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 15px;
}

/* Responsive Utilities */
@media (max-width: 576px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .listing-card .card-body {
        padding: 1rem;
    }
    
    .search-form {
        padding: 1.5rem 0;
    }
    
    .filter-panel {
        padding: 1rem;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #1a1a1a;
        color: #e9ecef;
    }
    
    .listing-card {
        background-color: #2d3748;
        color: #e9ecef;
    }
    
    .filter-panel {
        background-color: #2d3748;
        color: #e9ecef;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

.slide-up {
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-custom {
    box-shadow: 0 4px 25px rgba(0,0,0,0.1);
}

.border-radius-custom {
    border-radius: 15px;
}

/* Print Styles */
@media print {
    .bottom-nav,
    .contact-actions,
    .navbar {
        display: none !important;
    }
    
    .main-content {
        padding-bottom: 0;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .listing-card {
        background-color: #2d3748;
        border-color: #4a5568;
        color: #e2e8f0;
    }
    
    .filter-panel {
        background-color: #2d3748;
        color: #e2e8f0;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus styles for better accessibility */
.btn:focus,
.form-control:focus,
.form-select:focus {
    outline: 2px solid #0d6efd;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .listing-card {
        border-width: 2px;
    }
    
    .btn {
        border-width: 2px;
    }
}