:root {
  --ec-dark: #1a1715;
  --ec-gray: #5f5c58;
  --ec-light-gray: #97928c;
  --ec-terracotta: #d76953;
  --ec-terracotta-dark: #bf5340;
  --ec-light-terracotta: #fdeae3;
  --ec-beige: #f4f2ec;
  --ec-line: #e7e3dc;
  --ec-white: #ffffff;
  --ec-error: #b42318;
  --ec-success: #047a4e;
  --ec-radius: 18px;
  --ec-radius-lg: 26px;
  --ec-shadow-sm: 0 4px 16px rgba(26, 23, 21, 0.05);
  --ec-shadow-md: 0 18px 44px rgba(26, 23, 21, 0.07);
  --ec-shadow-accent: 0 14px 28px rgba(215, 105, 83, 0.28);
}

* { box-sizing: border-box; }
body.ec-body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ec-dark);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background:
    radial-gradient(1100px 480px at 90% -8%, rgba(215, 105, 83, 0.10), transparent 60%),
    radial-gradient(900px 420px at -5% 0%, rgba(215, 105, 83, 0.08), transparent 55%),
    linear-gradient(180deg, #fbfaf7 0%, var(--ec-beige) 100%);
  background-attachment: fixed;
}
.ec-body-embed { background: transparent; }
.ec-shell { padding: 28px 16px 56px; }
.ec-hero {
  position: relative;
  max-width: 1120px;
  margin: 0 auto 22px;
  padding: 34px 36px;
  border-radius: var(--ec-radius-lg);
  background: linear-gradient(135deg, #fff7f3 0%, #ffffff 52%, #f6efe9 100%);
  border: 1px solid rgba(215, 105, 83, 0.16);
  box-shadow: var(--ec-shadow-md);
  overflow: hidden;
}
.ec-hero::after {
  content: "";
  position: absolute;
  inset: auto -80px -120px auto;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(215, 105, 83, 0.14), transparent 70%);
  pointer-events: none;
}
.ec-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--ec-light-terracotta);
  color: var(--ec-terracotta-dark);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.ec-hero-badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ec-terracotta);
}
.ec-hero h1 { margin: 16px 0 10px; font-size: clamp(28px, 4vw, 44px); letter-spacing: -0.02em; line-height: 1.1; }
.ec-hero p { margin: 0; max-width: 760px; color: var(--ec-gray); line-height: 1.7; }
.ec-container { max-width: 1120px; margin: 0 auto; }
.ec-form, .ec-success-screen { display: grid; gap: 16px; }
.ec-stepper {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(25, 24, 24, 0.06);
  box-shadow: 0 14px 40px rgba(25, 24, 24, 0.05);
  border-radius: 24px;
  padding: 22px;
  backdrop-filter: blur(12px);
}
.ec-stepper-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: end;
}
.ec-stepper-head h2 { margin: 8px 0 6px; font-size: 26px; }
.ec-stepper-head p { margin: 0; color: var(--ec-gray); max-width: 680px; line-height: 1.6; }
.ec-stepper-badge {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--ec-light-terracotta);
  color: var(--ec-terracotta);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.ec-stepper-status {
  min-width: 240px;
  display: grid;
  gap: 10px;
}
.ec-stepper-status-label {
  text-align: right;
  color: var(--ec-gray);
  font-size: 14px;
  font-weight: 700;
}
.ec-progress {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: #efeae3;
  overflow: hidden;
}
.ec-progress span {
  display: block;
  width: 12.5%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--ec-terracotta), #e58d78);
  transition: width .25s ease;
}
.ec-stepper-tabs {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}
.ec-step-tab {
  min-height: 62px;
  border: 1px solid var(--ec-line);
  border-radius: 16px;
  background: #fff;
  color: var(--ec-gray);
  font-weight: 700;
  cursor: pointer;
  transition: all .2s ease;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 10px 12px;
  text-align: left;
}
.ec-step-tab-title { font-size: 14px; color: inherit; }
.ec-step-tab-meta { font-size: 12px; color: var(--ec-light-gray); margin-top: 4px; }
.ec-step-tab.is-active {
  background: var(--ec-dark);
  color: #fff;
  border-color: var(--ec-dark);
}
.ec-step-tab.is-active .ec-step-tab-meta { color: rgba(255, 255, 255, 0.7); }
.ec-step-tab.is-complete {
  background: rgba(2, 122, 72, 0.08);
  color: var(--ec-success);
  border-color: rgba(2, 122, 72, 0.24);
}
.ec-step-tab.is-complete-state .ec-step-tab-meta { color: var(--ec-success); }
.ec-step-tab.is-attention {
  border-color: rgba(215, 105, 83, 0.35);
  background: rgba(254, 231, 224, 0.55);
}
.ec-step-tab.is-attention .ec-step-tab-meta { color: var(--ec-terracotta); }
.ec-section {
  background: var(--ec-white);
  border-radius: 24px;
  border: 1px solid rgba(25, 24, 24, 0.06);
  box-shadow: 0 14px 40px rgba(25, 24, 24, 0.06);
  padding: 20px;
}
.ec-step-section { display: none; }
.ec-step-section.is-active { display: grid; }
.ec-section-head { margin-bottom: 14px; }
.ec-section-head h2 { margin: 0 0 6px; font-size: 22px; }
.ec-section-head p, .ec-help { color: var(--ec-gray); line-height: 1.6; }
.ec-inline-hint {
  margin-bottom: 14px;
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(254, 231, 224, 0.52), rgba(255,255,255,0.92));
  border: 1px solid rgba(215, 105, 83, 0.16);
}
.ec-inline-hint-title {
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ec-terracotta);
}
.ec-inline-hint-body {
  color: var(--ec-gray);
  line-height: 1.65;
  font-size: 14px;
}
.ec-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px 16px;
}
.ec-field { display: grid; gap: 6px; }
.ec-label { font-size: 14px; font-weight: 700; color: var(--ec-dark); }
.ec-required { color: var(--ec-terracotta); }
.ec-input, .ec-select, .ec-textarea {
  width: 100%;
  border: 1px solid var(--ec-line);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 14px;
  background: #fff;
  color: var(--ec-dark);
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.ec-input:focus, .ec-select:focus, .ec-textarea:focus {
  border-color: rgba(215, 105, 83, 0.6);
  box-shadow: 0 0 0 4px rgba(215, 105, 83, 0.12);
}
.ec-textarea { min-height: 110px; resize: vertical; }
.ec-radio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}
.ec-checkbox-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 16px;
  border: 1px solid var(--ec-line);
  border-radius: 18px;
  background: #fff;
  cursor: pointer;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.ec-checkbox-card:hover { border-color: rgba(215, 105, 83, 0.45); transform: translateY(-1px); }
