:root {
  --bg: #0f1729;
  --bg-soft: #1a2540;
  --card: #ffffff;
  --ink: #0f1729;
  --ink-soft: #5b6b8c;
  --line: #e3e8f2;
  --accent: #2563eb;
  --accent-ink: #1d4ed8;
  --good: #059669;
  --bad: #dc2626;
  --radius: 16px;
  --shadow: 0 10px 40px rgba(15, 23, 41, 0.12);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 80% -10%, #1e3a8a 0%, transparent 60%),
    radial-gradient(900px 500px at -10% 10%, #312e81 0%, transparent 55%),
    var(--bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 980px;
  margin: 0 auto;
  padding: clamp(1.5rem, 4vw, 3.5rem) clamp(1rem, 4vw, 2rem) 2rem;
}

/* Product name — the tool's title, above the headline */
.product-name {
  text-align: center;
  color: #c7d2fe;
  font-weight: 700;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  letter-spacing: 0.04em;
  margin: 0 0 0.5rem;
}

/* Intro */
.intro {
  text-align: center;
  color: #fff;
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}
.intro h1 {
  font-size: clamp(1.6rem, 4.5vw, 2.6rem);
  line-height: 1.1;
  margin: 0 0 0.6rem;
  letter-spacing: -0.02em;
}
.intro p {
  margin: 0;
  color: #c7d2fe;
  font-size: clamp(1rem, 2.5vw, 1.15rem);
}

/* Layout */
.layout {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(1rem, 3vw, 1.75rem);
  align-items: start;
}
@media (max-width: 760px) {
  .layout { grid-template-columns: 1fr; }
}

/* Cards */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(1.25rem, 3vw, 2rem);
}
.card-title {
  margin: 0 0 1.25rem;
  font-size: 1.05rem;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
}

/* Inputs */
.field { margin-bottom: 1.1rem; }
.field:last-child { margin-bottom: 0; }
.field label {
  display: block;
  font-size: 0.92rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--ink);
}
.optional {
  color: var(--ink-soft);
  font-weight: 400;
}
.field-hint {
  margin: 0.4rem 0 0;
  font-size: 0.82rem;
  color: var(--ink-soft);
}
.field input {
  width: 100%;
  padding: 0.7rem 0.85rem;
  font-size: 1.05rem;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}
.input-prefix {
  position: relative;
  display: flex;
  align-items: center;
}
.input-prefix .prefix {
  position: absolute;
  left: 0.85rem;
  color: var(--ink-soft);
  font-size: 1.05rem;
  pointer-events: none;
}
.input-prefix input { padding-left: 1.7rem; }

/* Results */
.results-for {
  margin: 0 0 1rem;
  font-weight: 700;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

/* ROI hero — the headline number */
.roi-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: linear-gradient(135deg, #2563eb 0%, #4f46e5 100%);
  color: #fff;
  border-radius: 14px;
  padding: clamp(1.25rem, 4vw, 2rem) 1rem;
  margin-bottom: 1.25rem;
}
.roi-hero.is-negative {
  background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
}
.roi-label {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
  font-weight: 700;
  opacity: 0.85;
}
.roi-value {
  font-size: clamp(3rem, 12vw, 5rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  margin: 0.35rem 0;
}
.roi-sub {
  font-size: 0.9rem;
  opacity: 0.9;
}

/* Secondary result grid */
.result-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}
@media (max-width: 420px) {
  .result-grid { grid-template-columns: 1fr; }
}
.result-block {
  background: #f7f9fd;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.result-label {
  font-size: 0.82rem;
  color: var(--ink-soft);
  font-weight: 600;
}
.result-value {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--ink);
}

/* Net savings emphasis */
.net-savings {
  margin-top: 1rem;
  padding: 1rem 1.15rem;
  border-radius: 10px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.net-savings .result-value { color: var(--good); font-size: 1.5rem; }
.net-savings.is-negative {
  background: #fef2f2;
  border-color: #fecaca;
}
.net-savings.is-negative .result-value { color: var(--bad); }

/* Footer */
.foot {
  text-align: center;
  margin-top: 2rem;
  color: #93a4c8;
  font-size: 0.82rem;
}
.foot p { margin: 0; }
.foot-brand {
  color: #c7d2fe;
  font-weight: 600;
  margin-bottom: 0.35rem !important;
}
.foot-demo {
  color: #93a4c8;
  font-style: italic;
  margin-bottom: 0.6rem !important;
}
