/* ==========================================================================
   Calculator Styles — Adapted for kak-md Hugo site
   Scoped under .calc-wrapper to avoid collisions with global styles
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Calculator-Specific CSS Variables (scoped)
   -------------------------------------------------------------------------- */

.calc-wrapper {
  /* Map to kak-md global variables */
  --bg-card: var(--bg);
  --bg-secondary: var(--bg-light);
  --text-secondary: var(--text-light);
  --text-muted: #9ca3af;

  /* Calculator color tokens — light theme */
  --blue-50: #eff6ff;
  --blue-200: #bfdbfe;
  --blue-500: #3b82f6;
  --blue-600: #2563eb;
  --blue-700: #1d4ed8;

  --orange-50: #fff7ed;
  --orange-200: #fed7aa;
  --orange-600: #ea580c;

  --yellow-50: #fefce8;
  --yellow-200: #fef08a;
  --yellow-600: #ca8a04;
  --yellow-800: #854d0e;

  --green-500: #22c55e;

  --radius: 0.75rem;
  --radius-lg: 1rem;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
}

[data-theme="dark"] .calc-wrapper {
  --bg-card: var(--bg-light);
  --bg-secondary: var(--bg);
  --text-secondary: var(--text-light);
  --text-muted: #6b7280;

  --blue-50: rgba(59, 130, 246, 0.1);
  --blue-200: rgba(59, 130, 246, 0.25);
  --orange-50: rgba(234, 88, 12, 0.1);
  --orange-200: rgba(234, 88, 12, 0.25);
  --yellow-50: rgba(202, 138, 4, 0.1);
  --yellow-200: rgba(202, 138, 4, 0.25);
  --yellow-800: #fef08a;
}

/* --------------------------------------------------------------------------
   2. Calculator Card
   -------------------------------------------------------------------------- */

.calculator-section {
  max-width: 42rem;
  margin: 0 auto 3rem;
  padding: 0 1rem;
  position: relative;
  z-index: 10;
}

.calc-wrapper .card {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

/* --------------------------------------------------------------------------
   3. Exchange Bar
   -------------------------------------------------------------------------- */

.calc-wrapper .exchange-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
}

.calc-wrapper .exchange-bar .rate-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.calc-wrapper .rate-live::before,
.calc-wrapper .rate-fallback::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  margin-right: 0.3rem;
  vertical-align: middle;
}

.calc-wrapper .rate-live::before {
  background-color: var(--green-500);
}

.calc-wrapper .rate-fallback::before {
  background-color: var(--yellow-600);
}

/* --------------------------------------------------------------------------
   4. Stepper — Mobile
   -------------------------------------------------------------------------- */

.calc-wrapper .stepper-mobile {
  display: block;
  text-align: center;
  margin-bottom: 1.25rem;
}

.calc-wrapper .stepper-mobile .step-counter {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.15rem;
}

.calc-wrapper .stepper-mobile .step-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}

/* --------------------------------------------------------------------------
   5. Stepper — Desktop
   -------------------------------------------------------------------------- */

.calc-wrapper .stepper-desktop {
  display: none;
  margin-bottom: 1.5rem;
}

.calc-wrapper .stepper-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.calc-wrapper .step-item {
  display: flex;
  align-items: center;
  gap: 0;
}

.calc-wrapper .step-circle {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 2px solid var(--border);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  background: transparent;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.calc-wrapper .step-circle.active {
  background-color: var(--blue-600);
  border-color: var(--blue-600);
  color: #fff;
}

.calc-wrapper .step-circle.completed {
  background-color: var(--green-500);
  border-color: var(--green-500);
  color: #fff;
}

.calc-wrapper .step-line {
  width: 3rem;
  height: 2px;
  background-color: var(--border);
  transition: background-color 0.3s ease;
  flex-shrink: 0;
}

.calc-wrapper .step-line.completed {
  background-color: var(--blue-600);
}

.calc-wrapper .step-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 0.5rem;
  padding: 0 0.25rem;
}

