/* Swapass — foglio di stile base. Design token da CLAUDE.md / Component Library.dc.html.
   Copiare qui, non reinventare, ogni nuovo componente man mano che le pagine vengono
   implementate: e' l'unica fonte di stile condivisa tra Web e Admin. */

:root {
  --primary: #1565FF;
  --primary-hover: #0F4FD1;
  --secondary: #00C7B3;
  --text-dark: #111111;
  --text-muted: #687280;
  --surface: #F2F4F7;
  --border: #E4E7EC;
  --white: #FFFFFF;
  --success: #16A34A;
  --success-bg: #EAF7EE;
  --warning: #D97706;
  --warning-bg: #FEF6E7;
  --error: #DC2626;
  --error-bg: #FDECEC;
  --info-bg: #EAF1FF;
  --input-border: #D0D5DD;
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --shadow-card: 0 4px 14px rgba(17, 17, 17, 0.05);
  --shadow-modal: 0 8px 24px rgba(17, 17, 17, 0.08);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--white);
  color: var(--text-dark);
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  line-height: 1.55;
}

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

h1 { font-size: 32px; line-height: 40px; font-weight: 600; margin: 0; }
h2 { font-size: 24px; line-height: 32px; font-weight: 600; margin: 0; }
h3 { font-size: 18px; line-height: 28px; font-weight: 500; margin: 0; }

.container { max-width: 1180px; margin: 0 auto; padding: 0 56px; }

/* Navbar */
.navbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 56px; border-bottom: 1px solid var(--border); height: 64px; box-sizing: border-box;
}
.navbar .brand { display: flex; align-items: center; gap: 10px; }
.navbar .brand .mark {
  width: 36px; height: 36px; border-radius: var(--radius-md); border: 2px solid var(--primary);
  display: flex; align-items: center; justify-content: center; color: var(--primary);
}
.navbar .brand .wordmark { font-size: 18px; font-weight: 700; }
.navbar .brand .wordmark .swa { color: var(--primary); }
.navbar .brand .wordmark .pass { color: var(--secondary); }
.navbar .links { display: flex; gap: 28px; font-size: 14px; font-weight: 500; }
.navbar .links a { color: var(--text-dark); text-decoration: none; }
.navbar .links a:hover { color: var(--primary); }
.navbar .actions { display: flex; gap: 12px; align-items: center; }

