/* ============================================
   E.ON Happy Hours – Full Flow
   4-Screen Design System
   ============================================ */

/* ---- RESET & BASE ---- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --eon-red: #E30613;
  --eon-red-dark: #B8050F;
  --eon-red-light: #FEE2E2;
  --eon-red-50: #FFF5F5;

  --text-primary: #1E1E2E;
  --text-secondary: #4B5563;
  --text-muted: #8E8EA0;
  --text-light: #9CA3AF;

  --bg-app: #F5F5F7;
  --bg-secondary: #F3F4F6;
  --bg-white: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-legal: #F8F9FA;
  --bg-ppe: #FFF7ED;

  --green: #16A34A;
  --green-light: #F0FDF4;
  --blue: #2563EB;

  --border-light: #E5E7EB;
  --border-card: #EBEBEF;

  --shadow-card: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-card-hover: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-sticky: 0 -4px 20px rgba(0,0,0,0.08);
  --shadow-overlay: 0 25px 60px rgba(0,0,0,0.3);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 100px;

  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;
  --transition-spring: 300ms cubic-bezier(0.34,1.56,0.64,1);
}

html { font-size: 16px; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text-primary);
  background: #E5E7EB;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  height: 100dvh;
  padding: 16px;
  overflow: hidden;
}

a { color: var(--eon-red); text-decoration: none; }

/* ---- PROTOTYPE SIDE NAV ---- */
.proto-nav {
  position: fixed;
  top: 50%;
  left: 16px;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 4px;
  z-index: 999;
  max-width: 160px;
}

.proto-nav-label {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #9CA3AF;
  padding: 0 10px 4px;
}

.proto-nav a {
  display: block;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 500;
  color: #6B7280;
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(8px);
  border-radius: 8px;
  text-decoration: none;
  transition: all 150ms ease;
  border: 1px solid transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.proto-nav a:hover {
  color: var(--eon-red);
  background: white;
  border-color: var(--border-light);
  text-decoration: none;
}

.proto-nav a.proto-nav--active {
  color: var(--eon-red);
  background: white;
  font-weight: 700;
  border-color: var(--eon-red);
  box-shadow: 0 1px 4px rgba(227,6,19,0.12);
}

@media (max-width: 700px) {
  .proto-nav { display: none; }
}
a:hover { text-decoration: underline; }

/* ============================================
   APP SHELL (PHONE FRAME)
   ============================================ */
.app-shell {
  width: 100%;
  max-width: 393px;
  height: min(852px, calc(100vh - 32px));
  height: min(852px, calc(100dvh - 32px));
  background: var(--bg-app);
  border-radius: 40px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 0 0 8px #1E1E2E, 0 0 0 10px #3a3a4a, var(--shadow-overlay);
}

/* ============================================
   SCREEN SYSTEM (NAVIGATION)
   ============================================ */
.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateX(60px);
  pointer-events: none;
  transition: opacity 350ms ease, transform 350ms ease;
  z-index: 1;
  will-change: transform, opacity;
}

.screen.active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: all;
  z-index: 10;
}

/* ============================================
   EKRAN 1: LOCK SCREEN
   ============================================ */
.screen--lock {
  transform: none;
}
.screen--lock.active { transform: none; }
.screen--lock.exit-left { transform: none; opacity: 0; }

.lock-bg {
  flex: 1;
  background: linear-gradient(170deg, #0a0a1a 0%, #1a1a3e 40%, #2a1a4a 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px;
  position: relative;
  overflow: hidden;
}

.lock-bg::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(ellipse at 30% 20%, rgba(227,6,19,0.08) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 80%, rgba(37,99,235,0.06) 0%, transparent 50%);
  animation: lockBgShift 10s ease-in-out infinite alternate;
}

@keyframes lockBgShift {
  from { transform: translate(0, 0); }
  to { transform: translate(-3%, 3%); }
}

.lock-status-bar {
  width: 100%;
  text-align: center;
  padding: 54px 0 0;
  position: relative;
  z-index: 2;
}

.lock-time-small {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.3px;
}

.lock-clock {
  position: relative;
  z-index: 2;
  margin: 4px 0 40px;
}

.lock-time {
  font-size: 72px;
  font-weight: 700;
  color: white;
  letter-spacing: -2px;
  line-height: 1;
}

/* Push Notification */
.push-notification {
  width: 100%;
  background: rgba(255,255,255,0.14);
  backdrop-filter: blur(40px);
  -webkit-backdrop-filter: blur(40px);
  border-radius: var(--radius-xl);
  padding: 14px 16px;
  cursor: pointer;
  position: relative;
  z-index: 2;
  border: 1px solid rgba(255,255,255,0.12);
  transition: transform 200ms ease, box-shadow 200ms ease;
  animation: pushSlideIn 600ms cubic-bezier(0.34,1.56,0.64,1) 300ms backwards;
}

