/*
Theme Name: Organic
Theme URI: https://templatesjungle.com/
Author: TemplatesJungle
Author URI: https://templatesjungle.com/
Description: Organic is specially designed product packaged for eCommerce store websites.
Version: 1.1
*/

/*--------------------------------------------------------------
This is main CSS file that contains custom style rules used in this template
--------------------------------------------------------------*/

/*--------------------------------------------------------------
/** VARIABLES
--------------------------------------------------------------*/
:root {
  --primary-color: #6BB252;
  --secondary-color: #364127;
  --accent-color: #F95F09;
  --success-color: #a3be4c;
  --light-bg: #f8f9fa;
  --border-color: #F7F7F7;
}

body {
  --heading-font: "Nunito", sans-serif;
  --bs-link-color: #333;
  --bs-link-hover-color: #333;
  --bs-link-color-rgb: 40,40,40;
  --bs-link-hover-color-rgb: 0,0,0;
  --bs-light-rgb: 248, 248, 248;
  --bs-font-sans-serif: "Open Sans", sans-serif;
  --bs-body-font-family: var(--bs-font-sans-serif);
  --bs-body-font-size: 1rem;
  --bs-body-font-weight: 400;
  --bs-body-line-height: 2;
  --bs-body-color: #747474;
  --bs-primary: #6BB252;
  --bs-primary-rgb: 107, 178, 82;
  --bs-secondary: #364127;
  --bs-secondary-rgb: 54, 65, 39;
  --bs-danger: #F95F09;
  --bs-danger-rgb: 249, 95, 9;
  --bs-success: #a3be4c;
  --bs-success-rgb: 163, 190, 76;
  --bs-primary-bg-subtle: #FFF9EB;
  --bs-success-bg-subtle: #eef5e5;
  --bs-border-color: #F7F7F7;
}

/*--------------------------------------------------------------
/** GENERAL
--------------------------------------------------------------*/
body {
  font-family: var(--bs-body-font-family);
  font-size: var(--bs-body-font-size);
  font-weight: var(--bs-body-font-weight);
  line-height: var(--bs-body-line-height);
  color: var(--bs-body-color);

}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font);
  font-weight: 700;
  color: #333;
}

