@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* ==========================================
   DESIGN SYSTEM VARIABLES
   ========================================== */
:root {
  --primary: #B08D4F;
  --primary-light: #C5A875;
  --primary-dark: #8E703C;
  --primary-rgb: 176, 141, 79;
  
  /* Theme Variables - Default (Light Mode) */
  --bg-light: #F9FAFB;
  --bg-cream: #F5F3EF;
  --bg-card-light: #FFFFFF;
  --text-dark: #1E252C;
  --text-muted-dark: #4B5563;
  --border-light: rgba(0, 0, 0, 0.06);
  --border-color: rgba(0, 0, 0, 0.08);
  --shadow-premium: 0 15px 35px rgba(0, 0, 0, 0.05);

  /* Dark Charcoal & Navy Tones (Static dark sections) */
  --bg-dark: #0A0D10;
  --bg-navy: #11161D;
  --bg-card: #181E26;
  --border-dark: rgba(176, 141, 79, 0.15);
  
  /* Typography Colors */
  --text-white: #FFFFFF;
  --text-muted-light: #9CA3AF;
  
  /* Typography Families */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  /* Shadows & Radius */
  --shadow-gold: 0 10px 30px rgba(176, 141, 79, 0.15);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  
  --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --header-height: 80px;
}

/* Dark Mode Variables Override */
body.dark-mode {
  --bg-light: #0A0D10;
  --bg-cream: #11161D;
  --bg-card-light: #181E26;
  --text-dark: #F3F4F6;
  --text-muted-dark: #9CA3AF;
  --border-light: rgba(255, 255, 255, 0.08);
  --border-color: rgba(255, 255, 255, 0.1);
  --shadow-premium: 0 15px 35px rgba(0, 0, 0, 0.3);
}

/* RTL / Kurdish Font override */
[dir="rtl"] {
  --font-heading: 'Cairo', sans-serif;
  --font-body: 'Cairo', sans-serif;
}

/* ==========================================
   BASE STYLES
   ========================================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-light);
  color: var(--text-dark);
  line-height: 1.6;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.4s ease, color 0.4s ease, border-color 0.4s ease;
}

section, .skill-card, .project-card, .contact-form-panel {
  transition: background-color 0.4s ease, color 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.2;
}

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

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

button, input, select, textarea {
  font-family: inherit;
}

/* Premium Gold Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-light);
}

/* ==========================================
   UTILITY CLASSES & ANIMATIONS
   ========================================== */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

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

.bg-dark-section {
  background-color: var(--bg-dark);
  color: var(--text-light);
}
.bg-dark-section h1,
.bg-dark-section h2,
.bg-dark-section h3,
.bg-dark-section h4 {
  color: var(--text-white);
}

.bg-cream-section {
  background-color: var(--bg-cream);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.5px;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
  cursor: pointer;
  border: 1px solid transparent;
  gap: 8px;
}

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

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--primary);
  color: var(--primary);
}
.btn-outline:hover {
  background-color: var(--primary);
  color: var(--text-white);
  transform: translateY(-2px);
}

.btn-dark {
  background-color: var(--bg-navy);
  color: var(--text-white);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.btn-dark:hover {
  background-color: var(--primary);
  border-color: var(--primary);
  transform: translateY(-2px);
}

/* Scroll Animation classes */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Section Header */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}
.section-header h2 {
  font-size: 36px;
  margin-bottom: 16px;
  position: relative;
  display: inline-block;
  padding-bottom: 12px;
}
.section-header h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: var(--primary);
}
.section-header p {
  color: var(--text-muted-dark);
  font-size: 16px;
  max-width: 600px;
  margin: 0 auto;
}
.bg-dark-section .section-header p {
  color: var(--text-muted-light);
}