.calc-wrapper .step-label-text {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-align: center;
  flex: 1;
}

.calc-wrapper .step-label-text.active {
  color: var(--blue-600);
  font-weight: 600;
}

@media (min-width: 640px) {
  .calc-wrapper .stepper-mobile {
    display: none;
  }

  .calc-wrapper .stepper-desktop {
    display: block;
  }
}

/* --------------------------------------------------------------------------
   6. Selection Grid
   -------------------------------------------------------------------------- */

.calc-wrapper .selection-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.calc-wrapper .engine-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .calc-wrapper .engine-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.calc-wrapper .selection-card {
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s ease;
  background-color: var(--bg-card);
}

.calc-wrapper .selection-card:hover {
  border-color: var(--blue-500);
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.calc-wrapper .selection-card.selected {
  border-color: var(--blue-500);
  background-color: var(--blue-50);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.calc-wrapper .selection-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  line-height: 1;
}

.calc-wrapper .selection-label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
}

.calc-wrapper .selection-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
  line-height: 1.4;
}

.calc-wrapper .selection-desc.discount {
  color: var(--green-500);
}

/* --------------------------------------------------------------------------
   7. Form Controls
   -------------------------------------------------------------------------- */

.calc-wrapper .form-group {
  margin-bottom: 1.25rem;
}

.calc-wrapper .form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 0.375rem;
}

.calc-wrapper .form-input,
.calc-wrapper .form-select {
  width: 100%;
  min-height: 44px;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-family: inherit;
  background-color: var(--bg-card);
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.calc-wrapper .form-input:focus,
.calc-wrapper .form-select:focus {
  outline: none;
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.calc-wrapper .form-input::placeholder {
  color: var(--text-muted);
}

.calc-wrapper .form-select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 12px;
  padding-right: 2.25rem;
}

.calc-wrapper .form-row {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 0.75rem;
}

.calc-wrapper .volume-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.calc-wrapper .volume-pill {
  padding: 0.25rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.8rem;
  font-family: inherit;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s ease;
}

.calc-wrapper .volume-pill:hover {
  border-color: var(--blue-500);
  color: var(--blue-600);
}

.calc-wrapper .volume-pill.active {
  background-color: var(--blue-600);
  border-color: var(--blue-600);
  color: #fff;
}

/* --------------------------------------------------------------------------
   8. Results — Breakdown
   -------------------------------------------------------------------------- */

.calc-wrapper .breakdown-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
}

.calc-wrapper .breakdown-row:last-child {
  border-bottom: none;
}

.calc-wrapper .breakdown-label {
  flex: 1;
  font-size: 0.875rem;
  color: var(--text);
}

.calc-wrapper .breakdown-note {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
  line-height: 1.4;
}

.calc-wrapper .breakdown-value {
  text-align: right;
  flex-shrink: 0;
  margin-left: 1rem;
}

.calc-wrapper .breakdown-primary {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
}

.calc-wrapper .breakdown-secondary {
  font-size: 0.7rem;
  color: var(--text-muted);
  display: block;
}

/* --------------------------------------------------------------------------
   9. Results — Total Cards
   -------------------------------------------------------------------------- */

.calc-wrapper .result-totals {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 1.25rem;
}

@media (min-width: 640px) {
  .calc-wrapper .result-totals {
    grid-template-columns: 1fr 1fr;
  }
}

.calc-wrapper .result-card {
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
  border: 1px solid;
}

.calc-wrapper .result-card.blue {
  background-color: var(--blue-50);
  border-color: var(--blue-200);
}

