/*
 * @file: console.css
 * @description: Stili specifici per la pagina del Console Onorario con layout tabella articoli ottimizzato
 * @author: Altoprofilo Studio
 * @last-updated: 2025-05-23
 * @version: V.1.1
 */

/* ==========================================================================
   VIDEO CONTAINER
   ========================================================================== */
.video-container {
  margin: 2rem 0;
  text-align: center;
}

.video-wrapper {
  position: relative;
  display: inline-block;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.video-wrapper video {
  width: 100%;
  height: auto;
  display: block;
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-normal);
}

.video-overlay:hover {
  background: rgba(0, 0, 0, 0.5);
}

.play-button {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-normal);
}

.play-button:hover {
  background: white;
  transform: scale(1.1);
}

.play-button i {
  width: 32px !important;
  height: 32px !important;
  color: var(--primary-color) !important;
  stroke: var(--primary-color) !important;
  margin-left: 4px; /* Compensazione visiva per icona play */
  margin-bottom: 0;
}

.video-caption {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ==========================================================================
   SECTION TITLES
   ========================================================================== */
.section-title {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  position: relative;
}

.section-title::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: var(--primary-color);
  margin: 1rem auto 0;
}

.section-intro {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  line-height: 1.7;
}

/* ==========================================================================
   CONTENT BOXES
   ========================================================================== */
.content-box {
  background: white;
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition-normal);
  border-top: 3px solid var(--primary-color);
  padding: 2rem; /* Aggiunto padding interno più generoso */
}

.content-box:hover {
  box-shadow: var(--shadow-md);
  transform: var(--hover-lift-small);
}

