/* ==========================================================================
   Eco-Warm Wood Theme - Ultra Fast & Clean Vanilla CSS
   Activity: Modern Paints & Gypsum Board Riyadh
   Color Tokens: Deep Forest Green (#2d5a27), Warm Wood (#a0522d), Sand (#f9f7f2)
   ========================================================================== */

:root {
  --primary: #2d5a27;
  --primary-dark: #1e3d1a;
  --primary-light: #447e3c;
  --wood: #a0522d;
  --wood-dark: #7a3c1f;
  --wood-light: #c8764a;
  --bg-sand: #f9f7f2;
  --surface: #ffffff;
  --text-main: #1e261d;
  --text-muted: #576354;
  --border-color: #e5dfd3;
  --gold: #d4941e;
  --whatsapp-color: #25d366;
  --call-color: #0d6efd;
  --shadow-sm: 0 2px 8px rgba(45, 90, 39, 0.06);
  --shadow-md: 0 6px 20px rgba(45, 90, 39, 0.1);
  --shadow-lg: 0 12px 32px rgba(45, 90, 39, 0.16);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --font-main: 'Cairo', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-main);
  direction: rtl;
  text-align: right;
  background-color: var(--bg-sand);
  color: var(--text-main);
  line-height: 1.65;
  overflow-x: hidden;
}

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

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

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

/* Promo Bar */
.promo-bar {
  background: linear-gradient(90deg, var(--wood-dark), var(--wood), var(--wood-dark));
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.45rem 1rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.promo-bar::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  animation: shine 3.5s infinite;
}

@keyframes shine {
  100% { left: 150%; }
}

/* Header & Navigation */
.site-header {
  background-color: var(--surface);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--border-color);
}

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

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  z-index: 1001;
}

.logo-wrap img {
  height: 48px;
  width: auto;
  border-radius: var(--radius-sm);
}

.logo-text {
  font-weight: 900;
  font-size: 1.2rem;
  color: var(--primary);
  line-height: 1.2;
}

.logo-text span {
  display: block;
  font-size: 0.78rem;
  color: var(--wood);
  font-weight: 600;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.nav-item {
  position: relative;
}

.nav-link {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-main);
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary);
  background-color: rgba(45, 90, 39, 0.05);
}

.dropdown-btn svg {
  transition: transform 0.3s ease;
}

.dropdown-btn.open svg {
  transform: rotate(180deg);
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background-color: var(--surface);
  min-width: 260px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  padding: 0.6rem 0;
  z-index: 1002;
}

.dropdown-menu.show {
  display: block;
  animation: fadeInDown 0.25s ease-out;
}

.dropdown-menu a {
  display: flex;
  align-items: center;
  padding: 0.75rem 1.2rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-main);
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

.dropdown-menu a:hover {
  background-color: rgba(45, 90, 39, 0.08);
  color: var(--primary);
  padding-right: 1.5rem;
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: var(--primary);
  cursor: pointer;
  padding: 0.4rem;
  z-index: 1001;
}

/* Close button inside Drawer */
.drawer-close-btn {
  display: none;
  width: 100%;
  background-color: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fca5a5;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 800;
  border-radius: var(--radius-sm);
  cursor: pointer;
  margin-bottom: 1.2rem;
  text-align: center;
}

/* Hero Section */
.hero {
  position: relative;
  background-color: var(--primary-dark);
  background-size: cover;
  background-position: center;
  color: #ffffff;
  padding: 4.5rem 0 3.5rem;
  text-align: center;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(212, 148, 30, 0.25);
  border: 1px solid var(--gold);
  color: #ffd978;
  padding: 0.35rem 1.1rem;
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
}

.hero-title {
  font-size: clamp(1.75rem, 4.5vw, 2.75rem);
  font-weight: 900;
  line-height: 1.35;
  margin-bottom: 1rem;
  color: #ffffff;
}

.hero-title span {
  color: #ffd978;
}

.hero-desc {
  font-size: clamp(0.95rem, 2vw, 1.15rem);
  line-height: 1.7;
  color: #e5ede3;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.9rem 1.8rem;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}

.btn-primary {
  background-color: var(--wood);
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(160, 82, 45, 0.4);
}

.btn-primary:hover {
  background-color: var(--wood-dark);
  transform: translateY(-2px);
}

.btn-whatsapp {
  background-color: var(--whatsapp-color);
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.35);
}

.btn-whatsapp:hover {
  background-color: #1ebc59;
  transform: translateY(-2px);
}

.btn-call {
  background-color: var(--call-color);
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(13, 110, 253, 0.35);
}

.hero-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 1.5rem;
}

.hero-feat-item {
  font-size: 0.88rem;
  font-weight: 600;
  color: #f0f7ef;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

/* Sections */
.section {
  padding: 4rem 0;
}

.section-title-wrap {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 2.8rem;
}

.section-badge {
  display: inline-block;
  color: var(--wood);
  background-color: rgba(160, 82, 45, 0.1);
  padding: 0.3rem 0.9rem;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.section-title {
  font-size: clamp(1.5rem, 3.2vw, 2.2rem);
  font-weight: 900;
  color: var(--primary);
  margin-bottom: 0.6rem;
}

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

/* Services Grid */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.service-card {
  background: var(--surface);
  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;
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: var(--wood-light);
}

.service-card-img {
  height: 200px;
  width: 100%;
  overflow: hidden;
  background-color: #e9e4da;
}

.service-card-img img {
  width: 100%;
  height: 100%;
  transition: transform 0.5s ease;
}

.service-card:hover .service-card-img img {
  transform: scale(1.06);
}

.service-card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.service-card-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.service-card-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1.2rem;
  flex-grow: 1;
}

.service-card-link {
  font-weight: 700;
  color: var(--wood);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.85rem;
}

@media (min-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
  }
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow-sm);
  background-color: #eae5dc;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  transition: transform 0.4s ease;
}

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