/* ==========================================
   NAVBAR (HEADER)
   ========================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  z-index: 1000;
  transition: var(--transition-smooth);
}
.header.scrolled {
  background-color: rgba(10, 13, 16, 0.85);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  border-bottom: 1px solid var(--border-dark);
  height: 70px;
}
.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 22px;
  color: var(--text-white);
}
.logo-img {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.logo:hover .logo-img {
  transform: scale(1.1);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.5px;
  position: relative;
  padding: 6px 0;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  transition: var(--transition-smooth);
}
.nav-links a:hover {
  color: var(--primary);
}
.nav-links a:hover::after {
  width: 100%;
}

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

/* Lang Switcher */
.lang-toggle {
  background: transparent;
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition-smooth);
}
.lang-toggle:hover {
  background-color: var(--primary);
  color: var(--text-white);
}

/* Hamburger menu */
.menu-btn {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  width: 30px;
  height: 24px;
  position: relative;
}
.menu-btn span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-white);
  position: absolute;
  left: 0;
  transition: var(--transition-smooth);
}
.menu-btn span:nth-child(1) { top: 0; }
.menu-btn span:nth-child(2) { top: 11px; }
.menu-btn span:nth-child(3) { top: 22px; }

.menu-btn.open span:nth-child(1) {
  transform: rotate(45deg);
  top: 11px;
}
.menu-btn.open span:nth-child(2) {
  opacity: 0;
}
.menu-btn.open span:nth-child(3) {
  transform: rotate(-45deg);
  top: 11px;
}

/* ==========================================
   HERO SECTION
   ========================================== */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  background-color: var(--bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-white);
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  background-image: url('images/hero_villa.png');
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
  animation: zoomSlow 20s infinite alternate;
}
@keyframes zoomSlow {
  0% { transform: scale(1); }
  100% { transform: scale(1.08); }
}
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(10, 13, 16, 0.7) 0%, rgba(10, 13, 16, 0.9) 100%);
  z-index: 2;
}
.hero .container {
  position: relative;
  z-index: 3;
  text-align: center;
  max-width: 900px;
}
.hero-title {
  font-size: 56px;
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -1px;
  font-weight: 800;
  animation: fadeInUp 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.hero-subtitle {
  font-size: 20px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 40px;
  max-width: 650px;
  margin-inline: auto;
  animation: fadeInUp 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.hero-ctas {
  display: flex;
  justify-content: center;
  gap: 16px;
  animation: fadeInUp 1.6s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==========================================
   ABOUT US
   ========================================== */
.about {
  padding: 120px 0;
  background-color: var(--bg-light);
}
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 80px;
  align-items: center;
}
.about-text h3 {
  font-size: 16px;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}
.about-text h2 {
  font-size: 40px;
  margin-bottom: 24px;
  color: var(--text-dark);
}
.about-text p {
  color: var(--text-muted-dark);
  margin-bottom: 20px;
  font-size: 16px;
}
.about-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 40px;
}
.about-feature-card {
  background-color: var(--bg-cream);
  padding: 24px;
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--primary);
  transition: var(--transition-smooth);
}
[dir="rtl"] .about-feature-card {
  border-left: none;
  border-right: 3px solid var(--primary);
}
.about-feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-premium);
}
.about-feature-card h4 {
  font-size: 18px;
  margin-bottom: 8px;
  color: var(--text-dark);
}
.about-feature-card p {
  font-size: 14px;
  margin-bottom: 0;
  color: var(--text-muted-dark);
}

.about-visual {
  position: relative;
}
.about-img-wrapper {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-premium);
}
.about-img-wrapper::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 1px solid var(--primary);
  margin: 12px;
  pointer-events: none;
}
.about-badge {
  position: absolute;
  bottom: -30px;
  right: -30px;
  background-color: var(--bg-navy);
  color: var(--text-white);
  padding: 30px;
  border: 1px solid var(--border-dark);
  box-shadow: var(--shadow-premium);
  text-align: center;
  border-radius: var(--radius-sm);
  z-index: 5;
}
[dir="rtl"] .about-badge {
  right: auto;
  left: -30px;
}
.about-badge span {
  display: block;
}
.about-badge .number {
  font-family: var(--font-heading);
  font-size: 48px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
}
.about-badge .label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 8px;
}

/* ==========================================
   SPECIALIZATIONS
   ========================================== */
