.public-navbar {
  position: sticky;
  top: 0;
  z-index: 90;
  border-bottom: 1px solid transparent;
  background: rgba(6, 10, 18, 0.5);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.public-navbar[data-scrolled="true"] {
  background: rgba(6, 10, 18, 0.86);
  border-bottom-color: var(--stroke);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.28);
}

.navbar-inner {
  min-height: var(--nav-height);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
}

.navbar-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  min-height: 42px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(224, 192, 122, 0.3);
  color: #f0d39c;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.05em;
}

.brand-name {
  font-size: 1.48rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: -0.02em;
}

.navbar-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.navbar-links a {
  position: relative;
  color: var(--muted);
  padding: 9px 12px;
  border-radius: 10px;
}

.mobile-leader-link {
  display: none;
}

.navbar-links a::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 4px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--gold), var(--gold2));
  transform: scaleX(0.7);
  opacity: 0;
  transition: transform 180ms ease, opacity 180ms ease;
}

.navbar-links a:hover,
.navbar-links a.is-active {
  color: rgba(255, 255, 255, 0.95);
}

.navbar-links a:hover::after,
.navbar-links a.is-active::after {
  transform: scaleX(1);
  opacity: 1;
}

.navbar-actions {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 10px;
}

.menu-btn {
  display: none;
  flex-direction: column;
}

.menu-btn span {
  width: 18px;
  height: 2px;
  border-radius: 10px;
  background: #fff;
}

.menu-btn span + span {
  margin-top: 4px;
}

.site-main {
  display: grid;
  gap: var(--section-gap);
  padding-top: 12px;
}

.page-section {
  padding-top: 12px;
}

.section-head {
  margin-bottom: 18px;
  display: grid;
  gap: 8px;
}

.section-head p {
  color: var(--muted);
}

.section-head-centered {
  text-align: center;
  justify-items: center;
}

.section-block {
  margin-top: 26px;
}

.card-header-inline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.empty-state {
  display: grid;
  gap: 8px;
  justify-items: start;
  border-radius: var(--r-md);
  border: 1px dashed rgba(255, 255, 255, 0.25);
  padding: 14px;
  background: rgba(255, 255, 255, 0.04);
}

.empty-state-icon {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.1);
}

.calendar-nav {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}

.calendar-nav h3 {
  text-align: center;
  text-transform: capitalize;
  font-size: 1.18rem;
}

.calendar-weekdays,
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.calendar-weekdays {
  margin-bottom: 6px;
}

.calendar-weekdays span {
  text-align: center;
  color: var(--muted2);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-size: 0.73rem;
}

.cal-day {
  min-height: 84px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  padding: 6px;
  cursor: pointer;
}

.cal-day-number {
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
}

.cal-day-events {
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cal-day--today {
  border-color: rgba(224, 192, 122, 0.86);
  background: rgba(224, 192, 122, 0.16);
}

.cal-day--selected {
  box-shadow: inset 0 0 0 1px rgba(224, 192, 122, 0.8);
}

.cal-day--has-events {
  border-color: rgba(128, 170, 255, 0.88);
}

.cal-day--empty {
  border: 0;
  background: transparent;
  pointer-events: none;
}

.event-badge,
.event-more,
.event-dot {
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.96);
  min-height: 24px;
  padding: 2px 8px;
  font-size: 0.72rem;
  text-align: left;
}

.event-dot {
  width: 8px;
  min-height: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  background: var(--gold2);
}

.notice-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.notice-chip {
  width: auto;
  min-height: 38px;
  border-radius: var(--r-pill);
}

.notice-chip .chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--gold2);
}

.progress-wrap {
  margin-top: 10px;
}

.progress-bar {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.16);
}

.progress {
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--gold2));
  transition: width 180ms ease;
}

.campaign-public-grid {
  display: grid;
  gap: 10px;
}

.campaign-public-card,
.public-day-event-item,
.pix-qr-card,
.pix-copy-card {
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--r-md);
  padding: 12px;
  background: rgba(7, 11, 20, 0.42);
}

.copy-feedback {
  opacity: 0;
  transition: opacity 150ms ease;
  color: var(--gold2);
}

.copy-feedback--show {
  opacity: 1;
}

.feedback-inline {
  margin-top: 10px;
  border-radius: var(--r-sm);
  padding: 9px 11px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
}

.feedback-inline--success {
  color: #d3ffde;
}

