/* ============================================================
   NOCTURNE — mobile / smartphone optimizations
   ============================================================ */

/* hamburger hidden on desktop */
.nav__burger { display: none; }

/* ---------- tablet & down: hamburger menu ---------- */
@media (max-width: 940px) {
  .nav__burger {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px; height: 42px;
    padding: 0 9px;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 12px;
    cursor: pointer;
    order: 5;
  }
  .nav__burger span {
    display: block;
    height: 1.5px;
    width: 100%;
    background: var(--white);
    border-radius: 2px;
    transition: transform .3s var(--ease), opacity .25s ease;
  }
  body.menu-open .nav__burger span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
  body.menu-open .nav__burger span:nth-child(2) { opacity: 0; }
  body.menu-open .nav__burger span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

  /* slide-down full menu */
  .nav__nav {
    position: fixed;
    top: 56px; left: 0; right: 0;
    background: rgba(6,6,9,0.97);
    -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--line-soft);
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: transform .4s var(--ease), opacity .35s ease;
    max-height: calc(100svh - 56px);
    overflow-y: auto;
  }
  body.menu-open .nav__nav { transform: none; opacity: 1; pointer-events: auto; }

  .nav__links {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0 16px;
  }
  .nav__links li { width: 100%; }
  .nav__links a {
    display: block;
    font-size: 17px;
    letter-spacing: 0.04em;
    color: var(--white);
    padding: 17px clamp(22px, 6vw, 40px);
    border-bottom: 1px solid var(--line-soft);
  }
  .nav__links a:active { background: rgba(232,192,116,0.08); }

  /* keep brand left, controls right; order them */
  .nav__inner { gap: 10px; }
  .nav__brand { order: 0; margin-right: auto; }
  .nav__cta { order: 3; }
  .nav__lang { order: 4; }
}

/* ---------- phones ---------- */
@media (max-width: 680px) {
  /* nav: trim the Request Sample button to an icon-ish compact pill */
  .nav { height: 54px; }
  .nav__nav { top: 54px; }
  .nav__inner { padding: 0 16px; gap: 8px; }
  .nav__brand { font-size: 16px; letter-spacing: 0.26em; text-indent: 0.26em; }
  .nav__cta { padding: 7px 13px; font-size: 11px; }
  .nav__cta svg { display: none; }
  .nav__lang { min-width: 0; padding: 7px 11px; font-size: 11px; }
  .nav__burger { width: 38px; height: 38px; }

  /* hero */
  .hero { min-height: 560px; }
  .hero__logo { width: min(90vw, 460px); }
  .hero__tag { font-size: clamp(15px, 4.6vw, 20px); }
  .hero__links { gap: 18px; flex-direction: column; }
  .hero__link { font-size: 16px; }

  /* section rhythm */
  :root { --sec-y: clamp(72px, 12vh, 110px); }
  .statement { padding: clamp(90px, 16vh, 150px) var(--pad); }
  .statement__big { font-size: clamp(30px, 8.5vw, 52px); line-height: 1.32; }
  .statement__sub { font-size: 15px; line-height: 1.95; }

  .bleed { min-height: 460px; }
  .bleed__title--big { font-size: clamp(28px, 8vw, 46px); white-space: normal; }
  .bleed__sub { font-size: 14px; }

  .h-sec { font-size: clamp(26px, 7.5vw, 40px); }
  .lede-sec { font-size: 15px; }
  .sec__head { margin-bottom: clamp(40px, 8vh, 64px); }

  /* core value */
  .value-row { padding: clamp(34px, 6vh, 56px) 0; }
  .value-row__num { font-size: 56px; }
  .value-row__title { font-size: clamp(21px, 6vw, 28px); }
  .value-row__text { font-size: 15px; line-height: 1.95; }

  /* technology bento */
  .bento__card { min-height: 0; }
  .bento__media { height: 200px; }
  .bento__title { font-size: clamp(21px, 6vw, 27px); }
  .bento__text { font-size: 14px; }

  /* applications: 2-up, labels readable */
  .gallery { gap: 10px; }
  .gallery__item { flex: 0 0 calc(50% - 5px); border-radius: 13px; }
  .gallery__label { font-size: 13px !important; }
  .gallery__item:hover { transform: none; }
  .gallery__item:active { transform: scale(1.04); }

  /* products: 1 column for legibility of catalog images */
  .products { grid-template-columns: 1fr 1fr; gap: 14px; }
  .product:hover .product__card { transform: none; box-shadow: none; }
  .product__name { font-size: 13px; }
  .product__cat { font-size: 11px; }

  /* evolution */
  .evo2__compare { grid-template-columns: 1fr; }
  .evo2__features { grid-template-columns: 1fr 1fr; }
  .evo2__col--black:hover { transform: none; }
  .evo2__name { font-size: clamp(20px, 6vw, 28px); }

  /* cta */
  .cta__title { font-size: clamp(32px, 9vw, 60px); }
  .cta__sub { font-size: 15px; }
  .cta__btn--overlay { font-size: 13px; padding: 13px 22px; }

  /* official card stacks */
  .official { padding: 26px 22px; }
  .official__title { font-size: 16px; }

  /* keep floating controls clear of thumbs */
  .bgm-toggle { right: 14px; bottom: 14px; width: 42px; height: 42px; }
  #bgm-prompt { right: 14px; bottom: 66px; font-size: 12px; }
}

/* very small phones */
@media (max-width: 380px) {
  .gallery__item { flex: 0 0 100%; }
  .products { grid-template-columns: 1fr; }
  .evo2__features { grid-template-columns: 1fr; }
  .nav__cta { display: none; }   /* Request Sample lives in the menu / CTA section */
}