.specializations {
  padding: 120px 0;
}
.spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 30px;
}
.spec-card {
  background-color: var(--bg-navy);
  border: 1px solid var(--border-dark);
  padding: 40px;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}
.spec-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background-color: var(--primary);
  transform: scaleX(0);
  transition: var(--transition-smooth);
  transform-origin: left;
}
[dir="rtl"] .spec-card::before {
  transform-origin: right;
}
.spec-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-gold);
  border-color: rgba(176, 141, 79, 0.4);
}
.spec-card:hover::before {
  transform: scaleX(1);
}
.spec-icon {
  width: 60px;
  height: 60px;
  background-color: rgba(176, 141, 79, 0.1);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--primary);
}
.spec-icon svg {
  width: 28px;
  height: 28px;
}
.spec-card h3 {
  font-size: 22px;
  margin-bottom: 12px;
  color: var(--text-white);
}
.spec-card p {
  color: var(--text-muted-light);
  font-size: 15px;
}

/* ==========================================
   SERVICES & SKILLS
   ========================================== */
.services-skills {
  padding: 100px 0;
  background-color: var(--bg-cream);
}
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}
.skill-card {
  background-color: var(--bg-card-light);
  padding: 30px 24px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-premium);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: var(--transition-smooth);
  border: 1px solid var(--border-light);
}
.skill-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
}
.skill-num {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 800;
  color: var(--primary-light);
}
.skill-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-dark);
}

/* ==========================================
   FEATURED PROJECTS
   ========================================== */
.projects {
  padding: 120px 0;
  background-color: var(--bg-light);
}
.project-filters {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 50px;
  flex-wrap: wrap;
}
.filter-btn {
  background: transparent;
  border: 1px solid var(--border-light);
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
}
.filter-btn:hover,
.filter-btn.active {
  background-color: var(--primary);
  border-color: var(--primary);
  color: var(--text-white);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 30px;
}
.project-card {
  background-color: var(--bg-card-light);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-premium);
  transition: var(--transition-smooth);
  border: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
}
.project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.12);
  border-color: rgba(176, 141, 79, 0.25);
}
.project-img-wrapper {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background-color: #e5e7eb;
}
.project-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.project-card:hover .project-img-wrapper img {
  transform: scale(1.08);
}
.project-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 6px 12px;
  background-color: rgba(10, 13, 16, 0.85);
  backdrop-filter: blur(8px);
  color: var(--text-white);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-dark);
}
[dir="rtl"] .project-badge {
  right: auto;
  left: 16px;
}
.project-badge.ongoing {
  background-color: rgba(176, 141, 79, 0.9);
  color: var(--text-white);
  border-color: var(--primary-light);
}

