:root {
  --tt-blue: #0b67b2;
  --tt-blue-dark: #084b82;
  --tt-green: #198754;
  --tt-ink: #173247;
  --tt-muted: #5c7080;
  --tt-bg: #f3f7fa;
  --tt-card: #ffffff;
  --tt-border: #d7e3ec;
  --tt-soft-blue: #edf7ff;
  --tt-soft-green: #eef9f1;
  --tt-warning: #fff8df;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--tt-ink);
  background: var(--tt-bg);
  line-height: 1.55;
}
a { color: var(--tt-blue); }
a:hover { color: var(--tt-blue-dark); }
.help-shell { width: min(1120px, calc(100% - 28px)); margin: 0 auto; }
.help-topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255,255,255,.97);
  border-bottom: 1px solid var(--tt-border);
  box-shadow: 0 2px 8px rgba(12,45,68,.06);
}
.help-topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; min-height: 66px;
}
.help-brand { color: var(--tt-ink); text-decoration: none; font-weight: 800; font-size: 1.14rem; }
.help-brand span { color: var(--tt-blue); }
.help-top-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.help-button, button.help-button {
  display: inline-block; border: 1px solid var(--tt-blue); border-radius: 9px;
  background: var(--tt-blue); color: #fff; padding: 9px 13px; text-decoration: none;
  font-weight: 700; cursor: pointer; font-size: .95rem;
}
.help-button:hover { background: var(--tt-blue-dark); color: #fff; }
.help-button.secondary { background: #fff; color: var(--tt-blue); }
.help-main { padding: 28px 0 48px; }
.help-hero {
  background: linear-gradient(135deg, #eef8ff 0%, #fff 70%);
  border: 1px solid #bfdff3; border-top: 5px solid var(--tt-blue);
  border-radius: 16px; padding: clamp(22px, 5vw, 38px); margin-bottom: 22px;
  box-shadow: 0 10px 28px rgba(14,64,94,.08);
}
.help-eyebrow { color: var(--tt-blue); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; font-size: .78rem; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); line-height: 1.08; margin: 7px 0 10px; }
h2 { font-size: 1.4rem; line-height: 1.2; margin-top: 28px; }
h3 { font-size: 1.1rem; }
.help-lede { color: var(--tt-muted); font-size: 1.08rem; max-width: 760px; }
.help-search-wrap { margin-top: 20px; max-width: 760px; }
.help-search {
  width: 100%; border: 2px solid #a9cfe8; border-radius: 12px; padding: 13px 15px;
  font-size: 1.05rem; background: #fff;
}
.help-search:focus { outline: 3px solid rgba(11,103,178,.18); border-color: var(--tt-blue); }
.help-search-status { margin: 8px 0 0; color: var(--tt-muted); font-size: .92rem; min-height: 1.4em; }
.help-category-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 24px; }
.help-filter {
  border: 1px solid var(--tt-border); background: #fff; color: var(--tt-ink);
  padding: 8px 12px; border-radius: 999px; cursor: pointer; font-weight: 700;
}
.help-filter[aria-pressed="true"] { background: var(--tt-blue); color: #fff; border-color: var(--tt-blue); }
.help-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.help-card {
  display: flex; flex-direction: column; background: var(--tt-card); border: 1px solid var(--tt-border);
  border-radius: 13px; padding: 18px; min-height: 190px; box-shadow: 0 4px 14px rgba(15,52,75,.05);
}
.help-card[hidden] { display: none; }
.help-card-category { color: var(--tt-blue); font-size: .76rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.help-card h2 { margin: 8px 0; font-size: 1.2rem; }
.help-card p { margin: 0 0 15px; color: var(--tt-muted); }
.help-card-link { margin-top: auto; font-weight: 800; text-decoration: none; }
.help-empty { background: #fff; border: 1px dashed #9db7c8; border-radius: 12px; padding: 18px; margin-top: 16px; }
.help-section-title { margin: 30px 0 12px; }
.help-quick-row { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; margin-bottom: 22px; }
.help-quick { background: var(--tt-soft-green); border: 1px solid #cce8d4; border-radius: 12px; padding: 14px; }
.help-quick a { font-weight: 800; }
.help-footer { background: #fff; border-top: 1px solid var(--tt-border); padding: 25px 0; color: var(--tt-muted); font-size: .9rem; }
.help-footer-inner { display: flex; flex-wrap: wrap; gap: 10px 20px; justify-content: space-between; }
.help-breadcrumbs { font-size: .92rem; margin-bottom: 16px; color: var(--tt-muted); }
.help-article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 24px; align-items: start; }
.help-article {
  background: #fff; border: 1px solid var(--tt-border); border-radius: 15px; padding: clamp(20px, 4vw, 34px);
  box-shadow: 0 8px 24px rgba(15,52,75,.06);
}
.help-article h1 { font-size: clamp(1.8rem, 4vw, 2.65rem); }
.help-article p, .help-article li { font-size: 1rem; }
.help-article li + li { margin-top: 7px; }
.help-meta { color: var(--tt-muted); font-size: .9rem; margin-bottom: 20px; }
.help-callout, .help-example {
  border-left: 5px solid var(--tt-blue); background: var(--tt-soft-blue); padding: 14px 16px; border-radius: 8px; margin: 18px 0;
}
.help-example { border-left-color: var(--tt-green); background: var(--tt-soft-green); }
.help-side { position: sticky; top: 88px; }
.help-side-card { background: #fff; border: 1px solid var(--tt-border); border-radius: 12px; padding: 15px; margin-bottom: 13px; }
.help-side-card h2 { font-size: 1rem; margin: 0 0 9px; }
.help-side-card ul { margin: 0; padding-left: 19px; }
.help-media-placeholder {
  border: 2px dashed #8aaec4; background: #f8fbfd; border-radius: 13px; padding: 22px; margin: 24px 0;
}
.help-media-label { color: var(--tt-blue); font-weight: 800; text-transform: uppercase; letter-spacing: .06em; font-size: .78rem; }
.help-media-placeholder code { display: inline-block; background: #e9f1f6; border-radius: 5px; padding: 2px 6px; overflow-wrap: anywhere; }
.help-related { border-top: 1px solid var(--tt-border); margin-top: 30px; padding-top: 20px; }
.help-related-list { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 9px; }
.help-related-list a { border: 1px solid var(--tt-border); border-radius: 9px; padding: 10px; text-decoration: none; font-weight: 700; }
.help-notice { background: var(--tt-warning); border: 1px solid #ead58e; border-radius: 10px; padding: 13px; margin-top: 24px; }
.help-print { width: 100%; }
@media (max-width: 900px) {
  .help-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .help-article-layout { grid-template-columns: 1fr; }
  .help-side { position: static; }
  .help-quick-row { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .help-shell { width: min(100% - 18px, 1120px); }
  .help-topbar-inner { align-items: flex-start; padding: 10px 0; }
  .help-top-actions { gap: 5px; }
  .help-button { padding: 8px 10px; font-size: .88rem; }
  .help-grid { grid-template-columns: 1fr; }
  .help-related-list { grid-template-columns: 1fr; }
  .help-hero { border-radius: 12px; }
}
@media print {
  .help-topbar, .help-side, .help-footer, .help-media-placeholder .help-media-instruction { display: none !important; }
  body { background: #fff; }
  .help-main { padding: 0; }
  .help-shell { width: 100%; }
  .help-article-layout { display: block; }
  .help-article { border: 0; box-shadow: none; padding: 0; }
}


/* Patch 304B: approved media replaces its placeholder automatically. */
.help-media-loaded { margin: 24px 0; }
.help-media-loaded img,
.help-media-loaded video {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 78vh;
  margin: 0 auto;
  border: 1px solid var(--tt-border);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(15,52,75,.08);
}
.help-media-loaded figcaption {
  margin-top: 9px;
  color: var(--tt-muted);
  font-size: .92rem;
  text-align: center;
}
.help-media-check-intro { margin-bottom: 18px; }
.help-media-check-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin: 16px 0;
}
.help-media-check-tools .help-search { flex: 1 1 300px; }
.help-media-check-summary { color: var(--tt-muted); font-weight: 700; }
.help-table-wrap {
  overflow-x: auto;
  background: #fff;
  border: 1px solid var(--tt-border);
  border-radius: 13px;
}
.help-media-table { width: 100%; border-collapse: collapse; min-width: 780px; }
.help-media-table th,
.help-media-table td { padding: 11px 12px; text-align: left; border-bottom: 1px solid var(--tt-border); vertical-align: top; }
.help-media-table th { background: var(--tt-soft-blue); font-size: .86rem; }
.help-media-table tr:last-child td { border-bottom: 0; }
.help-media-table tr[hidden] { display: none; }
.help-media-table code { overflow-wrap: anywhere; }
.help-media-status {
  display: inline-block;
  min-width: 72px;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: .82rem;
  font-weight: 800;
  text-align: center;
  background: #edf0f2;
  color: var(--tt-muted);
}
.help-media-status.found { background: #dff5e6; color: #176b38; }
.help-media-status.missing { background: #fff0d7; color: #8a4c00; }


/* Patch 304C: visible checklist runtime diagnostic. */
.help-runtime-status {
  margin: 12px 0;
  padding: 10px 12px;
  border: 1px solid var(--tt-border);
  border-radius: 10px;
  background: #fff7df;
  color: #755000;
  font-weight: 700;
}
.help-runtime-status.running { background: #eaf4ff; color: #165d91; }
.help-runtime-status.complete { background: #e5f7eb; color: #176b38; }
