/* =========================================================================
   FotoHoliday — components.css
   Bottoni, schede, tessere di scelta, moduli, calendario, avanzamento,
   allegati, avvisi, FAQ.
   ========================================================================= */

/* --- Bottoni ---------------------------------------------------------------- */
.btn {
  --btn-bg: var(--ink-900);
  --btn-fg: var(--sand-50);
  --btn-border: var(--ink-900);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.6rem;
  border: 1px solid var(--btn-border);
  border-radius: var(--radius-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 0.97rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: transform var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease),
    color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease),
    box-shadow var(--dur-fast) var(--ease);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-s);
}

.btn:active { transform: translateY(0); }

.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
  box-shadow: none;
}

.btn--accent {
  --btn-bg: var(--terra-600);
  --btn-border: var(--terra-600);
  --btn-fg: var(--white);
}

.btn--accent:hover { --btn-bg: var(--terra-700); --btn-border: var(--terra-700); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--ink-900);
  --btn-border: var(--line-strong);
}

.btn--ghost:hover { --btn-border: var(--ink-900); }

.btn--light {
  --btn-bg: transparent;
  --btn-fg: var(--sand-50);
  --btn-border: rgba(255, 255, 255, 0.4);
}

.btn--light:hover { --btn-bg: rgba(255, 255, 255, 0.1); --btn-border: var(--sand-50); }

.btn--solid-light {
  --btn-bg: var(--sand-50);
  --btn-fg: var(--ink-900);
  --btn-border: var(--sand-50);
}

.btn--small { padding: 0.5rem 1.05rem; font-size: 0.88rem; }
.btn--block { width: 100%; }

.btn__arrow { transition: transform var(--dur) var(--ease); }
.btn:hover .btn__arrow { transform: translateX(3px); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 500;
  color: var(--terra-700);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
}

.link-arrow:hover { color: var(--ink-900); }

/* --- Avvisi / note ----------------------------------------------------------- */
.note {
  display: flex;
  gap: 0.75rem;
  padding: var(--space-s) 1.1rem;
  border-radius: var(--radius-m);
  background: var(--sand-100);
  border: 1px solid var(--line);
  font-size: 0.93rem;
  line-height: 1.55;
  color: var(--ink-700);
}

.note > p:last-child { margin-bottom: 0; }

.note--demo {
  background: var(--terra-100);
  border-color: rgba(180, 81, 42, 0.28);
  color: var(--terra-700);
}

.note--ocean {
  background: var(--ocean-200);
  border-color: rgba(29, 90, 102, 0.26);
  color: var(--ocean-800);
}

.note__icon {
  flex: none;
  width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.25rem;
  border-radius: 50%;
  border: 1.5px solid currentColor;
  position: relative;
}

.note__icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 0.18rem;
  transform: translateX(-50%);
  width: 1.5px;
  height: 0.22rem;
  background: currentColor;
  box-shadow: 0 0.34rem 0 0 currentColor;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.22rem 0.7rem;
  border-radius: var(--radius-pill);
  background: var(--sand-200);
  color: var(--ink-700);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.badge--accent { background: var(--terra-600); color: var(--white); }
.badge--ocean { background: var(--ocean-700); color: var(--white); }
.badge--quiet { background: transparent; border: 1px solid var(--line-strong); color: var(--ink-500); }

/* --- Schede ------------------------------------------------------------------ */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  padding: var(--space-m);
  box-shadow: var(--shadow-s);
}

/* --- Pacchetti ---------------------------------------------------------------- */
.packages {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-m);
  align-items: stretch;
}

