/* ==========================================
   HEADER & NAVBAR
   Mobile-First + RTL
   ========================================== */

.site-header {
  background-color: var(--surface-color, #fff);
  border-bottom: 1px solid var(--border-color, #e5e7eb);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgb(0 0 0 / 3%);
  width: 100%;
}

.header-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.75rem 1rem;

  display: flex;
  align-items: center;
  justify-content: space-between;

  direction: rtl;
  position: relative;
}

/* ==========================================
   LOGO
   ========================================== */

.logo-container {
  display: block;
  flex-shrink: 0;
}

.logo-container img {
  height: 42px;
  width: auto;
  display: block;
  object-fit: contain;
}

/* ==========================================
   MOBILE MENU BUTTON
   حالت پایه = موبایل
   ========================================== */

.menu-toggle {
  display: flex;

  align-items: center;
  justify-content: center;

  background: transparent;
  border: none;

  font-size: 1.5rem;
  color: var(--text-color, #1f2937);

  cursor: pointer;

  padding: 0.4rem;

  transition:
    transform 0.2s ease,
    color 0.2s ease;
}

.menu-toggle:hover {
  color: var(--primary-color, #2563eb);
}

.menu-toggle:active {
  transform: scale(0.9);
}

/* ==========================================
   MOBILE NAVIGATION
   حالت پایه = موبایل
   ========================================== */

.main-nav {
  position: absolute;

  top: 100%;
  right: 0;
  left: 0;

  width: 100%;

  background-color: var(--surface-color, #fff);

  border-bottom: 1px solid var(--border-color, #e5e7eb);

  box-shadow: 0 10px 25px -5px rgb(0 0 0 / 10%);

  max-height: 0;
  overflow: hidden;

  transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  flex-direction: column;
  align-items: stretch;
}

/* منوی باز شده توسط JavaScript */

.main-nav.active {
  max-height: 500px;
}

/* ==========================================
   NAV LIST - MOBILE
   ========================================== */

.nav-list {
  list-style: none;

  display: flex;
  flex-direction: column;
  align-items: stretch;

  gap: 0.25rem;

  margin: 0;
  padding: 1rem;
}

/* ==========================================
   NAV LINKS - MOBILE
   ========================================== */

.nav-link {
  display: flex;
  align-items: center;

  gap: 0.75rem;

  padding: 0.75rem 1rem;

  color: var(--text-color, #4b5563);

  text-decoration: none;

  font-weight: 500;
  font-size: 0.9rem;

  border-radius: 8px;

  transition:
    background-color 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease;
}

.nav-link i {
  font-size: 1rem;

  color: var(--text-muted, #6b7280);

  transition: color 0.2s ease;

  width: 20px;
  text-align: center;
}

/* Hover */

.nav-link:hover {
  background-color: rgb(37 99 235 / 6%);
  color: var(--primary-color, #2563eb);
}

.nav-link:hover i {
  color: var(--primary-color, #2563eb);
}

/* Active - Mobile */

.nav-link.active {
  background-color: rgb(37 99 235 / 8%);

  color: var(--primary-color, #2563eb);

  font-weight: 600;

  border-right: 4px solid var(--primary-color, #2563eb);

  border-radius: 4px 8px 8px 4px;
}

.nav-link.active i {
  color: var(--primary-color, #2563eb);
}

/* ==========================================
   TABLET
   640px به بالا
   ========================================== */

@media (width >= 640px) {
  .header-container {
    padding-inline: 1.25rem;
  }

  .nav-link {
    font-size: 0.92rem;
  }
}

/* ==========================================
   DESKTOP
   993px به بالا
   ========================================== */

@media (width >= 993px) {
  /* ------------------------------
     Header
     ------------------------------ */

  .header-container {
    padding: 0.35rem 0.65rem;
  }

  /* ------------------------------
     Logo
     ------------------------------ */

  .logo-container img {
    height: 36px;
  }

  /* ------------------------------
     Hamburger
     در دسکتاپ کاملاً مخفی
     ------------------------------ */

  .menu-toggle {
    display: none;
  }

  /* ------------------------------
     Main Navigation
     بازگشت به حالت دسکتاپ
     ------------------------------ */

  .main-nav {
    position: static;

    width: auto;

    display: flex;
    flex-direction: row;
    align-items: center;

    background: transparent;

    border: none;
    box-shadow: none;

    max-height: none;
    overflow: visible;
  }

  /* ------------------------------
     Navigation List
     ------------------------------ */

  .nav-list {
    display: flex;
    flex-direction: row;
    align-items: center;

    gap: 0.05rem;

    margin: 0;
    padding: 0;
  }

  /* ------------------------------
     Navigation Links
     ------------------------------ */

  .nav-link {
    display: flex;
    align-items: center;

    gap: 0.3rem;

    padding: 0.35rem 0.45rem;

    font-size: 0.82rem;

    border-radius: 5px;

    white-space: nowrap;

    border-right: none;
  }

  /* ------------------------------
     Icons
     ------------------------------ */

  .nav-link i {
    font-size: 0.9rem;

    width: auto;
  }

  /* ------------------------------
     Active Desktop
     ------------------------------ */

  .nav-link.active {
    background-color: rgb(37 99 235 / 8%);

    color: var(--primary-color, #2563eb);

    border-right: none;

    border-bottom: 2px solid var(--primary-color, #2563eb);

    border-radius: 5px 5px 0 0;
  }
}

/* ==========================================
   FOOTER
   Mobile-First
   ========================================== */

.site-footer {
  background: linear-gradient(180deg, #0f172a 0%, #020617 100%);

  color: #f8fafc;

  padding: 3rem 1rem 1.5rem;

  margin-top: auto;

  position: relative;

  border-top: 1px solid rgb(255 255 255 / 8%);
}

/* ==========================================
   FOOTER CONTAINER
   ========================================== */

.footer-container {
  width: 100%;
  max-width: 1200px;

  margin: 0 auto;

  display: flex;
  flex-direction: column;

  align-items: center;

  gap: 2rem;
}

/* ==========================================
   FOOTER BRAND
   ========================================== */

.footer-brand {
  text-align: center;
}

.footer-brand h3 {
  font-size: 1.1rem;
  font-weight: 700;

  color: #fff;

  margin: 0 0 0.5rem;
}

.footer-brand p {
  color: #94a3b8;

  font-size: 0.88rem;

  margin: 0;
}

/* ==========================================
   PHONE CARDS
   Mobile = یک ستون
   ========================================== */

.footer-phones {
  display: grid;

  grid-template-columns: 1fr;

  gap: 0.85rem;

  width: 100%;
  max-width: 480px;
}

.phone-card {
  display: flex;

  align-items: center;
  justify-content: space-between;

  background: rgb(255 255 255 / 3%);

  border: 1px solid rgb(255 255 255 / 8%);

  padding: 0.85rem 1rem;

  border-radius: 12px;

  text-decoration: none;

  color: #f1f5f9;

  transition:
    background-color 0.25s ease,
    border-color 0.25s ease,
    transform 0.25s ease;
}

.phone-card:hover {
  background: rgb(37 99 235 / 15%);

  border-color: var(--primary-color, #2563eb);

  transform: translateY(-2px);
}

.phone-info {
  display: flex;

  align-items: center;

  gap: 0.85rem;

  min-width: 0;
}

.phone-icon-box {
  width: 36px;
  height: 36px;

  flex-shrink: 0;

  border-radius: 8px;

  background: rgb(37 99 235 / 20%);

  color: #60a5fa;

  display: flex;

  align-items: center;
  justify-content: center;

  font-size: 1rem;
}

.phone-label {
  display: flex;

  flex-direction: column;

  text-align: right;

  min-width: 0;
}

.phone-label span {
  font-size: 0.75rem;

  color: #94a3b8;
}

.phone-number {
  direction: ltr;

  font-family: monospace, sans-serif;

  font-weight: 700;

  font-size: 0.95rem;

  letter-spacing: 0.5px;

  white-space: nowrap;
}

/* ==========================================
   SOCIAL MEDIA
   ========================================== */

.social-section {
  display: flex;

  flex-direction: column;

  align-items: center;

  gap: 0.85rem;
}

.social-title {
  font-size: 0.85rem;

  color: #94a3b8;

  text-align: center;
}

.social-links {
  display: flex;

  gap: 1rem;

  align-items: center;
}

.social-icon-btn {
  width: 44px;
  height: 44px;

  border-radius: 12px;

  background: rgb(255 255 255 / 5%);

  border: 1px solid rgb(255 255 255 / 10%);

  display: flex;

  align-items: center;
  justify-content: center;

  transition:
    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    background-color 0.3s ease,
    box-shadow 0.3s ease;

  padding: 9px;
}

.social-icon-btn img {
  width: 100%;
  height: 100%;

  object-fit: contain;

  filter: brightness(0) invert(1);

  transition:
    transform 0.2s ease,
    filter 0.2s ease;
}

.social-icon-btn:hover img {
  transform: scale(1.1);
}

.social-icon-btn:hover {
  transform: translateY(-4px) scale(1.05);

  background: rgb(255 255 255 / 12%);

  box-shadow: 0 8px 20px rgb(0 0 0 / 30%);
}

/* ==========================================
   FOOTER DIVIDER
   ========================================== */

.footer-divider {
  width: 100%;
  height: 1px;

  background: linear-gradient(
    90deg,
    transparent,
    rgb(255 255 255 / 10%),
    transparent
  );

  margin: 0.5rem 0;
}

/* ==========================================
   COPYRIGHT
   ========================================== */

.copyright {
  font-size: 0.8rem;

  color: #64748b;

  text-align: center;

  margin: 0;
}

/* ==========================================
   TABLET FOOTER
   ========================================== */

@media (width >= 640px) {
  .site-footer {
    padding-inline: 1.25rem;
  }

  .footer-phones {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================
   DESKTOP FOOTER
   ========================================== */

@media (width >= 993px) {
  .footer-container {
    gap: 2rem;
  }
}
