/*
Theme Name: Astra Child Beon
Theme URI:  https://github.com/upwego/beon-wp
Description: Child theme do Astra para personalizações específicas da Beon.
Author:      UpWeGo
Author URI:  https://upwego.pt
Template:    astra
Version:     0.3.0
Text Domain: astra-child-beon
*/

/* ===== Be On Sport — fundacao de marca (UpWeGo, 2026-06-29) ===== */
:root{
  --beon-coral:#ea5e47;
  --beon-navy:#0c193a;
  --beon-grey:#d6d6d6;
}

/* Tipografia: corpo em Arimo */
body, button, input, select, optgroup, textarea,
.ast-container, .woocommerce, p, li, td, dd{
  font-family:'Arimo', Arial, Helvetica, sans-serif;
}
/* Titulos de destaque em Bebas Neue (display) */
.elementor-heading-title,
.entry-title:not(.woocommerce-loop-product__title):not(.product_title),
.ast-site-title, .site-title,
.widget-title, .widgettitle,
.elementor-icon-box-title, .elementor-price-table__header,
h1.page-title, .ast-archive-title{
  font-family:'Bebas Neue','Arimo',sans-serif !important;
  letter-spacing:.6px;
  font-weight:400;
}

/* Links */
a{ color:var(--beon-navy); }
a:hover, a:focus{ color:var(--beon-coral); }

/* Botoes (WooCommerce / Astra / Elementor / blocos) */
.ast-button, .wp-block-button__link,
.woocommerce a.button, .woocommerce button.button, .woocommerce input.button,
.woocommerce #respond input#submit, .woocommerce a.button.alt,
.woocommerce button.button.alt, .woocommerce .single_add_to_cart_button,
.elementor-button{
  background-color:var(--beon-coral) !important;
  border-color:var(--beon-coral) !important;
  color:#fff !important;
}
.ast-button:hover, .wp-block-button__link:hover,
.woocommerce a.button:hover, .woocommerce button.button:hover,
.woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover,
.woocommerce .single_add_to_cart_button:hover,
.elementor-button:hover{
  background-color:var(--beon-navy) !important;
  border-color:var(--beon-navy) !important;
  color:#fff !important;
}

/* Precos e promocoes */
.woocommerce ul.products li.product .price,
.woocommerce div.product p.price, .woocommerce div.product span.price,
.woocommerce-Price-amount{ color:var(--beon-navy); }
.woocommerce span.onsale, .onsale{
  background-color:var(--beon-coral) !important; color:#fff !important;
}

