/* ═══════════════════════════════════════════════════════════════
   SFP-Europa — Stili pagine principali (style-v3.css)
   Componenti di contenuto: quick-links, content-layout, cards,
   team, tables, forms inline, homepage hero, homepage services.
   Richiede style.css caricato prima.
   ═══════════════════════════════════════════════════════════════ */

/* ── QUICK LINKS BAR ── */
.quick-links {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
  padding: 1rem 1.25rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  align-items: center;
}
.quick-links-label {
  font-size: .7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-light);
  white-space: nowrap;
  margin-right: .25rem;
}
.quick-link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .45rem .9rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: .82rem;
  font-weight: 500;
  color: var(--text-mid);
  text-decoration: none;
  transition: all .15s;
  white-space: nowrap;
}
.quick-link:hover { background: var(--blue-light); border-color: var(--blue-mid); color: var(--blue-deep); }
.quick-link.primary { background: var(--blue-deep); border-color: var(--blue-deep); color: var(--white); }
.quick-link.primary:hover { background: var(--blue-mid); border-color: var(--blue-mid); }

/* ── CONTENT LAYOUT (testo + immagine laterale) ── */
.content-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 3rem;
  margin-bottom: 3rem;
  align-items: start;
}
.content-layout.no-image { grid-template-columns: 1fr; }
.content-layout.image-left { grid-template-columns: 340px 1fr; }

.content-text { font-size: .95rem; color: var(--text-mid); line-height: 1.8; }
.content-text h2 { font-family: var(--serif); font-size: 1.4rem; font-weight: 400; color: var(--text-dark); margin: 1.75rem 0 .75rem; }
.content-text h3 { font-family: var(--serif); font-size: 1.1rem; font-weight: 600; color: var(--blue-deep); margin: 1.25rem 0 .5rem; }
.content-text h2:first-child, .content-text h3:first-child { margin-top: 0; }
.content-text p { margin-bottom: .9rem; }
.content-text ol, .content-text ul { padding-left: 1.25rem; margin-bottom: .9rem; }
.content-text li { margin-bottom: .35rem; }
.content-text a { color: var(--blue-mid); }
.content-text strong { color: var(--text-dark); }
.content-text em { color: var(--text-light); font-style: italic; }

.content-image { position: sticky; top: calc(var(--nav-h) + 1rem); }
.content-image img { width: 100%; height: auto; border-radius: 10px; box-shadow: 0 4px 20px rgba(0,30,100,.1); }

/* ── INFO CARDS GRID (bottom of pages) ── */
.cards-section { margin-top: 3rem; padding-top: 2.5rem; border-top: 1px solid var(--border); }
.cards-section-title {
  font-size: .7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--text-light);
  margin-bottom: 1.25rem;
}
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}
.info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  transition: box-shadow .2s, border-color .2s;
}
.info-card:hover { box-shadow: 0 6px 20px rgba(0,30,100,.08); border-color: var(--blue-mid); }
.info-card-title { font-size: .9rem; font-weight: 600; color: var(--text-dark); }
.info-card-desc { font-size: .83rem; color: var(--text-mid); line-height: 1.6; flex: 1; }
.info-card-desc img { max-width: 100px; float: right; margin-left: .75rem; border-radius: 4px; }
.info-card-link {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  font-size: .82rem;
  font-weight: 600;
  color: var(--blue-mid);
  text-decoration: none;
  margin-top: .5rem;
  padding: .4rem .8rem;
  background: var(--blue-light);
  border-radius: 5px;
  transition: background .15s;
  align-self: flex-start;
}
.info-card-link:hover { background: var(--blue-deep); color: var(--white); }

/* ── TEAM GRID (Index_QUI) ── */
.team-section { margin-top: 2rem; }
.team-group-title {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 600;
  color: var(--blue-deep);
  padding: .6rem 1rem;
  background: var(--blue-xlight);
  border-radius: 6px;
  margin-bottom: 1rem;
  border-left: 3px solid var(--blue-deep);
}
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.team-member { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .4rem; }
.team-member img { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border); }
.team-member span { font-size: .75rem; font-weight: 500; color: var(--text-mid); line-height: 1.3; }

