/* =========================================================
   Portal Premium — refinamento visual global
   Objetivo: unificar o portal com o mesmo critério premium,
   contraste consistente, superfícies estáveis e melhor leitura
   em tema claro/escuro, preservando a estrutura existente.
   ========================================================= */

:root{
  --portal-premium-radius-sm:14px;
  --portal-premium-radius-md:18px;
  --portal-premium-radius-lg:24px;
  --portal-premium-shadow-sm:0 12px 28px rgba(8,24,11,.08);
  --portal-premium-shadow-md:0 20px 44px rgba(8,24,11,.10);
  --portal-premium-shadow-lg:0 28px 56px rgba(8,24,11,.12);
  --portal-premium-surface:#ffffff;
  --portal-premium-surface-soft:#f7faf6;
  --portal-premium-surface-strong:#eef4ef;
  --portal-premium-border:rgba(8,24,11,.08);
  --portal-premium-border-strong:rgba(8,24,11,.12);
}

html[data-theme='dark']{
  --portal-premium-surface:#1b241d;
  --portal-premium-surface-soft:#202b23;
  --portal-premium-surface-strong:#263229;
  --portal-premium-border:rgba(237,244,232,.10);
  --portal-premium-border-strong:rgba(237,244,232,.16);
  --portal-premium-shadow-sm:0 16px 32px rgba(0,0,0,.22);
  --portal-premium-shadow-md:0 24px 46px rgba(0,0,0,.28);
  --portal-premium-shadow-lg:0 32px 62px rgba(0,0,0,.34);
}

body{
  text-rendering:optimizeLegibility;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
}

.section,
.home-carousel-section,
.section--olive,
.section--dark,
.home-carousel-section--olive,
.home-carousel-section--amber{
  position:relative;
}

.page-banner,
.portal-hero__surface,
.services-hero,
.services-highlight,
.cta-banner .container{
  border-radius:var(--portal-premium-radius-lg)!important;
  box-shadow:var(--portal-premium-shadow-md)!important;
  overflow:hidden;
}

.card,
.news-related__body .card,
.download-card,
.central-card,
.event-card,
.value-card,
.aviso-card,
.news-card,
.service-card,
.shop-info-card,
.shop-card,
.auth-card,
.aside__box,
.contact-bar__item,
.services-toolbar,
.news-list-compact,
.portal-hero__stat,
.portal-chip-card,
.portal-hero__panel-card,
.services-stat,
.services-tag,
.home-gallery-carousel-card,
.home-shop-carousel-card,
.home-pa-carousel-card,
.gallery-portal-search,
.gallery-portal-list__item,
.gallery-portal-card__caption,
.gallery-alego-album-head,
.gallery-alego-viewer__main,
.gallery-alego-viewer__side,
.gallery-alego-latest,
.statute-box,
.medalha-card,
.medalha-card--soft,
.medalha-kpi,
.medalha-leader,
.medalha-source,
.timeline__item,
.pa-search-bar,
.pa-card,
.pa-empty{
  background:var(--portal-premium-surface)!important;
  border:1px solid var(--portal-premium-border)!important;
  border-radius:var(--portal-premium-radius-md)!important;
  box-shadow:var(--portal-premium-shadow-sm)!important;
}

html[data-theme='dark'] .card,
html[data-theme='dark'] .news-related__body .card,
html[data-theme='dark'] .download-card,
html[data-theme='dark'] .central-card,
html[data-theme='dark'] .event-card,
html[data-theme='dark'] .value-card,
html[data-theme='dark'] .aviso-card,
html[data-theme='dark'] .news-card,
html[data-theme='dark'] .service-card,
html[data-theme='dark'] .shop-info-card,
html[data-theme='dark'] .shop-card,
html[data-theme='dark'] .auth-card,
html[data-theme='dark'] .aside__box,
html[data-theme='dark'] .contact-bar__item,
html[data-theme='dark'] .services-toolbar,
html[data-theme='dark'] .news-list-compact,
html[data-theme='dark'] .portal-hero__stat,
html[data-theme='dark'] .portal-chip-card,
html[data-theme='dark'] .portal-hero__panel-card,
html[data-theme='dark'] .services-stat,
html[data-theme='dark'] .services-tag,
html[data-theme='dark'] .home-gallery-carousel-card,
html[data-theme='dark'] .home-shop-carousel-card,
html[data-theme='dark'] .home-pa-carousel-card,
html[data-theme='dark'] .gallery-portal-search,
html[data-theme='dark'] .gallery-portal-list__item,
html[data-theme='dark'] .gallery-portal-card__caption,
html[data-theme='dark'] .gallery-alego-album-head,
html[data-theme='dark'] .gallery-alego-viewer__main,
html[data-theme='dark'] .gallery-alego-viewer__side,
html[data-theme='dark'] .gallery-alego-latest,
html[data-theme='dark'] .statute-box,
html[data-theme='dark'] .medalha-card,
html[data-theme='dark'] .medalha-card--soft,
html[data-theme='dark'] .medalha-kpi,
html[data-theme='dark'] .medalha-leader,
html[data-theme='dark'] .medalha-source,
html[data-theme='dark'] .timeline__item,
html[data-theme='dark'] .pa-search-bar,
html[data-theme='dark'] .pa-card,
html[data-theme='dark'] .pa-empty{
  background:linear-gradient(180deg,var(--portal-premium-surface) 0%,var(--portal-premium-surface-soft) 100%)!important;
  border-color:var(--portal-premium-border)!important;
  box-shadow:var(--portal-premium-shadow-sm)!important;
}

