/* ============================================
   🌾 RESPONSIVE DESIGN - MOBILE FIRST
   Precision Optimized for All Screen Sizes
   ============================================ */

/* ── Max Width: 1200px (Large Tablets / Small Desktops) ── */
@media (max-width: 1200px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
  }

  .footer__top {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
  }

  .team-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .gallery-page-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ── Max Width: 992px (Tablets) ── */
@media (max-width: 992px) {
  .navbar__links {
    display: none !important;
  }

  .navbar__toggle {
    display: flex !important;
  }

  .navbar__mobile-menu {
    display: none;
  }

  .navbar__mobile-menu.open {
    display: flex;
  }

  .about-preview,
  .story-section {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }

  .about-preview__image,
  .story-section__image {
    max-width: 380px;
    margin: 0 auto var(--space-lg);
  }

  .products-grid,
  .products-page-grid,
  .blog-grid,
  .blog-page-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-layout {
    grid-template-columns: 1fr;
  }

  .mv-grid {
    grid-template-columns: 1fr;
  }

  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-page-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-lg);
  }

  #testimonials-grid,
  .testimonials-section .grid-3 {
    grid-template-columns: 1fr;
    max-width: 580px;
    margin-inline: auto;
  }

  .hero__content {
    text-align: center;
    margin-inline: auto;
  }

  .hero__subtitle {
    margin-inline: auto;
  }

  .hero__actions {
    justify-content: center;
  }

  .hero__float-item {
    display: none;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 580px;
    margin: 0 auto;
    gap: var(--space-xl);
  }
}