.calc-wrapper .result-card.blue .result-label {
  color: var(--blue-600);
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.calc-wrapper .result-card.blue .result-value {
  color: var(--blue-700);
}

.calc-wrapper .result-card.blue .result-secondary {
  color: var(--blue-500);
}

.calc-wrapper .result-card.orange {
  background-color: var(--orange-50);
  border-color: var(--orange-200);
}

.calc-wrapper .result-card.orange .result-label {
  color: var(--orange-600);
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.calc-wrapper .result-card.orange .result-value {
  color: var(--orange-600);
}

.calc-wrapper .result-card.orange .result-secondary {
  color: var(--orange-600);
  opacity: 0.7;
}

.calc-wrapper .result-value {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}

.calc-wrapper .result-secondary {
  font-size: 0.75rem;
  margin-top: 0.15rem;
}

/* --------------------------------------------------------------------------
   10. Disclaimer
   -------------------------------------------------------------------------- */

.calc-wrapper .disclaimer {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  background-color: var(--yellow-50);
  border: 1px solid var(--yellow-200);
  border-radius: var(--radius);
  padding: 1rem;
  margin-top: 1.25rem;
  font-size: 0.75rem;
  color: var(--yellow-800);
  line-height: 1.5;
}

.calc-wrapper .disclaimer-icon {
  flex-shrink: 0;
  font-size: 1rem;
  line-height: 1;
}

/* --------------------------------------------------------------------------
   11. Buttons (scoped to .calc-wrapper to avoid collision)
   -------------------------------------------------------------------------- */

.calc-wrapper .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s ease;
  border: none;
  text-decoration: none;
  line-height: 1;
}

.calc-wrapper .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.calc-wrapper .btn-primary {
  background-color: var(--blue-600);
  color: #fff;
}

.calc-wrapper .btn-primary:hover:not(:disabled) {
  background-color: var(--blue-700);
}

.calc-wrapper .btn-secondary {
  background-color: var(--bg-secondary);
  color: var(--text);
  border: 1px solid var(--border);
}

.calc-wrapper .btn-secondary:hover:not(:disabled) {
  background-color: var(--border);
}

.calc-wrapper .btn-outline {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.calc-wrapper .btn-outline:hover:not(:disabled) {
  background-color: var(--bg-secondary);
  border-color: var(--text-muted);
}

.calc-wrapper .btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.calc-wrapper .btn-ghost:hover:not(:disabled) {
  background-color: var(--bg-secondary);
}

.calc-wrapper .btn-lg {
  min-height: 52px;
  padding: 0.875rem 1.75rem;
  font-size: 1rem;
}

/* --------------------------------------------------------------------------
   12. Step Navigation
   -------------------------------------------------------------------------- */

.calc-wrapper .step-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

/* --------------------------------------------------------------------------
   13. Step Transitions
   -------------------------------------------------------------------------- */

.calc-wrapper #step-content {
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.calc-wrapper #step-content.fade-out {
  opacity: 0;
  transform: translateX(-10px);
}

.calc-wrapper #step-content.fade-in {
  opacity: 0;
  transform: translateX(10px);
}

/* --------------------------------------------------------------------------
   14. Print Styles
   -------------------------------------------------------------------------- */

@media print {
  .site-header,
  .site-footer,
  .breadcrumbs,
  .article-content,
  .calc-wrapper .step-nav,
  .calc-wrapper .stepper,
  .calc-wrapper .nav-buttons,
  .calc-wrapper .print-hidden {
    display: none !important;
  }

  .calc-wrapper .card {
    box-shadow: none;
    border: 1px solid #ccc;
  }

  .calculator-section {
    margin-top: 0;
  }

  body {
    padding: 0;
    margin: 0;
  }

  .container {
    max-width: 100%;
    padding: 0;
  }
}

/* --------------------------------------------------------------------------
   15. Responsive Utilities
   -------------------------------------------------------------------------- */

@media (max-width: 639px) {
  .calc-wrapper .card {
    padding: 1.25rem;
  }

  .calc-wrapper .form-row {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 640px) {
  .calc-wrapper .card {
    padding: 2rem;
  }
}

/* --------------------------------------------------------------------------
   16. Bridge Styles (app.js class names)
   -------------------------------------------------------------------------- */

/* Stepper mobile: app.js generates stepper-step-label / stepper-step-title */
.calc-wrapper .stepper-step-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: block;
  margin-bottom: 0.15rem;
}

