/*
 * NAVEGAÇÃO FLUTUANTE — CELULARES E TABLETS — 2.8.8
 * O menu desktop permanece inalterado.
 */

.mobile-bottom-nav {
  display: none;
}

.maps-hint {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: 560px;
  margin: -13px 0 22px;
  color: var(--muted);
  font-size: .82rem;
  line-height: 1.45;
}

.maps-hint .ui-icon {
  --icon-size: 1.05rem;
  color: var(--terracotta);
}

.maps-hint strong {
  color: var(--primary);
  font-weight: 850;
}

@media (max-width: 1100px) {
  body {
    padding-bottom:
      calc(108px + env(safe-area-inset-bottom));
  }

  .site-header {
    position: sticky;
    top: 0;
  }

  .header-inner {
    min-height: 72px !important;
    justify-content: center !important;
    gap: 0 !important;
  }

  .brand {
    width: 100%;
    max-width: none !important;
    justify-content: center;
    gap: 10px;
    text-align: center;
  }

  .brand img {
    width: 43px !important;
    height: 43px !important;
  }

  .brand span {
    max-width: min(68vw, 520px);
    font-size: clamp(1.18rem, 3.4vw, 1.7rem);
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }

  .menu-toggle,
  .site-nav {
    display: none !important;
  }

  .mobile-bottom-nav {
    position: fixed;
    left: 50%;
    bottom:
      calc(12px + env(safe-area-inset-bottom));
    z-index: 90;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: end;
    width: min(calc(100% - 28px), 620px);
    min-height: 72px;
    padding: 7px 9px;
    border: 1px solid rgba(98, 51, 6, .2);
    border-radius: 24px;
    background: rgba(255, 253, 249, .92);
    box-shadow:
      0 18px 48px rgba(52, 33, 22, .19),
      inset 0 1px 0 rgba(255, 255, 255, .82);
    -webkit-backdrop-filter: blur(20px) saturate(145%);
    backdrop-filter: blur(20px) saturate(145%);
    transform: translate(-50%, 0);
    opacity: 1;
    transition:
      transform .28s cubic-bezier(.22, .8, .25, 1),
      opacity .22s ease;
    will-change: transform, opacity;
  }

  .mobile-bottom-nav::before {
    content: "";
    position: absolute;
    inset: 7px;
    z-index: -1;
    border-radius: 18px;
    background:
      linear-gradient(
        180deg,
        rgba(247, 242, 233, .72),
        rgba(255, 253, 249, .3)
      );
    pointer-events: none;
  }

  .mobile-bottom-nav.is-hidden,
  .mobile-bottom-nav.is-keyboard-hidden,
  body.modal-open .mobile-bottom-nav {
    transform:
      translate(-50%, calc(100% + 34px));
    opacity: 0;
    pointer-events: none;
  }

  .mobile-bottom-nav a {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 58px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 6px 5px 5px;
    border-radius: 17px;
    color: var(--muted);
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
    transition:
      color .18s ease,
      background .18s ease,
      transform .18s ease;
  }

  .mobile-bottom-nav a:active {
    transform: scale(.96);
  }

  .mobile-bottom-nav a[aria-current="page"] {
    color: var(--primary);
    background: rgba(216, 193, 163, .34);
  }

  .mobile-nav-icon {
    display: grid;
    width: 38px;
    height: 34px;
    place-items: center;
    border-radius: 13px;
    transition:
      transform .18s ease,
      background .18s ease,
      color .18s ease,
      box-shadow .18s ease;
  }

  .mobile-nav-icon .ui-icon {
    --icon-size: 22px;
  }

  .mobile-nav-label {
    max-width: 100%;
    overflow: hidden;
    font-size: .68rem;
    font-weight: 850;
    line-height: 1.05;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-bottom-nav a[aria-current="page"]
  .mobile-nav-icon {
    transform: translateY(-1px);
    color: var(--warm-white);
    background: var(--primary);
    box-shadow: 0 7px 18px rgba(98, 51, 6, .23);
  }

  .mobile-bottom-nav .mobile-nav-primary {
    margin-top: -17px;
  }

  .mobile-bottom-nav .mobile-nav-primary
  .mobile-nav-icon {
    width: 51px;
    height: 51px;
    color: var(--warm-white);
    background:
      linear-gradient(
        145deg,
        var(--terracotta),
        var(--primary)
      );
    border: 4px solid var(--warm-white);
    border-radius: 50%;
    box-shadow:
      0 10px 25px rgba(98, 51, 6, .28),
      0 0 0 1px rgba(98, 51, 6, .1);
  }

  .mobile-bottom-nav .mobile-nav-primary
  .mobile-nav-icon .ui-icon {
    --icon-size: 24px;
  }

  .mobile-bottom-nav .mobile-nav-primary
  .mobile-nav-label {
    color: var(--primary);
  }

  .mobile-bottom-nav .mobile-nav-primary[
    aria-current="page"
  ] {
    background: rgba(216, 193, 163, .29);
  }

  .mobile-bottom-nav .mobile-nav-primary[
    aria-current="page"
  ] .mobile-nav-icon {
    box-shadow:
      0 11px 27px rgba(98, 51, 6, .34),
      0 0 0 3px rgba(216, 193, 163, .48);
  }

  .maps-hint {
    display: flex;
    justify-content: center;
    margin: -12px auto 21px;
    padding-inline: 10px;
    text-align: center;
  }

  .site-footer {
    padding-bottom:
      calc(26px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 700px) {
  .header-inner {
    min-height: 66px !important;
  }

  .brand {
    gap: 8px;
  }

  .brand img {
    width: 39px !important;
    height: 39px !important;
  }

  .brand span {
    max-width: 73vw;
    font-size: clamp(1.06rem, 5vw, 1.35rem);
  }

  .mobile-bottom-nav {
    bottom:
      calc(8px + env(safe-area-inset-bottom));
    width: min(calc(100% - 18px), 520px);
    min-height: 68px;
    padding: 6px 7px;
    border-radius: 22px;
  }

  .mobile-bottom-nav a {
    min-height: 56px;
    padding-inline: 3px;
  }

  .mobile-nav-label {
    font-size: .63rem;
  }

  .mobile-bottom-nav .mobile-nav-primary {
    margin-top: -15px;
  }

  .mobile-bottom-nav .mobile-nav-primary
  .mobile-nav-icon {
    width: 48px;
    height: 48px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-bottom-nav {
    transition: none;
  }

  .mobile-bottom-nav a,
  .mobile-nav-icon {
    transition: none;
  }
}


/* HOME NO CELULAR — CORREÇÃO 2.8.9
   Computador e tablet permanecem sem alteração. */
@media (max-width: 767px) {
  body[data-page="home"] .event-summary {
    display: grid !important;
    grid-template-columns:
      repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    margin: 13px 0 0 !important;
  }

  body[data-page="home"]
  .event-summary .event-pill {
    width: 100%;
    min-width: 0;
    min-height: 42px;
    justify-content: center;
    gap: 5px;
    padding: 7px 8px;
    overflow: visible;
    border-radius: 13px;
    font-size: .68rem;
    line-height: 1.15;
    white-space: nowrap;
  }

  body[data-page="home"]
  .event-summary .event-pill:last-child {
    grid-column: 1 / -1;
    min-height: 45px;
    color: var(--primary);
    background: rgba(216, 193, 163, .24);
  }

  body[data-page="home"]
  .event-summary .event-pill .ui-icon {
    --icon-size: 1rem;
    color: var(--terracotta);
  }

  body[data-page="home"] .maps-hint {
    display: flex;
    width: 100%;
    max-width: none;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 8px auto 15px;
    padding: 7px 10px;
    border: 1px solid rgba(98, 51, 6, .12);
    border-radius: 11px;
    color: var(--muted);
    background: rgba(255, 253, 249, .6);
    font-size: .68rem;
    line-height: 1.35;
    text-align: center;
  }

  body[data-page="home"] .maps-hint .ui-icon {
    --icon-size: .95rem;
    flex: 0 0 auto;
  }

  body[data-page="home"] .maps-hint strong {
    white-space: nowrap;
  }

  body[data-page="home"] .hero .actions {
    margin-top: 8px;
  }
}

@media (max-width: 359px) {
  body[data-page="home"] .event-summary {
    grid-template-columns: 1fr !important;
  }

  body[data-page="home"]
  .event-summary .event-pill:last-child {
    grid-column: auto;
  }

  body[data-page="home"] .maps-hint {
    align-items: flex-start;
    font-size: .65rem;
  }
}