/* ── DATA TABLE ── */
.table-wrap { overflow-x: auto; margin-bottom: 2rem; border-radius: 8px; border: 1px solid var(--border); }
.data-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.data-table th {
  background: var(--blue-deep);
  color: white;
  padding: .6rem 1rem;
  text-align: left;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .03em;
  white-space: nowrap;
}
.data-table td { padding: .55rem 1rem; border-bottom: 1px solid var(--border); color: var(--text-mid); vertical-align: top; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--blue-xlight); }
.data-table td a { color: var(--blue-mid); }

/* ── GENERIC CONTENT FALLBACK ── */
.generic-content { font-size: .95rem; color: var(--text-mid); line-height: 1.8; }
.generic-content h2 { font-family: var(--serif); font-size: 1.3rem; font-weight: 400; color: var(--text-dark); margin: 1.5rem 0 .75rem; }
.generic-content h3 { font-size: 1rem; font-weight: 600; color: var(--blue-deep); margin: 1.25rem 0 .5rem; }
.generic-content p { margin-bottom: .9rem; }
.generic-content a { color: var(--blue-mid); }
.generic-content img { max-width: 100%; border-radius: 6px; margin: .5rem 0; }
.generic-content table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
.generic-content th { background: var(--blue-deep); color: white; padding: .5rem .75rem; font-size: .8rem; }
.generic-content td { padding: .5rem .75rem; border-bottom: 1px solid var(--border); font-size: .875rem; }

/* ── FORM FIELDS INLINE (usati in pagine non-form) ── */
.form-wrap { margin-bottom: 2.5rem; }
.form-wrap h3 {
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--blue-deep);
  margin-bottom: 1.25rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--border);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: .85rem; }
.field-row.full { grid-template-columns: 1fr; }
.field { display: flex; flex-direction: column; gap: .3rem; }
.field label { font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--text-light); }
.field input:not([type=radio]):not([type=checkbox]),
.field select,
.field textarea {
  width: 100%;
  padding: .6rem .85rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: var(--sans);
  font-size: .9rem;
  color: var(--text-dark);
  background: var(--white);
  outline: none;
  transition: border-color .15s;
}
.field input[type=radio], .field input[type=checkbox] { width: auto; margin-right: .4rem; cursor: pointer; }
.field-radio { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.field-radio label { font-weight: 400; text-transform: none; letter-spacing: 0; cursor: pointer; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--blue-mid);
  box-shadow: 0 0 0 3px rgba(0,80,204,.1);
}
.field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7594' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .75rem center;
  padding-right: 2.5rem;
}
.form-actions { display: flex; gap: .75rem; margin-top: 1.5rem; flex-wrap: wrap; }
.btn-submit {
  background: var(--blue-deep);
  color: var(--white);
  border: none;
  padding: .7rem 2rem;
  border-radius: 6px;
  font-family: var(--sans);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s;
}
.btn-submit:hover { background: var(--blue-mid); }
.btn-reset {
  background: none;
  color: var(--text-mid);
  border: 1px solid var(--border);
  padding: .7rem 1.5rem;
  border-radius: 6px;
  font-family: var(--sans);
  font-size: .9rem;
  cursor: pointer;
  transition: all .15s;
}
.btn-reset:hover { border-color: var(--blue-mid); color: var(--blue-mid); }

