/* ===== Discount Calculator ===== */
.discountcalc-wrap {
  max-width: 720px;
  margin: 0 auto;
}

.dc-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.dc-title {
  font-size: 2rem;
  font-weight: 800;
  margin: 0 0 0.35rem;
  letter-spacing: -0.02em;
}

.dc-subtitle {
  color: #6b7280;
  font-size: 0.95rem;
  margin: 0;
}

/* ----- Input Card ----- */
.dc-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.dc-input-row,
.dc-percent-row {
  margin-bottom: 1rem;
}

.dc-input-row label,
.dc-percent-row label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: #374151;
  margin-bottom: 0.45rem;
}

.dc-price-input,
.dc-percent-input {
  position: relative;
  display: flex;
  align-items: center;
}

.dc-price-input input,
.dc-percent-input input {
  width: 100%;
  font-size: 1.4rem;
  font-weight: 700;
  padding: 0.75rem 2.4rem 0.75rem 0.95rem;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  text-align: right;
  background: #f9fafb;
  transition: all 0.15s ease;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
}

.dc-percent-input input::-webkit-outer-spin-button,
.dc-percent-input input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.dc-price-input input:focus,
.dc-percent-input input:focus {
  outline: none;
  border-color: #22c55e;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.12);
}

.dc-currency,
.dc-percent-sign {
  position: absolute;
  right: 0.95rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: #6b7280;
  pointer-events: none;
}

/* ----- Quick buttons ----- */
.dc-quick-btns {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.4rem;
  margin: 1rem 0 0.5rem;
}

@media (max-width: 480px) {
  .dc-quick-btns {
    grid-template-columns: repeat(4, 1fr);
  }
}

.dc-quick {
  padding: 0.55rem 0.3rem;
  border: 1.5px solid #e5e7eb;
  background: #fff;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
  transition: all 0.12s ease;
  font-variant-numeric: tabular-nums;
}

.dc-quick:hover {
  border-color: #22c55e;
  color: #22c55e;
}

.dc-quick.active {
  background: #22c55e;
  border-color: #22c55e;
  color: #fff;
  box-shadow: 0 2px 6px rgba(34, 197, 94, 0.3);
}

/* ----- Slider ----- */
.dc-slider {
  width: 100%;
  margin-top: 0.75rem;
  accent-color: #22c55e;
  height: 6px;
  cursor: pointer;
}

/* ----- Result Card ----- */
.dc-result-card {
  background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
  color: #fff;
  border-radius: 16px;
  padding: 1.5rem 1.5rem 1.25rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.2);
}

.dc-result-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.45rem 0;
  font-size: 1.02rem;
}

.dc-result-row.dc-final {
  border-top: 1px solid rgba(255, 255, 255, 0.3);
  margin-top: 0.5rem;
  padding-top: 0.9rem;
  font-size: 1.4rem;
  font-weight: 800;
}

.dc-label {
  opacity: 0.95;
}

.dc-pct-tag {
  font-size: 0.85rem;
  opacity: 0.8;
  font-weight: 500;
}

.dc-val {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.dc-saved {
  text-align: center;
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.25);
  font-size: 0.92rem;
  opacity: 0.95;
}

/* ----- Comparison Table ----- */
.dc-table-section {
  margin-bottom: 2.5rem;
}

.dc-table-title {
  font-size: 1.3rem;
  font-weight: 800;
  margin: 0 0 0.3rem;
  letter-spacing: -0.01em;
}

.dc-table-sub {
  color: #6b7280;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.dc-table-wrap {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  margin: 0.5rem 0 1.5rem;
}

.dc-table,
.dc-info-table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
  margin: 0;
}

.dc-table th,
.dc-info-table th {
  background: #f3f4f6;
  font-size: 0.85rem;
  font-weight: 700;
  color: #374151;
  padding: 0.75rem 0.6rem;
  text-align: right;
  border: none;
}

.dc-table th:first-child,
.dc-info-table th:first-child {
  text-align: center;
}

.dc-info-table th:last-child {
  text-align: left;
}

.dc-table td,
.dc-info-table td {
  padding: 0.7rem 0.6rem;
  text-align: right;
  border-top: 1px solid #f3f4f6;
  font-size: 0.93rem;
  color: #1f2937;
}

.dc-table td:first-child,
.dc-info-table td:first-child {
  text-align: center;
  font-weight: 700;
  color: #374151;
}

.dc-info-table td:last-child {
  text-align: left;
  color: #4b5563;
}

.dc-table tbody tr.active {
  background: #f0fdf4;
}

.dc-table tbody tr.active td:first-child,
.dc-table tbody tr.active td:last-child {
  color: #16a34a;
  font-weight: 800;
}

