/* ===== SMILING VOICE CUSTOM STYLES ===== */

:root {
  --sky-blue: #87CEEB;
  --ocean-blue: #3A86FF;
  --sunny-yellow: #FFD166;
  --grass-green: #06D6A0;
  --orange-punch: #FB8500;
  --dark-blue: #1D3557;
  --viola-uici: #9225db;
  --rosso-uici: #EF476F;
}

* { 
  box-sizing: border-box; 
}

body {
  font-family: 'Quicksand', sans-serif;
  background-color: #f8fbff;
  margin: 0;
  color: #333;
  line-height: 1.6;
}

/* ===== HEADER LOGOS SECTION ===== */
/* Logo wrapper styles reused inside navbar */
.logo-wrapper { display: flex; align-items: center; gap: 20px; }
.logo-main { height: 60px; width: auto; }
.logo-sep { width: 2px; height: 40px; background: #eee; }
.logo-cepell { height: 90px; width: auto; }

/* ===== NAVBAR BOOTSTRAP CUSTOMIZATIONS ===== */
.site-navbar {
  background: white !important;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  padding: 15px 0;
}

.site-navbar.admin-navbar {
  background: var(--dark-blue) !important;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.site-navbar .navbar-brand {
  display: flex;
  align-items: center;
  gap: 15px;
  text-decoration: none;
}

.logo-icon { 
  width: 50px; 
  height: 50px; 
  background: linear-gradient(135deg, var(--ocean-blue), var(--viola-uici)); 
  border-radius: 15px; 
  display: flex; 
  align-items: center; 
  justify-content: center;
  color: white; 
  font-size: 1.5rem;
}

.logo-text h1 { 
  font-family: 'Fredoka One', cursive; 
  color: var(--dark-blue); 
  font-size: 1.2rem; 
  line-height: 1.1; 
  margin: 0;
}

.logo-text small {
  color: var(--ocean-blue); 
  font-weight: bold;
}

/* Custom navbar buttons */
.site-navbar .navbar-nav .nav-link {
  padding: 8px 18px !important;
  border-radius: 25px;
  color: white !important;
  font-weight: 700;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  margin: 0 5px;
  text-decoration: none;
}

.nav-link.btn-home { 
  background: var(--ocean-blue); 
}
.nav-link.btn-scuola { 
  background: var(--grass-green); 
}
.nav-link.btn-donatori { 
  background: var(--orange-punch); 
}
.nav-link.btn-materiali { 
  background: var(--viola-uici); 
}
.nav-link.btn-servizi { 
  background: var(--sunny-yellow); 
  color: #333 !important; 
}
.nav-link.btn-contatti { 
  background: var(--rosso-uici); 
}

.site-navbar .navbar-nav .nav-link:hover { 
  transform: scale(1.05); 
  filter: brightness(1.1); 
  color: white !important;
}

.nav-link.btn-servizi:hover {
  color: #333 !important;
}

/* ===== HERO SECTION ===== */
.hero {
  background-color: var(--sky-blue);
  background-image: url('https://www.transparenttextures.com/patterns/kids-outline.png');
  padding: 60px 5%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 40px;

  border-bottom: 5px solid;
  border-image: linear-gradient(
  to right, 
  #4caf50 0% 20%,   /* Verde */
  #ffffff 20% 40%,  /* Bianco */
  #f44336 40% 60%,  /* Rosso */
  #2196f3 60% 80%,  /* Blu */
  #ffeb3b 80% 100%  /* Giallo */
  ) 1;
  padding-bottom: 10px; 
}

.hero-content { 
  color: white; 
}

.hero-content h2 { 
  font-family: 'Fredoka One', cursive; 
  font-size: 3rem; 
  line-height: 1.1; 
  margin-bottom: 25px; 
}

.hero-content span { 
  color: var(--sunny-yellow); 
  text-shadow: 2px 2px rgba(0,0,0,0.1); 
}

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

.btn-area {
  display: inline-block;
  background: var(--orange-punch);
  color: white;
  padding: 18px 35px;
  border-radius: 50px;
  font-size: 1.1rem;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 0 6px 0 #bc6400;
  border: 3px solid white;
  transition: 0.2s;
}

.btn-area:hover {
  color: white;
  text-decoration: none;
}

.btn-area:active { 
  transform: translateY(3px); 
  box-shadow: 0 3px 0 #bc6400; 
}

.hero-illustration img { 
  max-width: 100%; 
  height: auto; 
  border-radius: 30px; 
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.15)); 
}

/* ===== CARDS SECTION ===== */
.cards-container {
  margin-top: -60px;
  padding: 60px 15px 80px;
}