.project-info {
  padding: 30px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.project-info h3 {
  font-size: 22px;
  margin-bottom: 10px;
  color: var(--text-dark);
}
.project-location {
  font-size: 13px;
  color: var(--primary);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}
.project-info p {
  color: var(--text-muted-dark);
  font-size: 14px;
  margin-bottom: 20px;
  flex-grow: 1;
}

/* ==========================================
   PHOTO GALLERY
   ========================================== */
.gallery-section {
  padding: 120px 0;
}
.gallery-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.gallery-tab-btn {
  background-color: var(--bg-navy);
  border: 1px solid var(--border-dark);
  color: var(--text-muted-light);
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
}
.gallery-tab-btn:hover,
.gallery-tab-btn.active {
  background-color: var(--primary);
  color: var(--text-white);
  border-color: var(--primary);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.gallery-item {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  box-shadow: var(--shadow-premium);
  background-color: #1a1f26;
  border: 1px solid var(--border-dark);
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.gallery-item-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 13, 16, 0.85);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 24px;
  opacity: 0;
  transition: var(--transition-smooth);
  text-align: center;
  border: 1px solid var(--primary);
  margin: 10px;
  width: calc(100% - 20px);
  height: calc(100% - 20px);
}
.gallery-item:hover img {
  transform: scale(1.08);
}
.gallery-item:hover .gallery-item-overlay {
  opacity: 1;
}
.gallery-item-overlay svg {
  width: 24px;
  height: 24px;
  color: var(--primary);
  margin-bottom: 12px;
  transform: translateY(10px);
  transition: var(--transition-smooth);
}
.gallery-item:hover .gallery-item-overlay svg {
  transform: translateY(0);
}
.gallery-item-overlay h4 {
  font-size: 16px;
  color: var(--text-white);
  margin-bottom: 6px;
}
.gallery-item-overlay p {
  font-size: 12px;
  color: var(--primary-light);
  font-weight: 500;
  text-transform: uppercase;
}

/* ==========================================
   CUSTOM LIGHTBOX
   ========================================== */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(10, 13, 16, 0.98);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.lightbox.open {
  display: flex;
  opacity: 1;
}
.lightbox-content {
  position: relative;
  max-width: 85%;
  max-height: 85%;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.lightbox-img {
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-dark);
}
.lightbox-caption {
  color: var(--text-white);
  margin-top: 20px;
  font-size: 18px;
  font-family: var(--font-heading);
  text-align: center;
}
.lightbox-subcaption {
  color: var(--primary-light);
  font-size: 14px;
  text-transform: uppercase;
  margin-top: 4px;
}
.lightbox-btn {
  position: absolute;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-white);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-smooth);
}
.lightbox-btn:hover {
  background-color: var(--primary);
  color: var(--text-white);
  border-color: var(--primary);
}
.lightbox-close {
  top: 40px;
  right: 40px;
}
[dir="rtl"] .lightbox-close {
  right: auto;
  left: 40px;
}
.lightbox-prev {
  left: 40px;
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-next {
  right: 40px;
  top: 50%;
  transform: translateY(-50%);
}

/* ==========================================
   WHY CHOOSE US (STATS)
   ========================================== */
.stats {
  padding: 100px 0;
  background-color: var(--bg-navy);
  border-top: 1px solid var(--border-dark);
  border-bottom: 1px solid var(--border-dark);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 40px;
  text-align: center;
}
.stat-card {
  padding: 20px;
}
.stat-num {
  font-family: var(--font-heading);
  font-size: 64px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.stat-label {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-light);
  font-weight: 600;
}
.stat-desc {
  font-size: 13px;
  color: var(--text-muted-light);
  margin-top: 6px;
}

/* ==========================================
   CONTACT SECTION
   ========================================== */
.contact {
  padding: 120px 0;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 60px;
  align-items: start;
}
.contact-info-panel h3 {
  font-size: 15px;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}
.contact-info-panel h2 {
  font-size: 36px;
  margin-bottom: 30px;
}
.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 40px;
}
.contact-method-card {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}
.contact-icon {
  width: 50px;
  height: 50px;
  background-color: rgba(176, 141, 79, 0.08);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
  border: 1px solid rgba(176, 141, 79, 0.15);
}
.contact-icon svg {
  width: 22px;
  height: 22px;
}
.contact-method-text h4 {
  font-size: 16px;
  color: var(--text-dark);
  margin-bottom: 4px;
}
.contact-method-text p {
  color: var(--text-muted-dark);
  font-size: 15px;
}
.contact-method-text a:hover {
  color: var(--primary);
}

.map-wrapper {
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-premium);
  border: 1px solid var(--border-light);
  height: 250px;
}
.map-placeholder {
  width: 100%;
  height: 100%;
  border: 0;
}

/* Contact Form */
.contact-form-panel {
  background-color: var(--bg-cream);
  padding: 50px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-premium);
}
.form-title {
  font-size: 24px;
  margin-bottom: 30px;
  position: relative;
  padding-bottom: 10px;
}
.form-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background-color: var(--primary);
}
[dir="rtl"] .form-title::after {
  left: auto;
  right: 0;
}

.form-group {
  margin-bottom: 24px;
}
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-dark);
  text-transform: uppercase;
}
.form-control {
  width: 100%;
  background-color: var(--bg-card-light);
  border: 1px solid var(--border-light);
  padding: 14px 18px;
  font-size: 15px;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
  color: var(--text-dark);
}
.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(176, 141, 79, 0.1);
}
select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23B08D4F'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  background-size: 16px;
  padding-right: 48px;
}
[dir="rtl"] select.form-control {
  background-position: left 18px center;
  padding-right: 18px;
  padding-left: 48px;
}

