/* ============================================
   OFFERTEINCITTA.IT — Main Override CSS
   Fix navbar, logo, layout, mobile
   ============================================ */

/* === NAVBAR FIX — sfondo sempre visibile su mobile === */
.site-navbar {
  background: #111111 !important;
  border-bottom: 3px solid #FFD700 !important;
  position: sticky;
  top: 0;
  z-index: 1030;
  min-height: 72px;
  padding-top: 10px !important;
  padding-bottom: 10px !important;
  box-shadow: 0 2px 12px rgba(0,0,0,0.7);
}

/* Menu collapse su mobile: sfondo scuro */
.site-navbar .navbar-collapse {
  background: #111111;
  padding: 10px 0 16px 0;
  border-top: 1px solid #2a2a2a;
}
@media (min-width: 992px) {
  .site-navbar .navbar-collapse {
    background: transparent;
    padding: 0;
    border-top: none;
  }
}

/* Logo dimensioni — desktop */
.site-navbar .navbar-brand img,
.site-navbar .navbar-brand .oic-logo-svg,
.site-navbar .oic-navbar-logo {
  height: 50px !important;
  width: auto !important;
  max-width: 230px !important;
  object-fit: contain;
  display: block;
}

/* === NAVBAR TABLET (991px) === */
@media (max-width: 991px) {
  .site-navbar {
    min-height: 64px;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
  }
  .site-navbar .navbar-brand img,
  .site-navbar .navbar-brand .oic-logo-svg,
  .site-navbar .oic-navbar-logo {
    height: 44px !important;
    max-width: 200px !important;
  }
}

/* === NAVBAR SMALL MOBILE (576px) === */
@media (max-width: 576px) {
  .site-navbar {
    min-height: 58px;
    padding-top: 7px !important;
    padding-bottom: 7px !important;
  }
  .site-navbar .navbar-brand img,
  .site-navbar .navbar-brand .oic-logo-svg,
  .site-navbar .oic-navbar-logo {
    height: 40px !important;
    max-width: 175px !important;
  }
}

/* Toggler visibile */
.site-navbar .navbar-toggler {
  border: 1px solid rgba(255,215,0,0.4) !important;
  padding: 6px 10px;
  border-radius: 8px;
  color: #FFD700 !important;
}
.site-navbar .navbar-toggler:focus { box-shadow: none; }

/* Nav links */
.site-navbar .nav-link {
  color: #FFFFFF !important;
  font-weight: 500;
  padding: 8px 14px !important;
  border-radius: 8px;
  transition: all 0.2s;
}
.site-navbar .nav-link:hover,
.site-navbar .nav-link.active {
  color: #FFD700 !important;
  background: rgba(255,215,0,0.1);
}

/* === FLASHBAR === */
.site-flashbar {
  background: #FFD700;
  color: #1a1a1a;
  font-weight: 700;
  font-size: 12px;
  height: 36px;
  overflow: hidden;
  display: flex;
  align-items: center;
}
.flashbar-track span {
  color: #1a1a1a;
}

/* === LAYOUT 3 COLONNE === */
.site-body {
  display: flex;
  min-height: calc(100vh - 62px - 36px);
  align-items: flex-start;
}

.sidebar-left {
  width: 220px;
  min-width: 220px;
  background: #1e1e1e;
  border-right: 1px solid #2a2a2a;
  min-height: calc(100vh - 98px);
  position: sticky;
  top: 98px;
  overflow-y: auto;
  flex-shrink: 0;
}

.content-main {
  flex: 1;
  min-width: 0;
  overflow-x: hidden;
}

.sidebar-right {
  width: 220px;
  min-width: 220px;
  background: #1e1e1e;
  border-left: 1px solid #2a2a2a;
  min-height: calc(100vh - 98px);
  position: sticky;
  top: 98px;
  overflow-y: auto;
  flex-shrink: 0;
}

