/* MGF.AI — App shell (bottom nav, mobile topbar, safe-area, polish) */

:root {
  --mgf-bottom-nav-h: 4.5rem;
  --mgf-navbar-h: 72px;
}

/* ── App shell body ── */
body.mgf-app-shell {
  padding-bottom: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px));
}

body.mgf-app-shell.mgf-chat-page {
  padding-bottom: 0;
}

body.mgf-app-shell .immersive-bg img {
  opacity: 0.42;
  filter: brightness(0.45) contrast(1.05);
}

@media (min-width: 769px) {
  body.mgf-app-shell {
    padding-bottom: 0;
  }
  body.mgf-app-shell .immersive-bg img {
    opacity: 0.55;
  }
  body.mgf-app-shell:not(.mgf-chat-page) main.container {
    width: 100%;
    max-width: min(1360px, 94vw);
    margin-left: auto;
    margin-right: auto;
  }
  body.mgf-app-shell .navbar {
    padding: 0 2rem;
    height: var(--mgf-navbar-h, 72px);
  }
  body.mgf-app-shell .nav-tier-badge {
    display: inline-flex;
  }
}

/* ── Mobile topbar compact ── */
@media (max-width: 768px) {
  :root {
    --mgf-navbar-h: 56px;
  }
  body.mgf-app-shell .navbar {
    padding: 0 1rem;
    height: 56px;
    gap: 0.75rem;
  }
  body.mgf-app-shell .nav-actions .theme-switch {
    width: 52px;
    height: 28px;
    margin-right: 0;
  }
  body.mgf-app-shell .nav-tier-badge {
    display: none;
  }
  body.mgf-app-shell .mobile-menu-toggle {
    display: none !important;
  }
}

@media (min-width: 769px) {
  body.mgf-app-shell .mobile-menu-toggle {
    display: none !important;
  }
}

/* ── Bottom navigation ── */
.mgf-bottom-nav {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1005;
  height: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(6, 7, 11, 0.96);
  backdrop-filter: blur(24px) saturate(1.15);
  -webkit-backdrop-filter: blur(24px) saturate(1.15);
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 -1px 0 rgba(255, 255, 255, 0.04), 0 -12px 40px rgba(0, 0, 0, 0.55);
}

body.mgf-app-shell .mgf-bottom-nav {
  display: flex;
}

body.mgf-app-shell.mgf-chat-page .mgf-bottom-nav {
  display: none;
}

@media (min-width: 769px) {
  .mgf-bottom-nav {
    display: none !important;
  }
}

.mgf-bottom-nav__inner {
  display: flex;
  align-items: stretch;
  justify-content: space-around;
  width: 100%;
  max-width: none;
  margin: 0;
  height: var(--mgf-bottom-nav-h);
  padding: 0 0.15rem;
}

.mgf-bottom-nav__item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  min-width: 0;
  min-height: 44px;
  padding: 0.4rem 0.15rem 0.35rem;
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  position: relative;
  transition: color 0.2s, transform 0.15s ease;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.mgf-bottom-nav__item:hover,
.mgf-bottom-nav__item:focus-visible {
  color: var(--text);
  outline: none;
}

.mgf-bottom-nav__item:active {
  transform: scale(0.9);
}

.mgf-bottom-nav__item.is-active {
  color: var(--primary);
}

.mgf-bottom-nav__item.is-active::before {
  content: "";
  position: absolute;
  inset: 0.28rem 0.05rem 0.38rem;
  border-radius: 0.85rem;
  background: rgba(255, 51, 119, 0.1);
  z-index: 0;
  pointer-events: none;
  animation: mgfTabPillIn 0.38s cubic-bezier(0.34, 1.45, 0.64, 1) both;
}

.mgf-bottom-nav__item .mgf-bottom-nav__icon,
.mgf-bottom-nav__item .mgf-bottom-nav__label {
  position: relative;
  z-index: 1;
}

.mgf-bottom-nav__item.is-pressing .mgf-bottom-nav__icon {
  transform: scale(0.72);
  transition: transform 0.07s cubic-bezier(0.4, 0, 0.6, 1);
}