a {
  color: var(--bs-link-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: var(--primary-color);
}

.btn {
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
}

.btn-outline-primary {
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-outline-primary:hover {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
}

.text-primary {
  color: var(--primary-color) !important;
}

.bg-primary {
  background-color: var(--primary-color) !important;
}

.bg-light {
  background-color: var(--light-bg) !important;
}

.bg-success-subtle {
  background-color: var(--bs-success-bg-subtle) !important;
}

/*--------------------------------------------------------------
/** HEADER
--------------------------------------------------------------*/
.site-header {
  width: 100%;
  z-index: 99;
  transition: all 0.3s ease;
  padding: 15px 0;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar-brand img {
  max-height: 50px;
}

.navbar-nav .nav-link {
  font-weight: 600;
  padding: 0.5rem 1rem;
  color: #333;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: var(--primary-color);
}

.dropdown-menu {
  border: none;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  border-radius: 10px;
  padding: 1rem;
}

.dropdown-item {
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 5px;
}

.dropdown-item:hover,
.dropdown-item.active {
  background-color: var(--bs-success-bg-subtle);
  color: var(--primary-color);
}

/*--------------------------------------------------------------
/** PRELOADER
--------------------------------------------------------------*/
.preloader-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #fff;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
}

.preloader {
  width: 50px;
  height: 50px;
  border: 5px solid var(--bs-success-bg-subtle);
  border-top: 5px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/*--------------------------------------------------------------
/** HERO SECTION
--------------------------------------------------------------*/
.hero-section {
  background-color: var(--bs-success-bg-subtle);
  padding: 5rem 0;
}

.hero-content h1 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

.hero-content p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
}

/*--------------------------------------------------------------
/** PRODUCT CARDS
--------------------------------------------------------------*/
.product-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  margin-bottom: 30px;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.product-card .card-img-top {
  height: 200px;
  object-fit: cover;
}

.product-card .card-body {
  padding: 1.5rem;
}

.product-card .card-title {
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.product-card .card-subtitle {
  color: #6c757d;
  margin-bottom: 1rem;
}

.product-card .card-text {
  margin-bottom: 1rem;
}

.product-card .card-footer {
  background-color: transparent;
  border-top: 1px solid var(--border-color);
  padding: 1rem 1.5rem;
}

/*--------------------------------------------------------------
/** CATEGORY CARDS
--------------------------------------------------------------*/
.category-card {
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.3s ease;
  border: 1px solid var(--border-color);
  margin-bottom: 30px;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.category-icon {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

/*--------------------------------------------------------------
/** BANNER SECTION
--------------------------------------------------------------*/
.banner-section {
  background-color: var(--bs-success-bg-subtle);
  padding: 3rem 0;
}

.banner-content h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.banner-content p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

/*--------------------------------------------------------------
/** FOOTER
--------------------------------------------------------------*/
.footer {
  background-color: var(--secondary-color);
  color: white;
  padding: 3rem 0;
}

.footer h5 {
  color: white;
  margin-bottom: 1.5rem;
}

.footer a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
}

.footer a:hover {
  color: var(--primary-color);
}

.footer .list-inline-item {
  margin-right: 1rem;
}

.footer .list-inline-item a {
  font-size: 1.2rem;
}

/*--------------------------------------------------------------
/** RESPONSIVE
--------------------------------------------------------------*/
@media (max-width: 991.98px) {
  .hero-content h1 {
    font-size: 2.5rem;
  }

  .banner-content h2 {
    font-size: 2rem;
  }
}

@media (max-width: 767.98px) {
  .hero-content h1 {
    font-size: 2rem;
  }

  .banner-content h2 {
    font-size: 1.8rem;
  }

  .product-card .card-img-top {
    height: 180px;
  }
}

@media (max-width: 575.98px) {
  .hero-content h1 {
    font-size: 1.8rem;
  }

  .banner-content h2 {
    font-size: 1.5rem;
  }

  .product-card .card-img-top {
    height: 160px;
  }
}

/* ==== Featured product card (solid card look) ==== */
.ag-card{
  background: #ffffff; /* ✅ card vera */
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 22px;
  box-shadow: 0 14px 35px rgba(0,0,0,.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .22s ease, box-shadow .22s ease;
}

.ag-card:hover{
  transform: translateY(-4px);
  box-shadow: 0 18px 48px rgba(0,0,0,.12);
}

.ag-card__link{
  text-decoration: none;
  color: inherit;
  display: block;
}

.ag-card__media{
  position: relative;
  aspect-ratio: 4 / 3;
  background: #f7f7f7; /* area immagine separata */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
}

.ag-card__img{
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 16px;
  background: #fff;       /* ✅ elimina scacchiera PNG */
  padding: 10px;
  display: block;
}

.ag-card__img-fallback{
  width: 100%;
  height: 100%;
  border-radius: 16px;
  background: rgba(0,0,0,.04);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size: 2rem;
  opacity:.55;
}

.ag-card__badge{
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(107,178,82,.14);
  border: 1px solid rgba(107,178,82,.28);
  color: #2f6b1e;
  font-weight: 800;
  font-size: .78rem;
}

.ag-card__body{
  padding: 14px 16px 10px;
}

.ag-card__title{
  margin: 0;
  font-weight: 800;
  font-size: 1.05rem;
  line-height: 1.2;

  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.5em;
}

.ag-card__subtitle{
  margin: 6px 0 0;
  color: rgba(0,0,0,.55);
  font-size: .9rem;

  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ag-card__footer{
  margin-top: 10px;
  display:flex;
  align-items:center;
  justify-content: space-between;
}

.ag-card__price{
  font-weight: 900;
  font-size: 1.05rem;
}

.ag-card__cta{
  padding: 0 16px 16px;
  margin-top: auto; /* CTA sempre in basso */
}
