:root {
  --fest-ink: #1f1c1a;
  --fest-muted: #6b6560;
  --fest-line: #ebe4dc;
  --fest-bg: #f3efe9;
  --fest-card: #ffffff;
  --fest-soft: #faf7f3;
  --fest-accent: #d68352;
  --fest-accent-soft: #c06e3d;
  --fest-font: "Outfit", "Segoe UI", sans-serif;
  --fest-shadow: 0 10px 30px rgba(40, 30, 20, 0.06);
}

* { box-sizing: border-box; }

body.fest-body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(800px 320px at 50% -80px, rgba(214, 131, 82, 0.10), transparent 60%),
    var(--fest-bg);
  color: var(--fest-ink);
  font-family: var(--fest-font);
  font-size: 17.5px;
  font-weight: 400;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.fest-shell {
  width: min(1140px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 72px;
}

.fest-shell--thanks {
  padding-top: 72px;
  width: min(720px, calc(100% - 32px));
}

.fest-banner {
  position: relative;
  width: 100%;
  min-height: 190px;
  border: 1px solid var(--fest-line);
  border-bottom: none;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
  background: #dbdbdb;
  box-shadow: var(--fest-shadow);
}

.fest-banner__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fest-banner__overlay {
  position: absolute;
  inset: 0;
  background: #dbdbdb;
}

.fest-banner__inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 190px;
  padding: 28px 32px;
}

.fest-banner__logo {
  display: block;
  height: 92px;
  width: auto;
  max-width: 340px;
  object-fit: contain;
}

.fest-banner__partners {
  display: block;
  height: auto;
  width: min(420px, 48vw);
  max-width: 100%;
  object-fit: contain;
}

.fest-form {
  background: var(--fest-card);
  border: 1px solid var(--fest-line);
  border-radius: 0 0 12px 12px;
  padding: 0 0 34px;
  box-shadow: var(--fest-shadow);
}

.fest-alert {
  margin: 0 0 14px;
  padding: 14px 16px;
  border: 1px solid #f0c8c4;
  border-left: 3px solid #d93025;
  border-radius: 8px;
  background: #fff8f7;
  color: #5c2b27;
  font-size: 15.5px;
  font-weight: 400;
}

.fest-alert ul {
  margin: 8px 0 0;
  padding-left: 18px;
}

.fest-intro-block {
  padding: 30px 28px 24px;
  border-bottom: 1px solid var(--fest-line);
  border-top: 4px solid var(--fest-accent);
  background: linear-gradient(180deg, #fffaf6 0%, #ffffff 100%);
}

.fest-eyebrow {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fest-accent);
}

.fest-title {
  margin: 0 0 8px;
  font-size: clamp(28px, 3.2vw, 34px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--fest-ink);
}

.fest-subtitle {
  margin: 0 0 14px;
  font-size: 20px;
  font-weight: 400;
  color: var(--fest-accent-soft);
}

.fest-intro {
  margin: 0 0 10px;
  max-width: 88ch;
  color: #4a4440;
  font-size: 16.5px;
  font-weight: 400;
  line-height: 1.65;
}

.fest-intro:last-of-type {
  margin-bottom: 0;
}

.fest-required-note {
  margin: 14px 0 0;
  color: #d93025;
  font-size: 15px;
  font-weight: 400;
}

.fest-section {
  margin: 0;
  padding: 26px 28px 22px;
  border-bottom: 1px solid var(--fest-line);
}

.fest-section:last-of-type {
  border-bottom: none;
}

.fest-section--conditional {
  background: var(--fest-soft);
}

.fest-row[hidden],
.fest-field[hidden],
.fest-section--conditional[hidden] {
  display: none !important;
}

.fest-section__head {
  display: block;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f0ebe5;
}

.fest-section__title {
  margin: 0;
  font-size: 22px;
  font-weight: 500;
  color: #d68352;
  line-height: 1.3;
}

.fest-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.fest-row--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.fest-field {
  margin-bottom: 14px;
  min-width: 0;
}

.fest-row .fest-field {
  margin-bottom: 0;
}

.fest-field--span-2 { grid-column: span 2; }
.fest-field--span-3 { grid-column: span 3; }
.fest-field--span-4 { grid-column: span 4; }

.fest-field--nested {
  margin-bottom: 14px;
  padding: 14px;
  background: var(--fest-soft);
  border: 1px solid var(--fest-line);
  border-radius: 8px;
}

.fest-label {
  display: block;
  margin-bottom: 8px;
  font-size: 16px;
  font-weight: 400;
  color: #000000;
  line-height: 1.35;
  letter-spacing: 0.01em;
}

.fest-req {
  color: #d93025 !important;
}

.fest-declare .fest-req {
  color: #d93025 !important;
}

.fest-help,
.fest-note {
  margin: -2px 0 10px;
  font-size: 14.5px;
  font-weight: 400;
  color: #d68352;
  line-height: 1.45;
}

