/* ============================================
   RENT HUB - Main Public Styles
   ============================================ */

:root {
    --primary: #4a90d9;
    --primary-dark: #357abd;
    --primary-light: #e3f2fd;
    --secondary: #2c3e50;
    --success: #27ae60;
    --danger: #e74c3c;
    --warning: #f39c12;
    --text-dark: #2c3e50;
    --text-medium: #5a6c7d;
    --text-light: #95a5a6;
    --bg-light: #f8f9fa;
    --white: #ffffff;
    --border: #e1e8ed;
    --shadow: 0 2px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
    --gradient-primary: linear-gradient(135deg, #4a90d9, #357abd);
    --gradient-dark: linear-gradient(135deg, #2c3e50, #34495e);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: #f0f4f8;
    color: var(--text-dark);
    line-height: 1.6;
}

/* Navbar */
.navbar {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.nav-logo {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.nav-logo-image {
    display: block;
    height: 100px;
    width: auto;
    max-width: 260px;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.4rem;
    color: var(--text-dark);
    cursor: pointer;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 8px;
    align-items: center;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    text-decoration: none;
    color: var(--text-medium);
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s;
    font-size: 0.95rem;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
    background: rgba(11, 30, 238, 0.168);
}

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

.nav-link-agent:hover {
    background: rgb(191, 206, 237);
    color: black;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(74,144,217,0.3);
}

.nav-shortlist-count {
    background: var(--danger);
    color: white;
    font-size: 0.7rem;
    padding: 2px 7px;
    border-radius: 10px;
    font-weight: 700;
    margin-left: 4px;
}

/* Flash Messages */
.flash-message {
    max-width: 1200px;
    margin: 20px auto;
    padding: 16px 24px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideDown 0.4s ease;
    position: relative;
}

.flash-success { background: #d4edda; color: #155724; border-left: 4px solid var(--success); }
.flash-error { background: #f8d7da; color: #721c24; border-left: 4px solid var(--danger); }
.flash-warning { background: #fff3cd; color: #856404; border-left: 4px solid var(--warning); }

.flash-close {
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    opacity: 0.6;
}

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

/* Hero Section */
.hero {
    background: var(--gradient-dark);
    padding: 80px 24px;
    color: white;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-content h1 {
    font-size: 3rem;
    line-height: 1.2;
    margin-bottom: 20px;
}

.hero-content h1 span { color: var(--primary); }

.hero-content p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 30px;
    line-height: 1.7;
}

.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 40px;
}

.stat-item { text-align: center; }
.stat-number { font-size: 2rem; font-weight: 700; }
.stat-label { opacity: 0.7; font-size: 0.9rem; }

.hero-image img {
    width: 100%;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
}

/* Search Section */
.search-section {
    max-width: 1100px;
    margin: -40px auto 40px;
    padding: 0 24px;
}

.search-container {
    background: white;
    padding: 24px;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr auto;
    gap: 16px;
    align-items: end;
}

.search-input {
    padding: 14px 18px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 1rem;
    width: 100%;
    transition: all 0.3s;
    font-family: inherit;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(74,144,217,0.1);
}

.search-btn {
    padding: 14px 28px;
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(74,144,217,0.3);
}

/* Sections */
.section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 24px;
}

.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-header h2 {
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.section-line {
    width: 60px;
    height: 4px;
    background: var(--gradient-primary);
    margin: 0 auto 16px;
    border-radius: 2px;
}

.section-header p { color: var(--text-medium); }

/* Property Cards */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.property-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
}

.property-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.property-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.property-card:hover .property-image img { transform: scale(1.05); }

.property-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    color: white;
}

.property-badge-featured { background: linear-gradient(135deg, #f39c12, #e67e22); }

.property-price {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: rgba(0,0,0,0.75);
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1rem;
}

.shortlist-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-light);
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.shortlist-btn:hover,
.shortlist-btn.active {
    color: var(--danger);
    transform: scale(1.1);
}

.shortlist-btn.active i { font-weight: 900; }

.property-content { padding: 20px; }

.property-type {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.property-title {
    font-size: 1.15rem;
    margin: 8px 0;
    color: var(--text-dark);
    line-height: 1.4;
}

.property-location {
    color: var(--text-medium);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
}

.property-location i { color: var(--danger); }

.property-features {
    display: flex;
    gap: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.property-feature {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: var(--text-medium);
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(74,144,217,0.3);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

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

.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.btn-block { width: 100%; }

/* Property Detail */
.property-detail {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.property-detail-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
}

.property-detail-content { padding: 30px; }

.property-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
}

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

.property-detail-meta {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.property-detail-meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    background: var(--bg-light);
    border-radius: 10px;
}

.property-detail-meta-item i {
    font-size: 1.3rem;
    color: var(--primary);
}

/* Image Gallery */
.image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.image-gallery-item {
    border-radius: 10px;
    overflow: hidden;
    height: 150px;
}

.image-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.image-gallery-item:hover img { transform: scale(1.05); }

/* Agent Card */
.agent-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    background: var(--bg-light);
    border-radius: 12px;
    margin-top: 30px;
}

.agent-card img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
}

.agent-card-info h4 { margin-bottom: 4px; }
.agent-card-info p { color: var(--text-medium); font-size: 0.9rem; }

.agent-rating {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    color: var(--text-dark);
    font-weight: 600;
}
.agent-rating .rating-stars {
    display: inline-flex;
    gap: 2px;
    color: #f5b301;
}
.agent-rating .rating-stars .fa-star {
    font-size: 0.92rem;
}
.agent-rating .rating-count {
    font-size: 0.9rem;
    color: var(--text-medium);
}

/* Forms */
.form-group { margin-bottom: 20px; }
.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-medium);
    font-size: 0.9rem;
}

.form-control {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s;
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(74,144,217,0.1);
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%235a6c7d' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

textarea.form-control { min-height: 120px; resize: vertical; }

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-light);
}

.empty-state i { font-size: 3rem; margin-bottom: 16px; display: block; }
.empty-state h3 { color: var(--text-dark); margin-bottom: 8px; }

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 40px;
}

.pagination a {
    padding: 10px 18px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-medium);
    background: white;
    border: 1px solid var(--border);
    font-weight: 600;
    transition: all 0.3s;
}

