:root {
  color-scheme: light;
  --help-bg: #ffffff;
  --help-surface: #ffffff;
  --help-surface-soft: #f5f5f5;
  --help-text: #111318;
  --help-muted: #6f737b;
  --help-faint: #92969d;
  --help-line: #e5e6e8;
  --help-line-strong: #d5d7db;
  --help-accent: #0f6fe8;
  --help-overlay: rgba(5, 7, 10, .68);
  --help-shadow: 0 18px 45px rgba(17, 19, 24, .09);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --help-bg: #0b0c0f;
    --help-surface: #121419;
    --help-surface-soft: #191c22;
    --help-text: #f4f5f7;
    --help-muted: #a5a9b1;
    --help-faint: #7f848d;
    --help-line: #282c34;
    --help-line-strong: #3a3f48;
    --help-accent: #5b9cff;
    --help-overlay: rgba(3, 4, 7, .72);
    --help-shadow: 0 22px 55px rgba(0, 0, 0, .34);
  }
}

html[data-theme="dark"] {
  color-scheme: dark;
  --help-bg: #0b0c0f;
  --help-surface: #121419;
  --help-surface-soft: #191c22;
  --help-text: #f4f5f7;
  --help-muted: #a5a9b1;
  --help-faint: #7f848d;
  --help-line: #282c34;
  --help-line-strong: #3a3f48;
  --help-accent: #5b9cff;
  --help-overlay: rgba(3, 4, 7, .72);
  --help-shadow: 0 22px 55px rgba(0, 0, 0, .34);
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; background: var(--help-bg); }
body.page-help,
body.page-help-video { margin: 0; min-width: 320px; min-height: 100vh; background: var(--help-bg); color: var(--help-text); }
body.page-help a,
body.page-help-video a { color: inherit; text-decoration: none; }
body.page-help button,
body.page-help input,
body.page-help-video button { font: inherit; }

