/* ═══════════════════════════════════════════════
   RESPONSIVE — Full Professional Overhaul
   Breakpoints:
     ≤ 1280px  Large Tablet / Small Laptop
     ≤ 1024px  Tablet landscape
     ≤  768px  Tablet portrait
     ≤  480px  Mobile
     ≤  360px  Small mobile
   ═══════════════════════════════════════════════ */


/* ════════════════════════════════════════════════
   LARGE TABLET / SMALL LAPTOP  (≤ 1280px)
════════════════════════════════════════════════ */
@media (max-width: 1280px) {

  /* Nav */
  nav { padding: 0 40px; }
  .nav-links { gap: 28px; }
  .nav-links a { font-size: 10px; letter-spacing: 2px; }

  /* Sections inner */
  .section-inner { padding: 100px 60px; }

  /* Hero */
  .hero-content { padding: 100px 60px 0; }
  .hero-stats   { right: 60px; }

  /* Brand */
  .brand-inner { padding: 80px 60px; gap: 60px; }
  .brand-logo-ring { width: 340px; height: 340px; }
  .brand-logo-img  { width: 290px; height: 290px; }

  /* Numbers */
  .numbers-section { padding: 70px 60px; }

  /* Footer */
  .footer-top    { padding: 70px 60px 50px; }
  .footer-bottom { padding: 20px 60px; }

  /* Services */
  .services-grid { grid-template-columns: repeat(3, 1fr); }
}


