/* Home blog TrovoVenditori — card articoli v3 */
.tv-articles-section {
  margin-bottom: 3rem;
}

.tv-articles-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 1.75rem;
}

/* —— Articolo in evidenza —— */
.tv-featured-wrap {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.1);
  margin-bottom: 3rem;
}

.tv-featured-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  min-height: 380px;
}

.tv-featured-media {
  position: relative;
  min-height: 280px;
  background: linear-gradient(145deg, #071b3a 0%, #0d6efd 100%);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4.5rem;
}

.tv-featured-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(7, 27, 58, 0.15) 0%, rgba(7, 27, 58, 0.55) 100%);
}

.tv-featured-ribbon {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 2;
  background: #ff6b00;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 8px 14px;
  border-radius: 8px;
  box-shadow: 0 6px 16px rgba(255, 107, 0, 0.35);
}

.tv-featured-content {
  padding: 36px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.tv-featured-cat {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 14px;
}

.tv-featured-title {
  font-size: clamp(1.45rem, 2.5vw, 2rem);
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -0.5px;
  color: #0f172a;
  margin-bottom: 14px;
}

.tv-featured-excerpt {
  color: #64748b;
  font-size: 1.02rem;
  line-height: 1.65;
  margin-bottom: 22px;
}

.tv-featured-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #94a3b8;
  margin-bottom: 24px;
}

.tv-featured-meta span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.tv-featured-btn {
  align-self: flex-start;
  background: linear-gradient(135deg, #071b3a, #0d6efd);
  color: #fff !important;
  font-weight: 800;
  padding: 14px 26px;
  border-radius: 12px;
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(13, 110, 253, 0.3);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.tv-featured-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(13, 110, 253, 0.4);
  color: #fff;
}

/* —— Griglia articoli —— */
.tv-art-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.tv-art-card {
  position: relative;
  background: #fff;
  border: 1px solid #e8edf3;
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 18px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.tv-art-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--art-accent, #0d6efd);
  z-index: 3;
}

.tv-art-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.14);
}

.tv-art-thumb {
  position: relative;
  height: 196px;
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.8rem;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
}

.tv-art-thumb-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(7, 27, 58, 0.5) 100%);
  pointer-events: none;
}

.tv-art-cat-badge {
  position: absolute;
  bottom: 14px;
  left: 14px;
  right: 14px;
  z-index: 2;
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.2px;
  padding: 4px 9px;
  border-radius: 7px;
  text-transform: none;
  line-height: 1.25;
  max-width: calc(100% - 28px);
  white-space: normal;
  word-break: break-word;
  text-align: left;
}

.tv-art-body {
  padding: 22px 24px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.tv-art-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.78rem;
  font-weight: 600;
  color: #94a3b8;
  margin-bottom: 12px;
}

.tv-art-meta-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #cbd5e1;
}

.tv-art-title {
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -0.25px;
  color: #0f172a;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tv-art-card:hover .tv-art-title {
  color: #0d4ea6;
}

.tv-art-excerpt {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.tv-art-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.tv-art-cat-tag {
  font-size: 0.4rem;
  font-weight: 700;
  line-height: 1.25;
  padding: 3px 7px;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  transition: filter 0.15s ease;
  white-space: normal;
  word-break: break-word;
  text-align: center;
  max-width: 100%;
}

.tv-art-cat-tag:hover {
  filter: brightness(0.96);
}

.tv-art-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
  margin-top: auto;
}

.tv-art-author {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #94a3b8;
  min-width: 0;
}

.tv-art-author-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tv-art-avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #071b3a, #0d6efd);
  color: #fff;
  font-size: 0.56rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tv-art-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  font-weight: 800;
  color: #fff;
  background: var(--art-accent, #0d6efd);
  padding: 9px 16px;
  border-radius: 10px;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.12);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.tv-art-btn:hover {
  color: #fff;
  filter: brightness(0.95);
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.18);
}

.tv-art-btn i {
  transition: transform 0.2s ease;
}

.tv-art-card:hover .tv-art-btn i {
  transform: translateX(4px);
}

/* —— Carosello orizzontale altri articoli —— */
.tv-art-scroll-section {
  margin-bottom: 3rem;
}

.tv-art-scroll-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.tv-art-scroll-btn {
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #071b3a, #0d6efd);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(13, 110, 253, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
  flex-shrink: 0;
  padding: 0;
}

