/* Main Styles for Gulf Properties Website */

/* Global Styles */
:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --info-color: #0dcaf0;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --primary-font: 'Tajawal', sans-serif;
}

body {
    font-family: var(--primary-font);
    direction: rtl;
    text-align: right;
    background-color: #f8f9fa;
}

/* Header Styles */
.navbar {
    background-color: var(--primary-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.navbar-brand {
    font-weight: 700;
    color: white;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
    color: white;
}

/* Hero Section */
.hero-section {
    background-color: var(--primary-color);
    color: white;
    padding: 4rem 0;
    position: relative;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50px;
    background-color: #f8f9fa;
    clip-path: polygon(0 100%, 100% 100%, 100% 0);
}

/* Search Form */
.search-form {
    background-color: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Property Cards */
.property-card {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
}

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

.property-card .card-img-top {
    height: 200px;
    object-fit: cover;
}

.property-card .card-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.property-card .card-text {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.property-card .property-features {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

.property-card .property-price {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.2rem;
}

/* Property Details Page */
.property-detail-section {
    padding: 3rem 0;
}

.property-detail-header {
    margin-bottom: 2rem;
}

.property-detail-header h1 {
    font-weight: 700;
    margin-bottom: 1rem;
}

.property-detail-header .property-location {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.property-detail-header .property-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.property-images {
    margin-bottom: 2rem;
}

.property-main-image {
    height: 400px;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.property-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.property-thumbnail {
    height: 100px;
    border-radius: 5px;
    overflow: hidden;
    cursor: pointer;
}

.property-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s ease;
}

.property-thumbnail:hover img {
    opacity: 0.8;
}

.property-detail-features {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.property-detail-feature {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
}

.property-detail-feature i {
    color: var(--primary-color);
}

/* Forms */
.form-label {
    font-weight: 500;
}

.form-control, .form-select {
    padding: 0.75rem 1rem;
    border-radius: 5px;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Buttons */
.btn {
    padding: 0.5rem 1.5rem;
    border-radius: 5px;
    font-weight: 500;
}

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

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

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

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

/* Footer */
footer {
    background-color: var(--primary-color);
    color: white;
    padding: 3rem 0 1rem;
}

footer h5 {
    font-weight: 700;
    margin-bottom: 1.5rem;
}

footer ul li {
    margin-bottom: 0.5rem;
}

footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: white;
}

/* Responsive Adjustments */
@media (max-width: 767.98px) {
    .property-main-image {
        height: 300px;
    }
    
    .property-thumbnail {
        height: 80px;
    }
    
    .property-detail-header .property-price {
        font-size: 1.3rem;
    }
}

/* Utilities */
.text-primary {
    color: var(--primary-color) !important;
}

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

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

/* Arabic Text Alignment */
.text-right {
    text-align: right !important;
}

/* Default Property Image */
.default-property-img {
    background-color: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #adb5bd;
    font-size: 2rem;
}

/* Favorites Button */
.favorite-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
    z-index: 1;
}

.favorite-btn:hover {
    background-color: white;
}

.favorite-btn i {
    color: #dc3545;
    font-size: 1.2rem;
}

/* Line Clamp for Property Descriptions */
.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}
