@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --roi-primary:       #318DD8;
  --roi-hero-bg:       #101418;
  --roi-hero-fg:       #F5F5F5;
  --roi-hero-muted:    #97A1AA;
  --roi-surface-card:  #272E35;
  --roi-profit:        #2EB867;
  --roi-warning:       #F49D25;
  --roi-border-muted:  rgba(151, 161, 170, 0.15);
  --roi-border-muted-faint: rgba(151, 161, 170, 0.10);
  --roi-white-3:       rgba(255,255,255,0.03);
  --roi-radius:        0.75rem;
}

/* ─── Wrapper ─────────────────────────────────────────── */
.roi-calc-wrap {
  font-family: 'Inter', system-ui, sans-serif;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

/* ─── Outer card ─────────────────────────────────────── */
.roi-calc-card {
  background: #272e35b3;
  border: 1px solid var(--roi-border-muted);
  border-radius: 1rem;
  overflow: hidden;
  color: var(--roi-hero-fg);
}

/* ─── Header ─────────────────────────────────────────── */
.roi-calc-header {
  padding: 32px 32px 24px;
  border-bottom: 1px solid var(--roi-border-muted-faint);
}

.roi-calc-header-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}

.roi-icon-calculator {
  color: var(--roi-primary);
  flex-shrink: 0;
  width: 20px;
  height: 20px;
}

.roi-calc-title {
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  color: var(--roi-hero-fg) !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.3 !important;
}

.roi-calc-subtitle {
  font-size: 0.875rem;
  color: var(--roi-hero-muted);
  margin: 0;
  padding: 0;
}

/* ─── Body (2 columns) ───────────────────────────────── */
.roi-calc-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

/* ─── Section label ─────────────────────────────────── */
.roi-section-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--roi-primary);
  margin: 0 0 20px 0;
  padding: 0;
}

/* ─── LEFT: Sliders ──────────────────────────────────── */
.roi-calc-left {
  padding: 32px;
  border-right: 1px solid var(--roi-border-muted-faint);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.roi-slider-group {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.roi-slider-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}

.roi-slider-label {
  font-size: 0.875rem;
  color: var(--roi-hero-muted);
  flex: 1;
  padding-right: 8px;
}

.roi-slider-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--roi-hero-fg);
  white-space: nowrap;
}

/* Range slider */
.roi-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(151, 161, 170, 0.25);
  accent-color: var(--roi-primary);
  cursor: pointer;
  outline: none;
}

.roi-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--roi-primary);
  cursor: pointer;
  border: 2px solid #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
  transition: transform 0.15s;
}

.roi-range::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.roi-range::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--roi-primary);
  cursor: pointer;
  border: 2px solid #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.roi-range::-webkit-slider-runnable-track {
  border-radius: 999px;
}

.roi-slider-limits {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: rgba(151, 161, 170, 0.5);
  margin-top: 4px;
}

/* ─── RIGHT: Results ─────────────────────────────────── */
.roi-calc-right {
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.roi-cards {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

/* Result card */
.roi-result-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border-radius: var(--roi-radius);
  border: 1px solid var(--roi-border-muted);
  background: var(--roi-white-3);
  transition: border-color 0.2s;
}

/* Total card override */
.roi-total-card {
  border-color: rgba(49, 141, 216, 0.40);
  background: rgba(49, 141, 216, 0.10);
}

/* Icon wrapper */
.roi-card-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.roi-icon-muted {
  background: rgba(151, 161, 170, 0.10);
  color: var(--roi-hero-muted);
}

.roi-icon-primary {
  background: rgba(49, 141, 216, 0.20);
  color: var(--roi-primary);
}

/* Card text */
.roi-card-content {
  flex: 1;
  min-width: 0;
}

.roi-card-title {
  font-size: 0.75rem;
  color: var(--roi-hero-muted);
  margin: 0 0 2px 0;
  padding: 0;
}

.roi-card-desc {
  font-size: 0.625rem;
  color: rgba(151, 161, 170, 0.5);
  margin: 0;
  padding: 0;
  line-height: 1.4;
}

/* Card value */
.roi-card-value {
  font-size: 1.125rem;
  font-weight: 700;
  flex-shrink: 0;
  white-space: nowrap;
}

.roi-warning  { color: var(--roi-warning); }
.roi-profit   { color: var(--roi-profit); }
.roi-primary  { color: var(--roi-primary); }

/* Total wrapper */
.roi-total-wrap {
  border-top: 1px solid var(--roi-border-muted);
  padding-top: 14px;
}

.roi-disclaimer {
  font-size: 0.625rem;
  color: rgba(151, 161, 170, 0.4);
  text-align: center;
  margin: 10px 0 0 0;
  padding: 0;
}

/* ─── Responsive ─────────────────────────────────────── */
@media (max-width: 680px) {
  .roi-calc-body {
    grid-template-columns: 1fr;
  }

  .roi-calc-left {
    border-right: none;
    border-bottom: 1px solid var(--roi-border-muted-faint);
  }

  .roi-calc-header,
  .roi-calc-left,
  .roi-calc-right {
    padding: 20px;
  }
}