.help-container { width: min(1440px, calc(100% - 48px)); margin: 0 auto; }
.help-nav { position: sticky; z-index: 40; top: 0; height: 82px; border-bottom: 1px solid rgba(255, 255, 255, .1); background: #050505; color: #fff; }
.help-nav .nav-inner { display: flex; width: min(1480px, calc(100% - 48px)); height: 100%; align-items: center; gap: 24px; margin: 0 auto; }
.help-nav .nav-logo { display: inline-flex; width: 126px; flex: 0 0 auto; align-items: center; }
.help-nav .nav-logo-script { display: block; width: 126px; height: auto; filter: invert(1); }
.help-nav .nav-links { display: flex; min-width: 0; align-items: center; gap: clamp(16px, 1.8vw, 30px); margin-left: auto; white-space: nowrap; }
.help-nav .nav-links a,
.help-nav .nav-auth-trigger { position: relative; border: 0; padding: 0; background: transparent; color: rgba(255, 255, 255, .8); font-size: 14px; font-weight: 600; cursor: pointer; transition: color .18s ease, opacity .18s ease; }
.help-nav .nav-links a::after,
.help-nav .nav-auth-trigger::after { position: absolute; right: 0; bottom: -8px; left: 0; height: 2px; border-radius: 999px; background: #fff; content: ""; transform: scaleX(0); transition: transform .18s ease; }
.help-nav .nav-links a:hover,
.help-nav .nav-links a:active,
.help-nav .nav-links a.is-active,
.help-nav .nav-auth-trigger:hover,
.help-nav .nav-auth-trigger:active { color: #fff; }
.help-nav .nav-links a:hover::after,
.help-nav .nav-links a.is-active::after,
.help-nav .nav-auth-trigger:hover::after { transform: scaleX(1); }
.help-nav .nav-links a:focus-visible,
.help-nav .nav-auth-trigger:focus-visible,
.help-nav .nav-home:focus-visible { outline: 2px solid #fff; outline-offset: 5px; }
.help-nav .nav-auth-trigger:disabled { color: rgba(255, 255, 255, .38); cursor: not-allowed; }
.help-nav .nav-auth-trigger:disabled::after { display: none; }
.help-nav .nav-home { display: inline-flex; min-height: 40px; flex: 0 0 auto; align-items: center; justify-content: center; border: 1px solid rgba(255, 255, 255, .34); border-radius: 999px; padding: 0 17px; color: #fff; font-size: 13px; font-weight: 650; transition: background .18s ease, border-color .18s ease, transform .18s ease; }
.help-nav .nav-home:hover { border-color: #fff; background: rgba(255, 255, 255, .12); transform: translateY(-1px); }
.help-nav .nav-home:active { background: rgba(255, 255, 255, .08); transform: translateY(0); }

.help-main { min-height: calc(100vh - 82px); padding: clamp(70px, 8vw, 124px) 0 92px; }
.help-heading { max-width: none; }
.help-heading h1 { margin: 0; color: var(--help-text); font-size: clamp(21.6px, calc(3.36vw - 12px), 48px); font-weight: 700; letter-spacing: -.055em; line-height: 1.04; }
.help-heading p { max-width: none; margin: 20px 0 0; color: var(--help-muted); font-size: clamp(16px, 1.6vw, 20px); line-height: 1.72; white-space: nowrap; }
.help-search-wrap { position: relative; width: min(544px, 100%); margin-top: 40px; }
.help-search-wrap svg { position: absolute; left: 17px; top: 50%; width: 18px; height: 18px; color: var(--help-faint); pointer-events: none; transform: translateY(-50%); }
.help-search { width: 100%; min-height: 49px; border: 1px solid var(--help-line); border-radius: 12px; padding: 0 17px 0 46px; background: var(--help-surface); color: var(--help-text); box-shadow: 0 1px 0 rgba(17, 19, 24, .02); font-size: 14px; outline: 0; transition: border-color .18s ease, box-shadow .18s ease, background .18s ease; }
.help-search::placeholder { color: var(--help-faint); }
.help-search:hover:not(:disabled) { border-color: var(--help-line-strong); background: var(--help-surface-soft); }
.help-search:focus { border-color: var(--help-line-strong); background: var(--help-surface); box-shadow: none; }
.help-search:disabled { background: var(--help-surface-soft); color: var(--help-faint); cursor: not-allowed; opacity: .68; }

.help-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 54px 0 34px; border-bottom: 1px solid var(--help-line); }
.help-filters { display: flex; align-items: center; gap: 30px; }
.help-filter { position: relative; min-height: 48px; border: 0; padding: 0 1px; background: transparent; color: var(--help-muted); font-size: 15px; font-weight: 600; cursor: pointer; transition: color .18s ease; }
.help-filter::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; border-radius: 999px 999px 0 0; background: var(--help-text); content: ""; opacity: 0; transform: scaleX(.6); transition: opacity .18s ease, transform .18s ease; }
.help-filter:hover { color: var(--help-text); }
.help-filter:active { color: var(--help-accent); }
.help-filter.is-active { color: var(--help-text); }
.help-filter.is-active::after { opacity: 1; transform: scaleX(1); }
.help-filter:focus-visible { outline: 3px solid color-mix(in srgb, var(--help-accent) 30%, transparent); outline-offset: 3px; border-radius: 6px; }
.help-filter:disabled { color: var(--help-faint); cursor: not-allowed; opacity: .45; }
.help-result-count { color: var(--help-faint); font-size: 13px; }

.help-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 54px 32px; }
.help-card { min-width: 0; }
.help-card[hidden] { display: none; }
.help-card-link { display: block; border-radius: 18px; }
.help-card-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border: 1px solid var(--help-line); border-radius: 18px; background: #07090d; box-shadow: 0 1px 0 rgba(17, 19, 24, .04); transition: border-color .22s ease, box-shadow .22s ease, transform .22s ease; }
.help-card-media img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.002); transition: transform .36s ease, filter .28s ease; }
.help-card-media::after { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, var(--help-overlay) 100%); content: ""; opacity: .62; transition: opacity .22s ease; }
.help-card-type { position: absolute; z-index: 2; left: 16px; top: 16px; display: inline-flex; min-height: 30px; align-items: center; gap: 7px; border: 1px solid rgba(255, 255, 255, .28); border-radius: 999px; padding: 0 11px; background: rgba(5, 7, 10, .66); color: #fff; backdrop-filter: blur(12px); font-size: 12px; font-weight: 700; }
.help-card-type svg { width: 14px; height: 14px; }
.help-card-play { position: absolute; z-index: 2; left: 50%; top: 50%; display: grid; width: 58px; height: 58px; place-items: center; border: 1px solid rgba(255, 255, 255, .52); border-radius: 50%; background: rgba(3, 5, 8, .58); color: #fff; backdrop-filter: blur(10px); box-shadow: 0 12px 30px rgba(0, 0, 0, .22); transform: translate(-50%, -50%); transition: background .2s ease, transform .2s ease; }
.help-card-play svg { width: 22px; height: 22px; margin-left: 3px; }
.help-card-copy { padding-top: 21px; }
.help-card-copy h2 { margin: 0; color: var(--help-text); font-size: clamp(18px, 1.7vw, 22px); font-weight: 650; letter-spacing: -.025em; line-height: 1.38; transition: color .18s ease; }
.help-card-copy p { display: -webkit-box; min-height: 48px; overflow: hidden; margin: 12px 0 0; color: var(--help-muted); font-size: 14px; line-height: 1.7; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.help-card-meta { display: flex; align-items: center; gap: 8px; margin-top: 20px; color: var(--help-faint); font-size: 12px; }
.help-card-meta span + span::before { margin-right: 8px; content: "·"; }
.help-card-link:hover .help-card-media { border-color: var(--help-line-strong); box-shadow: var(--help-shadow); transform: translateY(-4px); }
.help-card-link:hover .help-card-media img { transform: scale(1.035); }
.help-card-link:hover .help-card-media::after { opacity: .78; }
.help-card-link:hover .help-card-copy h2 { color: var(--help-accent); }
.help-card-link:hover .help-card-play { background: rgba(3, 5, 8, .82); transform: translate(-50%, -50%) scale(1.06); }
.help-card-link:active .help-card-media { box-shadow: none; transform: translateY(-1px) scale(.995); }
.help-card-link:focus-visible { outline: 3px solid color-mix(in srgb, var(--help-accent) 34%, transparent); outline-offset: 6px; }
.help-empty { display: grid; min-height: 260px; place-items: center; border: 1px dashed var(--help-line-strong); border-radius: 18px; color: var(--help-muted); text-align: center; }
.help-empty[hidden] { display: none; }

.help-footer { border-top: 1px solid var(--help-line); padding: 28px 0 36px; color: var(--help-faint); font-size: 12px; }
.help-footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 22px; }
.help-footer a:hover { color: var(--help-text); }
.help-footer a:focus-visible { outline: 2px solid var(--help-accent); outline-offset: 3px; }

.video-main { min-height: calc(100vh - 82px); padding: 64px 0 92px; }
.video-breadcrumb { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 32px; color: var(--help-muted); font-size: 14px; font-weight: 600; transition: color .18s ease; }
.video-breadcrumb svg { width: 17px; height: 17px; }
.video-breadcrumb:hover { color: var(--help-text); }
.video-breadcrumb:active { color: var(--help-accent); }
.video-breadcrumb:focus-visible { outline: 3px solid color-mix(in srgb, var(--help-accent) 30%, transparent); outline-offset: 5px; border-radius: 6px; }
.video-heading { max-width: 920px; margin-bottom: 34px; }
.video-kicker { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 13px; color: var(--help-accent); font-size: 13px; font-weight: 700; }
.video-heading h1 { margin: 0; color: var(--help-text); font-size: clamp(34px, 5vw, 62px); font-weight: 700; letter-spacing: -.055em; line-height: 1.08; }
.video-heading p { max-width: 760px; margin: 18px 0 0; color: var(--help-muted); font-size: 16px; line-height: 1.75; }
.video-shell { overflow: hidden; border: 1px solid var(--help-line); border-radius: 22px; background: #020306; box-shadow: var(--help-shadow); }
.video-shell video { display: block; width: 100%; max-height: min(74vh, 900px); aspect-ratio: 16 / 9; background: #020306; object-fit: contain; }
.video-shell video:focus-visible { outline: 3px solid var(--help-accent); outline-offset: -5px; }
.video-fallback { margin: 20px 0 0; color: var(--help-muted); font-size: 13px; }
.video-fallback a { color: var(--help-accent); font-weight: 650; }
.video-fallback a:hover { text-decoration: underline; }

@media (max-width: 1180px) {
  .help-nav .nav-links { gap: 17px; }
  .help-nav .nav-links a,
  .help-nav .nav-auth-trigger { font-size: 13px; }
  .help-nav .nav-home { display: none; }
  .help-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .help-container { width: min(100% - 34px, 720px); }
  .help-nav { height: 70px; }
  .help-nav .nav-inner { width: calc(100% - 34px); }
  .help-nav .nav-logo,
  .help-nav .nav-logo-script { width: 112px; }
  .help-nav .nav-links { display: none; }
  .help-nav .i18n-language-switcher { margin-left: auto; }
  .help-main { min-height: calc(100vh - 70px); padding: 58px 0 72px; }
  .help-heading p { white-space: normal; }
  .help-toolbar { margin-top: 42px; }
  .video-main { min-height: calc(100vh - 70px); padding: 42px 0 72px; }
}

@media (max-width: 620px) {
  .help-grid { grid-template-columns: 1fr; gap: 42px; }
  .help-toolbar { align-items: flex-start; flex-direction: column; gap: 0; }
  .help-filters { width: 100%; gap: 24px; overflow-x: auto; }
  .help-result-count { padding: 14px 0; }
  .help-card-copy p { min-height: 0; }
  .help-footer-inner { align-items: flex-start; flex-direction: column; }
  .video-shell { border-radius: 14px; }
}

@media (forced-colors: active) {
  .help-card-media,
  .help-search,
  .help-filter.is-active { border: 1px solid CanvasText; }
  .help-card-type,
  .help-card-play { border: 1px solid ButtonText; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
