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

/* ==========================================================================
   Wiby Agency - Premium Design System & Typography
   Coolors Palette: #011826 - #083540 - #0e5259 - #1c8c81 - #0d0d0d
   ========================================================================== */

@font-face {
  font-family: 'IRANSans';
  src: url('/assets/fonts/IRANSans.woff2') format('woff2'),
       url('/assets/fonts/IRANSans.woff') format('woff'),
       url('/assets/fonts/IRANSans.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'IRANSans';
  src: url('/assets/fonts/IRANSansBold.woff2') format('woff2'),
       url('/assets/fonts/IRANSansBold.woff') format('woff'),
       url('/assets/fonts/IRANSansBold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Brand Color Palette */
  --bg-primary: #011826;
  --bg-secondary: #083540;
  --bg-glass: rgba(8, 53, 64, 0.65);
  --border-teal: #0e5259;
  --accent-teal: #1c8c81;
  --accent-glow: rgba(28, 140, 129, 0.45);
  --black-deep: #0d0d0d;
  
  /* Text & Neutrals */
  --text-light: #ffffff;
  --text-muted: #94a3b8;
  --text-dark: #0f172a;
  
  /* Layout & Transitions */
  --font-en: 'Outfit', 'Inter', sans-serif;
  --font-fa: 'IRANSans', sans-serif;
  --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  --radius-lg: 20px;
  --radius-md: 12px;
  --radius-sm: 8px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-primary);
  color: var(--text-light);
}

body {
  font-family: var(--font-en);
  line-height: 1.6;
  overflow-x: hidden;
  background: radial-gradient(circle at 15% 15%, #083540 0%, #011826 60%, #0d0d0d 100%);
  min-height: 100vh;
  position: relative;
}

/* RTL Override for Persian - Enforce IRANSans on 100% of DOM elements */
html[dir="rtl"],
html[dir="rtl"] *,
html[dir="rtl"] body,
html[dir="rtl"] button,
html[dir="rtl"] input,
html[dir="rtl"] select,
html[dir="rtl"] textarea,
html[dir="rtl"] a,
html[dir="rtl"] span,
html[dir="rtl"] div,
html[dir="rtl"] label,
html[dir="rtl"] li,
html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] h4,
html[dir="rtl"] h5,
html[dir="rtl"] h6,
html[dir="rtl"] p {
  font-family: 'IRANSans', sans-serif !important;
}

html[dir="rtl"], html[dir="rtl"] * {
  letter-spacing: normal !important;
}

html[dir="rtl"] .sheet-link span:last-child {
  display: inline-block;
  transform: scaleX(-1);
}

html[dir="rtl"] body {
  text-align: right;
}

html[dir="rtl"] .nav-links {
  direction: rtl;
  gap: 1.25rem;
  flex-wrap: nowrap !important;
}
html[dir="rtl"] .nav-link {
  font-size: 0.93rem;
  white-space: nowrap !important;
}

html[dir="rtl"] .calc-options {
  direction: rtl;
}

/* ==========================================================================
   Background Ambient Lighting & Glassmorphism
   ========================================================================== */
.ambient-glow {
  position: fixed;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(28, 140, 129, 0.18) 0%, rgba(1, 24, 38, 0) 70%);
  filter: blur(80px);
  z-index: -1;
  pointer-events: none;
}
.glow-1 { top: -10%; left: -10%; }
.glow-2 { bottom: 10%; right: -10%; background: radial-gradient(circle, rgba(14, 82, 89, 0.25) 0%, rgba(1, 24, 38, 0) 70%); }

.glass-card {
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(28, 140, 129, 0.2);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.glass-card:hover {
  transform: translateY(-8px);
  border-color: var(--accent-teal);
  box-shadow: 0 15px 35px rgba(1, 24, 38, 0.8), 0 0 25px var(--accent-glow);
}

/* ==========================================================================
   Typography & Utility Classes
   ========================================================================== */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 2;
}

.text-gradient {
  background: linear-gradient(135deg, #ffffff 0%, var(--accent-teal) 50%, #48e5d4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(28, 140, 129, 0.15);
  border: 1px solid var(--accent-teal);
  color: #48e5d4;
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  box-shadow: 0 0 15px rgba(28, 140, 129, 0.2);
}

html[dir="rtl"] .section-badge {
  letter-spacing: 0;
}

.section {
  padding: 7rem 0;
  position: relative;
}

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 4rem auto;
}

