/* Shared light / dark surfaces for every public theme */

html {
  --theme-box-radius: 16px;
  --theme-box-radius-inner: 12px;
}

html[data-theme-mode="dark"] {
  color-scheme: dark;
}

html[data-theme-mode="light"] {
  color-scheme: light;
}

html[data-theme-mode] body {
  background: var(--color-background);
  color: var(--color-text);
}

html[data-theme-mode] .card,
html[data-theme-mode] .item-card,
html[data-theme-mode] .podcast-card,
html[data-theme-mode] .podcasts-empty,
html[data-theme-mode] .programs-board,
html[data-theme-mode] .program-card,
html[data-theme-mode] .presenters-board,
html[data-theme-mode] .presenter-card,
html[data-theme-mode] .guestbook-card,
html[data-theme-mode] .poll-card,
html[data-theme-mode] .home-split .section:not(.section-programs):not(.section-presenters):not(.section-news):not(.section-gallery):not(.section-videos):not(.section-guestbook):not(.section-requests):not(.theme-page-body) {
  background: var(--color-surface, var(--color-background));
  color: var(--color-text);
  border-color: var(--color-border, rgba(0, 0, 0, 0.08));
}

html[data-theme-mode] .home-split .section-programs,
html[data-theme-mode] .home-split .section-presenters,
html[data-theme-mode] .home-split .section-news,
html[data-theme-mode] .home-split .section-gallery,
html[data-theme-mode] .home-split .section.theme-page-body,
.home-split .section-programs,
.home-split .section-presenters,
.home-split .section-news,
.home-split .section-gallery,
.home-split .section.theme-page-body {
  background: transparent;
  box-shadow: none;
}

.news-home-board__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.news-home-board__head .schedule-board__title {
  flex: 1;
  min-width: 0;
}

.news-home-board__more {
  flex-shrink: 0;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-primary, #ff6b00);
  text-decoration: none;
  white-space: nowrap;
}

.news-home-board__more:hover {
  text-decoration: underline;
}

@media (max-width: 640px) {
  .news-home-board {
    padding: 0.9rem 0.75rem 1rem;
  }
}

.card-grid-news .news-feed__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem 0.4rem;
  margin: 0 0 0.4rem;
  color: color-mix(in srgb, var(--color-text, #1a1a1a) 58%, transparent);
  font-size: 0.72rem;
  line-height: 1.25;
}

.card-grid-news .news-feed__meta svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

.card-grid-news .news-feed__dot {
  opacity: 0.7;
}

.card-grid-news .news-feed__meta strong {
  color: var(--color-text, #1a1a1a);
  font-weight: 700;
}

.card-cover-link {
  display: block;
  position: relative;
  color: inherit !important;
  text-decoration: none !important;
}

.card-cover-link:hover,
.card-cover-link:focus,
.card-cover-link:visited {
  color: inherit !important;
  text-decoration: none !important;
}

.card-cover-link:hover .card-title {
  color: var(--color-primary, #ff6b00);
}


.card-grid-news .card-more {
  display: inline-block;
  margin-top: 0.35rem;
  color: var(--color-primary, #ff6b00);
  font-size: 0.8rem;
  font-weight: 600;
}

html[data-theme-mode="dark"] .theme-page-nav,
html[data-theme-mode="light"] .theme-page-nav {
  background: var(--color-surface, #fff);
  border-bottom-color: var(--color-border, rgba(0, 0, 0, 0.08));
}

html[data-theme-mode] .card-title,
html[data-theme-mode] .section-title,
html[data-theme-mode] .presenter-name,
html[data-theme-mode] .program-title {
  color: var(--color-text);
}

html[data-theme-mode] .site-header {
  background: var(--color-primary);
}

html[data-theme-mode="dark"] .site-logo,
html[data-theme-mode="dark"] .site-nav a,
html[data-theme-mode="dark"] .nav-toggle,
html[data-theme-mode="light"] .site-logo,
html[data-theme-mode="light"] .site-nav a {
  color: #fff;
}

html[data-theme-mode] .btn-listen,
html[data-theme-mode] .theme-page-nav__link.is-active {
  background: var(--color-primary);
  color: #fff;
}

html[data-theme-mode] a {
  color: var(--color-primary);
}

html[data-theme-mode] .site-header a,
html[data-theme-mode] .site-logo,
html[data-theme-mode] .site-nav a,
html[data-theme-mode] .nav-toggle,
html[data-theme-mode] .site-footer a,
html[data-theme-mode] .footer-nav a,
html[data-theme-mode] .footer-copy {
  color: #fff;
}

html[data-theme-mode] .site-footer {
  background: var(--color-primary);
}

/* Toggle claro / escuro no menu */
.header-menu {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 1.5vw, 1.75rem);
  margin-left: auto;
}

.theme-mode-toggle {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.15rem;
  height: 2.15rem;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  line-height: 0;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.theme-mode-toggle:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.theme-mode-toggle__icon {
  display: block;
  flex-shrink: 0;
}

.theme-mode-toggle__icon--moon {
  display: none;
}

.theme-mode-toggle.is-dark .theme-mode-toggle__icon--sun {
  display: none;
}

.theme-mode-toggle.is-dark .theme-mode-toggle__icon--moon {
  display: block;
}

.header-inner--nav-desktop .header-menu {
  margin-left: 0;
  display: contents;
}

html[data-theme-mode="dark"] .theme-mode-toggle {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(0, 0, 0, 0.22);
}

/* Caixas — cantos arredondados consistentes em todo o site */
.schedule-board,
.hosts-board,
.hosts-home-board,
.news-home-board,
.news-board,
.contact-board,
.static-page-board,
.banner-carousel,
.card,
.item-card,
.host-card,
.program-row,
.story-rail__card,
.podcast-card {
  border-radius: var(--theme-box-radius, 16px);
}

.schedule-board,
.hosts-board,
.hosts-home-board,
.news-home-board,
.news-board,
.contact-board,
.static-page-board {
  border-radius: var(--theme-box-radius, 16px);
  overflow: hidden;
  isolation: isolate;
}

.banner-carousel,
.story-rail__card,
.podcast-card {
  overflow: hidden;
}

.program-row__thumb,
.card-img,
.item-img {
  border-radius: var(--theme-box-radius-inner, 12px);
}

.program-row__thumb--fallback {
  border-radius: var(--theme-box-radius-inner, 12px);
}

.banner-carousel__empty {
  border-radius: var(--theme-box-radius);
}