/* Floating & Sticky CTAs */
.floating-whatsapp {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 999;
  background-color: #25D366;
  color: var(--text-white);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
  transition: var(--transition-smooth);
}
[dir="rtl"] .floating-whatsapp {
  right: auto;
  left: 30px;
}
.floating-whatsapp:hover {
  transform: scale(1.1) translateY(-3px);
  background-color: #20BA5A;
}
.floating-whatsapp svg {
  width: 32px;
  height: 32px;
}

.sticky-mobile-cta {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: rgba(10, 13, 16, 0.9);
  backdrop-filter: blur(10px);
  padding: 12px 24px;
  z-index: 998;
  border-top: 1px solid var(--border-dark);
}

/* ==========================================
   FOOTER
   ========================================== */
.footer {
  background-color: var(--bg-dark);
  color: var(--text-light);
  padding: 80px 0 30px;
  border-top: 1px solid var(--border-dark);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}
.footer-logo-panel .logo {
  font-size: 24px;
  margin-bottom: 20px;
}
.footer-logo-panel p {
  color: var(--text-muted-light);
  font-size: 14px;
  margin-bottom: 24px;
  max-width: 320px;
}
.social-links {
  display: flex;
  gap: 12px;
}
.social-btn {
  width: 36px;
  height: 36px;
  background-color: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted-light);
  transition: var(--transition-smooth);
}
.social-btn:hover {
  background-color: var(--primary);
  border-color: var(--primary);
  color: var(--text-white);
  transform: translateY(-2px);
}
.social-btn svg {
  width: 18px;
  height: 18px;
}

.footer-nav-panel h4,
.footer-contact-panel h4 {
  color: var(--text-white);
  font-size: 18px;
  margin-bottom: 24px;
  position: relative;
  padding-bottom: 8px;
}
.footer-nav-panel h4::after,
.footer-contact-panel h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 30px;
  height: 2px;
  background-color: var(--primary);
}
[dir="rtl"] .footer-nav-panel h4::after,
[dir="rtl"] .footer-contact-panel h4::after {
  left: auto;
  right: 0;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.footer-links a {
  color: var(--text-muted-light);
  font-size: 14px;
}
.footer-links a:hover {
  color: var(--primary);
  padding-inline-start: 6px;
}

.footer-contact-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 14px;
  color: var(--text-muted-light);
}
.footer-contact-item svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 4px;
}
.footer-contact-item a:hover {
  color: var(--primary);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 13px;
  color: var(--text-muted-light);
}

/* ==========================================
   RESPONSIVE MEDIA QUERIES
   ========================================== */

@media (max-width: 1024px) {
  .hero-title {
    font-size: 44px;
  }
  .about-grid {
    grid-template-columns: 1fr;
    gap: 60px;
  }
  .about-visual {
    max-width: 600px;
    margin: 0 auto;
  }
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 50px;
  }
  .footer-grid {
    grid-template-columns: 1.2fr 0.8fr 1fr;
  }
}

