/* ═══════════════════════════════════════════════
   ETNA ZERO TREMILA — form.css
   Stili specifici per la pagina di registrazione.
   Richiede global.css caricato prima.
   ═══════════════════════════════════════════════ */

/* ── PAGE HERO (versione compatta per pagine interne) ── */
.page-hero {
  position: relative;
  background: linear-gradient(160deg, var(--crater) 0%, #0d0907 100%);
  padding: 120px 24px 60px;   /* top padding compensa la nav fissa */
  text-align: center;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='800' height='300' viewBox='0 0 800 300'%3E%3Cpolygon points='400,10 680,290 120,290' fill='none' stroke='%23d94f2b' stroke-width='0.5' opacity='0.18'/%3E%3Cpolygon points='400,40 650,290 150,290' fill='none' stroke='%23f07d30' stroke-width='0.3' opacity='0.1'/%3E%3C/svg%3E") center/contain no-repeat;
  opacity: 0.6;
  pointer-events: none;
}

.page-hero .eyebrow { margin-bottom: 14px; }

.page-hero h1 {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: clamp(42px, 8vw, 88px);
  font-weight: 900;
  line-height: 0.92;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--white);
}
.page-hero h1 span {
  display: block;
  color: var(--glow);
  font-size: 0.55em;
  letter-spacing: 0.04em;
}

.page-hero-sub {
  margin-top: 20px;
  font-size: 15px;
  color: var(--pumice);
  max-width: 480px;
  margin-inline: auto;
  line-height: 1.6;
}
.page-hero-sub strong { color: var(--snow); }

.elevation-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 28px;
  background: var(--ember);
  color: var(--white);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 18px;
  border-radius: 40px;
}
.elevation-badge::before { content: '▲'; font-size: 10px; }

/* ── FORM LAYOUT ── */
.form-wrapper {
  max-width: 640px;
  margin: 0 auto;
  padding: 48px 24px 96px;
}

/* ── FORM SECTION LABELS ── */
.form-section-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ember);
  margin: 36px 0 18px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--crater);
}

/* ── FIELD ── */
.field { margin-bottom: 24px; }

.field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--snow);
  margin-bottom: 6px;
}
.field label .lang {
  display: block;
  font-weight: 400;
  color: var(--pumice);
  font-size: 12px;
  margin-top: 1px;
}
.field label .req {
  color: var(--ember);
  margin-left: 3px;
}

/* ── INPUTS & SELECTS ── */
input[type="text"],
input[type="email"],
input[type="tel"],
select {
  width: 100%;
  background: var(--crater);
  border: 1.5px solid var(--ash);
  border-radius: var(--radius);
  color: var(--snow);
  font-family: 'Barlow', sans-serif;
  font-size: 15px;
  padding: 11px 14px;
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
  -webkit-appearance: none;
  outline: none;
}
input::placeholder { color: var(--ash); }

input:focus,
select:focus {
  border-color: var(--glow);
  box-shadow: 0 0 0 3px rgba(240,125,48,0.15);
}

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4' stroke='%23b8a89e' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 38px;
  cursor: pointer;
}
select option { background: var(--crater); color: var(--snow); }
select option[value=""] { color: var(--ash); }

/* ── FILE UPLOAD ── */
.upload-area {
  position: relative;
  border: 1.5px dashed var(--ash);
  border-radius: var(--radius);
  background: var(--crater);
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
}
.upload-area:hover,
.upload-area.dragover {
  border-color: var(--glow);
  background: rgba(240,125,48,0.05);
}
.upload-area input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
  border: none;
  background: none;
  box-shadow: none;
  padding: 0;
}
.upload-icon   { font-size: 26px; margin-bottom: 8px; opacity: 0.6; }
.upload-text   { font-size: 14px; color: var(--pumice); }
.upload-text strong { color: var(--glow); font-weight: 600; }
.upload-hint   { font-size: 11px; color: var(--ash); margin-top: 5px; letter-spacing: 0.04em; }
.upload-filename {
  display: none;
  margin-top: 10px;
  font-size: 12px;
  color: var(--glow);
  font-weight: 600;
}

/* ── CHECKBOX OPTIONS (optionals + consensi) ── */
.field-optionals {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.checkbox-field { margin-bottom: 16px; }

.checkbox-option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--crater);
  border: 1.5px solid var(--ash);
  border-radius: var(--radius);
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
}
.checkbox-option:hover { border-color: var(--glow); }
.checkbox-option input[type="checkbox"] {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--ember);
  cursor: pointer;
}
.checkbox-option-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 14px;
  color: var(--snow);
  line-height: 1.5;
}
.checkbox-option-name { font-weight: 600; }
.checkbox-option-desc { font-size: 13px; color: var(--pumice); }
.checkbox-option-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--glow);
}
.checkbox-option-price.is-discount { color: #4ade80; }

.checkbox-option-body a {
  color: var(--glow);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.checkbox-option-body a:hover { color: var(--white); }

/* ── SUBMIT ── */
.submit-area {
  margin-top: 44px;
  text-align: center;
}
.btn-submit {
  display: inline-block;
  background: var(--ember);
  color: var(--white);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: none;
  border-radius: var(--radius);
  padding: 16px 60px;
  cursor: pointer;
  transition: background var(--transition), transform 0.1s;
}
.btn-submit:hover  { background: #c44426; }
.btn-submit:active { transform: scale(0.98); }

.form-note {
  margin-top: 16px;
  font-size: 14px;
  color: var(--pumice);
}

/* ── DOCUMENT MODAL (regolamento / informativa privacy) ── */
.doc-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.doc-modal.is-open { display: flex; }
.doc-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(16, 12, 11, 0.75);
}
.doc-modal-dialog {
  position: relative;
  z-index: 1;
  background: var(--crater);
  border: 1px solid var(--ash);
  border-radius: var(--radius);
  width: 100%;
  max-width: 640px;
  max-height: min(80vh, 720px);
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 60px rgba(0,0,0,0.5);
}
.doc-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--ash);
}
.doc-modal-header h3 {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 20px;
  font-weight: 900;
  text-transform: uppercase;
  color: var(--white);
  margin: 0;
}
.doc-modal-close {
  background: none;
  border: none;
  color: var(--pumice);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}
.doc-modal-close:hover { color: var(--white); }
.doc-modal-body {
  padding: 22px;
  overflow-y: auto;
  color: var(--snow);
  font-size: 15px;
  line-height: 1.7;
}
.doc-modal-body h2,
.doc-modal-body h3 {
  font-family: 'Barlow Condensed', sans-serif;
  text-transform: uppercase;
  color: var(--white);
  margin: 24px 0 10px;
}
.doc-modal-body h2 { font-size: 20px; }
.doc-modal-body h3 { font-size: 17px; }
.doc-modal-body p  { margin: 0 0 14px; }
.doc-modal-body ul,
.doc-modal-body ol { margin: 0 0 14px; padding-left: 22px; }
.doc-modal-body li { margin-bottom: 6px; }
.doc-modal-body a  { color: var(--glow); }
.doc-modal-loading { color: var(--pumice); }

@media (max-width: 480px) {
  .doc-modal { padding: 12px; }
  .doc-modal-dialog { max-height: 88vh; }
}

/* ── RESPONSIVE ── */
@media (max-width: 480px) {
  .page-hero  { padding: 100px 16px 48px; }
  .form-wrapper { padding: 28px 16px 64px; }
}