.central-card,
.event-card,
.news-card,
.service-card,
.shop-card,
.home-gallery-carousel-card,
.home-shop-carousel-card,
.home-pa-carousel-card,
.gallery-portal-list__item,
.gallery-alego-latest__card,
.pa-card{
  transition:transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.central-card:hover,
.event-card:hover,
.news-card:hover,
.service-card:hover,
.shop-card:hover,
.home-gallery-carousel-card:hover,
.home-shop-carousel-card:hover,
.home-pa-carousel-card:hover,
.gallery-portal-list__item:hover,
.gallery-alego-latest__card:hover,
.pa-card:hover{
  transform:translateY(-3px);
  box-shadow:var(--portal-premium-shadow-md)!important;
  border-color:var(--portal-premium-border-strong)!important;
}

.btn,
.btn--outline,
.btn--ghost,
.btn--primary,
.btn-associe-desk,
.nav-shop-pill,
.header__entrar,
.home-carousel__btn,
.footer__social a{
  border-radius:999px!important;
}

.btn--outline,
.btn--ghost,
.header__entrar{
  backdrop-filter:blur(10px);
}

.form-control,
select.form-control,
textarea.form-control,
input[type='search'],
input[type='text'],
input[type='email'],
input[type='number'],
input[type='password'],
select,
textarea{
  border-radius:14px!important;
}

.table-responsive,
.admin-table,
table{
  border-radius:18px;
}

.section__title,
.home-carousel__title,
.page-banner__title,
.portal-hero__title,
.services-highlight h2,
.services-hero h1,
.contact-mobile h2,
.gallery-portal-header h1{
  letter-spacing:-.02em;
}

.portal-hero__surface,
.services-hero,
.services-highlight{
  border:1px solid var(--portal-premium-border)!important;
}

.home-gallery-carousel-card,
.home-shop-carousel-card,
.home-pa-carousel-card,
.home-gallery-card,
.home-shop-card,
.gallery-alego-latest__card,
.shop-admin-product__media,
.pa-carousel__viewport{
  overflow:hidden;
}

.home-gallery-carousel-card__media,
.home-shop-carousel-card__media,
.home-pa-carousel-card__media,
.home-gallery-card a,
.home-shop-card img,
.gallery-alego-latest__card a,
.news-card__media,
.news-related__media,
.shop-card__media,
.event-card__media,
.pa-carousel__viewport{
  background:var(--portal-premium-surface-strong)!important;
}

.home-gallery-carousel-card__media img,
.home-shop-carousel-card__media img,
.home-pa-carousel-card__media img,
.home-gallery-card img,
.home-shop-card img,
.gallery-alego-latest__card img,
.news-card img,
.news-related__media img,
.shop-card img,
.event-card img,
.pa-carousel__viewport img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.home-gallery-carousel-card__title,
.home-shop-carousel-card__title,
.home-pa-carousel-card__name,
.shop-card h2 a,
.event-card__title,
.gallery-alego-latest__caption,
.gallery-portal-list__body h2 a,
.gallery-portal-card__caption h2,
.pa-card h2,
.pa-card__title-name,
.pa-card__title-owner{
  font-weight:800!important;
}

.home-gallery-carousel-card__body,
.home-shop-carousel-card__body,
.home-pa-carousel-card__body,
.shop-card__body,
.gallery-portal-card__caption,
.gallery-portal-list__body,
.pa-card{
  position:relative;
}

html[data-theme='dark'] .home-carousel__btn,
html[data-theme='dark'] .footer__social a,
html[data-theme='dark'] .btn--outline,
html[data-theme='dark'] .btn--ghost,
html[data-theme='dark'] .header__entrar{
  border-color:rgba(237,244,232,.12)!important;
}

html[data-theme='dark'] .home-gallery-carousel-card__body,
html[data-theme='dark'] .home-shop-carousel-card__body,
html[data-theme='dark'] .home-pa-carousel-card__body{
  background:transparent!important;
}

.gallery-alego-viewer__frame,
.gallery-alego-viewer__thumb-frame,
.gallery-portal-card__media,
.gallery-portal-list__image,
.gallery-portal-card__image,
.shop-card__media,
.news-related__media,
.news-card__media,
.pa-carousel__placeholder,
.pa-visual__wrap{
  overflow:hidden;
  border-radius:16px;
}

.gallery-portal-search,
.gallery-portal-search__panel,
.services-search,
.services-toolbar,
.news-list-compact,
.download-card,
.contact-bar__item,
.auth-card,
.aside__box{
  backdrop-filter:blur(12px);
}

.footer,
.header,
.nav-desktop,
.mobile-dock{
  transition:background .2s ease,border-color .2s ease,box-shadow .2s ease;
}

@media (max-width: 991px){
  .page-banner,
  .portal-hero__surface,
  .services-hero,
  .services-highlight,
  .cta-banner .container{
    border-radius:20px!important;
  }

  .card,
  .download-card,
  .central-card,
  .event-card,
  .news-card,
  .service-card,
  .shop-card,
  .home-gallery-carousel-card,
  .home-shop-carousel-card,
  .home-pa-carousel-card,
  .gallery-portal-list__item,
  .gallery-portal-card__caption,
  .gallery-alego-album-head,
  .gallery-alego-viewer__main,
  .gallery-alego-viewer__side,
  .gallery-alego-latest,
  .pa-search-bar,
  .pa-card,
  .pa-empty{
    border-radius:18px!important;
  }
}