.section-title {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1rem;
  letter-spacing: -0.5px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.2rem;
  line-height: 1.7;
}

/* ==========================================================================
   Buttons & Interactive Elements
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem 2rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  outline: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-teal) 0%, #156d64 100%);
  color: #ffffff;
  box-shadow: 0 4px 20px rgba(28, 140, 129, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(28, 140, 129, 0.7);
  background: linear-gradient(135deg, #23ab9d 0%, var(--accent-teal) 100%);
}

.btn-secondary {
  background: rgba(14, 82, 89, 0.3);
  color: var(--text-light);
  border: 1px solid var(--border-teal);
}

.btn-secondary:hover {
  background: rgba(28, 140, 129, 0.25);
  border-color: var(--accent-teal);
  transform: translateY(-2px);
}

/* ==========================================================================
   Navigation Bar
   ========================================================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background: rgba(1, 24, 38, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(14, 82, 89, 0.4);
  transition: var(--transition);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 85px;
  width: 98%;
  max-width: 1750px;
  margin: 0 auto;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  text-decoration: none;
  color: var(--text-light);
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -0.5px;
  margin-right: 3rem;
  flex-shrink: 0;
}

html[dir="rtl"] .nav-brand {
  margin-right: 0;
  margin-left: 3rem;
}

.nav-logo-img {
  height: 46px;
  width: auto;
  object-fit: contain;
}

.nav-links {
  display: flex !important;
  list-style: none;
  gap: 1.5rem;
  align-items: center;
  white-space: nowrap !important;
  flex-wrap: nowrap !important;
}

.nav-link {
  color: var(--text-light);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.96rem;
  transition: var(--transition);
  opacity: 0.88;
  padding: 0.4rem 0.5rem;
  white-space: nowrap !important;
}

.nav-link:hover, .nav-link.active {
  color: #48e5d4;
  opacity: 1;
  text-shadow: 0 0 10px rgba(72, 229, 212, 0.5);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.lang-toggle {
  background: rgba(14, 82, 89, 0.4);
  border: 1px solid var(--border-teal);
  color: #ffffff;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.95rem;
}

.lang-toggle:hover {
  background: var(--accent-teal);
  border-color: #48e5d4;
  box-shadow: 0 0 15px var(--accent-glow);
}

.mobile-toggle {
  display: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: var(--text-light);
}

/* ==========================================================================
   Hero Section & 3D Canvas
   ========================================================================== */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 100px;
  position: relative;
}

#three-canvas-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

.hero-content {
  max-width: 800px;
  position: relative;
  z-index: 2;
  padding: 3rem 0;
}

.hero-title {
  font-size: 4.2rem;
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 1.5rem;
  letter-spacing: -1px;
}

html[dir="rtl"] .hero-title {
  font-size: 3.5rem;
  line-height: 1.3;
}

.hero-description {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  max-width: 700px;
  line-height: 1.8;
}

.hero-cta-group {
  display: flex;
  gap: 1.2rem;
  flex-wrap: wrap;
  margin-bottom: 4rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  padding-top: 2.5rem;
  border-top: 1px solid rgba(14, 82, 89, 0.5);
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  color: #48e5d4;
  line-height: 1.1;
  margin-bottom: 0.3rem;
  text-shadow: 0 0 20px rgba(28, 140, 129, 0.5);
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ==========================================================================
   Grids & Card Components
   ========================================================================== */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
@media (min-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

.card-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(28, 140, 129, 0.2) 0%, rgba(8, 53, 64, 0.4) 100%);
  border: 1px solid var(--accent-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 0 20px rgba(28, 140, 129, 0.2);
}

.glass-card h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-light);
}

.glass-card p {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  font-size: 0.98rem;
  line-height: 1.7;
}

.card-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  border-top: 1px solid rgba(14, 82, 89, 0.4);
  padding-top: 1.2rem;
}

.card-features li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: #d1d5db;
  font-size: 0.9rem;
}

.card-features li::before {
  content: "✓";
  color: #48e5d4;
  font-weight: 800;
}

/* ==========================================================================
   Interactive Cost Estimator Component
   ========================================================================== */
.calculator-box {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-teal);
  border-radius: var(--radius-lg);
  padding: 3.5rem;
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 3.5rem;
  box-shadow: 0 25px 50px rgba(1, 24, 38, 0.8);
}