.package {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  padding: var(--space-m) var(--space-m) var(--space-l);
  position: relative;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.package:hover { transform: translateY(-4px); box-shadow: var(--shadow-m); }

.package--featured {
  background: var(--ink-900);
  color: var(--sand-200);
  border-color: var(--ink-900);
}

.package--featured h3 { color: var(--sand-50); }
.package--featured .package__price { color: var(--sand-50); }
.package--featured .package__list li { border-color: rgba(255, 255, 255, 0.14); }
.package--featured .package__list li::before { background: var(--terra-500); }

.package__badge {
  position: absolute;
  top: -0.75rem;
  left: var(--space-m);
}

.package__name {
  font-size: var(--step-2);
  margin-bottom: 0.2rem;
}

.package__tagline {
  font-size: 0.93rem;
  color: var(--text-muted);
  margin-bottom: var(--space-s);
}

.package--featured .package__tagline { color: var(--sand-400); }

.package__price {
  font-family: var(--font-display);
  font-size: var(--step-1);
  color: var(--ink-900);
  padding-block: var(--space-xs);
  border-block: 1px solid var(--line);
  margin-bottom: var(--space-s);
}

.package--featured .package__price { border-color: rgba(255, 255, 255, 0.16); }

.package__price small {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.package--featured .package__price small { color: var(--sand-400); }

.package__list {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--space-m);
  flex: 1;
}

.package__list li {
  position: relative;
  padding: 0.55rem 0 0.55rem 1.4rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.95rem;
}

.package__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.05rem;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--terra-600);
}

@media (max-width: 62rem) {
  .packages { grid-template-columns: 1fr; }
}

/* --- Tessere di scelta (moduli conversazionali) -------------------------------- */
.choices {
  display: grid;
  gap: var(--space-s);
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  margin: 0;
  padding: 0;
  border: 0;
}

.choices--wide { grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); }
.choices--compact { grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); }

.choice {
  position: relative;
  display: block;
  border-radius: var(--radius-m);
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease),
    transform var(--dur-fast) var(--ease);
}

.choice:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
  box-shadow: var(--shadow-s);
}

.choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.choice__body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.95rem 1.05rem;
}

.choice__title {
  font-family: var(--font-display);
  font-size: var(--step-1);
  line-height: 1.2;
}

.choice__meta {
  font-size: 0.87rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.choice__media {
  aspect-ratio: 4 / 3;
  background: linear-gradient(160deg, var(--sand-300), var(--ocean-200));
  overflow: hidden;
}

.choice__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--dur-slow) var(--ease);
}

.choice:hover .choice__media img { transform: scale(1.04); }

.choice__check {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  border: 1.5px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.92);
  display: grid;
  place-content: center;
  transition: background var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}

.choice__check::after {
  content: "";
  width: 0.5rem;
  height: 0.28rem;
  border-left: 2px solid var(--white);
  border-bottom: 2px solid var(--white);
  transform: rotate(-45deg) scale(0.4);
  opacity: 0;
  transition: opacity var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease);
}

.choice:has(input:checked) {
  border-color: var(--terra-600);
  box-shadow: 0 0 0 1px var(--terra-600), var(--shadow-s);
}

.choice:has(input:checked) .choice__check {
  background: var(--terra-600);
  border-color: var(--terra-600);
}

.choice:has(input:checked) .choice__check::after { opacity: 1; transform: rotate(-45deg) scale(1); }

.choice:has(input:focus-visible) {
  outline: 2px solid var(--terra-600);
  outline-offset: 3px;
}

/* Varianti senza immagine, usate per opzioni brevi. */
.choice--plain .choice__body { padding: 0.9rem 2.6rem 0.9rem 1.05rem; }
.choice--plain .choice__title { font-size: var(--step-0); font-family: var(--font-sans); font-weight: 500; }

/* --- Moduli ------------------------------------------------------------------- */
.field { margin-bottom: var(--space-s); }

.field__label,
.fieldset__legend {
  display: block;
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--ink-800);
  margin-bottom: 0.3rem;
}

.field__hint {
  display: block;
  font-size: 0.86rem;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
  line-height: 1.5;
}

.field__optional {
  font-weight: 400;
  color: var(--ink-400);
  font-size: 0.85rem;
}

.input,
.select,
.textarea {
  width: 100%;
  padding: 0.75rem 0.95rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-s);
  background: var(--white);
  color: var(--ink-900);
  transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}

.input:hover,
.select:hover,
.textarea:hover { border-color: var(--ink-400); }

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--terra-600);
  box-shadow: 0 0 0 3px rgba(200, 106, 62, 0.18);
}