/* Bottoni (Sezione componenti — CLAUDE.md) */
.btn {
  font-family: 'Poppins', sans-serif; font-size: 13px; font-weight: 600;
  border-radius: var(--radius-md); padding: 12px 22px; cursor: pointer; border: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px;
}
.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-hover); }
.btn-secondary { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-secondary:hover { background: var(--info-bg); }
.btn-ghost { background: transparent; color: var(--primary); border: none; }
.btn-ghost:hover { background: var(--surface); }
.btn-gradient { background: linear-gradient(90deg, #1565FF, #00C7B3); color: var(--white); }
.btn-disabled, .btn:disabled { background: var(--surface); color: #98A2B3; cursor: not-allowed; }

/* Hero */
.hero {
  padding: 64px 56px 48px; background: linear-gradient(180deg, #F7FAFF 0%, #FFFFFF 100%);
}
.hero .titolo { font-size: 44px; font-weight: 700; line-height: 1.15; }
.hero .titolo .accento { color: var(--primary); }
.hero .sottotitolo { font-size: 16px; color: var(--text-muted); margin-top: 16px; max-width: 480px; }
.hero .cta-row { display: flex; gap: 16px; margin-top: 32px; flex-wrap: wrap; }

/* Card generica */
.card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 16px;
}
.card:hover { box-shadow: var(--shadow-card); }

/* Footer */
.footer { border-top: 1px solid var(--border); padding: 40px 56px; color: var(--text-muted); font-size: 13px; }

/* Pagine legali (Sezione 4 elenco schermate) — template unico: titolo, ultimo
   aggiornamento, indice laterale ancorato, corpo testo max-width 720px, 16/28. */
.legal-layout { display: flex; gap: 48px; max-width: 1180px; margin: 0 auto; padding: 48px 56px 96px; align-items: flex-start; }
.legal-sidebar { width: 240px; flex-shrink: 0; position: sticky; top: 24px; }
.legal-sidebar nav { display: flex; flex-direction: column; gap: 2px; }
.legal-sidebar a { display: block; padding: 8px 12px; border-radius: 8px; font-size: 13px; color: var(--text-muted); line-height: 1.4; }
.legal-sidebar a:hover { background: var(--surface); color: var(--text-dark); }
.legal-content { max-width: 720px; font-size: 16px; line-height: 28px; }
.legal-content h1 { margin-bottom: 8px; }
.legal-updated { color: var(--text-muted); font-size: 13px; margin-bottom: 32px; }
.legal-content section { margin-bottom: 32px; scroll-margin-top: 24px; }
.legal-content h2 { font-size: 18px; line-height: 28px; font-weight: 500; margin-bottom: 12px; scroll-margin-top: 24px; }
.legal-content p { margin: 0 0 14px; }
.legal-content ul { margin: 0 0 14px; padding-left: 22px; }
.legal-content li { margin-bottom: 6px; }
.legal-callout { background: var(--info-bg); border-radius: 10px; padding: 16px; font-size: 15px; margin: 16px 0; }
.legal-callout.legal-callout-warn { background: var(--warning-bg); }
@media (max-width: 900px) {
  .legal-layout { flex-direction: column; padding: 32px 20px 64px; gap: 24px; }
  .legal-sidebar { position: static; width: 100%; }
}

.footer-top {
  border-top: 1px solid var(--border); padding: 48px 56px 24px;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr 1fr 1.2fr; gap: 24px;
}
.footer-brand .wordmark { font-size: 16px; font-weight: 700; }
.footer-brand .wordmark .swa { color: var(--primary); }
.footer-brand .wordmark .pass { color: var(--secondary); }
.footer-brand .claim { font-size: 12px; color: var(--text-muted); margin-top: 6px; }
.footer-col { font-size: 13px; color: var(--text-muted); display: flex; flex-direction: column; gap: 8px; }
.footer-col-title { font-weight: 700; color: var(--text-dark); margin-bottom: 4px; }
.footer-col a { color: var(--text-muted); }
.footer-col a:hover { color: var(--primary); }
.footer-help { background: var(--surface); border-radius: var(--radius-lg); padding: 16px; font-size: 13px; }
.footer-help .link { color: var(--primary); font-weight: 600; margin-top: 8px; display: inline-block; }
.footer-bottom { text-align: center; font-size: 12px; color: #98A2B3; padding: 20px 0; border-top: 1px solid var(--border); }

/* Sezioni pagine informative */
.section { padding: 56px; }
.section-narrow { max-width: 720px; margin: 0 auto; }
.section-title { font-size: 24px; font-weight: 600; margin-bottom: 12px; }
.section-lead { color: var(--text-muted); font-size: 15px; margin-bottom: 40px; max-width: 640px; }
.page-hero { padding: 48px 56px 32px; background: linear-gradient(180deg, #F7FAFF 0%, #FFFFFF 100%); }
.page-hero h1 { max-width: 640px; }
.page-hero .sottotitolo { font-size: 15px; color: var(--text-muted); margin-top: 12px; max-width: 560px; }

/* Come funziona: 4 step */
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.step-card { text-align: center; }
.step-num {
  width: 52px; height: 52px; border-radius: var(--radius-lg); background: var(--info-bg); color: var(--primary);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 12px; font-weight: 700;
}
.step-card h3 { font-size: 14px; font-weight: 600; }
.step-card p { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

/* Card benefici / trust point */
.benefits-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.benefit-card { border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; }
.benefit-card .icon { color: var(--primary); margin-bottom: 10px; }
.benefit-card h3 { font-size: 15px; font-weight: 600; }
.benefit-card p { font-size: 13px; color: var(--text-muted); margin-top: 6px; }

/* FAQ accordion (details/summary nativo) */
.faq-list { display: flex; flex-direction: column; gap: 12px; max-width: 760px; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 4px 18px; }
.faq-item summary {
  font-size: 14px; font-weight: 500; padding: 14px 0; cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '⌄'; color: var(--text-muted); font-size: 16px; flex-shrink: 0; }
.faq-item[open] summary::after { content: '⌃'; }
.faq-item .faq-answer { font-size: 13px; color: var(--text-muted); padding: 0 0 16px; line-height: 1.6; }

/* Categorie: griglia card */
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.cat-card {
  display: flex; align-items: center; gap: 14px; border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 18px; background: var(--white);
}
.cat-card:hover { box-shadow: var(--shadow-card); border-color: var(--primary); }
.cat-card .icon {
  width: 44px; height: 44px; border-radius: var(--radius-md); background: var(--info-bg); color: var(--primary);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.cat-card .nome { font-size: 15px; font-weight: 600; color: var(--text-dark); }
.cat-card .desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

/* Stato vuoto */
.empty-state { text-align: center; padding: 56px 20px; color: var(--text-muted); }
.empty-state .icon { color: #98A2B3; margin-bottom: 12px; }
.empty-state h3 { font-size: 16px; color: var(--text-dark); }
.empty-state p { font-size: 13px; margin-top: 6px; }

/* Card risultato biglietto (liste categoria/ricerca) */
.ticket-row {
  display: flex; align-items: center; gap: 16px; border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 14px 16px; background: var(--white);
}
.ticket-row:hover { box-shadow: var(--shadow-card); }
.ticket-row .thumb {
  width: 56px; height: 56px; border-radius: var(--radius-sm); background: var(--surface); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; color: #98A2B3;
}
.ticket-row .info { flex: 1; min-width: 0; }
.ticket-row .titolo { font-size: 14px; font-weight: 600; color: var(--text-dark); }
.ticket-row .meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.ticket-row .prezzo { font-size: 16px; font-weight: 700; color: var(--text-dark); white-space: nowrap; }

/* Form di contatto placeholder */
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field label { font-size: 12px; font-weight: 500; }
.form-field .input-control {
  width: 100%; border: 1px solid var(--input-border); border-radius: var(--radius-md);
  padding: 11px 14px; font-family: 'Poppins', sans-serif; font-size: 14px; box-sizing: border-box;
}
.alert-success {
  background: var(--success-bg); color: var(--success); border-radius: var(--radius-md);
  padding: 12px 14px; font-size: 13px; display: flex; align-items: center; gap: 8px;
}

@media (max-width: 992px) {
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .benefits-grid { grid-template-columns: 1fr; }
}

/* Mobile: sotto 768px, navbar orizzontale collassa (Sezione convenzioni codice) */
@media (max-width: 768px) {
  .navbar { padding: 12px 20px; flex-wrap: wrap; row-gap: 8px; }
  .navbar .links { display: none; }
  .hero { padding: 40px 20px; }
  .hero .titolo { font-size: 32px; }
  .container { padding: 0 20px; }
  .section, .page-hero, .footer-top { padding-left: 20px; padding-right: 20px; }
  .steps-grid, .cat-grid { grid-template-columns: 1fr 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .ticket-row { flex-wrap: wrap; }
}