.fest-note {
  margin: 12px 0 0;
  padding: 11px 13px;
  background: #faf7f3;
  border: 1px solid var(--fest-line);
  border-left: 3px solid var(--fest-accent);
  border-radius: 8px;
  color: #d68352;
}

.fest-input,
.fest-select,
.fest-textarea {
  width: 100%;
  font: inherit;
  font-size: 16px;
  font-weight: 400;
  color: var(--fest-ink);
  background-color: #fff;
  border: 1px solid #d9d0c7;
  border-radius: 8px;
  padding: 12px 13px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.iti {
  --iti-path-flags-1x: url("/vendor/intl-tel-input/img/flags.png");
  --iti-path-flags-2x: url("/vendor/intl-tel-input/img/flags@2x.png");
  width: 100%;
}

.iti--separate-dial-code .fest-input {
  padding-left: 102px !important;
}

.iti__selected-flag {
  background: #fff9f4;
  border-right: 1px solid #d9d0c7;
}

.iti__dial-code {
  color: #6e655d;
}

.iti__country-list {
  z-index: 1200;
}

.fest-input:hover,
.fest-select:hover,
.fest-textarea:hover {
  background-color: #fff;
  border-color: #c9bdb1;
}

.fest-input:focus,
.fest-select:focus,
.fest-textarea:focus {
  background-color: #fff;
  border-color: var(--fest-accent);
  box-shadow: 0 0 0 3px rgba(214, 131, 82, 0.14);
}

.fest-select {
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b6560' d='M1.4.6 6 5.2 10.6.6 12 2 6 8 0 2z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 8px;
  padding-right: 36px;
  cursor: pointer;
}

.fest-select:hover,
.fest-select:focus,
.fest-select:active {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b6560' d='M1.4.6 6 5.2 10.6.6 12 2 6 8 0 2z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 8px;
}

.fest-textarea {
  resize: vertical;
  min-height: 110px;
  line-height: 1.5;
}

.fest-checks,
.fest-radios {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px 14px;
  align-items: start;
}

.fest-checks--programs {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.fest-radios {
  grid-template-columns: auto auto;
  justify-content: start;
  gap: 6px 18px;
}

.fest-check,
.fest-radio,
.fest-declare {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 4px 2px;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}

.fest-check:hover,
.fest-radio:hover,
.fest-check--program:hover {
  background: var(--fest-soft);
  border-color: transparent;
}

.fest-check:has(input:checked),
.fest-radio:has(input:checked),
.fest-check--program:has(input:checked) {
  background: rgba(214, 131, 82, 0.08);
  border-color: transparent;
}

.fest-check input,
.fest-radio input,
.fest-declare input {
  -webkit-appearance: none;
  appearance: none;
  margin: 2px 0 0;
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  border: 1.5px solid #c4bbb2;
  border-radius: 3px;
  background-color: #fff;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 10px;
  cursor: pointer;
  position: relative;
  transition: border-color 0.12s ease, background-color 0.12s ease;
}

.fest-radio input {
  border-radius: 50%;
}

.fest-check input:checked,
.fest-declare input:checked {
  background-color: var(--fest-accent);
  border-color: var(--fest-accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath fill='none' stroke='%23ffffff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round' d='M2.5 6.2 5 8.7 9.5 3.5'/%3E%3C/svg%3E");
}

.fest-radio input:checked {
  background-color: var(--fest-accent);
  border-color: var(--fest-accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Ccircle cx='6' cy='6' r='2.6' fill='%23ffffff'/%3E%3C/svg%3E");
}

.fest-check span,
.fest-radio span {
  font-size: 15px;
  line-height: 1.4;
  color: #333;
  font-weight: 400;
  padding-top: 1px;
}

.fest-declares {
  display: grid;
  gap: 6px;
}

.fest-declare {
  padding: 8px 10px;
  background: var(--fest-soft);
  border-color: var(--fest-line);
}

.fest-declare:hover {
  background: #f5f1eb;
}

.fest-declare:has(input:checked) {
  background: rgba(214, 131, 82, 0.08);
  border-color: rgba(214, 131, 82, 0.28);
}

.fest-declare span {
  font-size: 15.5px;
  line-height: 1.5;
  color: #333;
  font-weight: 400;
}

.fest-error {
  display: none;
  margin-top: 5px;
  color: #d93025;
  font-size: 14px;
  font-weight: 400;
}

.fest-field.is-invalid .fest-error {
  display: block;
}

.fest-field.is-invalid .fest-input,
.fest-field.is-invalid .fest-select,
.fest-field.is-invalid .fest-textarea {
  border-color: #d93025;
  background-color: #fff8f7;
}

.fest-field.is-invalid .fest-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b6560' d='M1.4.6 6 5.2 10.6.6 12 2 6 8 0 2z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 8px;
}

.fest-field.is-invalid .iti__selected-flag {
  border-color: #d93025;
}

.fest-declare.is-invalid {
  border-color: #d93025;
}

.fest-submit-bar {
  display: flex;
  justify-content: flex-start;
  padding: 10px 28px 0;
}

.fest-btn {
  appearance: none;
  border: none;
  background: var(--fest-accent);
  color: #fff;
  border-radius: 8px;
  padding: 13px 26px;
  font: inherit;
  font-size: 16.5px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(214, 131, 82, 0.22);
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.fest-btn--submit:hover {
  background: var(--fest-accent-soft);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(214, 131, 82, 0.28);
}

.fest-thanks {
  position: relative;
  background: #fff;
  border: 1px solid var(--fest-line);
  border-radius: 14px;
  padding: 48px 44px 40px;
  box-shadow: 0 16px 40px rgba(40, 30, 20, 0.08);
  text-align: center;
  overflow: hidden;
}

.fest-thanks::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 4px;
  background: var(--fest-accent);
}

.fest-thanks__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(214, 131, 82, 0.12);
  color: var(--fest-accent);
}

.fest-thanks .fest-eyebrow {
  margin-bottom: 10px;
}

.fest-thanks .fest-title {
  margin: 0 auto 18px;
  max-width: 100%;
  font-family: auto;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 500;
  line-height: 1.22;
  white-space: nowrap;
}

.fest-thanks__body {
  max-width: 58ch;
  margin: 0 auto;
  text-align: justify;
  padding: 18px 20px;
  background: #faf7f3;
  border: 1px solid #eee4da;
  border-radius: 12px;
}

.fest-thanks__body .fest-intro {
  margin: 0 0 12px;
  font-size: 16px;
  line-height: 1.65;
  color: #4a4440;
}

.fest-thanks__body .fest-intro:last-child {
  margin-bottom: 0;
}

.fest-ref {
  margin: 0 auto 22px;
  padding: 10px 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f7efe8;
  border: 1px solid rgba(214, 131, 82, 0.22);
  border-radius: 999px;
  font-size: 15px;
  color: var(--fest-accent-soft);
  font-weight: 400;
}

.fest-ref strong {
  font-weight: 600;
  color: var(--fest-ink);
  letter-spacing: 0.02em;
}

.fest-thanks__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px 14px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid #f0ebe5;
}

.fest-thanks__link {
  color: #666;
  font-size: 15.5px;
  font-weight: 400;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.fest-thanks__link:hover {
  color: var(--fest-ink);
  border-bottom-color: #cbbdb3;
}

.fest-thanks__link--accent {
  color: var(--fest-accent);
  font-weight: 500;
}

.fest-thanks__link--accent:hover {
  color: var(--fest-accent-soft);
  border-bottom-color: var(--fest-accent);
}

.fest-thanks__sep {
  color: #c4bbb2;
  font-size: 14px;
  line-height: 1;
}

@media (max-width: 1300px) {
  .fest-label {
    font-size: 18px;
    line-height: 1.38;
  }

  .fest-check span,
  .fest-radio span {
    font-size: 16px;
    line-height: 1.45;
  }

  .fest-help,
  .fest-note {
    font-size: 15.5px;
  }
}

@media (max-width: 1100px) {
  .fest-row,
  .fest-checks,
  .fest-checks--programs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fest-field--span-2,
  .fest-field--span-3,
  .fest-field--span-4 {
    grid-column: span 2;
  }
}

@media (max-width: 980px) {
  .fest-shell--thanks {
    width: min(92vw, 720px);
    padding-top: 24px;
  }

  .fest-thanks {
    padding: 40px 28px 34px;
  }

  .fest-thanks .fest-title {
    font-size: clamp(20px, 5.1vw, 28px);
  }

  .fest-thanks__body {
    max-width: 100%;
    padding: 16px;
  }
}

@media (max-width: 760px) {
  .fest-shell {
    width: calc(100% - 16px);
    padding: 14px 0 56px;
  }

  .fest-shell--thanks {
    width: calc(100% - 16px);
    padding-top: 18px;
  }

  .fest-banner__inner {
    flex-direction: column;
    align-items: flex-start;
    padding: 22px 18px;
    min-height: 160px;
  }

  .fest-banner__logo {
    height: 72px;
    max-width: 280px;
  }

  .fest-banner__partners {
    width: min(100%, 360px);
  }

  .fest-intro-block,
  .fest-section,
  .fest-submit-bar {
    padding-left: 16px;
    padding-right: 16px;
  }

  .fest-row,
  .fest-row--2,
  .fest-checks,
  .fest-checks--programs {
    grid-template-columns: 1fr;
  }

  .fest-field--span-2,
  .fest-field--span-3,
  .fest-field--span-4 {
    grid-column: span 1;
  }

  .fest-btn--submit {
    width: 100%;
  }

  .fest-thanks {
    padding: 34px 18px 28px;
    border-radius: 12px;
  }

  .fest-thanks__body {
    padding: 14px;
  }

  .fest-thanks__actions {
    flex-direction: column;
    gap: 12px;
    padding-top: 16px;
  }

  .fest-thanks__sep {
    display: none;
  }
}

@media (max-width: 425px) {
  .fest-banner__inner {
    align-items: center;
  }

  .fest-banner__left {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .fest-banner__logo {
    margin-left: auto;
    margin-right: auto;
  }
}
