/* ==========================================================
   Harbal — phone layout (≤ 760px)
   • Compact menu button instead of a two-line menu bar
   • Service-page top section: picture first, title underneath
   • Video gallery becomes a swipe row
   ========================================================== */

.mnav-btn { display: none; }

@media (max-width: 760px) {
  /* ---------- menu ---------- */
  header > .wrap { flex-wrap: nowrap !important; min-height: 54px !important; position: relative; }
  .mnav-btn {
    all: unset; box-sizing: border-box; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; margin-right: -8px; border-radius: 12px;
    color: #1C2B3A;
  }
  .mnav-btn:focus-visible { outline: 3px solid #1E5A8E; outline-offset: 2px; }
  body.home .mnav-btn { color: #FFFFFF; filter: drop-shadow(0 1px 6px rgba(0,0,0,.35)); }
  html body header.mnav-open .mnav-btn { color: #1C2B3A; filter: none; }
  .mnav-btn svg { width: 24px; height: 24px; display: block; }
  .mnav-btn .x { display: none; }
  html body header.mnav-open .mnav-btn .bars { display: none; }
  html body header.mnav-open .mnav-btn .x { display: block; }

  header nav[aria-label="Main"] { display: none !important; }
  html body header.mnav-open { background: #FFFFFF !important; }
  html body header.mnav-open > .wrap > a > span { color: #1C2B3A !important; text-shadow: none !important; }
  html body header.mnav-open nav[aria-label="Main"] {
    display: flex !important; flex-direction: column; align-items: stretch !important; gap: 2px !important;
    position: absolute; left: -20px; right: -20px; top: 100%;
    padding: 10px 16px 18px; background: #FFFFFF;
    border-top: 1px solid #E1E6EC; box-shadow: 0 18px 40px rgba(28,43,58,.16);
    max-height: calc(100svh - 54px); overflow-y: auto; overscroll-behavior: contain;
    animation: mnav-in .28s cubic-bezier(.2,.7,.2,1) both;
  }
  @keyframes mnav-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
  html body header.mnav-open nav .np, html body header.mnav-open nav .ddb {
    color: #1C2B3A !important; background: transparent !important; text-shadow: none !important;
    min-height: 46px; padding: 0 12px !important; font-size: 16px !important; border-radius: 12px;
    display: flex !important; align-items: center;
  }
  html body header.mnav-open nav .np[aria-current], html body header.mnav-open nav .np:hover { background: #EAF2FB !important; color: #1E5A8E !important; }
  html body header.mnav-open nav .ddb { pointer-events: none; color: #4A5868 !important; font-size: 13px !important;
    letter-spacing: .12em; text-transform: uppercase; min-height: 34px; margin-top: 6px; }
  html body header.mnav-open nav .ddb .chev { display: none; }
  html body header.mnav-open nav .dd { order: 5; }
  html body header.mnav-open nav .ddp {
    position: static !important; opacity: 1 !important; visibility: visible !important; transform: none !important;
    width: auto !important; padding: 0 !important; border: 0 !important; box-shadow: none !important; background: none !important;
    transition: none !important;
  }
  html body header.mnav-open nav .ddp::before { display: none; }
  html body header.mnav-open nav .ddi { padding: 9px 10px; }
  html body header.mnav-open nav .ddic { width: 34px; height: 34px; border-radius: 10px; font-size: 12px; }
  body.mnav-lock { overflow: hidden; }

  /* ---------- service-page top section ---------- */
  .doors { height: auto !important; max-height: none !important; }
  .doors .doors-stage {
    position: relative !important; top: 0 !important; height: auto !important; max-height: none !important; overflow: hidden;
    display: flex; flex-wrap: wrap; justify-content: center; align-items: baseline;
    column-gap: 10px; row-gap: 14px; padding: 18px 18px 26px; box-sizing: border-box;
  }
  .doors .d-img {
    position: relative !important; left: auto !important; top: auto !important; transform: none !important;
    flex: 0 0 100%; width: 100% !important; height: auto !important; aspect-ratio: 4 / 3;
    opacity: 1 !important; border-radius: 16px; box-shadow: 0 18px 44px rgba(28,43,58,.16);
    animation: m-img .9s cubic-bezier(.2,.7,.2,1) both;
  }
  .doors .d-line, .doors .d-small, .doors .d-hint, .doors .d-cap, .doors .d-ov { display: none !important; }
  .doors .d-word {
    position: static !important; transform: none !important; opacity: 1 !important; order: 1;
    font-size: clamp(30px, 10vw, 44px) !important; line-height: 1 !important; white-space: nowrap;
  }
  .doors .d-left { animation: m-left .8s cubic-bezier(.2,.7,.2,1) .15s both; }
  .doors .d-right { animation: m-right .8s cubic-bezier(.2,.7,.2,1) .25s both; }
  .doors .sr-door .sr-mount { width: 96% !important; }
  @keyframes m-img { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
  @keyframes m-left { from { opacity: 0; transform: translateX(-28px); } to { opacity: 1; transform: none; } }
  @keyframes m-right { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }

  /* ---------- video gallery: swipe row ---------- */
  .work-video-grid {
    display: flex !important; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px !important;
    padding: 2px 2px 10px; margin: 0 -14px; padding-inline: 14px; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .work-video-grid::-webkit-scrollbar { display: none; }
  .work-video-grid > .work-uploaded-video { flex: 0 0 64%; scroll-snap-align: center; border-radius: 14px; }
  .work-video-grid-section::after {
    content: "Swipe to see more →"; display: block; text-align: center; margin-top: 8px;
    font: 600 12px/1 'Plus Jakarta Sans', sans-serif; letter-spacing: .08em; color: #4A6A86;
  }
}

@media (max-width: 760px) and (prefers-reduced-motion: reduce) {
  .doors .d-img, .doors .d-left, .doors .d-right, html body header.mnav-open nav[aria-label="Main"] { animation: none !important; }
}

/* ---------- tablets (761–1100px): keep the Services dropdown inside the screen ---------- */
@media (min-width: 761px) and (max-width: 1100px) {
  header .ddp { position: fixed !important; top: 58px !important; left: auto !important; right: 16px !important;
    width: min(440px, calc(100vw - 32px)) !important; max-height: calc(100vh - 74px); overflow-y: auto; }
  .doors .d-word { font-size: clamp(30px, 5.4vw, 60px) !important; }
}