@media (max-width: 768px) {
  :root {
    --header-height: 70px;
  }
  
  .header {
    background-color: var(--bg-dark);
    border-bottom: 1px solid var(--border-dark);
  }
  .header .container {
    padding: 0 16px;
  }
  
  .menu-btn {
    display: block;
    z-index: 1001;
  }
  
  .nav-links {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background-color: var(--bg-navy);
    flex-direction: column;
    padding: 50px 24px;
    gap: 24px;
    align-items: center;
    border-top: 1px solid var(--border-dark);
    transform: translateY(-120%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
  }
  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .nav-links a {
    font-size: 18px;
  }
  
  .nav-actions {
    margin-inline-end: 20px;
  }
  
  .hero-title {
    font-size: 34px;
  }
  .hero-subtitle {
    font-size: 16px;
  }
  .hero-ctas {
    flex-direction: column;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }
  
  .about {
    padding: 80px 0;
  }
  .about-text h2 {
    font-size: 32px;
  }
  .about-features {
    grid-template-columns: 1fr;
  }
  .about-badge {
    bottom: -15px;
    right: -15px;
    padding: 20px;
  }
  [dir="rtl"] .about-badge {
    left: -15px;
  }
  .about-badge .number {
    font-size: 36px;
  }
  
  .specializations,
  .projects,
  .gallery-section,
  .stats,
  .contact {
    padding: 80px 0;
  }
  
  .section-header h2 {
    font-size: 28px;
  }
  
  .spec-grid {
    grid-template-columns: 1fr;
  }
  .projects-grid {
    grid-template-columns: 1fr;
  }
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
  }
  .gallery-item-overlay {
    display: none; /* Hide hover details on mobile, use click direct */
  }
  
  .lightbox-btn {
    width: 40px;
    height: 40px;
  }
  .lightbox-prev {
    left: 10px;
  }
  .lightbox-next {
    right: 10px;
  }
  .lightbox-close {
    top: 20px;
    right: 20px;
  }
  [dir="rtl"] .lightbox-close {
    left: 20px;
  }
  
  .contact-form-panel {
    padding: 30px 20px;
  }
  
  .floating-whatsapp {
    bottom: 80px;
    right: 20px;
    width: 50px;
    height: 50px;
  }
  [dir="rtl"] .floating-whatsapp {
    left: 20px;
  }
  .floating-whatsapp svg {
    width: 26px;
    height: 26px;
  }
  
  .sticky-mobile-cta {
    display: flex;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr 1fr;
  }
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================
   WEBGL SPECIAL GRAPHICS & HOVER STYLES
   ========================================== */
#hero-webgl {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

/* Canvas styling for image hover reveal */
.webgl-hover-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.webgl-hover-canvas.active {
  opacity: 1;
}

/* Elevate overlays and badges on top of canvas graphics */
.gallery-item-overlay,
.project-badge {
  z-index: 3 !important;
}

/* ==========================================
   THEME TOGGLE BUTTON STYLING
   ========================================== */
.theme-toggle {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.8);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-smooth);
}
.theme-toggle:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* Sun/Moon SVG Toggle states */
.theme-toggle .sun-icon { display: none !important; }
.theme-toggle .moon-icon { display: block !important; }

body.dark-mode .theme-toggle .sun-icon { display: block !important; color: var(--primary); }
body.dark-mode .theme-toggle .moon-icon { display: none !important; }

/* Scrolled Header Styling in Light Mode */
.header.scrolled {
  background-color: rgba(255, 255, 255, 0.85);
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}
body.dark-mode .header.scrolled {
  background-color: rgba(10, 13, 16, 0.85);
  border-bottom: 1px solid var(--border-dark);
}

.header.scrolled .logo,
.header.scrolled .nav-links a {
  color: var(--text-dark);
}
body.dark-mode .header.scrolled .logo,
body.dark-mode .header.scrolled .nav-links a {
  color: var(--text-white);
}

.header.scrolled .theme-toggle {
  border-color: var(--border-color);
  color: var(--text-dark);
}
body.dark-mode .header.scrolled .theme-toggle {
  border-color: rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.8);
}

.header.scrolled .logo:hover,
.header.scrolled .nav-links a:hover {
  color: var(--primary);
}

/* ==========================================
   HERO TITLE VISIBILITY
   ========================================== */
.hero-title {
  color: var(--text-white) !important;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.8), 0 2px 4px rgba(0, 0, 0, 0.6) !important;
}

/* ==========================================
   HOVER REVEAL IMAGE COMPONENT STYLING
   ========================================== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 columns desktop */
  gap: 24px;
}

@media (max-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 columns tablet */
  }
}

@media (max-width: 600px) {
  .gallery-grid {
    grid-template-columns: 1fr; /* 1 column mobile */
  }
}