.calc-group {
  margin-bottom: 2.5rem;
}

.calc-label {
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--text-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.calc-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.calc-btn {
  background: rgba(1, 24, 38, 0.6);
  border: 1px solid var(--border-teal);
  color: var(--text-muted);
  padding: 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.calc-btn:hover, .calc-btn.active {
  background: rgba(28, 140, 129, 0.25);
  border-color: var(--accent-teal);
  color: #ffffff;
  box-shadow: 0 0 20px var(--accent-glow);
  transform: translateY(-2px);
}

input[type="range"] {
  width: 100%;
  height: 8px;
  background: rgba(14, 82, 89, 0.6);
  border-radius: 5px;
  outline: none;
  -webkit-appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #48e5d4;
  cursor: pointer;
  box-shadow: 0 0 15px rgba(28, 140, 129, 0.8);
  transition: var(--transition);
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.calc-summary {
  background: rgba(1, 24, 38, 0.9);
  border: 1px solid var(--accent-teal);
  border-radius: var(--radius-md);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  box-shadow: inset 0 0 30px rgba(28, 140, 129, 0.15);
}

.estimated-price {
  font-size: 3.5rem;
  font-weight: 900;
  color: #48e5d4;
  margin: 1rem 0 0.5rem 0;
  text-shadow: 0 0 25px rgba(28, 140, 129, 0.6);
}

/* ==========================================================================
   Contact Form Section
   ========================================================================== */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  height: 100%;
  justify-content: space-between;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  text-align: left;
  width: 100%;
}

html[dir="rtl"] .form-group {
  text-align: right;
}

.form-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-light);
}

.form-input, .form-textarea, .form-select {
  background: rgba(1, 24, 38, 0.7);
  border: 1px solid var(--border-teal);
  border-radius: var(--radius-sm);
  padding: 1rem 1.2rem;
  color: var(--text-light);
  font-family: inherit;
  font-size: 1rem;
  transition: var(--transition);
  outline: none;
  width: 100%;
  box-sizing: border-box;
}

.form-input, .form-select {
  height: 58px;
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  border-color: var(--accent-teal);
  box-shadow: 0 0 15px var(--accent-glow);
  background: rgba(8, 53, 64, 0.8);
}

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

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  background: #000b12;
  border-top: 1px solid var(--border-teal);
  padding: 4rem 0 2rem 0;
  margin-top: 4rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 3rem;
}