.textarea { min-height: 7rem; resize: vertical; }

.select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink-500) 50%),
    linear-gradient(135deg, var(--ink-500) 50%, transparent 50%);
  background-position: right 1.05rem center, right 0.75rem center;
  background-size: 0.35rem 0.35rem, 0.35rem 0.35rem;
  background-repeat: no-repeat;
  padding-right: 2.2rem;
}

/* Elenco personalizzato: resta nel viewport anche dentro una card con overflow. */
.select--custom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.25rem;
  text-align: left;
  background-image: none;
  cursor: pointer;
}

.select--custom__label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.select--custom__chevron {
  width: .58rem;
  height: .58rem;
  flex: none;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform var(--dur-fast) var(--ease);
}
.select--custom[aria-expanded="true"] .select--custom__chevron { transform: rotate(225deg) translateY(-2px); }
.select--custom:focus-visible { outline: 3px solid var(--terra-500); outline-offset: 2px; }

.select-popover {
  position: fixed;
  z-index: 2100;
  box-sizing: border-box;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: .38rem;
  border: 1px solid var(--sand-300);
  border-radius: .9rem;
  background: var(--white);
  box-shadow: var(--shadow-l);
}
.select-popover[hidden] { display: none; }
.select-popover__option {
  display: flex;
  width: 100%;
  min-height: 2.75rem;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .7rem .85rem;
  border: 0;
  border-radius: .65rem;
  background: transparent;
  color: var(--ink-900);
  text-align: left;
  line-height: 1.35;
}
.select-popover__option:hover,
.select-popover__option[aria-selected="true"] { background: var(--sand-100); }
.select-popover__option[aria-selected="true"] { color: var(--terra-700); font-weight: 700; }
.select-popover__option[aria-selected="true"]::after { content: '✓'; font-weight: 800; }
.select-popover__option:focus-visible { outline: 2px solid var(--terra-600); outline-offset: -2px; }

.input[aria-invalid="true"],
.select[aria-invalid="true"],
.textarea[aria-invalid="true"] {
  border-color: #A22C1E;
  box-shadow: 0 0 0 3px rgba(162, 44, 30, 0.14);
}

.field__error {
  display: block;
  font-size: 0.86rem;
  color: #8E2718;
  margin-top: 0.3rem;
  font-weight: 500;
}

.field__error:empty { display: none; }

.field-row {
  display: grid;
  gap: var(--space-s);
  grid-template-columns: repeat(2, 1fr);
}

.field-row--phone { grid-template-columns: minmax(9rem, 13rem) 1fr; }

@media (max-width: 34rem) {
  .field-row,
  .field-row--phone { grid-template-columns: 1fr; }
}

.checkbox {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  font-size: 0.93rem;
  line-height: 1.5;
  padding: 0.5rem 0;
  cursor: pointer;
}

.checkbox input {
  flex: none;
  width: 1.15rem;
  height: 1.15rem;
  margin-top: 0.15rem;
  accent-color: var(--terra-600);
}

.fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 var(--space-m);
}

/* --- Selezione a pillole (giorni, fasce, lingue) --------------------------------- */
.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0;
  margin: 0;
  border: 0;
}

.pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  background: var(--white);
  font-size: 0.92rem;
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease),
    color var(--dur-fast) var(--ease);
}

.pill input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.pill:hover { border-color: var(--ink-400); }

.pill:has(input:checked) {
  background: var(--ink-900);
  border-color: var(--ink-900);
  color: var(--sand-50);
}

.pill:has(input:focus-visible) { outline: 2px solid var(--terra-600); outline-offset: 2px; }

/* --- Avanzamento del modulo conversazionale ---------------------------------------- */
.flow {
  background: var(--sand-100);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow-m);
}

.flow__header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-xs) var(--space-s);
  padding: var(--space-s) var(--space-m);
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.flow__counter {
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-500);
  font-weight: 600;
}

.flow__title-mini {
  font-family: var(--font-display);
  font-size: var(--step-0);
  color: var(--ink-800);
}