/* ── HOMEPAGE HERO ── */
.home-hero {
  background: linear-gradient(135deg, var(--blue-deep), #001a66);
  color: var(--white);
  padding: 4rem 2rem 3rem;
  margin: -3rem -2rem 3rem;
}
.home-hero-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.home-hero h2 {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 300;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.home-hero h2 strong { font-weight: 600; }
.home-hero p { font-size: .95rem; color: rgba(255,255,255,.75); line-height: 1.7; margin-bottom: 1.5rem; }
.home-hero-actions { display: flex; gap: .75rem; flex-wrap: wrap; }
.home-news-img img { width: 100%; border-radius: 10px; box-shadow: 0 12px 40px rgba(0,0,0,.3); }

/* ── HOMEPAGE SERVICES ── */
.home-services {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  margin-bottom: 3rem;
}
.home-service {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  padding: 1.5rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
  transition: all .2s;
}
.home-service:hover { box-shadow: 0 6px 24px rgba(0,30,100,.08); border-color: var(--blue-mid); transform: translateY(-2px); }
.home-service-icon { font-size: 1.4rem; }
.home-service-name { font-size: .9rem; font-weight: 600; color: var(--text-dark); }
.home-service-desc { font-size: .82rem; color: var(--text-light); line-height: 1.5; flex: 1; }
.home-service-arrow { font-size: .78rem; font-weight: 600; color: var(--blue-mid); margin-top: auto; }

/* ── RESPONSIVE v3 ── */
@media (max-width: 900px) {
  .content-layout { grid-template-columns: 1fr; }
  .content-layout.image-left { grid-template-columns: 1fr; }
  .content-image { position: static; }
  .home-hero-inner { grid-template-columns: 1fr; }
  .home-news-img { display: none; }
}
@media (max-width: 640px) {
  .cards-grid { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: repeat(3, 1fr); }
  .field-row { grid-template-columns: 1fr; }
  .home-hero { margin: -2rem -1.25rem 2rem; padding: 3rem 1.5rem 2.5rem; }
}
/* ═══════════════════════════════════════════════════════════════
   SFP-Europa — Team members (aggiunta a style-v3.css)
   Sostituisce .team-grid e .team-member esistenti con versione
   più robusta: foto circolari, fallback avatar, campo role.
   ═══════════════════════════════════════════════════════════════ */

/* ── TEAM SECTION ── */
.team-section {
  margin: 1.5rem 0 2rem;
}

.team-group-title {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 600;
  color: var(--blue-deep);
  padding: .6rem 1rem;
  background: var(--blue-xlight);
  border-radius: 6px;
  margin-bottom: 1.5rem;
  border-left: 3px solid var(--blue-deep);
}

/* ── GRID ── */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1.5rem 1rem;
  margin-bottom: 1.5rem;
}

/* ── MEMBER CARD ── */
.team-member {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: .5rem;
}

/* Foto circolare */
.team-member img {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  object-position: top center;
  border: 2px solid var(--border);
  background: var(--bg);
  display: block;
  transition: border-color .2s;
}
.team-member:hover img {
  border-color: var(--blue-mid);
}

/* Fallback avatar (initiali) */
.team-avatar-fallback {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: var(--blue-light);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--blue-deep);
  letter-spacing: .02em;
  flex-shrink: 0;
}

/* Nome */
.team-member-name {
  font-size: .8rem;
  color: var(--text-dark);
  line-height: 1.35;
}
.team-member-name strong {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: var(--text-dark);
}

/* Ruolo opzionale */
.team-member-role {
  font-size: .72rem;
  color: var(--blue-mid);
  font-weight: 500;
  background: var(--blue-light);
  padding: .15rem .5rem;
  border-radius: 20px;
  white-space: nowrap;
}


/* ── CARDS GRID — colonne fisse ── */
.cards-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.cards-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }

/* ── INFO CARD — icona ── */
.info-card-icon {
  font-size: 1.5rem;
  margin-bottom: .25rem;
  line-height: 1;
}

/* ── RESPONSIVE colonne fisse ── */
@media (max-width: 900px) {
  .cards-grid.cols-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .cards-grid.cols-2,
  .cards-grid.cols-3 { grid-template-columns: 1fr; }
}	

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .team-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem .75rem;
  }
  .team-member img,
  .team-avatar-fallback {
    width: 72px;
    height: 72px;
  }
}
@media (max-width: 380px) {
  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}


/* ── CANDIDATS HOME PAGE ── */
.candidats-strip {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 2rem 2rem;
}
.candidats-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 2.5rem;
}
.candidats-thumb-link { flex-shrink: 0; }
.candidats-thumb {
  width: 160px;
  height: auto;
  border-radius: 6px;
  border: 1px solid var(--border);
  box-shadow: 0 4px 16px rgba(0,30,100,.1);
  transition: box-shadow .2s;
}
.candidats-thumb:hover { box-shadow: 0 6px 24px rgba(0,30,100,.18); }
.candidats-body { flex: 1; }
.candidats-title {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--text-dark);
  margin: .25rem 0 .5rem;
}
.candidats-desc {
  font-size: .9rem;
  color: var(--text-mid);
  line-height: 1.6;
  margin-bottom: 1rem;
  max-width: 500px;
}
.candidats-btn { margin-top: .25rem; }

@media (max-width: 640px) {
  .candidats-inner { flex-direction: column; align-items: flex-start; gap: 1.25rem; }
  .candidats-thumb { width: 120px; }
}