/* === HERO SECTION === */
.hero-box {
  margin: 16px;
  padding: 28px 24px;
  background: radial-gradient(circle at top right, rgba(255,215,0,.15), transparent 40%),
              linear-gradient(180deg, #2a2a2a, #1d1d1d);
  border: 1px solid #3a3a3a;
  border-radius: 14px;
}
.hero-kicker {
  color: #FFD700;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 10px;
}
.hero-title {
  font-size: clamp(22px, 4vw, 36px);
  font-weight: 800;
  color: #FFFFFF;
  line-height: 1.2;
  margin-bottom: 12px;
}
.hero-title span { color: #FFD700; }
.hero-description {
  color: #AAAAAA;
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 20px;
  max-width: 600px;
}

/* === SEARCH BAR === */
.hero-search {
  background: #222;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 20px;
}
.hero-search .form-control,
.hero-search .form-select {
  background: #333;
  border: 1px solid #444;
  color: #fff;
  border-radius: 8px;
}
.hero-search .form-control:focus,
.hero-search .form-select:focus {
  border-color: #FFD700;
  box-shadow: 0 0 0 2px rgba(255,215,0,0.15);
  background: #333;
  color: #fff;
}
.hero-search .form-control::placeholder { color: #666; }
.hero-search option { background: #333; color: #fff; }

/* === HERO STATS === */
.hero-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.hero-stat {
  background: rgba(255,215,0,0.08);
  border: 1px solid rgba(255,215,0,0.2);
  border-radius: 10px;
  padding: 10px 16px;
  min-width: 130px;
  flex: 1;
}
.hero-stat strong {
  display: block;
  color: #FFD700;
  font-size: 20px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 4px;
}
.hero-stat span {
  color: #888;
  font-size: 11px;
}

/* === SECTION HEAD === */
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px 6px;
  margin-top: 8px;
}
.section-head h2 {
  font-size: 16px;
  font-weight: 700;
  color: #FFFFFF;
  margin: 0;
}
.section-head a {
  color: #FFD700;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}
.section-head a:hover { text-decoration: underline; }

/* === CATEGORIA CHIPS === */
.cat-chips-wrap {
  padding: 8px 16px 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.cat-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 10px 14px;
  text-decoration: none;
  color: #aaa;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  min-width: 60px;
}
.cat-chip:hover, .cat-chip.active {
  border-color: #FFD700;
  color: #FFD700;
  background: rgba(255,215,0,0.08);
}
.cat-chip .cat-icon {
  font-size: 22px;
  line-height: 1;
}

/* === OFFER CARDS === */
.offer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  padding: 8px 16px 16px;
}
.offer-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  display: block;
  color: inherit;
}
.offer-card:hover {
  border-color: #FFD700;
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(255,215,0,0.15);
}
.offer-card .card-img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: #333;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
}
.offer-card .card-img-placeholder {
  width: 100%;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, #2a2a2a, #333);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
}
.offer-card .card-body {
  padding: 12px;
}
.offer-card .card-store {
  font-size: 10px;
  color: #888;
  margin-bottom: 4px;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.5px;
}
.offer-card .card-title {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
}
.offer-card .card-price-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.offer-card .price-new {
  color: #FFD700;
  font-size: 16px;
  font-weight: 800;
}
.offer-card .price-old {
  color: #666;
  font-size: 12px;
  text-decoration: line-through;
}
.offer-card .price-badge {
  background: #FF6B35;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
}
.offer-card .card-footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid #3a3a3a;
}
.offer-card .card-city {
  font-size: 10px;
  color: #666;
}
.offer-card .card-likes {
  font-size: 11px;
  color: #888;
  display: flex;
  align-items: center;
  gap: 3px;
}

/* === SKELETON LOADING === */
.skeleton {
  background: linear-gradient(90deg, #2a2a2a 25%, #333 50%, #2a2a2a 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: 8px;
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.skeleton-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  overflow: hidden;
}
.skeleton-img { width: 100%; aspect-ratio: 4/3; }
.skeleton-text { height: 12px; margin: 12px; border-radius: 4px; }
.skeleton-text-sm { height: 10px; margin: 6px 12px; width: 60%; }

/* === STORE CARDS === */
.store-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  padding: 8px 16px 16px;
}
.store-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 14px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: all 0.2s;
}
.store-card:hover {
  border-color: #FFD700;
  box-shadow: 0 4px 16px rgba(255,215,0,0.1);
  transform: translateY(-2px);
}
.store-card .store-logo {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #333;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin: 0 auto 10px;
  border: 2px solid #3a3a3a;
}
.store-card .store-name {
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}
.store-card .store-cat {
  font-size: 10px;
  color: #888;
}
.store-card .store-badge {
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  margin-top: 6px;
  display: inline-block;
}

/* === SLIDES === */
.slides-wrap {
  margin: 0 16px 8px;
  position: relative;
}
.slide-box {
  background: linear-gradient(135deg, #2a2a2a, #1e1e1e);
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 20px;
  display: none;
}
.slide-box.active { display: block; }
.slide-badge {
  background: rgba(255,215,0,0.15);
  color: #FFD700;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  display: inline-block;
  margin-bottom: 10px;
}
.slide-box h3 {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}
.slide-box p {
  color: #aaa;
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 12px;
}
.slider-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}
.slider-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: #444;
  cursor: pointer;
  padding: 0;
  transition: all 0.2s;
}
.slider-dots button.active {
  background: #FFD700;
  width: 20px;
  border-radius: 4px;
}