@keyframes pushSlideIn {
  from { opacity: 0; transform: translateY(-30px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.push-notification:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.push-notification:active {
  transform: scale(0.98);
}

.push-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.push-app-icon {
  width: 28px;
  height: 28px;
  background: white;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.push-app-name {
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,0.8);
  flex: 1;
}

.push-time {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
}

.push-body { display: flex; gap: 12px; }

.push-content { flex: 1; }

.push-title {
  font-size: 14px;
  font-weight: 700;
  color: white;
  margin-bottom: 4px;
  line-height: 1.3;
}

.push-text {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  line-height: 1.45;
}

.push-text strong { color: rgba(255,255,255,0.95); }

.push-hint {
  text-align: center;
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  margin-top: 10px;
  animation: hintPulse 2s ease-in-out infinite;
}

@keyframes hintPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.7; }
}

.lock-bottom {
  position: absolute;
  bottom: 30px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 30px;
  z-index: 2;
}

.lock-flashlight, .lock-camera {
  width: 44px;
  height: 44px;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lock-home-indicator {
  width: 120px;
  height: 5px;
  background: rgba(255,255,255,0.3);
  border-radius: 100px;
}

/* ============================================
   SHARED: STATUS BAR
   ============================================ */
.status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 28px 8px;
  flex-shrink: 0;
}

.status-bar--white { background: var(--bg-white); }

.status-time { font-size: 15px; font-weight: 600; letter-spacing: 0.5px; }
.status-icons { display: flex; align-items: center; gap: 6px; }

.battery-icon { display: flex; align-items: center; gap: 1px; }
.battery-body { width: 22px; height: 11px; border: 1.5px solid var(--text-primary); border-radius: 3px; padding: 1.5px; }
.battery-level { width: 100%; height: 100%; background: var(--text-primary); border-radius: 1px; }
.battery-tip { width: 2px; height: 5px; background: var(--text-primary); border-radius: 0 1px 1px 0; }

/* ============================================
   SHARED: NAV BAR
   ============================================ */
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px 12px;
  background: var(--bg-white);
  border-bottom: 1px solid var(--border-light);
  flex-shrink: 0;
}

.nav-back {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-primary);
  padding: 4px;
  border-radius: 8px;
  transition: background var(--transition-fast);
}
.nav-back:hover { background: var(--bg-app); }
.nav-title { display: flex; flex-direction: column; align-items: center; }
.nav-step { font-size: 13px; font-weight: 500; color: var(--text-muted); }
.nav-logo svg { display: block; }

/* ============================================
   SHARED: PROGRESS BAR
   ============================================ */
.progress-bar {
  padding: 12px 20px 16px;
  background: var(--bg-white);
  flex-shrink: 0;
}

.progress-track {
  height: 4px;
  background: var(--border-light);
  border-radius: 100px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--eon-red), #FF4D58);
  border-radius: 100px;
  transition: width 600ms cubic-bezier(0.34,1.56,0.64,1);
}

.progress-bar--success .progress-fill {
  background: linear-gradient(90deg, var(--green), #22C55E);
}

.progress-labels { display: flex; justify-content: space-between; margin-top: 8px; }
.progress-label { font-size: 11px; font-weight: 500; color: var(--text-light); transition: color var(--transition-normal); }
.progress-label.done { color: var(--text-muted); }
.progress-label.active { color: var(--eon-red); font-weight: 600; }
.progress-bar--success .progress-label.active { color: var(--green); }

/* ============================================
   SHARED: CONTENT AREA
   ============================================ */
.content {
  flex: 1;
  overflow-y: auto;
  padding: 20px 16px 0;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.content::-webkit-scrollbar { width: 4px; }
.content::-webkit-scrollbar-track { background: transparent; }
.content::-webkit-scrollbar-thumb { background: #D1D5DB; border-radius: 100px; }

/* ============================================
   SHARED: PAGE HEADER
   ============================================ */
.page-header { margin-bottom: 20px; padding: 0 4px; }
.page-title { font-size: 22px; font-weight: 700; color: var(--text-primary); line-height: 1.3; letter-spacing: -0.3px; }
.page-subtitle { font-size: 14px; color: var(--text-secondary); margin-top: 6px; line-height: 1.5; }

/* ============================================
   SHARED: CARDS
   ============================================ */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid var(--border-card);
  animation: cardSlideIn 400ms ease-out backwards;
}

@keyframes cardSlideIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 16px 0;
}

.card-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: var(--eon-red-50);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card-title { font-size: 15px; font-weight: 600; color: var(--text-primary); }
.card-body { padding: 16px; }

/* ============================================
   EKRAN 2: LANDING PAGE
   ============================================ */

/* Hero */
.hero {
  padding: 4px 4px 8px;
  margin-bottom: 16px;
}

.hero-greeting {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.hero-cta-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
  background: var(--eon-red);
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
}

.hero-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.2;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}

.hero-highlight {
  color: var(--eon-red);
  position: relative;
}

.hero-highlight::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 6px;
  background: var(--eon-red-light);
  border-radius: 3px;
  z-index: -1;
}