.tv-art-scroll-btn__icon {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
  margin-top: -2px;
}

.tv-art-scroll-btn--side {
  width: 52px;
  height: 52px;
}

.tv-art-scroll-btn:hover {
  color: #fff;
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(13, 110, 253, 0.42);
}

.tv-art-scroll-btn:active {
  transform: translateY(0);
}

.tv-art-scroll-btn:disabled {
  opacity: 0.35;
  cursor: default;
  transform: none;
  box-shadow: none;
}

.tv-art-scroll-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding: 8px 4px 16px;
  scrollbar-width: thin;
  scrollbar-color: #94a3b8 #e2e8f0;
}

.tv-art-scroll-wrap::-webkit-scrollbar {
  height: 10px;
}

.tv-art-scroll-wrap::-webkit-scrollbar-track {
  background: #e2e8f0;
  border-radius: 999px;
}

.tv-art-scroll-wrap::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 999px;
}

.tv-art-scroll-track {
  display: flex;
  gap: 24px;
  padding: 4px 8px 8px;
}

.tv-art-card--scroll {
  flex: 0 0 320px;
  scroll-snap-align: start;
  max-width: 320px;
}

.tv-art-card--scroll .tv-art-thumb {
  height: 168px;
}

/* —— Chip categorie e settori scorrevoli —— */
.tv-chip-scroll-section,
.tv-sector-scroll-section {
  margin-bottom: 2rem;
}

.tv-chip-scroll-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tv-chip-scroll-wrap {
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding: 4px 2px 8px;
  scrollbar-width: thin;
  scrollbar-color: #94a3b8 #e2e8f0;
}

.tv-chip-scroll-wrap::-webkit-scrollbar {
  height: 8px;
}

.tv-chip-scroll-wrap::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 999px;
}

.tv-chip-scroll-track {
  display: flex;
  gap: 8px;
  width: max-content;
  min-width: 100%;
}

.tv-chip-scroll-track--categories .tv-category-chip--compact {
  flex: 0 0 124px;
  width: 124px;
  max-width: 124px;
  min-height: 44px;
  scroll-snap-align: start;
}

.tv-category-chip--compact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 7px 8px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #e5e7eb;
  color: #111827;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.68rem;
  line-height: 1.2;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
  white-space: normal;
  overflow: visible;
  text-align: center;
  word-break: break-word;
  height: 100%;
}

.tv-category-chip--compact:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.1);
}

.tv-sector-chip {
  flex: 0 0 132px;
  max-width: 132px;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 8px 6px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #dbe3ef;
  color: #0f172a;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.64rem;
  line-height: 1.25;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.05);
  scroll-snap-align: start;
  overflow: hidden;
}

.tv-sector-chip:hover {
  color: #0d4ea6;
  border-color: #bfdbfe;
  transform: translateY(-1px);
}

.tv-sector-scroll-note {
  margin: 10px 0 0;
  text-align: right;
}

.tv-art-scroll-btn--chip {
  width: 40px;
  height: 40px;
}

.tv-art-scroll-btn--chip .tv-art-scroll-btn__icon {
  font-size: 1.6rem;
}

@media (min-width: 1200px) {
  .tv-chip-scroll-track--categories .tv-category-chip--compact {
    flex-basis: 124px;
    width: 124px;
    max-width: 124px;
  }
}

@media (max-width: 992px) {
  .tv-art-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .tv-featured-inner {
    grid-template-columns: 1fr;
  }

  .tv-featured-media {
    min-height: 220px;
  }

  .tv-featured-content {
    padding: 28px 24px;
  }
}

@media (max-width: 576px) {
  .tv-art-grid {
    grid-template-columns: 1fr;
  }

  .tv-art-scroll-row {
    gap: 8px;
  }

  .tv-art-scroll-btn--side {
    width: 44px;
    height: 44px;
  }

  .tv-art-scroll-btn__icon {
    font-size: 1.7rem;
  }

  .tv-art-card--scroll {
    flex-basis: 82vw;
    max-width: 82vw;
  }

  .tv-chip-scroll-track--categories .tv-category-chip--compact {
    flex-basis: 108px;
    width: 108px;
    max-width: 108px;
    min-height: 42px;
    font-size: 0.64rem;
  }

  .tv-sector-chip {
    flex-basis: 108px;
    max-width: 108px;
    min-height: 50px;
    font-size: 0.6rem;
  }
}