/* ── Max Width: 768px (Phones & Tablets) ── */
@media (max-width: 768px) {
  :root {
    --navbar-height: 70px;
    --container-padding: 16px;
  }

  .container {
    padding-inline: 16px;
  }

  .navbar {
    height: 70px;
  }

  .navbar__inner {
    padding-inline: 16px;
  }

  .navbar__logo {
    gap: 10px;
    flex-shrink: 0;
    white-space: nowrap;
  }

  .navbar__logo-img {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
  }

  .navbar__logo-text {
    font-size: 1.15rem;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .navbar__actions {
    gap: 8px;
  }

  .navbar__lang-btn {
    padding: 6px 10px;
    font-size: 0.85rem;
  }

  .navbar .theme-toggle {
    padding: 0 !important;
    width: 58px !important;
    height: 30px !important;
    flex-shrink: 0;
  }

  .hero {
    min-height: 100vh;
    min-height: 100dvh;
    padding: calc(var(--navbar-height, 70px) + 12px) 0 24px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
  }

  .hero .container {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
  }

  .hero__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    padding-inline-end: 46px;
    width: 100%;
    max-height: 640px;
    margin-block: auto;
  }

  .hero__badge {
    margin-bottom: 0;
    font-size: 0.9rem;
    padding: 0.35rem 0.95rem;
    display: inline-flex;
    align-self: center;
    margin-inline: auto;
  }

  .hero__title {
    font-size: clamp(1.85rem, 6.8vw, 2.5rem);
    line-height: 1.3;
    margin-bottom: 0;
  }

  .hero__title-main {
    display: block;
    line-height: 1.3;
    overflow-wrap: break-word;
    word-break: normal;
  }

  .hero__title-sub {
    display: block;
    line-height: 1.3;
    margin-top: 6px;
    overflow-wrap: break-word;
    word-break: normal;
  }

  [dir="rtl"] .hero__title-main,
  [dir="rtl"] .hero__title-sub {
    white-space: nowrap;
  }

  .hero__subtitle {
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 0;
    max-width: 580px;
  }

  .hero__arrow {
    display: none;
  }

  .page-hero {
    padding: 110px 0 50px;
  }

  .page-hero--slider {
    min-height: 55vh;
    min-height: 55dvh;
    padding: 120px 0 55px;
  }

  .page-hero__title {
    font-size: clamp(1.75rem, 5.5vw, 2.4rem);
  }

  .page-hero__subtitle {
    font-size: 0.95rem;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .stats-grid {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin: 0 auto;
    gap: 2rem;
  }

  .stat-card {
    padding: 0;
  }

  .products-grid,
  .products-page-grid {
    grid-template-columns: 1fr;
    max-width: 440px;
    margin-inline: auto;
  }

  .gallery-page-grid {
    grid-template-columns: 1fr;
    max-width: 460px;
    margin-inline: auto;
    gap: 20px;
  }

  .gallery-card__image {
    height: 240px;
  }

  .product-card__image {
    height: 230px;
  }

  .blog-grid,
  .blog-page-grid {
    grid-template-columns: 1fr;
    max-width: 440px;
    margin-inline: auto;
  }

  .values-grid {
    grid-template-columns: 1fr;
  }

  #testimonials-grid,
  .testimonials-section .grid-3 {
    grid-template-columns: 1fr !important;
    max-width: 440px;
    margin-inline: auto;
    gap: var(--space-lg);
  }

  .team-grid {
    grid-template-columns: 1fr;
    max-width: 360px;
    margin-inline: auto;
  }

  .about-preview__highlights {
    grid-template-columns: 1fr;
  }

  .footer__top {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
    text-align: center;
  }

  .footer__brand {
    text-align: center;
  }

  .footer__brand .navbar__logo {
    justify-content: center;
  }

  .footer__social {
    justify-content: center;
  }

  .footer__contact-item {
    justify-content: center;
  }

  .footer__bottom {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }

  .filter-bar {
    justify-content: center;
    gap: 8px;
    width: 100%;
  }

  .filter-btn {
    padding: 0.45rem 0.95rem;
    font-size: 0.85rem;
  }

  .search-box {
    width: 100%;
    max-width: 320px;
    margin-inline: auto;
  }

  .hero__scroll-indicator {
    display: flex !important;
    bottom: 8px;
    opacity: 0.7;
    transform: translateX(-50%) scale(0.75);
  }

  .cta-section__inner {
    padding: var(--space-2xl) var(--space-md);
  }

  .lightbox__nav--prev { left: var(--space-xs); }
  .lightbox__nav--next { right: var(--space-xs); }
  .lightbox__close { top: var(--space-sm); right: var(--space-sm); }
  [dir="rtl"] .lightbox__nav--prev { left: auto; right: var(--space-xs); }
  [dir="rtl"] .lightbox__nav--next { right: auto; left: var(--space-xs); }
  [dir="rtl"] .lightbox__close { right: auto; left: var(--space-sm); }
}

/* ── Max Width: 480px (Small Phones) ── */
@media (max-width: 480px) {
  :root {
    --navbar-height: 64px;
  }

  .navbar {
    height: 64px;
  }

  .navbar__logo {
    gap: 8px;
    flex-shrink: 0;
    white-space: nowrap;
  }

  .navbar__logo-img {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
  }

  .navbar__logo-text {
    font-size: 1.05rem;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .hero {
    min-height: 100vh;
    min-height: 100dvh;
    padding: calc(var(--navbar-height, 64px) + 10px) 0 20px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
  }

  .hero .container {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
  }

  .hero__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    padding-inline-end: 42px;
    width: 100%;
    max-height: 600px;
    margin-block: auto;
  }

  .hero__badge {
    margin-bottom: 0;
    font-size: 0.85rem;
    padding: 0.32rem 0.88rem;
    display: inline-flex;
    align-self: center;
    margin-inline: auto;
  }

  .hero__title {
    font-size: clamp(1.75rem, 7.8vw, 2.3rem);
    line-height: 1.28;
    margin-bottom: 0;
  }

  [dir="ltr"] .hero__title {
    font-size: clamp(1.45rem, 6.5vw, 2.05rem);
  }

  .hero__title-main {
    display: block;
    line-height: 1.28;
    overflow-wrap: break-word;
    word-break: normal;
  }

  .hero__title-sub {
    display: block;
    line-height: 1.28;
    margin-top: 5px;
    overflow-wrap: break-word;
    word-break: normal;
  }

  [dir="rtl"] .hero__title-main,
  [dir="rtl"] .hero__title-sub {
    white-space: nowrap;
  }

  .hero__subtitle {
    font-size: 0.96rem;
    line-height: 1.65;
    margin-bottom: 0;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .hero__actions {
    flex-direction: column;
    width: 100%;
    gap: 10px;
    margin-bottom: 0;
  }

  .hero__actions .btn {
    width: 100%;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .btn--lg {
    padding: 0.8rem 1.5rem;
    font-size: 0.98rem;
  }

  .filter-bar {
    gap: 6px;
  }

  .filter-btn {
    padding: 0.4rem 0.85rem;
    font-size: 0.8rem;
  }

  .contact-form-card {
    padding: var(--space-md);
  }

  .section-header {
    margin-bottom: var(--space-xl);
  }

  .section-header h2 {
    font-size: 1.75rem;
  }
}

/* ── Floating Side Socials Responsive ── */
@media (max-width: 768px) {
  .side-socials {
    top: calc(var(--navbar-height, 64px) + 12px);
    right: 12px;
    left: auto;
    padding: 0 !important;
    gap: 7px;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }

  [dir="rtl"] .side-socials {
    right: auto !important;
    left: 12px !important;
  }

  .side-socials__link {
    width: 34px;
    height: 34px;
  }

  .side-socials__link svg {
    width: 15px;
    height: 15px;
  }

  .side-socials__tooltip {
    display: none !important;
  }
}

@media (max-width: 360px) {
  .navbar__logo {
    gap: 6px;
    flex-shrink: 0;
    white-space: nowrap;
  }

  .navbar__logo-img {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
  }

  .navbar__logo-text {
    font-size: 0.95rem;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .hero {
    min-height: 100vh;
    min-height: 100dvh;
    padding: calc(var(--navbar-height, 64px) + 8px) 0 16px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
  }

  .hero .container {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
  }

  .hero__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    padding-inline-end: 38px;
    width: 100%;
    max-height: 560px;
    margin-block: auto;
  }

  .hero__badge {
    margin-bottom: 0;
    font-size: 0.8rem;
    padding: 0.28rem 0.76rem;
    display: inline-flex;
    align-self: center;
    margin-inline: auto;
  }

  .hero__title {
    font-size: clamp(1.45rem, 6.8vw, 1.85rem);
    line-height: 1.25;
    margin-bottom: 0;
  }

  [dir="ltr"] .hero__title {
    font-size: clamp(1.25rem, 5.8vw, 1.65rem);
  }

  .hero__title-main {
    line-height: 1.25;
    overflow-wrap: break-word;
    word-break: normal;
  }

  .hero__title-sub {
    line-height: 1.25;
    margin-top: 4px;
    overflow-wrap: break-word;
    word-break: normal;
  }

  [dir="rtl"] .hero__title-main,
  [dir="rtl"] .hero__title-sub {
    white-space: nowrap;
  }

  .hero__subtitle {
    font-size: 0.88rem;
    line-height: 1.55;
    margin-bottom: 0;
  }

  .hero__actions {
    gap: 8px;
    margin-bottom: 0;
  }

  .hero__actions .btn {
    min-height: 44px;
  }
}

@media (max-width: 480px) {
  .side-socials {
    top: calc(var(--navbar-height, 64px) + 10px);
    right: 8px;
    left: auto;
    padding: 0 !important;
    gap: 6px;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }

  [dir="rtl"] .side-socials {
    right: auto !important;
    left: 8px !important;
  }

  .side-socials__link {
    width: 30px;
    height: 30px;
  }

  .side-socials__link svg {
    width: 13px;
    height: 13px;
  }
}
