:root {
  --bg: #18191a;
  --sidebar: #242526;
  --panel: #242526;
  --panel-2: #2d2f30;
  --field: #3a3b3c;
  --line: #3e4042;
  --text: #f2f3f5;
  --muted: #b0b3b8;
  --teal: #38c5c0;
  --blue: #2d88ff;
  --gold: #e2a73a;
  --coral: #ec7063;
  --green: #4fc08d;
  font-family: "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}

* { box-sizing: border-box; }
html { min-width: 320px; }
body { margin: 0; min-height: 100vh; overflow-x: clip; font-size: 16px; background: var(--bg); }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button { cursor: pointer; }
h1, h2, h3, h4, h5, h6, strong, b, th { font-weight: 500; }

.signin-success { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; overflow: hidden; background: #17191af5; opacity: 0; pointer-events: none; transition: opacity 260ms ease; }
.signin-success[hidden] { display: none; }
.signin-success.visible { opacity: 1; }
.signin-success-art { width: min(760px, 88vw); display: grid; justify-items: center; transform: translateY(18px) scale(.72); opacity: 0; filter: drop-shadow(0 28px 45px #000b); }
.signin-success.visible .signin-success-art { animation: impact-success-in 780ms cubic-bezier(.18,.85,.22,1.12) forwards, impact-success-breathe 900ms ease-in-out 780ms infinite alternate; }
.signin-success-art::after { content: ""; width: min(520px, 66vw); height: 3px; margin-top: -3.5%; background: linear-gradient(90deg, transparent, #21b637, #f0dc00, #ff1e17, transparent); opacity: .8; transform: scaleX(0); animation: impact-success-sweep 900ms ease-out 420ms forwards; }
.signin-success-art img { width: 100%; height: auto; display: block; }
.signin-success-art p { margin: 16px 0 0; color: white; font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace; font-size: 18px; font-weight: 500; letter-spacing: 0; }
.signin-success.leaving { opacity: 0; }

@keyframes impact-success-in {
  0% { opacity: 0; transform: translateY(18px) scale(.72); }
  62% { opacity: 1; transform: translateY(-4px) scale(1.035); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes impact-success-breathe {
  from { filter: drop-shadow(0 28px 45px #000b) brightness(1); }
  to { filter: drop-shadow(0 30px 52px #0da3b94d) brightness(1.06); }
}
@keyframes impact-success-sweep {
  from { opacity: 0; transform: scaleX(0); }
  to { opacity: .8; transform: scaleX(1); }
}

.sidebar {
  position: fixed;
  inset: 98px auto 0 0;
  z-index: 5;
  width: 324px;
  display: flex;
  flex-direction: column;
  padding: 0 12px 18px;
  background: var(--sidebar);
  border-right: 0;
}

.product { min-height: 70px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border-bottom: 0; }
.product strong { font-size: 1.65rem; }
.product span { color: var(--teal); font-size: 1rem; }
.mast-brand { width: 300px; min-height: 98px; justify-content: flex-start; gap: 24px; padding-inline: 0; }
#product-logo { width: 124px; height: 76px; flex: 0 0 124px; object-fit: contain; object-position: left center; }
.impact-gauge { width: 104px; height: 76px; flex: 0 0 104px; object-fit: contain; }
.org-avatar { width: 42px; height: 42px; flex: 0 0 42px; display: grid; place-items: center; border-radius: 50%; color: #102f32; background: var(--teal); font-weight: 500; }
.org-avatar.has-logo { overflow: hidden; border: 1px solid #55595b; border-radius: 6px; background: #fff; }
.org-avatar.has-logo img { width: 100%; height: 100%; object-fit: contain; padding: 3px; }
.sidebar nav { display: grid; gap: 3px; }
.sidebar nav > small { padding: 15px 12px 5px; color: #7f8287; font-size: .64rem; font-weight: 500; text-transform: uppercase; }
.sidebar nav button { min-width: 0; padding: 11px 13px; border: 0; border-radius: 6px; color: #d5d7da; background: transparent; text-align: left; font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace; font-size: 15px; font-weight: 400; }
.sidebar nav button:hover, .sidebar nav button:focus-visible { color: white; background: #333536; }
.sidebar nav button.active { color: white; background: #3a3b3c; box-shadow: inset 3px 0 var(--teal); }
.privacy-state { display: flex; align-items: center; gap: 8px; margin: auto 10px 0; color: #92959a; font-size: .7rem; }
.privacy-state i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }

main { min-width: 0; min-height: calc(100vh - 98px); margin-left: 324px; padding: 24px 32px 56px; background: var(--bg); }
.masthead { position: relative; z-index: 6; min-height: 98px; display: grid; grid-template-columns: 300px minmax(0, 1fr) auto; grid-template-areas: "brand period actions"; align-items: center; gap: 20px; padding: 0 32px 0 12px; border-bottom: 1px solid #d8e2e6; color: #112c40; background: #fff; }
.mast-brand { grid-area: brand; }
.mast-context { display: none; }
.masthead h1 { margin: 0; color: white; font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace; font-size: 1.55rem; font-weight: 500; line-height: 1.15; }
.mast-actions, .period-fields { min-width: 0; display: flex; align-items: end; gap: 8px; }
.mast-actions { grid-area: actions; justify-self: end; }
.masthead > .period-fields { grid-area: period; justify-self: start; }
.field { min-width: 0; display: grid; gap: 4px; color: #506575; font-size: .68rem; font-weight: 500; }
.field input, .field select { width: 100%; height: 38px; min-width: 136px; padding: 0 10px; border: 1px solid #55575a; border-radius: 5px; color: var(--text); background: var(--field); color-scheme: dark; }
.field input { font-weight: 400; }
.org-picker { width: 190px; min-width: 0; flex: 0 1 190px; }
.org-picker select { min-width: 0; font-weight: 400; }
.org-picker[hidden] { display: none; }
.primary, .secondary { min-height: 39px; padding: 0 15px; border: 1px solid transparent; border-radius: 5px; font-size: 11px; font-weight: 500; }
.primary { color: #fff; border-color: #008fd0; background: #008fd0; }
.primary:hover, .primary:focus-visible { border-color: #087cab; background: #087cab; }
.secondary { color: var(--text); border-color: #5c5f62; background: var(--field); }
.secondary:hover, .secondary:focus-visible { border-color: var(--muted); }
#logout { width: 50px; flex: 0 0 50px; padding-inline: 4px; font-weight: 300; }
#request-report { width: 110px; flex: 0 0 110px; color: #fff; font-weight: 500; }
#apply { font-weight: 400; }
.masthead .field input, .masthead .field select { color: #112c40; border-color: #d8e2e6; background: #fff; color-scheme: light; }
.masthead .field input:hover, .masthead .field select:hover { border-color: #90a6b0; }
.masthead .field input:focus, .masthead .field select:focus { border-color: #008c83; outline: 2px solid #dff4eb; outline-offset: 1px; }
.masthead #apply { color: #fff; border-color: #008fd0; background: #008fd0; }
.masthead #logout { color: #082d4b; border-color: #d8e2e6; background: #fff; }
.full { width: 100%; }
.source-toast { position: fixed; top: 112px; right: 18px; z-index: 30; width: min(390px, calc(100vw - 36px)); display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 14px; border-left: 4px solid var(--blue); color: #d8e4f4; background: #26354a; box-shadow: 0 14px 38px #0009; font-size: .72rem; opacity: 0; transform: translateY(-10px); transition: opacity 180ms ease, transform 180ms ease; }
.source-toast.visible { opacity: 1; transform: translateY(0); }
.source-toast[hidden] { display: none; }
.source-toast button { width: 28px; height: 28px; flex: 0 0 28px; padding: 0; border: 0; color: #c9d9ef; background: transparent; font-size: 1.25rem; line-height: 1; }
[hidden] { display: none !important; }
.view { display: none; min-width: 0; }
.view.active { display: block; }

.eyebrow { margin: 0 0 5px; color: var(--teal); font-size: .66rem; font-weight: 500; text-transform: uppercase; letter-spacing: .09em; }
.welcome-row, .reports-intro { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 15px; }
.reports-actions { display: flex; align-items: center; gap: 8px; }
.report-refresh { width: 39px; height: 39px; flex: 0 0 39px; padding: 0; border: 1px solid #d8e2e6; border-radius: 50%; color: #082d4b; background: #fff; font-size: 22px; font-weight: 300; line-height: 1; }
.report-refresh:hover, .report-refresh:focus-visible { border-color: var(--muted); }
.report-refresh.is-spinning { animation: report-refresh-spin 700ms linear infinite; }
.report-open { color: var(--teal); font-size: 11px; font-weight: 400; text-decoration: none; white-space: nowrap; }
.report-open:hover, .report-open:focus-visible { color: #76e1dc; text-decoration: underline; }
.report-title-link { color: var(--text); text-decoration: none; }
.report-title-link:hover, .report-title-link:focus-visible { color: var(--teal); text-decoration: underline; }
@keyframes report-refresh-spin { to { transform: rotate(360deg); } }
.welcome-row h2, .view-intro h2 { margin: 0; color: white; font-size: 1.4rem; }
.welcome-row p:not(.eyebrow), .view-intro > p:not(.eyebrow) { margin: 5px 0 0; color: var(--muted); font-size: .82rem; }
.link-button { padding: 5px 0; border: 0; color: var(--teal); background: transparent; font-size: 11px; font-weight: 300; white-space: nowrap; }
.link-button span { padding-left: 4px; font-size: 1.05rem; }

.home-layout { display: grid; grid-template-columns: minmax(0, 2.15fr) minmax(260px, .85fr); gap: 14px; }
.home-main { min-width: 0; }
.home-side { display: grid; align-content: start; gap: 14px; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.metric { min-width: 0; min-height: 150px; display: flex; flex-direction: column; padding: 17px; border: 1px solid var(--line); border-top: 3px solid var(--teal); border-radius: 6px; color: var(--text); background: var(--panel); text-align: left; }
.metric.gold { border-top-color: var(--gold); }
.metric.coral { border-top-color: var(--coral); }
.metric.green { border-top-color: var(--green); }
.metric:hover, .metric:focus-visible { border-color: #5d6063; background: #2a2c2d; transform: translateY(-1px); }
.metric > span { color: var(--muted); font-size: .74rem; font-weight: 500; }
.metric > strong { margin: 13px 0 4px; color: white; font-size: 2rem; line-height: 1; }
.metric > small { min-height: 33px; color: #9fa2a7; font-size: .69rem; line-height: 1.4; }
.metric > em { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 9px; color: var(--teal); font-size: 11px; font-style: normal; font-weight: 500; }
.metric > em b { font-size: 1.05rem; }
.panel { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }
.journey-panel, .spaced { margin-top: 14px; }
.panel h3 { margin: 0; color: white; font-size: 1.05rem; }
#analytics .panel-heading h3 { font-weight: 400; }
.panel > p, .panel-heading p { margin: 5px 0 0; color: var(--muted); font-size: .75rem; line-height: 1.45; }
.panel-heading { display: flex; justify-content: space-between; align-items: start; gap: 16px; }
.journey { display: grid; grid-template-columns: auto 1fr auto 1fr auto 1fr auto; align-items: center; gap: 10px; margin-top: 25px; }
.journey div { min-width: 78px; }
.journey strong, .journey span { display: block; }
.journey strong { color: white; font-size: 1.3rem; }
.journey span { margin-top: 3px; color: var(--muted); font-size: .67rem; }
.journey i { height: 2px; background: #3f6665; }
.rate-row { display: flex; gap: 24px; margin-top: 21px; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: .72rem; }
.rate-row b { color: white; }
.code-performance { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin-top: 20px; background: var(--line); }
.code-performance div { min-width: 0; padding: 15px; background: var(--panel-2); }
.code-performance small, .code-performance strong { display: block; }
.code-performance small { min-height: 29px; color: var(--muted); font-size: .66rem; line-height: 1.35; }
.code-performance strong { margin-top: 6px; color: white; font-size: .95rem; overflow-wrap: anywhere; }
.readiness { display: grid; gap: 15px; margin-top: 19px; }
.readiness > div { display: grid; grid-template-columns: 1fr auto; gap: 7px; font-size: .74rem; }
.readiness-track, .bar-track { height: 8px; overflow: hidden; background: var(--field); }
.readiness-track { grid-column: 1 / -1; }
.readiness-track i, .bar-track i { display: block; height: 100%; background: var(--teal); }
.readiness > p { margin: 0; padding-top: 12px; border-top: 1px solid var(--line); color: var(--muted); font-size: .71rem; }

.org-status { background: linear-gradient(145deg, #253536, #242526 55%); }
.org-summary { display: flex; align-items: center; gap: 11px; margin: 18px 0; }
.org-summary strong, .org-summary small { display: block; }
.org-summary small { margin-top: 3px; color: var(--muted); font-size: .69rem; }
.org-status dl { margin: 0 0 16px; }
.org-status dl div { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); font-size: .71rem; }
.org-status dt { color: var(--muted); }
.org-status dd { margin: 0; color: #80d8b5; font-weight: 500; text-align: right; }
.status-pill { width: auto; min-width: 50px; height: 26px; display: inline-flex; align-items: center; justify-content: center; padding: 0 9px; border: 1px solid; border-radius: 999px; font-size: .64rem; font-weight: 500; white-space: nowrap; }
.status-pill.good { color: #fff; border-color: #009624; background: #00c853; }
.status-pill.watch { color: #201900; border-color: #b99b00; background: #ffd600; }
.status-pill.missing { color: #ff9ca5; border-color: #7d454a; background: #4e292c; }
.action-list { padding: 9px 18px; }
.action-list h3 { padding: 8px 0 12px; }
.action-list button { width: 100%; display: flex; justify-content: space-between; gap: 11px; padding: 13px 0; border: 0; border-top: 1px solid var(--line); color: var(--text); background: transparent; text-align: left; font-size: 11px; font-weight: 500; }
.action-list button b { color: var(--teal); }
.disclaimer { margin: 15px 0 0; color: #8e9196; font-size: .69rem; }

.view-intro { margin: 5px 0 18px; }
.metric-grid.compact .metric { min-height: 130px; }
.two-column { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.bar-list { display: grid; gap: 14px; margin-top: 19px; }
.bar-row > div:first-child { display: flex; justify-content: space-between; gap: 14px; margin-bottom: 6px; color: var(--muted); font-size: .74rem; }
.bar-row strong { color: white; }
.empty { padding: 23px; border: 1px dashed #55585b; border-radius: 6px; color: var(--muted); background: #202122; font-size: .77rem; }
.privacy-banner { display: grid; gap: 3px; margin-bottom: 14px; padding: 14px 16px; border-left: 4px solid var(--gold); border-radius: 4px; color: #efd39c; background: #403621; font-size: .74rem; }
.tracking-note { display: grid; gap: 3px; margin-bottom: 14px; padding: 12px 14px; border-left: 4px solid var(--blue); border-radius: 4px; color: #c9d9ef; background: #253346; font-size: .71rem; line-height: 1.45; }
.tracking-note strong { color: white; }
.view-toast { position: fixed; top: 18px; right: 18px; z-index: 30; width: min(460px, calc(100vw - 36px)); display: flex; align-items: start; justify-content: space-between; gap: 14px; margin: 0; box-shadow: 0 14px 38px #0009; opacity: 0; transform: translateY(-10px); transition: opacity 180ms ease, transform 180ms ease; }
.view-toast.visible { opacity: 1; transform: translateY(0); }
.view-toast[hidden] { display: none; }
.view-toast > span { display: grid; gap: 3px; }
.view-toast button { width: 28px; height: 28px; flex: 0 0 28px; padding: 0; border: 0; color: #c9d9ef; background: transparent; font-size: 1.25rem; line-height: 1; }
.table-wrap { width: 100%; max-width: 100%; min-width: 0; margin-top: 17px; overflow-x: auto; overscroll-behavior-inline: contain; -webkit-overflow-scrolling: touch; }
table { width: 100%; min-width: 620px; border-collapse: collapse; }
th, td { padding: 13px 11px; border-bottom: 1px solid var(--line); color: #d8dade; text-align: left; font-size: .72rem; }
th { color: #92959a; font-size: .64rem; text-transform: uppercase; }
td small { display: block; margin-top: 3px; color: var(--muted); }

body[data-view="reports"] main { color: #112c40; background: #f5f6f2; }
body[data-view="reports"] #reports .view-intro h2,
body[data-view="reports"] #reports .view-intro p,
body[data-view="reports"] #reports .report-title-link,
body[data-view="reports"] #reports td { color: #112c40; }
body[data-view="reports"] #reports .panel { border-color: #d8e2e6; background: #fff; }
body[data-view="reports"] #reports .empty { color: #647887; border-color: #d8e2e6; background: #fff; }
body[data-view="reports"] #reports th { color: #647887; }
body[data-view="reports"] #reports th,
body[data-view="reports"] #reports td { border-bottom-color: #d8e2e6; }
body[data-view="reports"] #reports td small { color: #647887; }
body[data-view="reports"] #reports .report-open { color: #008c83; }
body[data-view="reports"] #reports .report-title-link:hover,
body[data-view="reports"] #reports .report-title-link:focus-visible,
body[data-view="reports"] #reports .report-open:hover,
body[data-view="reports"] #reports .report-open:focus-visible { color: #075c60; }

.roi-sections { display: grid; gap: 14px; }
.roi-performance { padding: 21px; }
.roi-kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin-top: 20px; background: var(--line); }
.roi-kpis.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.roi-kpis > div, .roi-kpis > button { min-width: 0; padding: 17px; background: var(--panel-2); }
.roi-kpis > div.featured, .roi-kpis > button.featured { background: #124c5a; }
.roi-kpi-link { border: 0; border-radius: 0; color: inherit; text-align: left; cursor: pointer; transition: background-color 150ms ease, box-shadow 150ms ease; }
.roi-kpi-link:hover { background: #343638; }
.roi-kpi-link.featured:hover { background: #176071; }
.roi-kpi-link:focus-visible { position: relative; z-index: 1; outline: 2px solid var(--teal); outline-offset: -2px; }
.roi-kpi-link > span { display: block; margin-top: 10px; color: var(--teal); font-size: 11px; font-weight: 500; }
.roi-kpi-link.featured > span { color: #94f0ed; }
.roi-kpis small, .roi-kpis strong { display: block; }
.roi-kpis small { min-height: 30px; color: var(--muted); font-size: .67rem; line-height: 1.35; }
.roi-kpis .featured small { color: #b9d7dc; }
.roi-kpis strong { margin-top: 7px; color: white; font-size: 1.65rem; overflow-wrap: anywhere; }
#analytics .analytics-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 0; }
#analytics .analytics-kpis > div { padding: 12px 16px; }
#analytics .analytics-kpis small { min-height: 0; }
#analytics .analytics-kpis strong { margin-top: 5px; font-size: 1.45rem; }
.analytics-toolbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 16px; }
.analytics-toolbar h2 { margin: 0 0 4px; }
.analytics-toolbar p { margin: 0; color: var(--muted); }
.analytics-periods { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 7px; background: var(--panel); }
.analytics-period { min-height: 34px; padding: 0 13px; border: 0; border-radius: 5px; background: transparent; color: var(--ink); font: inherit; cursor: pointer; }
.analytics-period:hover { background: var(--panel-2); }
.analytics-period.active { background: #0097f5; color: white; font-weight: 700; }
.attention-summary { display: grid; grid-template-columns: minmax(260px, 1.2fr) minmax(420px, 1fr); align-items: center; gap: 28px; margin-bottom: 18px; padding: 22px 24px; border: 1px solid var(--line); border-left: 6px solid #64748b; border-radius: 8px; background: var(--panel); }
.attention-summary > div { display: flex; align-items: center; gap: 14px; }
.attention-signal { width: 14px; height: 14px; flex: 0 0 auto; border-radius: 50%; background: #64748b; box-shadow: 0 0 0 6px #e2e8f0; }
.attention-summary.up { border-left-color: #16a34a; }
.attention-summary.up .attention-signal { background: #16a34a; box-shadow: 0 0 0 6px #dcfce7; }
.attention-summary.steady { border-left-color: #0284c7; }
.attention-summary.steady .attention-signal { background: #0284c7; box-shadow: 0 0 0 6px #e0f2fe; }
.attention-summary.down, .attention-summary.quiet { border-left-color: #eab308; }
.attention-summary.down .attention-signal, .attention-summary.quiet .attention-signal { background: #eab308; box-shadow: 0 0 0 6px #fef9c3; }
.attention-summary small { color: var(--muted); text-transform: uppercase; font-size: .68rem; font-weight: 700; }
.attention-summary h3 { margin: 2px 0 3px; font-size: 1.35rem; }
.attention-summary p { margin: 0; color: var(--muted); }
.attention-summary dl { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; }
.attention-summary dl div { padding: 2px 14px; border-left: 1px solid var(--line); }
.attention-summary dt { color: var(--muted); font-size: .69rem; }
.attention-summary dd { margin: 5px 0 0; font-size: 1.2rem; font-weight: 700; }
.analytics-source { display: flex; align-items: center; gap: 9px; margin: 4px 0 10px; color: var(--muted); }
.analytics-source strong { color: var(--ink); font-size: .84rem; }
.analytics-source small { margin-left: auto; }
.analytics-section-heading { margin: 30px 0 14px; padding-top: 24px; border-top: 1px solid var(--line); }
.analytics-section-heading h2 { margin: 0 0 4px; font-size: 1.25rem; }
.analytics-section-heading p { margin: 0; color: var(--muted); }
.analytics-unavailable { margin-bottom: 18px; }
.cloudflare-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); overflow: hidden; }
.cloudflare-kpis > div { min-width: 0; padding: 18px 20px; border-right: 1px solid var(--line); }
.cloudflare-kpis > div:last-child { border-right: 0; }
.cloudflare-kpis small, .cloudflare-kpis strong, .cloudflare-kpis span { display: block; }
.cloudflare-kpis small { color: var(--muted); font-size: .72rem; }
.cloudflare-kpis strong { margin: 5px 0 3px; font-size: 1.65rem; }
.cloudflare-kpis span { color: var(--muted); font-size: .7rem; }
.cloudflare-dashboard { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.cloudflare-dashboard .panel { min-width: 0; margin: 0; padding: 20px; max-height: 430px; overflow: auto; }
.cloudflare-dashboard .traffic-over-time { grid-column: 1 / -1; overflow: hidden; }
.traffic-chart { width: 100%; }
.traffic-chart { position: relative; }
.traffic-chart svg { display: block; width: 100%; height: auto; aspect-ratio: 900 / 240; overflow: visible; }
.traffic-chart .chart-grid { stroke: #dfe7ec; stroke-width: 1; stroke-dasharray: 3 5; }
.traffic-chart .traffic-line { fill: none; stroke: #087fae; stroke-width: 2.25; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.chart-axis { fill: #6b7f8d; font-size: 9px; }
.chart-time { font-size: 8px; }
.traffic-point { fill: transparent; stroke: transparent; stroke-width: 2; cursor: crosshair; }
.traffic-point:hover, .traffic-point:focus { fill: #fff; stroke: #087fae; outline: none; }
.traffic-tooltip { position: absolute; z-index: 2; padding: 7px 9px; border-radius: 5px; background: #0b2942; color: #fff; font-size: .72rem; font-weight: 700; white-space: nowrap; transform: translate(-50%, calc(-100% - 8px)); pointer-events: none; box-shadow: 0 4px 12px rgba(11,41,66,.2); }
.live-refresh { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: .7rem; white-space: nowrap; }
.live-refresh i { width: 8px; height: 8px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 4px #dcfce7; }
.analytics-unavailable strong, .analytics-unavailable span { display: block; }
.analytics-unavailable span { margin-top: 4px; color: var(--muted); }
.detail-toolbar { margin-bottom: 16px; }
.detail-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
#rcc-detail .rcc-detail-summary { width: 300px; grid-template-columns: 100px 200px; }
#rcc-detail .rcc-detail-summary > div:nth-child(2) strong { width: 200px; font-weight: 300; }
#rcc-detail .panel-heading h3 { font-size: 20px; font-weight: 300; }
#rcc-detail .link-button { font-weight: 400; }
.yield-bar { display: grid; grid-template-columns: 115px minmax(120px, 1fr) auto; gap: 11px; align-items: center; margin-top: 17px; font-size: .7rem; }
.yield-bar span, .conversion-row span { color: var(--muted); }
.yield-bar > div { height: 8px; overflow: hidden; background: var(--field); }
.yield-bar i { display: block; height: 100%; background: var(--teal); }
.conversion-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 17px; }
.conversion-row.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.conversion-row div { display: grid; gap: 5px; padding: 12px 13px; border-left: 3px solid var(--teal); background: #202122; font-size: .71rem; }
.conversion-row b { color: white; overflow-wrap: anywhere; }
.roi-context > div { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 15px; }
.roi-context > div span { padding: 9px 11px; border: 1px solid var(--line); border-radius: 4px; color: var(--muted); font-size: .71rem; }
.roi-context > div strong { color: white; }
.health-summary { display: flex; gap: 34px; padding-bottom: 17px; }
.health-summary div { display: grid; gap: 2px; }
.health-summary strong { color: white; font-size: 1.7rem; }
.health-summary span { color: var(--muted); font-size: .71rem; }

.outcomes-intro { display: flex; align-items: end; justify-content: space-between; gap: 20px; }
.outcome-actions { display: flex; flex-wrap: wrap; justify-content: end; gap: 8px; }
.outcome-kpis { margin-top: 0; }
.outcome-kpis .featured span { display: block; margin-top: 7px; color: #b9d7dc; font-size: .67rem; }
.outcome-empty { margin-top: 14px; padding: 13px 15px; border-left: 4px solid var(--gold); color: #efd39c; background: #403621; font-size: .73rem; line-height: 1.45; }
.outcome-columns { margin-top: 14px; }
.pipeline { display: grid; grid-template-columns: auto 1fr auto 1fr auto 1fr auto; align-items: center; gap: 8px; margin-top: 23px; }
.pipeline span { display: grid; gap: 4px; min-width: 54px; color: var(--muted); font-size: .67rem; }
.pipeline b { color: white; font-size: 1.25rem; }
.pipeline i { height: 2px; background: #3f6665; }
.retention-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin-top: 20px; background: var(--line); }
.retention-grid div { display: grid; gap: 5px; padding: 16px; background: var(--panel-2); }
.retention-grid strong { color: white; font-size: 1.35rem; }
.retention-grid span { color: var(--muted); font-size: .68rem; }
.journey-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin-top: 18px; background: var(--line); }
.journey-summary div { min-width: 0; display: grid; gap: 7px; padding: 16px; background: var(--panel-2); }
.journey-summary small { color: var(--muted); font-size: .67rem; line-height: 1.35; }
.journey-summary strong { color: white; font-size: 1rem; overflow-wrap: anywhere; }
.readiness-list { display: grid; gap: 8px; margin-top: 18px; }
.readiness-list span { padding: 10px 12px; border-left: 3px solid var(--coral); color: #e4b4b8; background: #382527; font-size: .71rem; }

dialog { width: min(700px, calc(100% - 28px)); max-height: calc(100dvh - 24px); overflow: auto; padding: 0; border: 1px solid var(--line); border-radius: 7px; color: var(--text); background: var(--panel); box-shadow: 0 25px 75px #00000080; }
dialog::backdrop { background: #000000b5; }
#report-form, #outcome-form { padding: 24px; }
#report-form header, #outcome-form header { display: flex; justify-content: space-between; gap: 18px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
#report-form header p, #outcome-form header p { margin: 0; color: var(--teal); font-size: .67rem; font-weight: 500; text-transform: uppercase; }
#report-form h2, #outcome-form h2 { margin: 4px 0 0; color: white; font-size: 1.35rem; }
.icon-button { width: 35px; height: 35px; padding: 0; border: 0; color: var(--muted); background: transparent; font-size: 1.5rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; margin-top: 18px; }
#report-form label, #outcome-form label { display: grid; gap: 6px; margin-bottom: 14px; color: #d7d9dc; font-size: .72rem; font-weight: 500; }
#report-form input, #report-form select, #report-form textarea, #outcome-form input, #outcome-form select, #outcome-form textarea { width: 100%; padding: 10px; border: 1px solid #55575a; border-radius: 4px; color: var(--text); background: var(--field); color-scheme: dark; }
#report-form textarea, #outcome-form textarea { resize: vertical; }
.privacy-note { margin: 0; padding: 10px; color: var(--muted); background: #202122; font-size: .7rem; }
#report-message, #outcome-message { min-height: 18px; color: var(--green); font-size: .73rem; }
#report-form footer, #outcome-form footer { display: flex; justify-content: end; gap: 8px; }

@media (max-width: 1120px) {
  .sidebar { inset: 127px auto 0 0; }
  main { min-height: calc(100vh - 127px); }
  .masthead { min-height: 127px; grid-template-columns: 300px minmax(0, 1fr); grid-template-areas: "brand actions" "brand period"; gap: 4px 20px; }
  .source-toast { top: 141px; }
  .home-layout { grid-template-columns: 1fr; }
  .home-side { grid-template-columns: 1fr 1fr; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .roi-kpis.four, .conversion-row.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .journey-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .cloudflare-kpis { grid-template-columns: 1fr 1fr; }
  .cloudflare-kpis > div:nth-child(2) { border-right: 0; }
  .cloudflare-kpis > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .cloudflare-dashboard { grid-template-columns: 1fr; }
  .cloudflare-dashboard .traffic-over-time { grid-column: auto; }
  .analytics-toolbar { align-items: stretch; flex-direction: column; gap: 12px; }
  .analytics-periods { display: grid; grid-template-columns: repeat(4, 1fr); }
  .analytics-period { padding: 0 6px; }
  .attention-summary { grid-template-columns: 1fr; gap: 18px; padding: 18px; }
  .attention-summary dl { grid-template-columns: 1fr 1fr; }
  .attention-summary dl div { padding: 8px 12px; }
  .sidebar { position: static; width: auto; max-width: 100%; padding-bottom: 12px; border-right: 0; border-bottom: 0; }
  .product { min-height: 60px; }
  .mast-brand { width: min(300px, 100%); min-height: 82px; }
  .masthead { min-height: 0; grid-template-columns: minmax(0, 1fr); grid-template-areas: "brand" "period" "actions"; gap: 10px; padding: 8px 18px 16px; }
  .mast-actions, .period-fields { width: 100%; flex-wrap: wrap; }
  .masthead > .period-fields { justify-self: stretch; }
  .org-picker { width: auto; flex: 1 1 220px; }
  .period-fields .field { flex: 1 1 136px; }
  #apply { flex: 0 1 auto; }
  .source-toast { top: auto; right: 18px; bottom: 18px; }
  .org-identity { max-width: 340px; }
  .sidebar nav { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .sidebar nav > small { display: none; }
  .sidebar nav button { overflow-wrap: anywhere; }
  .privacy-state { display: none; }
  main { max-width: 100%; margin-left: 0; padding: 22px 22px 44px; }
}

@media (max-width: 580px) {
  .sidebar nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  main { padding: 20px 14px 36px; }
  .masthead { grid-template-columns: 1fr; grid-template-areas: "brand" "period" "actions"; align-items: start; gap: 8px; padding: 8px 14px 14px; }
  .mast-brand { min-height: 82px; }
  .period-fields { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .mast-actions { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) 54px; grid-template-areas: "org logout" "request request"; }
  .mast-actions .org-picker { grid-area: org; width: 100%; }
  .mast-actions #logout { grid-area: logout; width: 54px; }
  .mast-actions #request-report { grid-area: request; }
  .mast-actions { justify-self: stretch; }
  .mast-actions .primary { width: 100%; }
  #request-report { width: 100%; flex: 1 0 100%; }
  .period-fields .field { width: 100%; }
  .field input, .field select { min-width: 0; }
  .period-fields #apply { grid-column: 1 / -1; min-height: 44px; }
  .source-toast { top: auto; right: 14px; bottom: 14px; width: calc(100vw - 28px); }
  .metric-grid, .home-side, .two-column { grid-template-columns: 1fr; }
  .welcome-row, .reports-intro, .outcomes-intro { align-items: start; flex-direction: column; }
  .reports-actions { width: 100%; }
  .outcome-actions { width: 100%; justify-content: start; }
  .journey { grid-template-columns: 1fr 1fr; }
  .journey i { display: none; }
  .rate-row { flex-direction: column; gap: 7px; }
  .code-performance, .roi-kpis, .roi-kpis.four { grid-template-columns: 1fr 1fr; }
  #rcc-detail .rcc-detail-summary { width: 100%; grid-template-columns: minmax(80px, 100px) minmax(0, 1fr); }
  #rcc-detail .rcc-detail-summary > div:nth-child(2) strong { width: auto; }
  #analytics .analytics-kpis { grid-template-columns: 1fr 1fr; }
  .conversion-row, .conversion-row.four, .yield-bar { grid-template-columns: 1fr; }
  .pipeline { grid-template-columns: 1fr 1fr; }
  .pipeline i { display: none; }
  .retention-grid, .journey-summary { grid-template-columns: 1fr 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .panel { padding: 15px; }
  .panel-heading { flex-direction: column; }
  .link-button { white-space: normal; text-align: left; }
  .primary, .secondary { min-height: 44px; }
  #report-form, #outcome-form { padding: 17px; }
  #report-form footer, #outcome-form footer { display: grid; grid-template-columns: 1fr 1fr; }
  .health-summary { flex-wrap: wrap; gap: 18px 28px; }
  .view-intro, .view-intro > div, .view-intro p { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
}

@media (max-width: 380px) {
  .sidebar { padding-inline: 8px; }
  .sidebar nav button { padding-inline: 10px; font-size: 14px; }
  main { padding-inline: 10px; }
  .masthead { padding-inline: 10px; }
  .mast-brand { gap: 12px; }
  #product-logo { width: 112px; flex-basis: 112px; }
  .impact-gauge { width: 96px; flex-basis: 96px; }
  .metric-grid, .code-performance, .roi-kpis, .roi-kpis.four, #analytics .analytics-kpis, .retention-grid, .journey-summary { grid-template-columns: 1fr; }
  .reports-actions > .primary { flex: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .signin-success, .signin-success-art, .signin-success-art::after { animation: none !important; transition-duration: 1ms; }
  .signin-success.visible .signin-success-art { opacity: 1; transform: none; }
}
body.auth-pending > .masthead,
body.auth-pending > .sidebar,
body.auth-pending > main,
body.authenticated > .auth-gate { display: none; }

.auth-gate { min-height: 100vh; display: block; padding: 32px 20px 64px; background: #fff; color: #082f4f; text-align: center; }
.auth-brand { padding: 0; }
.auth-brand img { display: block; width: min(230px, 62vw); height: auto; margin: 0 auto; }
.auth-welcome { max-width: 620px; margin: 22px auto 0; }
.auth-welcome .eyebrow { display: none; }
.auth-welcome h1 { margin: 0 0 16px; font-family: Georgia, serif; font-size: 40px; font-weight: 400; line-height: 1.08; letter-spacing: 0; color: #082f4f; }
.auth-welcome p { margin: 0 auto 4px; color: #294c68; font-size: 16px; line-height: 1.55; }
.auth-welcome p + p { margin-top: 0; }
.auth-welcome a { display: inline-block; margin-top: 14px; color: #087f88; }
.auth-terms a { color: #087f88; }
.auth-panel { width: 100%; max-width: 420px; min-width: 0; margin: 42px auto 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; text-align: left; }
.auth-visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.auth-providers { min-width: 0; display: flex; justify-content: center; gap: 24px; }
.provider-login { width: 60px; min-width: 60px; height: 60px; display: grid; place-items: center; border: 0; border-radius: 50%; background: #f3f7f8; color: #087f88; transition: box-shadow .15s, transform .15s; }
.provider-login:hover, .provider-login:focus-visible { border-color: #168294; box-shadow: 0 0 0 3px #16829422; transform: translateY(-1px); }
.provider-login svg { width: 25px; height: 25px; }
.auth-divider { display: flex; align-items: center; gap: 14px; margin: 28px 0 16px; color: #526d7d; font-size: 14px; }
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: #d8e4ea; }
.auth-panel label { display: grid; gap: 8px; margin-top: 16px; color: #17384f; font-size: 13px; font-weight: 600; }
.auth-panel input { width: 100%; min-width: 0; min-height: 54px; padding: 0 16px; border: 1px solid #cbd9df; border-radius: 12px; background: #f4f8fa; color: #082f4f; font: inherit; }
.auth-panel input:focus { outline: 3px solid #16829422; border-color: #168294; }
.auth-panel .primary { width: 100%; min-height: 50px; margin-top: 16px; border-radius: 999px; background: #082f4f; }
#auth-message { min-height: 22px; margin: 14px 0 0; color: #435f70; font-size: 13px; }
.auth-terms { display: block; margin-top: 30px; color: #6c818d; font-size: 12px; line-height: 1.55; text-align: center; }
.access-denied .secondary { width: 100%; min-height: 44px; margin-top: 10px; }
#access-request-message { min-height: 22px; margin: 14px 0 0; color: #b9c0c3; font-size: 13px; }

@media (max-width: 620px) {
  .auth-gate { padding: 24px 18px 40px; }
  .auth-brand img { width: 190px; }
  .auth-welcome { margin-top: 18px; }
  .auth-welcome h1 { margin-bottom: 12px; font-size: 34px; }
  .auth-welcome p { font-size: 15px; line-height: 1.5; }
  .auth-panel { margin-top: 34px; }
}