/* === SIDEBAR WIDGETS === */
.sidebar-widget {
  padding: 14px 12px;
  border-bottom: 1px solid #2a2a2a;
}
.sidebar-widget-title {
  font-size: 10px;
  font-weight: 800;
  color: #FFD700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
}
.quick-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  background: #222;
  border: 1px solid #2e2e2e;
  border-radius: 8px;
  margin-bottom: 6px;
  text-decoration: none;
  color: #ccc;
  font-size: 12px;
  transition: all 0.2s;
}
.quick-chip:hover {
  border-color: #FFD700;
  color: #FFD700;
  background: rgba(255,215,0,0.05);
}
.stat-mini {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 8px;
}
.stat-mini strong {
  color: #FFD700;
  font-size: 16px;
  font-weight: 800;
}
.stat-mini span {
  color: #888;
  font-size: 11px;
}

/* === RIGHT BANNER === */
.right-banner {
  background: linear-gradient(160deg, #2a2a2a, #1e1e1e);
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  margin: 14px 10px;
}
.right-banner img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  margin-bottom: 10px;
}

/* === HOT / TOP LISTS === */
.hot-list-item, .top-list-item {
  display: flex;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid #222;
  text-decoration: none;
  color: inherit;
  align-items: center;
  transition: all 0.2s;
}
.hot-list-item:hover, .top-list-item:hover { color: #FFD700; }
.hot-list-item:last-child, .top-list-item:last-child { border-bottom: none; }
.hot-item-img {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: #333;
  object-fit: cover;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}
.hot-item-info { flex: 1; min-width: 0; }
.hot-item-title {
  font-size: 11px;
  font-weight: 600;
  color: #ddd;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
.hot-item-price {
  font-size: 12px;
  color: #FFD700;
  font-weight: 700;
}

/* === FOOTER === */
.footer-box {
  background: #111;
  border-top: 1px solid #2a2a2a;
  padding: 28px 20px;
  margin-top: 20px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
.footer-links {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-links a {
  color: #888;
  font-size: 12px;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: #FFD700; }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}
.footer-col h4 {
  color: #FFD700;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 10px;
}
.footer-col a {
  display: block;
  color: #888;
  font-size: 12px;
  text-decoration: none;
  margin-bottom: 6px;
  transition: color 0.2s;
}
.footer-col a:hover { color: #FFD700; }
.footer-bottom {
  border-top: 1px solid #2a2a2a;
  padding-top: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.footer-bottom p {
  color: #555;
  font-size: 11px;
  margin: 0;
}

/* === MOBILE BOTTOM NAV === */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #111111;
  border-top: 1px solid #2a2a2a;
  z-index: 1000;
  padding: 8px 0 4px;
  justify-content: space-around;
}
.mobile-bottom-nav a {
  color: #888;
  font-size: 10px;
  font-weight: 600;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-width: 44px;
  padding: 4px 8px;
  border-radius: 8px;
  transition: all 0.2s;
}
.mobile-bottom-nav a i {
  font-size: 20px;
  line-height: 1;
}
.mobile-bottom-nav a.active,
.mobile-bottom-nav a:hover {
  color: #FFD700;
}
@media (max-width: 768px) {
  .mobile-bottom-nav { display: flex; }
  .sidebar-left { display: none !important; }
  .sidebar-right { display: none !important; }
  .content-main { padding-bottom: 70px; }
}
@media (min-width: 1100px) {
  .sidebar-right { display: block !important; }
}

/* === MODAL LOGIN === */
.login-modal .modal-content {
  background: #1e1e1e;
  border: 1px solid #3a3a3a;
  border-radius: 16px;
  color: #fff;
}
.login-modal .modal-header {
  border-bottom: 1px solid #2a2a2a;
  padding: 20px 24px;
}
.login-modal .btn-close {
  filter: invert(1);
  opacity: 0.6;
}
.login-modal .btn-close:hover { opacity: 1; }
.login-modal .modal-body { padding: 20px 24px; }
.login-modal .form-control {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  color: #fff;
  border-radius: 8px;
}
.login-modal .form-control:focus {
  background: #2a2a2a;
  border-color: #FFD700;
  color: #fff;
  box-shadow: 0 0 0 2px rgba(255,215,0,0.15);
}
.login-modal .form-label { color: #aaa; font-size: 12px; margin-bottom: 6px; }

/* === VOLANTINI === */
.flyer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  padding: 8px 16px 16px;
}
.flyer-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
}
.flyer-card:hover {
  border-color: #FFD700;
  box-shadow: 0 6px 20px rgba(255,215,0,0.12);
  transform: translateY(-2px);
}
.flyer-cover {
  aspect-ratio: 3/4;
  background: linear-gradient(135deg, #2a2a2a, #333);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  border-bottom: 1px solid #3a3a3a;
}
.flyer-info { padding: 12px; }
.flyer-store { font-size: 11px; color: #888; font-weight: 600; margin-bottom: 4px; }
.flyer-title { font-size: 13px; font-weight: 700; color: #fff; margin-bottom: 8px; }
.flyer-dates { font-size: 10px; color: #666; }

/* === ANNUNCI === */
.annunci-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
  padding: 8px 16px 16px;
}
.annuncio-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  color: inherit;
  display: block;
}
.annuncio-card:hover {
  border-color: #FFD700;
  box-shadow: 0 6px 20px rgba(255,215,0,0.12);
}

/* === FORM INPUTS SCURI === */
.form-select.input-dark, .form-control.input-dark {
  background: #2a2a2a !important;
  border: 1px solid #3a3a3a !important;
  color: #fff !important;
  border-radius: 8px;
}
.form-select.input-dark:focus, .form-control.input-dark:focus {
  border-color: #FFD700 !important;
  box-shadow: 0 0 0 2px rgba(255,215,0,0.15) !important;
}
.form-select.input-dark option { background: #2a2a2a; color: #fff; }

/* === MASCOTTE EMPTY STATE === */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #555;
}
.empty-state .mascot { font-size: 60px; margin-bottom: 16px; display: block; }
.empty-state h3 { font-size: 16px; font-weight: 700; color: #888; margin-bottom: 8px; }
.empty-state p { font-size: 13px; color: #555; }

/* === TOAST CUSTOM === */
.toast-container { z-index: 9999; }
.toast { background: #2a2a2a; border: 1px solid #3a3a3a; color: #fff; }
.toast.toast-success { border-left: 4px solid #00C851; }
.toast.toast-error { border-left: 4px solid #FF4444; }
.toast.toast-info { border-left: 4px solid #4A90D9; }

/* === SCROLLBAR === */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #1a1a1a; }
::-webkit-scrollbar-thumb { background: #3a3a3a; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #FFD700; }

/* === UTILITY === */
.text-brand { color: #FFD700 !important; }
.bg-brand { background: #FFD700 !important; color: #1a1a1a !important; }
.border-brand { border-color: #FFD700 !important; }
.rounded-brand { border-radius: 12px !important; }

/* ============================================
   AGGIORNAMENTO HOMEPAGE & SEZIONI NUOVE
   ============================================ */

/* Flash Bar */
.flash-bar {
  background: linear-gradient(90deg, #cc0000, #1a1a1a, #cc0000);
  background-size: 200% 100%;
  animation: flashSlide 4s ease infinite;
  color: #fff;
  font-size: 13px;
  min-height: 40px;
  display: flex;
  align-items: center;
  padding: 6px 12px;
  flex-wrap: nowrap;
  gap: 8px;
}

/* Flash-bar responsive mobile */
@media (max-width: 767px) {
  .flash-bar {
    min-height: 40px;
    padding: 6px 10px;
    flex-wrap: nowrap;
    overflow: hidden;
  }
  .flash-bar .flash-bar-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    min-width: 0;
    font-size: 12px;
  }
  .flash-bar .flash-bar-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 6px;
  }
  .flash-bar .btn-warning {
    font-size: 11px;
    padding: 3px 10px;
    white-space: nowrap;
  }
}
@keyframes flashSlide {
  0%{background-position:0% 50%} 50%{background-position:100% 50%} 100%{background-position:0% 50%}
}

/* OIC Navbar standalone (homepage) */
.oic-navbar {
  background: #111111 !important;
  border-bottom: 2px solid #FFD700;
  position: sticky;
  top: 0;
  z-index: 1030;
}
.oic-navbar .nav-link { color: #fff !important; font-weight: 500; }
.oic-navbar .nav-link:hover, .oic-navbar .nav-link.active { color: #FFD700 !important; }
.oic-input { background:#1e1e1e !important; border-color:#333 !important; color:#fff !important; }
.oic-input:focus { border-color:#FFD700 !important; box-shadow:0 0 0 2px rgba(255,215,0,0.2) !important; }
.oic-input option { background:#1e1e1e; }

/* Layout shell senza sidebar (homepage) */
.layout-shell {
  display: flex;
  gap: 0;
  min-height: 80vh;
  align-items: flex-start;
}
.sidebar-left { padding: 16px; }
.sidebar-right { padding: 16px; }
.main-content { flex: 1; min-width: 0; padding: 20px 16px; }
@media(max-width:1199px) { .main-content { padding: 12px; } }

/* Widget Boxes */
.widget-box {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  padding: 14px;
}
.widget-title {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid #2a2a2a;
}

/* Stat Mini in sidebar */
.stat-mini {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid #222;
}
.stat-mini:last-child { border-bottom: none; }
.stat-val { color: #FFD700; font-weight: 800; font-size: 15px; }
.stat-lbl { color: #888; font-size: 11px; }

/* Badge categorie sidebar */
.badge-cat {
  background: #222;
  color: #FFD700;
  border: 1px solid #333;
  border-radius: 16px;
  padding: 3px 10px;
  font-size: 11px;
  text-decoration: none;
  transition: all 0.2s;
}
.badge-cat:hover { background: #FFD700; color: #000; }

/* Chip categorie mobile */
.chip-cat {
  background: #1a1a1a;
  color: #fff;
  border: 1px solid #333;
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 13px;
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.2s;
}
.chip-cat:hover { background: #FFD700; color: #000; border-color: #FFD700; }

/* KPI Cards */
.kpi-card {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  padding: 14px;
  transition: border-color 0.2s;
}
.kpi-card:hover { border-color: #FFD700; }
.kpi-val { font-size: 20px; font-weight: 800; color: #FFD700; }
.kpi-lbl { font-size: 11px; color: #888; margin-top: 2px; }

/* Section Titles */
.section-title {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
}

/* Grid Offerte */
.grid-offerte {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.card-offer {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.25s;
}
.card-offer:hover { border-color: #FFD700; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(255,215,0,0.15); }
.card-offer-body { padding: 10px; }

/* Skeleton loading */
.loading-skeleton { animation: skeletonPulse 1.5s infinite; }
.skeleton-img { height: 120px; background: #2a2a2a; border-radius: 8px 8px 0 0; }
.skeleton-text { height: 60px; background: #222; margin: 10px; border-radius: 6px; }
@keyframes skeletonPulse { 0%,100%{opacity:1} 50%{opacity:0.5} }

/* Like Button */
.btn-like {
  background: none;
  border: 1px solid #333;
  color: #888;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 13px;
}
.btn-like:hover { color: #FF6B9D; border-color: #FF6B9D; }
.btn-like.liked { color: #FF6B9D; border-color: #FF6B9D; background: rgba(255,107,157,0.1); }

/* Mobile Bottom Nav */
.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1040;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 8px 0;
  border-top: 2px solid #FFD700;
}
.mobile-bottom-nav .nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: #888;
  text-decoration: none;
  font-size: 10px;
  gap: 2px;
  padding: 4px 10px;
  border-radius: 8px;
  transition: all 0.2s;
}
.mobile-bottom-nav .nav-item i { font-size: 20px; }
.mobile-bottom-nav .nav-item.active, .mobile-bottom-nav .nav-item:hover { color: #FFD700; }

/* Footer hover links */
.hover-yellow:hover { color: #FFD700 !important; }

/* Volantino Card */
.volantino-card { transition: all 0.2s; }
.volantino-card:hover { border-color: #FFD700 !important; transform: scale(1.02); }

/* Store Card */
.store-card { transition: all 0.2s; }
.store-card:hover { border-color: #FFD700 !important; }

/* Body padding bottom per mobile nav */
@media(max-width:1199px) {
  body { padding-bottom: 72px; }
}

/* ============================================
   PATCH v2 — Spacing, Footer, Images, Mobile
   ============================================ */

/* === SPAZIATURA sotto navbar + flashbar su mobile === */
/* Il layout-shell deve partire SOTTO la fascia gialla, non sovrapporsi */
.layout-shell {
  padding-top: 0;
}

/* Aggiunge spazio tra navbar+flashbar e il contenuto principale */
@media (max-width: 991px) {
  .layout-shell {
    padding-top: 12px;   /* 12px extra gap su mobile */
  }
  .site-flashbar {
    position: relative;
    z-index: 1020;      /* sempre sopra il contenuto */
  }
  /* Evita sovrapposizione flashbar gialla su contenuto hero */
  .hero-box {
    margin-top: 8px;
  }
  .main-content {
    padding-top: 8px;
  }
}

/* === OTTIMIZZAZIONE IMMAGINI CARD === */
/* Banner carousel: proporzione corretta */
.carousel-item img,
.carousel-img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  object-position: center;
  border-radius: 10px;
  display: block;
}
@media (max-width: 768px) {
  .carousel-item img, .carousel-img { height: 180px; }
}

/* Offer card: immagini nette al corretto aspect-ratio */
.offer-card .card-img-real {
  width: 100%;
  height: 140px;
  object-fit: cover;
  object-position: center;
  background: #333;
  border-radius: 10px 10px 0 0;
  display: block;
}

/* Store/negozio card avatar */
.store-card .store-avatar img,
.negozio-avatar {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid #FFD700;
}

/* Sidebar banner immagini */
.sidebar-banner img {
  width: 100%;
  height: auto;
  max-height: 180px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

/* === BANNER HERO CORRETTO === */
.hero-carousel {
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 16px;
}
.hero-carousel .carousel-caption {
  background: linear-gradient(transparent, rgba(0,0,0,0.75));
  bottom: 0;
  left: 0;
  right: 0;
  text-align: left;
  padding: 20px 20px 16px;
  border-radius: 0 0 14px 14px;
}

/* === LAYOUT SHELL FIX desktop — nessun padding inutile === */
@media (min-width: 992px) {
  .main-content {
    padding: 0;
  }
}

/* === FLASHBAR mobile: testo non tagliato === */
@media (max-width: 576px) {
  .site-flashbar {
    font-size: 11px;
    height: 32px;
  }
  .flashbar-track {
    white-space: nowrap;
  }
}

/* === CARD IMMAGINI GENERALI: nessun blur/allungamento === */
img {
  image-rendering: auto;
}
.card img, .widget-box img {
  max-width: 100%;
  height: auto;
}

/* === PRIVACY / LEGAL pages === */
.legal-page {
  max-width: 860px;
  margin: 0 auto;
  padding: 32px 16px 64px;
  color: #ccc;
  line-height: 1.8;
}
.legal-page h1 {
  color: #FFD700;
  font-size: 2rem;
  margin-bottom: 8px;
}
.legal-page h2 {
  color: #FFD700;
  font-size: 1.2rem;
  margin-top: 32px;
  margin-bottom: 8px;
  border-bottom: 1px solid #333;
  padding-bottom: 6px;
}
.legal-page p, .legal-page li { color: #aaa; font-size: 14px; }
.legal-page a { color: #FFD700; }
.legal-page .last-update {
  color: #666;
  font-size: 12px;
  margin-bottom: 24px;
}

/* === FARMACIA / NUMERI UTILI === */
.numeri-utili-card {
  background: #1e1e1e;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, background 0.2s;
}
.numeri-utili-card:hover {
  border-color: #FFD700;
  background: rgba(255,215,0,0.06);
}
.numeri-utili-card .nu-icon {
  font-size: 28px;
  width: 44px;
  text-align: center;
  flex-shrink: 0;
}
.numeri-utili-card .nu-label { font-weight: 700; color: #fff; font-size: 14px; }
.numeri-utili-card .nu-number { color: #FFD700; font-size: 18px; font-weight: 800; }
.numeri-utili-card .nu-desc { color: #888; font-size: 11px; }

/* === FOOTER FIX - visibilità testo === */
footer .text-muted { color: #aaaaaa !important; }
footer a.text-muted { color: #aaaaaa !important; }
footer a.text-muted:hover, footer a.hover-yellow:hover { color: #FFD700 !important; }
footer h6 { color: #FFD700 !important; font-weight: 700; letter-spacing: 0.5px; }
footer .badge { font-size: 11px !important; padding: 7px 14px !important; }
.hover-yellow { transition: color 0.2s; }
.hover-yellow:hover { color: #FFD700 !important; }

/* Fix navbar: il brand "OfferteInCittà" testo */
.site-navbar .navbar-brand span {
  color: #FFD700;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.3px;
}

/* Mobile bottom nav testo visibile */
.mobile-bottom-nav .nav-item span { 
  color: #aaa; 
  font-size: 10px; 
  display: block; 
}
.mobile-bottom-nav .nav-item.active span,
.mobile-bottom-nav .nav-item.active i { color: #FFD700 !important; }

/* Logo responsive già gestito nella sezione NAVBAR FIX in cima al file */

/* ============================================
   FLASH-BAR — Mobile Fix Completo
   ============================================ */

/* Stile base già definito sopra – questi sono gli override mobile specifici */

/* Su schermi piccoli: testo troncato, bottone compatto */
@media (max-width: 479px) {
  .flash-bar {
    min-height: 38px;
    padding: 5px 8px;
  }
  .flash-bar .badge {
    display: none; /* Nasconde badge "NUOVO" su schermi molto piccoli */
  }
  .flash-bar .flash-bar-text span:last-child {
    font-size: 11px;
  }
  .flash-bar .btn-warning {
    font-size: 11px;
    padding: 2px 8px;
  }
}

/* ============================================
   SPAZIO SOTTO LA NAVBAR — Layout Fix
   ============================================ */

/* Primo elemento dopo la navbar deve avere respiro */
.flash-bar + nav,
.flash-bar + .site-wrapper,
.flash-bar + div,
nav.site-navbar + .flash-bar {
  /* Nessun margin-top extra, il flash-bar è già padding */
}

/* Body: padding-top per compensare navbar sticky + flash-bar */
@media (max-width: 991px) {
  /* Assicura che il contenuto non finisca sotto la mobile bottom-nav */
  .site-wrapper, .layout-shell, main {
    padding-bottom: 80px;
  }
}

/* Il layout-shell deve partire SUBITO dopo navbar+flashbar su mobile */
@media (max-width: 991px) {
  .layout-shell > .sidebar-left {
    display: none; /* Le sidebar si nascondono su mobile */
  }
  .layout-shell > .content-main,
  .layout-shell > main {
    width: 100%;
    padding: 12px 12px 80px;
    overflow-x: hidden;
  }
}


/* ============================================
   MOBILE FILTER BAR — Barra cerca+filtri+vista
   Sticky sotto navbar, visibile solo su mobile
   ============================================ */
.mobile-filter-bar {
  background: #1a1a1a;
  border-bottom: 1px solid #333;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  width: 100%;
}
@media (min-width: 992px) {
  .mobile-filter-bar { display: none !important; }
}
.mobile-filter-bar .oic-input {
  background: #2a2a2a !important;
  color: #fff !important;
  border: none !important;
  font-size: 13px;
}
.mobile-filter-bar .oic-input::placeholder { color: #888; }
.mobile-filter-bar .oic-input:focus { 
  background: #333 !important;
  box-shadow: 0 0 0 2px rgba(255,215,0,0.25) !important;
}
.mobile-filter-bar .input-group-text.oic-input {
  background: #2a2a2a !important;
  border-right: 1px solid #333 !important;
}
.mobile-filter-bar .form-select.oic-input {
  background-color: #2a2a2a !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23FFD700' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
}
.mobile-filter-bar .view-switcher {
  display: flex;
  gap: 2px;
}

/* ============================================
   MOBILE BOTTOM NAV — 5 voci uniformi
   ============================================ */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1040;
  background: #111111;
  border-top: 2px solid #FFD700;
  padding: 6px 0 4px;
  justify-content: space-around;
  align-items: center;
}
@media (max-width: 991px) {
  .mobile-bottom-nav {
    display: flex;
  }
}
.mobile-bottom-nav a {
  color: #888;
  font-size: 10px;
  text-align: center;
  text-decoration: none;
  padding: 2px 8px;
  border-radius: 8px;
  transition: color 0.2s;
  flex: 1;
  min-width: 0;
}
.mobile-bottom-nav a i {
  font-size: 20px;
  display: block;
  margin-bottom: 2px;
}
.mobile-bottom-nav a.active,
.mobile-bottom-nav a:hover {
  color: #FFD700;
}

/* Spazio per non far finire il contenuto sotto il bottom-nav */
@media (max-width: 991px) {
  body { padding-bottom: 70px; }
}

/* ── Home filter select (Città / Categoria) ── */
.home-filter-select {
  background: #1e1e1e !important;
  color: #fff !important;
  border: 1px solid #444 !important;
  border-radius: 20px !important;
  font-size: 13px;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23FFD700' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 12px;
  padding-right: 28px !important;
  cursor: pointer;
}
.home-filter-select:focus {
  border-color: #FFD700 !important;
  box-shadow: 0 0 0 2px rgba(255,215,0,0.2) !important;
  outline: none;
}
.home-filter-select option {
  background: #1e1e1e;
  color: #fff;
}

/* ── Section title box (Offerte in Evidenza) ── */
.section-title-box {
  background: #1a1a1a;
  border: 1px solid #FFD700;
  border-radius: 8px;
  padding: 8px 14px;
  display: inline-flex;
  align-items: center;
  width: 100%;
  margin-bottom: 6px;
}
.section-title-box h5 {
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}

/* ── Padding bottom per evitare overlap bottom nav ──────────── */
@media (max-width: 991px) {
  .main-content,
  .site-body > main,
  body > main,
  .layout-shell .main-content {
    padding-bottom: 80px !important;
  }
  .flash-bar {
    display: flex !important;
  }
}

/* ── Banner Volantini Mobile ─────────────────────────────────── */
.volantini-banner-mobile {
  display: flex;
  align-items: center;
  gap: 14px;
  background: linear-gradient(135deg, #1a1a1a 0%, #2a1f00 100%);
  border: 1.5px solid #FFD700;
  border-radius: 14px;
  padding: 18px 16px;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  width: 100%;
  box-shadow: 0 4px 16px rgba(255,215,0,0.12);
}
.volantini-banner-mobile:hover,
.volantini-banner-mobile:active {
  transform: scale(0.98);
  box-shadow: 0 2px 10px rgba(255,215,0,0.22);
  border-color: #ffe566;
}
.volantini-banner-mobile__icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  background: #FFD700;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: #111;
}
.volantini-banner-mobile__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.volantini-banner-mobile__title {
  font-size: 16px;
  font-weight: 700;
  color: #FFD700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.volantini-banner-mobile__sub {
  font-size: 12px;
  color: #aaa;
  line-height: 1.3;
}
.volantini-banner-mobile__arrow {
  flex-shrink: 0;
  font-size: 20px;
  color: #FFD700;
}

/* ── Bottom Nav Fisso (globale) ──────────────────────────────── */
.mobile-bottom-nav.d-xl-none {
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 1050 !important;
  background: #111111 !important;
  border-top: 2px solid #FFD700 !important;
  display: flex !important;
  justify-content: space-around !important;
  align-items: stretch !important;
  padding: 4px 0 !important;
}
.bn-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 10px;
  font-weight: 600;
  padding: 4px 10px;
  gap: 2px;
  flex: 1;
  transition: color 0.15s;
}
.bn-item i {
  font-size: 1.25rem;
  line-height: 1;
}
.bn-item span {
  line-height: 1;
  white-space: nowrap;
}
@media (max-width: 991px) {
  body {
    padding-bottom: 68px !important;
  }
}

/* Store card in griglia — stesso stile card-offerta */
.store-card-grid {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 12px;
  transition: border-color 0.2s, transform 0.2s;
  overflow: hidden;
}
.store-card-grid:hover {
  border-color: #FFD700;
  transform: translateY(-2px);
}

/* ═══════════════════════════════════════════════════════
   FOOTER — regole consolidate (uniformate alla home)
   ═══════════════════════════════════════════════════════ */
footer {
  background: #0d0d0d;
  border-top: 1px solid #222;
  padding: 28px 14px 20px;
  margin-top: 20px;
}
.footer-inner {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

/* ── Logo centrato ── */
.footer-logo {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  gap: 10px;
  margin-bottom: 10px;
}
.footer-logo img {
  height: 52px !important;
  width: auto;
  display: inline-block;
  filter: brightness(1.1);
}

/* ── Descrizione ── */
.footer-desc {
  font-size: 12px;
  color: #aaa;
  line-height: 1.6;
  margin-bottom: 16px;
  text-align: center;
}

/* ── Social buttons ── */
.footer-social {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer-social a {
  border: 1px solid #333;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: border-color 0.2s;
}
.footer-social a:hover { border-color: #FFD700; }

/* ── Colonne footer ── */
.footer-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px 12px;
  margin-bottom: 20px;
  text-align: left;
}
.footer-col h6 {
  color: #FFD700 !important;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-col ul li { margin-bottom: 7px; }
.footer-col ul li a {
  color: #ccc;
  font-size: 12px;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: color 0.15s;
}
.footer-col ul li a:hover { color: #FFD700; }

/* ── Barra in fondo ── */
.footer-bottom {
  border-top: 1px solid #222;
  padding-top: 14px;
  font-size: 11px;
  color: #555;
  text-align: center;
  max-width: 1400px;
  margin: 0 auto;
}
.footer-bottom a {
  color: #555;
  text-decoration: none;
  margin: 0 6px;
}
.footer-bottom a:hover { color: #FFD700; }

/* ── Desktop: 4 colonne ── */
@media (min-width: 768px) {
  .footer-cols {
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
  }
  footer {
    padding: 40px 0 0;
  }
  .footer-col h6 { font-size: 13px; text-align: center; }
  .footer-col ul li a { font-size: 13px; justify-content: center; }
  .footer-logo img { height: 60px !important; }
  .footer-desc { font-size: 13px; }
  .footer-social { margin-bottom: 32px; }
}
/* ═══════════════════════════════════════════════════════ */
