/* =====================================================
   ALCENOR CAPITAL - STYLE PRINCIPAL
   Immobilier de Prestige & Volet Investissement Maroc
   ===================================================== */

:root {
  --primary: #0B132B;
  --primary-light: #1C2541;
  --primary-dark: #050A18;
  --gold: #C5A880;
  --gold-hover: #B39368;
  --gold-soft: rgba(197, 168, 128, 0.15);
  --emerald: #0D9488;
  --emerald-dark: #0F766E;
  --text-main: #1E293B;
  --text-muted: #64748B;
  --text-light: #94A3B8;
  --bg-main: #F8FAFC;
  --bg-card: #FFFFFF;
  --border-color: #E2E8F0;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --shadow-sm: 0 2px 4px rgba(11, 19, 43, 0.04);
  --shadow-md: 0 10px 25px -5px rgba(11, 19, 43, 0.08);
  --shadow-lg: 0 20px 35px -10px rgba(11, 19, 43, 0.12);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--primary);
  font-weight: 700;
  line-height: 1.25;
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 80px 0;
}

.section-title-wrap {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 50px auto;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gold-soft);
  color: #8B6B38;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 14px;
}

.section-title {
  font-size: 2.3rem;
  font-weight: 800;
  margin-bottom: 12px;
  color: var(--primary);
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 12px 26px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  border: 1px solid transparent;
  transition: var(--transition);
}

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

.btn-primary:hover {
  background: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-gold {
  background: var(--gold);
  color: #FFFFFF;
}

.btn-gold:hover {
  background: var(--gold-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(197, 168, 128, 0.35);
}

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

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

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

/* Header & Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo svg {
  width: 36px;
  height: 36px;
}

.brand-name {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--primary);
}

.brand-name span {
  color: var(--gold);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-main);
  position: relative;
  padding: 6px 0;
}

.nav-link:hover, .nav-link.active {
  color: var(--gold);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.currency-select {
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: #FFF;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
  cursor: pointer;
}

/* Mobile Toggle */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

/* Hero Section */
.hero-section {
  position: relative;
  background: linear-gradient(135deg, rgba(11, 19, 43, 0.92) 0%, rgba(28, 37, 65, 0.88) 100%), url('https://images.unsplash.com/photo-1548013146-72479768bbaa?w=1600&auto=format&fit=crop&q=80') center/cover no-repeat;
  color: #FFFFFF;
  padding: 100px 0 120px 0;
  overflow: hidden;
}

.hero-content {
  max-width: 820px;
  margin: 0 auto;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(197, 168, 128, 0.2);
  border: 1px solid rgba(197, 168, 128, 0.4);
  color: #F3E5AB;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  margin-bottom: 24px;
}

.hero-title {
  color: #FFFFFF;
  font-size: 3.2rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 20px;
  line-height: 1.15;
}

.hero-title span {
  color: var(--gold);
}

.hero-desc {
  font-size: 1.2rem;
  color: #E2E8F0;
  margin-bottom: 40px;
  line-height: 1.6;
}

/* Search Bar Box */
.search-box-wrap {
  background: #FFFFFF;
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
  margin-top: 20px;
  color: var(--text-main);
  text-align: left;
}

.search-tabs {
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 12px;
}

.tab-btn {
  background: none;
  border: none;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  transition: var(--transition);
}

.tab-btn.active {
  background: var(--primary);
  color: #FFFFFF;
}

.search-form-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr) auto;
  gap: 16px;
  align-items: flex-end;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  color: var(--text-main);
  background: #FFFFFF;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(197, 168, 128, 0.2);
}

/* Cards & Grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 30px;
}

.property-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.property-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--gold);
}

.card-image-wrap {
  position: relative;
  height: 240px;
  overflow: hidden;
}

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

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

.card-badges {
  position: absolute;
  top: 14px;
  left: 14px;
  display: flex;
  gap: 8px;
  z-index: 2;
}

.badge {
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #FFF;
}

.badge-featured {
  background: var(--gold);
}

.badge-transaction {
  background: var(--primary);
}

.badge-ai {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(13, 148, 136, 0.9);
  color: #FFF;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: 4px;
  backdrop-filter: blur(4px);
}

.card-body {
  padding: 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-price-wrap {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
}

.card-price {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--primary);
}

.card-price-secondary {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.4;
}

.card-location {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 16px;
}

.card-specs {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 16px;
  color: var(--text-main);
  font-size: 0.88rem;
  font-weight: 600;
}

.spec-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.card-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Foreign Investors Highlight Banner */
.investor-promo-banner {
  background: linear-gradient(135deg, #0B132B 0%, #1C2541 60%, #0F766E 100%);
  border-radius: var(--radius-lg);
  padding: 60px;
  color: #FFFFFF;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.investor-promo-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

.investor-perks-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 28px 0;
}

.perk-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.95rem;
}

.perk-item svg {
  color: var(--gold);
  flex-shrink: 0;
  margin-top: 3px;
}

/* Packs Section */
.packs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.pack-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  padding: 40px 30px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition);
}

.pack-card.popular {
  border-color: var(--gold);
  box-shadow: 0 15px 35px rgba(197, 168, 128, 0.25);
  transform: translateY(-8px);
}

.popular-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: #FFF;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 4px 18px;
  border-radius: var(--radius-full);
}

.pack-price {
  font-size: 2.3rem;
  font-weight: 800;
  color: var(--primary);
  margin: 16px 0 24px 0;
}

.pack-price span {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 500;
}

.pack-features {
  list-style: none;
  margin-bottom: 30px;
  flex-grow: 1;
}

.pack-features li {
  padding: 10px 0;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--text-main);
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(11, 19, 43, 0.7);
  backdrop-filter: blur(6px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.active {
  display: flex;
}

.modal-box {
  background: #FFF;
  border-radius: var(--radius-md);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 32px;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
}

/* Footer */
.site-footer {
  background: var(--primary-dark);
  color: #94A3B8;
  padding: 80px 0 30px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 60px;
}

.footer-col h4 {
  color: #FFFFFF;
  font-size: 1.1rem;
  margin-bottom: 20px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

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

.footer-bottom {
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
}

/* Responsive */
@media (max-width: 1024px) {
  .search-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .packs-grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin: 0 auto;
  }
  .investor-promo-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .main-nav {
    display: none;
  }
  .mobile-toggle {
    display: block;
  }
  .hero-title {
    font-size: 2.2rem;
  }
  .search-form-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 14px;
    text-align: center;
  }
}
