/* ==========================================================================
 * FULLMENT — FluentCart in the site's look.
 *
 * FluentCart reads its colours from --fct-* custom properties (checked on the
 * live checkout, 8 Oct 2026: checkout.css and cart-drawer.css fall back to
 * these). Setting them here recolours checkout, cart drawer, shop and account
 * in one place; the rules below only fix shape (radii, type, spacing).
 * ========================================================================== */

:root{
  --fct-primary-text-color:var(--ink);
  --fct-secondary-text-color:var(--muted);
  --fct-border-color:#d9dcd6;              /* --line flattened on paper: inputs need an opaque border */
  --fct-active-border-color:var(--w700);
  --fct-divider-color:var(--mist);
  --fct-primary-bg-color:var(--night);
  --fct-secondary-bg-color:var(--bone);
  --fct-card-bg:var(--bone);                /* o nome real em 1.7.x é --fct-card-bg (era este que faltava: sem ele o cartão cai no branco puro do plugin) */
  --fct-card-bg-color:var(--bone);          /* nome antigo, mantido por precaução */
  --fct-btn-bg-color:var(--night);
  --fct-btn-text-color:var(--bone);
  --fct-btn-hover-bg-color:var(--deep);
  --fct-btn-hover-text-color:var(--bone);
  --fct-btn-border-color:var(--night);
  --fct-secondary-btn-bg-color:var(--paper);
  --fct-secondary-btn-hover-bg-color:var(--bone);
  --fct-input-bg-color:var(--paper);
  --fct-input-disabled-bg-color:var(--bone);
  --fct-input-text-color:var(--ink);
  --fct-input-placeholder-text-color:#8a9a96;
}

/* ---- type: FluentCart ships its own font stack in places */
.fm [class^="fct"],.fm [class*=" fct"],.fm [class*="fluent-cart"],
.fm [class^="fct"] input,.fm [class^="fct"] select,.fm [class^="fct"] textarea,.fm [class^="fct"] button{font-family:var(--sans)}
.fm [class^="fct"] h1,.fm [class^="fct"] h2,.fm [class^="fct"] h3,.fm [class^="fct"] h4{font-family:var(--sans);font-weight:350;letter-spacing:-.01em}

/* ---- inputs
 * FluentCart joins stacked fields into one group (shared borders), so shape is
 * left to it: rounding each input separately breaks the group. Only type and
 * the focus ring are ours. */
.fm .fct_input_wrapper input,.fm .fct_input_wrapper select,.fm .fct_input_wrapper textarea,
.fm .fct_coupon_input,.fm .fct-shop-input{font-size:.95rem;color:var(--ink)}
.fm .fct_input_wrapper input:focus,.fm .fct_input_wrapper select:focus,.fm .fct_input_wrapper textarea:focus,
.fm .fct_coupon_input:focus,.fm .fct-shop-input:focus{border-color:var(--w700);box-shadow:0 0 0 3px rgba(76,175,165,.18);outline:0;position:relative;z-index:1}
.fm .fct_input_label,.fm .fct_form_section_header_label{color:var(--ink);font-weight:350}
.fm .fct_form_section_header_label{font-family:var(--label);font-weight:500;font-size:.62rem;letter-spacing:.24em;text-transform:uppercase;color:var(--w700)}
.fm input[type="checkbox"].fct-input-checkbox{accent-color:var(--night)}

/* ---- buttons: pills, like .btn on the static site */
.fm .fct_place_order_btn,.fm .fluent-cart-add-to-cart-button,.fm .fluent-cart-direct-checkout-button,.fm .fct-product-view-button,
.fm .fct-customer-login-btn,.fm .fct-not-found-button,.fm .fct-checkout-btn,.fm [class*="fct-btn"],.fm [class*="fct_btn"]{
  border-radius:999px;font-family:var(--sans);font-weight:350;letter-spacing:0;transition:transform .3s var(--ease),background .3s}
.fm .fct_place_order_btn{min-height:56px;font-size:1rem}
.fm .fct_place_order_btn:hover,.fm .fluent-cart-add-to-cart-button:hover,.fm .fluent-cart-direct-checkout-button:hover,.fm .fct-customer-login-btn:hover,.fm .fct-not-found-button:hover{transform:translateY(-2px)}

/* ---- cards: order summary, payment methods, product cards */
.fm .fct_summary_box,.fm .fct_checkout_payment_methods,.fm .fct_payment_methods_list,.fm .fct-product-card,.fm .fct_auth_wrap{
  border-radius:20px;border-color:var(--line)}
.fm .fct_summary_box{box-shadow:0 30px 60px -40px rgba(17,40,38,.35)}
.fm .fct_line_item .fct_item_image img{border-radius:10px}
.fm .fct_summary_items_total,.fm .fct_summary_items_total *{font-weight:350}
.fm .fct_summary_items_total .fct_summary_value{font-size:1.25rem;font-variant-numeric:tabular-nums}
.fm .fct_coupon_toggle{border-radius:12px;background:var(--bone)}