.footer-bottom {
  border-top: 1px solid rgba(14, 82, 89, 0.3);
  padding-top: 2rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ==========================================================================
   Responsive Breakpoints & Modern Mobile Floating Dock
   ========================================================================== */
@media (max-width: 1250px) {
  .nav-links {
    gap: 0.8rem !important;
  }
  .nav-link {
    font-size: 0.88rem !important;
    padding: 0.3rem 0.3rem !important;
  }
  .nav-brand {
    margin-right: 1rem !important;
  }
  html[dir="rtl"] .nav-brand {
    margin-left: 1rem !important;
  }
}

@media (max-width: 1024px) {
  .calculator-box {
    grid-template-columns: 1fr;
    padding: 2rem;
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .nav-links, .mobile-toggle, .lang-toggle, .flag-btn, .nav-actions {
    display: none !important;
  }
  .mobile-dock {
    display: flex !important;
  }
  .navbar {
    height: 75px;
  }
  .nav-brand {
    margin-right: 0 !important;
  }
  html[dir="rtl"] .nav-brand {
    margin-left: 0 !important;
  }
  .hero-title {
    font-size: 2.8rem;
  }
  html[dir="rtl"] .hero-title {
    font-size: 2.5rem !important;
    line-height: 1.35 !important;
  }
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
  .hero-stats {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .calc-options {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Modern Bottom Floating Action Dock & Slide-Up Sheet (Mobile / Tablet)
   ========================================================================== */
.mobile-dock {
  display: none;
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 92%;
  max-width: 480px;
  background: rgba(8, 53, 64, 0.92);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(72, 229, 212, 0.4);
  border-radius: 50px;
  padding: 0.6rem 1.2rem;
  z-index: 9999;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 20px rgba(72, 229, 212, 0.2);
  justify-content: space-around;
  align-items: center;
}

.dock-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  color: #e2e8f0;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  background: transparent;
  border: none;
  transition: all 0.25s ease;
  padding: 0.3rem 0.6rem;
  border-radius: 12px;
}

.dock-item span.dock-icon {
  font-size: 1.3rem;
}

.dock-item:hover, .dock-item.active {
  color: #48e5d4;
  transform: translateY(-3px);
}

/* Slide-up Glassmorphic Modal Sheet */
.mobile-sheet-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(1, 24, 38, 0.85);
  backdrop-filter: blur(10px);
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mobile-sheet-overlay.active {
  display: block;
  opacity: 1;
}

.mobile-sheet-modal {
  position: absolute;
  bottom: -100%;
  left: 0;
  width: 100%;
  background: radial-gradient(circle at 50% 0%, #0e5259 0%, #011826 80%);
  border-top: 1px solid #48e5d4;
  border-radius: 30px 30px 0 0;
  padding: 2.5rem 2rem 5rem 2rem;
  transition: bottom 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.9);
  max-height: 85vh;
  overflow-y: auto;
}

.mobile-sheet-overlay.active .mobile-sheet-modal {
  bottom: 0;
}

.sheet-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(72, 229, 212, 0.2);
}

.sheet-close-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sheet-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.sheet-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.2rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  color: #fff;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 600;
  transition: all 0.2s ease;
}

.sheet-link:hover {
  background: rgba(72, 229, 212, 0.15);
  border-color: #48e5d4;
  color: #48e5d4;
  transform: translateX(6px);
}

html[dir="rtl"] .sheet-link:hover {
  transform: translateX(-6px);
}

/* ==========================================================================
   Super Deluxe Trending Micro-interactions & Movie-Like Section Animations
   ========================================================================== */
.reveal-item {
  opacity: 0;
  transform: translateY(40px) scale(0.97);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal-item.revealed {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Flag Icon Language Switcher Button */
.flag-btn {
  font-size: 1.4rem;
  padding: 0.4rem 0.8rem;
  border-radius: 50px;
  background: rgba(28, 140, 129, 0.2);
  border: 1px solid var(--accent-teal);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 15px rgba(72, 229, 212, 0.2);
}

.flag-btn:hover {
  transform: scale(1.1) rotate(5deg);
  background: rgba(28, 140, 129, 0.4);
  box-shadow: 0 0 25px rgba(72, 229, 212, 0.5);
  border-color: #48e5d4;
}

/* ==========================================================================
   Cinematic 3D Particle Intro & Warp Drive
   ========================================================================== */
#cinematic-intro {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at center, #011d2e 0%, #010e17 100%);
  z-index: 100000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

#intro-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

#intro-content-box {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transform-style: preserve-3d;
}

#intro-logo-img {
  height: 90px;
  margin-bottom: 1.5rem;
  filter: drop-shadow(0 0 30px rgba(72, 229, 212, 0.8));
  animation: introLogoFloat 4s infinite ease-in-out;
}

#intro-status {
  color: #48e5d4;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 2rem;
  text-shadow: 0 0 10px rgba(72, 229, 212, 0.5);
}

.intro-progress-container {
  width: 300px;
  max-width: 80vw;
  height: 6px;
  background: rgba(14, 82, 89, 0.3);
  border: 1px solid rgba(72, 229, 212, 0.4);
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.8), inset 0 0 8px rgba(0, 0, 0, 0.5);
}

.intro-progress-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #1c8c81 0%, #48e5d4 50%, #ffd700 100%);
  border-radius: 10px;
  transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 15px #48e5d4;
}

@keyframes introLogoFloat {
  0%, 100% { transform: translateY(0) scale(1); filter: drop-shadow(0 0 25px rgba(72, 229, 212, 0.6)); }
  50% { transform: translateY(-10px) scale(1.03); filter: drop-shadow(0 0 40px rgba(72, 229, 212, 0.9)); }
}

/* ==========================================================================
   Staggered Cascading Entrance Animations (Triggered on body.intro-completed)
   ========================================================================== */
body:not(.intro-completed) .header {
  opacity: 0;
  transform: translateY(-60px);
}

body:not(.intro-completed) .hero-content {
  opacity: 0;
  transform: translateY(40px) scale(0.95);
}

body:not(.intro-completed) .hero-visual {
  opacity: 0;
  transform: scale(0.8);
}

