/* ============================
   Gerador de Contrato — Styles
   ============================ */

/* Hero */
.gc-hero {
  padding-top: 140px;
  padding-bottom: 50px;
  background: linear-gradient(135deg, #1f99e8 0%, #0d89e0 52%, #066db8 100%);
  position: relative;
  overflow: hidden;
}

.gc-hero::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -10%;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
}

.gc-badge {
  margin-bottom: 20px;
}

.gc-hero-title {
  font-family: "Sora", sans-serif;
  font-size: 46px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.15;
  margin-top: 16px;
}

.gc-hero-sub {
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
  line-height: 1.7;
  max-width: 600px;
  margin: 18px auto 0;
}

/* Form Section */
.gc-form-section {
  padding: 60px 0 40px;
}

/* Steps */
.gc-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 36px;
  flex-wrap: wrap;
}

.gc-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: default;
}

.gc-step-num {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e6eef8;
  color: #8a9bb5;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.gc-step-label {
  font-size: 12px;
  font-weight: 600;
  color: #8a9bb5;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  transition: color 0.3s ease;
}

.gc-step.active .gc-step-num {
  background: var(--gn-primary);
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(13, 137, 224, 0.35);
}

.gc-step.active .gc-step-label {
  color: var(--gn-primary);
}

.gc-step.done .gc-step-num {
  background: #28c76f;
  color: #ffffff;
}

.gc-step.done .gc-step-label {
  color: #28c76f;
}

.gc-step-line {
  width: 40px;
  height: 3px;
  background: #e6eef8;
  border-radius: 2px;
  margin: 0 6px;
  margin-bottom: 22px;
  transition: background 0.3s ease;
}

.gc-step-line.done {
  background: #28c76f;
}

/* Card */
.gc-card {
  background: #ffffff;
  border: 1px solid #e6eff9;
  border-radius: 20px;
  padding: 40px 36px;
  box-shadow: 0 12px 40px rgba(16, 39, 66, 0.08);
}

/* Panels */
.gc-panel {
  display: none;
}

.gc-panel.active {
  display: block;
  animation: gcFadeIn 0.35s ease;
}

@keyframes gcFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.gc-panel-title {
  font-family: "Sora", sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--gn-ink);
  margin-bottom: 6px;
}

.gc-panel-title i {
  color: var(--gn-primary);
  margin-right: 8px;
}

.gc-panel-desc {
  color: var(--gn-muted);
  font-size: 15px;
  margin-bottom: 28px;
}

/* ========== Type Selector ========== */
.gc-type-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 10px;
}

label.gc-type-option {
  display: block;
  cursor: pointer;
  margin: 0;
  padding: 0;
}

.gc-type-option input[type="radio"] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
  opacity: 0;
}

span.gc-type-card {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 28px 16px;
  border: 2px solid #e2ecf7;
  border-radius: 16px;
  background: #fafcff;
  transition: all 0.3s ease;
  min-height: 160px;
  justify-content: center;
}

.gc-type-card i {
  font-size: 36px;
  color: #8a9bb5;
  margin-bottom: 12px;
  transition: all 0.3s ease;
}

.gc-type-card strong {
  font-size: 16px;
  font-weight: 700;
  color: var(--gn-ink);
  margin-bottom: 6px;
  display: block;
}

.gc-type-card small {
  font-size: 13px;
  color: var(--gn-muted);
  line-height: 1.4;
  display: block;
}

.gc-type-option:hover .gc-type-card {
  border-color: var(--gn-primary);
  box-shadow: 0 8px 24px rgba(13, 137, 224, 0.1);
  transform: translateY(-2px);
}

.gc-type-option.active .gc-type-card {
  border-color: var(--gn-primary);
  background: var(--gn-primary-soft);
  box-shadow: 0 8px 28px rgba(13, 137, 224, 0.15);
}

.gc-type-option.active .gc-type-card i {
  color: var(--gn-primary);
  transform: scale(1.1);
}

/* ========== Fields ========== */
.gc-field {
  margin-bottom: 20px;
}

.gc-field label,
.gc-field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gn-ink);
  margin-bottom: 6px;
}

.gc-field input,
.gc-field select {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  border: 1.5px solid #d8e4f0;
  border-radius: 12px;
  font-size: 15px;
  font-family: "Manrope", sans-serif;
  color: var(--gn-ink);
  background: #fafcff;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.gc-field input:focus,
.gc-field select:focus {
  outline: none;
  border-color: var(--gn-primary);
  box-shadow: 0 0 0 3px rgba(13, 137, 224, 0.12);
  background: #ffffff;
}

.gc-field input.gc-error,
.gc-field select.gc-error {
  border-color: #e74c3c;
  box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.12);
}

