/* =========================================
   RESPONSIVE.CSS — centralized width-based overrides
   QUWMA
   ========================================= */

/* =========================================
   <= 991.98px
   tablets + mobile
   ========================================= */
@media (max-width: 991.98px) {
  /* =========================
     NAVBAR
     ========================= */
  .quwma-navbar {
    padding: 0.6rem 0;
  }

  .quwma-navbar .container {
    align-items: center;
  }

  .quwma-navbar .navbar-brand {
    max-width: calc(100% - 64px);
  }

  .quwma-navbar .navbar-logo {
    height: 42px;
  }

  .quwma-navbar .brand-text {
    font-size: 1rem;
    letter-spacing: 0.06em;
  }

  .quwma-navbar .brand-sub {
    display: none;
  }

  .quwma-navbar .navbar-collapse {
    margin-top: 0.8rem;
    padding: 0.9rem 1rem 1rem;
    border-radius: 18px;
    background: rgba(74, 190, 112, 0.98);
    border: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow: 0 14px 34px rgba(2, 6, 23, 0.14);
  }

  .quwma-navbar .navbar-nav {
    align-items: stretch;
    gap: 0.4rem;
    padding-top: 0;
    width: 100%;
  }

  .quwma-navbar .nav-item {
    width: 100%;
  }

  .quwma-navbar .nav-link {
    display: block;
    width: 100%;
    padding: 0.7rem 0;
    white-space: normal;
    line-height: 1.35;
  }

  .quwma-navbar .nav-link::after {
    display: none;
  }

  .quwma-navbar .nav-item.dropdown.nav-services {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 0.4rem;
    width: 100%;
  }

  .quwma-navbar .nav-item.dropdown.nav-services > .nav-services-link {
    min-width: 0;
    white-space: normal;
  }

  .quwma-navbar .nav-services-toggle {
    justify-self: end;
    padding: 0.35rem 0.5rem;
  }

  .quwma-navbar .dropdown-menu.quwma-dropdown {
    position: static !important;
    transform: none !important;
    inset: auto !important;
    width: 100%;
    min-width: 100%;
    margin-top: 0.35rem;
    padding: 0.45rem;
    border-radius: 14px;
  }

  .quwma-navbar .dropdown-item {
    white-space: normal;
    line-height: 1.4;
  }

  .quwma-navbar .language-switcher {
    display: flex;
    justify-content: flex-start;
    width: 100%;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    padding-left: 0;
    margin-left: 0;
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
  }

  .quwma-navbar::before,
  .quwma-navbar::after {
    display: none;
  }

  /* =========================
     HOME
     ========================= */
  .page-home .hero-section.hero-world .container {
    padding-top: calc(var(--navbar-h, 72px) + 0.75rem);
    padding-bottom: 2.3rem;
  }

  .page-home .hero-section.hero-world .col-lg-7 {
    padding: 1.15rem 1.05rem;
    border-radius: 20px;
  }

  .page-home .hero-section.hero-world .col-lg-7::before {
    left: 16px;
    top: 14px;
    width: 64px;
  }

  .page-home .hero-section.hero-world .section-title {
    font-size: clamp(2.6rem, 10vw, 4.1rem);
    line-height: 1.01;
    margin-top: 0.95rem;
    margin-bottom: 0.85rem;
  }

  .page-home .hero-section.hero-world .section-text {
    font-size: 1rem;
    line-height: 1.64;
    max-width: 100%;
  }

  .page-home .hero-section.hero-world .btn {
    min-height: 50px;
    padding: 0.82rem 1.05rem;
    border-radius: 12px;
  }

  .home-info-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .page-home .home-card-image,
  .page-home .home-card-image-left {
    min-height: 240px;
    border-radius: 18px;
  }

  .page-home .home-card-content {
    padding: 1.25rem 1.15rem;
  }

  .page-home .home-card:hover {
    transform: translateY(-4px) scale(1.005);
  }

  /* =========================
     ABOUT
     ========================= */
  .page-about .about-hero.about-hero-world .container {
    padding-top: calc(var(--navbar-h, 72px) + 0.8rem);
    padding-bottom: 2.35rem;
  }

  .page-about .about-hero.about-hero-world .col-lg-7 {
    padding: 1.15rem 1.05rem;
    border-radius: 18px;
  }

  .page-about .about-hero.about-hero-world .col-lg-7::before {
    left: 16px;
    top: 14px;
    width: 64px;
  }

  .page-about .about-hero.about-hero-world .section-title {
    font-size: clamp(2.3rem, 7vw, 3.4rem);
    line-height: 1.07;
    margin-top: 0.9rem;
    margin-bottom: 0.8rem;
  }

  .page-about .about-hero.about-hero-world .section-text {
    font-size: 1rem;
    line-height: 1.64;
    max-width: 100%;
  }

  .page-about .about-team .section-text,
  .page-about .about-team-intro {
    max-width: 100%;
  }

  /* =========================
     SERVICES
     ========================= */
  .page-services .services-hero.services-hero--bg .container {
    padding-top: calc(var(--navbar-h, 72px) + 0.45rem);
    padding-bottom: 2.3rem;
  }

  .page-services .services-hero__content {
    padding: 1.15rem 1.05rem;
    border-radius: 18px;
  }

  .page-services .services-hero__content::before {
    left: 16px;
    top: 14px;
    width: 64px;
  }

  .page-services .services-hero.services-hero--bg .section-title {
    font-size: clamp(2.2rem, 7vw, 3.2rem);
    line-height: 1.07;
    margin-top: 0.9rem;
    margin-bottom: 0.8rem;
  }

  .page-services .services-hero.services-hero--bg .section-text {
    font-size: 1rem;
    line-height: 1.64;
    max-width: 100%;
  }

  .page-services .services-overview.section {
    padding-top: 28px;
  }

  .page-services .service-direction {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .page-services .service-direction-media img {
    aspect-ratio: 16 / 9;
  }

  .page-services .service-intro-card {
    position: static;
    border-radius: 22px;
  }

  .page-services .service-intro-media img {
    min-height: 240px;
    border-radius: 18px;
  }

  .page-services .service-block .accordion {
    border-radius: 22px;
    padding: 1rem;
  }

  .page-services #technical-engineering .service-intro-card,
  .page-services #it-engineering .service-intro-card {
    padding: 1.15rem 1.05rem;
    border-radius: 22px;
  }

  .page-services #technical-engineering .service-intro-media img,
  .page-services #it-engineering .service-intro-media img {
    min-height: 240px;
    max-height: none;
    border-radius: 18px;
  }

  .page-services #technical-engineering .row.mt-4,
  .page-services #it-engineering .row.mt-4 {
    margin-top: 1rem !important;
  }

  .page-services #technical-engineering .service-gallery-grid,
  .page-services #it-engineering .service-gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .page-services #technical-engineering .service-gallery-item img,
  .page-services #it-engineering .service-gallery-item img {
    aspect-ratio: 16 / 11;
  }

  /* =========================
     PROJECTS
     ========================= */
  .page-projects .projects-hero.projects-hero--bg .container {
    padding:
      calc(var(--navbar-h, 72px) + 0.85rem)
      1.05rem
      2.4rem;
    border-radius: 18px;
  }

  .page-projects .projects-hero.projects-hero--bg .section-title {
    font-size: clamp(2.5rem, 8vw, 3.6rem);
    line-height: 1.08;
    margin-bottom: 0.85rem;
  }

  .page-projects .projects-hero.projects-hero--bg .section-text {
    font-size: 1.02rem;
    line-height: 1.65;
    max-width: 100%;
  }

  .page-projects .projects-hero.projects-hero--bg .hero-note {
    font-size: 0.92rem;
    margin-bottom: 0.75rem;
  }

  .page-projects .projects-hero.projects-hero--bg::before {
    background-position: center 75%;
  }

  .projects-cards {
    grid-template-columns: 1fr;
  }

  .project-card2.projects-media img {
    max-height: 260px;
  }

  .projects-showcase-extra {
    padding-top: 20px;
    padding-bottom: 56px;
  }

  .projects-extra-card {
    padding: 22px;
    border-radius: 24px;
  }

  .projects-extra-layout {
    gap: 22px;
  }

  .projects-extra-image {
    aspect-ratio: 16 / 10;
  }

  .projects-extra-company-row {
    padding: 12px 0;
  }

  .projects-catalog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-catalog-card {
    min-height: 320px;
  }

  /* =========================
     PROJECT DETAIL
     ========================= */
  .page-project-detail .project-gallery-slide {
    min-height: 380px;
  }

  .page-project-detail .project-gallery-image {
    max-height: 340px;
  }

  .page-project-detail .project-contact-photo-wrap {
    min-height: 300px;
    max-height: 300px;
  }

  .page-project-detail .project-gallery-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .page-project-detail .project-gallery-grid-item {
    min-height: 260px;
    padding: 14px;
  }

  .page-project-detail .project-gallery-thumb {
    max-height: 340px;
  }

  /* =========================
     CONTACT
     ========================= */
  .page-contact .contact-hero.contact-hero--bg {
    padding: 38px 0 18px;
    margin-bottom: 10px;
  }

  .page-contact .contact-hero-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "lead"
      "brand"
      "info";
    gap: 18px;
  }

  .page-contact .contact-hero-info {
    justify-self: stretch;
  }

  .page-contact .contact-hero-info-card {
    width: 100%;
  }

  .page-contact .contact-card,
  .page-contact .contact-info-card,
  .page-contact .contact-form-card {
    padding: 16px 16px;
    border-radius: 16px;
  }
}