.mgf-bottom-nav__item.is-pressing:not(.is-active) .mgf-bottom-nav__label {
  opacity: 0.75;
  transition: opacity 0.07s ease;
}

.mgf-bottom-nav__item.is-tab-arrived .mgf-bottom-nav__icon {
  animation: mgfTabIconPop 0.48s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.mgf-bottom-nav__item.is-tab-arrived::after {
  animation: mgfTabIndicatorPop 0.42s cubic-bezier(0.34, 1.45, 0.64, 1) both;
}

.mgf-bottom-nav__item.is-active::after {
  content: "";
  position: absolute;
  bottom: 0.2rem;
  left: 50%;
  transform: translateX(-50%);
  width: 1.35rem;
  height: 2px;
  border-radius: 999px;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary-glow, rgba(255, 51, 119, 0.5));
}

.mgf-bottom-nav__icon {
  font-size: 1.35rem;
  line-height: 1;
  transition: transform 0.2s ease, filter 0.2s ease;
}

.mgf-bottom-nav__item.is-active .mgf-bottom-nav__icon {
  transform: translateY(-1px) scale(1.06);
  filter: drop-shadow(0 0 6px var(--primary-glow, rgba(255, 51, 119, 0.45)));
}

.mgf-bottom-nav__label {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.1;
  padding: 0 0.1rem;
}

.mgf-bottom-nav__led {
  position: absolute;
  top: 0.45rem;
  right: calc(50% - 1.15rem);
}

/* ── Adaptive flashes ── */
@media (max-width: 768px) {
  .flashes {
    top: auto;
    bottom: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px) + 0.75rem);
    left: 1rem;
    right: 1rem;
    align-items: stretch;
  }
  .flash {
    max-width: none;
    animation-name: mgfFlashSlideUp;
  }
  body.mgf-chat-page .flashes {
    bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  }
}

/* ── Hide desktop nav on mobile (bottom nav replaces it) ── */
@media (max-width: 768px) {
  body.mgf-app-shell .nav-links {
    display: none !important;
  }
}

@media (min-width: 769px) {
  body.mgf-app-shell .nav-links {
    display: flex;
  }
}

/* ── Dashboard premium upsell above bottom nav ── */
@media (max-width: 768px) {
  body.mgf-app-shell .premium-floating {
    bottom: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px) + 0.75rem) !important;
    left: 1rem !important;
    right: 1rem !important;
    width: auto !important;
  }
}

/* ── Dashboard resume card ── */
.dash-resume-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 51, 119, 0.35);
  background: linear-gradient(135deg, rgba(255, 51, 119, 0.12), rgba(255, 255, 255, 0.03));
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, transform 0.2s;
  position: relative;
}
.dash-resume-led {
  position: absolute;
  left: 0.55rem;
  top: 50%;
  transform: translateY(-50%);
}
.dash-resume-card.conv-has-unread {
  padding-left: 2rem;
}
.dash-resume-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}
.dash-resume-card__avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.dash-resume-card__body { flex: 1; min-width: 0; }
.dash-resume-card__label {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary);
  margin-bottom: 0.15rem;
}
.dash-resume-card__name {
  font-weight: 900;
  font-size: 1.05rem;
  margin-bottom: 0.2rem;
}
.dash-resume-card__preview {
  font-size: 0.85rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-resume-card__cta {
  flex-shrink: 0;
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--primary);
}

/* ── Profile accordion (settings cards) ── */
@media (max-width: 768px) {
  .settings-card.mgf-profile-accordion > h2,
  .settings-card.mgf-profile-accordion > h3 {
    display: none;
  }
  .settings-card.mgf-profile-accordion .profile-section__body {
    display: none;
  }
  .settings-card.mgf-profile-accordion.is-open .profile-section__body {
    display: block;
  }
  .settings-card.mgf-profile-accordion .profile-section__toggle {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    margin-bottom: 0.75rem;
    color: var(--text);
    font-family: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    text-align: left;
  }
  .subscription-teaser.mgf-profile-accordion .profile-section__toggle {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    margin-bottom: 0.75rem;
    color: var(--text);
    font-family: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    text-align: left;
  }
  .subscription-teaser.mgf-profile-accordion .profile-section__body {
    display: none;
  }
  .subscription-teaser.mgf-profile-accordion.is-open .profile-section__body {
    display: block;
  }
}