/* Realces */
::selection{ background:var(--beon-coral); color:#fff; }
.star-rating span{ color:var(--beon-coral); }

/* Header: icone do carrinho NAO e botao coral (estava a tapar o perfil) */
.elementor-menu-cart__toggle_button.elementor-button,
.elementor-menu-cart__toggle .elementor-button{
  background-color:transparent !important;
  border:0 !important;
  box-shadow:none !important;
  color:#fff !important;
  padding:0 6px !important;
}
.elementor-menu-cart__toggle_button svg,
.elementor-menu-cart__toggle_button .elementor-button-icon{ fill:#fff !important; color:#fff !important; }
.elementor-menu-cart__toggle_button .elementor-button-icon-qty{
  background-color:var(--beon-coral) !important; color:#fff !important;
}

/* Logo do header ligeiramente mais a esquerda (so desktop) */
@media (min-width:1025px){
  .elementor-element-4ae98f9{ margin-left:-15px !important; }
}

/* ============ Be On Sport — polish / micro-interacoes ============ */

/* Transicoes: links/forms so cor/fundo/borda; componentes que animam levam transform/shadow */
a, input, select, textarea,
[data-elementor-type="footer"] .elementor-icon-list-item a{
  transition: color .2s ease, background-color .2s ease, border-color .2s ease;
}
.button, button, .elementor-button,
.woocommerce ul.products li.product,
.woocommerce ul.products li.product img,
.elementor-location-header .elementor-nav-menu a.elementor-item{
  transition: color .2s ease, background-color .2s ease, border-color .2s ease,
              transform .25s cubic-bezier(.2,.7,.3,1), box-shadow .25s ease;
}

/* Cartoes de produto: raio + zoom contido, hover so em ecras com rato real */
.woocommerce ul.products li.product{ border-radius:14px; }
.woocommerce ul.products li.product > a{ display:block; overflow:hidden; border-radius:10px; }
.woocommerce ul.products li.product a img{ border-radius:10px; }
@media (hover:hover) and (pointer:fine){
  .woocommerce ul.products li.product:hover{
    transform:translateY(-6px);
    box-shadow:0 18px 38px -18px rgba(12,25,58,.45);
  }
  .woocommerce ul.products li.product:hover a img{ transform:scale(1.045); }
  .woocommerce ul.products li.product:hover .woocommerce-loop-product__title{ color:var(--beon-coral); }
  .woocommerce ul.products li.product-category:hover a img{ transform:scale(1.05); }
}

/* Botoes: raio + leve elevacao no hover */
.ast-button, .wp-block-button__link,
.woocommerce a.button, .woocommerce button.button,
.woocommerce .single_add_to_cart_button, .elementor-button{ border-radius:8px; }
.ast-button:hover, .wp-block-button__link:hover,
.woocommerce a.button:hover, .woocommerce button.button:hover,
.woocommerce .single_add_to_cart_button:hover,
.elementor-button:hover{
  transform:translateY(-2px);
  box-shadow:0 10px 22px -10px rgba(234,94,71,.7);
}
/* carrinho / fechar: nunca elevacao nem caixa coral */
.elementor-menu-cart__close-button{ background-color:transparent !important; border:0 !important; }
.elementor-menu-cart__toggle .elementor-button:hover,
.elementor-menu-cart__toggle_button.elementor-button:hover{ transform:none !important; box-shadow:none !important; }

/* Menu do header (so desktop): sublinhado coral animado */
@media (min-width:1025px){
  .elementor-location-header .elementor-nav-menu a.elementor-item{ position:relative; }
  .elementor-location-header .elementor-nav-menu a.elementor-item:after{
    content:""; position:absolute; left:14px; right:14px; bottom:8px; height:2px;
    background:var(--beon-coral); transform:scaleX(0); transform-origin:left;
    transition:transform .25s ease;
  }
  .elementor-location-header .elementor-nav-menu a.elementor-item:hover:after,
  .elementor-location-header .elementor-nav-menu .current-menu-item a.elementor-item:after{ transform:scaleX(1); }
}

/* Footer: destaque coral + deslize no hover dos links */
[data-elementor-type="footer"] .elementor-icon-list-item a{ display:inline-block; }
[data-elementor-type="footer"] .elementor-icon-list-item a:hover{
  color:var(--beon-coral) !important; transform:translateX(5px);
}
/* nao deixar o link navy global "vazar" para o header escuro */
[data-elementor-type="header"] a{ color:inherit; }

/* Focus states (teclado) com a cor da marca */
input:focus, select:focus, textarea:focus,
.woocommerce form .form-row input.input-text:focus{
  outline:none !important; border-color:var(--beon-coral) !important;
  box-shadow:0 0 0 3px rgba(234,94,71,.18) !important;
}
a:focus-visible, button:focus-visible, .elementor-button:focus-visible,
.woocommerce a.button:focus-visible, .elementor-item:focus-visible{
  outline:2px solid var(--beon-coral) !important; outline-offset:2px !important;
}

/* Breadcrumb, abas e estrelas */
.woocommerce-breadcrumb a{ color:var(--beon-navy); }
.woocommerce-breadcrumb a:hover{ color:var(--beon-coral); }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a{ color:var(--beon-coral); }
.star-rating, .woocommerce .star-rating span{ color:var(--beon-coral); }

/* Titulo de categoria (alinhado a esquerda) com tracinho coral */
.woocommerce-products-header__title, .ast-archive-title{
  position:relative; padding-bottom:.32em;
}
.woocommerce-products-header__title:after, .ast-archive-title:after{
  content:""; position:absolute; left:0; bottom:0; width:54px; height:4px;
  border-radius:3px; background:var(--beon-coral);
}

/* ============ Be On Sport — comportamentos / acabamentos ============ */

/* Scroll suave + scrollbar com a marca */
html{ scroll-behavior:smooth; scrollbar-width:thin; scrollbar-color:var(--beon-coral) #eef1f6; }
@media (min-width:1025px){
  ::-webkit-scrollbar{ width:11px; height:11px; }
  ::-webkit-scrollbar-track{ background:#eef1f6; }
  ::-webkit-scrollbar-thumb{ background:var(--beon-coral); border-radius:10px; border:3px solid #eef1f6; }
  ::-webkit-scrollbar-thumb:hover{ background:var(--beon-navy); }
}

/* Botao voltar ao topo */
.beon-totop{
  position:fixed; right:22px; bottom:22px; z-index:9999;
  width:46px; height:46px; padding:0; border:0; border-radius:50%;
  background:var(--beon-coral); color:#fff; font-size:22px; line-height:46px; cursor:pointer;
  box-shadow:0 10px 26px -8px rgba(234,94,71,.7);
  opacity:0; visibility:hidden; transform:translateY(12px);
  transition:opacity .25s ease, transform .25s ease, background-color .2s ease;
}
.beon-totop.is-visible{ opacity:1; visibility:visible; transform:translateY(0); }
.beon-totop:hover{ background:var(--beon-navy); }
@media (max-width:782px){ .beon-totop{ right:14px; bottom:84px; width:42px; height:42px; line-height:42px; } }

/* Rodape: linha de acento coral no topo + leve subida dos icones sociais */
[data-elementor-type="footer"]{ border-top:3px solid var(--beon-coral); }
[data-elementor-type="footer"] .elementor-social-icon{ transition:transform .2s ease, background-color .2s ease; }
[data-elementor-type="footer"] .elementor-social-icon:hover{ transform:translateY(-3px); }

/* === Ajustes header / produto (2026-06-30) === */
/* Barra branca entre header e conteudo na homepage (padding do tema) */
body.elementor-page-32998 #content.site-content,
body.elementor-page-32998 #content > .ast-container,
body.elementor-page-32998 #main{ padding-top:0 !important; margin-top:0 !important; }
/* Logo do header mais estreito */
.elementor-element-4ae98f9 img{ max-width:215px !important; height:auto; }
/* Alinhar verticalmente o icone do carrinho com os restantes */
.elementor-menu-cart__toggle{ display:flex !important; align-items:center; justify-content:center; }
.elementor-menu-cart__toggle_button{ display:inline-flex !important; align-items:center; }
/* "Rating: 0" no template de produto: tirar o realce de botao coral */
.elementor-element-479f3809 .elementor-button{
  background:transparent !important; border:0 !important; box-shadow:none !important;
  color:var(--beon-navy) !important; padding:0 !important; pointer-events:none;
}
.elementor-element-479f3809 .elementor-button:hover{ transform:none !important; }
.elementor-element-479f3809 .elementor-button .e-fas-star{ color:var(--beon-coral) !important; }

/* === Fixes ronda 2 (2026-06-30) === */
/* Menu dropdown tem de ficar ACIMA do conteudo da home (estava por baixo do banner) */
header.elementor-location-header{ position:relative; z-index:999; }
/* Barra branca (~20px) entre header e hero: puxar a home para cima */
body.elementor-page-32998 .beon-home{ margin-top:-20px; }
/* Carrinho ligeiramente mais abaixo para alinhar com coracao/conta */
.elementor-element-ba93348 .elementor-menu-cart__toggle_button{ transform:translateY(4px); }

/* === Grelha de produtos (loja/categorias): alinhamento + sem sufixo IVA (2026-07-02) === */
/* sufixo "com IVA" escondido nas LISTAGENS (mantém-se na página de produto) */
.woocommerce ul.products .woocommerce-price-suffix,
.woocommerce ul.products .woocommerce-Price-suffix{ display:none; }
/* cartões com altura consistente: botão ancorado em baixo */
.woocommerce ul.products li.product{ display:flex; flex-direction:column; }
.woocommerce ul.products li.product .astra-shop-summary-wrap{ display:flex; flex-direction:column; flex:1 1 auto; }
.woocommerce ul.products li.product .astra-shop-summary-wrap .button,
.woocommerce ul.products li.product a.add_to_cart_button,
.woocommerce ul.products li.product .ast-on-card-button{ margin-top:auto; align-self:center; }
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist{ margin-top:10px; }

/* === Miniaturas uniformes nas grelhas (2026-07-02): imagens em caixa quadrada === */
.woocommerce ul.products li.product .astra-shop-thumbnail-wrap,
.woocommerce ul.products li.product > .woocommerce-LoopProduct-link{ display:block; }
.woocommerce ul.products li.product .astra-shop-thumbnail-wrap img,
.woocommerce ul.products li.product > .woocommerce-LoopProduct-link > img,
.woocommerce ul.products li.product img.attachment-woocommerce_thumbnail{
  aspect-ratio:1/1; width:100%; height:auto; object-fit:contain; background:#fff;
}
/* titulo com altura minima p/ 2 linhas: botoes começam parelhos */
.woocommerce ul.products li.product .woocommerce-loop-product__title{ min-height:2.9em; }

/* === Grelhas: caixa de imagem QUADRADA fixa + botao sempre em baixo (2026-07-02 v2) === */
.woocommerce ul.products li.product .astra-shop-thumbnail-wrap{
  aspect-ratio:1/1 !important; overflow:hidden;
  display:flex !important; align-items:center; justify-content:center; background:#fff;
}
.woocommerce ul.products li.product .astra-shop-thumbnail-wrap img{
  width:100% !important; height:100% !important; object-fit:contain !important; margin:0 !important;
}
/* fallback p/ cartoes sem wrap do Astra */
.woocommerce ul.products li.product > .woocommerce-LoopProduct-link > img,
.woocommerce ul.products li.product img.attachment-woocommerce_thumbnail{
  aspect-ratio:1/1 !important; object-fit:contain !important; width:100% !important;
}
/* resumo estica; botao ancora no fundo; favoritos por baixo do botao */
.woocommerce ul.products li.product{ display:flex !important; flex-direction:column; }
.woocommerce ul.products li.product .astra-shop-summary-wrap{ display:flex !important; flex-direction:column; flex:1 1 auto !important; width:100%; }
.woocommerce ul.products li.product .astra-shop-summary-wrap > a.button,
.woocommerce ul.products li.product .astra-shop-summary-wrap .add_to_cart_button,
.woocommerce ul.products li.product .astra-shop-summary-wrap .ast-on-card-button{ margin-top:auto !important; align-self:center; }
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist{ margin-top:8px !important; }

/* fix v3: wrap a 100% de largura + coluna forcada */
.woocommerce ul.products li.product{ flex-direction:column !important; }
.woocommerce ul.products li.product .astra-shop-thumbnail-wrap{ width:100% !important; flex:0 0 auto !important; }

/* login: esconder o toggle mostrar-password que ficava como caixa coral vazia (2026-07-02) */
.woocommerce form .show-password-input,
.woocommerce-page form .show-password-input{ display:none !important; }