.hero-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Savings Card */
.savings-card {
  background: linear-gradient(135deg, #1E1E2E, #2D2D44);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
  color: white;
  position: relative;
  overflow: hidden;
}

.savings-card::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -20%;
  width: 160px;
  height: 160px;
  background: radial-gradient(circle, rgba(227,6,19,0.2) 0%, transparent 70%);
}

.savings-top {
  position: relative;
  z-index: 1;
}

.savings-label {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 4px;
}

.savings-amount {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.savings-tilde {
  font-size: 28px;
  font-weight: 300;
  color: rgba(255,255,255,0.5);
}

.savings-number {
  font-size: 48px;
  font-weight: 900;
  letter-spacing: -2px;
  line-height: 1;
  background: linear-gradient(135deg, #FFFFFF, #FFD1D1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.savings-currency {
  font-size: 16px;
  font-weight: 500;
  color: rgba(255,255,255,0.6);
  margin-left: 2px;
}

.savings-bar {
  height: 6px;
  background: rgba(255,255,255,0.1);
  border-radius: 100px;
  margin: 16px 0 8px;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.savings-bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--eon-red), #FF6B6B);
  border-radius: 100px;
  transition: width 1200ms cubic-bezier(0.34,1.56,0.64,1);
}

.savings-bar-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  position: relative;
  z-index: 1;
}

.savings-bar-savings {
  font-weight: 700;
  color: #FF6B6B;
}

/* Chart */
.chart-container {
  position: relative;
  display: flex;
  gap: 8px;
  height: 160px;
  padding-bottom: 24px;
}

.chart-y-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-size: 10px;
  color: var(--text-light);
  padding-bottom: 24px;
  width: 32px;
  text-align: right;
  flex-shrink: 0;
}

.chart-bars {
  flex: 1;
  display: flex;
  gap: 6px;
  align-items: flex-end;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-light);
  position: relative;
}

.chart-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  height: 100%;
  justify-content: flex-end;
}

.chart-col--highlight {
  position: relative;
}

.chart-col--highlight::before {
  content: '';
  position: absolute;
  inset: -4px -3px;
  bottom: 18px;
  background: rgba(22,163,74,0.06);
  border-radius: 8px;
  border: 1px dashed rgba(22,163,74,0.2);
}