.flow__progress {
  flex: 1 1 100%;
  height: 3px;
  background: var(--sand-200);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.flow__progress-bar {
  height: 100%;
  width: 0;
  background: var(--terra-600);
  border-radius: inherit;
  transition: width var(--dur) var(--ease);
}

.flow__body { padding: var(--space-l) var(--space-m); }

@media (min-width: 48rem) {
  .flow__body { padding: var(--space-xl) var(--space-l); }
}

.flow__step-head { margin-bottom: var(--space-m); max-width: 44rem; }

.flow__question {
  font-size: var(--step-3);
  margin-bottom: 0.35rem;
}

.flow__question:focus { outline: none; }

.flow__help {
  color: var(--ink-700);
  font-size: 0.98rem;
  margin: 0;
}

.flow__footer {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s);
  align-items: center;
  padding: var(--space-s) var(--space-m) var(--space-m);
  border-top: 1px solid var(--line);
  background: var(--white);
}

.flow__footer .btn--ghost { margin-right: auto; }

.flow__status {
  flex: 1 1 100%;
  font-size: 0.9rem;
  color: #8E2718;
  font-weight: 500;
  min-height: 1.2rem;
}

.flow__status:empty { min-height: 0; }

.flow__section + .flow__section { margin-top: var(--space-m); }

.flow__subhead {
  font-family: var(--font-sans);
  font-size: 0.93rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-bottom: 0.45rem;
}

/* --- Calendario ------------------------------------------------------------------ */
.calendar {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  padding: var(--space-s);
}

.calendar__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xs);
  margin-bottom: var(--space-xs);
}

.calendar__month {
  font-family: var(--font-display);
  font-size: var(--step-1);
  text-transform: capitalize;
}

.calendar__nav {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--white);
  display: grid;
  place-content: center;
  transition: background var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}

.calendar__nav:hover:not([disabled]) { background: var(--sand-100); border-color: var(--ink-400); }
.calendar__nav[disabled] { opacity: 0.3; cursor: not-allowed; }

.calendar__weekdays,
.calendar__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.calendar__weekdays {
  margin-bottom: 3px;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-400);
  text-align: center;
}

.day {
  aspect-ratio: 1;
  min-height: 2.4rem;
  border: 1px solid transparent;
  border-radius: var(--radius-s);
  background: var(--sand-100);
  color: var(--ink-800);
  font-size: 0.92rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease);
}

.day:hover:not([disabled]) { background: var(--sand-200); border-color: var(--line-strong); }

.day[disabled] {
  background: transparent;
  color: var(--sand-400);
  cursor: not-allowed;
  text-decoration: line-through;
  text-decoration-thickness: 1px;
}

.day--empty { background: transparent; border: 0; }

.day__dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--terra-600);
  opacity: 0.85;
}

.day[disabled] .day__dot { display: none; }

.day[aria-pressed="true"] {
  background: var(--ink-900);
  color: var(--sand-50);
  border-color: var(--ink-900);
}

.day[aria-pressed="true"] .day__dot { background: var(--sand-300); }

.calendar__legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-s);
  margin-top: var(--space-xs);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.calendar__legend span { display: inline-flex; align-items: center; gap: 0.35rem; }

.legend-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--terra-600);
}

.legend-dot--off { background: var(--sand-400); }

/* --- Fasce orarie ------------------------------------------------------------------ */
.slots {
  display: grid;
  gap: 0.5rem;
  grid-template-columns: repeat(auto-fill, minmax(7.5rem, 1fr));
  padding: 0;
  margin: 0;
  border: 0;
}

.slot {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-s);
  background: var(--white);
  cursor: pointer;
  text-align: left;
  transition: border-color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}

.slot input { position: absolute; opacity: 0; width: 1px; height: 1px; }

.slot__time { font-weight: 600; font-variant-numeric: tabular-nums; }
.slot__label { font-size: 0.78rem; color: var(--text-muted); }

.slot:hover { border-color: var(--ink-400); }

.slot:has(input:checked) {
  background: var(--ink-900);
  border-color: var(--ink-900);
  color: var(--sand-50);
}

.slot:has(input:checked) .slot__label { color: var(--sand-300); }
.slot:has(input:focus-visible) { outline: 2px solid var(--terra-600); outline-offset: 2px; }