/* ========== Total Card ========== */
.gc-total-card {
  background: linear-gradient(135deg, #f7fbff 0%, #eef6ff 100%);
  border: 2px solid #d4eaff;
  border-radius: 16px;
  padding: 24px 28px;
  margin-top: 24px;
}

.gc-total-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.gc-total-value {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.gc-total-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--gn-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.gc-total-amount {
  font-family: "Sora", sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: var(--gn-primary);
  line-height: 1.1;
}

.gc-total-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gc-days-switch {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  margin: 0;
  user-select: none;
}

.gc-days-switch input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.gc-switch-slider {
  position: relative;
  width: 44px;
  height: 24px;
  background: #c8d6e5;
  border-radius: 24px;
  transition: background 0.3s ease;
  flex-shrink: 0;
}

.gc-switch-slider::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.3s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.gc-days-switch input:checked + .gc-switch-slider {
  background: var(--gn-primary);
}

.gc-days-switch input:checked + .gc-switch-slider::after {
  transform: translateX(20px);
}

.gc-days-switch input:disabled + .gc-switch-slider {
  background: #dde6f0;
  opacity: 0.5;
  cursor: not-allowed;
}

.gc-days-switch input:disabled ~ .gc-switch-text {
  opacity: 0.5;
}

.gc-switch-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--gn-ink);
  white-space: nowrap;
}

.gc-days-badge {
  display: none;
  background: var(--gn-primary);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

.gc-days-badge.visible {
  display: inline-block;
}

.gc-total-hint {
  font-size: 13px;
  color: var(--gn-muted);
  margin: 10px 0 0;
  font-style: italic;
}

.gc-total-hint.hidden {
  display: none;
}

/* ========== Items List ========== */
.gc-items-section {
  margin-bottom: 24px;
}

.gc-item-row {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  align-items: center;
}

.gc-item-row input {
  height: 44px;
  padding: 0 14px;
  border: 1.5px solid #d8e4f0;
  border-radius: 10px;
  font-size: 14px;
  font-family: "Manrope", sans-serif;
  color: var(--gn-ink);
  background: #fafcff;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.gc-item-row input:focus {
  outline: none;
  border-color: var(--gn-primary);
  box-shadow: 0 0 0 3px rgba(13, 137, 224, 0.12);
  background: #ffffff;
}

.gc-item-row input.gc-error {
  border-color: #e74c3c;
}

.gc-item-desc {
  flex: 3;
  min-width: 0;
}

.gc-item-qty {
  flex: 0 0 70px;
  text-align: center;
}

.gc-item-valor {
  flex: 1;
  min-width: 100px;
}

.gc-item-remove {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border: none;
  background: #fde8e8;
  color: #e74c3c;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gc-item-remove:hover {
  background: #e74c3c;
  color: #fff;
}

.gc-btn-add-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 1.5px dashed var(--gn-primary);
  color: var(--gn-primary);
  font-size: 14px;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Manrope", sans-serif;
  margin-top: 4px;
  -webkit-appearance: none;
  appearance: none;
}

.gc-btn-add-item i {
  font-size: 16px;
  display: inline-block;
}

.gc-btn-add-item:hover {
  background: var(--gn-primary-soft);
}

.gc-divider {
  border: none;
  border-top: 1px solid #edf3fa;
  margin: 28px 0;
}

/* ========== Cláusulas Editáveis ========== */
.gc-clausula-item {
  background: #f8fbff;
  border: 1px solid #dce8f5;
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 16px;
  transition: all 0.3s ease;
}

.gc-clausula-item:hover {
  border-color: #c2d8f0;
  box-shadow: 0 4px 16px rgba(16, 39, 66, 0.06);
}

.gc-clausula-custom {
  border-color: var(--gn-primary);
  border-style: dashed;
}

.gc-clausula-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.gc-clausula-num {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gn-primary);
  white-space: nowrap;
  background: var(--gn-primary-soft);
  padding: 4px 10px;
  border-radius: 6px;
}

.gc-clausula-titulo {
  flex: 1;
  height: 38px;
  padding: 0 12px;
  border: 1.5px solid #d8e4f0;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  font-family: "Manrope", sans-serif;
  color: var(--gn-ink);
  background: #ffffff;
  transition: border-color 0.25s ease;
}

.gc-clausula-titulo:focus {
  outline: none;
  border-color: var(--gn-primary);
  box-shadow: 0 0 0 3px rgba(13, 137, 224, 0.1);
}