.ec-checkbox-card input { margin-top: 3px; accent-color: var(--ec-terracotta); }
.ec-checkbox-single { margin-bottom: 12px; }
.ec-file-drop {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 18px;
  border: 1px dashed rgba(215, 105, 83, 0.4);
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(254, 231, 224, 0.55), rgba(255, 255, 255, 0.95));
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease, transform .2s ease, box-shadow .2s ease;
}
.ec-file-drop:hover { border-color: rgba(215, 105, 83, 0.7); }
.ec-file-drop.is-dragover {
  border-color: var(--ec-terracotta);
  border-style: solid;
  background: linear-gradient(180deg, rgba(254, 231, 224, 0.95), rgba(254, 231, 224, 0.6));
  transform: scale(1.01);
  box-shadow: 0 0 0 4px rgba(215, 105, 83, 0.15);
}
.ec-file-drop.is-dragover .ec-file-title { color: var(--ec-terracotta); }
.ec-file-input { width: 100%; }
.ec-file-title { font-weight: 700; }
.ec-file-help, .ec-file-list { color: var(--ec-gray); font-size: 14px; }
.ec-upload-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}
.ec-upload-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(25, 24, 24, 0.08);
  background: #fff;
}
.ec-upload-item-main {
  min-width: 0;
}
.ec-upload-item-title {
  font-weight: 700;
  word-break: break-word;
}
.ec-upload-item-meta {
  color: var(--ec-gray);
  font-size: 13px;
  margin-top: 4px;
}
.ec-upload-remove {
  border: 0;
  border-radius: 12px;
  background: rgba(215, 105, 83, 0.12);
  color: var(--ec-terracotta);
  min-height: 40px;
  padding: 0 14px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.ec-alert {
  padding: 18px 20px;
  border-radius: 18px;
  border: 1px solid transparent;
  line-height: 1.6;
}
.ec-alert ul { margin: 10px 0 0; padding-left: 20px; }
.ec-alert-error {
  background: #fff2f0;
  border-color: rgba(180, 35, 24, 0.2);
  color: var(--ec-error);
}
.ec-step-error {
  padding: 12px;
  border-radius: 18px;
  background: rgba(255, 242, 240, 0.55);
}
.ec-step-error-banner {
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 600;
}
.ec-input-error,
.ec-input.ec-input-error,
.ec-select.ec-input-error,
.ec-textarea.ec-input-error,
.ec-radio-grid.ec-input-error,
.ec-file-drop.ec-input-error,
.ec-checkbox-single.ec-input-error {
  border-color: rgba(180, 35, 24, 0.55);
  background: rgba(255, 242, 240, 0.55);
}
.ec-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}
.ec-step-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-top: 16px;
}
.ec-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--ec-terracotta), #c65843);
  color: var(--ec-white);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 14px 30px rgba(215, 105, 83, 0.25);
}
.ec-button-secondary {
  background: #f4efe9;
  color: var(--ec-dark);
  box-shadow: none;
  border: 1px solid rgba(25, 24, 24, 0.08);
}
.ec-step-summary {
  margin-top: 18px;
}
.ec-step-summary-card {
  padding: 18px 20px;
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(254, 231, 224, 0.68), rgba(255, 255, 255, 0.9));
  border: 1px solid rgba(215, 105, 83, 0.18);
}
.ec-step-summary-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
}
.ec-step-summary-card p {
  margin: 0;
  color: var(--ec-gray);
  line-height: 1.6;
}
.ec-success-screen {
  background: var(--ec-white);
  padding: 48px 28px;
  border-radius: 28px;
  text-align: center;
  box-shadow: 0 16px 44px rgba(25, 24, 24, 0.08);
}
.ec-success-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(2, 122, 72, 0.12);
  color: var(--ec-success);
  font-size: 32px;
  font-weight: 800;
}
.ec-honeypot { position: absolute; left: -9999px; opacity: 0; pointer-events: none; }
.ec-consent-list { display: grid; gap: 12px; }
.ec-preview {
  margin-bottom: 22px;
  padding: 20px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(245, 244, 239, 0.92), rgba(255, 255, 255, 0.96));
  border: 1px solid rgba(25, 24, 24, 0.06);
}
.ec-preview-head h3 {
  margin: 0 0 8px;
  font-size: 20px;
}
.ec-preview-head p {
  margin: 0 0 18px;
  color: var(--ec-gray);
  line-height: 1.6;
}
.ec-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.ec-preview-card {
  padding: 16px 18px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid rgba(215, 105, 83, 0.12);
  box-shadow: 0 8px 24px rgba(25, 24, 24, 0.04);
}
.ec-preview-card-title {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ec-terracotta);
  margin-bottom: 10px;
}
.ec-preview-card-body {
  color: var(--ec-dark);
  line-height: 1.7;
  font-size: 14px;
}

@media (max-width: 900px) {
  .ec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ec-shell { padding: 16px 12px 40px; }
  .ec-section, .ec-hero { padding: 20px; border-radius: 20px; }
  .ec-stepper, .ec-stepper-head { padding: 18px; }
  .ec-stepper-head {
    flex-direction: column;
    align-items: stretch;
  }
  .ec-stepper-status { min-width: 0; }
  .ec-stepper-status-label { text-align: left; }
  .ec-stepper-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .ec-preview-grid {
    grid-template-columns: 1fr;
  }
  .ec-step-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }
  .ec-step-actions .ec-button {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .ec-grid { grid-template-columns: 1fr; }
}
