:root {
  color-scheme: light;
  --white: #ffffff;
  --surface: #f5f8f9;
  --surface-blue: #eef8fb;
  --blue: #00a2ce;
  --blue-dark: #016f8e;
  --blue-deep: #074f64;
  --blue-soft: #d8f0f7;
  --ink: #273136;
  --muted: #56656b;
  --line: #d9e2e5;
  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  min-width: 320px;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font);
  line-height: 1.5;
}

button,
a {
  font: inherit;
}

button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(0, 162, 206, 0.35);
  outline-offset: 3px;
}

.page-shell {
  min-height: 100vh;
}

.site-header {
  position: relative;
  z-index: 2;
  display: flex;
  min-height: 88px;
  align-items: center;
  justify-content: space-between;
  padding: 16px 4vw;
  border-bottom: 1px solid var(--line);
  background: var(--white);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  display: block;
  width: 46px;
  height: 46px;
  border-radius: 11px;
  /* Matches the icon tile so its 2-unit inset blends into the rounded corners. */
  background: var(--blue-dark);
  box-shadow: 0 9px 20px rgba(1, 111, 142, 0.2);
}

.brand-copy {
  display: grid;
  line-height: 1.15;
}

.brand-copy strong {
  color: var(--blue-dark);
  font-size: 1rem;
}

.brand-copy small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.76rem;
}

.header-actions {
  display: flex;
  align-items: center;
}

.language-toggle {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #edf1f2;
}

.language-toggle button {
  min-width: 46px;
  min-height: 38px;
  padding: 6px 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 700;
}

.language-toggle button.is-active {
  background: var(--white);
  color: var(--blue-dark);
  box-shadow: 0 4px 12px rgba(34, 52, 58, 0.1);
}

.main-layout {
  display: grid;
  min-height: calc(100vh - 88px);
  grid-template-columns: minmax(430px, 0.92fr) minmax(510px, 1.08fr);
}

.exam-directory {
  padding: 58px clamp(30px, 5vw, 78px);
  background: var(--white);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--blue-dark);
  font-size: 0.79rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.eyebrow span {
  width: 30px;
  height: 2px;
  background: var(--blue);
}

.directory-heading h1 {
  max-width: 500px;
  margin-top: 14px;
  color: var(--blue-deep);
  font-size: clamp(2.25rem, 4vw, 3.8rem);
  font-weight: 650;
  letter-spacing: -0.045em;
  line-height: 1.02;
}

.directory-heading > p:last-child {
  margin-top: 17px;
  color: var(--muted);
}

.exam-list {
  display: grid;
  gap: 30px;
  margin-top: 36px;
  scroll-margin-top: 20px;
}

.exam-specialty {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--blue-dark);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.exam-specialty::before {
  width: 18px;
  height: 2px;
  background: var(--blue);
  content: "";
}

.exam-options {
  border-top: 1px solid var(--line);
}

.exam-option {
  display: grid;
  width: 100%;
  min-height: 72px;
  grid-template-columns: 36px 1fr auto;
  align-items: center;
  gap: 10px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition:
    padding 160ms ease,
    background 160ms ease;
}

.exam-number {
  color: #8aa0a8;
  font-size: 0.72rem;
  font-weight: 800;
}

.exam-name {
  color: var(--ink);
  font-size: 1rem;
  font-weight: 650;
}

.exam-arrow {
  color: var(--blue-dark);
  font-size: 1.2rem;
}

.exam-option:hover,
.exam-option.is-selected {
  padding-inline: 13px;
  background: var(--surface-blue);
}

.exam-option.is-selected .exam-name {
  color: var(--blue-dark);
}