.chart-bar-group {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.chart-bar {
  width: 70%;
  border-radius: 4px 4px 0 0;
  transition: height 800ms cubic-bezier(0.34,1.56,0.64,1);
}

.chart-bar--peak { background: linear-gradient(180deg, #FCA5A5, var(--eon-red-light)); border-radius: 4px 4px 0 0; }
.chart-bar--happy { background: linear-gradient(180deg, #86EFAC, #BBF7D0); }

.chart-bar-group--stacked {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 0;
}

.chart-bar-group--stacked .chart-bar {
  width: 70%;
  border-radius: 0;
}

.chart-bar-group--stacked .chart-bar--peak {
  border-radius: 4px 4px 0 0;
}

.chart-bar-group--stacked .chart-bar--happy {
  border-radius: 0 0 0 0;
}

.chart-label {
  font-size: 10px;
  font-weight: 500;
  color: var(--text-light);
  position: absolute;
  bottom: 0;
}

.chart-label--happy { color: var(--green); font-weight: 600; }

.chart-zone-label {
  position: absolute;
  top: -8px;
  right: 0;
}

.chart-zone-badge {
  font-size: 10px;
  font-weight: 700;
  color: var(--green);
  background: var(--green-light);
  border: 1px solid #BBF7D0;
  padding: 3px 8px;
  border-radius: var(--radius-full);
}

.chart-insight {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.chart-insight svg { flex-shrink: 0; }
.chart-insight strong { color: var(--green); }

.chart-legend {
  display: flex;
  gap: 16px;
  margin-top: 10px;
  margin-bottom: 4px;
}

.chart-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}

.chart-bar-val {
  position: absolute;
  top: -18px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 9px;
  font-weight: 700;
  color: var(--text-secondary);
  white-space: nowrap;
}

.chart-bar { position: relative; }

.chart-footnote {
  font-size: 10px;
  color: var(--text-light);
  margin-top: 8px;
  line-height: 1.4;
  font-style: italic;
}

/* Card label badges (Korzyść 1, 2, 3) */
.card-label-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-bottom: 2px;
}

.card-label-badge--green { color: var(--green); background: var(--green-light); }
.card-label-badge--blue { color: var(--blue); background: #EFF6FF; }
.card-label-badge--purple { color: #7C3AED; background: #F5F3FF; }

.card-data-source {
  display: block;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  margin-top: 2px;
}

.card-icon--green { background: var(--green-light); }
.card-icon--blue { background: #EFF6FF; }
.card-icon--purple { background: #F5F3FF; }

.card-intro {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 14px;
}

/* Happy Hours zones indicators */
.hh-zones {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
  padding: 12px;
  background: var(--green-light);
  border-radius: var(--radius-md);
  border: 1px solid #BBF7D0;
}

.hh-zones-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--green);
  margin-bottom: 2px;
}

.hh-zone {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-primary);
}

.hh-zone svg { flex-shrink: 0; }
.hh-zone strong { color: var(--green); }

/* Premium summary (68% + ~240 zł) */
.premium-summary {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: linear-gradient(135deg, #1E1E2E, #2D2D44);
  border-radius: var(--radius-md);
  margin: 14px 0;
  color: white;
}

.premium-stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.premium-stat-value {
  font-size: 32px;
  font-weight: 900;
  letter-spacing: -1px;
  line-height: 1;
  background: linear-gradient(135deg, #FFFFFF, #FFD1D1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.premium-stat-unit {
  font-size: 16px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  margin-left: 2px;
}

.premium-stat-row {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 2px;
}

.premium-stat-label {
  display: block;
  font-size: 11px;
  color: rgba(255,255,255,0.6);
  margin-top: 4px;
  line-height: 1.3;
}

.premium-stat-divider {
  width: 1px;
  height: 40px;
  background: rgba(255,255,255,0.15);
  flex-shrink: 0;
}

/* Freeze comparison mini */
/* Compare Table */
.compare-table { width: 100%; }

.compare-header, .compare-row {
  display: grid;
  grid-template-columns: 1fr 0.8fr 0.8fr;
  gap: 2px;
}

.compare-header {
  margin-bottom: 4px;
}

.compare-cell {
  padding: 8px 6px;
  font-size: 12px;
}

.compare-cell--label {
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.compare-cell-sub {
  font-size: 10px;
  color: var(--text-light);
  font-weight: 400;
}

.compare-cell--old, .compare-cell--new {
  text-align: center;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
}

.compare-cell--old { background: #F9FAFB; }
.compare-cell--new { background: var(--eon-red-50); }

.compare-badge {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-bottom: 2px;
}

.compare-badge--old { color: var(--text-muted); background: var(--border-light); }
.compare-badge--new { color: var(--eon-red); background: var(--eon-red-light); }

.compare-tariff {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
}

.compare-row {
  border-top: 1px solid var(--border-light);
}

.compare-row--highlight {
  background: var(--green-light);
  border-radius: var(--radius-sm);
  border-top: 1px solid #BBF7D0;
}

.compare-row--highlight .compare-cell--new { background: rgba(22,163,74,0.08); }

.compare-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.compare-price--green { color: var(--green); }

.compare-price-small {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.compare-unit {
  font-size: 10px;
  color: var(--text-muted);
}

.compare-na { font-size: 14px; color: var(--text-light); }

.compare-save {
  font-size: 10px;
  font-weight: 700;
  color: white;
  background: var(--green);
  padding: 1px 6px;
  border-radius: var(--radius-full);
  margin-top: 2px;
}

/* Benefits */
.benefits-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.benefit-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}

.benefit-item:hover { background: var(--bg-app); }

.benefit-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.benefit-icon--green { background: #F0FDF4; }
.benefit-icon--blue { background: #EFF6FF; }
.benefit-icon--emerald { background: #ECFDF5; }
.benefit-icon--purple { background: #F5F3FF; }

.benefit-text {
  font-size: 13px;
  line-height: 1.5;
}

.benefit-text strong {
  display: block;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.benefit-text span { color: var(--text-secondary); }

/* ============================================
   EKRAN 3: CHECKOUT COMPONENTS
   ============================================ */

/* Data Rows */
.data-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-light);
}
.data-row:last-of-type { border-bottom: none; }

.data-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.data-value { font-size: 15px; font-weight: 500; color: var(--text-primary); }
.ppe-row { padding-bottom: 4px; }

.ppe-value {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  padding: 10px 12px;
  background: var(--bg-ppe);
  border-radius: var(--radius-sm);
  border: 1px dashed #FDBA74;
}

.ppe-badge {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #C2410C;
  background: #FED7AA;
  padding: 3px 8px;
  border-radius: var(--radius-full);
}

.ppe-number {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.5px;
}

.card-footer-note {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: var(--bg-app);
  font-size: 12px;
  color: var(--text-muted);
  border-top: 1px solid var(--border-light);
}
.card-footer-note svg { flex-shrink: 0; }

.link-inline { color: var(--eon-red); font-weight: 500; text-decoration: none; }
.link-inline:hover { text-decoration: underline; }

/* Product Card */
.product-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.product-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #1E1E2E, #2D2D44);
  color: white;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
}

.product-badge-icon { font-size: 16px; }

.product-tariff {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg-app);
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.price-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.price-card {
  padding: 14px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.price-card--happy { background: linear-gradient(135deg, #F0FDF4, #ECFDF5); border-color: #BBF7D0; }
.price-card--peak { background: var(--bg-app); }

.price-card-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.price-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.price-dot--green { background: var(--green); }
.price-dot--red { background: var(--eon-red); }

.price-tag {
  flex-basis: 100%;
  width: fit-content;
  margin-top: 3px;
  font-size: 9px;
  font-weight: 700;
  color: var(--green);
  background: #DCFCE7;
  padding: 2px 6px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.price-card-value {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}

.price-unit { font-size: 13px; font-weight: 500; color: var(--text-muted); }
.price-card-unit { font-size: 13px; font-weight: 500; color: var(--text-muted); margin-top: -2px; }
.price-card-brutto { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); margin-top: 4px; }
.price-card-desc { font-size: 11px; color: var(--text-muted); line-height: 1.3; }

.detail-rows { border-top: 1px solid var(--border-light); padding-top: 12px; }

.detail-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
}
.detail-row:not(:last-child) { border-bottom: 1px solid var(--border-light); }

.detail-label { font-size: 13px; color: var(--text-secondary); }
.detail-value { font-size: 13px; font-weight: 600; color: var(--text-primary); display: flex; align-items: center; gap: 4px; }
.detail-value--strong { color: var(--eon-red); }

.bonus-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  background: var(--green-light);
  border-radius: var(--radius-md);
  border: 1px solid #BBF7D0;
}

.bonus-icon {
  width: 36px;
  height: 36px;
  background: white;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.bonus-text { font-size: 13px; line-height: 1.5; }
.bonus-text strong { display: block; color: #166534; font-weight: 600; margin-bottom: 2px; }
.bonus-text span { color: var(--text-secondary); }

/* Documents */
.doc-grid { display: flex; flex-direction: column; gap: 8px; }

.doc-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-app);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  text-decoration: none;
  color: var(--text-primary);
  transition: all var(--transition-fast);
}

.doc-tile:hover {
  background: var(--eon-red-50);
  border-color: var(--eon-red);
  box-shadow: var(--shadow-card-hover);
  text-decoration: none;
  transform: translateY(-1px);
}

.doc-tile-icon { flex-shrink: 0; }
.doc-tile-text { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.doc-tile-title { font-size: 13px; font-weight: 600; }
.doc-tile-size { font-size: 11px; color: var(--text-muted); }
.doc-tile-download { flex-shrink: 0; transition: transform var(--transition-fast); }
.doc-tile:hover .doc-tile-download { transform: translateY(2px); stroke: var(--eon-red); }

.doc-notice {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--text-muted);
}
.doc-notice svg { flex-shrink: 0; }

/* Consents */
.consent-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px;
  margin-bottom: 8px;
  background: var(--bg-app);
  border-radius: var(--radius-md);
  border: 2px solid var(--border-light);
  cursor: pointer;
  transition: all var(--transition-normal);
  min-height: 44px;
  -webkit-tap-highlight-color: transparent;
}

.consent-item:last-of-type { margin-bottom: 0; }
.consent-item:hover { border-color: #D1D5DB; background: #F9FAFB; }
.consent-item.checked { border-color: var(--eon-red); background: var(--eon-red-50); }

.consent-item.error {
  border-color: var(--eon-red);
  background: #FEF2F2;
  animation: shakeError 400ms ease;
}

@keyframes shakeError {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

.consent-item--optional { opacity: 0.85; }
.consent-item--optional.checked { opacity: 1; }

.consent-checkbox {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.consent-checkmark {
  width: 24px;
  height: 24px;
  min-width: 24px;
  border-radius: 6px;
  border: 2px solid #D1D5DB;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-spring);
  margin-top: 2px;
}

.consent-checkmark svg {
  opacity: 0;
  transform: scale(0.5);
  transition: all var(--transition-spring);
}

.consent-item.checked .consent-checkmark { background: var(--eon-red); border-color: var(--eon-red); }
.consent-item.checked .consent-checkmark svg { opacity: 1; transform: scale(1); }
.consent-item.error .consent-checkmark { border-color: var(--eon-red); box-shadow: 0 0 0 3px rgba(227,6,19,0.15); }

.consent-text {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
  flex: 1;
}

.consent-required-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--eon-red);
  background: var(--eon-red-light);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-bottom: 4px;
}

.consent-optional-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  background: var(--border-light);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-bottom: 4px;
}

.consent-error {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  margin-top: 12px;
  background: #FEF2F2;
  border-radius: var(--radius-sm);
  border: 1px solid var(--eon-red-light);
  font-size: 13px;
  font-weight: 500;
  color: var(--eon-red);
}

.consent-error.visible {
  display: flex;
  animation: slideDown 300ms ease-out;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Legal Footer */
.legal-footer {
  background: var(--bg-legal);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid var(--border-light);
}

.legal-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
}
.legal-item:not(:last-child) { border-bottom: 1px solid var(--border-light); }
.legal-item svg { flex-shrink: 0; margin-top: 1px; }
.legal-item p { font-size: 12px; line-height: 1.6; color: #6B7280; }
.legal-item strong { color: var(--text-secondary); }

.link-inline-muted {
  color: #6B7280;
  text-decoration: underline;
  text-decoration-color: #D1D5DB;
  text-underline-offset: 2px;
}
.link-inline-muted:hover { color: var(--eon-red); }

/* ============================================
   SHARED: CTA BAR
   ============================================ */
.cta-spacer { height: 140px; }

.cta-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-white);
  padding: 12px 16px 28px;
  border-top: 1px solid var(--border-light);
  box-shadow: var(--shadow-sticky);
  z-index: 50;
}

.cta-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.cta-summary-label { font-size: 13px; font-weight: 500; color: var(--text-secondary); }
.cta-summary-price { font-size: 13px; color: var(--text-muted); }
.cta-summary-price strong { color: var(--green); font-weight: 700; }

.cta-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 16px 24px;
  background: linear-gradient(135deg, var(--eon-red), #FF2D3B);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.cta-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.15), transparent);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.cta-button:hover::before { opacity: 1; }
.cta-button:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(227,6,19,0.35); }
.cta-button:active { transform: translateY(0) scale(0.98); }

.cta-button.loading { pointer-events: none; }
.cta-button.loading .cta-button-text,
.cta-button.loading .cta-button-arrow { opacity: 0; }
.cta-button.loading svg { opacity: 0; }

.cta-button.loading::after {
  content: '';
  width: 22px;
  height: 22px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 700ms linear infinite;
  position: absolute;
}

@keyframes spin { to { transform: rotate(360deg); } }

.cta-button-arrow { transition: transform var(--transition-fast); }
.cta-button:hover .cta-button-arrow { transform: translateX(3px); }
.cta-legal-micro { font-size: 11px; color: var(--text-light); text-align: center; margin-top: 8px; line-height: 1.4; }

/* ============================================
   EKRAN 4: EMAIL LOOP
   ============================================ */
.email-content {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.email-screen {
  text-align: center;
  max-width: 320px;
  width: 100%;
}

.email-animation {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.email-envelope {
  position: relative;
  z-index: 2;
  animation: envelopeBounce 2s ease-in-out infinite;
}

@keyframes envelopeBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.email-pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid var(--eon-red-light);
  animation: emailPulseAnim 2s ease-out infinite;
}

.email-pulse--delay { animation-delay: 1s; }

@keyframes emailPulseAnim {
  0% { transform: scale(0.8); opacity: 1; }
  100% { transform: scale(1.8); opacity: 0; }
}

.email-badge-success {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  background: var(--green-light);
  border: 1px solid #BBF7D0;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  color: var(--green);
  margin-bottom: 16px;
}

.email-title {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: -0.3px;
}

.email-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 8px;
}

.email-address-card {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--eon-red-50);
  border: 1px solid var(--eon-red-light);
  border-radius: var(--radius-md);
  font-size: 14px;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.email-instructions {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 20px;
}

.email-timer-card {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: var(--bg-app);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  margin-bottom: 24px;
}

.email-timer-text {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.email-timer-label {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}

.email-timer-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}

.email-open-mail {
  margin-bottom: 20px;
}

.email-help {
  font-size: 12px;
  color: var(--text-muted);
}

.email-help p { margin-bottom: 6px; }

.email-resend {
  background: none;
  border: none;
  color: var(--eon-red);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  transition: background var(--transition-fast);
}

.email-resend:hover { background: var(--eon-red-50); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 440px) {
  body { padding: 0; background: var(--bg-app); overflow: hidden; }
  .app-shell {
    border-radius: 0;
    box-shadow: none;
    height: 100vh;
    height: 100dvh;
    max-width: 100%;
  }
}

/* Scale down phone frame if viewport is too short */
@media (max-height: 700px) {
  body { padding: 8px; }
  .app-shell {
    border-radius: 28px;
    box-shadow: 0 0 0 6px #1E1E2E, 0 0 0 8px #3a3a4a, var(--shadow-overlay);
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.consent-item:focus-within { outline: 2px solid var(--eon-red); outline-offset: 2px; }
.cta-button:focus-visible, .nav-back:focus-visible { outline: 2px solid var(--eon-red); outline-offset: 2px; }
.doc-tile:focus-visible { outline: 2px solid var(--eon-red); outline-offset: 2px; }

/* ============================================
   VARIANT CAROUSEL (swipe left/right)
   ============================================ */

.variant-carousel {
  position: relative;
  margin: 0 -12px;
}

.variant-track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 4px 12px 16px;
  scrollbar-width: none;
}
.variant-track::-webkit-scrollbar { display: none; }

.variant-card {
  flex: 0 0 85%;
  scroll-snap-align: center;
  background: #fff;
  border: 2px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px 16px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.variant-card.variant-card--active,
.variant-card:hover {
  border-color: var(--eon-red);
  box-shadow: 0 4px 20px rgba(227, 6, 19, 0.1);
}

.variant-card-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
}
.variant-card-badge--red { color: #fff; background: var(--eon-red); }
.variant-card-badge--blue { color: #2563EB; background: #EFF6FF; }
.variant-card-badge--purple { color: #7C3AED; background: #F5F3FF; }

.variant-card-name {
  font-size: 18px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.variant-card-price {
  font-size: 26px;
  font-weight: 900;
  color: var(--eon-red);
  margin-bottom: 2px;
}
.variant-card-price-unit {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.variant-card-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.variant-card-features li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
}
.variant-card-features li svg {
  flex-shrink: 0;
  margin-top: 1px;
}

.variant-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding-bottom: 4px;
}
.variant-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border-light);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
.variant-dot.active {
  background: var(--eon-red);
  transform: scale(1.25);
}

.variant-hint {
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}
.variant-hint svg {
  vertical-align: middle;
  margin: 0 2px;
}

/* Dynamic price indicator */
.dynamic-price-display {
  text-align: center;
  padding: 20px 16px;
  background: linear-gradient(135deg, #F0FDF4, #ECFDF5);
  border-radius: var(--radius-md);
  border: 1px solid #BBF7D0;
  margin-bottom: 16px;
}
.dynamic-price-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--green);
  margin-bottom: 6px;
}
.dynamic-price-value {
  font-size: 32px;
  font-weight: 900;
  color: var(--text-primary);
}
.dynamic-price-unit {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}
.dynamic-price-note {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Freeze compare – obecna oferta vs nowa */
.freeze-compare {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}
.freeze-compare-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
}
.freeze-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}
.freeze-status {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
}
.freeze-status--warning {
  color: #B45309;
  background: #FEF3C7;
}
.freeze-status--ok {
  color: #059669;
  background: #D1FAE5;
}

/* Savings highlight box */
.savings-highlight {
  text-align: center;
  padding: 20px 16px;
  background: linear-gradient(135deg, #EEF2FF, #E0E7FF);
  border-radius: var(--radius-md);
  border: 1px solid #C7D2FE;
  margin-bottom: 16px;
}
.savings-highlight-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #4338CA;
  margin-bottom: 6px;
}
.savings-highlight-value {
  font-size: 32px;
  font-weight: 900;
  color: var(--text-primary);
}
.savings-highlight-unit {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}
.savings-highlight-note {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Cost comparison bars */
.cost-compare-bar {
  margin-bottom: 16px;
}
.cost-compare-row {
  margin-bottom: 10px;
}
.cost-compare-label {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.cost-compare-label strong {
  color: var(--text-primary);
}
.cost-compare-track {
  height: 24px;
  border-radius: 6px;
  background: var(--bg-secondary);
  overflow: hidden;
}
.cost-compare-fill {
  height: 100%;
  border-radius: 6px;
  display: flex;
  align-items: center;
  padding-left: 8px;
  font-size: 11px;
  font-weight: 700;
  color: white;
  transition: width 1.2s ease-out;
}
.cost-compare-fill--old {
  background: #94A3B8;
}
.cost-compare-fill--new {
  background: var(--green);
}

/* Usage profile mini chart */
.usage-profile {
  margin-bottom: 16px;
}
.usage-profile-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 10px;
}
.usage-profile-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 60px;
}
.usage-profile-bar {
  flex: 1;
  border-radius: 3px 3px 0 0;
  min-height: 4px;
  transition: height 0.8s ease-out;
}
.usage-profile-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 4px;
}
.usage-profile-labels span {
  font-size: 9px;
  color: var(--text-muted);
}

/* ---- SZABLONY KORZYŚCI (UNIVERSAL BENEFIT TEMPLATES) ---- */
.szablon-screen {
  transform: none;
  opacity: 1;
  overflow-y: auto;
  padding-bottom: 40px;
}
.szablon-intro {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  border: 1px solid var(--border-light);
}
.szablon-intro h1 {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 12px;
}
.szablon-intro p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
.szablon-intro p:last-child { margin-bottom: 0; }
.szablon-section {
  margin-bottom: 28px;
}
.szablon-section h2 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.szablon-section h2::before {
  content: '';
  width: 4px;
  height: 20px;
  background: var(--eon-red);
  border-radius: 2px;
}
.template-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.template-card {
  background: var(--bg-white);
  border-radius: var(--radius-md);
  padding: 16px;
  border: 1px solid var(--border-light);
}
.template-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.template-id {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.template-icon-badge {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--green-light);
  color: var(--green);
}
.template-icon-badge.benefit-icon--blue { background: #EFF6FF; color: var(--blue); }
.template-icon-badge.benefit-icon--purple { background: #F5F3FF; color: #7C3AED; }
.template-icon-badge.benefit-icon--emerald { background: #ECFDF5; color: #059669; }
.template-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}
.template-card p {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 4px;
  line-height: 1.4;
}
.template-card code {
  font-size: 11px;
  background: var(--bg-app);
  padding: 2px 6px;
  border-radius: 4px;
  word-break: break-all;
}
.template-placeholders,
.template-products {
  margin-top: 8px;
  font-size: 11px;
  color: var(--text-muted);
}
.szablon-preview {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: 20px;
  border: 1px solid var(--border-light);
}
.szablon-select-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.szablon-select-row label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}
.szablon-select-row select {
  flex: 1;
  max-width: 240px;
  padding: 10px 14px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--bg-white);
}
.szablon-preview .benefits-list {
  margin-top: 0;
}
.szablon-empty {
  font-size: 14px;
  color: var(--text-muted);
  padding: 20px;
  text-align: center;
}
.szablon-arch-diagram {
  background: var(--bg-app);
  border-radius: var(--radius-md);
  padding: 16px;
  margin: 16px 0;
  font-family: monospace;
  font-size: 11px;
  line-height: 1.6;
  color: var(--text-secondary);
  overflow-x: auto;
}

/* ---- SZABLONY KORZYŚCI – DOC LAYOUT (bez telefonu) ---- */
body.szablon-doc {
  display: block;
  height: auto;
  min-height: 100vh;
  align-items: stretch;
  justify-content: flex-start;
  padding: 0;
  overflow: auto;
}
.szablon-doc {
  background: var(--bg-white);
}
.szablon-doc-body {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 24px 48px;
}
.szablon-doc h1 {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
}
.szablon-doc h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 32px;
  margin-bottom: 12px;
}
.szablon-doc h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: 20px;
  margin-bottom: 8px;
}
.szablon-doc p, .szablon-doc li {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
.szablon-doc ul {
  margin-left: 20px;
  margin-bottom: 16px;
}
.szablon-doc table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin: 16px 0;
}
.szablon-doc th, .szablon-doc td {
  border: 1px solid var(--border-light);
  padding: 10px 12px;
  text-align: left;
}
.szablon-doc th {
  background: var(--bg-app);
  font-weight: 600;
  color: var(--text-primary);
}
.szablon-doc td {
  color: var(--text-secondary);
}
.szablon-doc code {
  font-size: 12px;
  background: var(--bg-app);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: monospace;
}
.szablon-doc pre {
  background: var(--bg-app);
  border-radius: var(--radius-md);
  padding: 16px;
  font-size: 12px;
  overflow-x: auto;
  margin: 16px 0;
  border: 1px solid var(--border-light);
}
.szablon-doc .flow-block {
  background: #f8f9fa;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 16px;
  margin: 16px 0;
  font-size: 13px;
  color: var(--text-secondary);
}

/* ---- OVERLAY WARSTWY SZABLONÓW ---- */
.overlay-templates {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9998;
  display: none;
}
.overlay-templates.overlay-templates--on {
  display: block;
}
.overlay-annotation {
  pointer-events: none;
}
.overlay-line {
  overflow: visible;
}
.overlay-label {
  max-width: 200px;
  padding: 6px 10px;
  background: #fff;
  border: 1px solid var(--eon-red);
  border-radius: 6px;
  font-size: 10px;
  line-height: 1.35;
  color: var(--text-primary);
  box-shadow: var(--shadow-card);
  pointer-events: none;
}
.overlay-label--inline {
  padding: 4px 8px;
  font-size: 9px;
}
.overlay-label--inline .overlay-tpl {
  display: block;
  word-break: break-all;
}
.overlay-label--inline .overlay-data {
  display: block;
  word-break: break-all;
  white-space: normal;
}
.overlay-label .overlay-lbl {
  font-weight: 600;
  color: var(--eon-red);
  display: block;
  margin-bottom: 2px;
}
.overlay-label .overlay-tpl {
  font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
  font-size: 9px;
  color: var(--eon-red);
  font-weight: 600;
}
.overlay-label .overlay-data {
  font-size: 9px;
  color: var(--text-muted);
  font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}
.overlay-toggle-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: 16px;
  min-width: 0;
}
.overlay-toggle-zone {
  flex-shrink: 0;
}
.overlay-toggle-btn {
  display: block;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  cursor: pointer;
  transition: all 150ms ease;
  white-space: nowrap;
}
.overlay-toggle-btn:hover {
  color: var(--eon-red);
  border-color: var(--eon-red);
}
.overlay-toggle-btn.overlay-toggle--on {
  color: var(--eon-red);
  background: var(--eon-red-50);
  border-color: var(--eon-red);
}

/* ---- AUTH OVERLAY (PASSWORD SCREEN) ---- */
.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1E1E2E 0%, #0F0F14 100%);
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.auth-overlay--hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.auth-box {
  background: #fff;
  padding: 32px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-overlay);
  width: 100%;
  max-width: 320px;
  margin: 16px;
}
.auth-box h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 20px;
  text-align: center;
}
.auth-box input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-family: inherit;
  margin-bottom: 12px;
}
.auth-box input:focus {
  outline: none;
  border-color: var(--eon-red);
  box-shadow: 0 0 0 3px var(--eon-red-50);
}
.auth-box button {
  width: 100%;
  padding: 12px 16px;
  background: var(--eon-red);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background var(--transition-fast);
}
.auth-box button:hover {
  background: var(--eon-red-dark);
}
.auth-error {
  margin-top: 12px;
  font-size: 13px;
  color: var(--eon-red);
  text-align: center;
  min-height: 18px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