.content-box h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.content-box p {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.content-box p:last-child {
  margin-bottom: 0;
}

/* ==========================================================================
   INFO LIST
   ========================================================================== */
.info-list h4 {
  color: var(--primary-color);
  font-size: 1rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.info-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.info-list li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

.info-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
}

/* ==========================================================================
   COMPARISON TABLE
   ========================================================================== */
.comparison-table {
  margin: 2rem 0;
  background: white;
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.comparison-table h3 {
  background: var(--bg-light);
  color: var(--primary-color);
  padding: 1.5rem;
  margin: 0;
  font-size: 1.25rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.table-container {
  padding: 1.5rem;
}

.table-responsive {
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
}

.table th,
.table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  vertical-align: top;
}

.table thead th {
  background: var(--bg-light);
  font-weight: 600;
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
}

.table tbody td:first-child {
  font-weight: 500;
  color: var(--primary-color);
  background: rgba(0, 51, 102, 0.02);
}

.table tbody tr:hover {
  background: rgba(0, 51, 102, 0.03);
}

/* ==========================================================================
   ARTICLES TABLE - PERFECT ALIGNMENT (NEW)
   Layout ottimizzato per lista articoli Convenzione di Vienna
   ========================================================================== */
.articles-table {
  margin: 1.5rem 0;
  background: rgba(0, 51, 102, 0.02);
  border-radius: 8px;
  padding: 1.5rem;
  border-left: 4px solid var(--primary-color);
}

.article-item {
  align-items: flex-start;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  min-height: 50px;
}

.article-item:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

/* Colonna numero articolo - larghezza fissa */
.article-number-col {
  min-width: 200px;
  max-width: 200px;
  flex-shrink: 0;
  margin-right: 1.5rem;
}

/* Colonna testo - larghezza flessibile */
.article-text-col {
  flex: 1;
  line-height: 1.6;
  padding-top: 0.125rem; /* Allineamento visivo */
}

/* Stile numero articolo */
.article-number {
  display: inline-block;
  font-weight: 600;
  color: var(--primary-color);
  background: white;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  border: 1px solid rgba(0, 51, 102, 0.1);
  font-size: 0.9rem;
  width: 100%;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: var(--transition-fast);
}

.article-number:hover {
  background: rgba(0, 51, 102, 0.05);
  transform: var(--hover-lift-small);
}

/* ==========================================================================
   TIMELINE
   ========================================================================== */
.timeline {
  position: relative;
  margin: 2rem 0;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 150px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
}

.timeline-item {
  position: relative;
  margin-bottom: 3rem;
  display: flex;
  align-items: flex-start;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-date {
  min-width: 140px;
  max-width: 140px;
  text-align: right;
  padding-right: 2rem;
  flex-shrink: 0;
}

.timeline-date span {
  display: inline-block;
  background: var(--primary-color);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  position: relative;
  z-index: 2;
}

.timeline-content {
  flex: 1;
  background: white;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  margin-left: 2rem;
  position: relative;
  transition: var(--transition-normal);
}

.timeline-content:hover {
  box-shadow: var(--shadow-md);
  transform: var(--hover-lift-small);
}

.timeline-content::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 30px;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 10px 10px 10px 0;
  border-color: transparent white transparent transparent;
}

.timeline-content h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.2rem;
}

.timeline-content p {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.timeline-content p:last-child {
  margin-bottom: 0;
}

.timeline-content blockquote {
  background: var(--bg-light);
  padding: 1.5rem;
  border-left: 4px solid var(--accent-color);
  margin: 1.5rem 0;
  border-radius: 0 8px 8px 0;
}

.timeline-content blockquote p {
  font-style: italic;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.timeline-content cite {
  display: block;
  text-align: right;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-style: normal;
}

/* ==========================================================================
   FUNCTION CARDS
   ========================================================================== */
.function-card {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-normal);
  text-align: center;
  border-top: 3px solid var(--primary-color);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.function-card:hover {
  box-shadow: var(--shadow-md);
  transform: var(--hover-lift-small);
}

.function-icon {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  transition: var(--transition-normal);
}

.function-card:hover .function-icon {
  transform: scale(1.1);
}

.function-icon i {
  width: 32px !important;
  height: 32px !important;
  color: white !important;
  stroke: white !important;
  fill: none !important;
  margin: 0;
}

/* Regola specifica aggiuntiva per assicurare icone bianche */
.function-icon svg,
.function-icon svg path {
  color: white !important;
  stroke: white !important;
  fill: none !important;
}

.function-content {
  flex: 1;
}

.function-content h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.function-content p,
.function-content ul {
  text-align: left;
  line-height: 1.6;
}

.function-content ul {
  margin-top: 1rem;
  padding-left: 1.5rem;
}

.function-content li {
  margin-bottom: 0.5rem;
}

/* ==========================================================================
   PROCESS CONTAINER
   ========================================================================== */
.process-container {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

/* Aggiunto padding specifico per content-body nella sezione Convenzione */
#convenzione .content-body {
  padding: 2rem;
}

.process-intro {
  text-align: center;
  margin-bottom: 2rem;
}

.process-intro p {
  font-size: 1.1rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.process-steps {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.process-step {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  padding: 1.5rem;
  background: var(--bg-light);
  border-radius: 12px;
  border-left: 4px solid var(--primary-color);
}

.step-number {
  min-width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--primary-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 600;
  flex-shrink: 0;
}

.step-content {
  flex: 1;
}

.step-content h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.2rem;
}

.step-content p {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.step-content ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

.step-content li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

/* ==========================================================================
   FAQ SECTION - VERSIONE MIGLIORATA
   Design moderno con card separate e animazioni fluide
   ========================================================================== */

.faq-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.faq-item {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  border: 1px solid rgba(0, 51, 102, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-bottom: none; /* Rimuove il vecchio border-bottom */
}

.faq-item:hover {
  box-shadow: 0 4px 16px rgba(0, 51, 102, 0.12);
  transform: translateY(-2px);
}

.faq-item.active {
  box-shadow: 0 4px 20px rgba(0, 51, 102, 0.15);
  border-color: var(--primary-color);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.75rem 1.5rem;
  background: white;
  cursor: pointer;
  transition: all 0.25s ease;
  outline: none;
  position: relative;
  gap: 1rem;
}

/* Contatore FAQ */
.faq-question::before {
  content: attr(data-faq-number);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  flex-shrink: 0;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 51, 102, 0.2);
}

.faq-question:hover {
  background: linear-gradient(to right, rgba(0, 51, 102, 0.02), transparent);
}

.faq-question:hover::before {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 4px 12px rgba(0, 51, 102, 0.3);
}

.faq-question:focus {
  background: rgba(0, 51, 102, 0.03);
  outline: 2px solid var(--primary-color);
  outline-offset: -2px;
}

.faq-question h3 {
  color: var(--text-dark);
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  flex: 1;
  padding-right: 1rem;
  transition: color 0.25s ease;
  line-height: 1.4;
}

.faq-question:hover h3 {
  color: var(--primary-color);
}

.faq-question[aria-expanded="true"] h3 {
  color: var(--primary-color);
}

/* Icona espandi/collassa */
.faq-icon-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  background: rgba(0, 51, 102, 0.06);
  border-radius: 50%;
  flex-shrink: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-question:hover .faq-icon-wrapper {
  background: rgba(0, 51, 102, 0.1);
}

.faq-question i {
  width: 20px !important;
  height: 20px !important;
  color: var(--primary-color) !important;
  stroke: var(--primary-color) !important;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
  margin: 0;
}

.faq-question[aria-expanded="true"] .faq-icon-wrapper {
  background: var(--primary-color);
  transform: rotate(180deg);
}

.faq-question[aria-expanded="true"] i {
  color: white !important;
  stroke: white !important;
}

/* Risposta FAQ */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  background: linear-gradient(to bottom, rgba(0, 51, 102, 0.01), transparent);
}

.faq-answer-content {
  padding: 0 1.5rem 2rem 1.5rem;
  border-top: 1px solid rgba(0, 51, 102, 0.06);
  margin-top: 0;
}

/* Spaziatura per allineare con il testo della domanda (dopo l'icona numerata) */
.faq-answer-content {
  padding-left: calc(1.5rem + 32px + 1rem); /* padding + larghezza icona + gap */
}

.faq-answer p {
  margin: 1.5rem 0 1rem 0;
  line-height: 1.7;
  color: var(--text-dark);
  font-size: 1rem;
}

.faq-answer p:first-child {
  margin-top: 1.5rem;
}

.faq-answer p:last-child {
  margin-bottom: 0;
}

.faq-answer ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
  list-style: none;
}

.faq-answer li {
  position: relative;
  margin-bottom: 0.75rem;
  line-height: 1.6;
  padding-left: 1.5rem;
  color: var(--text-dark);
}

.faq-answer li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
  font-size: 1.1rem;
}

.faq-answer strong {
  color: var(--primary-color);
  font-weight: 600;
}

/* Badge o highlight nel testo */
.faq-answer .highlight {
  background: rgba(0, 51, 102, 0.08);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-weight: 500;
  color: var(--primary-color);
}

/* ==========================================================================
   FIX: Chevron bianco quando FAQ aperta (variante lineare)
   ========================================================================== */

.faq--linear .faq-question[aria-expanded="true"] i,
.faq--linear .faq-question[aria-expanded="true"] svg {
  color: white !important;
  stroke: white !important;
}

.faq--linear .faq-question[aria-expanded="true"] .faq-icon-wrapper {
  background: var(--primary-color);
  border-radius: 50%;
}

/* ==========================================================================
   RESPONSIVE DESIGN - FAQ
   ========================================================================== */

@media (max-width: 768px) {
  .faq-container {
    gap: 0.75rem;
  }

  .faq-item {
    border-radius: 10px;
  }

  .faq-question {
    padding: 1.25rem 1rem;
    gap: 0.75rem;
  }

  .faq-question::before {
    min-width: 28px;
    height: 28px;
    font-size: 0.8rem;
    border-radius: 6px;
  }

  .faq-question h3 {
    font-size: 1rem;
    padding-right: 0.5rem;
  }

  .faq-icon-wrapper {
    min-width: 32px;
    height: 32px;
  }

  .faq-question i {
    width: 18px !important;
    height: 18px !important;
  }

  .faq-answer-content {
    padding: 0 1rem 1.5rem 1rem;
  }

  .faq-answer p {
    font-size: 0.95rem;
    margin: 1rem 0 0.75rem 0;
  }

  .faq-answer ul {
    padding-left: 1rem;
  }

  .faq-answer li {
    font-size: 0.95rem;
    padding-left: 1.25rem;
    margin-bottom: 0.5rem;
  }
}

@media (min-width: 769px) and (max-width: 992px) {
  .faq-question {
    padding: 1.5rem 1.25rem;
  }

  .faq-answer-content {
    padding-left: calc(1.25rem + 32px + 1rem);
  }
}

/* ==========================================================================
   ACCESSIBILITY MIGLIORATA
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .faq-item,
  .faq-question,
  .faq-question::before,
  .faq-icon-wrapper,
  .faq-question i,
  .faq-answer {
    transition: none;
  }

  .faq-item:hover {
    transform: none;
  }

  .faq-question:hover::before,
  .faq-question[aria-expanded="true"] .faq-icon-wrapper {
    transform: none;
  }
}

@media (prefers-contrast: high) {
  .faq-item {
    border: 2px solid var(--primary-color);
  }

  .faq-question::before {
    border: 2px solid white;
  }

  .faq-question:focus {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
  }
}

/* Focus visibile per navigazione da tastiera */
.faq-question:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 2px;
}

/* ==========================================================================
   PRINT
   ========================================================================== */

@media print {
  .faq-container {
    gap: 0.5rem;
  }

  .faq-item {
    box-shadow: none;
    border: 1px solid #ccc;
    break-inside: avoid;
  }

  .faq-question {
    padding: 1rem;
  }

  .faq-question::before {
    box-shadow: none;
  }

  .faq-icon-wrapper {
    display: none;
  }

  .faq-answer {
    max-height: none !important;
  }

  .faq-answer-content {
    padding: 1rem;
  }
}
/* ==========================================================================
   RESPONSIVE DESIGN
   ========================================================================== */

/* Mobile - Stack verticale */
@media (max-width: 768px) {

  /* Article table responsive */
  .article-item {
    flex-direction: column;
    align-items: stretch;
  }
  
  .article-number-col {
    min-width: 100%;
    max-width: 100%;
    margin-right: 0;
    margin-bottom: 0.75rem;
  }
  
  .article-number {
    display: inline-block;
    width: auto;
    max-width: 280px;
    text-align: left;
    padding: 0.4rem 0.6rem;
  }
  
  .article-text-col {
    padding-top: 0;
  }
  
  .articles-table {
    padding: 1rem;
  }

  /* Timeline responsive */
  .timeline::before {
    left: 25px;
  }

  .timeline-item {
    flex-direction: column;
    padding-left: 60px;
    position: relative;
  }

  .timeline-date {
    position: absolute;
    left: 0;
    top: 0;
    text-align: left;
    padding-right: 0;
  }

  .timeline-date span {
    font-size: 0.8rem;
    padding: 0.3rem 0.6rem;
  }

  .timeline-content {
    margin-left: 0;
    margin-top: 1rem;
  }

  .timeline-content::before {
    display: none;
  }

  /* Process steps */
  .process-step {
    flex-direction: column;
    text-align: center;
  }

  .step-number {
    margin: 0 auto 1rem;
  }

  /* Function cards */
  .function-card {
    margin-bottom: 1.5rem;
  }

  /* FAQ */
  .faq-question {
    padding: 1rem;
  }

  .faq-question h3 {
    font-size: 1rem;
  }

  .faq-answer div,
  .faq-answer p,
  .faq-answer ul {
    padding: 0 1rem 1rem;
  }

  .faq-answer ul {
    padding-left: 2rem;
  }

  /* Table responsive */
  .table-responsive {
    font-size: 0.9rem;
  }

  .table th,
  .table td {
    padding: 0.75rem 0.5rem;
  }

  /* Video */
  .video-wrapper {
    max-width: 100%;
  }

  .play-button {
    width: 60px;
    height: 60px;
  }

  .play-button i {
    width: 24px !important;
    height: 24px !important;
  }
}

/* Tablet - Layout intermedio */
@media (min-width: 769px) and (max-width: 992px) {
  .article-number-col {
    min-width: 180px;
    max-width: 180px;
    margin-right: 1rem;
  }
  
  .article-number {
    font-size: 0.85rem;
    padding: 0.4rem 0.6rem;
  }

  .timeline::before {
    left: 120px;
  }

  .timeline-date {
    min-width: 110px;
    max-width: 110px;
  }

  .timeline-content {
    margin-left: 1.5rem;
  }
}

/* ==========================================================================
   ACCESSIBILITY & PRINT
   ========================================================================== */

/* High contrast mode */
@media (prefers-contrast: high) {
  .article-number {
    border: 2px solid var(--primary-color);
    background: white;
  }
  
  .articles-table {
    border-left-width: 6px;
    background: white;
  }

  .function-card,
  .content-box,
  .timeline-content {
    border: 1px solid var(--primary-color);
  }

  .faq-question:focus {
    outline: 3px solid var(--primary-color);
  }
}

/* Print styles */
@media print {
  .articles-table {
    background: white;
    border-left: 3px solid #000;
    break-inside: avoid;
  }
  
  .article-item {
    break-inside: avoid;
    margin-bottom: 0.5rem;
  }
  
  .article-number {
    background: white;
    border: 1px solid #000;
    box-shadow: none;
  }

  .timeline-content,
  .function-card,
  .process-step {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ccc;
  }

  .video-container {
    display: none;
  }

  .quick-nav {
    display: none;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .article-number,
  .function-card,
  .content-box,
  .timeline-content,
  .process-step,
  .faq-question {
    transition: none;
  }
  
  .article-number:hover,
  .function-card:hover,
  .content-box:hover,
  .timeline-content:hover {
    transform: none;
  }

  .function-card:hover .function-icon {
    transform: none;
  }

  .faq-question[aria-expanded="true"] i {
    transform: none;
  }
}

/* ==========================================================================
   LEGACY SUPPORT - FALLBACK per old .article-list
   Mantiene compatibilità con vecchio codice
   ========================================================================== */

/* Se rimane ancora la vecchia lista, migliora almeno quella */
.key-points .article-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.key-points .article-list li {
  display: flex;
  align-items: flex-start;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  gap: 1rem;
}

.key-points .article-list li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.key-points .article-list .article-number {
  min-width: 160px;
  flex-shrink: 0;
  font-weight: 600;
  color: var(--primary-color);
  background: rgba(0, 51, 102, 0.05);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.9rem;
}

.key-points .article-list .article-number::after {
  content: "";
  display: none;
}

/* Mobile fallback per old list */
@media (max-width: 768px) {
  .key-points .article-list li {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .key-points .article-list .article-number {
    min-width: auto;
    align-self: flex-start;
  }
}

.faq-answer {
    padding-top: 40px;
}

/* ==========================================================================
   FAQ — Variante Lineare (UCOI)
   Look minimale, coerente con stile istituzionale
   ========================================================================== */

.faq--linear {
  background: transparent;
  box-shadow: none;
  padding: 0;
}

/* Struttura: ogni item è una riga con solo un sottile divisore */
.faq--linear .faq-item {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  transform: none;
  background: transparent;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}
.faq--linear .faq-item:hover,
.faq--linear .faq-item.active {
  box-shadow: none;
  border-color: rgba(0,0,0,0.12);
}

/* Domanda: testo nero, senza gradienti né box concavi/convessi */
.faq--linear .faq-question {
  background: transparent;
  padding: 1rem 0;
  gap: .75rem;
  outline: none;
}
.faq--linear .faq-question:hover { background: transparent; }
.faq--linear .faq-question:focus,
.faq--linear .faq-question:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* Titolo domanda: tipografia pulita */
.faq--linear .faq-question h3 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.35;
}
.faq--linear .faq-question[aria-expanded="true"] h3 {
  color: var(--text-dark);
}

/* Nasconde il contatore numerato se ancora presente nel markup */
.faq--linear .faq-question::before { display: none; }

/* Icona: solo chevron, niente pill rotonda colorata */
.faq--linear .faq-icon-wrapper {
  min-width: 24px;
  height: 24px;
  background: transparent;
  border-radius: 0;
  transition: transform .2s ease;
}
.faq--linear .faq-question i,
.faq--linear .faq-question svg {
  width: 18px !important;
  height: 18px !important;
  stroke: currentColor !important;
  color: var(--text-dark) !important;
}
.faq--linear .faq-question[aria-expanded="true"] .faq-icon-wrapper {
  transform: rotate(180deg);
}

/* Risposta: senza blocchi colorati/gradienti; spacing compatto e leggibile */
.faq--linear .faq-answer {
  background: transparent;
  max-height: 0;
  overflow: hidden;
  transition: max-height .25s ease;
}
.faq--linear .faq-answer-content {
  padding: .25rem 0 1rem 0;
  border-top: 0;
  margin: 0;
}
.faq--linear .faq-answer p,
.faq--linear .faq-answer li {
  color: var(--text-dark);
  line-height: 1.6;
  font-size: 1rem;
}

/* Elenco nella risposta: trattino minimale, niente frecce grandi */
.faq--linear .faq-answer ul {
  margin: .5rem 0 0 0;
  padding-left: 1.25rem;
  list-style: disc;
}
.faq--linear .faq-answer li {
  margin: .4rem 0;
  padding-left: 0;
}
.faq--linear .faq-answer li::before { content: none; }

/* Riduzione motion */
@media (prefers-reduced-motion: reduce) {
  .faq--linear .faq-answer { transition: none; }
  .faq--linear .faq-icon-wrapper { transition: none; }
}

/* Mobile: stessi principi, solo padding leggermente più stretto */
@media (max-width: 768px) {
  .faq--linear .faq-question { padding: .85rem 0; }
  .faq--linear .faq-answer-content { padding: .25rem 0 .85rem 0; }
}