body.intro-completed .header {
  animation: headerCascadeDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

body.intro-completed .nav-brand {
  opacity: 0;
  animation: slideInLeft 0.8s 0.1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

body.intro-completed .nav-links li {
  opacity: 0;
  animation: navLinkCascade 0.6s calc(0.2s + var(--idx, 1) * 0.08s) cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

body.intro-completed .nav-actions {
  opacity: 0;
  animation: slideInRight 0.8s 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

body.intro-completed .hero-content {
  opacity: 0;
  animation: heroContentReveal 1s 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

body.intro-completed .hero-visual {
  opacity: 0;
  animation: heroVisualReveal 1.2s 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(-40px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(40px); }
  to { opacity: 1; transform: translateX(0); }
}

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

@keyframes heroContentReveal {
  from { opacity: 0; transform: translateY(40px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes heroVisualReveal {
  from { opacity: 0; transform: scale(0.8) rotateZ(-5deg); }
  to { opacity: 1; transform: scale(1) rotateZ(0); }
}

/* Portfolio Interactive Carousel Slider */
#projects .container {
  max-width: 1440px !important;
}

.portfolio-carousel-wrapper {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 1.5rem 0;
}

.portfolio-carousel {
  display: flex;
  gap: 1.5rem;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.portfolio-slide {
  flex: 0 0 calc((100% - 3rem) / 3);
  max-width: calc((100% - 3rem) / 3);
  display: flex;
  flex-direction: column;
}

/* Enlarge client favicon icons inside featured carousel */
.portfolio-slide .client-icon {
  width: 64px !important;
  height: 64px !important;
  border-radius: 16px !important;
  padding: 8px !important;
  background: rgba(255, 255, 255, 0.15) !important;
  box-shadow: 0 0 20px rgba(72, 229, 212, 0.4) !important;
}

@media (max-width: 1024px) {
  .portfolio-slide {
    flex: 0 0 calc((100% - 1.5rem) / 2);
    max-width: calc((100% - 1.5rem) / 2);
  }
}

@media (max-width: 768px) {
  .portfolio-slide {
    flex: 0 0 100%;
    max-width: 100%;
  }
  .container {
    padding: 0 1.25rem !important;
  }
  .section {
    padding: 4.5rem 0 !important;
  }
  .hero-section {
    padding-top: 6.5rem !important;
    padding-bottom: 3.5rem !important;
  }
  .hero-title {
    font-size: 2.2rem !important;
    line-height: 1.25 !important;
  }
  html[dir="rtl"] .hero-title {
    font-size: 2rem !important;
    line-height: 1.35 !important;
  }
  .section-title {
    font-size: 1.85rem !important;
  }
  html[dir="rtl"] .section-title {
    font-size: 1.75rem !important;
  }
  .hero-description, .section-subtitle {
    font-size: 1rem !important;
    line-height: 1.7 !important;
  }
  .hero-cta-group {
    flex-direction: column !important;
    width: 100% !important;
    gap: 0.85rem !important;
    margin-bottom: 2.5rem !important;
  }
  .hero-cta-group .btn, .section .btn, .glass-card .btn {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0.85rem 1.2rem !important;
    font-size: 0.95rem !important;
    white-space: normal !important;
    text-align: center !important;
    line-height: 1.4 !important;
    justify-content: center !important;
  }
  .stat-number {
    font-size: 2rem !important;
  }
  .glass-card {
    padding: 1.5rem !important;
  }
  .form-group {
    width: 100% !important;
  }
}

.carousel-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(14, 82, 89, 0.8);
  border: 1px solid #48e5d4;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.carousel-nav-btn:hover {
  background: #48e5d4;
  color: #011826;
  transform: translateY(-50%) scale(1.1);
}

.carousel-prev { left: 10px; }
.carousel-next { right: 10px; }

/* Interactive Social SVG Vector Icons */
.social-icons-grid {
  display: flex;
  gap: 1.2rem;
  align-items: center;
  margin-top: 1.5rem;
}

.social-icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(72, 229, 212, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #48e5d4;
  transition: all 0.3s ease;
}

.social-icon-btn:hover {
  background: #48e5d4;
  color: #011826;
  transform: translateY(-4px) rotate(8deg);
  box-shadow: 0 0 20px rgba(72, 229, 212, 0.6);
}