.calc-wrapper .stepper-step-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  display: block;
}

/* Stepper desktop: override display to flex for the structure app.js generates */
@media (min-width: 640px) {
  .calc-wrapper .stepper-desktop {
    display: flex;
    align-items: flex-start;
    justify-content: center;
  }
}

.calc-wrapper .stepper-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.calc-wrapper .stepper-circle {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 2px solid var(--border);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  background: transparent;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.calc-wrapper .stepper-item.active .stepper-circle {
  background-color: var(--blue-600);
  border-color: var(--blue-600);
  color: #fff;
}

.calc-wrapper .stepper-item.completed .stepper-circle {
  background-color: var(--green-500);
  border-color: var(--green-500);
  color: #fff;
}

.calc-wrapper .stepper-title {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-align: center;
  max-width: 80px;
}

.calc-wrapper .stepper-item.active .stepper-title {
  color: var(--blue-600);
  font-weight: 600;
}

.calc-wrapper .stepper-line {
  width: 3rem;
  height: 2px;
  margin-top: 15px;
  background-color: var(--border);
  transition: background-color 0.3s ease;
  flex-shrink: 0;
}

.calc-wrapper .stepper-line.completed {
  background-color: var(--blue-600);
}

/* Selection grid variants */
.calc-wrapper .selection-grid-2x2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.calc-wrapper .selection-grid-2x3 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .calc-wrapper .selection-grid-2x3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Form: price row & popular volumes */
.calc-wrapper .price-row {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 0.75rem;
}

.calc-wrapper .price-input {
  width: 100%;
}

.calc-wrapper .currency-select {
  width: 100%;
}

.calc-wrapper .popular-volumes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
  align-items: center;
}

.calc-wrapper .popular-label {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Results */
.calc-wrapper .result-container {}

.calc-wrapper .result-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
  text-align: center;
}

.calc-wrapper .result-summary {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.calc-wrapper .breakdown-table {}

.calc-wrapper .totals-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 1.25rem;
}

@media (min-width: 640px) {
  .calc-wrapper .totals-row {
    grid-template-columns: 1fr 1fr;
  }
}

.calc-wrapper .total-card {
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
  border: 1px solid;
}

.calc-wrapper .total-card-blue {
  background-color: var(--blue-50);
  border-color: var(--blue-200);
}

.calc-wrapper .total-card-blue .total-card-label {
  color: var(--blue-600);
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.calc-wrapper .total-card-blue .total-card-value {
  color: var(--blue-700);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}

.calc-wrapper .total-card-blue .total-card-secondary {
  color: var(--blue-500);
  font-size: 0.75rem;
  margin-top: 0.15rem;
}

.calc-wrapper .total-card-orange {
  background-color: var(--orange-50);
  border-color: var(--orange-200);
}

.calc-wrapper .total-card-orange .total-card-label {
  color: var(--orange-600);
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.calc-wrapper .total-card-orange .total-card-value {
  color: var(--orange-600);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}

.calc-wrapper .total-card-orange .total-card-secondary {
  color: var(--orange-600);
  opacity: 0.7;
  font-size: 0.75rem;
  margin-top: 0.15rem;
}

/* Navigation buttons */
.calc-wrapper .nav-buttons {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

/* Exchange bar live indicator */
.calc-wrapper .exchange-live {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--green-500);
  vertical-align: middle;
}

.calc-wrapper .exchange-date {
  opacity: 0.8;
}

/* Result actions */
.calc-wrapper .result-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}

/* Params form wrapper */
.calc-wrapper .params-form {}

/* Step content transitions (app.js applies to #calculator-app) */
.calc-wrapper #calculator-app {
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.calc-wrapper #calculator-app.fade-out {
  opacity: 0;
  transform: translateX(-10px);
}