@media (min-width: 769px) {
  .settings-card.mgf-profile-accordion .profile-section__toggle,
  .subscription-teaser.mgf-profile-accordion .profile-section__toggle {
    display: none;
  }
  .settings-card.mgf-profile-accordion .profile-section__body,
  .subscription-teaser.mgf-profile-accordion .profile-section__body {
    display: block !important;
  }
}

@keyframes mgfFlashSlideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* ── Page title utilities ── */
.mgf-page-title {
  font-size: clamp(1.75rem, 5vw, 3.5rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin-bottom: 0.5rem;
}

.mgf-page-sub {
  color: var(--text-muted);
  font-size: clamp(0.9rem, 2.5vw, 1.1rem);
  font-weight: 600;
}

.mgf-page-header {
  margin-bottom: clamp(1.5rem, 4vw, 3rem);
}

.mgf-page-header--center {
  text-align: center;
}

/* ── Sticky subheaders (Discover / Gallery) ── */
.mgf-sticky-subheader {
  position: sticky;
  top: var(--mgf-navbar-h, 72px);
  z-index: 900;
  margin-bottom: 1.5rem;
  padding: 0.75rem 0 1rem;
  background: linear-gradient(180deg, rgba(3, 4, 7, 0.96) 0%, rgba(3, 4, 7, 0.88) 75%, transparent 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

@media (max-width: 768px) {
  .mgf-sticky-subheader {
    top: 56px;
  }
}

/* ── Horizontal scroll hint ── */
.mgf-scroll-hint-wrap {
  position: relative;
}

.mgf-scroll-hint-wrap::after {
  content: "→";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 1.25rem;
  color: var(--text-muted);
  opacity: 0.7;
  padding-right: 0.5rem;
  animation: mgfScrollHintPulse 2s ease-in-out infinite;
}

@media (min-width: 769px) {
  .mgf-scroll-hint-wrap::after {
    display: none;
  }
}

@keyframes mgfScrollHintPulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.9; }
}

/* ── Dashboard feed mobile ── */
@media (max-width: 768px) {
  .dash-container {
    display: block !important;
    padding: 0 0 calc(5rem + env(safe-area-inset-bottom, 0px)) !important;
    min-height: auto !important;
  }
  .dash-hero {
    margin-top: 0.5rem !important;
    margin-bottom: 1.5rem !important;
    align-items: flex-start !important;
    text-align: left !important;
  }
  .hero-title {
    font-size: clamp(1.75rem, 7vw, 2.5rem) !important;
  }
}

/* ── Contacts inbox mobile ── */
@media (max-width: 768px) {
  .inbox-container {
    margin: 1rem auto 5rem !important;
    padding: 0 1rem !important;
  }
  .inbox-header h1 {
    font-size: clamp(1.75rem, 6vw, 2.5rem) !important;
  }
}

/* ── Discover mobile ── */
@media (max-width: 768px) {
  .discover-container {
    margin: 0 auto !important;
    padding: 0 1rem calc(5rem + env(safe-area-inset-bottom, 0px)) !important;
  }
  .discover-page-header h1 {
    font-size: clamp(1.75rem, 6vw, 2.2rem) !important;
  }
  .discover-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0.75rem !important;
  }
}

