/* Active "Submit a paper" button keeps its yellow look */
.nav a.btn[aria-current="page"] { background: var(--yellow); color: var(--navy-900); box-shadow: none; border-radius: var(--radius); }

/* Compact hero */
.hero--compact .wrap { padding-top: 56px; padding-bottom: 56px; }
.crumbs { font-size: .85rem; color: var(--line); margin-bottom: 20px; }
.crumbs a { color: var(--white); }
.hero .eyebrow { color: var(--yellow); }
.hero-meta { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-meta li { display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; color: var(--white); border: 1px solid rgba(255,255,255,.28); background: rgba(255,255,255,.06); border-radius: 999px; padding: 7px 14px; }
.hero-meta svg { width: 16px; height: 16px; flex: none; color: var(--yellow); }

/* Layout */
.layout { display: grid; grid-template-columns: minmax(0,1fr) 340px; gap: 40px; align-items: start; }
@media (max-width: 960px) { .layout { grid-template-columns: minmax(0,1fr); } }
.form-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; font-size: .88rem; color: var(--muted); }

/* Form sections */
.fs { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow); display: grid; gap: 22px; }
.fs-head { display: flex; gap: 16px; align-items: flex-start; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.fs-head h2 { font-size: 1.6rem; margin: 0 0 4px; }
.fs-head p { margin: 0; font-size: .92rem; color: var(--muted); }
.fs-num { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--navy); color: var(--white); display: grid; place-items: center; font: 600 1rem/1 var(--font-display); box-shadow: 0 0 0 4px var(--yellow-soft); }
.row-2 { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 20px; }
@media (max-width: 640px) { .fs { padding: 22px 18px; } .row-2 { grid-template-columns: minmax(0,1fr); } }

fieldset.field { border: 0; margin: 0; padding: 0; min-width: 0; }
fieldset.field legend { padding: 0; margin-bottom: 6px; }
.opt { font-weight: 400; color: var(--muted); font-size: .82rem; margin-left: 4px; }
.label { font-weight: 600; font-size: .92rem; color: var(--ink); }
input[type=radio], input[type=checkbox] { accent-color: var(--navy); width: 18px; height: 18px; margin: 2px 0 0; flex: none; }

/* Radio cards */
.options { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
@media (max-width: 640px) { .options { grid-template-columns: minmax(0,1fr); } }
.option { display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; cursor: pointer; background: var(--white); transition: border-color .15s, box-shadow .15s; }
.option:hover { border-color: var(--muted); }
.option:has(input:checked) { border-color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); background: var(--paper); }
.option strong { display: block; color: var(--ink); font-size: .95rem; }
.option small { display: block; color: var(--muted); font-size: .84rem; line-height: 1.45; margin-top: 2px; }

