/* Mahina Menu v6.48 — main-site header structure, best-site language control,
   pasta subsection labels, media-origin footer, and refined art cursor. */

.topbar.mahina-main-header {
  isolation: isolate;
  justify-content: space-between;
  padding-inline: clamp(18px, 5vw, 72px);
}

.topbar.mahina-main-header > .brand {
  position: absolute !important;
  top: 50%;
  left: 50%;
  z-index: 3;
  display: inline-flex;
  width: 138px;
  height: auto;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
}

.topbar.mahina-main-header > .brand img {
  width: 100% !important;
  height: auto !important;
  object-fit: contain;
  object-position: center;
}

.topbar.mahina-main-header > .topbar-menu-title {
  display: none !important;
}

.topbar.mahina-main-header > .topbar-actions {
  position: relative;
  z-index: 4;
  margin-left: auto;
  gap: 9px;
}

.topbar.mahina-main-header .topbar-actions > .menu-button {
  display: none !important;
}

.mahina-header-menu-trigger {
  position: relative;
  z-index: 4;
  display: inline-flex;
  min-width: 72px;
  min-height: 38px;
  align-items: center;
  gap: 9px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--mahina-popup-font);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.mahina-header-menu-trigger:hover {
  color: #111;
}

.mahina-header-menu-trigger:focus-visible {
  border-radius: 5px;
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.mahina-header-menu-glyph {
  position: relative;
  display: inline-block;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
}

.mahina-header-menu-glyph::before,
.mahina-header-menu-glyph::after {
  position: absolute;
  left: 2px;
  width: 18px;
  height: 1.4px;
  border-radius: 999px;
  background: currentColor;
  content: "";
}

.mahina-header-menu-glyph::before {
  top: 7px;
}

.mahina-header-menu-glyph::after {
  bottom: 7px;
}

.mahina-header-phone {
  padding-right: 13px;
  border-right: 1px solid var(--line);
  color: var(--mahina-popup-soft);
  font-family: var(--mahina-popup-font);
  font-size: 11px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.topbar.mahina-main-header .mode-button {
  min-width: 0;
  max-width: 164px;
  background: rgba(30, 30, 32, 0.045);
}

.topbar.mahina-main-header .mahina-language-trigger {
  min-width: 76px;
  height: 34px;
  gap: 5px;
  padding-inline: 10px;
}

.mahina-language-trigger > svg:not(.mahina-language-chevron) {
  width: 14px;
  height: 14px;
  stroke-width: 1.45;
}

.mahina-language-trigger .mahina-language-chevron {
  width: 8px;
  height: 6px;
  flex: 0 0 auto;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Match the current MAIN navigation-dialog geometry while retaining MENU links. */
.overlay.mahina-menu-overlay {
  padding: 22px;
}

.mahina-menu-panel.nav-drawer {
  width: min(100%, 700px);
  max-height: calc(100svh - 44px);
  border-radius: 28px;
  padding: clamp(26px, 4vw, 42px);
}

.mahina-pasta-subsection {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  margin: 4px 0 0;
  padding: 15px 0 7px;
  border-top: 1px solid rgba(83, 78, 70, 0.34);
  color: #37342f;
  text-align: start;
}

.mahina-pasta-subsection strong {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.09em;
  line-height: 1.3;
  text-transform: uppercase;
}

.mahina-pasta-subsection small {
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.3;
  text-transform: uppercase;
}

.mahina-pasta-subsection + .menu-item {
  border-top: 0;
  padding-top: 12px;
}

html[data-menu-rtl="true"] .mahina-pasta-subsection {
  text-align: right;
}

/* The default triangle keeps its exact point while gaining an external shadow
   and an internal beveled highlight. */
.art-cursor-arrow {
  contain: layout style;
  overflow: visible;
  background:
    radial-gradient(circle at 13% 12%, rgba(255, 255, 255, 1) 0 4%, rgba(255, 255, 255, 0.7) 8%, transparent 25%),
    linear-gradient(315deg, rgba(246, 249, 253, 0.98) 0%, rgba(174, 187, 205, 0.93) 31%, rgba(73, 82, 98, 0.82) 67%, rgba(35, 39, 47, 0.32) 100%);
  -webkit-backdrop-filter: blur(2.4px) saturate(122%);
  backdrop-filter: blur(2.4px) saturate(122%);
  filter:
    drop-shadow(1.4px 2.2px 2.4px rgba(15, 19, 27, 0.38))
    drop-shadow(-0.45px -0.45px 0.65px rgba(255, 255, 255, 0.9));
  box-shadow:
    inset 0.8px 0.8px 0 rgba(255, 255, 255, 0.72),
    inset -1px -1px 1px rgba(24, 30, 40, 0.24);
}

.art-cursor-arrow::before {
  inset: -10% -16%;
  background: linear-gradient(315deg, rgba(255, 255, 255, 0.94) 0%, rgba(255, 255, 255, 0.46) 25%, transparent 57%);
}

.art-cursor-arrow::after {
  content: "";
  position: absolute;
  inset: 1px;
  pointer-events: none;
  clip-path: polygon(0 0, 100% 38%, 38% 100%);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.86) 0%, rgba(255, 255, 255, 0.28) 24%, transparent 48%);
  opacity: 0.92;
}

/* The shared 19px hover point is reduced by 30%: 13.3px.
   Pressed state follows the same ratio: 12px to 8.4px. */
.art-cursor-lens {
  width: 13.3px;
  height: 13.3px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 31% 27%, rgba(255, 255, 255, 0.98) 0 12%, rgba(255, 255, 255, 0.64) 18%, transparent 39%),
    linear-gradient(145deg, rgba(105, 133, 169, 0.9), rgba(40, 49, 63, 0.76));
  -webkit-backdrop-filter: blur(1.2px) saturate(124%);
  backdrop-filter: blur(1.2px) saturate(124%);
  filter: blur(0.32px) saturate(1.08);
  box-shadow:
    0 0 0 0.85px rgba(30, 37, 48, 0.58),
    0 2.2px 6.5px rgba(32, 48, 72, 0.34),
    inset 0 1px 1.5px rgba(255, 255, 255, 0.78);
}