/* ── Mobile app native polish (logged-in shell) ── */
@media (max-width: 768px) {
  body.mgf-app-shell {
    overscroll-behavior-y: contain;
    -webkit-tap-highlight-color: transparent;
  }

  body.mgf-app-shell:not(.mgf-chat-page) .site-footer {
    display: none;
  }

  body.mgf-app-shell .navbar {
    position: sticky;
    top: 0;
    background: rgba(6, 7, 11, 0.9);
    backdrop-filter: blur(20px) saturate(1.15);
    -webkit-backdrop-filter: blur(20px) saturate(1.15);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.03);
  }

  body.mgf-app-shell .navbar-brand {
    font-size: 1.2rem;
  }

  body.mgf-app-shell:not(.mgf-chat-page) main.container {
    width: 100%;
    max-width: 100%;
    padding-left: 1rem;
    padding-right: 1rem;
    overflow-x: hidden;
    box-sizing: border-box;
  }

  body.mgf-app-shell .mgf-page-header {
    margin-bottom: 1.25rem;
  }

  body.mgf-app-shell .mgf-page-title {
    font-size: 1.65rem;
    letter-spacing: -0.03em;
  }

  body.mgf-app-shell .mgf-page-sub {
    font-size: 0.88rem;
  }

  /* Conversation / inbox rows — iOS-style list */
  body.mgf-app-shell .message-item,
  body.mgf-app-shell .message-item-lg {
    padding: 0.85rem 1rem;
    gap: 0.85rem;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.06);
    box-shadow: none;
  }

  body.mgf-app-shell .message-item:active,
  body.mgf-app-shell .message-item-lg:active {
    transform: scale(0.985);
    background: rgba(255, 255, 255, 0.07);
  }

  body.mgf-app-shell .message-item:hover,
  body.mgf-app-shell .message-item-lg:hover {
    transform: none;
    box-shadow: none;
  }

  body.mgf-app-shell .msg-avatar-wrap {
    width: 48px;
    height: 48px;
  }

  body.mgf-app-shell .message-item-lg .msg-avatar-wrap {
    width: 56px;
    height: 56px;
  }

  body.mgf-app-shell .msg-name {
    font-size: 1rem;
  }

  body.mgf-app-shell .message-item-lg .msg-name {
    font-size: 1.05rem;
  }

  body.mgf-app-shell .msg-preview {
    font-size: 0.85rem;
  }

  body.mgf-app-shell .msg-action {
    display: none;
  }

  body.mgf-app-shell .dash-resume-card {
    border-radius: 1rem;
    padding: 0.85rem 1rem;
    margin-bottom: 1rem;
  }

  body.mgf-app-shell .stat-glass {
    border-radius: 1rem;
    padding: 0.85rem 0.75rem;
  }

  body.mgf-app-shell .portrait-card {
    border-radius: 1rem;
  }
}

@media (max-width: 768px) and (hover: hover) {
  body.mgf-app-shell .message-item:hover,
  body.mgf-app-shell .message-item-lg:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
  }
}

/* ── Haptic tab transitions (mobile app shell) ── */
@keyframes mgfTabIconPop {
  0% { transform: scale(0.75); }
  42% { transform: translateY(-3px) scale(1.14); }
  68% { transform: translateY(-1px) scale(1.02); }
  100% { transform: translateY(-1px) scale(1.06); }
}

