/*
Theme Name: Lojas AZ
Theme URI: https://lojasaz.com
Description: Child theme do Storefront com o design personalizado da Lojas AZ (hero preto/dourado, grelha de categorias, mais vendidos, faixa de benefícios, CTA empresas e testemunhos).
Author: Lojas AZ
Template: storefront
Version: 1.0.0
Text Domain: lojas-az
*/

:root{
    --az-black: #0e0e0e;
    --az-black-soft: #171717;
    --az-gold: #c9a24d;
    --az-gold-light: #d9bd7a;
    --az-cream: #f7f5f1;
    --az-grey: #6b6b6b;
    --az-border: #2a2a2a;
}

body{
    color: #1a1a1a;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
h1,h2,h3,.az-serif{
    font-family: 'Playfair Display', Georgia, serif;
}

.az-container{
    max-width:1240px;
    margin:0 auto;
    padding:0 24px;
}

/* ---------- TOPBAR ---------- */
.az-topbar{
    background:var(--az-black);
    color:#cfcfcf;
    font-size:12px;
}
.az-topbar .az-container{
    display:flex;
    justify-content:space-between;
    align-items:center;
    height:34px;
}
.az-topbar a{color:#cfcfcf;text-decoration:none;margin-left:18px;}
.az-topbar a:hover{color:var(--az-gold);}

/* ---------- HEADER ---------- */
.az-header{
    background:#fff;
    border-bottom:1px solid #eee;
    padding:18px 0;
}
.az-header .az-container{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:24px;
    flex-wrap:wrap;
}
.az-logo{
    display:flex;
    flex-direction:column;
    line-height:1;
    text-decoration:none;
}
.az-logo .az-logo-main{
    font-family:'Playfair Display', serif;
    font-size:30px;
    font-weight:700;
    color:#111;
}
.az-logo .az-logo-main span{color:var(--az-gold);}
.az-logo .az-logo-sub{
    font-size:9px;
    letter-spacing:3px;
    color:#999;
    margin-top:2px;
}
.az-tagline{
    font-size:12px;
    color:var(--az-gold);
    margin-left:14px;
    border-left:1px solid #ddd;
    padding-left:14px;
}
.az-search{
    flex:1;
    max-width:460px;
    display:flex;
}
.az-search input{
    flex:1;
    border:1px solid #ddd;
    border-right:none;
    padding:10px 16px;
    font-size:14px;
    border-radius:4px 0 0 4px;
}
.az-search button{
    background:var(--az-gold);
    border:none;
    color:#111;
    padding:0 18px;
    border-radius:0 4px 4px 0;
    cursor:pointer;
}
.az-header-actions{
    display:flex;
    align-items:center;
    gap:26px;
    font-size:13px;
}
.az-header-actions a{color:#222;text-decoration:none;}
.az-header-actions .az-cart{position:relative;}
.az-header-actions .az-cart-count{
    position:absolute;top:-8px;right:-10px;
    background:var(--az-gold);color:#111;
    font-size:10px;font-weight:700;
    border-radius:50%;width:16px;height:16px;
    display:flex;align-items:center;justify-content:center;
}

/* ---------- NAV ---------- */
.az-nav{
    background:var(--az-black);
}
.az-nav .az-container{
    display:flex;
    align-items:center;
    justify-content:space-between;
}
.az-nav ul{
    list-style:none;margin:0;padding:0;
    display:flex;gap:6px;
}
.az-nav ul li a{
    display:block;
    padding:16px 14px;
    color:#eee;
    text-decoration:none;
    font-size:14px;
}
.az-nav ul li a:hover{color:var(--az-gold);}
.az-nav-cta{
    background:var(--az-gold);
    color:#111 !important;
    padding:8px 18px !important;
    border-radius:3px;
    font-weight:600;
    font-size:13px !important;
}

/* ---------- HERO ---------- */
.az-hero{
    background: linear-gradient(120deg, #0a0a0a 0%, #171717 60%, #1c1c1c 100%);
    color:#fff;
    padding:70px 0;
}
.az-hero .az-container{
    display:grid;
    grid-template-columns: 1fr 1fr;
    gap:50px;
    align-items:center;
}
.az-hero h1{
    color:#fff !important;
    font-size:44px;
    line-height:1.15;
    margin:0 0 18px;
    font-weight:700;
}
.az-hero h1 .az-gold-line{color:var(--az-gold);display:block;}
.az-hero p{
    color:#c9c9c9;
    font-size:16px;
    max-width:420px;
    margin-bottom:28px;
}
.az-hero-buttons{display:flex;gap:14px;margin-bottom:36px;}
.az-btn-gold{
    background:var(--az-gold);
    color:#111;
    padding:14px 26px;
    border-radius:4px;
    text-decoration:none;
    font-weight:600;
    font-size:14px;
    border:1px solid var(--az-gold);
}
.az-btn-outline{
    background:transparent;
    color:#fff;
    padding:14px 26px;
    border-radius:4px;
    text-decoration:none;
    font-weight:600;
    font-size:14px;
    border:1px solid #555;
}
.az-hero-features{display:flex;gap:28px;flex-wrap:wrap;font-size:12px;color:#bbb;}
.az-hero-features span{display:flex;align-items:center;gap:6px;}
.az-hero-image{
    min-height:340px;
    border-radius:6px;
    background-size:cover;
    background-position:center;
    background-color:#141414;
    background-image: var(--az-hero-bg, none);
    display:flex;align-items:center;justify-content:center;
    color:#555;
    font-size:13px;
    text-align:center;
    border:1px dashed #333;
}

/* ---------- CATEGORY GRID ---------- */
.az-categories{padding:0;}
.az-cat-grid{
    display:grid;
    grid-template-columns:repeat(5,1fr);
}
.az-cat-card{
    position:relative;
    min-height:210px;
    background:#222 center/cover no-repeat;
    display:flex;flex-direction:column;justify-content:flex-end;
    padding:20px;
    color:#fff;
    text-decoration:none;
    border-right:1px solid #000;
}
.az-cat-card::before{
    content:"";
    position:absolute;inset:0;
    background:linear-gradient(180deg, rgba(0,0,0,.15), rgba(0,0,0,.75));
}
.az-cat-card *{position:relative;z-index:1;}
.az-cat-card h3{font-size:16px;margin:0 0 4px;font-family:'Inter',sans-serif;font-weight:600;}
.az-cat-card p{font-size:11.5px;color:#ddd;margin:0 0 12px;line-height:1.5;}
.az-cat-arrow{
    width:30px;height:30px;border-radius:50%;
    background:var(--az-gold);color:#111;
    display:flex;align-items:center;justify-content:center;
    font-size:14px;
}

/* ---------- BEST SELLERS ---------- */
.az-section{padding:60px 0;}
.az-section-head{
    display:flex;justify-content:space-between;align-items:center;
    margin-bottom:26px;
}
.az-section-head h2{font-size:24px;margin:0;}
.az-section-head a{color:var(--az-gold);text-decoration:none;font-size:13px;font-weight:600;}

.az-products ul.products{
    display:grid !important;
    grid-template-columns:repeat(6,1fr) !important;
    gap:18px;
    list-style:none;margin:0;padding:0;
}
.az-products ul.products li.product{
    border:1px solid #eee;
    border-radius:6px;
    padding:14px;
    text-align:left;
}
.az-products ul.products li.product img{
    border-radius:4px;margin-bottom:10px;
}
.az-products ul.products li.product .woocommerce-loop-product__title{
    font-size:13px;font-weight:600;color:#111;margin:4px 0;
}
.az-products ul.products li.product .price{
    font-size:13px;color:#555;display:block;margin-bottom:10px;
}
.az-products ul.products li.product a.button{
    display:block;text-align:center;
    background:var(--az-gold) !important;
    color:#111 !important;
    border-radius:4px;
    padding:9px 0 !important;
    font-size:12px;font-weight:600;
}

/* ---------- BENEFITS STRIP ---------- */
.az-benefits{background:var(--az-cream);padding:36px 0;}
.az-benefits h2{text-align:center;font-size:20px;margin:0 0 26px;}
.az-benefits-row{
    display:flex;justify-content:space-between;flex-wrap:wrap;gap:20px;
}
.az-benefit{display:flex;align-items:center;gap:10px;font-size:13px;color:#333;flex:1;min-width:160px;}
.az-benefit .az-icon{font-size:20px;color:var(--az-gold);}
.az-benefit strong{display:block;font-size:13px;}
.az-benefit span{color:#777;font-size:12px;}

/* ---------- CTA + TESTIMONIALS ---------- */
.az-cta{background:var(--az-black);padding:0;}
.az-cta .az-container{
    display:grid;grid-template-columns:1.1fr 0.9fr;gap:0;
    max-width:1240px;
}
.az-cta-left{padding:60px 40px;color:#fff;}
.az-cta-left h2{font-size:30px;margin:0 0 16px;}
.az-cta-left p{color:#bbb;margin-bottom:20px;max-width:420px;}
.az-cta-left ul{list-style:none;margin:0 0 26px;padding:0;}
.az-cta-left ul li{margin-bottom:8px;font-size:13px;color:#ddd;}
.az-cta-left ul li:before{content:"✔ ";color:var(--az-gold);}

.az-testimonials{
    background:#fff;color:#111;padding:60px 40px;
    display:flex;flex-direction:column;justify-content:center;
}
.az-testimonials h3{font-size:16px;margin:0 0 18px;}
.az-testimonial-stars{color:var(--az-gold);margin-bottom:10px;}
.az-testimonial-text{font-style:italic;font-size:15px;margin-bottom:12px;}
.az-testimonial-author{font-weight:700;font-size:13px;}

/* ---------- FOOTER ---------- */
.az-footer{background:var(--az-black);color:#bbb;padding:56px 0 20px;}
.az-footer-grid{
    display:grid;grid-template-columns:1.4fr 1fr 1fr 1fr 1.2fr;gap:30px;
    margin-bottom:36px;
}
.az-footer h4{color:#fff;font-size:14px;margin:0 0 14px;}
.az-footer ul{list-style:none;margin:0;padding:0;}
.az-footer ul li{margin-bottom:8px;font-size:13px;}
.az-footer ul li a{color:#aaa;text-decoration:none;}
.az-footer ul li a:hover{color:var(--az-gold);}
.az-footer-bottom{
    border-top:1px solid var(--az-border);
    padding-top:18px;
    display:flex;justify-content:space-between;
    font-size:12px;color:#888;
    flex-wrap:wrap;gap:10px;
}
.az-newsletter{display:flex;margin-top:10px;}
.az-newsletter input{flex:1;padding:10px;border:none;border-radius:3px 0 0 3px;font-size:12px;}
.az-newsletter button{background:var(--az-gold);border:none;padding:0 16px;border-radius:0 3px 3px 0;cursor:pointer;}
.az-socials{display:flex;gap:10px;margin-bottom:16px;}
.az-socials a{
    width:30px;height:30px;border-radius:50%;background:#222;
    display:flex;align-items:center;justify-content:center;color:#fff;text-decoration:none;font-size:13px;
}

/* ---------- RESPONSIVE ---------- */
@media(max-width:960px){
    .az-hero .az-container{grid-template-columns:1fr;}
    .az-cat-grid{grid-template-columns:repeat(2,1fr);}
    .az-products ul.products{grid-template-columns:repeat(3,1fr) !important;}
    .az-cta .az-container{grid-template-columns:1fr;}
    .az-footer-grid{grid-template-columns:1fr 1fr;}
}
@media(max-width:600px){
    .az-header .az-container{flex-direction:column;align-items:flex-start;}
    .az-nav ul{flex-wrap:wrap;}
    .az-cat-grid{grid-template-columns:1fr;}
    .az-products ul.products{grid-template-columns:repeat(2,1fr) !important;}
    .az-hero h1{font-size:32px;}
}
/* ===== DROPDOWN DO MENU (submenus só aparecem ao passar o rato) ===== */
.az-nav ul.sub-menu{
    display:none;
    position:absolute;
    top:100%;
    left:0;
    background:#0d0d0d;
    border-top:2px solid var(--az-gold);
    min-width:180px;
    z-index:100;
    padding:0;
    margin:0;
    list-style:none;
}
.az-nav li{
    position:relative;
}
.az-nav li:hover > ul.sub-menu{
    display:block;
}
.az-nav ul.sub-menu li{
    width:100%;
}
.az-nav ul.sub-menu li a{
    display:block;
    padding:10px 16px;
    color:#fff;
    white-space:nowrap;
}
.az-nav ul.sub-menu li a:hover{
    color:var(--az-gold);
    background:#1a1a1a;
}
/* ===== TÍTULO E DESCRIÇÃO DA PÁGINA DE CATEGORIA ===== */
.woocommerce-products-header__title,
.page-title{
	color:#fff !important;
}
.term-description,
.woocommerce-products-header__description{
	color:#c9c9c9 !important;
}

/* ===== AVISOS DO WOOCOMMERCE (mensagens azuis por padrão) ===== */
.woocommerce-info,
.woocommerce-message,
.woocommerce-noreviews,
.woocommerce-error{
	background:#1a1a1a !important;
	color:#fff !important;
	border-top-color:var(--az-gold) !important;
}
.woocommerce-info a,
.woocommerce-message a{
	color:var(--az-gold) !important;
}
/* ===== PÁGINA DE PRODUTO INDIVIDUAL ===== */
.single-product .product_title,
.single-product h1.entry-title{
	color:#fff !important;
}
.single-product .woocommerce-Price-amount,
.single-product .price{
	color:var(--az-gold) !important;
}
.single-product .woocommerce-product-details__short-description,
.single-product .woocommerce-product-details__short-description p{
	color:#c9c9c9 !important;
}
.single-product label{
	color:#fff !important;
}
.single-product select{
	background:#1a1a1a;
	color:#fff;
	border:1px solid #444;
}
.single-product .breadcrumb,
.single-product .breadcrumb a,
nav.woocommerce-breadcrumb,
nav.woocommerce-breadcrumb a{
	color:#c9c9c9 !important;
}
/* Fundo preto em toda a página de produto individual */
body.single-product {
    background-color: #0d0d0d;
}
body.single-product .storefront-product-pagination,
body.single-product #content,
body.single-product .site-main {
    background-color: #0d0d0d;
}
.az-preview-box {
    clear: both;
    width: 100%;
    box-sizing: border-box;
    margin-top: 20px;
}
/* Submenus dentro de submenus abrem para o lado, não tapam os itens irmãos */
.az-nav ul.sub-menu ul.sub-menu{
    top: 0;
    left: 100%;
}
/* Miniaturas dos produtos mostram a imagem inteira, sem cortar */
ul.products li.product img,
.woocommerce ul.products li.product img {
    object-fit: contain !important;
    background: #1a1a1a;
    aspect-ratio: 1 / 1;
}
/* ===== Menu hambúrguer (telemóvel) ===== */
.az-nav-toggle{
    display:none;
    flex-direction:column;
    justify-content:center;
    gap:5px;
    width:34px;
    height:34px;
    background:none;
    border:none;
    cursor:pointer;
    padding:0;
}
.az-nav-toggle span{
    display:block;
    width:100%;
    height:2px;
    background:#111;
    transition:transform 0.2s ease, opacity 0.2s ease;
}
.az-nav-toggle.active span:nth-child(1){ transform:translateY(7px) rotate(45deg); }
.az-nav-toggle.active span:nth-child(2){ opacity:0; }
.az-nav-toggle.active span:nth-child(3){ transform:translateY(-7px) rotate(-45deg); }

/* Pesquisa dentro do menu (só aparece com o menu aberto, no telemóvel) */
.az-nav-search-item{
    display:none;
}
@media(max-width:768px){
    .az-nav-toggle{ display:flex; }
    .az-nav{
        display:none; /* a faixa preta toda fica escondida até se abrir o menu */
    }
    .az-nav.az-nav-open{
        display:block;
    }
    .az-nav .az-container{ flex-wrap:wrap; }
    .az-nav ul{
        display:flex;
        flex-direction:column;
        width:100%;
        gap:0;
    }
    .az-nav ul li a{
        padding:12px 4px;
        border-top:1px solid #222;
    }
    /* nos ecrãs pequenos, os submenus ficam sempre visíveis em bloco (tocar não ativa ":hover") */
    .az-nav ul.sub-menu{
        display:block !important;
        position:static;
        background:#111;
        border-top:none;
        min-width:100%;
        padding-left:14px;
    }
    .az-nav ul.sub-menu ul.sub-menu{
        position:static;
        left:0;
        top:0;
    }
    .az-nav-search-item{
        display:block;
        width:100%;
        padding:14px 4px;
        border-top:1px solid #222;
    }
    .az-nav-search-item .az-search{
        display:flex;
        max-width:100%;
    }
    .az-nav-cta{
        margin:10px 0;
        display:inline-block;
    }
}
/* ===== Cabeçalho em icones, mais compacto ainda, no telemóvel ===== */
.az-search-toggle{
    display:none;
    background:none;
    border:none;
    font-size:18px;
    cursor:pointer;
    padding:6px;
}
@media(max-width:768px){
    .az-topbar{
        display:none; /* cabeçalho minimalista, sem barra superior no telemóvel */
    }
    .az-header{
        padding:10px 0;
    }
    .az-header .az-container{
        flex-direction:row;
        flex-wrap:nowrap;
        align-items:center;
        justify-content:flex-start;
        gap:10px;
    }
    .az-nav-toggle{
        order:1;
        flex-shrink:0;
    }
    .az-header .az-container > div:first-of-type{
        order:2;
        flex:1;
        min-width:0;
    }
    .az-logo .az-logo-main{
        font-size:20px;
    }
    .az-logo .az-logo-sub{
        font-size:7px;
        letter-spacing:2px;
    }
    .az-tagline{
        display:none; /* poupa espaço, o logo já chega */
    }
    .az-search-toggle{
        order:3;
        display:inline-flex;
        flex-shrink:0;
    }
    .az-search{
        display:none;
        order:10;
        width:100%;
    }
    .az-search.az-search-open{
        display:flex;
        margin-top:6px;
    }
    .az-header-actions{
        order:4;
        flex-shrink:0;
        gap:10px;
    }
    .az-actions-label{
        display:none;
    }
    .az-header-actions .az-cart-count{
        position:static;
        margin-left:2px;
        width:auto;
        height:auto;
        border-radius:8px;
        padding:1px 5px;
    }
}
/* Esconde a informação de REF/Categoria em todos os produtos */
.product_meta {
    display: none !important;
}