/* ════════════════════════════════════════════════
   TABLET LANDSCAPE  (≤ 1024px)
════════════════════════════════════════════════ */
@media (max-width: 1024px) {

  /* ── Nav ── */
  nav { padding: 0 28px; height: 72px; }
  .nav-links { gap: 20px; }
  .nav-links a { font-size: 10px; letter-spacing: 1.5px; }
  .nav-cta { padding: 10px 20px; font-size: 9px; letter-spacing: 2px; }

  /* Logo */
  .nav-logo-img  { width: 44px; height: 44px; }
  .nav-logo-text { font-size: 17px; letter-spacing: 4px; }
  .nav-logo-text em { font-size: 9px; letter-spacing: 3px; }

  /* ── Hero ── */
  .hero-content { padding: 88px 40px 0; }
  .hero-stats   { display: none; }
  .hero-btns    { gap: 14px; }

  /* ── Sections ── */
  .section-inner { padding: 80px 40px; }

  /* ── Brand / Logo section ── */
  .brand-inner {
    grid-template-columns: 300px 1fr;
    gap: 50px;
    padding: 70px 40px;
  }
  .brand-logo-ring { width: 280px; height: 280px; }
  .brand-logo-img  { width: 236px; height: 236px; }
  .brand-values { grid-template-columns: 1fr; }

  /* ── About ── */
  .about-grid { grid-template-columns: 1fr; gap: 50px; }
  .about-image-stack { height: 420px; }

  /* ── Services ── */
  .services-grid { grid-template-columns: repeat(2, 1fr); gap: 2px; }
  .service-card.featured { grid-row: auto; min-height: 380px; }
  .services-header { flex-direction: column; gap: 24px; align-items: flex-start; }

  /* ── Numbers ── */
  .numbers-section { padding: 60px 40px; }
  .numbers-grid { grid-template-columns: repeat(2, 1fr); gap: 2px; }
  .number-val  { font-size: 50px; }

  /* ── Projects ── */
  .projects-grid { grid-template-columns: repeat(2, 1fr); gap: 3px; }
  .project-card  { grid-column: auto !important; height: 280px !important; }
  .projects-intro { grid-template-columns: 1fr; gap: 30px; margin-bottom: 50px; }

  /* ── FRI-TEX ── */
  .fritex-section { padding: 80px 40px; }
  .fritex-grid { grid-template-columns: repeat(2, 1fr); }

  /* ── Testimonial ── */
  .testimonial-section { padding: 100px 40px; }

  /* ── Contact ── */
  .contact-grid { grid-template-columns: 1fr; gap: 50px; }

  /* ── Footer ── */
  .footer-top    { grid-template-columns: 1fr 1fr; gap: 40px; padding: 60px 40px 40px; }
  .footer-bottom { padding: 20px 40px; }

  /* ── Service Overlay ── */
  .sp-topbar       { padding: 0 28px; height: 64px; }
  .sp-hero-content { padding: 60px 40px 50px; }
  .sp-body         { padding: 60px 40px 80px; }
  .sp-intro-grid   { grid-template-columns: 1fr; gap: 40px; }
  .sp-offerings    { grid-template-columns: repeat(2, 1fr); }
  .sp-steps        { grid-template-columns: repeat(2, 1fr); }
  .sp-gallery      { grid-template-columns: repeat(2, 1fr); }
  .sp-cta-band     { padding: 50px 40px; flex-direction: column; align-items: flex-start; }
  .sp-service-nav  { padding: 30px 40px; }

  /* ── Boutique / Marché ── */
  .shop-hero      { padding: 80px 40px 60px; }
  .shop-grid-wrap { padding: 50px 40px; }
  .shop-grid      { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .shop-trust-strip { grid-template-columns: repeat(2, 1fr); }
  .product-img-wrap { height: 240px; }
}


/* ════════════════════════════════════════════════
   TABLET PORTRAIT  (≤ 768px)
════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* ── Nav — hamburger menu ── */
  nav { padding: 0 20px; height: 68px; }
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 68px; left: 0; right: 0;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 28px 24px 32px;
    gap: 4px;
    border-bottom: 2px solid var(--gold-dark);
    z-index: 1100;
    box-shadow: 0 12px 40px rgba(28,28,26,0.12);
  }
  .nav-links.open li { border-bottom: 1px solid var(--border-gold); }
  .nav-links.open li:last-child { border-bottom: none; }
  .nav-links.open a {
    display: block;
    padding: 14px 0;
    font-size: 12px;
    letter-spacing: 3px;
  }
  .nav-toggle  { display: flex; }
  .nav-cta     { display: none; }
  .lang-switcher { order: -1; margin-left: auto; margin-right: 8px; }

  /* Logo smaller */
  .nav-logo-img  { width: 40px; height: 40px; }
  .nav-logo-text { font-size: 15px; letter-spacing: 3px; }
  .nav-logo-text em { font-size: 8px; letter-spacing: 2px; }
  .nav-logo { gap: 10px; }

  /* ── Hero ── */
  .hero-content {
    padding: 80px 24px 0;
    text-align: left;
  }
  .hero-tagline  { font-size: 10px; letter-spacing: 4px; }
  .hero-subtitle { margin-bottom: 28px; }
  .hero-desc     { margin-bottom: 36px; }
  .hero-btns     { flex-direction: column; align-items: flex-start; gap: 12px; }
  .hero-btns .btn-primary,
  .hero-btns .btn-outline { width: 100%; text-align: center; padding: 16px 24px; }

  /* ── Sections ── */
  .section-inner { padding: 64px 24px; }

  /* ── Brand / Logo section ── */
  .brand-inner {
    grid-template-columns: 1fr;
    padding: 64px 24px;
    gap: 44px;
    text-align: center;
  }
  .brand-logo-ring { width: 260px; height: 260px; margin: 0 auto; }
  .brand-logo-img  { width: 220px; height: 220px; }
  .brand-logo-wrap::before,
  .brand-logo-wrap::after { display: none; }
  .brand-divider   { margin: 20px auto; }
  .brand-values    { grid-template-columns: 1fr; max-width: 400px; margin: 0 auto 32px; text-align: left; }
  .brand-ctas      { justify-content: center; flex-direction: column; align-items: center; }
  .brand-ctas .btn-primary,
  .brand-ctas .btn-outline { width: 100%; max-width: 320px; text-align: center; }
  .brand-desc { margin: 0 auto 28px; }

  /* ── About ── */
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-image-stack { height: 340px; }
  .about-values { grid-template-columns: 1fr; gap: 16px; }

  /* ── Services ── */
  .services-grid { grid-template-columns: 1fr; }
  .service-card  { height: 320px; }
  .service-card.featured { min-height: 320px; }

  /* ── Numbers ── */
  .numbers-section { padding: 50px 24px; }
  .numbers-grid    { grid-template-columns: repeat(2, 1fr); }
  .number-val      { font-size: 42px; }
  .number-label    { font-size: 10px; letter-spacing: 2px; }

  /* ── FRI-TEX ── */
  .fritex-section  { padding: 64px 24px; }
  .fritex-section::before { font-size: 100px; }
  .fritex-grid     { grid-template-columns: 1fr; gap: 2px; }

  /* ── Projects ── */
  .projects-intro  { grid-template-columns: 1fr; gap: 24px; margin-bottom: 36px; }
  .projects-grid   { grid-template-columns: 1fr; gap: 3px; }
  .project-card    { grid-column: auto !important; height: 260px !important; }

  /* ── Testimonial ── */
  .testimonial-section  { padding: 72px 24px; }
  .testimonial-section::before { font-size: 120px; }

  /* ── Contact ── */
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .contact-info h3 { font-size: 20px; margin-bottom: 32px; }
  .form-row { grid-template-columns: 1fr; }
  .contact-detail { gap: 14px; margin-bottom: 24px; }
  .contact-detail-icon { width: 40px; height: 40px; font-size: 15px; }

  /* ── Footer ── */
  .footer-top {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 50px 24px 36px;
  }
  .footer-logo-wrap { margin-bottom: 16px; }
  .footer-bottom {
    padding: 20px 24px;
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
  .footer-legal { gap: 16px; flex-wrap: wrap; justify-content: center; }

  /* ── Service Overlay ── */
  .sp-topbar { padding: 0 20px; height: 60px; }
  .sp-topbar-logo { display: none; }
  .sp-hero { min-height: 55vh; }
  .sp-hero-content { padding: 50px 20px 36px; }
  .sp-body { padding: 40px 20px 60px; }
  .sp-intro-grid { gap: 30px; }
  .sp-offerings { grid-template-columns: 1fr; gap: 2px; }
  .sp-steps     { grid-template-columns: 1fr; gap: 2px; }
  .sp-gallery   { grid-template-columns: 1fr; gap: 2px; }
  .sp-gallery img { height: 200px; }
  .sp-cta-band  { padding: 40px 20px; flex-direction: column; }
  .sp-service-nav { padding: 24px 20px; flex-direction: column; gap: 14px; }

  /* ── Boutique / Marché ── */
  .shop-hero      { padding: 72px 24px 50px; }
  .shop-grid-wrap { padding: 40px 24px; }
  .shop-grid      { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .shop-trust-strip { grid-template-columns: repeat(2, 1fr); gap: 3px; }
  .product-img-wrap { height: 200px; }
  .product-body   { padding: 18px 18px 22px; }
  .product-name   { font-size: 14px; }
  .product-desc   { font-size: 12px; }
  .product-price  { font-size: 17px; }
  .shop-filters   { gap: 6px; margin-top: 28px; }
  .filter-btn     { padding: 10px 16px; font-size: 10px; letter-spacing: 2px; }
}


/* ════════════════════════════════════════════════
   MOBILE  (≤ 480px)
════════════════════════════════════════════════ */
@media (max-width: 480px) {

  /* ── Nav ── */
  nav { padding: 0 16px; height: 64px; }
  .nav-logo-img  { width: 36px; height: 36px; }
  .nav-logo-text { font-size: 13px; letter-spacing: 2px; }
  .nav-logo-text em { display: none; }
  .nav-links.open { top: 64px; padding: 20px 16px 24px; }

  /* ── Hero ── */
  .hero-content { padding: 72px 16px 0; }
  .hero-tagline { font-size: 9px; }
  .btn-primary, .btn-outline {
    font-size: 10px;
    letter-spacing: 3px;
    padding: 15px 20px;
  }

  /* ── Sections ── */
  .section-inner { padding: 52px 16px; }
  .section-title { line-height: 1.15; }
  .section-subtitle { font-size: 17px; margin-bottom: 32px; }

  /* ── Brand ── */
  .brand-inner    { padding: 52px 16px; }
  .brand-logo-ring { width: 220px; height: 220px; }
  .brand-logo-img  { width: 186px; height: 186px; }
  .brand-value-item { padding: 12px 14px; }
  .brand-value-text { font-size: 10px; letter-spacing: 1.5px; }

  /* ── Numbers ── */
  .numbers-section { padding: 44px 16px; }
  .number-val { font-size: 36px; }

  /* ── FRI-TEX ── */
  .fritex-section { padding: 52px 16px; }
  .fritex-card    { padding: 28px 20px; }

  /* ── Projects ── */
  .project-card { height: 220px !important; }
  .project-name { font-size: 17px; }

  /* ── Testimonial ── */
  .testimonial-section { padding: 56px 16px; }

  /* ── Contact ── */
  .form-field label  { font-size: 9px; padding: 12px 14px 0; }
  .form-field input,
  .form-field select,
  .form-field textarea { padding: 8px 14px 12px; font-size: 13px; }
  .form-submit { padding: 18px; font-size: 10px; }
  .contact-detail-icon { width: 36px; height: 36px; font-size: 14px; }

  /* ── Scroll indicator ── */
  .hero-scroll { display: none; }

  /* ── Footer ── */
  .footer-top    { padding: 44px 16px 32px; }
  .footer-bottom { padding: 18px 16px; }
  .footer-brand  { font-size: 22px; }
  .footer-copy   { font-size: 10px; }
  .footer-legal a { font-size: 10px; }
  .footer-logo-wrap { gap: 12px; }
  .footer-logo-img  { width: 48px; height: 48px; }

  /* ── About ── */
  .about-badge { width: 96px; height: 96px; }
  .about-badge-num { font-size: 26px; }
  .about-image-stack { height: 300px; }

  /* ── Boutique / Marché ── */
  .shop-hero      { padding: 60px 16px 40px; }
  .shop-grid-wrap { padding: 32px 16px; }
  .shop-grid      { grid-template-columns: 1fr; gap: 16px; }
  .shop-trust-strip { grid-template-columns: repeat(2, 1fr); }
  .shop-trust-item  { padding: 24px 16px; }
  .product-img-wrap { height: 240px; }
  .product-body   { padding: 20px 20px 24px; }
  .product-name   { font-size: 15px; }
  .product-price  { font-size: 19px; }
  .add-cart-btn   { padding: 14px 20px; font-size: 10px; }
  .shop-filters   { gap: 6px; }
  .filter-btn     { padding: 10px 14px; font-size: 9px; letter-spacing: 1.5px; }
}


/* ════════════════════════════════════════════════
   SMALL MOBILE  (≤ 360px)
════════════════════════════════════════════════ */
@media (max-width: 360px) {

  nav { padding: 0 12px; }
  .nav-logo-img  { width: 32px; height: 32px; border-width: 1px; }
  .nav-logo-text { font-size: 12px; }
  .section-inner { padding: 44px 12px; }
  .brand-inner   { padding: 44px 12px; }
  .numbers-section { padding: 36px 12px; }
  .number-val { font-size: 30px; }
  .fritex-section { padding: 44px 12px; }
  .testimonial-section { padding: 48px 12px; }
  .footer-top    { padding: 36px 12px 28px; }
  .footer-bottom { padding: 14px 12px; }
  .brand-logo-ring { width: 190px; height: 190px; }
  .brand-logo-img  { width: 158px; height: 158px; }
  .btn-primary, .btn-outline { padding: 13px 16px; font-size: 8px; }

  /* ── Boutique ── */
  .shop-hero { padding: 52px 12px 36px; }
  .shop-grid-wrap { padding: 28px 12px; }
  .shop-trust-strip { grid-template-columns: 1fr 1fr; }
}


/* ════════════════════════════════════════════════
   GLOBAL TOUCH / USABILITY FIXES (all mobile)
════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* Prevent horizontal scroll */
  body { overflow-x: hidden; }

  /* Smooth scrolling on iOS */
  html { -webkit-overflow-scrolling: touch; }

  /* Bigger touch targets */
  .nav-toggle { padding: 12px 8px; }
  .qty-btn, .cart-close { min-width: 44px; min-height: 44px; }
  .filter-btn { padding: 12px 20px; }
  .add-cart-btn, .product-quick { padding: 13px 18px; }
  .form-submit { min-height: 52px; }

  /* Remove hover transforms on touch (prevent sticky hover states) */
  @media (hover: none) {
    .product-card:hover { -webkit-transform: none; transform: none; }
    .service-card:hover .service-card-bg { -webkit-transform: none; transform: none; }
    .btn-primary:hover,
    .btn-outline:hover { -webkit-transform: none; transform: none; box-shadow: none; }
  }

  /* Ensure images don't overflow */
  img { max-width: 100%; }

  /* Fix 100vw including scrollbar */
  .marquee-strip { overflow: hidden; }

  /* Cart sidebar full-width on mobile */
  .cart-sidebar  { width: 100%; right: -100%; border-left: none; }
  .cart-sidebar.open { right: 0; }
  .checkout-modal { max-height: 95vh; }
  .modal-field-row { grid-template-columns: 1fr; }

  /* Service overlay full-screen on mobile */
  .sp-overlay { }

  /* Prevent iOS zoom on input focus — set font-size ≥16px inside inputs */
  input, select, textarea { font-size: 16px !important; }
}