.slot--off {
  opacity: 0.5;
  cursor: not-allowed;
  background: var(--sand-100);
}

.slot--off:hover { border-color: var(--line-strong); }

/* Età dei bambini: campi corti affiancati. */
.age-grid {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s);
}

.age-grid .field { margin-bottom: 0; }
.input--narrow { width: 6.5rem; }

/* --- Ricerca hotel ------------------------------------------------------------------- */
.combo { position: relative; }

.combo__list {
  position: absolute;
  z-index: 20;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  max-height: 16rem;
  overflow-y: auto;
  background: var(--white);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-s);
  box-shadow: var(--shadow-m);
  list-style: none;
  margin: 0;
  padding: 0.25rem;
}

.combo__list[hidden] { display: none; }

.combo__option {
  padding: 0.55rem 0.7rem;
  border-radius: var(--radius-s);
  cursor: pointer;
  font-size: 0.94rem;
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
}

.combo__option small { color: var(--text-muted); font-size: 0.8rem; white-space: nowrap; }

.combo__option[aria-selected="true"],
.combo__option:hover { background: var(--sand-100); }

.combo__empty {
  padding: 0.6rem 0.7rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* --- Riepilogo --------------------------------------------------------------------- */
.summary {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  overflow: hidden;
}

.summary__row {
  display: grid;
  grid-template-columns: minmax(8rem, 13rem) 1fr auto;
  gap: 0.5rem var(--space-s);
  padding: 0.8rem 1.1rem;
  align-items: baseline;
  font-size: 0.95rem;
}

.summary__row + .summary__row { border-top: 1px solid var(--line); }

.summary__key {
  color: var(--text-muted);
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.summary__value { font-weight: 500; }
.summary__value span { display: block; font-weight: 400; color: var(--text-muted); font-size: 0.9rem; }

.summary__edit {
  background: none;
  border: 0;
  color: var(--terra-700);
  font-size: 0.86rem;
  text-decoration: underline;
  padding: 0;
}

@media (max-width: 34rem) {
  .summary__row { grid-template-columns: 1fr auto; }
  .summary__key { grid-column: 1 / -1; }
}

/* --- Esito finale ------------------------------------------------------------------- */
.outcome {
  text-align: center;
  max-width: 34rem;
  margin-inline: auto;
  padding: var(--space-m) 0;
}

.outcome__list {
  text-align: left;
  max-width: 34rem;
  margin: 0 auto var(--space-m);
  color: var(--ink-700);
}

.outcome__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s);
  justify-content: center;
}

.outcome__mark {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto var(--space-s);
  border-radius: 50%;
  border: 1.5px solid var(--terra-600);
  display: grid;
  place-content: center;
  color: var(--terra-600);
  font-family: var(--font-display);
  font-size: var(--step-2);
}

/* --- Allegati (portfolio fotografi) --------------------------------------------------- */
.dropzone {
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius-m);
  background: var(--white);
  padding: var(--space-l) var(--space-m);
  text-align: center;
  transition: border-color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}

.dropzone.is-dragover {
  border-color: var(--terra-600);
  background: var(--terra-100);
}

.dropzone__title {
  font-family: var(--font-display);
  font-size: var(--step-1);
  margin-bottom: 0.2rem;
}

.dropzone__hint { font-size: 0.87rem; color: var(--text-muted); margin-bottom: var(--space-s); }
.dropzone__formats { max-width: 40rem; margin: .8rem auto 0; color: var(--ink-500); font-size: .8rem; line-height: 1.5; }

.attachments {
  list-style: none;
  margin: var(--space-s) 0 0;
  padding: 0;
  display: grid;
  gap: 0.6rem;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
}

.attachment {
  display: flex;
  gap: 0.7rem;
  align-items: center;
  padding: 0.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  background: var(--white);
}

.attachment__thumb {
  flex: none;
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-s);
  overflow: hidden;
  background: var(--sand-200);
  display: grid;
  place-content: center;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--ink-500);
}

.attachment__thumb img { width: 100%; height: 100%; object-fit: cover; }