/* Lead Form */
.form-section {
  background: linear-gradient(180deg, #f2ece1 0%, var(--bg-sand) 100%);
  border-radius: var(--radius-lg);
  padding: 2.5rem 1.5rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  max-width: 760px;
  margin: 0 auto;
}

.lead-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}

@media (max-width: 640px) {
  .lead-form {
    grid-template-columns: 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary-dark);
}

.form-control {
  width: 100%;
  padding: 0.85rem 1rem;
  font-family: inherit;
  font-size: 0.95rem;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  background-color: var(--surface);
  color: var(--text-main);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(45, 90, 39, 0.15);
}

/* Floating Action Buttons */
.fab-container-right {
  position: fixed;
  bottom: 1.5rem;
  right: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  z-index: 999;
}

.fab-btn {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
  border: none;
  cursor: pointer;
}

.fab-call { background: linear-gradient(135deg, #1d72fe, #0b55ca); }
.fab-whatsapp { background: linear-gradient(135deg, #2ae06c, #1fa84f); }

.fab-shake {
  animation: intermittentShake 4s ease-in-out infinite;
}

@keyframes intermittentShake {
  0%, 75%, 100% { transform: scale(1) rotate(0deg); }
  78% { transform: scale(1.08) rotate(-9deg); }
  82% { transform: scale(1.08) rotate(9deg); }
  86% { transform: scale(1.08) rotate(-7deg); }
  90% { transform: scale(1.08) rotate(7deg); }
  94% { transform: scale(1.04) rotate(-3deg); }
  98% { transform: scale(1.02) rotate(3deg); }
}

.fab-container-left {
  position: fixed;
  bottom: 1.5rem;
  left: 1.25rem;
  z-index: 999;
}

.fab-scroll-top {
  width: 48px;
  height: 48px;
  background-color: var(--primary-dark);
  color: #ffffff;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  border: none;
  cursor: pointer;
}

.fab-scroll-top.visible { display: flex; }

/* Footer */
.site-footer {
  background-color: #172116;
  color: #e5ece4;
  padding: 3.5rem 0 1.5rem;
  border-top: 3px solid var(--wood);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 2.2rem;
  margin-bottom: 2.5rem;
}

@media (max-width: 840px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.8rem;
  }
}

.footer-col h4 {
  color: #ffd978;
  font-size: 1.15rem;
  font-weight: 800;
  margin-bottom: 1.2rem;
  position: relative;
  padding-bottom: 0.4rem;
}

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 35px;
  height: 2px;
  background-color: var(--wood);
}

.footer-links li { margin-bottom: 0.6rem; }
.footer-links a { font-size: 0.9rem; color: #cbd8cb; }
.footer-links a:hover { color: #ffd978; padding-right: 0.4rem; }

.neighborhoods-section {
  background-color: rgba(255, 255, 255, 0.04);
  padding: 1.5rem;
  border-radius: var(--radius-md);
  margin-bottom: 2.5rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.neighborhoods-title {
  color: #ffd978;
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
}

.neighborhoods-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.neighborhood-tag {
  background-color: rgba(255, 255, 255, 0.07);
  color: #dfe9de;
  padding: 0.25rem 0.65rem;
  border-radius: 4px;
  font-size: 0.8rem;
}

.footer-bottom {
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  font-size: 0.85rem;
  color: #9eb19d;
}

.developer-credit {
  margin-top: 0.5rem;
  display: inline-block;
  color: #ffd978;
  font-weight: 700;
}

/* =========================================================
   Mobile Navigation Drawer (Bulletproof Touch Fix)
   ========================================================= */
@media (max-width: 991px) {
  .mobile-toggle {
    display: block;
  }
  
  .drawer-close-btn {
    display: block;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -105%;
    width: 300px;
    height: 100vh;
    background-color: #ffffff;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 1.5rem 1.25rem 3rem;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.35);
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100000;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav-menu.open {
    right: 0 !important;
  }

  .nav-item {
    width: 100%;
    border-bottom: 1px solid var(--border-color);
  }

  .nav-link {
    padding: 1rem 0.5rem;
    width: 100%;
    font-size: 1.05rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-main);
  }

  .dropdown-menu {
    position: static;
    display: none;
    box-shadow: none;
    border: none;
    padding: 0.5rem 0.8rem;
    background-color: var(--bg-sand);
    border-radius: var(--radius-sm);
    margin-bottom: 0.75rem;
  }

  .dropdown-menu.show {
    display: flex;
    flex-direction: column;
  }

  .dropdown-menu a {
    padding: 0.85rem 0.5rem;
    font-size: 0.95rem;
    border-bottom: 1px dashed rgba(0,0,0,0.08);
  }

  .dropdown-menu a:last-child {
    border-bottom: none;
  }

  .nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 99999;
    backdrop-filter: blur(2px);
  }

  .nav-overlay.show {
    display: block;
  }
}

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