.card {
  background: white;
  padding: 40px 30px;
  border-radius: 40px 15px 40px 15px;
  text-align: center;
  box-shadow: 0 15px 30px rgba(0,0,0,0.05);
  border: 8px solid;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

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

/* Card color variants */
.card.blue { 
  border-color: #A2D2FF; 
  background-color: #f0f7ff; 
}
.card.green { 
  border-color: #B7E4C7; 
  background-color: #f1fff6; 
}
.card.yellow { 
  border-color: #FFEA8A; 
  background-color: #fffdf2; 
}
.card.viola { 
  border-color: #b388eb; 
  background-color: #f7f0ff; 
}
.card.rossa { 
  border-color: #ffadad; 
  background-color: #fff5f5; 
}
.card.arancio { 
  border-color: #ffd6a5; 
  background-color: #fffaf0; 
}

.card-icon { 
  font-size: 3.5rem; 
  margin-bottom: 20px; 
  color: var(--dark-blue); 
}

.card h3 { 
  font-family: 'Fredoka One', cursive; 
  margin-bottom: 15px; 
  font-size: 1.4rem; 
  color: var(--dark-blue); 
}

.card p { 
  font-size: 1rem; 
  margin-bottom: 20px; 
}

.card a { 
  font-weight: 700; 
  color: var(--ocean-blue); 
  text-decoration: none; 
  border-bottom: 2px solid; 
  padding-bottom: 2px; 
}

.card a:hover {
  color: var(--dark-blue);
  text-decoration: none;
}

.cepell-logo { 
  max-width: 150px; 
  margin: 15px auto; 
  display: block; 
}

/* ===== FOOTER ===== */
footer {
  background: var(--dark-blue);
  color: white;
  text-align: center;
  padding: 60px 20px;
  margin-top: 50px;
  border-top: 8px dashed var(--sunny-yellow);
}

.footer-pattern {
  height: 20px;
  background-image: repeating-linear-gradient(45deg, var(--orange-punch), var(--orange-punch) 10px, var(--sunny-yellow) 10px, var(--sunny-yellow) 20px);
  margin-bottom: 30px;
  border-radius: 10px;
  max-width: 300px;
  margin-left: auto;
  margin-right: auto;
}

footer .bi {
  font-size: 1.5rem;
  margin: 0 10px;
  color: white;
  transition: color 0.3s ease;
}

footer .bi:hover {
  color: var(--sunny-yellow);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
  .hero-content h2 { 
    font-size: 2.2rem; 
  }

  .cards-container { 
    margin-top: 20px; 
  }

  .site-navbar .navbar-nav {
    text-align: center;
    margin-top: 15px;
  }

  .site-navbar .navbar-nav .nav-link {
    margin: 5px;
  }
}

/* ===== ACCESSIBILITY IMPROVEMENTS ===== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus styles for better accessibility */
.nav-link:focus,
.btn-area:focus,
.card a:focus {
  outline: 3px solid var(--sunny-yellow);
  outline-offset: 2px;
}

/* Skip link for screen readers */
.skip-link {
  position: absolute;
  top: -40px;
  left: 6px;
  background: var(--dark-blue);
  color: white;
  padding: 8px;
  text-decoration: none;
  border-radius: 4px;
  z-index: 1000;
}

.skip-link:focus {
  top: 6px;
}

/* ===== NEWS LIST ===== */
.news-list-hero {
  background: linear-gradient(135deg, rgba(58, 134, 255, 0.16), rgba(146, 37, 219, 0.12));
  border-bottom: 4px solid rgba(29, 53, 87, 0.08);
}

.news-list-hero__content {
  max-width: 760px;
}

.news-list-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--sunny-yellow);
  color: var(--dark-blue);
  font-weight: 700;
  margin-bottom: 20px;
}

.news-list-hero__title {
  color: var(--dark-blue);
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  margin-bottom: 16px;
}

.news-list-hero__text {
  font-size: 1.1rem;
  color: rgba(29, 53, 87, 0.9);
  margin-bottom: 0;
  max-width: 62ch;
}

.news-list-section {
  background: #f8fbff;
}

.news-grid-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  background: #fff;
  border: 4px solid #dcecff;
  border-radius: 28px 12px 28px 12px;
  box-shadow: 0 12px 28px rgba(29, 53, 87, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
}

.news-grid-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 34px rgba(29, 53, 87, 0.12);
}

.news-grid-card__body {
  padding: 28px 24px 18px;
}

.news-grid-card__meta {
  margin-bottom: 18px;
}

.news-grid-card__date {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(6, 214, 160, 0.15);
  color: var(--dark-blue);
  font-size: 0.95rem;
  font-weight: 700;
}

.news-grid-card__heading {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
}

.news-grid-card__thumb {
  width: 82px;
  height: 82px;
  border-radius: 18px;
  object-fit: cover;
  flex-shrink: 0;
  border: 3px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 20px rgba(29, 53, 87, 0.12);
}

.news-grid-card__title {
  font-size: 1.45rem;
  line-height: 1.2;
  margin: 0;
}

.news-grid-card__link {
  color: var(--dark-blue);
  text-decoration: none;
  border-bottom: none;
}

.news-grid-card__link:hover {
  color: var(--ocean-blue);
}

.news-grid-card__excerpt {
  margin-bottom: 0;
  color: #4b5563;
  font-size: 1rem;
}

.news-grid-card__footer {
  padding: 0 24px 24px;
}

.news-grid-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--ocean-blue);
  text-decoration: none;
  border-bottom: none;
}

.news-grid-card__cta:hover {
  color: var(--dark-blue);
}

.news-list-empty {
  background: #fff;
  border: 4px dashed rgba(58, 134, 255, 0.3);
  border-radius: 28px;
  text-align: center;
  padding: 56px 24px;
  color: var(--dark-blue);
}

.news-list-empty__icon {
  font-size: 3rem;
  color: var(--orange-punch);
  margin-bottom: 16px;
}

@media (max-width: 768px) {
  .news-grid-card__heading {
    flex-direction: column;
  }

  .news-grid-card__thumb {
    width: 100%;
    height: 180px;
  }
}