.attachment__meta { min-width: 0; flex: 1; }

.attachment__name {
  font-size: 0.88rem;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.attachment__size { font-size: 0.78rem; color: var(--text-muted); }

.attachment__remove {
  flex: none;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--white);
  color: var(--ink-700);
  line-height: 1;
  font-size: 1rem;
}

.attachment__remove:hover { background: var(--sand-100); border-color: var(--ink-400); }

/* Le dieci foto si vedono tutte senza una lista interna da scorrere. */
.portfolio-photos { grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr)); gap: .75rem; }
.portfolio-photos .attachment { position: relative; display: flex; flex-direction: column; align-items: stretch; gap: .45rem; padding: .4rem; min-width: 0; }
.attachment__preview { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: var(--radius-s); background: var(--sand-100); cursor: zoom-in; }
.attachment__preview:focus-visible, .portfolio-preview button:focus-visible { outline: 3px solid #087fab; outline-offset: 2px; }
.portfolio-photos .attachment__thumb { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; }
.portfolio-photos .attachment__thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.attachment__eye { position: absolute; right: .45rem; bottom: .45rem; display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; background: rgba(255,255,255,.94); color: #10466a; font-size: 1.1rem; box-shadow: 0 2px 7px #10466a33; }
.attachment__eye svg { width: 1.25rem; height: 1.25rem; }
.portfolio-photos .attachment__meta { display: block; width: 100%; padding: 0 .15rem; }
.portfolio-photos .attachment__name { display: block; font-size: .78rem; }
.portfolio-photos .attachment__size { display: block; font-size: .68rem; }
.portfolio-photos .attachment__remove { position: absolute; top: .75rem; right: .75rem; width: 2rem; height: 2rem; border-color: #fff; box-shadow: 0 2px 7px #10466a33; cursor: pointer; }
.portfolio-preview { width: min(90vw, 54rem); max-height: 90vh; padding: 1rem; border: 0; border-radius: 1rem; color: #10466a; background: #fff; box-shadow: 0 20px 60px #062e4580; }
.portfolio-preview::backdrop { background: #062e45b3; }
.portfolio-preview__bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .75rem; }
.portfolio-preview__title { margin: 0; min-width: 0; overflow-wrap: anywhere; font-weight: 600; }
.portfolio-preview__close { flex: none; display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border: 1px solid var(--line-strong); border-radius: 50%; background: #fff; color: #10466a; font-size: 1.5rem; cursor: pointer; }
.portfolio-preview__image { display: block; max-width: 100%; max-height: min(65vh, 48rem); margin: 0 auto; object-fit: contain; }
.portfolio-preview__image[hidden], .portfolio-preview__fallback[hidden] { display: none; }
.portfolio-preview__fallback { padding: 2rem; text-align: center; }
.portfolio-preview__nav { display: flex; justify-content: space-between; gap: .75rem; margin-top: .75rem; }
@media (max-width: 480px) {
  .portfolio-photos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .portfolio-preview { width: 94vw; padding: .75rem; }
  .portfolio-preview__nav .btn { padding-inline: .6rem; font-size: .8rem; }
}

/* --- FAQ ------------------------------------------------------------------------------ */
.faq { border-top: 1px solid var(--line); }

.faq__item {
  border-bottom: 1px solid var(--line);
}

.faq__item summary {
  display: flex;
  gap: var(--space-s);
  align-items: baseline;
  justify-content: space-between;
  padding: var(--space-s) 0;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: var(--step-1);
  color: var(--ink-900);
}

.faq__item summary::-webkit-details-marker { display: none; }

.faq__item summary::after {
  content: "";
  flex: none;
  width: 0.7rem;
  height: 0.7rem;
  border-right: 1.5px solid var(--terra-600);
  border-bottom: 1.5px solid var(--terra-600);
  transform: rotate(45deg) translateY(-2px);
  transition: transform var(--dur) var(--ease);
}

.faq__item[open] summary::after { transform: rotate(-135deg) translateY(-2px); }

.faq__answer {
  padding-bottom: var(--space-s);
  max-width: 58ch;
  color: var(--ink-700);
}

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