.feedback-inline--error {
  color: #ffd8d3;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 14px;
  background: rgba(2, 4, 10, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.modal[hidden] {
  display: none;
}

.modal-card {
  width: min(760px, 100%);
  max-height: min(88vh, 860px);
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--r-lg);
  background: linear-gradient(160deg, rgba(15, 24, 43, 0.98), rgba(7, 12, 22, 0.98));
  box-shadow: var(--shadow-md);
  padding: 18px;
  position: relative;
}

.modal-close {
  position: absolute;
  right: 10px;
  top: 8px;
  width: 34px;
  min-width: 34px;
  min-height: 34px;
  font-size: 1.2rem;
  padding: 0;
  border-radius: 999px;
}

.public-day-events {
  margin-top: 10px;
  display: grid;
  gap: 10px;
}

.event-actions-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 0;
}

.event-actions-row .btn-secondary {
  width: 100%;
  min-height: 42px;
}

@media (max-width: 560px) {
  .event-actions-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .modal-card {
    width: min(100%, 100vw);
    max-height: min(92vh, 92dvh);
    border-radius: 16px;
    padding: 14px;
  }

  .public-day-event-item .destaque-thumb {
    min-height: 180px !important;
  }
}

.public-footer {
  margin-top: 36px;
  border-top: 1px solid var(--stroke);
  background: linear-gradient(180deg, rgba(7, 11, 20, 0.24), rgba(7, 11, 20, 0.94));
  padding: 26px 0 34px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 18px;
}

.footer-grid h3 {
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.footer-grid p,
.footer-grid a {
  color: var(--muted);
  margin-bottom: 4px;
  display: block;
}

.service-times-lines {
  display: grid;
  gap: 4px;
}

.service-times-lines p {
  margin: 0;
}

.footer-grid a:hover {
  color: #fff;
}

@media (max-width: 1200px) {
  .brand-name {
    font-size: 1.24rem;
  }

  .navbar-links a {
    padding-inline: 8px;
  }
}

@media (max-width: 900px) {
  :root {
    --nav-height: 68px;
  }

  .navbar-inner {
    grid-template-columns: auto 1fr auto;
  }

  .brand-name {
    display: none;
  }

  .menu-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .navbar-links {
    position: absolute;
    left: 12px;
    right: 12px;
    top: calc(var(--nav-height) - 2px);
    border: 1px solid var(--stroke);
    border-radius: var(--r-md);
    background: rgba(7, 11, 20, 0.95);
    box-shadow: var(--shadow-md);
    padding: 8px;
    display: grid;
    gap: 2px;
    opacity: 0;
    transform: translateY(-5px);
    pointer-events: none;
    transition: opacity 160ms ease, transform 160ms ease;
  }

  .public-navbar.nav-open .navbar-links {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .navbar-links a {
    width: 100%;
    padding: 10px;
  }

  .navbar-actions .btn-primary {
    display: none;
  }

  .navbar-actions {
    gap: 8px;
  }

  .navbar-actions > a.icon-circle[href="/admin.html"] {
    display: inline-flex;
  }

  .mobile-leader-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 4px;
    border: 1px solid rgba(224, 192, 122, 0.35);
    background: rgba(224, 192, 122, 0.1);
    color: #f6dca7 !important;
    font-weight: 700;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .calendar-nav {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "header header"
      "prev next";
  }

  .calendar-nav h3 {
    grid-area: header;
  }

  .calendar-nav button:first-child {
    grid-area: prev;
  }

  .calendar-nav button:last-child {
    grid-area: next;
  }

  .calendar-weekdays,
  .calendar-grid {
    gap: 4px;
  }

  .cal-day {
    min-height: 68px;
    padding: 5px;
  }

  .event-badge,
  .event-more {
    font-size: 0;
    min-height: 8px;
    height: 8px;
    border: 0;
    padding: 0;
    width: 8px;
    background: var(--gold2);
  }

  .notice-chips {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 6px;
  }

  .modal {
    place-items: end center;
    padding: 0;
  }

  .modal-card {
    width: 100%;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    max-height: min(84vh, 780px);
    padding-bottom: 24px;
  }
}

@media (max-width: 390px) {
  .navbar-actions {
    gap: 6px;
  }

  .navbar-actions .icon-circle {
    width: 38px;
    min-width: 38px;
    height: 38px;
  }
}

@media (max-width: 390px) {
  .container {
    width: min(var(--max-content), calc(100% - 14px));
  }

  .chip {
    padding-inline: 11px;
    min-height: 32px;
  }
}
