/*
Theme Name:   Il Gusto della Costa Child
Theme URI:    https://www.ilgustodellacosta.it
Description:  Child theme per Il Gusto della Costa — Design "Costa d'Oro"
Author:       Il Gusto della Costa
Template:     hello-elementor
Version:      1.0.0
Text Domain:  gusto-della-costa
*/

/* ============================================================
   DESIGN TOKENS — "COSTA D'ORO"
   Importa questi come CSS Custom Properties globali
   Usali in Elementor > Site Settings > Custom CSS
   ============================================================ */

:root {
  /* Colori */
  --navy:         #0B1D3A;
  --navy-mid:     #142847;
  --gold:         #C9A456;
  --gold-light:   #E8C97A;
  --gold-pale:    #F5E9C8;
  --cream:        #F8F2E4;
  --cream-dark:   #EDE3CC;
  --sage:         #8FA67C;
  --rust:         #C05E3B;
  --text:         #1C1C2E;
  --text-mid:     #4A4A60;
  --text-light:   #8A8A9A;
  --white:        #FFFFFF;

  /* Tipografia */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'Jost', 'Helvetica Neue', sans-serif;

  /* Spaziature */
  --radius-sm:    6px;
  --radius-md:    14px;
  --radius-lg:    28px;
  --section-pad:  6rem 2rem;

  /* Ombre */
  --shadow-card:  0 8px 40px rgba(11,29,58,0.12);
  --shadow-hover: 0 20px 60px rgba(11,29,58,0.22);

  /* Transizioni */
  --transition:   0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a  { color: inherit; text-decoration: none; }

/* ============================================================
   TIPOGRAFIA GLOBALE
   ============================================================ */
h1, h2, h3, h4, .elementor-heading-title {
  font-family: var(--font-display) !important;
  line-height: 1.15;
}
h1 { font-size: clamp(2.8rem, 6vw, 5.5rem); font-weight: 300; }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); font-weight: 400; }
h3 { font-size: clamp(1.4rem, 2.5vw, 2rem); font-weight: 400; }
h4 { font-size: 1.2rem; font-weight: 500; }
p  { font-weight: 300; line-height: 1.75; }

.eyebrow {
  font-family: var(--font-body) !important;
  font-size: 0.72rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.22em !important;
  text-transform: uppercase !important;
  color: var(--gold) !important;
}

/* ============================================================
   HEADER ELEMENTOR
   ============================================================ */
.e-header,
#site-header,
.site-header {
  position: fixed !important;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  transition: background var(--transition), box-shadow var(--transition);
}

/* Header trasparente default */
.e-header--transparent,
.header-transparent {
  background: transparent !important;
}

/* Header scrolled */
.header-scrolled,
.e-header--scrolled {
  background: rgba(11, 29, 58, 0.97) !important;
  box-shadow: 0 2px 30px rgba(0,0,0,0.3) !important;
}

/* Logo nell'header */
.header-logo img {
  height: 60px !important;
  width: auto !important;
  object-fit: contain !important;
}

/* Nav links */
.elementor-nav-menu a,
.e-nav-menu a {
  font-family: var(--font-body) !important;
  font-size: 0.82rem !important;
  font-weight: 500 !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  color: var(--cream) !important;
  transition: color var(--transition) !important;
  position: relative;
}
.elementor-nav-menu a::after,
.e-nav-menu a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0; right: 100%;
  height: 1px;
  background: var(--gold);
  transition: right var(--transition);
}
.elementor-nav-menu a:hover::after,
.e-nav-menu a:hover::after { right: 0; }
.elementor-nav-menu a:hover,
.e-nav-menu a:hover { color: var(--gold) !important; }

/* Mobile hamburger */
.elementor-menu-toggle i,
.e-n-menu-toggle i { color: var(--cream) !important; }