.document-area {
  display: grid;
  place-items: center;
  align-content: center;
  padding: 58px clamp(34px, 6vw, 90px);
  background:
    linear-gradient(rgba(1, 111, 142, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(1, 111, 142, 0.055) 1px, transparent 1px), #eef5f7;
  background-size: 34px 34px;
}

.document-sheet {
  position: relative;
  display: grid;
  width: min(580px, 100%);
  min-height: 520px;
  place-items: center;
  padding: 55px;
  border: 1px solid #d4e4e8;
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 30px 70px rgba(23, 73, 86, 0.14);
}

.document-kicker {
  position: absolute;
  top: 22px;
  left: 24px;
  color: var(--blue-dark);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.document-empty,
.document-summary {
  display: grid;
  width: 100%;
  max-width: 410px;
  justify-items: center;
  margin-inline: auto;
  text-align: center;
}

.document-selected {
  width: 100%;
}

.document-sheet.is-reading {
  width: min(760px, 100%);
  min-height: auto;
  place-items: stretch;
  padding-bottom: 42px;
}

.paper-stack {
  position: relative;
  width: 105px;
  height: 128px;
  margin-bottom: 30px;
}

.paper-stack span,
.paper-stack strong {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 1px solid #bed7de;
  border-radius: 4px;
  background: var(--white);
  color: var(--blue-dark);
  font-size: 1.15rem;
  font-weight: 800;
}

.paper-stack span:first-child {
  transform: rotate(-9deg) translate(-9px, 3px);
}

.paper-stack span:nth-child(2) {
  transform: rotate(7deg) translate(8px, 2px);
}

.paper-stack strong {
  background: linear-gradient(145deg, var(--white), var(--surface-blue));
}

.document-empty h2,
.document-summary h2 {
  color: var(--blue-deep);
  font-size: 1.55rem;
  line-height: 1.2;
}

.document-empty p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.92rem;
}

.selection-check {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  margin-bottom: 18px;
  border-radius: 50%;
  background: var(--blue);
  color: var(--white);
  font-size: 1.2rem;
  font-weight: 800;
}

.selection-label {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.file-card {
  display: grid;
  width: 100%;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 13px;
  margin: 27px 0 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  text-align: left;
}

.file-card.is-pending {
  background: #fafbfb;
}

.file-type {
  display: grid;
  width: 46px;
  height: 52px;
  place-items: center;
  border-radius: 7px;
  background: var(--blue-soft);
  color: var(--blue-dark);
  font-size: 0.7rem;
  font-weight: 900;
}

.file-copy {
  display: grid;
  gap: 3px;
}

.file-copy strong {
  font-size: 0.9rem;
}

.file-copy small {
  color: var(--muted);
  font-size: 0.75rem;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #aab8bd;
}

.file-card.is-available .status-dot {
  background: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-soft);
}

.document-actions {
  display: flex;
  width: 100%;
  flex-wrap: wrap;
  gap: 10px;
}

.button {
  display: inline-flex;
  min-height: 50px;
  flex: 1 1 150px;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border: 2px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

.button:not(:disabled):hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--blue-dark);
  color: var(--white);
  box-shadow: 0 9px 19px rgba(1, 111, 142, 0.2);
}

.button-secondary {
  border-color: #b9dbe4;
  background: var(--white);
  color: var(--blue-dark);
}

.button:disabled {
  border-color: #dce3e5;
  background: #e9edef;
  color: #87969b;
  cursor: not-allowed;
  box-shadow: none;
}

.choose-another {
  margin-top: 20px;
  border: 0;
  background: transparent;
  color: var(--blue-dark);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 700;
}

.web-document {
  width: 100%;
  margin-top: 42px;
  padding-top: 38px;
  border-top: 1px solid var(--line);
  color: var(--ink);
  text-align: left;
}

.web-document > header > p:first-child {
  color: var(--blue-dark);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.web-document h2 {
  margin-top: 8px;
  color: var(--blue-deep);
  font-size: clamp(1.8rem, 4vw, 2.35rem);
  line-height: 1.12;
}

.web-summary {
  margin-top: 10px;
  color: var(--muted);
  font-size: 1rem;
}

.web-document section {
  margin-top: 32px;
}

.web-document h3 {
  margin-bottom: 12px;
  color: var(--blue-dark);
  font-size: 1.12rem;
}

.web-document section p + p {
  margin-top: 12px;
}

.web-document ul {
  display: grid;
  gap: 10px;
  padding-left: 24px;
}

.web-document li::marker {
  color: var(--blue);
}

.web-contact {
  margin-top: 34px;
  padding: 20px;
  border-left: 4px solid var(--blue);
  border-radius: 0 10px 10px 0;
  background: var(--surface-blue);
}

.web-contact h3 {
  margin-bottom: 6px;
}

.safety-note {
  max-width: 560px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 0.77rem;
  text-align: center;
}

@media (max-width: 900px) {
  .main-layout {
    grid-template-columns: 1fr;
  }

  .exam-directory {
    padding-bottom: 35px;
  }

  .document-area {
    padding-block: 45px;
  }
}

@media (max-width: 620px) {
  .site-header {
    min-height: 74px;
    padding-inline: 16px;
  }

  .brand-mark {
    width: 42px;
    height: 42px;
  }

  .brand-copy small {
    display: none;
  }

  .language-toggle button {
    min-width: 42px;
    min-height: 36px;
    padding-inline: 9px;
  }

  .exam-directory {
    padding: 43px 20px 30px;
  }

  .directory-heading h1 {
    font-size: 2.45rem;
  }

  .document-area {
    padding: 30px 16px;
    scroll-margin-top: 20px;
  }

  .document-sheet {
    min-height: 460px;
    padding: 55px 20px 28px;
  }

  .document-sheet.is-reading {
    padding-inline: 20px;
  }

  .web-document {
    margin-top: 34px;
    padding-top: 30px;
  }

  .document-actions {
    flex-direction: column;
  }

  .button {
    flex-basis: auto;
  }

  .safety-note {
    padding-inline: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