/* ════════════════════════════════════════════════
   CROSS-BROWSER GLOBAL FIXES
════════════════════════════════════════════════ */

/* Safe area insets — iPhone X+ notch / home bar */
@supports (padding: env(safe-area-inset-bottom)) {
  nav       { padding-left: max(60px, env(safe-area-inset-left));  padding-right: max(60px, env(safe-area-inset-right)); }
  footer    { padding-bottom: env(safe-area-inset-bottom); }
  .cart-sidebar { padding-bottom: env(safe-area-inset-bottom); }
  .sp-overlay   { padding-bottom: env(safe-area-inset-bottom); }
}

/* Firefox — remove inner padding/border on buttons */
button::-moz-focus-inner { border: 0; padding: 0; }

/* All interactive elements — no blue tap flash on Android Chrome */
a, button, [role="button"] { -webkit-tap-highlight-color: transparent; }

/* Prevent text selection on UI buttons */
button, .btn-primary, .btn-outline, .nav-cta, .filter-btn, .add-cart-btn {
  -webkit-user-select: none;
     -moz-user-select: none;
      -ms-user-select: none;
          user-select: none;
}

/* Improve subpixel rendering on Windows */
* { -webkit-font-smoothing: antialiased; }

/* Focus-visible ring for keyboard accessibility (not shown on mouse click) */
:focus-visible {
  outline: 2px solid var(--gold-dark);
  outline-offset: 3px;
}
:focus:not(:focus-visible) { outline: none; }