/* Error state */
.field.is-error input { border-color: var(--bad); box-shadow: inset 0 0 0 1px var(--bad); }
.error-msg { display: flex; gap: 8px; align-items: flex-start; margin: 0; color: var(--bad); font-size: .85rem; font-weight: 500; }
.error-msg svg { width: 16px; height: 16px; flex: none; margin-top: 2px; }
.field:not(.is-error) .error-msg { display: none; }
.demo-tag { font: 600 .68rem/1 var(--font-text); letter-spacing: .06em; text-transform: uppercase; color: #7A5B00; background: var(--warn-soft); border: 1px dashed #D9B84A; border-radius: 4px; padding: 3px 6px; margin-left: 6px; vertical-align: 2px; }

/* Co-authors repeater */
.coauthors { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.coauthor { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); padding: 14px 16px 16px; }
.coauthor-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.coauthor-top span { font: 600 .75rem/1 var(--font-text); letter-spacing: .1em; text-transform: uppercase; color: var(--navy); }
.coauthor-grid { display: grid; grid-template-columns: 1.1fr 1.2fr 1fr; gap: 12px; }
.coauthor-grid label { display: grid; gap: 4px; font-size: .8rem; font-weight: 600; color: var(--muted); }
.coauthor-grid input { padding: 10px 12px; }
@media (max-width: 760px) { .coauthor-grid { grid-template-columns: minmax(0,1fr); } }
.link-btn { background: none; border: 0; padding: 4px 0; font: 600 .82rem/1 var(--font-text); color: var(--bad); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.add-row { justify-self: start; }
.co-rows { display: grid; gap: 12px; }
.co-rows[hidden] { display: none; }
.field .co-err { display: none; }
.field .co-err.is-on { display: flex; }

/* Dropzone */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.dz { display: grid; justify-items: center; gap: 6px; cursor: pointer; transition: border-color .15s, background .15s; }
.dz svg { width: 40px; height: 40px; color: var(--navy); margin-bottom: 4px; }
.dz:hover, .dz.is-over { border-color: var(--navy); background: var(--yellow-soft); }
.sr-only:focus-visible + .dz { outline: 3px solid rgba(244,194,13,.6); border-color: var(--navy); }
.dz-browse { color: var(--navy-700); text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.dz-meta { font-size: .8rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line); background: var(--white); border-radius: 999px; padding: 4px 10px; margin-top: 6px; }
.file-chip { display: flex; align-items: center; gap: 14px; border: 1px solid #BFE3CF; background: var(--ok-soft); border-radius: var(--radius-lg); padding: 14px 16px; }
.file-chip[hidden] { display: none; }
.file-ico { flex: none; width: 42px; height: 50px; border-radius: 4px; background: var(--white); border: 1px solid var(--line); display: grid; place-items: center; font: 700 .68rem/1 var(--font-text); color: var(--bad); letter-spacing: .04em; }
.file-info { min-width: 0; flex: 1; }
.file-info b { display: block; color: var(--ink); font-size: .95rem; overflow-wrap: anywhere; }
.file-info small { color: var(--ok); font-weight: 600; font-size: .82rem; }
.file-actions { display: flex; gap: 14px; flex: none; }
.file-actions .link-btn { color: var(--navy-700); }
.file-actions .link-btn.danger { color: var(--bad); }
@media (max-width: 480px) { .file-chip { flex-wrap: wrap; } .file-actions { width: 100%; padding-left: 56px; } }
.dz[hidden] { display: none; }
.field .dz-error { display: none; }
.field .dz-error.is-on { display: flex; }
.demo-link { background: none; border: 0; padding: 0; font: 500 .82rem/1.4 var(--font-text); color: var(--muted); text-decoration: underline dotted; text-underline-offset: 3px; cursor: pointer; justify-self: start; }

.choice > span, .choice .sub { display: block; }
.choice strong { color: var(--ink); font-weight: 600; }
.choice .sub { color: var(--muted); font-size: .85rem; margin-top: 2px; }
.choice-box { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }

/* CAPTCHA mock (Cloudflare Turnstile style) */
.captcha { width: 100%; max-width: 340px; justify-content: space-between; padding: 12px 14px; }
.ts-left { display: flex; align-items: center; gap: 12px; }
.ts-box { width: 26px; height: 26px; border: 2px solid var(--muted); border-radius: 4px; background: var(--white); cursor: pointer; display: grid; place-items: center; padding: 0; flex: none; }
.ts-box svg { width: 16px; height: 16px; display: none; }
.captcha.is-busy .ts-box { border-color: var(--line); border-top-color: var(--navy); border-radius: 50%; animation: spin .7s linear infinite; }
.captcha.is-ok .ts-box { border: 0; background: var(--ok); border-radius: 50%; }
.captcha.is-ok .ts-box svg { display: block; color: var(--white); }
@keyframes spin { to { transform: rotate(360deg); } }
.ts-brand { text-align: right; line-height: 1.15; }
.ts-brand b { display: block; font-size: .72rem; letter-spacing: .08em; color: var(--ink); }
.ts-brand small { font-size: .66rem; color: var(--muted); }

/* Submit */
.submit-bar { display: flex; flex-wrap: wrap; gap: 16px 20px; align-items: center; padding-top: 6px; }
.btn--lg { padding: 18px 32px; font-size: 1.05rem; }
.submit-bar p { margin: 0; flex: 1 1 240px; font-size: .88rem; color: var(--muted); }
.preview-link { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; border: 1px dashed var(--muted); border-radius: var(--radius-lg); padding: 16px 20px; color: var(--muted); font-size: .9rem; }
.preview-link a { font-weight: 600; }

/* Sidebar */
.side { display: grid; gap: 20px; position: sticky; top: 96px; }
@media (max-width: 960px) { .side { position: static; } }
.side h3 { font-size: 1.45rem; margin-bottom: 18px; }
.side h4 { font-family: var(--font-text); font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-bottom: 12px; }
.vsteps { list-style: none; margin: 0; padding: 0; display: grid; }
.vsteps li { display: grid; grid-template-columns: 32px minmax(0,1fr); gap: 14px; position: relative; padding-bottom: 22px; }
.vsteps li:last-child { padding-bottom: 0; }
.vsteps li:not(:last-child)::after { content: ""; position: absolute; left: 15px; top: 34px; bottom: 2px; width: 2px; background: var(--line); }
.vs-dot { width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--navy); color: var(--navy); background: var(--white); display: grid; place-items: center; font: 600 .95rem/1 var(--font-display); }
.vsteps li.is-now .vs-dot { background: var(--yellow); border-color: var(--yellow); color: var(--navy-900); }
.vsteps strong { display: block; color: var(--navy); font-size: .98rem; }
.vsteps p { margin: 2px 0 4px; font-size: .88rem; color: var(--text); line-height: 1.5; }
.vsteps .when { font-size: .78rem; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
.kv { margin: 0; display: grid; gap: 10px; font-size: .9rem; }
.kv div { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.kv div:last-child { border-bottom: 0; padding-bottom: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; text-align: right; }
.trust { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: .88rem; }
.trust li { display: flex; gap: 10px; align-items: flex-start; }
.trust svg { width: 18px; height: 18px; flex: none; color: var(--ok); margin-top: 2px; }

/* ---------- Gravity Forms: the call for papers form as in mocki/submit.html ----------
   Markup hooks: includes/gravity-forms-look.php. Colours and control sizes come from the style settings
   passed to gravity_form() (itfa_gf_style_settings), the rest is here. Everything sits under #cfp. */
#cfp .gform_wrapper.gform-theme--framework.gform-theme--orbital {
  --gf-color-danger: #B3261E; --gf-color-danger-rgb: 179, 38, 30;
  --gf-ctrl-label-color-req: #B3261E;
  margin: 0;
}
#cfp .gform-theme .gform_heading { margin: 0 0 20px; }
#cfp .gform-theme .gform_required_legend { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 0; font-size: .88rem; color: var(--muted); }
#cfp .gform-theme .gform_fields { row-gap: 20px; column-gap: 0; }

/* Section cards */
#cfp .itfa-fs { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(12, minmax(0,1fr)); column-gap: 20px; row-gap: 22px; align-items: start;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow); min-width: 0; }
#cfp .itfa-fs > .gfield { grid-column: 1 / -1; min-width: 0; }
#cfp .itfa-fs > .gfield--width-half { grid-column: span 6; }
#cfp .gform-theme .gsection { display: flex; gap: 16px; align-items: flex-start; margin: 0; padding: 0 0 18px; border-bottom: 1px solid var(--line); }
#cfp .gform-theme .gsection .fs-text { min-width: 0; }
#cfp .gform-theme .gsection_title { font: 500 1.6rem/1.15 var(--font-display); color: var(--navy); letter-spacing: -.01em; margin: 0 0 4px; }
#cfp .gform-theme .gsection_description { margin: 0; padding: 0; font-size: .92rem; line-height: 1.6; color: var(--muted); }
@media (max-width: 640px) {
  #cfp .itfa-fs { padding: 22px 18px; }
  #cfp .itfa-fs > .gfield--width-half { grid-column: 1 / -1; }
}

/* Labels, required marks, hints */
#cfp .gform-theme .gfield_label,
#cfp .gform-theme .gform-field-label--type-sub { font: 600 .92rem/1.4 var(--font-text); color: var(--ink); margin: 0 0 6px; padding: 0; }
/* The space before the mark comes from the markup itself. */
#cfp .gform-theme .gfield_required { color: var(--bad); margin: 0; padding: 0; font-size: inherit; font-weight: 600; }
#cfp .gform-theme .gfield--type-name.gfield_contains_required .gform-field-label--type-sub::after,
#cfp .gform-theme .itfa-coauthors .gfield_label::after { content: "*"; color: var(--bad); margin-left: 4px; }
#cfp .gform-theme .itfa-fs > .gfield--type-text:not(.gfield_contains_required) > .gfield_label::after { content: "optional"; margin-left: 6px; font-weight: 400; font-size: .82rem; color: var(--muted); }
#cfp .gform-theme .gfield_description { font-size: .82rem; line-height: 1.5; color: var(--muted); padding: 6px 0 0; }
#cfp .gform-theme .gfield_description.gfield_description--above,
#cfp .gform-theme .field_description_above .gfield_description { padding: 0 0 10px; }
#cfp .gform-theme .ginput_complex { row-gap: 22px; }

/* Text fields and the country list */
#cfp .gform-theme input[type=text], #cfp .gform-theme input[type=email], #cfp .gform-theme select, #cfp .gform-theme textarea {
  font-family: var(--font-text); font-size: 1rem; color: var(--ink); border-color: #C5CDD9; border-radius: var(--radius); box-shadow: none; }
#cfp .gform-theme input[type=text]:focus, #cfp .gform-theme input[type=email]:focus, #cfp .gform-theme select:focus, #cfp .gform-theme textarea:focus {
  outline: 3px solid rgba(244,194,13,.5); outline-offset: 0; border-color: var(--navy); box-shadow: none; }
#cfp .gform-theme input::placeholder { font-size: 1rem; color: #6B7480; opacity: 1; }
/* Session form: the description */
#cfp .gform-theme textarea { min-height: 120px; height: 150px; resize: vertical; line-height: 1.55; }
#cfp .gform-theme .ginput_counter { font-size: .82rem; color: var(--muted); padding-top: 6px; }

/* Category and submission type as option cards. The whole card picks the choice. */
#cfp .gform-theme .itfa-options .gfield_radio { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
@media (max-width: 640px) { #cfp .gform-theme .itfa-options .gfield_radio { grid-template-columns: minmax(0,1fr); } }
#cfp .gform-theme .itfa-options .gchoice { position: relative; display: flex; gap: 12px; align-items: flex-start; margin: 0; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; background: var(--white); transition: border-color .15s, box-shadow .15s; }
#cfp .gform-theme .itfa-options .gchoice:hover { border-color: var(--muted); }
#cfp .gform-theme .itfa-options .gchoice:has(input:checked) { border-color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); background: var(--paper); }
#cfp .gform-theme .itfa-options .gchoice label { font: 600 .95rem/1.4 var(--font-text); color: var(--ink); cursor: pointer; margin: 0; }
#cfp .gform-theme .itfa-options .gchoice label::before { content: ""; position: absolute; inset: 0; }
#cfp .gform-theme .choice-note { display: block; font-weight: 400; font-size: .84rem; line-height: 1.45; color: var(--muted); margin-top: 2px; }

/* Checkboxes: None, discussant, consents */
#cfp .gform-theme .gfield--type-checkbox .gchoice,
#cfp .gform-theme .ginput_container_consent { display: flex; gap: 10px; align-items: flex-start; }
#cfp .gform-theme .gfield--type-checkbox .gchoice label,
#cfp .gform-theme .gfield_consent_label { font: 600 .95rem/1.45 var(--font-text); color: var(--ink); margin: 0; padding: 0; }
#cfp .gform-theme .itfa-coauthors .gchoice,
#cfp .gform-theme .itfa-boxed { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
#cfp .gform-theme .itfa-boxed .gfield_description,
#cfp .gform-theme .gfield_consent_description { padding: 2px 0 0 calc(var(--gf-ctrl-choice-size, 20px) + 10px); }
#cfp .gform-theme .gfield_consent_description { margin: 0; border: 0; background: none; max-height: none; overflow: visible; font-size: .85rem; line-height: 1.5; color: var(--muted); }
#cfp .gform-theme .gfield_consent_description_text { border: 0; padding: 0; margin: 0; max-height: none; overflow: visible; background: none; }
#cfp .itfa-fs > .itfa-consent { margin-top: -6px; }

/* Co-author rows: one card per row, labels inside, "Remove" top right, one "Add" button under the list */
#cfp .gform-theme .itfa-corows > .gfield_label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
#cfp .itfa-fs > .itfa-coauthors + .itfa-corows { margin-top: -10px; }
#cfp .gform-theme .itfa-corows .gfield_list_header { display: none; }
#cfp .gform-theme .itfa-corows .gfield_list_groups { display: grid; gap: 12px; counter-reset: coauthor; }
#cfp .gform-theme .itfa-corows .gfield_list_group { counter-increment: coauthor; position: relative; display: grid; grid-template-columns: 1.1fr 1.2fr 1fr; gap: 12px; margin: 0;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); padding: 40px 16px 16px; }
#cfp .gform-theme .itfa-corows .gfield_list_group::before { content: "Co-author " counter(coauthor); position: absolute; top: 15px; left: 16px; font: 600 .75rem/1 var(--font-text); letter-spacing: .1em; text-transform: uppercase; color: var(--navy); }
#cfp .gform-theme .itfa-corows .gfield_list_group:last-child { margin-bottom: 50px; }
#cfp .gform-theme .itfa-corows .gfield_list_cell { padding: 0; margin: 0; max-width: none; width: auto; flex: none; }
#cfp .gform-theme .itfa-corows .gfield_list_cell::before { content: attr(data-label); display: block; font: 600 .8rem/1.4 var(--font-text); color: var(--muted); margin-bottom: 4px; }
#cfp .gform-theme .itfa-corows .gfield_list_cell input { padding: 10px 12px; }
#cfp .gform-theme .itfa-corows .gfield_list_icons { display: contents; }
#cfp .gform-theme .itfa-corows .delete_list_item { position: absolute; top: 9px; right: 12px; width: auto; height: auto; padding: 4px; background: none; border: 0; box-shadow: none;
  font: 600 .82rem/1 var(--font-text); color: var(--bad); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
#cfp .gform-theme .itfa-corows .delete_list_item::before,
#cfp .gform-theme .itfa-corows .add_list_item::before { content: none; }
#cfp .gform-theme .itfa-corows .gfield_list_group:not(:last-child) .add_list_item { display: none; }
#cfp .gform-theme .itfa-corows .add_list_item { position: absolute; left: 0; bottom: -50px; width: auto; height: auto; padding: 9px 14px; margin: 0;
  background: transparent; border: 2px solid var(--navy); border-radius: var(--radius); box-shadow: none; color: var(--navy); font: 600 0/1 var(--font-text); cursor: pointer; }
/* Gravity Forms forces its icon font on this button with !important, so the label needs one too. */
#cfp .gform-theme .itfa-corows .add_list_item::after { content: "+ Add another co-author"; font: 600 .85rem/1 var(--font-text); font-family: var(--font-text) !important; letter-spacing: 0; }
#cfp .gform-theme .itfa-corows .add_list_item:hover { background: var(--navy); color: var(--white); }
@media (max-width: 760px) { #cfp .gform-theme .itfa-corows .gfield_list_group { grid-template-columns: minmax(0,1fr); } }

/* PDF drop zone. The size limit is shown as a pill inside the zone; the long rules line stays for screen readers. */
#cfp .gform-theme .itfa-dropzone .gform_drop_area { display: block; text-align: center; padding: 28px; border: 2px dashed #C5CDD9; border-radius: var(--radius-lg); background: var(--paper); color: var(--muted); box-shadow: none; transition: border-color .15s, background .15s; }
#cfp .gform-theme .itfa-dropzone .gform_drop_area:hover,
#cfp .gform-theme .itfa-dropzone .gform_drop_area.hover { border-color: var(--navy); background: var(--yellow-soft); }
#cfp .gform-theme .itfa-dropzone .dz-icon { display: block; width: 40px; height: 40px; margin: 0 auto 10px; color: var(--navy); }
#cfp .gform-theme .itfa-dropzone .gform_drop_instructions { display: inline; margin: 0; font-size: 1rem; color: var(--navy); }
#cfp .gform-theme .itfa-dropzone .gform_drop_instructions strong { font-weight: 600; }
#cfp .gform-theme .itfa-dropzone .gform_button_select_files { display: inline; width: auto; height: auto; min-height: 0; padding: 0; margin: 0; background: none; border: 0; box-shadow: none;
  font: 600 1rem/1.4 var(--font-text); color: var(--navy-700); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
#cfp .gform-theme .itfa-dropzone .gform_drop_area::before { content: none; display: none; }
#cfp .gform-theme .itfa-dropzone .dz-meta { display: table; margin: 12px auto 0; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--white);
  font: 600 .8rem/1.4 var(--font-text); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
#cfp .gform-theme .itfa-dropzone .gform_fileupload_rules,
#cfp .gform-theme .itfa-dropzone > .gfield_description { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
/* Gravity Forms leaves an empty preview item after a rejected file, so only a real file counts. Otherwise the drop zone
   and the error were hidden and the author saw an empty green chip, as if the upload had worked. */
#cfp .gform-theme .itfa-dropzone:has(.ginput_preview:not(:empty)) .gform_drop_area { display: none; }
#cfp .gform-theme .itfa-dropzone .ginput_preview_list { margin: 0; }
/* After the upload: a chip with the file, as in the mockup. One file only, so the "maximum reached" note is noise. */
#cfp .gform-theme .itfa-dropzone:has(.ginput_preview:not(:empty)) .validation_message--hidden-on-empty { display: none; }
#cfp .gform-theme .itfa-dropzone .ginput_preview:empty { display: none; }
#cfp .gform-theme .itfa-dropzone .ginput_preview { display: grid; grid-template-columns: 42px minmax(0,1fr) auto; column-gap: 14px; row-gap: 2px; align-items: center; margin: 0;
  border: 1px solid #BFE3CF; background: var(--ok-soft); border-radius: var(--radius-lg); padding: 14px 16px; text-align: left; }
#cfp .gform-theme .itfa-dropzone .ginput_preview::before { content: "PDF"; grid-column: 1; grid-row: 1 / span 2; width: 42px; height: 50px; border-radius: 4px; background: var(--white); border: 1px solid var(--line);
  display: grid; place-items: center; font: 700 .68rem/1 var(--font-text); color: var(--bad); letter-spacing: .04em; }
#cfp .gform-theme .itfa-dropzone .gfield_fileupload_filename { grid-column: 2; grid-row: 1; align-self: end; font: 600 .95rem/1.4 var(--font-text); color: var(--ink); overflow-wrap: anywhere; margin: 0; padding: 0; }
#cfp .gform-theme .itfa-dropzone .gfield_fileupload_filesize,
#cfp .gform-theme .itfa-dropzone .gfield_fileupload_progress { grid-column: 2; grid-row: 2; align-self: start; margin: 0; padding: 0; }
#cfp .gform-theme .itfa-dropzone .gfield_fileupload_filesize { font: 600 .82rem/1.4 var(--font-text); color: var(--ok); }
#cfp .gform-theme .itfa-dropzone .ginput_preview:has(.gfield_fileupload_progress_complete) .gfield_fileupload_filesize::after { content: " · Uploaded"; }
#cfp .gform-theme .itfa-dropzone .gfield_fileupload_progress_complete { display: none; }
#cfp .gform-theme .itfa-dropzone .gfield_fileupload_progress:not(.gfield_fileupload_progress_complete) { justify-self: end; }
#cfp .gform-theme .itfa-dropzone .gform_delete_file { grid-column: 3; grid-row: 1 / span 2; width: auto; height: auto; min-height: 0; padding: 4px 0; margin: 0; background: none; border: 0; box-shadow: none; color: var(--bad); cursor: pointer; }
#cfp .gform-theme .itfa-dropzone .gform_delete_file .dashicons { display: none; }
#cfp .gform-theme .itfa-dropzone .gform_delete_file::after { content: "Remove"; color: var(--bad); font: 600 .82rem/1 var(--font-text); font-family: var(--font-text) !important; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 480px) { #cfp .gform-theme .itfa-dropzone .gform_delete_file { grid-column: 2; grid-row: 3; justify-self: start; } }

/* Security check (Cloudflare Turnstile): label with the mark, the widget as wide as in the mockup, the note under it.
   The widget draws itself in a Cloudflare iframe; 65px is its height, kept free so the button does not jump when it loads. */
#cfp .gform-theme .itfa-captcha .gfield_label { display: block; }
#cfp .gform-theme .itfa-captcha .ginput_container_turnstile { max-width: 340px; }
#cfp .gform-theme .itfa-captcha .cf-turnstile { min-height: 65px; }
/* Cloudflare never draws the widget narrower than 300px. Below 360px the card is narrower, so the page would scroll
   sideways (320px: 15px). The widget is scaled down there instead; it stays clickable. */
@media (max-width: 359px) {
  #cfp .gform-theme .itfa-captcha .cf-turnstile { transform: scale(.83); transform-origin: left top; margin-bottom: -11px; }
}

/* Submit: the button and the note side by side at the bottom of the last card */
#cfp .itfa-fs:last-child { border-bottom: 0; border-bottom-left-radius: 0; border-bottom-right-radius: 0; padding-bottom: 22px; clip-path: inset(-24px -24px 0 -24px); }
/* margin-top -1px covers the sub-pixel seam between the card and the footer. */
#cfp .gform-theme .gform_footer { position: relative; display: flex; flex-wrap: wrap; gap: 16px 20px; align-items: center; margin: -1px 0 0; padding: 7px 32px 32px;
  background: var(--white); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 var(--radius-lg) var(--radius-lg); box-shadow: var(--shadow); clip-path: inset(0 -24px -24px -24px); }
@media (max-width: 640px) {
  #cfp .itfa-fs:last-child { padding-bottom: 22px; }
  #cfp .gform-theme .gform_footer { padding: 6px 18px 22px; }
}
#cfp .gform-theme .gform_footer .gform_button { font: 600 1.05rem/1 var(--font-text); padding: 18px 32px; min-height: 0; height: auto; border: 2px solid transparent; border-radius: var(--radius); background: var(--yellow); color: var(--navy-900); box-shadow: none; }
#cfp .gform-theme .gform_footer .gform_button:hover { background: #FFD233; color: var(--navy-900); }
#cfp .gform-theme .gform_footer .submit-note { margin: 0; flex: 1 1 240px; font-size: .88rem; line-height: 1.6; color: var(--muted); }

/* Session form (?type=session): one block per paper inside the "Papers" card, papers 4 and 5 behind a tick box */
.other-form { margin: 18px 0 0; font-size: .95rem; color: #DCE4F0; }
.other-form a { color: var(--yellow); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
/* "Paper 2: " in front of each label, for screen readers only. Gravity Forms' theme resets spans inside labels, so the
   general .sr-only rule above loses there. */
#cfp .gform-theme .gfield_label .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); clip-path: inset(50%); white-space: nowrap; border: 0; }
#cfp .itfa-fs > .itfa-paper-head { margin-top: 8px; padding-top: 26px; border-top: 1px solid var(--line); }
#cfp .itfa-fs > .gsection + .itfa-paper-head { margin-top: 0; padding-top: 0; border-top: 0; }
#cfp .gform-theme .paper-head { display: flex; align-items: baseline; gap: 10px; margin: 0; font: 500 1.3rem/1.2 var(--font-display); color: var(--navy); }
#cfp .gform-theme .paper-head .paper-opt { font: 400 .82rem/1 var(--font-text); color: var(--muted); }
#cfp .gform-theme .itfa-paper-toggle { background: var(--paper); }
#cfp .gform-theme .itfa-paper-toggle .gchoice label { font-weight: 600; color: var(--navy); }
#cfp .cfp-thanks .summary .papers { margin: 0; padding-left: 1.2em; display: grid; gap: 10px; }
#cfp .cfp-thanks .summary .papers small { color: var(--muted); font-size: .88rem; }

/* Errors: red frame on the field, short red line under it */
#cfp .gform-theme .gfield_error input[type=text], #cfp .gform-theme .gfield_error input[type=email], #cfp .gform-theme .gfield_error select, #cfp .gform-theme .gfield_error textarea { border-color: var(--bad); box-shadow: inset 0 0 0 1px var(--bad); }
#cfp .gform-theme .gfield_validation_message, #cfp .gform-theme .validation_message { display: flex; gap: 8px; align-items: flex-start; margin: 0; padding: 6px 0 0; border: 0; background: none; color: var(--bad); font-size: .85rem; font-weight: 500; }
#cfp .gform-theme .gform_validation_errors { border: 1px solid #F2C4C0; background: var(--bad-soft); border-radius: var(--radius-lg); box-shadow: none; margin: 0 0 20px; }

/* Confirmation after Submit, as in mocki/submit-thanks.html. Markup: the form's confirmation (tools/cfp-form.php).
   Icons are CSS masks, because the confirmation text goes through WordPress content filters. */
#cfp .cfp-thanks { color: var(--text); font-size: 1rem; line-height: 1.6; }
#cfp .cfp-thanks .confirm { background: var(--white); border: 1px solid var(--line); border-top: 4px solid var(--ok); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: 48px 40px 40px; text-align: center; }
#cfp .cfp-thanks .big-check { width: 84px; height: 84px; border-radius: 50%; background: var(--ok-soft); display: grid; place-items: center; margin: 0 auto 24px; box-shadow: 0 0 0 10px rgba(30,122,76,.06); animation: itfa-pop .5s cubic-bezier(.2,1.4,.4,1) both; }
#cfp .cfp-thanks .big-check::before { content: ""; width: 44px; height: 44px; background: var(--ok);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/contain no-repeat; }
@keyframes itfa-pop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { #cfp .cfp-thanks .big-check { animation: none; } }
#cfp .cfp-thanks .eyebrow { display: block; margin: 0 0 .75rem; }
#cfp .cfp-thanks h2 { font: 500 clamp(1.9rem, 4.4vw, 2.6rem)/1.15 var(--font-display); color: var(--navy); letter-spacing: -.01em; max-width: 20ch; margin: 0 auto .4em; }
/* submit.js moves focus to the heading after sending, so screen readers start there. It is not a control: no ring. */
#cfp .cfp-thanks h2:focus { outline: none; }
#cfp .cfp-thanks .lead { margin: 0 auto; font-size: 1.05rem; color: var(--text); }
#cfp .cfp-thanks .ref { margin: 32px auto 0; display: inline-grid; gap: 6px; justify-items: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px 28px; }
#cfp .cfp-thanks .ref-label { font: 600 .72rem/1 var(--font-text); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
#cfp .cfp-thanks .ref-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center; }
#cfp .cfp-thanks .ref-num { font: 500 clamp(1.5rem, 5vw, 2rem)/1.1 var(--font-display); color: var(--navy); letter-spacing: .02em; }
#cfp .cfp-thanks .copy-btn { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); font: 600 .8rem/1 var(--font-text); color: var(--navy); padding: 8px 12px; cursor: pointer; }
#cfp .cfp-thanks .copy-btn:hover { border-color: var(--navy); }
#cfp .cfp-thanks .mail-line { display: flex; gap: 12px; align-items: flex-start; text-align: left; margin: 28px auto 0; max-width: 560px; background: var(--ok-soft); border: 1px solid #BFE3CF; border-radius: var(--radius-lg); padding: 14px 18px; font-size: .95rem; color: var(--ink); }
#cfp .cfp-thanks .mail-line::before { content: ""; flex: none; width: 22px; height: 22px; margin-top: 2px; background: var(--ok);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M3 7l9 6 9-6'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M3 7l9 6 9-6'/%3E%3C/svg%3E") center/contain no-repeat; }
#cfp .cfp-thanks .mail-line small { display: block; color: var(--muted); font-size: .84rem; margin-top: 2px; }
#cfp .cfp-thanks h3 { font: 500 1.7rem/1.15 var(--font-display); color: var(--navy); margin: 40px 0 16px; }
#cfp .cfp-thanks .summary { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); margin: 0; }
#cfp .cfp-thanks .summary > div { display: grid; grid-template-columns: 180px minmax(0,1fr); gap: 16px; padding: 14px 22px; border-bottom: 1px solid var(--line); }
#cfp .cfp-thanks .summary > div:last-child { border-bottom: 0; }
#cfp .cfp-thanks .summary dt { font-size: .85rem; font-weight: 600; color: var(--muted); }
#cfp .cfp-thanks .summary dd { margin: 0; color: var(--ink); overflow-wrap: anywhere; }
#cfp .cfp-thanks .summary dd em { color: var(--navy); font-family: var(--font-display); font-size: 1.12rem; font-style: normal; }
#cfp .cfp-thanks .pdf-pill { display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; }
#cfp .cfp-thanks .pdf-pill b { font: 700 .62rem/1 var(--font-text); color: var(--bad); border: 1px solid var(--line); border-radius: 3px; padding: 4px 5px; background: var(--white); }
#cfp .cfp-thanks .actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin: 40px 0 0; }
#cfp .cfp-thanks .help { text-align: center; font-size: .9rem; color: var(--muted); margin: 20px 0 0; }
@media (max-width: 640px) {
  #cfp .cfp-thanks .confirm { padding: 36px 20px 28px; }
  #cfp .cfp-thanks .ref { padding: 16px 18px; }
  #cfp .cfp-thanks .summary > div { grid-template-columns: minmax(0,1fr); gap: 2px; padding: 12px 16px; }
}
