/* ── SITEWIDE MOBILE POLISH ── */

@media (max-width: 768px) {
  html { -webkit-text-size-adjust: 100%; }

  /* Sections */
  section,
  .section-compact { padding: 56px 20px !important; }

  .section-header {
    flex-direction: column;
    align-items: stretch !important;
    gap: 18px !important;
    margin-bottom: 32px !important;
  }
  .section-header .btn-primary,
  .section-header .btn-secondary {
    width: 100%;
    justify-content: center;
  }

  .section-title {
    font-size: clamp(1.45rem, 5.5vw, 1.9rem) !important;
    letter-spacing: -.5px !important;
  }
  .section-sub { font-size: .9rem; line-height: 1.65; }

  /* Page heroes */
  .page-hero {
    padding: 20px 20px 40px !important;
  }
  .page-hero h1 {
    font-size: clamp(1.65rem, 6.5vw, 2.1rem) !important;
    letter-spacing: -.6px !important;
  }
  .page-hero p { font-size: .92rem; line-height: 1.65; }
  .breadcrumb {
    font-size: .72rem;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 6px;
  }

  /* Premium page heroes */
  .svc-hero,
  .contact-hero,
  .blog-hero,
  .proj-hero {
    padding: 24px 20px 40px !important;
  }
  .svc-hero h1,
  .contact-hero h1,
  .blog-hero h1,
  .proj-hero h1 {
    font-size: clamp(1.75rem, 7vw, 2.35rem) !important;
  }
  .svc-hero-lead,
  .contact-hero-lead,
  .blog-hero-lead,
  .proj-hero-lead {
    font-size: .92rem !important;
  }

  /* Rreth Nesh — hero kompakt */
  .about-hero {
    padding: 12px 20px 36px !important;
  }
  .about-hero-grid { gap: 24px !important; }
  .about-hero .breadcrumb { margin-bottom: 10px !important; }
  .about-hero-badge {
    margin-bottom: 12px !important;
    padding: 5px 12px !important;
    font-size: .7rem !important;
  }
  .about-hero h1 {
    font-size: clamp(1.55rem, 6.2vw, 2rem) !important;
    letter-spacing: -.7px !important;
    line-height: 1.18 !important;
    margin-bottom: 12px !important;
  }
  .about-hero-lead {
    font-size: .88rem !important;
    line-height: 1.65 !important;
    margin-bottom: 18px !important;
  }
  /* About hero stats — unified grid */
  .about-hero-stats {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0 !important;
    max-width: none !important;
    flex-direction: unset !important;
  }
  .about-hero-stat {
    background: transparent !important;
    border: none !important;
    border-right: 1px solid var(--border) !important;
    border-radius: 0 !important;
    padding: 14px 8px !important;
    text-align: center;
  }
  .about-hero-stat:last-child { border-right: none !important; }
  .about-hero-stat strong {
    font-size: 1.2rem !important;
  }
  .about-hero-stat span {
    font-size: .62rem !important;
    line-height: 1.3;
    margin-top: 3px !important;
  }
  .about-hero-visual {
    min-height: 200px !important;
    margin-top: 4px;
  }

  /* Home hero — tipografi premium */
  .home-hero {
    padding: 68px 20px 44px !important;
  }
  .home-hero .hero-badge {
    margin-bottom: 16px;
    padding: 5px 12px;
    font-size: .68rem;
    letter-spacing: .6px;
  }
  .home-hero h1 {
    font-size: clamp(1.75rem, 7.5vw, 2.2rem) !important;
    letter-spacing: -.9px !important;
    line-height: 1.14 !important;
    margin-bottom: 14px;
  }
  .home-hero .hero-sub {
    font-size: .9rem;
    line-height: 1.68;
    color: var(--text-mid);
    margin-bottom: 24px;
    max-width: none;
  }
  .hero-actions {
    flex-direction: column;
    width: 100%;
    gap: 10px;
    margin-bottom: 28px;
  }
  .hero-actions .btn-primary,
  .hero-actions .btn-secondary {
    width: 100%;
    justify-content: center;
    padding: 14px 20px;
    font-size: .9rem;
  }
  .home-hero .hero-stats {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0 !important;
    max-width: none !important;
  }
  .home-hero .hero-stats > div {
    background: transparent !important;
    border: none !important;
    border-right: 1px solid var(--border) !important;
    border-radius: 0 !important;
    padding: 14px 8px !important;
    text-align: center;
  }
  .home-hero .hero-stats > div:last-child { border-right: none !important; }
  .home-hero .hero-stat-val { font-size: 1.25rem !important; }
  .home-hero .hero-stat-lbl {
    font-size: .64rem;
    line-height: 1.3;
    margin-top: 4px;
  }

  /* Capabilities */
  .capabilities { padding: 56px 20px !important; }
  .capabilities-header { margin-bottom: 32px !important; }
  .cap-visual img { min-height: 220px !important; }
  .cap-card {
    padding: 22px 20px !important;
  }
  .cap-card:hover { transform: none; }

  /* Grids */
  .services-grid { grid-template-columns: 1fr !important; gap: 14px !important; }
  .why-compact { grid-template-columns: 1fr !important; gap: 12px !important; }
  .testimonials-grid { grid-template-columns: 1fr !important; gap: 14px !important; }

  /* Process — horizontal scroll */
  .process-steps {
    display: flex !important;
    grid-template-columns: unset !important;
    overflow-x: auto;
    gap: 10px;
    padding: 4px 2px 12px;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }
  .process-steps::-webkit-scrollbar { display: none; }
  .process-steps::before { display: none !important; }
  .process-step {
    flex: 0 0 92px;
    scroll-snap-align: start;
  }
  .process-step-circle {
    width: 50px; height: 50px;
    font-size: 1.15rem;
    margin-bottom: 8px;
  }
  .process-step-name { font-size: .7rem; line-height: 1.25; }

  /* Stats band */
  .stats-band { padding: 40px 20px !important; }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 28px 16px !important;
  }
  .stat-val { font-size: 1.9rem !important; }

  /* CTA bands */
  .cta-band,
  .cta-band-light,
  .proj-page .cta-band-light {
    padding: 48px 20px !important;
  }
  .cta-inner {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 20px !important;
    text-align: center;
  }
  .cta-title,
  .cta-title-dark {
    font-size: clamp(1.35rem, 5vw, 1.75rem) !important;
  }
  .cta-actions {
    flex-direction: column;
    width: 100%;
    gap: 10px;
  }
  .cta-actions .btn-primary,
  .cta-actions .btn-secondary,
  .cta-actions .btn-white,
  .cta-actions .btn-outline-white,
  .cta-inner > .btn-white,
  .cta-inner > .btn-primary {
    width: 100%;
    justify-content: center;
  }

  /* Filter pills — scroll row */
  .blog-filters,
  .proj-filters,
  .svc-filters {
    flex-wrap: nowrap !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
    margin-bottom: 28px !important;
    scrollbar-width: none;
    gap: 8px !important;
  }
  .blog-filters::-webkit-scrollbar,
  .proj-filters::-webkit-scrollbar,
  .svc-filters::-webkit-scrollbar { display: none; }
  .blog-filter,
  .proj-filter,
  .svc-filter {
    flex-shrink: 0;
    padding: 8px 16px !important;
    font-size: .78rem !important;
  }

  /* Careers */
  .careers-grid {
    grid-template-columns: 1fr !important;
    gap: 36px !important;
  }
  .career-card {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 14px !important;
    padding: 18px 18px !important;
  }
  .career-apply {
    display: block !important;
    width: 100%;
    text-align: center;
    padding: 11px 16px !important;
  }
  .career-list { gap: 12px !important; }

  /* Contact shell */
  .contact-shell {
    padding: 0 16px !important;
    margin-bottom: 28px !important;
  }
  .contact-shell > *:first-child {
    border-radius: var(--radius-lg) var(--radius-lg) 0 0 !important;
  }
  .contact-shell > *:last-child {
    border-radius: 0 0 var(--radius-lg) var(--radius-lg) !important;
  }

  /* Page sections */
  .svc-section,
  .blog-section,
  .careers-section,
  .proj-section,
  .about-story,
  .about-values,
  .about-leadership {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

  /* Svc hero stats */
  .svc-hero-stat {
    border-right: none !important;
    border-bottom: 1px solid var(--border) !important;
  }
  .svc-hero-stat:nth-child(2n) { border-right: none !important; }
  .svc-hero-stat:last-child { border-bottom: none !important; }

  /* Contact */
  .contact-pills { gap: 8px; }
  .contact-pill {
    flex: 1 1 calc(50% - 8px);
    text-align: center;
    padding: 10px 12px !important;
    font-size: .76rem !important;
  }
  .contact-quick-actions { grid-template-columns: 1fr !important; }
  .contact-map-header {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 8px;
  }

  /* Blog / project modals */
  .blog-modal-overlay,
  .proj-modal-overlay {
    padding: 0 !important;
    align-items: flex-end !important;
  }
  .blog-modal,
  .proj-modal {
    width: 100% !important;
    max-width: 100% !important;
    max-height: 92dvh !important;
    border-radius: 20px 20px 0 0 !important;
    overflow-y: auto;
  }
  .blog-modal-body,
  .proj-modal-body {
    padding: 22px 20px 28px !important;
  }
  .blog-modal-title,
  .proj-modal-title {
    font-size: 1.35rem !important;
  }
  .proj-modal-gallery {
    grid-template-columns: 1fr !important;
  }
  .proj-modal-cta {
    flex-direction: column;
  }
  .proj-modal-cta .btn-primary,
  .proj-modal-cta .btn-secondary {
    width: 100%;
    min-width: 0 !important;
  }

  /* Footer */
  .site-footer-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 22px 14px !important;
  }
  .site-footer-brand { grid-column: 1 / -1 !important; }
  .site-footer-bar {
    flex-direction: column;
    text-align: center;
    gap: 14px;
  }
  .site-footer-socials { justify-content: center; }

  /* Reduce hover motion on touch */
  .service-card:hover,
  .testi-card:hover,
  .blog-card:hover {
    transform: none;
  }
}