.gc-clausula-remove {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border: none;
  background: #fde8e8;
  color: #e74c3c;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.gc-clausula-remove:hover {
  background: #e74c3c;
  color: #fff;
}

.gc-clausula-texto {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid #d8e4f0;
  border-radius: 10px;
  font-size: 14px;
  font-family: "Manrope", sans-serif;
  color: #3a424e;
  line-height: 1.6;
  background: #ffffff;
  resize: vertical;
  min-height: 80px;
  transition: border-color 0.25s ease;
}

.gc-clausula-texto:focus {
  outline: none;
  border-color: var(--gn-primary);
  box-shadow: 0 0 0 3px rgba(13, 137, 224, 0.1);
}

.gc-btn-add-clausula {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 2px dashed #28c76f;
  color: #28c76f;
  font-size: 14px;
  font-weight: 700;
  padding: 12px 24px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Manrope", sans-serif;
  margin-top: 8px;
  margin-bottom: 16px;
}

.gc-btn-add-clausula:hover {
  background: rgba(40, 199, 111, 0.08);
  border-color: #1fba59;
}

/* ========== Actions ========== */
.gc-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid #edf3fa;
}

.gc-btn-back {
  background: none;
  border: none;
  color: var(--gn-muted);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  padding: 10px 18px;
  border-radius: 10px;
  transition: all 0.2s ease;
  font-family: "Manrope", sans-serif;
}

.gc-btn-back:hover {
  background: #f0f5fb;
  color: var(--gn-ink);
}

.gc-btn-back i {
  margin-right: 6px;
}

.gc-btn-next,
.gc-btn-generate {
  padding: 0 28px;
  height: 48px;
  line-height: 48px;
  font-size: 15px;
}

.gc-btn-next i,
.gc-btn-generate i {
  margin-left: 8px;
}

/* Preview Actions */
.gc-preview-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}

.gc-btn-secondary {
  background: #f0f5fb;
  border: 1.5px solid #d8e4f0;
  color: var(--gn-ink);
  font-size: 14px;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Manrope", sans-serif;
}

.gc-btn-secondary:hover {
  background: var(--gn-primary);
  color: #ffffff;
  border-color: var(--gn-primary);
}

.gc-btn-secondary i {
  margin-right: 6px;
}

/* ========== Contract Preview ========== */
.gc-contract-preview {
  background: #fdfefe;
  border: 1px solid #dbe8f4;
  border-radius: 14px;
  padding: 36px 32px;
  max-height: 600px;
  overflow-y: auto;
}

.gc-contract-body {
  font-family: Georgia, "Times New Roman", serif;
  color: #222;
  line-height: 1.75;
}

.gc-contract-title {
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 24px;
  letter-spacing: 1px;
}

.gc-contract-body h3 {
  font-size: 14px;
  font-weight: 700;
  margin-top: 22px;
  margin-bottom: 8px;
  color: #111;
  font-family: Georgia, "Times New Roman", serif;
}

.gc-contract-body p {
  font-size: 14px;
  text-align: justify;
  margin-bottom: 8px;
}

.gc-contract-body ul {
  margin: 6px 0 6px 20px;
  font-size: 14px;
}

.gc-contract-body ul li {
  margin-bottom: 4px;
}

/* Items table in contract */
.gc-items-table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 24px;
}

.gc-items-table th,
.gc-items-table td {
  border: 1px solid #bbb;
  padding: 8px 12px;
  font-size: 13px;
  text-align: left;
}

.gc-items-table th {
  background: #f0f0f0;
  font-weight: 700;
}

.gc-contract-signatures {
  display: flex;
  justify-content: space-between;
  margin-top: 40px;
  gap: 20px;
}

.gc-sig {
  text-align: center;
  flex: 1;
}

.gc-sig-line {
  border-bottom: 1px solid #333;
  margin-bottom: 10px;
  height: 50px;
}

.gc-sig p {
  font-size: 12px;
  text-align: center;
}

.gc-contract-locale {
  margin-top: 30px;
}

.gc-contract-watermark {
  margin-top: 36px;
  text-align: center;
  font-size: 11px;
  color: #aaa;
  border-top: 1px solid #e0e0e0;
  padding-top: 14px;
}

/* ========== CTA Section ========== */
.gc-cta {
  padding: 70px 0 80px;
}