/* ----- Guide ----- */
.dc-guide {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid #e5e7eb;
  color: #374151;
  line-height: 1.75;
}

.dc-guide h2 {
  font-size: 1.25rem;
  font-weight: 800;
  margin: 2rem 0 0.85rem;
  letter-spacing: -0.01em;
  color: #111827;
}

.dc-guide h2:first-child {
  margin-top: 0;
}

.dc-guide p {
  margin: 0 0 0.85rem;
  color: #374151;
}

.dc-guide ol,
.dc-guide ul {
  padding-left: 1.3rem;
  margin-bottom: 1rem;
}

.dc-guide ol li,
.dc-guide ul li {
  margin-bottom: 0.4rem;
}

.dc-guide a {
  color: #16a34a;
  text-decoration: none;
  font-weight: 600;
}

.dc-guide a:hover {
  text-decoration: underline;
}

/* ----- Tier cards ----- */
.dc-tiers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin: 1rem 0 1.5rem;
}

@media (max-width: 540px) {
  .dc-tiers {
    grid-template-columns: 1fr;
  }
}

.dc-tier {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 0.9rem 1rem;
  background: #fff;
  transition: border-color 0.12s;
}

.dc-tier:hover {
  border-color: #22c55e;
}

.dc-tier-pct {
  font-size: 1.05rem;
  font-weight: 800;
  color: #16a34a;
  font-variant-numeric: tabular-nums;
}

.dc-tier-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #1f2937;
  margin: 0.15rem 0 0.4rem;
}

.dc-tier p {
  font-size: 0.88rem;
  color: #6b7280;
  line-height: 1.55;
  margin: 0;
}

/* ----- Example box ----- */
.dc-example {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 12px;
  padding: 1rem 1.2rem;
  margin: 0.5rem 0 1.5rem;
}

.dc-example-title {
  font-weight: 700;
  color: #14532d;
  margin-bottom: 0.6rem;
  font-size: 0.95rem;
}

.dc-example ol {
  margin: 0 0 0.5rem;
  padding-left: 1.3rem;
}

.dc-example ol li {
  color: #1f2937;
  margin-bottom: 0.25rem;
}

.dc-example-note {
  margin: 0.5rem 0 0 !important;
  font-size: 0.9rem !important;
  color: #4b5563 !important;
  padding-top: 0.5rem;
  border-top: 1px dashed #bbf7d0;
}

/* ----- FAQ ----- */
.dc-faq details {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.55rem;
  background: #fff;
  transition: border-color 0.12s;
}

.dc-faq details[open] {
  border-color: #22c55e;
}

.dc-faq summary {
  font-weight: 600;
  cursor: pointer;
  color: #1f2937;
  list-style: none;
  position: relative;
  padding-right: 1.5rem;
}

.dc-faq summary::-webkit-details-marker {
  display: none;
}

.dc-faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: -2px;
  font-size: 1.3rem;
  color: #9ca3af;
  font-weight: 400;
  transition: transform 0.15s;
}

.dc-faq details[open] summary::after {
  content: "−";
  color: #22c55e;
}

.dc-faq p {
  margin: 0.6rem 0 0 !important;
  color: #4b5563 !important;
  font-size: 0.94rem !important;
  line-height: 1.7;
}

/* ----- Dark mode ----- */
@media (prefers-color-scheme: dark) {
  .dc-card,
  .dc-table-wrap,
  .dc-faq details,
  .dc-tier {
    background: #1f2937;
    border-color: #374151;
  }
  .dc-input-row label,
  .dc-percent-row label,
  .dc-table td,
  .dc-info-table td,
  .dc-faq summary,
  .dc-guide,
  .dc-guide h2,
  .dc-guide p,
  .dc-tier-name {
    color: #e5e7eb;
  }
  .dc-price-input input,
  .dc-percent-input input {
    background: #111827;
    border-color: #374151;
    color: #f9fafb;
  }
  .dc-quick {
    background: #1f2937;
    border-color: #374151;
    color: #e5e7eb;
  }
  .dc-table th,
  .dc-info-table th {
    background: #111827;
    color: #e5e7eb;
  }
  .dc-table td,
  .dc-info-table td {
    border-top-color: #374151;
  }
  .dc-info-table td:last-child,
  .dc-tier p,
  .dc-faq p {
    color: #9ca3af !important;
  }
  .dc-table tbody tr.active {
    background: rgba(34, 197, 94, 0.12);
  }
  .dc-subtitle,
  .dc-table-sub {
    color: #9ca3af;
  }
  .dc-guide {
    border-top-color: #374151;
  }
  .dc-example {
    background: rgba(34, 197, 94, 0.08);
    border-color: #14532d;
  }
  .dc-example-title {
    color: #86efac;
  }
  .dc-example ol li {
    color: #e5e7eb;
  }
}