/* =============================================
   Zabibu Residence - Main Stylesheet
   ============================================= */

:root {
  --primary: #1a3c5e;
  --primary-light: #2563eb;
  --secondary: #e8a020;
  --accent: #16a34a;
  --danger: #dc2626;
  --text-dark: #1e293b;
  --text-muted: #64748b;
  --bg-light: #f8fafc;
  --border: #e2e8f0;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.12);
  --transition: all 0.3s ease;
  --font: 'Inter', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; height: 100%; }
body { font-family: var(--font); color: var(--text-dark); background: #fff; line-height: 1.6; min-height: 100vh; display: flex; flex-direction: column; }
body > footer { margin-top: auto; }

/* Typography */
.fw-500 { font-weight: 500 !important; }
.fw-600 { font-weight: 600 !important; }
.fw-700 { font-weight: 700 !important; }
.fw-800 { font-weight: 800 !important; }
.x-small { font-size: 0.7rem; }
.text-primary { color: var(--primary) !important; }
.bg-primary { background-color: var(--primary) !important; }
.btn-primary { background: var(--primary) !important; border-color: var(--primary) !important; }
.btn-primary:hover { background: var(--primary-light) !important; border-color: var(--primary-light) !important; }
.btn-outline-primary { color: var(--primary) !important; border-color: var(--primary) !important; }
.btn-outline-primary:hover { background: var(--primary) !important; color: #fff !important; }

/* Cards */
.card { border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); transition: var(--transition); }
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.card-img-top { border-radius: var(--radius) var(--radius) 0 0; object-fit: cover; }

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

/* Navbar */
#mainNav { transition: var(--transition); border-bottom: 1px solid var(--border); }
#mainNav .nav-link { color: var(--text-dark) !important; padding: 0.5rem 0.75rem !important; border-radius: 8px; font-size: 0.9rem; }
#mainNav .nav-link:hover, #mainNav .nav-link.active { color: var(--primary) !important; background: rgba(26,60,94,0.06); }

/* Section Headers */
.section-tag { display: inline-block; background: rgba(26,60,94,0.08); color: var(--primary); font-size: 0.8rem; font-weight: 600; padding: 0.3rem 1rem; border-radius: 50px; margin-bottom: 0.75rem; letter-spacing: 0.05em; text-transform: uppercase; }
.section-title { font-family: 'Playfair Display', serif; font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; color: var(--text-dark); }
.section-title span { color: var(--primary); }
.section-subtitle { color: var(--text-muted); font-size: 1rem; max-width: 600px; }

/* Stat Cards */
.stat-card { border-radius: var(--radius); padding: 1.5rem; position: relative; overflow: hidden; }
.stat-card .stat-icon { width: 56px; height: 56px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; }
.stat-card .stat-value { font-size: 2rem; font-weight: 800; line-height: 1; }
.stat-card .stat-label { font-size: 0.82rem; color: var(--text-muted); font-weight: 500; }
.stat-card .stat-trend { font-size: 0.8rem; font-weight: 600; }

/* Property Cards */
.property-card { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); }
.property-card .property-img-wrap { position: relative; height: 220px; overflow: hidden; }
.property-card .property-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.property-card:hover .property-img-wrap img { transform: scale(1.06); }
.property-card .property-badge { position: absolute; top: 12px; left: 12px; }
.property-card .property-fav { position: absolute; top: 12px; right: 12px; width: 36px; height: 36px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,0.15); transition: var(--transition); }
.property-card .property-fav:hover { background: #fee2e2; color: #dc2626; }
.property-card .property-body { padding: 1.25rem; }
.property-card .property-price { font-size: 1.3rem; font-weight: 800; color: var(--primary); }
.property-card .property-price span { font-size: 0.8rem; font-weight: 400; color: var(--text-muted); }
.property-card .property-meta { display: flex; gap: 1rem; font-size: 0.82rem; color: var(--text-muted); }
.property-card .property-meta i { color: var(--primary); }
.property-card .property-body h5 a { color: var(--text-dark) !important; }
.property-card .property-body h5 a:hover { color: var(--primary) !important; }

/* Buttons */
.btn { border-radius: 8px; font-weight: 500; transition: var(--transition); }
.btn-lg { padding: 0.75rem 1.75rem; font-size: 1rem; }
.btn-xl { padding: 1rem 2.5rem; font-size: 1.05rem; border-radius: 12px; }
.btn-secondary { background: var(--secondary) !important; border-color: var(--secondary) !important; color: #fff !important; }
.btn-secondary:hover { opacity: 0.9; }

/* Search Box */
.search-box { background: #fff; border-radius: 16px; padding: 1.5rem; box-shadow: var(--shadow-lg); }
.search-box .form-control, .search-box .form-select { border-radius: 10px; border: 1px solid var(--border); padding: 0.7rem 1rem; font-size: 0.9rem; }
.search-box .form-control:focus, .search-box .form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,60,94,0.1); }

/* Testimonials */
.testimonial-card { background: #fff; border-radius: var(--radius); padding: 2rem; border: 1px solid var(--border); }
.testimonial-card .quote-icon { font-size: 2.5rem; color: var(--primary); opacity: 0.15; line-height: 1; }
.testimonial-card .stars { color: #f59e0b; }

/* Stats Section */
.stats-section { background: linear-gradient(135deg, var(--primary) 0%, #0f2744 100%); }

/* Amenity Pills */
.amenity-pill { display: inline-flex; align-items: center; gap: 0.4rem; background: var(--bg-light); border: 1px solid var(--border); border-radius: 8px; padding: 0.35rem 0.85rem; font-size: 0.82rem; color: var(--text-dark); }
.amenity-pill i { color: var(--primary); }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* Tables */
.table th { font-weight: 600; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted); border-bottom: 2px solid var(--border); }
.table td { font-size: 0.9rem; vertical-align: middle; }

/* Form styling */
.form-label { font-weight: 600; font-size: 0.85rem; color: var(--text-dark); margin-bottom: 0.35rem; }
.form-control, .form-select { border-radius: 8px; border: 1px solid var(--border); font-size: 0.9rem; padding: 0.6rem 0.9rem; }
.form-control:focus, .form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,60,94,0.1); }

/* Page header */
.page-header { background: linear-gradient(135deg, var(--primary) 0%, #0f2744 100%); padding: 3rem 0 2rem; }
.page-header h1 { color: #fff; font-family: 'Playfair Display', serif; }
.page-header p { color: rgba(255,255,255,0.75); }
.breadcrumb-item.active { color: rgba(255,255,255,0.6); }
.breadcrumb-item a { color: rgba(255,255,255,0.85); text-decoration: none; }
.breadcrumb-item + .breadcrumb-item::before { color: rgba(255,255,255,0.5); }

/* Dark Mode */
[data-bs-theme="dark"] { --text-dark: #f1f5f9; --bg-light: #1e293b; --border: #334155; }
[data-bs-theme="dark"] body { background: #0f172a; color: #f1f5f9; }
[data-bs-theme="dark"] .card { background: #1e293b; border-color: #334155; }
[data-bs-theme="dark"] .table { --bs-table-bg: transparent; color: #f1f5f9; }
[data-bs-theme="dark"] .form-control, [data-bs-theme="dark"] .form-select { background: #1e293b; border-color: #334155; color: #f1f5f9; }

/* Animations */
@keyframes fadeInUp { from { opacity:0; transform:translateY(30px); } to { opacity:1; transform:translateY(0); } }
@keyframes pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.05); } }
.animate-fadeInUp { animation: fadeInUp 0.6s ease forwards; }
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }

/* Footer */
footer.bg-dark { background-color: #0f172a !important; }
footer.bg-dark,
footer.bg-dark p,
footer.bg-dark li,
footer.bg-dark span,
footer.bg-dark small,
footer.bg-dark div { color: #ffffff !important; }
footer.bg-dark .text-muted { color: #ffffff !important; }
footer.bg-dark a { color: #ffffff !important; text-decoration: none; transition: color 0.2s; }
footer.bg-dark a:hover { color: #60a5fa !important; }
footer.bg-dark h6,
footer.bg-dark .fw-700,
footer.bg-dark .text-white { color: #ffffff !important; }
footer.bg-dark ul li { margin-bottom: 0.6rem; }
footer.bg-dark i.text-primary,
footer.bg-dark .text-primary { color: #60a5fa !important; }
footer.bg-dark .badge.bg-success { background-color: #16a34a !important; color: #fff !important; }
footer.bg-dark .btn-outline-light { border-color: rgba(255,255,255,0.35) !important; color: #e2e8f0 !important; }
footer.bg-dark .btn-outline-light:hover { background: rgba(255,255,255,0.12) !important; color: #fff !important; }
footer.bg-dark .btn-success { background: #16a34a !important; border-color: #16a34a !important; color: #fff !important; }
footer.bg-dark .input-group .form-control { background: rgba(255,255,255,0.1) !important; border-color: rgba(255,255,255,0.25) !important; color: #fff !important; }
footer.bg-dark .input-group .form-control::placeholder { color: rgba(255,255,255,0.5) !important; }
footer.bg-dark hr { border-color: rgba(255,255,255,0.15) !important; }
footer.bg-dark .border-secondary { border-color: rgba(255,255,255,0.15) !important; }

/* Responsive */
@media (max-width: 768px) {
  .section-title { font-size: 1.5rem; }
  .stat-card .stat-value { font-size: 1.5rem; }
  .property-card .property-img-wrap { height: 180px; }
}