.pagination a:hover,
.pagination a.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Footer */
.footer {
    background: var(--secondary);
    color: white;
    padding: 60px 24px 20px;
    margin-top: 60px;
}

.footer-container { max-width: 1200px; margin: 0 auto; }

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--primary);
}

.footer-brand p {
    opacity: 0.7;
    line-height: 1.7;
    margin-bottom: 20px;
}

.footer-social {
    display: flex;
    gap: 12px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s;
}

.footer-social a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.footer-links h4,
.footer-contact h4 {
    margin-bottom: 20px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-links a {
    display: block;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    padding: 8px 0;
    transition: all 0.3s;
}

.footer-links a:hover {
    color: var(--primary);
    padding-left: 8px;
}

.footer-contact p {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    opacity: 0.8;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
    opacity: 0.6;
    font-size: 0.9rem;
}

/* Shortlist Page */
.shortlist-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.shortlist-empty {
    text-align: center;
    padding: 80px 20px;
}

.shortlist-empty i {
    font-size: 4rem;
    color: var(--text-light);
    margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 968px) {
    .hero-container { grid-template-columns: 1fr; text-align: center; }
    .hero-content h1 { font-size: 2.2rem; }
    .hero-stats { justify-content: center; }
    .search-container { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .property-detail-header { flex-direction: column; text-align: center; }
    .property-detail-meta { justify-content: center; }
}

@media (max-width: 600px) {
    .nav-toggle { display: block; }
    .nav-menu {
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: var(--shadow-lg);
        transform: translateY(-150%);
        transition: transform 0.3s;
    }
    .nav-menu.active { transform: translateY(0); }
    .properties-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .agent-card { flex-direction: column; text-align: center; }
}
