:root {
  --navy: #0f2a47;
  --teal: #168f83;
  --red: #b8322a;
  --amber: #d98e2b;
  --ink: #172632;
  --muted: #5d6c79;
  --paper: #f4f7f8;
  --white: #fff;
  --line: #d6e0e4;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font: 16px/1.5 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.language-switcher { position: fixed; top: 14px; right: 16px; z-index: 10; display: flex; align-items: center; gap: 2px; padding: 4px; color: #cfe1e8; background: rgba(8,31,49,.86); border: 1px solid rgba(255,255,255,.22); border-radius: 9px; box-shadow: 0 5px 18px rgba(0,0,0,.18); backdrop-filter: blur(8px); }
.language-switcher button { min-width: 38px; padding: 6px 8px; color: #cfe1e8; background: transparent; border-radius: 6px; font-size: .82rem; }
.language-switcher button.active { color: var(--navy); background: white; }
.language-switcher span { color: rgba(255,255,255,.4); }
.hero {
  min-height: 320px;
  padding: 64px max(6vw, 32px);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  color: white;
  background: linear-gradient(125deg, var(--navy), #164d68);
  border-bottom: 8px solid var(--teal);
}
.hero-copy { max-width: 900px; }
.hero h1 { font-size: clamp(2.4rem, 5vw, 4.8rem); line-height: 1; margin: 8px 0 20px; max-width: 900px; }
.hero p { font-size: 1.25rem; max-width: 760px; }
.hero-cta { margin-top: 10px; color: var(--navy); background: white; }
.hero-side { display: grid; gap: 16px; width: min(100%, 300px); margin-left: 40px; }
.progress-card { padding: 20px; color: var(--ink); background: rgba(255,255,255,.96); border-radius: 12px; box-shadow: 0 12px 30px rgba(0,0,0,.14); }
.progress-card-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.progress-card-heading span { color: var(--muted); font-size: .82rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.progress-card-heading strong { color: var(--navy); font-size: 1.2rem; }
.progress-card p { margin: 12px 0; color: var(--muted); font-size: .94rem; }
.progress-track, .mini-track { width: 100%; height: 8px; margin-top: 12px; overflow: hidden; appearance: none; border: 0; background: #dce6e9; border-radius: 999px; }
.progress-track::-webkit-progress-bar, .mini-track::-webkit-progress-bar, .score-meter::-webkit-progress-bar { background: #dce6e9; border-radius: 999px; }
.progress-track::-webkit-progress-value, .score-meter::-webkit-progress-value { background: var(--teal); border-radius: 999px; transition: width .35s ease; }
.progress-track::-moz-progress-bar, .score-meter::-moz-progress-bar { background: var(--teal); border-radius: 999px; }
.progress-card.complete { outline: 3px solid rgba(92,224,210,.45); }
.hero-actions { display: grid; gap: 10px; min-width: 190px; }
.hero-actions button { width: 100%; }
.mode-button { background: var(--amber); }
.mode-button.online { background: var(--teal); }
.hero-status { min-height: 42px; max-width: 260px; color: #d9e7ed; font-size: .9rem; }
.hero-status.success { color: #7df0df; }
.hero-status.failure { color: #ffc3bd; }
.eyebrow, .section-heading span { color: #5ce0d2; text-transform: uppercase; letter-spacing: .14em; font-weight: 800; }
nav { position: sticky; top: 0; z-index: 3; display: flex; gap: 28px; padding: 16px 6vw; background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); backdrop-filter: blur(8px); }
nav a, a { color: var(--teal); font-weight: 700; text-decoration: none; }
nav a { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); transition: color .2s ease; }
nav a.active { color: var(--navy); }
nav a.complete { color: var(--teal); }
.nav-state { width: 9px; height: 9px; background: #c4d0d5; border-radius: 50%; }
nav a.complete .nav-state { background: var(--teal); box-shadow: 0 0 0 4px rgba(22,143,131,.12); }
main { max-width: 1200px; margin: auto; }
section { margin: 42px 20px; padding: 42px; background: white; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 12px 30px rgba(15,42,71,.07); }
.section-heading h2 { margin: 5px 0; font-size: 2rem; }
.section-heading span { color: var(--teal); }
.warning { margin: 24px 0; padding: 14px; border-left: 5px solid var(--amber); background: #fff8ea; }
.controls, .presets { display: flex; flex-wrap: wrap; gap: 12px; margin: 18px 0; }
input { width: 100%; padding: 12px; border: 1px solid #aebdc4; border-radius: 7px; font: inherit; }
.controls input { flex: 1; min-width: 280px; }
button, .button-link {
  border: 0; border-radius: 7px; padding: 12px 18px; color: white; background: var(--teal);
  font: inherit; font-weight: 750; cursor: pointer; display: inline-block;
}
button:disabled { cursor: wait; opacity: .65; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid rgba(22,143,131,.35); outline-offset: 3px; }
button.secondary, .presets button { color: var(--navy); background: #e8eff2; }
button.danger, .button-link.danger { background: var(--red); color: white; }
.presets button.active { color: white; background: var(--navy); }
.live-preview { display: grid; grid-template-columns: minmax(185px, .7fr) minmax(160px, 1fr) minmax(220px, 1.3fr); align-items: center; gap: 18px; margin-top: 22px; padding: 18px; background: #f4f8f9; border: 1px solid var(--line); border-radius: 10px; }
.live-preview strong { display: block; color: var(--navy); font-size: 1.15rem; }
.preview-label { display: block; color: var(--teal); font-size: .76rem; font-weight: 850; letter-spacing: .09em; text-transform: uppercase; }
.mini-track { margin: 0; }
.mini-track::-webkit-progress-value { background: var(--amber); border-radius: 999px; transition: width .2s ease; }
.mini-track::-moz-progress-bar { background: var(--amber); border-radius: 999px; }
.mini-track.target-met::-webkit-progress-value { background: var(--teal); }
.mini-track.target-met::-moz-progress-bar { background: var(--teal); }
#length-hint { color: var(--muted); font-size: .92rem; }
.result-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 24px; }
.result-grid > div { position: relative; padding: 22px; overflow: hidden; background: #edf3f5; border-radius: 10px; animation: rise-in .3s ease both; }
.result-grid > div.has-tooltip { overflow: visible; z-index: 2; }
.result-grid > div:nth-child(2) { animation-delay: .04s; }
.result-grid > div:nth-child(3) { animation-delay: .08s; }
.result-grid > div:nth-child(4) { animation-delay: .12s; }
.result-grid > div:nth-child(5) { animation-delay: .16s; }
.result-grid > div:nth-child(6) { animation-delay: .2s; }
.result-grid strong { display: block; color: var(--navy); font-size: 1.55rem; }
.result-grid span { color: var(--muted); }
.metric-label { display: inline-flex; align-items: center; gap: 7px; }
.result-grid .bad { border-left: 6px solid var(--red); }
.result-grid .good { border-left: 6px solid var(--teal); }
.score-meter { position: absolute; right: 0; bottom: 0; left: 0; width: 100%; height: 5px; appearance: none; border: 0; background: #d4dfe3; }
.score-meter::-webkit-progress-value { background: var(--amber); }
.score-meter::-moz-progress-bar { background: var(--amber); }
.analysis-feedback { margin-top: 14px; padding: 18px 20px; background: #fff8ea; border-left: 5px solid var(--amber); border-radius: 7px; }
.analysis-feedback strong { display: block; margin-bottom: 4px; }
.analysis-feedback ul { margin: 8px 0 0; padding-left: 20px; }
.empty { color: var(--muted); padding: 28px; text-align: center; }
.panel { margin-top: 22px; padding: 22px; border: 1px solid var(--line); border-radius: 10px; overflow-x: auto; }
.metric { font-size: 1.25rem; margin-bottom: 15px; }
.stuffing-explainer { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: center; gap: 14px; margin: 24px 0; }
.stuffing-explainer > div { min-height: 130px; padding: 18px; background: #f3f7f8; border-radius: 10px; }
.stuffing-explainer strong { display: block; margin-top: 10px; color: var(--navy); }
.stuffing-explainer p { margin: 4px 0 0; color: var(--muted); font-size: .92rem; }
.explainer-number { display: grid; width: 30px; height: 30px; place-items: center; color: white; background: var(--teal); border-radius: 50%; font-weight: 850; }
.explainer-arrow { color: var(--teal); font-size: 1.4rem; font-weight: 900; }
.stuffing-lab { display: grid; gap: 22px; }
.lab-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.lab-heading h3 { margin: 3px 0; color: var(--navy); font-size: 1.4rem; }
.lab-heading p { margin: 0; color: var(--muted); }
.lab-progress { min-width: 125px; padding: 12px 14px; text-align: center; background: #edf3f5; border-radius: 9px; }
.lab-progress strong { display: block; color: var(--navy); font-size: 1.35rem; }
.lab-progress span { color: var(--muted); font-size: .82rem; }
.lab-step { padding: 20px; background: #f7f9fa; border: 1px solid var(--line); border-radius: 10px; }
.lab-step-heading { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.lab-step-heading span { display: grid; width: 28px; height: 28px; place-items: center; color: white; background: var(--navy); border-radius: 50%; font-weight: 850; }
.lab-step-heading strong { color: var(--navy); }
.credential-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.credential-card { padding: 14px; color: var(--ink); text-align: left; background: white; border: 2px solid var(--line); }
.credential-card:hover, .credential-card.selected { color: var(--ink); background: #eaf8f5; border-color: var(--teal); }
.credential-card span, .credential-card code { display: block; }
.credential-card span { overflow: hidden; font-weight: 800; text-overflow: ellipsis; }
.credential-card code { margin-top: 5px; color: var(--red); background: transparent; font-size: .84rem; }
.replay-workbench { display: grid; grid-template-columns: minmax(220px, .9fr) auto minmax(280px, 1.4fr); align-items: stretch; gap: 14px; }
.stolen-credential { display: grid; align-content: center; padding: 18px; color: white; background: var(--navy); border-radius: 10px; }
.stolen-credential span { color: #b9d2de; font-size: .78rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.stolen-credential strong, .stolen-credential code { display: block; overflow-wrap: anywhere; }
.stolen-credential code { margin-top: 5px; color: #8cf1e4; background: transparent; }
.replay-arrow { display: grid; place-items: center; color: var(--teal); font-size: 1.8rem; font-weight: 900; }
.target-services { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.target-button { display: grid; align-content: center; min-height: 105px; color: var(--navy); text-align: left; background: white; border: 2px solid var(--line); }
.target-button:hover { border-color: var(--teal); }
.target-button.testing { color: white; background: var(--navy); animation: pulse .45s ease infinite alternate; }
.target-button.takeover { color: var(--red); background: #fff0ee; border-color: #e4a69f; }
.target-button.rejected { color: var(--teal); background: #eaf8f5; border-color: #8bcfc5; }
.target-button small { margin-top: 5px; color: inherit; font-weight: 650; }
.attempt-explanation { padding: 17px 18px; background: #eef3f5; border-radius: 9px; }
.attempt-explanation.takeover { background: #fff0ee; border-left: 5px solid var(--red); }
.attempt-explanation.rejected { background: #eaf8f5; border-left: 5px solid var(--teal); }
.attempt-explanation strong { display: block; color: var(--navy); }
.attempt-explanation p { margin: 4px 0 0; color: var(--muted); }
.attack-matrix { width: 100%; table-layout: fixed; }
.attack-matrix th:not(:first-child), .attack-matrix td:not(:first-child) { text-align: center; }
.matrix-result { display: inline-block; min-width: 88px; padding: 6px 8px; background: #edf3f5; border-radius: 999px; font-size: .78rem; font-weight: 850; }
.matrix-result.takeover { color: var(--red); background: #ffe3df; }
.matrix-result.rejected { color: var(--teal); background: #dff4ef; }
.lab-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.lab-summary { padding: 20px; background: #eef3f5; border-radius: 10px; }
.lab-summary.bad { border-left: 6px solid var(--red); }
.lab-summary.good { border-left: 6px solid var(--teal); }
.lab-summary strong { display: block; color: var(--navy); font-size: 1.2rem; }
.lab-summary p { margin: 5px 0 0; color: var(--muted); }
.scenario-comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.scenario-summary { padding: 20px; background: #f1f5f6; border-radius: 9px; }
.scenario-summary strong { display: block; color: var(--navy); font-size: 1.7rem; }
.scenario-summary.bad { border-top: 5px solid var(--red); }
.scenario-summary.good { border-top: 5px solid var(--teal); }
table { width: 100%; border-collapse: collapse; margin-top: 16px; }
th, td { padding: 10px; text-align: left; border-bottom: 1px solid var(--line); }
.bad-text { color: var(--red); font-weight: 800; }
.good-text { color: var(--teal); font-weight: 800; }
pre { padding: 14px; background: #10283d; color: #e6f4f3; border-radius: 7px; overflow: auto; }
.comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 24px; }
.comparison article { padding: 28px; border: 1px solid var(--line); border-radius: 12px; }
.comparison article.highlighted { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(22,143,131,.12); }
.comparison label { display: block; margin: 12px 0; color: var(--muted); font-weight: 700; }
.comparison button { margin: 5px 6px 5px 0; }
.status { min-height: 48px; margin: 16px 0; padding: 12px; background: #eef3f5; border-radius: 7px; }
.status.success { border-left: 5px solid var(--teal); }
.status.failure { border-left: 5px solid var(--red); }
.browser-warning { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 24px; padding: 18px 20px; background: #fff8ea; border: 1px solid #efd49c; border-left: 6px solid var(--amber); border-radius: 10px; }
.browser-warning[hidden] { display: none; }
.browser-warning strong { color: var(--navy); }
.browser-warning p { margin: 4px 0 0; color: var(--muted); }
.passkey-heading { display: flex; align-items: center; gap: 9px; }
.passkey-heading h3 { margin: 0; }
.help-button { position: relative; display: inline-grid; width: 26px; height: 26px; margin: 0; padding: 0; place-items: center; color: var(--navy); background: #e8eff2; border: 1px solid #c5d3d9; border-radius: 50%; font-size: .9rem; line-height: 1; }
.help-button.compact-help { width: 20px; height: 20px; font-size: .72rem; }
.help-button:hover, .help-button:focus-visible { color: white; background: var(--teal); border-color: var(--teal); }
.help-button::after { content: attr(data-tooltip); position: absolute; right: 50%; bottom: calc(100% + 10px); z-index: 4; width: max-content; max-width: 230px; padding: 7px 10px; color: white; background: var(--navy); border-radius: 6px; opacity: 0; pointer-events: none; transform: translateX(50%) translateY(4px); transition: opacity .15s ease, transform .15s ease; font-size: .78rem; font-weight: 700; line-height: 1.3; }
.help-button:hover::after, .help-button:focus-visible::after { opacity: 1; transform: translateX(50%) translateY(0); }
.transfer-demo { display: grid; grid-template-columns: 1.2fr auto 1.4fr; align-items: center; gap: 18px; margin-top: 20px; padding: 22px; background: #f5f8f9; border: 1px solid var(--line); border-radius: 12px; }
.transfer-demo strong { display: block; color: var(--navy); }
.segmented-control { display: flex; padding: 4px; background: #dfe8eb; border-radius: 9px; }
.segmented-control button { padding: 9px 13px; color: var(--muted); background: transparent; }
.segmented-control button.active { color: white; background: var(--navy); }
.transfer-result { padding: 14px 16px; border-radius: 8px; transition: background .2s ease, transform .2s ease; }
.transfer-result span { display: block; color: var(--muted); font-size: .9rem; }
.transfer-result.danger-result { background: #fff0ee; border-left: 5px solid var(--red); }
.transfer-result.safe-result { background: #eaf8f5; border-left: 5px solid var(--teal); }
.transfer-result.changed { transform: scale(.98); }
.phish-callout { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 24px; padding: 22px; background: #fff4f2; border: 1px solid #edc2bd; border-radius: 10px; }
.activity-section { padding-top: 30px; padding-bottom: 30px; }
.activity-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.activity-heading h2 { margin: 3px 0 0; }
.small-button { padding: 9px 14px; }
.activity-log { display: grid; gap: 8px; margin: 20px 0 0; padding: 0; list-style: none; }
.activity-log li { display: grid; grid-template-columns: 72px 1fr; gap: 14px; padding: 12px 14px; background: #f3f7f8; border-radius: 7px; animation: rise-in .25s ease; }
.activity-log time { color: var(--teal); font-variant-numeric: tabular-nums; font-weight: 800; }
.activity-log .empty-activity { display: block; color: var(--muted); text-align: center; }
.setup-dialog { width: min(680px, calc(100vw - 32px)); max-height: calc(100vh - 40px); padding: 0; color: var(--ink); background: white; border: 0; border-radius: 16px; box-shadow: 0 24px 70px rgba(15,42,71,.32); }
.setup-dialog::backdrop { background: rgba(8,24,38,.68); backdrop-filter: blur(3px); }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; padding: 26px 28px 20px; border-bottom: 1px solid var(--line); }
.dialog-heading h2 { margin: 4px 0 0; color: var(--navy); font-size: 1.55rem; }
.dialog-close { min-width: 42px; padding: 7px 12px; color: var(--muted); background: #edf3f5; font-size: 1.4rem; line-height: 1; }
.setup-steps { display: grid; gap: 0; margin: 0; padding: 8px 28px; list-style: none; counter-reset: setup-step; }
.setup-steps li { position: relative; padding: 16px 0 16px 48px; border-bottom: 1px solid var(--line); counter-increment: setup-step; }
.setup-steps li:last-child { border-bottom: 0; }
.setup-steps li::before { content: counter(setup-step); position: absolute; top: 15px; left: 0; display: grid; width: 32px; height: 32px; place-items: center; color: white; background: var(--teal); border-radius: 50%; font-weight: 850; }
.setup-steps strong, .setup-steps span { display: block; }
.setup-steps strong { color: var(--navy); }
.setup-steps span { margin-top: 3px; color: var(--muted); }
kbd { padding: 3px 7px; color: var(--navy); background: #e8eff2; border: 1px solid #c9d6db; border-bottom-width: 2px; border-radius: 5px; font: 700 .88em/1.4 system-ui, sans-serif; white-space: nowrap; }
.dialog-note { margin: 4px 28px 20px; padding: 14px 16px; color: var(--muted); background: #f3f7f8; border-radius: 8px; font-size: .92rem; }
.dialog-actions { display: flex; justify-content: flex-end; padding: 18px 28px; background: #f7f9fa; border-top: 1px solid var(--line); }
footer { padding: 36px; color: var(--muted); text-align: center; }
code { padding: 2px 5px; background: #e8eff2; border-radius: 4px; }
.phish-banner { padding: 14px; color: white; background: var(--red); text-align: center; font-weight: 900; letter-spacing: .08em; }
.phish-main { max-width: 950px; }
.phish-page h1 { font-size: 2.7rem; margin-bottom: 5px; }
.phish-page .eyebrow { color: var(--red); }
@keyframes rise-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  from { opacity: .72; }
  to { opacity: 1; }
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
@media (max-width: 760px) {
  .hero { display: block; padding: 40px 24px; }
  .hero-side { margin: 28px 0 0; }
  .hero-actions { max-width: 300px; }
  nav { gap: 14px; overflow-x: auto; }
  nav a { white-space: nowrap; }
  section { padding: 24px; }
  .result-grid, .comparison, .scenario-comparison, .credential-cards { grid-template-columns: 1fr; }
  .live-preview, .transfer-demo { grid-template-columns: 1fr; }
  .stuffing-explainer { grid-template-columns: 1fr; }
  .explainer-arrow { transform: rotate(90deg); text-align: center; }
  .replay-workbench { grid-template-columns: 1fr; }
  .replay-arrow { transform: rotate(90deg); }
  .phish-callout, .browser-warning { align-items: flex-start; flex-direction: column; }
  .dialog-heading { padding: 22px 20px 18px; }
  .setup-steps { padding-right: 20px; padding-left: 20px; }
  .dialog-note { margin-right: 20px; margin-left: 20px; }
  .dialog-actions { padding: 16px 20px; }
}