.calc-wrapper #calculator-app.fade-in {
  opacity: 0;
  transform: translateX(10px);
}

/* ==========================================================================
   17. Excise Article Styles
   Scoped under .excise-article to avoid collisions
   ========================================================================== */

.excise-article {
  margin-top: 2.5rem;
}

/* Override .article-content defaults inside excise-article */
.article-content .excise-article h2 {
  margin: 0 0 32px;
  padding: 0;
  font-size: inherit;
}

.article-content .excise-article p {
  margin-bottom: 0;
}

/* --- Intro text --- */
.excise-intro {
  margin-bottom: 3.5rem;
}

.excise-intro-text {
  font-size: 0.95rem;
  color: var(--text-light);
  line-height: 1.75;
}

.excise-intro-text p {
  margin-bottom: 1rem;
}

.excise-intro-text p:last-child {
  margin-bottom: 0;
}

.excise-intro-text strong {
  color: var(--text);
  font-weight: 600;
}

/* --- News banner --- */
.excise-news-banner {
  background: rgba(202, 138, 4, 0.08);
  border: 1px solid rgba(202, 138, 4, 0.2);
  border-radius: 10px;
  padding: 14px 18px;
  margin-bottom: 3.5rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

[data-theme="dark"] .excise-news-banner {
  background: rgba(251, 191, 36, 0.08);
  border-color: rgba(251, 191, 36, 0.2);
}

.excise-news-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.excise-news-text {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.6;
}

.excise-news-text strong {
  color: #ca8a04;
  font-weight: 600;
}

[data-theme="dark"] .excise-news-text strong {
  color: #fbbf24;
}

/* --- How to use (steps grid) --- */
.excise-how-to {
  margin-bottom: 4rem;
}

.excise-how-to-title {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 32px;
  color: var(--text);
}

.excise-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.excise-step {
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 16px;
}

[data-theme="dark"] .excise-step {
  background: var(--bg-light);
}

.excise-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.1);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}

[data-theme="dark"] .excise-step-num {
  background: rgba(59, 130, 246, 0.15);
}

.excise-step-title {
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 3px;
  color: var(--text);
}

.excise-step-desc {
  font-size: 0.8rem;
  color: var(--text-light);
  line-height: 1.5;
}

/* --- What's included (grid) --- */
.excise-includes {
  margin-bottom: 4rem;
}

.excise-includes-title {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 32px;
  color: var(--text);
}

.excise-includes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 8px;
}

.excise-include-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.excise-include-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 6px;
}