.gallery-item {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3; /* Crop to 4:3 aspect ratio */
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  background-color: #0c0f12;
  box-shadow: var(--shadow-premium);
  border: 1px solid var(--border-light);
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.hover-reveal-img-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.7s cubic-bezier(0.25, 1, 0.5, 1), filter 0.7s ease, opacity 0.7s ease;
}

/* Standard Card: Dimmed & desaturated default state */
.gallery-item:not(.before-after) .img-before {
  filter: grayscale(45%) brightness(0.45);
}

/* Before-After Card: Show raw before image at full brightness by default */
.gallery-item.before-after .img-before {
  filter: none; /* Full brightness and color */
  opacity: 1;
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

/* After image loaded but hidden by default (opacity: 0) */
.gallery-item.before-after .img-after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0; /* Hidden by default */
  filter: none;
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 2;
}

/* Dark overlay for standard cards */
.hover-reveal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(10, 13, 16, 0.55); /* 55-65% dark overlay */
  z-index: 1;
  clip-path: inset(0 0 0 0);
  transition: clip-path 0.7s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Hide dark overlay on Before-After cards so the raw before image is fully visible */
.gallery-item.before-after .hover-reveal-overlay {
  display: none !important;
}

/* Glowing sliding golden line separator */
.hover-reveal-img-wrapper::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  height: 100%;
  background: linear-gradient(180deg, transparent 0%, var(--primary) 50%, transparent 100%);
  box-shadow: 0 0 8px var(--primary), 0 0 16px rgba(176, 141, 79, 0.4);
  z-index: 3;
  opacity: 0;
  transition: left 0.7s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.4s ease;
  pointer-events: none;
}

.gallery-item:hover .hover-reveal-img-wrapper::after,
.gallery-item.active .hover-reveal-img-wrapper::after {
  left: 100%;
  opacity: 1;
}

/* Before / After Corner Badge */
.before-after-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background-color: var(--primary);
  color: var(--text-white);
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: var(--radius-sm);
  z-index: 4;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  transition: var(--transition-smooth);
}
[dir="rtl"] .before-after-badge {
  right: auto;
  left: 16px;
}

.gallery-item:hover .before-after-badge,
.gallery-item.active .before-after-badge {
  background-color: var(--bg-navy);
  border: 1px solid var(--primary);
  color: var(--primary-light);
}

/* ==========================================
   REVEAL / HOVER STATES (ARCHITECTURAL WIPE)
   ========================================== */

/* 1. Wipe the dark overlay off to the right for all cards */
.gallery-item:hover .hover-reveal-overlay,
.gallery-item.active .hover-reveal-overlay {
  clip-path: inset(0 0 0 100%);
}

/* 2. Standard Card: Wipe reveals bright, colored image and scale */
.gallery-item:not(.before-after):hover .img-before,
.gallery-item:not(.before-after).active .img-before {
  filter: grayscale(0%) brightness(1);
  transform: scale(1.05);
}

/* 3. Before/After Card: Crossfade reveal opacity */
.gallery-item.before-after:hover .img-before,
.gallery-item.before-after.active .img-before {
  opacity: 0;
  transform: scale(1.05);
}

/* 4. Before/After Card: Show the completed after image */
.gallery-item.before-after:hover .img-after,
.gallery-item.before-after.active .img-after {
  opacity: 1;
  transform: scale(1.05);
}

/* 5. Text details container reveal */
.gallery-item:hover .hover-reveal-content,
.gallery-item.active .hover-reveal-content {
  transform: translateY(0);
  opacity: 1;
}

/* ==========================================
   ACCESSIBILITY & MOTION FALLBACKS
   ========================================= */
@media (prefers-reduced-motion: reduce) {
  .gallery-item img,
  .gallery-item .hover-reveal-content {
    transform: none !important;
    transition: opacity 0.5s ease, filter 0.5s ease !important;
  }
}

/* Fallback transitions when WebGL fails (CORS check) */
.webgl-failed img {
  opacity: 1 !important;
  pointer-events: auto !important;
}
.gallery-item.webgl-failed .hover-reveal-overlay {
  display: block !important;
}


