:root {
  --pi-bg: #f5f7f9;
  --pi-surface: #ffffff;
  --pi-soft: #edf2f5;
  --pi-text: #17191d;
  --pi-muted: #66707c;
  --pi-border: #dce2e7;
  --pi-dark: #111720;
  --pi-blue: #506adf;
  --pi-radius: 20px;
  --pi-shadow: 0 18px 50px rgba(20, 27, 36, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--pi-bg);
  color: var(--pi-text);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.65;
}
a { color: inherit; }
img { max-width: 100%; }

.pi-header {
  min-height: 72px;
  padding: 0 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--pi-border);
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(14px);
}
.pi-brand { text-decoration: none; }
.pi-brand strong { font-size: 20px; letter-spacing: -.03em; }
.pi-brand span { margin-left: 9px; color: var(--pi-muted); font-size: 13px; }
.pi-header nav { display: flex; flex-wrap: wrap; gap: 18px; }
.pi-header nav a { color: #39414b; font-size: 13px; font-weight: 700; text-decoration: none; }
.pi-header nav a:hover { text-decoration: underline; }

.pi-hero {
  max-width: 1120px;
  margin: 0 auto;
  padding: 78px 28px 48px;
}
.pi-eyebrow {
  margin: 0 0 12px;
  color: #526777;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .16em;
}
.pi-hero h1 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(42px, 7vw, 78px);
  line-height: .98;
  letter-spacing: -.055em;
}
.pi-hero-lead {
  max-width: 790px;
  margin: 24px 0 0;
  color: var(--pi-muted);
  font-size: clamp(17px, 2vw, 21px);
}
.pi-hero-actions { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; }
.pi-button {
  display: inline-block;
  padding: 13px 17px;
  border: 1px solid var(--pi-dark);
  border-radius: 11px;
  background: var(--pi-dark);
  color: #fff;
  font-size: 14px;
  font-weight: 750;
  text-decoration: none;
}
.pi-button.secondary { background: transparent; color: var(--pi-dark); }