/* =========================================
   <= 768px
   page-wide background tweak
   ========================================= */
@media (max-width: 768px) {
  body[class^="page-"]::before,
  body[class*=" page-"]::before {
    position: fixed;
    filter: saturate(1.03);
  }
}

/* =========================================
   <= 767.98px
   small tablets / large phones
   ========================================= */
@media (max-width: 767.98px) {
  .hero-section .hero-stats .stat-box {
    flex: 1 1 100%;
    min-width: 0;
  }

  .hero-section .hero-stats {
    flex-direction: column;
    max-width: 100%;
  }

  .page-project-detail .project-gallery-slide {
    min-height: 320px;
    padding: 14px;
  }

  .page-project-detail .project-gallery-image {
    max-height: 280px;
  }

  .page-project-detail .project-detail-card {
    padding: 20px 18px 22px;
  }

  .page-project-detail .project-contact-body {
    padding: 18px;
  }

  .page-project-detail .project-contact-photo-wrap {
    min-height: 260px;
    max-height: 260px;
  }
}

/* =========================================
   <= 576px
   root font-size
   ========================================= */
@media (max-width: 576px) {
  html {
    font-size: 16px;
  }
}

/* =========================================
   <= 575.98px
   phones
   ========================================= */
@media (max-width: 575.98px) {
  /* NAVBAR */
  .quwma-navbar .navbar-brand {
    gap: 0.45rem;
  }

  .quwma-navbar .navbar-logo {
    height: 38px;
  }

  .quwma-navbar .brand-text {
    font-size: 0.95rem;
  }

  .quwma-navbar .navbar-toggler {
    padding: 0.3rem 0.45rem;
    border-radius: 10px;
  }

  .quwma-navbar .navbar-collapse {
    margin-top: 0.7rem;
    padding: 0.85rem 0.85rem 0.95rem;
  }

  .quwma-navbar .lang-pill .lang-btn {
    padding: 0.3rem 0.5rem;
    font-size: 0.74rem;
  }

  /* MAIN / ABOUT */
  .about-team .team-photo-wrap {
    height: 210px;
  }

  .about-audience .aud-toggle {
    padding: 7px 10px;
  }

  .about-audience .aud-toggle-text {
    display: none;
  }

  /* SERVICES */
  .page-services #technical-engineering .service-gallery-grid,
  .page-services #it-engineering .service-gallery-grid {
    grid-template-columns: 1fr;
  }

  /* PROJECTS */
  .projects-extra-card {
    padding: 18px;
    border-radius: 20px;
  }

  .projects-extra-title {
    margin-bottom: 14px;
  }

  .projects-extra-company-text {
    font-size: 0.95rem;
    line-height: 1.55;
  }

  .projects-catalog-grid {
    grid-template-columns: 1fr;
  }

  .project-catalog-card {
    min-height: auto;
  }
}