/* Carrello WooCommerce nell'header */
.cart-icon-wrapper {
  position: relative;
  cursor: pointer;
  color: var(--cream);
  font-size: 1.2rem;
  transition: color var(--transition);
}
.cart-icon-wrapper:hover { color: var(--gold); }
.cart-count-badge {
  position: absolute;
  top: -6px; right: -8px;
  width: 18px; height: 18px;
  background: var(--gold);
  color: var(--navy);
  border-radius: 50%;
  font-size: 0.65rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ============================================================
   FOOTER ELEMENTOR
   ============================================================ */
.e-footer,
#site-footer,
.site-footer {
  background: var(--navy) !important;
  color: var(--cream) !important;
}

.footer-widget-title,
.elementor-widget-heading.footer-heading .elementor-heading-title {
  font-family: var(--font-body) !important;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.2em !important;
  text-transform: uppercase !important;
  color: var(--gold) !important;
  margin-bottom: 1.5rem !important;
}

.footer-nav a,
.elementor-widget-nav-menu.footer-nav a {
  font-size: 0.9rem !important;
  color: rgba(248,242,228,0.7) !important;
  transition: color var(--transition) !important;
  display: block;
  padding: 0.3rem 0;
}
.footer-nav a:hover { color: var(--gold) !important; }

.footer-contact p,
.footer-contact a {
  font-size: 0.88rem;
  color: rgba(248,242,228,0.7);
  line-height: 1.8;
}
.footer-contact a:hover { color: var(--gold); }

.footer-bottom-bar {
  border-top: 1px solid rgba(255,255,255,0.1) !important;
  padding-top: 2rem !important;
}
.footer-bottom-bar p,
.footer-bottom-bar a {
  font-size: 0.78rem !important;
  color: rgba(248,242,228,0.4) !important;
}

/* Social icons footer */
.footer-social .elementor-social-icon {
  background: transparent !important;
  border: 1px solid rgba(255,255,255,0.2) !important;
  width: 40px !important;
  height: 40px !important;
  line-height: 40px !important;
  border-radius: 50% !important;
  color: var(--cream) !important;
  transition: var(--transition) !important;
}
.footer-social .elementor-social-icon:hover {
  border-color: var(--gold) !important;
  color: var(--gold) !important;
}

/* ============================================================
   PULSANTI GLOBALI
   ============================================================ */
.btn-gold,
.elementor-button.btn-gold {
  background: var(--gold) !important;
  color: var(--navy) !important;
  border: none !important;
  border-radius: var(--radius-sm) !important;
  font-family: var(--font-body) !important;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  padding: 0.9rem 2.2rem !important;
  transition: var(--transition) !important;
}
.btn-gold:hover {
  background: var(--gold-light) !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(201,164,86,0.4) !important;
}

.btn-outline,
.elementor-button.btn-outline {
  background: transparent !important;
  color: var(--cream) !important;
  border: 1.5px solid rgba(255,255,255,0.4) !important;
  border-radius: var(--radius-sm) !important;
  font-family: var(--font-body) !important;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  padding: 0.9rem 2.2rem !important;
  transition: var(--transition) !important;
}
.btn-outline:hover {
  border-color: var(--gold) !important;
  color: var(--gold) !important;
  transform: translateY(-2px) !important;
}

.btn-navy,
.elementor-button.btn-navy {
  background: var(--navy) !important;
  color: var(--cream) !important;
  border: none !important;
  border-radius: var(--radius-sm) !important;
  font-family: var(--font-body) !important;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  padding: 0.9rem 2.2rem !important;
  transition: var(--transition) !important;
}
.btn-navy:hover {
  background: var(--navy-mid) !important;
  transform: translateY(-2px) !important;
}

/* ============================================================
   PRODUCT CARDS (WooCommerce / Custom)
   ============================================================ */
.product-card,
.wc-product-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform var(--transition), box-shadow var(--transition);
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}
.product-card .product-img {
  aspect-ratio: 4/3;
  overflow: hidden;
}
.product-card .product-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.product-card:hover .product-img img { transform: scale(1.07); }

.product-badge {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  border-radius: 99px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.badge-new { background: var(--gold); color: var(--navy); }
.badge-bio { background: var(--sage); color: var(--white); }

.product-price {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--navy);
}

.btn-add-cart {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.2rem;
  background: var(--navy);
  color: var(--cream);
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  width: 100%;
  transition: var(--transition);
}
.btn-add-cart:hover { background: var(--gold); color: var(--navy); }

/* ============================================================
   SEZIONI PAGINA
   ============================================================ */

/* Hero home */
.hero-section {
  position: relative;
  min-height: 100vh;
  background: var(--navy);
  display: flex;
  align-items: center;
}
.hero-section::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(11,29,58,0.72) 0%, rgba(11,29,58,0.35) 60%, rgba(0,0,0,0.2) 100%);
  pointer-events: none;
}

/* Hero sottopagine */
.page-hero {
  position: relative;
  min-height: 50vh;
  background: var(--navy);
  display: flex;
  align-items: flex-end;
  padding-bottom: 4rem;
}
.page-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11,29,58,0.85) 0%, rgba(11,29,58,0.3) 100%);
  pointer-events: none;
}
.page-hero .elementor-container { position: relative; z-index: 2; }

/* Sezione cream */
.section-cream { background: var(--cream) !important; }

/* Sezione navy */
.section-navy { background: var(--navy) !important; }
.section-navy h2,
.section-navy h3,
.section-navy p,
.section-navy .elementor-heading-title { color: var(--cream) !important; }

/* Sezione navy-mid */
.section-navy-mid { background: var(--navy-mid) !important; }

/* Sezione gold */
.section-gold { background: var(--gold) !important; }
.section-gold h2,
.section-gold p { color: var(--navy) !important; }

