/* GIA vs ISA vs Pension: aligned with DB CETV / Lifetime Mortgage shell (RetirementCalculators.uk) */

:root {
  --gipp-ink: #0f172a;
  --gipp-muted: #475569;
  --gipp-navy: #083141;
}

#gipp-root.gipp-app {
  width: auto;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 0 14px;
  box-sizing: border-box;
  overflow-x: hidden;
}

.gipp-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 18px 30px;
  border: 2px solid rgba(8, 49, 65, 0.18);
  border-radius: 22px;
  box-shadow: 0 20px 60px rgba(2, 6, 23, 0.1);
  background: #fff;
  color: var(--gipp-ink);
}

.gipp-hero {
  border: 1px solid rgba(8, 49, 65, 0.2);
  border-radius: 18px;
  padding: 22px;
  background: linear-gradient(135deg, #fff 0%, #f0f9ff 52%, #e0f2fe 100%);
}

.gipp-title {
  margin: 0 0 8px;
  font-size: clamp(1.45rem, 3.6vw, 2.15rem);
  font-weight: 950;
  color: var(--gipp-navy);
  letter-spacing: -0.02em;
}

.gipp-sub {
  margin: 0;
  color: var(--gipp-muted);
  font-weight: 650;
  line-height: 1.55;
}

.gipp-hero-context {
  margin: 12px 0 0;
  color: #0c4a6e;
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1.55;
}

.gipp-plain-english {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(8, 49, 65, 0.14);
  background: linear-gradient(165deg, #f8fafc 0%, #fff 100%);
}

.gipp-plain-english__title {
  margin: 0 0 10px;
  font-size: 1.2rem;
  font-weight: 950;
  color: var(--gipp-navy);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.gipp-plain-english__list {
  margin: 0;
  padding-left: 1.15rem;
  color: #334155;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.55;
}

.gipp-plain-english__list li {
  margin: 0 0 8px;
}

.gipp-plain-english__list li:last-child {
  margin-bottom: 0;
}

.gipp-card {
  margin-top: 16px;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 18px;
  background: #fff;
}

.gipp-card--inputs {
  border: 2px solid rgba(8, 49, 65, 0.2);
  border-left: 5px solid var(--gipp-navy);
  background: linear-gradient(165deg, #f1f5f9 0%, #fff 42%);
  box-shadow: 0 6px 22px rgba(8, 49, 65, 0.07);
}

.gipp-card--inputs .gipp-h3::before {
  content: "✎";
  display: inline-block;
  margin-right: 8px;
  font-size: 1em;
  opacity: 0.9;
}

.gipp-h3 {
  margin: 0 0 10px;
  font-size: 1.3rem;
  font-weight: 950;
  color: var(--gipp-navy);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.gipp-card-lead {
  margin: -4px 0 14px;
  color: var(--gipp-muted);
  font-weight: 650;
  font-size: 0.92rem;
  line-height: 1.55;
}

.gipp-input-section {
  margin-top: 18px;
  padding: 16px 16px 18px;
  border-radius: 14px;
  border: 1px solid rgba(8, 49, 65, 0.12);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.gipp-input-section:first-of-type {
  margin-top: 6px;
}

.gipp-input-section--timeline {
  border-left: 4px solid #0e7490;
  background: linear-gradient(135deg, rgba(236, 254, 255, 0.5) 0%, rgba(255, 255, 255, 0.9) 48%);
}

.gipp-input-section--contributions {
  margin-top: 22px;
  border-left: 4px solid #4f46e5;
  background: linear-gradient(135deg, rgba(238, 242, 255, 0.55) 0%, rgba(255, 255, 255, 0.92) 50%);
}

.gipp-input-section .gipp-input-group-title {
  margin: 0 0 6px;
  font-size: 1.12rem;
  font-weight: 950;
  color: var(--gipp-navy);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.gipp-input-section-lead {
  margin: 0 0 14px;
  font-size: 0.84rem;
  font-weight: 650;
  color: #64748b;
  line-height: 1.5;
}

.gipp-input-section .gipp-grid {
  margin-top: 0;
}

.gipp-input-section .gipp-presets {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(8, 49, 65, 0.1);
}

.gipp-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.gipp-field {
  display: grid;
  gap: 6px;
}

.gipp-label {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--gipp-navy);
}

.gipp-hint {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 650;
  color: #64748b;
  line-height: 1.45;
}

.gipp-input {
  width: 100%;
  padding: 12px;
  border: 2px solid rgba(8, 49, 65, 0.2);
  border-radius: 12px;
  box-sizing: border-box;
  font-size: max(16px, 1rem);
}

.gipp-input:focus {
  outline: none;
  border-color: rgba(21, 94, 117, 0.55);
  box-shadow: 0 0 0 5px rgba(21, 94, 117, 0.12);
}

.gipp-presets {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(8, 49, 65, 0.1);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.gipp-presets-label {
  font-size: 0.82rem;
  font-weight: 850;
  color: #64748b;
  margin-right: 4px;
}

.gipp-preset-btn {
  padding: 10px 14px;
  font-size: 0.84rem;
  font-weight: 800;
  background: #fff;
  border: 2px solid rgba(8, 49, 65, 0.18);
  color: var(--gipp-navy);
  border-radius: 10px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.gipp-preset-btn:hover {
  background: #f8fafc;
  border-color: rgba(21, 94, 117, 0.45);
}

/* Results: DB CETV rhythm */
.gipp-results {
  margin-top: 24px;
  padding: 20px 16px 8px;
  border-radius: 18px;
  background: #f8fafc;
  border: 1px solid rgba(8, 49, 65, 0.12);
}

.gipp-results-header {
  width: 100%;
  margin: 0 0 16px;
  padding: 0 0 14px;
  border-bottom: 3px solid rgba(8, 49, 65, 0.22);
}

.gipp-results-heading.gipp-h3 {
  margin: 0 0 8px;
}

.gipp-results-lead {
  margin: 0;
  color: var(--gipp-muted);
  font-size: 0.95rem;
  font-weight: 650;
  line-height: 1.55;
}

.gipp-illustration-callout {
  margin: 0 0 18px;
  padding: 16px 18px;
  border-radius: 14px;
  border: 2px solid rgba(217, 119, 6, 0.35);
  background: linear-gradient(145deg, #fffbeb 0%, #fff 55%);
  box-shadow: 0 4px 14px rgba(180, 83, 9, 0.08);
}

.gipp-illustration-callout__kicker {
  margin: 0 0 10px;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #b45309;
}

.gipp-illustration-callout__text {
  margin: 0 0 12px;
  font-size: clamp(0.9rem, 2.2vw, 1rem);
  font-weight: 650;
  color: #451a03;
  line-height: 1.6;
}

.gipp-illustration-callout__text:last-child {
  margin-bottom: 0;
}

.gipp-illustration-callout__text a {
  color: #0e7490;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.gipp-illustration-callout__text--warn {
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(217, 119, 6, 0.25);
  font-weight: 650;
  color: #78350f;
}

.gipp-gap-panel {
  margin: 16px 0;
  padding: 18px 20px;
  border-radius: 16px;
  border: 2px solid rgba(21, 94, 117, 0.28);
  background: linear-gradient(135deg, #ecfeff 0%, #f0f9ff 45%, #fff 100%);
  text-align: center;
  box-shadow: 0 6px 20px rgba(8, 49, 65, 0.08);
}

.gipp-gap-panel__eyebrow {
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #0e7490;
  margin-bottom: 8px;
}

.gipp-gap-panel__figure {
  font-size: clamp(1.35rem, 4vw, 1.85rem);
  font-weight: 950;
  color: var(--gipp-navy);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  margin-bottom: 10px;
}

.gipp-gap-panel__text {
  margin: 0;
  font-size: clamp(0.88rem, 2.1vw, 0.98rem);
  font-weight: 650;
  color: #334155;
  line-height: 1.55;
  max-width: 52rem;
  margin-left: auto;
  margin-right: auto;
}

.gipp-visual-board {
  border-radius: 18px;
  overflow: hidden;
  border: 2px solid rgba(8, 49, 65, 0.14);
  box-shadow: 0 12px 40px rgba(2, 6, 23, 0.08);
  background: #fff;
}

.gipp-visual-board-intro {
  padding: 16px 18px;
  background: linear-gradient(135deg, #f0f9ff 0%, #fff 55%);
  border-bottom: 1px solid rgba(8, 49, 65, 0.1);
}

.gipp-visual-board-title {
  margin: 0 0 8px;
  font-size: clamp(1.18rem, 2.85vw, 1.35rem);
  font-weight: 950;
  color: var(--gipp-navy);
  letter-spacing: -0.02em;
  line-height: 1.28;
}

.gipp-visual-board-sub {
  margin: 0;
  font-size: clamp(0.86rem, 2vw, 0.95rem);
  font-weight: 650;
  color: #475569;
  line-height: 1.55;
}

/* Pot size bar chart (scaled to largest pot in run) */
.gipp-pot-chart {
  border-top: 1px solid rgba(8, 49, 65, 0.1);
  padding: 16px 18px 18px;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 55%);
}

.gipp-pot-chart__intro {
  margin-bottom: 14px;
}

.gipp-pot-chart__title {
  margin: 0 0 6px;
  font-size: clamp(1.05rem, 2.55vw, 1.22rem);
  font-weight: 950;
  color: var(--gipp-navy);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.gipp-pot-chart__lead {
  margin: 0;
  font-size: clamp(0.82rem, 2vw, 0.92rem);
  font-weight: 650;
  color: #64748b;
  line-height: 1.45;
}

.gipp-pot-bar-row {
  display: grid;
  grid-template-columns: minmax(4.25rem, 5.25rem) minmax(0, 1fr) minmax(4.5rem, 6.5rem);
  gap: 8px 12px;
  align-items: center;
  margin-bottom: 12px;
}

.gipp-pot-bar-row:last-child {
  margin-bottom: 0;
}

.gipp-pot-bar-row__label {
  font-size: 0.78rem;
  font-weight: 900;
  color: var(--gipp-navy);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.gipp-pot-bar-row__track {
  height: 16px;
  border-radius: 9px;
  background: rgba(8, 49, 65, 0.09);
  overflow: hidden;
  min-width: 0;
}

.gipp-pot-bar-row__fill {
  height: 100%;
  min-width: 2px;
  border-radius: 9px;
  transition: width 0.38s ease;
}

.gipp-pot-bar-row--gia .gipp-pot-bar-row__fill {
  background: linear-gradient(90deg, #059669, #34d399);
}

.gipp-pot-bar-row--isa .gipp-pot-bar-row__fill {
  background: linear-gradient(90deg, #1d4ed8, #60a5fa);
}

.gipp-pot-bar-row--pen .gipp-pot-bar-row__fill {
  background: linear-gradient(90deg, #9a3412, #fb923c);
}

.gipp-pot-bar-row__value {
  font-size: clamp(0.92rem, 2.4vw, 1.05rem);
  font-weight: 950;
  color: var(--gipp-navy);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

@media (max-width: 400px) {
  .gipp-pot-bar-row {
    grid-template-columns: 3.5rem minmax(0, 1fr) auto;
    gap: 6px 8px;
  }

  .gipp-pot-bar-row__value {
    font-size: 0.86rem;
  }
}

.gipp-visual-columns--triple {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0;
  align-items: stretch;
}

.gipp-visual-path {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.gipp-visual-path--gia {
  background: linear-gradient(180deg, #ecfdf5 0%, #fff 28%);
  border-right: 1px solid rgba(8, 49, 65, 0.08);
}

.gipp-visual-path--isa {
  background: linear-gradient(180deg, #eff6ff 0%, #fff 28%);
  border-right: 1px solid rgba(8, 49, 65, 0.08);
}

.gipp-visual-path--pen {
  background: linear-gradient(180deg, #fff7ed 0%, #fff 28%);
}

.gipp-visual-path--winner {
  box-shadow: inset 0 0 0 3px rgba(220, 38, 38, 0.55);
  position: relative;
  z-index: 1;
}

.gipp-visual-path-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  font-weight: 950;
  font-size: 0.95rem;
  color: #fff;
}

.gipp-visual-path--gia .gipp-visual-path-head {
  background: linear-gradient(135deg, #059669, #047857);
}

.gipp-visual-path--isa .gipp-visual-path-head {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
}

.gipp-visual-path--pen .gipp-visual-path-head {
  background: linear-gradient(135deg, #c2410c, #9a3412);
}

.gipp-visual-path-icon {
  font-size: 1.35rem;
  line-height: 1;
}

.gipp-visual-path-name {
  line-height: 1.25;
}

.gipp-visual-path-tag {
  padding: 8px 16px;
  font-size: 0.72rem;
  font-weight: 750;
  color: #64748b;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(8, 49, 65, 0.06);
}

.gipp-visual-path--gia .gipp-visual-path-tag {
  background: rgba(236, 253, 245, 0.95);
}

.gipp-visual-path--isa .gipp-visual-path-tag {
  background: rgba(239, 246, 255, 0.95);
}

.gipp-visual-path--pen .gipp-visual-path-tag {
  background: rgba(255, 247, 237, 0.95);
}

.gipp-visual-metrics {
  padding: 14px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
}

.gipp-visual-metric {
  padding: 10px 12px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid rgba(8, 49, 65, 0.1);
}

.gipp-visual-path--gia .gipp-visual-metric {
  border-left: 3px solid #10b981;
}

.gipp-visual-path--isa .gipp-visual-metric {
  border-left: 3px solid #3b82f6;
}

.gipp-visual-path--pen .gipp-visual-metric {
  border-left: 3px solid #ea580c;
}

.gipp-visual-metric-label {
  font-size: 0.72rem;
  font-weight: 800;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.gipp-visual-metric-value {
  margin-top: 6px;
  font-size: clamp(1.05rem, 2.8vw, 1.35rem);
  font-weight: 950;
  color: var(--gipp-navy);
  font-variant-numeric: tabular-nums;
}

.gipp-visual-metric-note {
  margin-top: 6px;
  font-size: 0.72rem;
  font-weight: 650;
  color: #64748b;
  line-height: 1.35;
}

.gipp-visual-metric--secondary {
  padding-top: 8px;
  margin-top: 4px;
  border-top: 1px dashed rgba(8, 49, 65, 0.12);
}

.gipp-visual-metric--gain .gipp-visual-metric-value {
  color: #0f766e;
}

.gipp-visual-metric-value--sm {
  font-size: clamp(0.95rem, 2.5vw, 1.12rem);
  font-weight: 900;
}

.gipp-verdict-strip {
  margin-top: 14px;
  padding: 16px 18px;
  border-radius: 14px;
  border: 2px solid rgba(88, 28, 135, 0.22);
  background: linear-gradient(145deg, #faf5ff 0%, #fff 45%);
  font-size: clamp(0.92rem, 2.2vw, 1.02rem);
  font-weight: 700;
  color: #4c1d95;
  line-height: 1.55;
  text-align: center;
}

.gipp-bridge-panel {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.55;
}

.gipp-bridge-panel--warn {
  background: linear-gradient(145deg, #fffbeb 0%, #fff 50%);
  border: 2px solid rgba(217, 119, 6, 0.35);
  color: #92400e;
}

.gipp-bridge-panel--ok {
  background: linear-gradient(145deg, #ecfdf5 0%, #fff 50%);
  border: 2px solid rgba(22, 101, 52, 0.28);
  color: #14532d;
}

.gipp-bridge-panel strong {
  font-weight: 900;
}

.gipp-card--results {
  margin-top: 16px;
  border: 2px solid rgba(21, 94, 117, 0.2);
  background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
  box-shadow: 0 8px 24px rgba(21, 94, 117, 0.08);
}

.gipp-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  touch-action: pan-x;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  margin-top: 12px;
}

.gipp-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.gipp-table th,
.gipp-table td {
  border: 1px solid #e2e8f0;
  padding: 10px;
}

.gipp-table th {
  background: #f1f5f9;
  color: var(--gipp-navy);
  font-weight: 900;
}

.gipp-th-neutral {
  background: #f9fafb !important;
}

.gipp-th-gia {
  background: #d1fae5 !important;
  color: #065f46;
}

.gipp-th-isa {
  background: #dbeafe !important;
  color: #1e40af;
}

.gipp-th-pen {
  background: #ffedd5 !important;
  color: #9a3412;
}

.gipp-td-neutral {
  font-weight: 650;
  color: #334155;
}

.gipp-td-gia {
  background: #f0fdf4;
  font-weight: 650;
  color: #065f46;
}

.gipp-td-isa {
  background: #eff6ff;
  font-weight: 650;
  color: #1e40af;
}

.gipp-td-pen {
  background: #fff7ed;
  font-weight: 650;
  color: #9a3412;
}

.gipp-table tbody tr:nth-child(even) .gipp-td-gia {
  background: #ecfdf5;
}

.gipp-table tbody tr:nth-child(even) .gipp-td-isa {
  background: #e0f2fe;
}

.gipp-table tbody tr:nth-child(even) .gipp-td-pen {
  background: #ffedd5;
}

.gipp-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.gipp-mechanics-details {
  margin-top: 14px;
  border-radius: 14px;
  border: 1px dashed rgba(8, 49, 65, 0.22);
  background: #fafafa;
}

.gipp-mechanics-summary {
  cursor: pointer;
  padding: 16px 18px;
  font-size: clamp(1.1rem, 2.55vw, 1.22rem);
  font-weight: 950;
  color: var(--gipp-navy);
  list-style: none;
  line-height: 1.4;
  letter-spacing: -0.02em;
}

.gipp-mechanics-summary::-webkit-details-marker {
  display: none;
}

.gipp-mechanics-body {
  padding: 0 18px 20px;
}

.gipp-mechanics-body .gipp-table-wrap--rules {
  margin-top: 0;
}

.gipp-methodology-details {
  margin-top: 14px;
  border-radius: 14px;
  border: 1px solid rgba(21, 94, 117, 0.22);
  background: linear-gradient(165deg, #f0fdfa 0%, #fff 55%);
  box-shadow: 0 4px 18px rgba(2, 6, 23, 0.06);
}

.gipp-methodology-summary {
  cursor: pointer;
  padding: 16px 18px;
  font-size: clamp(1.02rem, 2.45vw, 1.15rem);
  font-weight: 950;
  color: var(--gipp-navy);
  list-style: none;
  line-height: 1.35;
  letter-spacing: -0.02em;
}

.gipp-methodology-summary::-webkit-details-marker {
  display: none;
}

.gipp-methodology-body {
  padding: 0 18px 18px;
}

.gipp-methodology-list {
  margin: 0;
  padding-left: 1.2rem;
  color: #334155;
  font-size: clamp(0.88rem, 2vw, 0.95rem);
  font-weight: 650;
  line-height: 1.55;
}

.gipp-methodology-list li {
  margin-bottom: 10px;
}

.gipp-methodology-list li:last-child {
  margin-bottom: 0;
}

.gipp-rules-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: clamp(0.94rem, 2.1vw, 1.05rem);
}

.gipp-rules-table th,
.gipp-rules-table td {
  padding: 12px 14px;
  border-bottom: 1px solid #e2e8f0;
  vertical-align: top;
  line-height: 1.55;
}

.gipp-rules-table th {
  background: #f8fafc;
  color: var(--gipp-navy);
  text-align: left;
}

.gipp-rules-table thead th {
  font-size: clamp(0.98rem, 2.2vw, 1.08rem);
  font-weight: 900;
  padding-bottom: 14px;
}

.gipp-rules-table tbody th {
  font-weight: 800;
  font-size: clamp(0.95rem, 2.1vw, 1.02rem);
}

.gipp-rules-table td {
  font-weight: 650;
  color: #334155;
}

.gipp-rh-gia {
  background: rgba(5, 150, 105, 0.08);
}

.gipp-rh-isa {
  background: rgba(37, 99, 235, 0.08);
}

.gipp-rh-pen {
  background: rgba(194, 65, 12, 0.08);
}

.gipp-results-footnote {
  margin: 16px 0 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(254, 243, 199, 0.45);
  border: 1px solid rgba(217, 119, 6, 0.22);
  color: #92400e;
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.45;
}

.gipp-export {
  margin-top: 20px;
  padding: 20px;
  border-radius: 16px;
  border: 2px solid rgba(21, 94, 117, 0.3);
  background: linear-gradient(135deg, #fff 0%, #ecfeff 100%);
  text-align: center;
}

.gipp-export-title {
  margin: 0 0 8px;
  color: var(--gipp-navy);
  font-size: clamp(1.22rem, 3.25vw, 1.58rem);
  font-weight: 950;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.gipp-export-sub {
  margin: 0 0 14px;
  color: var(--gipp-muted);
  font-weight: 650;
  font-size: 0.92rem;
  line-height: 1.5;
}

.gipp-export-btn {
  width: 100%;
  max-width: 420px;
  padding: 17px 18px;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  color: #fff;
  font-size: 1.05rem;
  font-weight: 950;
  letter-spacing: 0.02em;
  background: linear-gradient(180deg, #0e7490 0%, #155e75 55%, #164e63 100%);
  box-shadow: 0 6px 0 #0c4a5f, 0 16px 34px rgba(21, 94, 117, 0.35);
}

.gipp-export-btn:hover {
  filter: brightness(1.03);
}

.gipp-export-btn:active {
  transform: translateY(2px);
  box-shadow: 0 3px 0 #0c4a5f, 0 8px 20px rgba(21, 94, 117, 0.28);
}

/* Modal: DB CETV */
.gipp-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999999;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom))
    max(16px, env(safe-area-inset-left));
  box-sizing: border-box;
  overflow-y: auto;
}

.gipp-modal {
  width: 100%;
  max-width: 560px;
  max-height: min(92vh, calc(100dvh - 32px));
  background: #fff;
  border: 3px solid var(--gipp-navy);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.gipp-modal-header {
  padding: 22px;
  background: linear-gradient(135deg, var(--gipp-navy), #0a4a5f);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.gipp-modal-header-text {
  flex: 1;
  min-width: 0;
}

.gipp-modal-header h3 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.22rem, 4.2vw, 1.55rem);
  font-weight: 950;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.gipp-modal-header-sub {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.875rem;
  font-weight: 550;
  line-height: 1.45;
}

.gipp-modal-close {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.gipp-modal-body {
  padding: 22px;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}

.gipp-modal-lead {
  margin: 0 0 14px;
  color: #1e293b;
  font-weight: 650;
  font-size: clamp(0.95rem, 2.2vw, 1.05rem);
  line-height: 1.55;
}

.gipp-modal-label {
  display: block;
  margin: 10px 0 7px;
  font-weight: 900;
  color: #0f172a;
  font-size: 0.95rem;
}

.gipp-modal-input {
  width: 100%;
  padding: 12px;
  border: 2px solid rgba(8, 49, 65, 0.28);
  border-radius: 12px;
  box-sizing: border-box;
  font-size: max(16px, 1rem);
}

.gipp-modal-error {
  margin-top: 10px;
  color: #b91c1c;
  font-weight: 700;
  font-size: 0.92rem;
}

.gipp-modal-footer {
  padding: 18px 22px;
  background: #ecfeff;
  border-top: 2px solid rgba(21, 94, 117, 0.22);
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.gipp-modal-submit {
  flex: 1 1 auto;
  min-width: min(100%, 240px);
  min-height: 54px;
  border-radius: 14px;
  border: 2px solid #0c4a5f;
  background: linear-gradient(180deg, #0e7490 0%, #155e75 55%, #164e63 100%);
  color: #fff;
  font-weight: 950;
  cursor: pointer;
}

.gipp-modal-secondary {
  border: 2px solid rgba(8, 49, 65, 0.25);
  background: #fff;
  color: var(--gipp-navy);
  border-radius: 14px;
  padding: 14px 18px;
  font-weight: 850;
  cursor: pointer;
  min-height: 54px;
}

.gipp-modal-success {
  margin: 0;
  padding: 8px 0;
  text-align: center;
  color: #059669;
  font-weight: 800;
  font-size: 1.05rem;
  line-height: 1.5;
}

@media (max-width: 900px) {
  .gipp-visual-columns--triple {
    grid-template-columns: 1fr;
  }

  .gipp-visual-path--gia,
  .gipp-visual-path--isa {
    border-right: none;
    border-bottom: 1px solid rgba(8, 49, 65, 0.08);
  }

  .gipp-modal-overlay {
    align-items: flex-start;
    padding-top: max(12px, env(safe-area-inset-top));
  }
}

@media (prefers-reduced-motion: reduce) {
  .gipp-pot-bar-row__fill {
    transition: none;
  }
}

@media (max-width: 520px) {
  #gipp-root.gipp-app {
    padding: 0 10px;
  }

  .gipp-shell {
    padding: 16px 12px 22px;
    border-radius: 16px;
  }

  .gipp-hero {
    padding: 16px;
    border-radius: 14px;
  }

  .gipp-card {
    padding: 14px;
  }

  .gipp-results {
    padding: 16px 12px 2px;
    border-radius: 14px;
  }

  .gipp-pot-chart {
    padding: 14px 12px 16px;
  }

  .gipp-methodology-summary {
    padding: 14px 14px;
  }

  .gipp-methodology-body {
    padding: 0 14px 14px;
  }

  .gipp-export {
    padding: 16px 14px;
  }

  .gipp-export-btn {
    max-width: none;
  }

  .gipp-modal-header,
  .gipp-modal-body,
  .gipp-modal-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .gipp-modal-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .gipp-modal-submit,
  .gipp-modal-secondary {
    width: 100%;
    min-width: 0;
  }
}