/* ---- shop grid */
.fm .fct-product-card{overflow:hidden;background:var(--bone);border:1px solid var(--line);transition:transform .5s var(--ease),box-shadow .5s var(--ease)}
.fm .fct-product-card:hover{transform:translateY(-4px);box-shadow:var(--shadow)}
.fm .fct-product-card-title,.fm .fct-product-card-title a{font-family:var(--sans);font-weight:350;font-size:1.15rem;line-height:1.25;text-decoration:none;color:var(--ink)}
.fm .fct-product-card-prices{font-variant-numeric:tabular-nums}
/* Product covers are 1200×630 with the title written on them; FluentCart's
 * square crop cut the words off. Show them at their own ratio. */
.fm .fct-product-card-image-wrap{aspect-ratio:1200/630;height:auto}
.fm .fct-product-card-image-wrap img,.fm .fct-product-card-image{width:100%;height:100%;aspect-ratio:auto;object-fit:cover}

/* ---- empty states / not found / login prompt */
.fm .fct-not-found-title,.fm .fluent-cart-cart-empty-content-text{font-weight:250;font-size:clamp(1.5rem,3vw,2.2rem);letter-spacing:-.015em}
.fm .fct_auth_wrap{padding:clamp(1.4rem,3vw,2.2rem);background:var(--bone);border:1px solid var(--line)}

/* ---- FluentCart's own error text keeps a readable red, not brand colour */
.fm .fct_form_error{color:#b3261e}

/* ---- small FluentCart links: brand green, no stray underlines */
.fm .fct_coupon_toggle,.fm .fct_coupon_toggle a{text-decoration:none}
.fm .fct_tax_simple_toggle,.fm .fct_item_tax_hint_button{color:var(--w700)}

/* ---- single product: the gallery image at the covers' own ratio (1200×630),
 * not FluentCart's square crop */
.fm .fct-product-gallery-thumb{aspect-ratio:1200/630;height:auto;border-radius:20px;overflow:hidden}
.fm .fct-product-gallery-thumb img{width:100%;height:100%;object-fit:cover}
.fm #fct-product-summary-title{font-weight:250;font-size:clamp(2rem,4vw,3.2rem);line-height:1.05;letter-spacing:-.02em}
/* FluentCart's login prompt button carries a stronger rule of its own */
.fm .fct_auth_wrap a.fct-customer-login-btn{border-radius:999px;padding:.85em 1.5em;background:var(--night);color:var(--bone);border:0;text-decoration:none;display:inline-flex;align-items:center}
.fm .fct_auth_wrap a.fct-customer-login-btn:hover{background:var(--deep)}

/* ── Janela do pagamento instantâneo ────────────────────────────────────────
 * O FluentCart abre o checkout num iframe sobreposto (classe .fct-checkout-modal).
 * O plugin pinta o painel, o carregador e o iframe de branco puro (#fff): quem
 * clica em «comprar agora» vê um flash branco fora do sistema da marca. O ícone
 * de fechar também vinha branco. Estas regras ficam fora do âmbito .fm porque a
 * janela é acrescentada ao <body>, fora do contentor da página. */
.fct-checkout-modal,.fct-checkout-modal-loader,.fct-checkout-modal-iframe{background:var(--paper)}
.fct-checkout-modal-close{background:var(--bone);color:var(--ink);border-radius:999px}
.fct-checkout-modal-close:hover{background:var(--mist);color:var(--ink)}
.fct-checkout-modal-loader-spinner{border-color:var(--mist);border-top-color:var(--night)}

/* O «?» de ajuda do IVA, no resumo da encomenda, era o último elemento branco
 * puro do checkout (14×14 px). */
.fct_item_tax_hint_button{background:var(--bone);color:var(--ink);border-color:var(--line);border-radius:999px}

/* «Ir para o pagamento» na página /carrinho/ é um <a class="fct-primary-btn">.
 * O «.fm a{color:inherit}» do tema (0,1,1) ganha à cor do FluentCart
 * (.fct-primary-btn, 0,1,0): o texto herdava a tinta e ficava tinta sobre tinta,
 * botão escuro sem texto visível. Na gaveta do carrinho não acontecia porque a
 * regra do FluentCart lá é mais específica. Medido a 18 Out 2026. */
.fm a.fct-primary-btn,.fm a.fct-primary-btn:visited{color:var(--fct-btn-text-color,var(--bone))}
.fm a.fct-primary-btn:hover,.fm a.fct-primary-btn:focus-visible{background:var(--deep);color:var(--bone)}

/* A bolha flutuante do FluentCart (canto inferior direito) sai: o carrinho tem
 * agora lugar no cabeçalho, em todas as páginas. A gaveta continua a abrir
 * sozinha quando se adiciona um produto. */
body .fct-cart-drawer-open-btn{display:none}