@keyframes mgfTabPillIn {
  0% { transform: scale(0.55); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes mgfTabIndicatorPop {
  0% { transform: translateX(-50%) scaleX(0.2); opacity: 0; }
  100% { transform: translateX(-50%) scaleX(1); opacity: 1; }
}

@keyframes mgfPageEnterFromRight {
  from {
    opacity: 0.42;
    transform: translateX(44px) scale(0.975);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes mgfPageEnterFromLeft {
  from {
    opacity: 0.42;
    transform: translateX(-44px) scale(0.975);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes mgfPageExitToLeft {
  from {
    opacity: 1;
    transform: none;
  }
  to {
    opacity: 0.35;
    transform: translateX(-40px) scale(0.975);
  }
}

@keyframes mgfPageExitToRight {
  from {
    opacity: 1;
    transform: none;
  }
  to {
    opacity: 0.35;
    transform: translateX(40px) scale(0.975);
  }
}

@media (max-width: 768px) {
  body.mgf-app-shell.mgf-tab-navigating {
    overflow: hidden;
  }

  body.mgf-app-shell.mgf-tab-navigating .mgf-bottom-nav {
    pointer-events: none;
  }

  body.mgf-app-shell.mgf-tab-navigating main.container.mgf-tab-exit-left {
    animation: mgfPageExitToLeft 0.32s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  }

  body.mgf-app-shell.mgf-tab-navigating main.container.mgf-tab-exit-right {
    animation: mgfPageExitToRight 0.32s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  }

  html.mgf-tab-enter-right body.mgf-app-shell:not(.mgf-chat-page) main.container,
  body.mgf-app-shell:not(.mgf-chat-page) main.container.mgf-tab-enter-right {
    animation: mgfPageEnterFromRight 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  html.mgf-tab-enter-left body.mgf-app-shell:not(.mgf-chat-page) main.container,
  body.mgf-app-shell:not(.mgf-chat-page) main.container.mgf-tab-enter-left {
    animation: mgfPageEnterFromLeft 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
  }
}

/* ── UX hints (swipe + PWA) ── */
@keyframes mgfHintIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@keyframes mgfBannerIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  body.mgf-chat-page .mgf-swipe-hint,
  body.mgf-chat-page .mgf-pwa-banner {
    display: none !important;
  }

  .mgf-swipe-hint {
    position: fixed;
    left: 50%;
    bottom: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px) + 0.65rem);
    transform: translateX(-50%);
    z-index: 1006;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    max-width: min(22rem, calc(100vw - 2rem));
    padding: 0.55rem 0.65rem 0.55rem 0.75rem;
    border-radius: 999px;
    background: rgba(12, 13, 18, 0.94);
    border: 1px solid rgba(255, 51, 119, 0.35);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    animation: mgfHintIn 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .mgf-swipe-hint[hidden] {
    display: none !important;
  }

  .mgf-swipe-hint__icon {
    font-size: 1rem;
    color: var(--primary);
    flex-shrink: 0;
  }

  .mgf-swipe-hint__text {
    flex: 1;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.25;
  }

  .mgf-swipe-hint__dismiss {
    flex-shrink: 0;
    border: none;
    border-radius: 999px;
    padding: 0.35rem 0.65rem;
    background: rgba(255, 51, 119, 0.18);
    color: var(--primary);
    font-family: inherit;
    font-size: 0.72rem;
    font-weight: 800;
    cursor: pointer;
  }

  .mgf-pwa-banner {
    position: fixed;
    left: 0.75rem;
    right: 0.75rem;
    bottom: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px) + 0.65rem);
    z-index: 1010;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: 1rem;
    background: rgba(10, 11, 16, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    animation: mgfBannerIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
    pointer-events: auto;
  }

  .mgf-pwa-banner__actions .btn {
    pointer-events: auto;
    touch-action: manipulation;
  }

  .mgf-pwa-banner[hidden] {
    display: none !important;
  }

  .mgf-pwa-banner__title {
    margin: 0 0 0.2rem;
    font-size: 0.92rem;
    font-weight: 800;
  }

  .mgf-pwa-banner__text,
  .mgf-pwa-banner__ios {
    margin: 0;
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.35;
  }

  .mgf-pwa-banner__ios {
    margin-top: 0.35rem;
    color: var(--primary);
    font-weight: 700;
  }

  .mgf-pwa-banner__actions {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex-shrink: 0;
  }

  body.mgf-app-shell:has(.mgf-swipe-hint:not([hidden])) .mgf-pwa-banner:not([hidden]) {
    bottom: calc(var(--mgf-bottom-nav-h) + env(safe-area-inset-bottom, 0px) + 3.5rem);
  }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .mgf-scroll-hint-wrap::after {
    animation: none;
  }
  body.mgf-app-shell main.container.mgf-tab-enter-right,
  body.mgf-app-shell main.container.mgf-tab-enter-left {
    animation: none !important;
  }
  html.mgf-tab-enter-right body.mgf-app-shell main.container,
  html.mgf-tab-enter-left body.mgf-app-shell main.container {
    animation: none !important;
  }
  body.mgf-app-shell.mgf-tab-navigating main.container.mgf-tab-exit-left,
  body.mgf-app-shell.mgf-tab-navigating main.container.mgf-tab-exit-right {
    animation: none !important;
  }
  .mgf-bottom-nav__item.is-active::before,
  .mgf-bottom-nav__item.is-tab-arrived .mgf-bottom-nav__icon,
  .mgf-bottom-nav__item.is-tab-arrived::after {
    animation: none !important;
  }
}
