/* USPI WORK & DOCUMENTS — legal pages (privacy, cookies, terms)
   Standalone stylesheet: does not depend on main.css. */

:root {
  --navy: #0b1c45;
  --ink: #1d2b4f;
  --muted: #4b5b7c;
  --blue: #0b63e5;
  --blue-deep: #0a3f9e;
  --bg: #f3f8ff;
  --line: #dde8f7;
  --tint: #eaf2ff;
  --card: #ffffff;
  --ok: #0f7a44;
  --ok-bg: #e7f6ee;
  --err: #b42318;
  --err-bg: #fdecea;
  --radius: 14px;
  --shadow: 0 14px 34px -16px rgba(17, 62, 150, .32);
  --shadow-sm: 0 4px 14px -6px rgba(17, 62, 150, .18);
  --grad: linear-gradient(135deg, #2a9bff 0%, #0b63e5 55%, #0a4fc4 100%);
  --col: 860px;
  --gutter: 16px;
  --header-h: 72px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Roboto", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

@media (min-width: 768px) {
  body { font-size: 17px; }
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--blue);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { color: var(--blue-deep); text-decoration-thickness: 2px; }

a[href^="mailto:"],
a[href^="tel:"] { white-space: nowrap; }

:focus { outline: none; }
:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  border-radius: 6px;
}

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--navy);
  color: #fff;
  border-radius: 10px;
  font-weight: 500;
  text-decoration: none;
}
.skip-link:focus { top: 12px; color: #fff; }

.wrap {
  width: 100%;
  max-width: calc(var(--col) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- Header ---------- */
.lh {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 8px 30px -18px rgba(17, 62, 150, .35);
  border-bottom: 1px solid var(--line);
}
@supports ((-webkit-backdrop-filter: blur(8px)) or (backdrop-filter: blur(8px))) {
  .lh {
    background: rgba(255, 255, 255, .82);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
  }
}
.lh__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: var(--header-h);
}
.lh__logo { display: inline-flex; flex-shrink: 1; min-width: 0; }
.lh__logo img { width: 190px; max-width: 100%; height: auto; }
.lh__back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  padding: 9px 14px;
  border-radius: 999px;
  background: var(--tint);
  color: var(--blue);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: none;
  box-shadow: inset 0 0 0 1px rgba(11, 99, 229, .18);
  transition: background-color .2s, box-shadow .2s;
}
.lh__back:hover {
  background: #dceaff;
  box-shadow: inset 0 0 0 1px rgba(11, 99, 229, .4);
  color: var(--blue-deep);
}
@media (max-width: 420px) {
  :root { --header-h: 64px; }
  .lh__logo img { width: 150px; }
  .lh__back { padding: 8px 12px; font-size: 14px; }
}
@media (max-width: 360px) {
  .lh__inner { gap: 8px; }
  .lh__back { padding: 7px 10px; font-size: 13px; }
}

/* ---------- Page intro ---------- */
.intro { padding: 36px 0 8px; }
@media (min-width: 768px) {
  .intro { padding: 56px 0 12px; }
}
.eyebrow {
  margin: 0 0 10px;
  color: var(--blue);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
h1, h2, h3 {
  color: var(--navy);
  line-height: 1.22;
  margin: 0;
}
h1 {
  font-size: clamp(28px, 6.4vw, 42px);
  font-weight: 900;
  letter-spacing: -.01em;
}
.intro__lead {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 1.05em;
}
.updated {
  display: inline-block;
  margin: 16px 0 0;
  padding: 6px 12px;
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 14px;
  box-shadow: var(--shadow-sm);
}

/* ---------- Cards & sections ---------- */
.content { padding: 20px 0 56px; }
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 18px;
  margin: 0 0 18px;
}
@media (min-width: 600px) {
  .card { padding: 30px 32px; margin-bottom: 22px; }
}
.card > :first-child { margin-top: 0; }
.card > :last-child { margin-bottom: 0; }

.card h2 {
  font-size: clamp(21px, 4.6vw, 26px);
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.card h2 .num {
  flex-shrink: 0;
  display: inline-grid;
  place-items: center;
  min-width: 30px;
  height: 30px;
  padding: 0 6px;
  border-radius: 9px;
  background: var(--grad);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  transform: translateY(-2px);
}
.card h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 22px 0 8px;
}
p { margin: 0 0 12px; }
ul, ol { margin: 0 0 14px; padding-left: 22px; }
li { margin: 0 0 6px; }
li::marker { color: var(--blue); }
b, strong { font-weight: 700; color: var(--navy); }

/* ---------- Table of contents ---------- */
.toc h2 { font-size: 19px; margin-bottom: 10px; }
.toc ol {
  margin: 0;
  padding-left: 24px;
  columns: 1;
}
@media (min-width: 700px) {
  .toc ol { columns: 2; column-gap: 40px; }
}
.toc li { break-inside: avoid; margin-bottom: 6px; }
.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; }

