:root {
  --ctc-bg: #0f172a;
  --ctc-card: #111827;
  --ctc-surface: #ffffff;
  --ctc-border: #e5e7eb;
  --ctc-text: #0f172a;
  --ctc-muted: #64748b;
  --ctc-primary: #111827;
  --ctc-success: #16a34a;
  --ctc-success-soft: #dcfce7;
  --ctc-shadow: 0 20px 40px rgba(15, 23, 42, 0.12);
  --ctc-radius: 20px;
}

.ctc-tradein {
  padding: 24px 0;
  color: var(--ctc-text);
  font-family: inherit;
}

.ctc-tradein__hero {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 560px);
  gap: 28px;
  align-items: start;
}

.ctc-tradein__copy {
  padding: 16px 4px;
}

.ctc-tradein__eyebrow {
  display: inline-block;
  margin-bottom: 14px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #eef2ff;
  color: #3730a3;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
}

.ctc-tradein__copy h2 {
  margin: 0 0 14px;
  font-size: clamp(32px, 5vw, 48px);
  line-height: 1.02;
}

.ctc-tradein__copy p {
  margin: 0 0 18px;
  color: var(--ctc-muted);
  font-size: 17px;
  line-height: 1.6;
}

.ctc-tradein__bullets {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ctc-tradein__bullets li {
  position: relative;
  padding-left: 24px;
  font-weight: 600;
}

.ctc-tradein__bullets li::before {
  content: '•';
  position: absolute;
  left: 8px;
  top: 0;
}

.ctc-tradein__card {
  background: var(--ctc-surface);
  border: 1px solid var(--ctc-border);
  border-radius: var(--ctc-radius);
  box-shadow: var(--ctc-shadow);
  padding: 22px;
}

.ctc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.ctc-field {
  display: grid;
  gap: 8px;
}

.ctc-field--full {
  grid-column: 1 / -1;
}

.ctc-field--inline {
  align-self: end;
}

.ctc-field label,
.ctc-check span {
  font-size: 14px;
  font-weight: 700;
}

.ctc-field input[type="text"],
.ctc-field select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  padding: 0 14px;
  background: #fff;
  color: var(--ctc-text);
  font-size: 15px;
}

.ctc-field input[type="text"]:focus,
.ctc-field select:focus {
  outline: 2px solid #c7d2fe;
  border-color: #818cf8;
}

.ctc-check {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  padding: 0 14px;
}

.ctc-check input {
  width: 18px;
  height: 18px;
}

.ctc-actions {
  display: flex;
  gap: 12px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.ctc-button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: transform .15s ease, opacity .15s ease;
}

.ctc-button:hover {
  transform: translateY(-1px);
}

.ctc-button--primary {
  background: var(--ctc-primary);
  color: #fff;
}

.ctc-button--ghost {
  background: #fff;
  border-color: #d1d5db;
  color: var(--ctc-text);
}

.ctc-button--whatsapp {
  background: #25D366;
  color: #062d14;
}

.ctc-result {
  margin-top: 20px;
  padding: 18px;
  border-radius: 18px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.ctc-result__badge {
  display: inline-block;
  margin-bottom: 10px;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--ctc-success-soft);
  color: #166534;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.ctc-result h3 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.05;
}

.ctc-result p {
  margin: 10px 0 0;
  color: var(--ctc-muted);
  font-size: 15px;
  line-height: 1.55;
}

.ctc-result__meta {
  margin: 12px 0 16px;
  color: var(--ctc-text);
  font-size: 14px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ctc-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #e2e8f0;
  font-weight: 700;
}

.ctc-result small {
  display: block;
  margin-top: 10px;
  color: var(--ctc-muted);
  line-height: 1.5;
}

@media (max-width: 960px) {
  .ctc-tradein__hero {
    grid-template-columns: 1fr;
  }
}

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

  .ctc-actions {
    flex-direction: column;
  }

  .ctc-button {
    width: 100%;
  }
}

.ctc-result[data-state="success"] h3 {
  color: #15803d;
}

.ctc-result[data-state="warning"] h3,
.ctc-result[data-state="empty"] h3 {
  color: #b45309;
}

.ctc-result[data-state="success"] {
  background: #f0fdf4;
  border-color: #bbf7d0;
}

.ctc-result[data-state="warning"],
.ctc-result[data-state="empty"] {
  background: #fff7ed;
  border-color: #fed7aa;
}

.ctc-result a.ctc-button--whatsapp {
  width: 100%;
  max-width: 320px;
}

.ctc-result h3[data-ctc-result-range] {
  letter-spacing: -0.02em;
}

.ctc-result__meta .ctc-chip {
  background: #e8f0fe;
}

.ctc-field textarea {
  width: 100%;
  min-height: 120px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  padding: 12px 14px;
  background: #fff;
  color: var(--ctc-text);
  font-size: 15px;
  line-height: 1.5;
  resize: vertical;
}

.ctc-field textarea:focus {
  outline: 2px solid #c7d2fe;
  border-color: #818cf8;
}

.large-text.code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