.art-cursor-lens::before {
  inset: 0.8px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.62), rgba(105, 137, 178, 0.24));
  filter: none;
}

.art-cursor-lens.is-positioned.is-interactive {
  opacity: 0.94;
  box-shadow:
    0 0 0 0.9px rgba(27, 34, 45, 0.64),
    0 2.5px 7px rgba(31, 48, 73, 0.4),
    inset 0 1px 1.5px rgba(255, 255, 255, 0.84);
}

.art-cursor-lens.is-pressed {
  width: 8.4px;
  height: 8.4px;
  opacity: 0.96;
  filter: blur(0.2px) brightness(0.94) saturate(1.1);
}

.mahina-origin-footer {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 24px 20px 104px;
  border-top: 1px solid rgba(30, 30, 32, 0.08);
  background: #f7f7f5;
  color: var(--mahina-popup-soft);
  font-family: var(--mahina-popup-font);
  text-align: center;
}

.mahina-origin-copyright {
  margin: 0;
  color: rgba(30, 30, 32, 0.62);
  font-size: 9px;
  line-height: 1.5;
}

.mahina-origin-footer .mahina-media-origin {
  width: min(calc(100% - 32px), 660px);
  max-width: 660px;
  margin: 0;
  color: rgba(30, 30, 32, 0.55);
  font-size: 9.5px;
  font-weight: 450;
  line-height: 1.58;
  letter-spacing: 0.005em;
  text-align: center;
  text-wrap: balance;
  overflow-wrap: anywhere;
  white-space: pre-line;
}

@media (max-width: 1080px) {
  .mahina-header-phone {
    display: none;
  }

  .topbar.mahina-main-header .mode-button {
    max-width: 132px;
  }
}

@media (max-width: 720px) {
  .topbar.mahina-main-header {
    padding-inline: 10px 8px;
  }

  .topbar.mahina-main-header > .brand {
    width: 96px;
  }

  .mahina-header-menu-trigger {
    min-width: 36px;
  }

  .mahina-header-menu-trigger > span:last-child {
    display: none;
  }

  .topbar.mahina-main-header > .topbar-actions {
    gap: 4px;
  }

  .topbar.mahina-main-header .mode-button {
    max-width: 86px;
  }

  .topbar.mahina-main-header .mahina-language-trigger {
    min-width: 68px;
    height: 32px;
    padding-inline: 8px;
  }

  .overlay.mahina-menu-overlay {
    padding: 12px;
  }

  .mahina-menu-panel.nav-drawer {
    max-height: calc(100svh - 24px);
    border-radius: 22px;
  }

  .mahina-pasta-subsection {
    padding-top: 12px;
  }

  .mahina-origin-footer {
    padding: 20px 16px 92px;
  }

  .mahina-origin-footer .mahina-media-origin {
    width: min(100%, 620px);
    font-size: 8.8px;
  }
}

@media (max-width: 420px) {
  .topbar.mahina-main-header > .brand {
    width: 82px;
  }

  .topbar.mahina-main-header .mode-button {
    max-width: 70px;
    padding-inline: 8px;
  }

  .topbar.mahina-main-header .mahina-language-trigger {
    min-width: 58px;
    gap: 3px;
    padding-inline: 6px;
  }

  .mahina-language-trigger > svg:not(.mahina-language-chevron) {
    width: 13px;
    height: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .art-cursor-arrow::before,
  .art-cursor-lens::before {
    animation: none;
  }
}