/* Sezione white */
.section-white { background: var(--white) !important; }

/* Brand strip / marquee */
.brand-strip { background: var(--gold) !important; overflow: hidden; padding: 1rem 0; }
.brand-strip-inner {
  display: flex;
  gap: 3rem;
  white-space: nowrap;
  animation: marquee 20s linear infinite;
}
.brand-strip-item {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--navy);
}
@keyframes marquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Divider gold */
.divider-gold {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  color: var(--gold);
}
.divider-gold::before, .divider-gold::after {
  content: '';
  flex: 1;
  height: 1px;
  background: currentColor;
  opacity: 0.3;
}

/* Quote block */
.quote-block {
  border-left: 3px solid var(--gold);
  padding: 1rem 1.5rem;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-style: italic;
  color: var(--text-mid);
  line-height: 1.7;
}
.quote-block cite {
  display: block;
  font-style: normal;
  font-size: 0.8rem;
  font-family: var(--font-body);
  letter-spacing: 0.1em;
  margin-top: 0.5rem;
  color: var(--gold);
}

/* Value card */
.value-card {
  text-align: center;
  padding: 3rem 2rem;
  background: var(--white);
  border-radius: var(--radius-md);
  border: 1px solid var(--cream-dark);
  transition: var(--transition);
}
.value-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card);
}

/* Territory card */
.territory-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 16/9;
}
.territory-card img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.territory-card:hover img { transform: scale(1.06); }
.territory-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11,29,58,0.85) 0%, transparent 60%);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.territory-card-overlay h3 { color: var(--cream); font-size: 1.8rem; }
.territory-card-overlay p { color: rgba(248,242,228,0.7); font-size: 0.85rem; }

/* Filter bar */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.filter-btn {
  padding: 0.55rem 1.3rem;
  border-radius: 99px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--white);
  color: var(--text-mid);
  border: 1.5px solid var(--cream-dark);
  cursor: pointer;
  transition: var(--transition);
}
.filter-btn:hover,
.filter-btn.active {
  background: var(--navy);
  color: var(--cream);
  border-color: var(--navy);
}

/* FAQ accordion */
.faq-item { border-bottom: 1px solid var(--cream-dark); }
.faq-question {
  width: 100%;
  text-align: left;
  padding: 1.5rem 0;
  background: transparent;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--navy);
  cursor: pointer;
  border: none;
  transition: color var(--transition);
}
.faq-question:hover { color: var(--gold); }
.faq-toggle { font-size: 1.5rem; transition: transform 0.35s ease; }
.faq-item.open .faq-toggle { transform: rotate(45deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
.faq-item.open .faq-answer { max-height: 400px; }
.faq-answer-inner { padding-bottom: 1.5rem; color: var(--text-mid); font-size: 0.95rem; line-height: 1.8; }

/* Form inputs */
.elementor-form input,
.elementor-form select,
.elementor-form textarea {
  border: 1.5px solid var(--cream-dark) !important;
  border-radius: var(--radius-sm) !important;
  background: var(--cream) !important;
  font-family: var(--font-body) !important;
  color: var(--text) !important;
  transition: border-color var(--transition) !important;
}
.elementor-form input:focus,
.elementor-form select:focus,
.elementor-form textarea:focus {
  border-color: var(--gold) !important;
  background: var(--white) !important;
  outline: none !important;
}

/* Toast notification */
.gusto-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: var(--navy);
  color: var(--cream);
  padding: 0.9rem 1.8rem;
  border-radius: 99px;
  font-size: 0.9rem;
  font-weight: 500;
  z-index: 9999;
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
  border-left: 3px solid var(--gold);
  white-space: nowrap;
}
.gusto-toast.show { transform: translateX(-50%) translateY(0); }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .elementor-column.hide-tablet { display: none !important; }
}
@media (max-width: 767px) {
  :root { --section-pad: 4rem 1.25rem; }
  h1 { font-size: 2.8rem; }
  h2 { font-size: 2rem; }
  .header-logo img { height: 48px !important; }
  .elementor-column.hide-mobile { display: none !important; }
  .filter-bar { gap: 0.5rem; }
  .filter-btn { font-size: 0.72rem; padding: 0.45rem 0.9rem; }
}

/* ============================================================
   STICKY HEADER JS HELPER
   (incollare in Elementor > Site Settings > Custom Code > Head)
   ============================================================ */
/*
<script>
window.addEventListener('scroll', function() {
  var header = document.querySelector('.e-header, #site-header, header.elementor-section');
  if (!header) return;
  if (window.scrollY > 60) {
    header.classList.add('header-scrolled');
    header.classList.remove('header-transparent');
  } else {
    header.classList.remove('header-scrolled');
    header.classList.add('header-transparent');
  }
}, { passive: true });
</script>
*/