.excise-include-dot.green { background: #16a34a; }
.excise-include-dot.orange { background: #ea580c; }
.excise-include-dot.blue { background: var(--accent); }
.excise-include-dot.purple { background: #7c3aed; }
.excise-include-dot.yellow { background: #ca8a04; }

[data-theme="dark"] .excise-include-dot.green { background: #34d399; }
[data-theme="dark"] .excise-include-dot.orange { background: #fb923c; }
[data-theme="dark"] .excise-include-dot.blue { background: #60a5fa; }
[data-theme="dark"] .excise-include-dot.purple { background: #a78bfa; }
[data-theme="dark"] .excise-include-dot.yellow { background: #fbbf24; }

.excise-include-label {
  font-weight: 600;
  font-size: 0.86rem;
  color: var(--text);
}

.excise-include-desc {
  font-size: 0.76rem;
  color: var(--text-light);
  margin-top: 1px;
}

/* --- Disclaimer --- */
.excise-disclaimer {
  background: rgba(234, 88, 12, 0.06);
  border: 1px solid rgba(234, 88, 12, 0.18);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.84rem;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 2.5rem;
}

[data-theme="dark"] .excise-disclaimer {
  background: rgba(251, 146, 60, 0.08);
  border-color: rgba(251, 146, 60, 0.2);
}

.excise-disclaimer-icon {
  font-size: 1rem;
  flex-shrink: 0;
}

.excise-disclaimer em {
  font-style: italic;
  color: #ea580c;
}

[data-theme="dark"] .excise-disclaimer em {
  color: #fb923c;
}

/* --- Divider --- */
.excise-divider {
  height: 1px;
  background: var(--border);
  margin: 0 0 3.5rem;
}

/* --- Section block (tables) --- */
.excise-section {
  margin-bottom: 3rem;
}

.excise-section-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

.excise-section-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.excise-section-icon.fuel { background: rgba(234, 88, 12, 0.08); }
.excise-section-icon.diesel { background: rgba(59, 130, 246, 0.08); }
.excise-section-icon.moto { background: rgba(168, 85, 247, 0.08); }
.excise-section-icon.truck { background: rgba(248, 113, 113, 0.08); }
.excise-section-icon.retro { background: rgba(202, 138, 4, 0.08); }
.excise-section-icon.luxury { background: rgba(244, 114, 182, 0.08); }
.excise-section-icon.fee { background: rgba(52, 211, 153, 0.08); }
.excise-section-icon.electric { background: rgba(52, 211, 153, 0.08); }

[data-theme="dark"] .excise-section-icon.fuel { background: rgba(234, 88, 12, 0.15); }
[data-theme="dark"] .excise-section-icon.diesel { background: rgba(59, 130, 246, 0.15); }
[data-theme="dark"] .excise-section-icon.moto { background: rgba(168, 85, 247, 0.15); }
[data-theme="dark"] .excise-section-icon.truck { background: rgba(248, 113, 113, 0.15); }
[data-theme="dark"] .excise-section-icon.retro { background: rgba(202, 138, 4, 0.15); }
[data-theme="dark"] .excise-section-icon.luxury { background: rgba(244, 114, 182, 0.15); }
[data-theme="dark"] .excise-section-icon.fee { background: rgba(52, 211, 153, 0.15); }
[data-theme="dark"] .excise-section-icon.electric { background: rgba(52, 211, 153, 0.15); }

.excise-section-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.excise-section-subtitle {
  font-size: 0.76rem;
  color: var(--text-light);
  font-weight: 500;
  margin-top: 1px;
}

/* --- Card --- */
.excise-card {
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

/* --- Tables --- */
.excise-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.excise-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.86rem;
}

.excise-table thead th {
  background: var(--bg);
  font-weight: 600;
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-light);
  padding: 10px 12px;
  text-align: right;
  white-space: nowrap;
  border-bottom: 1px solid var(--border);
}

[data-theme="dark"] .excise-table thead th {
  background: var(--bg);
}

.excise-table thead th:first-child {
  text-align: left;
}

.excise-table tbody td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--border);
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  color: var(--text-light);
}

.excise-table tbody td:first-child {
  text-align: left;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.excise-table tbody tr:last-child td {
  border-bottom: none;
}

.excise-table tbody tr:hover {
  background: var(--bg);
}

[data-theme="dark"] .excise-table tbody tr:hover {
  background: var(--bg);
}

/* Age column colors */
.excise-col-young { color: #16a34a; }
.excise-col-mid { color: #ea580c; }
.excise-col-old { color: #dc2626; }

[data-theme="dark"] .excise-col-young { color: #34d399; }
[data-theme="dark"] .excise-col-mid { color: #fb923c; }
[data-theme="dark"] .excise-col-old { color: #f87171; }

/* --- Example box --- */
.excise-example {
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.18);
  border-radius: 10px;
  padding: 16px 18px;
  margin-top: 12px;
}

[data-theme="dark"] .excise-example {
  background: rgba(52, 211, 153, 0.08);
  border-color: rgba(52, 211, 153, 0.2);
}

.excise-example-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #059669;
  margin-bottom: 5px;
}

[data-theme="dark"] .excise-example-label {
  color: #34d399;
}

.excise-example-calc {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.6;
}

.excise-example-calc strong {
  color: var(--text);
  font-weight: 700;
}

.excise-example-result {
  font-size: 1.2rem;
  font-weight: 800;
  color: #059669;
  margin-top: 5px;
}

[data-theme="dark"] .excise-example-result {
  color: #34d399;
}

/* --- Info grid (customs fee) --- */
.excise-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 10px;
}

.excise-info-card {
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.excise-info-label {
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-light);
  font-weight: 600;
}

.excise-info-value {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.excise-info-value.green { color: #16a34a; }
.excise-info-value.orange { color: #ea580c; }

[data-theme="dark"] .excise-info-value.green { color: #34d399; }
[data-theme="dark"] .excise-info-value.orange { color: #fb923c; }

.excise-info-desc {
  font-size: 0.8rem;
  color: var(--text-light);
}

/* --- EV badges --- */
.excise-ev-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  padding: 16px;
}

.excise-ev-badge {
  border-radius: 10px;
  padding: 14px;
  text-align: center;
  border: 1px solid;
}

.excise-ev-badge.ev-full {
  background: rgba(16, 185, 129, 0.06);
  border-color: rgba(16, 185, 129, 0.18);
}

.excise-ev-badge.ev-plugin {
  background: rgba(59, 130, 246, 0.06);
  border-color: rgba(59, 130, 246, 0.18);
}

.excise-ev-badge.ev-hev {
  background: rgba(202, 138, 4, 0.06);
  border-color: rgba(202, 138, 4, 0.18);
}

[data-theme="dark"] .excise-ev-badge.ev-full {
  background: rgba(52, 211, 153, 0.08);
  border-color: rgba(52, 211, 153, 0.2);
}
[data-theme="dark"] .excise-ev-badge.ev-plugin {
  background: rgba(96, 165, 250, 0.08);
  border-color: rgba(96, 165, 250, 0.2);
}
[data-theme="dark"] .excise-ev-badge.ev-hev {
  background: rgba(251, 191, 36, 0.08);
  border-color: rgba(251, 191, 36, 0.2);
}

.excise-ev-icon {
  font-size: 1.4rem;
  margin-bottom: 5px;
}

.excise-ev-type {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text);
  margin-bottom: 2px;
}

.excise-ev-discount {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.ev-full .excise-ev-discount { color: #059669; }
.ev-plugin .excise-ev-discount { color: #2563eb; }
.ev-hev .excise-ev-discount { color: #ca8a04; }

[data-theme="dark"] .ev-full .excise-ev-discount { color: #34d399; }
[data-theme="dark"] .ev-plugin .excise-ev-discount { color: #60a5fa; }
[data-theme="dark"] .ev-hev .excise-ev-discount { color: #fbbf24; }

.excise-ev-note {
  font-size: 0.73rem;
  color: var(--text-light);
  margin-top: 2px;
}

/* --- Footer note --- */
/* FAQ accordion */
.excise-section-icon.faq { background: rgba(37, 99, 235, 0.08); }
[data-theme="dark"] .excise-section-icon.faq { background: rgba(59, 130, 246, 0.15); }

.excise-faq-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.excise-faq-item {
  border-bottom: 1px solid var(--border);
}

.excise-faq-item summary {
  cursor: pointer;
  padding: 14px 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.excise-faq-item summary::after {
  content: "+";
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--text-light);
  flex-shrink: 0;
  transition: transform 0.2s;
}

.excise-faq-item[open] summary::after {
  content: "−";
}

.excise-faq-item p {
  padding: 0 0 14px;
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.6;
}

.excise-footer {
  text-align: center;
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--text-light);
}

/* --- Responsive --- */
@media (max-width: 640px) {
  .excise-steps { grid-template-columns: 1fr 1fr; }
  .excise-includes-grid { grid-template-columns: 1fr; }
  .excise-table thead th,
  .excise-table tbody td { padding: 8px 9px; font-size: 0.78rem; }
  .excise-ev-grid { grid-template-columns: 1fr; }
}

@media (max-width: 420px) {
  .excise-steps { grid-template-columns: 1fr; }
}
