/* =========================================================
   AgroKron Hero – Front Office CSS
   views/css/agrokronhero.css
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@700;800;900&family=Barlow:wght@400;500;600&display=swap');

/* ── LAYOUT ── */
.ak-hero-section {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 16px;
  padding: 20px;
  background: #f5f4f0;
  font-family: 'Barlow', sans-serif;
}

/* ── SLIDER ── */
.ak-slider {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: #1a1a18;
  min-height: 360px;
}

.ak-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  opacity: 0;
  transition: opacity 0.55s ease;
  pointer-events: none;
}
.ak-slide.active {
  opacity: 1;
  pointer-events: auto;
}

/* gradient bg via CSS variable set inline */
.ak-slide-bg {
  position: absolute;
  inset: 0;
  background: var(--ak-bg, #1a1a18);
  background-image:
    radial-gradient(ellipse at 80% -20%, color-mix(in srgb, var(--ak-accent,#e8a020) 18%, transparent), transparent 55%),
    radial-gradient(ellipse at -10% 110%, color-mix(in srgb, var(--ak-accent,#e8a020) 9%, transparent), transparent 50%);
}

/* decorative circles */
.ak-circle {
  position: absolute;
  border-radius: 50%;
  background: var(--ak-accent, #e8a020);
  pointer-events: none;
}
.ak-c1 { width:260px; height:260px; top:-70px; right:-50px; opacity:.10; }
.ak-c2 { width:200px; height:200px; bottom:-80px; left:28%;  opacity:.06; }
.ak-c3 { width:120px; height:120px; top:40%;  left:-40px; opacity:.04; background:#fff; }

/* slide inner content */
.ak-slide-inner {
  position: relative;
  z-index: 2;
  padding: 36px 40px;
  max-width: 580px;
}

.ak-slide-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ak-accent, #e8a020);
  margin-bottom: 10px;
}

.ak-slide-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 52px;
  font-weight: 900;
  color: #fff;
  line-height: .95;
  letter-spacing: -.5px;
}
.ak-slide-title em {
  font-style: normal;
  color: var(--ak-accent, #e8a020);
}

.ak-slide-sub {
  font-size: 14px;
  color: rgba(255,255,255,.52);
  margin-top: 10px;
  line-height: 1.55;
  max-width: 440px;
}

.ak-slide-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--ak-accent, #e8a020);
  color: #fff;
  border-radius: 8px;
  padding: 13px 24px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .05em;
  text-decoration: none;
  margin-top: 22px;
  transition: filter .15s, transform .1s;
}
.ak-slide-cta:hover { filter: brightness(1.12); transform: translateY(-1px); color:#fff; }
.ak-slide-cta:active { transform: translateY(0); }

/* dots */
.ak-dots {
  position: absolute;
  bottom: 20px;
  left: 38px;
  display: flex;
  gap: 5px;
  z-index: 3;
}
.ak-dot {
  width: 22px;
  height: 3px;
  border-radius: 2px;
  background: rgba(255,255,255,.22);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background .2s, width .25s;
}
.ak-dot.on {
  background: var(--ak-accent, #e8a020);
  width: 38px;
}

/* ── CATEGORIE ── */
.ak-cats {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ak-cat {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 18px 18px 16px 22px;
  min-height: 104px;
  border-radius: 12px;
  background: #1f1f1c;
  text-decoration: none;
  overflow: hidden;
  transition: background .18s, transform .18s;
}
.ak-cat:hover { background: #282822; transform: translateY(-2px); }
.ak-cat:hover .ak-cat-arr { transform: translateX(5px); }

/* left accent bar */
.ak-cat-stripe {
  position: absolute;
  top: 0; left: 0;
  width: 4px; height: 100%;
  background: #e8a020;
}

/* decorative icon */
.ak-cat-icon {
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%);
  font-size: 52px;
  opacity: .12;
  pointer-events: none;
  line-height: 1;
}

.ak-cat-eyebrow {
  display: block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #e8a020;
  margin-bottom: 4px;
}
.ak-cat-name {
  display: block;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 23px;
  font-weight: 800;
  color: #fff;
  line-height: 1;
}
.ak-cat-arr {
  display: inline-block;
  color: #e8a020;
  font-size: 18px;
  margin-left: 6px;
  transition: transform .18s;
}

/* ── RESPONSIVE — TABLET (≤ 960px) ── */
@media (max-width: 960px) {
  .ak-hero-section {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 14px;
  }
  .ak-slider { min-height: 300px; }
  .ak-slide-inner { padding: 26px 28px; }
  .ak-slide-title { font-size: 40px; }

  .ak-cats {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .ak-cat {
    flex: 1 1 calc(33.33% - 8px);
    min-height: 90px;
  }
}

/* ── RESPONSIVE — MOBILE (≤ 600px) ── */
@media (max-width: 600px) {
  .ak-hero-section { padding: 10px; gap: 10px; }
  .ak-slider { min-height: 250px; }
  .ak-slide-inner { padding: 20px 20px; }
  .ak-slide-title { font-size: 30px; }
  .ak-slide-sub { font-size: 13px; }
  .ak-slide-cta { font-size: 14px; padding: 10px 18px; margin-top: 14px; }
  .ak-dots { left: 20px; bottom: 14px; }

  .ak-cats { flex-direction: column; gap: 8px; }
  .ak-cat {
    flex: unset;
    min-height: 78px;
    padding: 13px 14px 11px 18px;
  }
  .ak-cat-name { font-size: 20px; }
  .ak-cat-icon { font-size: 40px; }
}

/* ── IMMAGINE PRODOTTO AGGIUNTA (Posizionata in modo sicuro a destra) ── */
.ak-slide-product {
  position: absolute;
  right: 5%;
  bottom: 0;
  max-height: 90%;
  max-width: 45%;
  object-fit: contain;
  z-index: 1; /* Rimane sotto al testo se per caso si sovrappone */
}

@media (max-width: 767px) {
  .ak-slide-product {
    display: none; /* Nascondiamo la foto su smartphone per non coprire i testi */
  }
}