/* ---------- Requisites / definition lists ---------- */
.req {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px 18px;
  margin: 8px 0 14px;
  padding: 16px 18px;
  border-radius: 12px;
  background: var(--tint);
}
.req dt { color: var(--muted); font-size: .92em; margin-top: 8px; }
.req dt:first-child { margin-top: 0; }
.req dd { margin: 0; color: var(--navy); font-weight: 500; }
@media (min-width: 600px) {
  .req { grid-template-columns: minmax(150px, max-content) 1fr; padding: 18px 22px; }
  .req dt, .req dt:first-child { margin-top: 0; }
  .req dd { margin-bottom: 6px; }
}

/* ---------- Callouts ---------- */
.note {
  margin: 14px 0;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--tint);
  border-left: 4px solid var(--blue);
}
.note > :last-child { margin-bottom: 0; }

/* ---------- Tables ---------- */
.table-wrap {
  margin: 12px 0 16px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 12px;
  border: 1px solid var(--line);
}
.table-wrap:focus-visible { outline-offset: 2px; }
table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.5;
}
th, td {
  padding: 11px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}
thead th {
  background: #eef4fd;
  color: var(--navy);
  font-weight: 700;
  white-space: nowrap;
}
tbody tr:last-child td { border-bottom: 0; }
table.table--compact { min-width: 0; }
table.table--compact td:first-child { width: 42%; color: var(--navy); font-weight: 500; }
@media (max-width: 420px) {
  table.table--compact { font-size: 14px; }
  table.table--compact th, table.table--compact td { padding: 10px 10px; }
}
tbody tr:nth-child(even) td { background: #fafcff; }
td code, p code, li code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .9em;
  padding: 1px 6px;
  border-radius: 6px;
  background: #eef4fd;
  color: var(--navy);
  white-space: nowrap;
}
.tag {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}
.tag--need { background: var(--ok-bg); color: var(--ok); }
.tag--mkt { background: #fff4e0; color: #8a4b00; }
.table-hint { margin: -8px 0 12px; color: var(--muted); font-size: 14px; }
@media (min-width: 700px) {
  .table-hint { display: none; }
}

/* ---------- Steps (terms) ---------- */
.steps {
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: 12px 0 16px;
  display: grid;
  gap: 12px;
}
@media (min-width: 700px) {
  .steps { grid-template-columns: 1fr 1fr; }
}
.steps li {
  counter-increment: step;
  position: relative;
  margin: 0;
  padding: 16px 16px 16px 60px;
  border-radius: 12px;
  background: var(--tint);
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 16px;
  top: 16px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--grad);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
}
.steps b { display: block; margin-bottom: 2px; }

/* ---------- Links list ---------- */
.doc-links { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 10px; }
.doc-links li { margin: 0; }
.doc-links a {
  display: block;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--tint);
  font-weight: 500;
  text-decoration: none;
  box-shadow: inset 0 0 0 1px rgba(11, 99, 229, .14);
  transition: box-shadow .2s, background-color .2s;
}
.doc-links a:hover { background: #dceaff; box-shadow: inset 0 0 0 1px rgba(11, 99, 229, .4); }
.doc-links small { display: block; color: var(--muted); font-weight: 400; font-size: 14px; }
.doc-links + p { margin-top: 16px; }

/* ---------- Button + status (cookies) ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border: 0;
  border-radius: 12px;
  background: var(--grad);
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 10px 24px -10px rgba(11, 99, 229, .8), inset 0 1px 0 rgba(255, 255, 255, .35);
  transition: transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -12px rgba(11, 99, 229, .9), inset 0 1px 0 rgba(255, 255, 255, .4); }
.btn:active { transform: translateY(0); }
@media (max-width: 480px) {
  .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .btn:hover { transition: none; transform: none; }
}
.status {
  margin: 14px 0 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--ok-bg);
  color: var(--ok);
  font-weight: 500;
}
.status.is-error { background: var(--err-bg); color: var(--err); }
.status[hidden] { display: none; }
.after-action { margin-top: 18px; }

/* ---------- Footer ---------- */
.lf {
  background: var(--navy);
  color: #c9d6f0;
  padding: 32px 0 28px;
  font-size: 15px;
  line-height: 1.6;
}
.lf a { color: #fff; }
.lf a:hover { color: #cfe3ff; }
.lf :focus-visible { outline-color: #7cc0ff; }
.lf__nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 0 0 20px;
  padding: 0 0 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .14);
}
.lf__nav li { margin: 0; }
.lf__nav a { font-weight: 500; text-decoration: none; }
.lf__nav a:hover { text-decoration: underline; }
.lf__nav a[aria-current="page"] { color: #8fc6ff; text-decoration: underline; }
.lf p { margin: 0 0 6px; }
.lf b { color: #fff; }
.nw { white-space: nowrap; }
.lf__copy { margin-top: 14px !important; color: #8fa3cc; font-size: 14px; }

/* ---------- Print ---------- */
@media print {
  .lh, .skip-link, .btn, .status, .lf__nav { display: none !important; }
  body { background: #fff; font-size: 12pt; }
  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid-page; }
  .lf { background: #fff; color: #000; }
  .lf a, .lf b { color: #000; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 10pt; color: #555; }
}
