:root {
  color-scheme: light;
  --ink: #13231d;
  --muted: #587068;
  --line: #d7e0da;
  --paper: #f4f7f3;
  --panel: #ffffff;
  --leaf: #2f8f62;
  --deep: #0f241d;
  --sun: #efb43a;
  --coral: #d46645;
  --shadow: 0 18px 50px rgba(19, 35, 29, 0.09);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  letter-spacing: 0;
}

button, input, select { font: inherit; }
code { font-family: Consolas, "Courier New", monospace; }

.shell {
  width: min(1240px, calc(100% - 36px));
  margin: 0 auto;
}

.pec-banner {
  position: sticky;
  top: 0;
  z-index: 999;
  display: flex;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  padding: 10px 14px;
  background: var(--deep);
  color: #fff;
  font-weight: 800;
}

.pec-banner a { color: #9af2c3; text-decoration: none; }

.hero {
  padding: 36px 0 22px;
  background: linear-gradient(180deg, #ffffff 0%, var(--paper) 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.88fr) minmax(420px, 1.12fr);
  gap: 28px;
  align-items: center;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--leaf);
  font-size: 0.84rem;
  font-weight: 900;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  max-width: 880px;
  margin-bottom: 14px;
  font-size: clamp(2.2rem, 5vw, 5rem);
  line-height: 0.96;
}

h2 { margin-bottom: 0; font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { margin-bottom: 12px; font-size: 1.12rem; }

.lead {
  max-width: 72ch;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.55;
}

.cta-row, .csv-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.btn {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  text-decoration: none;
}

.btn.primary { background: var(--deep); color: #fff; border-color: var(--deep); }

.trial-gate {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(15, 36, 29, 0.72);
  backdrop-filter: blur(8px);
}

.trial-gate[hidden] {
  display: none;
}

.trial-card {
  width: min(920px, 100%);
  max-height: min(92vh, 860px);
  overflow: auto;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.trial-status,
.trial-inline {
  color: var(--muted);
}

.trial-inline {
  margin: 8px 0 0;
}

.unlock-block {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.offers-section {
  display: grid;
  gap: 18px;
}

.offer-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.offer-card {
  min-height: 208px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
}

.offer-card.featured {
  border-color: rgba(47, 143, 98, 0.55);
  background: rgba(47, 143, 98, 0.08);
}

.offer-card span {
  color: var(--leaf);
  font-size: 0.82rem;
  font-weight: 900;
  text-transform: uppercase;
}

.offer-card strong {
  font-size: 1.25rem;
}

.offer-card em {
  color: var(--ink);
  font-size: 1.55rem;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

.offer-card p {
  color: var(--muted);
  line-height: 1.45;
}

.offer-card ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.35;
}

.pricing-note {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.bank-transfer {
  display: grid;
  gap: 14px;
  margin-top: 16px;
  padding: 16px;
  border: 1px solid rgba(47, 143, 98, 0.32);
  border-radius: 8px;
  background: #f6faf7;
}

.bank-transfer h3 {
  margin-bottom: 8px;
}

.bank-transfer p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.5;
}

.payment-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.payment-steps div {
  min-height: 92px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.payment-steps dt {
  color: var(--leaf);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.payment-steps dd {
  margin: 0;
  color: var(--ink);
  font-weight: 800;
  line-height: 1.35;
}

.payment-iban {
  overflow-wrap: anywhere;
  font-family: Consolas, "Courier New", monospace;
  letter-spacing: 0;
}

.trial-expired .simulator,
.trial-expired .data-import {
  position: relative;
}

.trial-expired .simulator::after,
.trial-expired .data-import::after {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  background: rgba(244, 247, 243, 0.6);
  content: "";
  pointer-events: none;
}

.hero-media {
  position: relative;
  min-height: 420px;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.market-card {
  position: absolute;
  left: 18px;
  bottom: 18px;
  max-width: min(360px, calc(100% - 36px));
  display: grid;
  gap: 4px;
  padding: 14px;
  border-radius: 8px;
  background: rgba(15, 36, 29, 0.88);
  color: #fff;
}

.market-card strong { font-size: 2rem; line-height: 1; }
.market-card small { color: #dbe8df; }

.trust-grid,
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 20px 0;
}

.trust-grid article,
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 10px 28px rgba(19, 35, 29, 0.05);
}

.trust-grid article {
  min-height: 136px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 18px;
}

.trust-grid span,
.trust-grid small,
.field span,
.metric-grid span,
.data-import p,
.card p,
.contacts p,
.footer {
  color: var(--muted);
}

.trust-grid strong { font-size: 1.25rem; }

.daily-pulse {
  display: grid;
  grid-template-columns: minmax(320px, 0.92fr) minmax(420px, 1.08fr);
  gap: 14px;
  align-items: stretch;
  margin: 20px 0;
  padding: 22px;
  border: 1px solid rgba(47, 143, 98, 0.28);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.daily-copy {
  display: grid;
  align-content: center;
  gap: 12px;
}

.daily-copy h2 {
  max-width: 760px;
}

.daily-copy p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.daily-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: end;
  margin-top: 4px;
}

.threshold-field {
  min-width: min(240px, 100%);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 8px;
  color: var(--muted);
  font-weight: 800;
}

.threshold-field span {
  grid-column: 1 / -1;
}

.threshold-field input {
  width: 150px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
  color: var(--ink);
}

.threshold-field small {
  align-self: center;
}

.watch-status {
  min-height: 24px;
  font-weight: 800;
}

.pulse-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.pulse-card {
  min-height: 138px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
}

.pulse-card span,
.pulse-card small {
  color: var(--muted);
}

.pulse-card strong {
  overflow-wrap: anywhere;
  font-size: clamp(1.5rem, 2.6vw, 2.3rem);
  line-height: 1;
}

.energy-chart {
  grid-column: 1 / -1;
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
}

.chart-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.chart-head div {
  display: grid;
  gap: 4px;
}

.chart-head span,
.chart-head small,
.chart-axis {
  color: var(--muted);
}

.chart-head strong {
  font-size: 1.08rem;
}

.chart-canvas {
  min-height: 220px;
}

.chart-canvas svg {
  width: 100%;
  height: auto;
  display: block;
}

.chart-grid {
  fill: none;
  stroke: rgba(88, 112, 104, 0.18);
  stroke-width: 1;
}

.chart-area {
  fill: rgba(47, 143, 98, 0.12);
}

.chart-line {
  fill: none;
  stroke: #246f4d;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4;
}

.chart-dot {
  fill: #fff;
  stroke: #246f4d;
  stroke-width: 3;
}

.chart-axis {
  fill: currentColor;
  font-size: 12px;
  font-weight: 800;
}

.chart-axis.end {
  text-anchor: end;
}

.chart-empty {
  min-height: 220px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 800;
  text-align: center;
}

.simulator, .panel {
  margin-bottom: 18px;
}

.section-head,
.result-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}

.sim-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(260px, 0.72fr) minmax(420px, 1.28fr);
  gap: 14px;
}

.panel {
  padding: 20px;
}

.field {
  display: grid;
  gap: 8px;
  margin-bottom: 15px;
}

.field output {
  color: var(--ink);
  font-weight: 900;
}

.field input,
.field select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
  color: var(--ink);
}

.field input[type="range"] {
  min-height: auto;
  padding: 0;
  accent-color: var(--leaf);
}

.toggle {
  display: flex;
  gap: 9px;
  align-items: center;
  color: var(--muted);
}

.toggle input { width: 18px; height: 18px; accent-color: var(--leaf); }

.price-note {
  padding: 14px;
  margin-bottom: 14px;
  border-left: 4px solid var(--leaf);
  background: #f5f8f4;
  color: var(--muted);
  line-height: 1.45;
}

.badge {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  justify-content: center;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(47, 143, 98, 0.14);
  color: #1c6946;
  font-size: 0.88rem;
  font-weight: 900;
  text-align: center;
}

.badge.warn { background: rgba(239, 180, 58, 0.2); color: #835500; }
.badge.risk { background: rgba(212, 102, 69, 0.15); color: #87331d; }

.metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.metric-grid article {
  min-height: 126px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
}

.metric-grid strong {
  overflow-wrap: anywhere;
  font-size: clamp(1.45rem, 2.7vw, 2.4rem);
  line-height: 1;
}

.data-import {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(280px, 0.74fr);
  gap: 18px;
  align-items: center;
}

.file-drop {
  min-width: 240px;
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px dashed #9eb6aa;
  border-radius: 8px;
  background: #f5f8f4;
  cursor: pointer;
}

.file-drop input { width: 100%; }
.file-drop span { color: var(--muted); }

.card { min-height: 156px; }
.contacts a { color: #0e5c41; }

.legal-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 20px 0;
}

.legal-strip article {
  min-height: 164px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(19, 35, 29, 0.05);
}

.legal-strip span {
  color: var(--leaf);
  font-size: 0.82rem;
  font-weight: 900;
  text-transform: uppercase;
}

.legal-strip strong {
  font-size: 1.18rem;
}

.legal-strip p,
.legal-updated,
.legal-block p {
  color: var(--muted);
  line-height: 1.55;
}

.legal-page {
  padding: 42px 0 24px;
}

.legal-page h1 {
  max-width: 900px;
  font-size: clamp(2.2rem, 4vw, 4rem);
}

.legal-block {
  max-width: 940px;
  margin: 18px 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.legal-block h2 {
  margin-bottom: 10px;
  font-size: 1.35rem;
}

.legal-block a,
.footer a {
  color: #0e5c41;
  font-weight: 800;
}

.legal-footer {
  border-top: 1px solid var(--line);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 0 42px;
  font-size: 0.9rem;
}

@media (max-width: 1060px) {
  .hero-grid,
  .daily-pulse,
  .sim-grid,
  .data-import {
    grid-template-columns: 1fr;
  }

  .offer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .legal-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-media { min-height: 340px; }
}

@media (max-width: 760px) {
  .shell { width: min(100% - 24px, 1240px); }
  .pec-banner { justify-content: flex-start; }
  .trust-grid,
  .grid-3,
  .offer-grid,
  .legal-strip,
  .payment-steps,
  .pulse-grid,
  .metric-grid {
    grid-template-columns: 1fr;
  }
  .section-head,
  .result-head,
  .chart-head,
  .footer {
    flex-direction: column;
  }
}