.gc-cta-card {
  background: linear-gradient(135deg, #f7fbff 0%, #eef6ff 100%);
  border: 2px solid #d4eaff;
  border-radius: 24px;
  padding: 54px 44px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.gc-cta-card::before {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(13, 137, 224, 0.06);
}

.gc-cta-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gn-primary), var(--gn-accent));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  box-shadow: 0 12px 28px rgba(13, 137, 224, 0.3);
}

.gc-cta-icon i {
  font-size: 32px;
  color: #ffffff;
}

.gc-cta-title {
  font-family: "Sora", sans-serif;
  font-size: 36px;
  font-weight: 800;
  color: var(--gn-ink);
  margin-bottom: 12px;
}

.gc-cta-subtitle {
  font-size: 17px;
  color: var(--gn-muted);
  max-width: 560px;
  margin: 0 auto 30px;
  line-height: 1.65;
}

.gc-cta-features {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-bottom: 36px;
}

.gc-cta-feat {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #d8eaf8;
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 14px;
  font-weight: 500;
  color: var(--gn-ink);
}

.gc-cta-feat i {
  color: #28c76f;
  font-size: 16px;
}

.gc-cta-buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.gc-btn-whatsapp {
  background: #25d366 !important;
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.3) !important;
  height: 54px;
  line-height: 54px;
  padding: 0 32px;
  font-size: 16px;
  font-weight: 700;
}

.gc-btn-whatsapp:hover {
  background: #1fba59 !important;
  box-shadow: 0 8px 20px rgba(37, 211, 102, 0.4) !important;
}

.gc-btn-whatsapp i {
  margin-right: 8px;
  font-size: 20px;
}

.gc-btn-platform {
  height: 54px;
  line-height: 54px;
  padding: 0 32px;
  font-size: 16px;
  font-weight: 700;
}

.gc-btn-platform i {
  margin-right: 8px;
}

.gc-cta-small {
  font-size: 14px;
  color: var(--gn-muted);
}

.gc-cta-small strong {
  color: var(--gn-primary);
}

/* Footer */
.gc-footer {
  background: var(--gn-ink);
  padding: 24px 0;
}

.gc-footer p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  margin: 0;
}

.gc-footer a {
  color: var(--gn-accent);
  text-decoration: none;
}

.gc-footer a:hover {
  text-decoration: underline;
}

/* Toast */
.gc-toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--gn-ink);
  color: #ffffff;
  padding: 12px 28px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 9999;
}

.gc-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ========== Responsive ========== */
@media (max-width: 767px) {
  .gc-hero {
    padding-top: 110px;
    padding-bottom: 36px;
  }

  .gc-hero-title {
    font-size: 30px;
  }

  .gc-hero-sub {
    font-size: 16px;
  }

  .gc-card {
    padding: 28px 20px;
  }

  .gc-steps {
    gap: 4px;
  }

  .gc-step-line {
    width: 18px;
    margin: 0 3px;
  }

  .gc-step-label {
    font-size: 9px;
  }

  .gc-step-num {
    width: 34px;
    height: 34px;
    font-size: 13px;
  }

  /* Type grid stacks */
  .gc-type-grid {
    grid-template-columns: 1fr !important;
    gap: 12px;
  }

  span.gc-type-card {
    flex-direction: row !important;
    text-align: left;
    padding: 18px 16px;
    gap: 14px;
    min-height: auto;
  }

  .gc-type-card i {
    font-size: 28px;
    margin-bottom: 0;
  }

  /* Item rows stack */
  .gc-item-row {
    flex-wrap: wrap;
  }

  .gc-item-desc {
    flex: 1 1 100%;
  }

  .gc-item-qty {
    flex: 1 1 60px;
  }

  .gc-item-valor {
    flex: 1 1 100px;
  }

  /* Clausulas */
  .gc-clausula-header {
    flex-wrap: wrap;
    gap: 8px;
  }

  .gc-clausula-titulo {
    flex: 1 1 100%;
    order: 3;
  }

  .gc-contract-preview {
    padding: 24px 16px;
  }

  .gc-contract-signatures {
    flex-direction: column;
    gap: 30px;
  }

  .gc-total-card {
    padding: 20px;
  }

  .gc-total-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .gc-total-amount {
    font-size: 26px;
  }

  .gc-cta-card {
    padding: 36px 20px;
  }

  .gc-cta-title {
    font-size: 28px;
  }

  .gc-cta-buttons {
    flex-direction: column;
    align-items: center;
  }

  .gc-btn-whatsapp,
  .gc-btn-platform {
    width: 100%;
    text-align: center;
  }

  .gc-preview-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .gc-preview-actions .gc-btn-back,
  .gc-preview-actions .gc-btn-secondary {
    text-align: center;
  }
}