.pi-main { max-width: 1120px; margin: 0 auto; padding: 0 28px 84px; }
.pi-section { margin-top: 30px; padding: 34px; border: 1px solid var(--pi-border); border-radius: var(--pi-radius); background: var(--pi-surface); box-shadow: var(--pi-shadow); }
.pi-section h2 { margin: 0 0 14px; font-size: clamp(25px, 3vw, 38px); line-height: 1.12; letter-spacing: -.035em; }
.pi-section h3 { margin: 27px 0 8px; font-size: 19px; }
.pi-section p { color: #4f5863; }
.pi-section p:last-child { margin-bottom: 0; }
.pi-section ul, .pi-section ol { padding-left: 23px; }
.pi-section li { margin: 8px 0; color: #404954; }

.pi-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 18px; }
.pi-grid.three { grid-template-columns: repeat(3, minmax(0,1fr)); }
.pi-card { padding: 22px; border: 1px solid var(--pi-border); border-radius: 16px; background: #fff; }
.pi-card h3 { margin: 0 0 7px; }
.pi-card p { margin: 0; color: var(--pi-muted); }
.pi-step-number { width: 32px; height: 32px; margin-bottom: 15px; display: grid; place-items: center; border-radius: 50%; background: var(--pi-dark); color: #fff; font-size: 13px; font-weight: 800; }

.pi-notice { margin: 24px 0; padding: 20px 22px; border: 1px solid #cbd8df; border-left: 5px solid #52718a; border-radius: 14px; background: #edf4f7; }
.pi-notice.warning { border-color: #ead7a6; border-left-color: #a87911; background: #fff8e7; }
.pi-notice strong { display: block; margin-bottom: 5px; }
.pi-notice p { margin: 0; }

.pi-table-wrap { overflow-x: auto; }
.pi-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.pi-table th, .pi-table td { padding: 12px 13px; border-bottom: 1px solid var(--pi-border); text-align: left; white-space: nowrap; }
.pi-table th { color: #55606c; font-size: 11px; letter-spacing: .06em; }
.pi-status { color: #176a42; font-weight: 800; }

.pi-test { margin-top: 28px; overflow: hidden; border: 1px solid var(--pi-border); border-radius: 18px; background: #fff; }
.pi-test-images { display: grid; grid-template-columns: 1fr 1fr; }
.pi-test-figure { margin: 0; min-width: 0; }
.pi-test-figure + .pi-test-figure { border-left: 1px solid var(--pi-border); }
.pi-test-figure img { width: 100%; aspect-ratio: 1 / 1; display: block; object-fit: cover; background: #e9edf0; }
.pi-test-figure.landscape img { aspect-ratio: 3 / 2; }
.pi-test-figure.portrait img { aspect-ratio: 4 / 5; }
.pi-test-figure figcaption { padding: 10px 14px; color: #59636f; font-size: 12px; font-weight: 750; }
.pi-test-images { position: relative; cursor: zoom-in; }
.pi-test-images::after { content: "Click to zoom"; position: absolute; right: 12px; top: 12px; padding: 7px 10px; border-radius: 999px; background: rgba(17,23,32,.88); color: #fff; font-size: 11px; font-weight: 800; box-shadow: 0 4px 14px rgba(0,0,0,.2); pointer-events: none; }
.pi-test-images:focus-visible { outline: 3px solid var(--pi-blue); outline-offset: 4px; }
.pi-zoom-note { margin-bottom: 6px; }
.pi-test-copy { padding: 20px 22px 23px; }
.pi-test-copy h3 { margin: 0 0 7px; }
.pi-test-copy p { margin: 0; color: var(--pi-muted); }
.pi-metrics { margin-top: 15px; display: flex; flex-wrap: wrap; gap: 8px; }
.pi-metrics span { padding: 6px 9px; border: 1px solid var(--pi-border); border-radius: 999px; background: var(--pi-soft); color: #47515d; font-size: 11px; font-weight: 750; }

.pi-definition { display: grid; grid-template-columns: 190px 1fr; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--pi-border); }
.pi-definition:last-child { border-bottom: 0; }
.pi-definition strong { font-size: 14px; }
.pi-definition span { color: var(--pi-muted); }

.pi-footer { padding: 48px 28px 26px; background: var(--pi-dark); color: #dfe7ef; }
.pi-footer-grid { max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: 1.2fr 1.45fr 1fr 1fr; gap: 38px; }
.pi-footer h2 { margin: 0 0 15px; color: #8da6ff; font-size: 11px; letter-spacing: .11em; }
.pi-footer a { display: block; margin-bottom: 9px; color: #d8e5ff; font-size: 13px; text-decoration: none; }
.pi-footer a:hover { color: #fff; text-decoration: underline; }
.pi-footer-bottom { max-width: 1080px; margin: 38px auto 0; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.1); color: #8f9aaa; font-size: 12px; }

body.pi-zoom-open { overflow: hidden; }
.pi-zoom[hidden] { display: none; }
.pi-zoom { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 20px; background: rgba(6,10,15,.92); }
.pi-zoom-panel { width: min(1420px, 100%); max-height: calc(100vh - 40px); overflow: hidden; border: 1px solid rgba(255,255,255,.18); border-radius: 18px; background: #101720; color: #fff; box-shadow: 0 30px 100px rgba(0,0,0,.55); }
.pi-zoom-bar { min-height: 62px; padding: 10px 14px 10px 20px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid rgba(255,255,255,.13); }
.pi-zoom-bar strong { display: block; font-size: 15px; }
.pi-zoom-bar span { display: block; color: #aab7c5; font-size: 12px; }
.pi-zoom-controls { display: flex; gap: 7px; }
.pi-zoom-controls button { min-width: 42px; height: 40px; padding: 0 12px; border: 1px solid rgba(255,255,255,.2); border-radius: 9px; background: #1d2936; color: #fff; font: inherit; font-weight: 800; cursor: pointer; }
.pi-zoom-controls button:hover, .pi-zoom-controls button:focus-visible { background: #314154; outline: none; }
.pi-zoom-controls .pi-zoom-close { margin-left: 7px; background: #fff; color: #101720; font-size: 23px; }
.pi-zoom-stage { height: min(72vh, 850px); display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: rgba(255,255,255,.18); touch-action: none; user-select: none; }
.pi-zoom-stage figure { min-width: 0; margin: 0; display: grid; grid-template-rows: 1fr auto; overflow: hidden; background: #0a0f15; }
.pi-zoom-viewport { min-height: 0; position: relative; overflow: hidden; cursor: grab; }
.pi-zoom-viewport:active { cursor: grabbing; }
.pi-zoom-viewport img { width: 100%; height: 100%; display: block; object-fit: contain; transform-origin: 50% 50%; will-change: transform; pointer-events: none; }
.pi-zoom-stage figcaption { padding: 10px 14px; background: #111a24; color: #dce6ef; font-size: 12px; font-weight: 750; text-align: center; }
.pi-zoom-help { margin: 0; padding: 10px 16px 12px; color: #aab7c5; font-size: 12px; text-align: center; }

@media (max-width: 820px) {
  .pi-header { padding: 14px 20px; align-items: flex-start; }
  .pi-header nav { justify-content: flex-end; gap: 11px; }
  .pi-grid, .pi-grid.three { grid-template-columns: 1fr; }
  .pi-footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .pi-header { position: static; flex-direction: column; }
  .pi-header nav { justify-content: flex-start; }
  .pi-brand span { display: none; }
  .pi-hero { padding: 50px 20px 30px; }
  .pi-main { padding: 0 16px 60px; }
  .pi-section { padding: 24px 20px; }
  .pi-test-images { grid-template-columns: 1fr; }
  .pi-test-figure + .pi-test-figure { border-left: 0; border-top: 1px solid var(--pi-border); }
  .pi-definition { grid-template-columns: 1fr; gap: 4px; }
  .pi-footer-grid { grid-template-columns: 1fr; }
  .pi-zoom { padding: 0; }
  .pi-zoom-panel { height: 100%; max-height: none; border: 0; border-radius: 0; }
  .pi-zoom-bar { min-height: 58px; padding-left: 14px; }
  .pi-zoom-bar strong { font-size: 13px; }
  .pi-zoom-controls button { min-width: 36px; height: 36px; padding: 0 9px; }
  .pi-zoom-stage { height: calc(100vh - 126px); grid-template-columns: 1fr; grid-template-rows: 1fr 1fr; }
  .pi-zoom-stage figcaption { padding: 5px 10px; font-size: 10px; }
  .pi-zoom-help { display: none; }
}