@media (max-width: 480px) {
  .site-footer-grid { grid-template-columns: 1fr !important; }
  .contact-hero-stats,
  .svc-hero-stats {
    grid-template-columns: 1fr !important;
  }
  .contact-hero-stat,
  .svc-hero-stat {
    border-right: none !important;
    border-bottom: 1px solid var(--border) !important;
  }
  .contact-hero-stat:last-child,
  .svc-hero-stat:last-child { border-bottom: none !important; }
  .about-hero-stats {
    grid-template-columns: 1fr !important;
  }
  .about-hero-stat {
    border-right: none !important;
    border-bottom: 1px solid var(--border) !important;
  }
  .about-hero-stat:last-child { border-bottom: none !important; }
  .home-hero .hero-stats {
    grid-template-columns: 1fr !important;
  }
  .home-hero .hero-stats > div {
    border-right: none !important;
    border-bottom: 1px solid var(--border) !important;
  }
  .home-hero .hero-stats > div:last-child { border-bottom: none !important; }
  .proj-hero-stats {
    flex-direction: column;
    gap: 16px !important;
  }
  .contact-pill { flex: 1 1 100%; }
  .process-step { flex: 0 0 84px; }
  .stats-grid { grid-template-columns: 1fr 1fr !important; }
  .about-hero-stat strong { font-size: 1.05rem !important; }
  .about-hero-stat span { font-size: .58rem !important; }
}

/* Safe areas (notched phones) */
@supports (padding: max(0px)) {
  .site-mobile-actions {
    padding-bottom: max(24px, env(safe-area-inset-bottom));
  }
  .whatsapp-float {
    bottom: max(18px, env(safe-area-inset-bottom));
    right: max(16px, env(safe-area-inset-right));
  }
  #backTop {
    right: max(16px, env(safe-area-inset-right));
    bottom: max(80px, calc(62px + env(safe-area-inset-bottom)));
  }
}
