@font-face {
  font-family: "F1 Display";
  src: url("../fonts/f1-regular.ttf") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "F1 Display";
  src: url("../fonts/f1-bold.ttf") format("truetype");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "F1 Wide";
  src: url("../fonts/f1-wide.ttf") format("truetype");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root { --red: #e10600; --white: #fff; --muted: #a7a8ac; --line: rgba(255,255,255,.15); --yellow: #f4c430; }
* { box-sizing: border-box; }
html, body { min-width: 320px; min-height: 100%; }
body { margin: 0; overflow-x: hidden; color: var(--white); background: #080808; font-family: "F1 Display", "PingFang SC", "Microsoft YaHei", sans-serif; letter-spacing: 0; -webkit-font-smoothing: antialiased; }
button, a { color: inherit; font: inherit; letter-spacing: 0; }
a { text-decoration: none; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 4px; }

.redirect-background, .redirect-overlay { position: fixed; inset: 0; width: 100%; height: 100%; }
.redirect-background { object-fit: cover; object-position: center; }
.redirect-overlay { background: rgba(0,0,0,.76); box-shadow: inset 0 0 220px rgba(0,0,0,.76); }
.redirect-header { position: relative; z-index: 2; height: 72px; display: flex; align-items: center; width: min(calc(100% - 48px), 1120px); margin-inline: auto; border-bottom: 1px solid var(--line); }
.redirect-brand { display: inline-flex; align-items: center; gap: 11px; font-family: "F1 Wide", sans-serif; font-size: 19px; font-weight: 700; }
.redirect-brand img { width: 42px; height: 42px; border-radius: 7px; }

.redirect-main { position: relative; z-index: 2; min-height: calc(100svh - 72px); display: grid; place-items: center; padding: 42px 24px 64px; }
.redirect-panel { width: min(100%, 460px); padding: 30px; border: 1px solid var(--line); border-top: 4px solid var(--red); border-radius: 8px; background: rgba(12,13,15,.96); box-shadow: 0 28px 80px rgba(0,0,0,.58); text-align: center; }
.redirect-app { display: flex; align-items: center; gap: 14px; padding-bottom: 24px; border-bottom: 1px solid var(--line); text-align: left; }
.redirect-app > img { width: 64px; height: 64px; border-radius: 11px; }
.redirect-app div { display: flex; flex-direction: column; gap: 6px; }
.redirect-app span, .redirect-kicker { color: var(--red); font-family: "F1 Wide", sans-serif; font-size: 9px; font-weight: 700; }
.redirect-app strong { font-family: "F1 Wide", sans-serif; font-size: 21px; }
.redirect-state-icon { width: 68px; height: 68px; display: grid; place-items: center; margin: 32px auto 22px; border: 1px solid rgba(225,6,0,.5); border-radius: 50%; color: #ff4b46; background: rgba(225,6,0,.09); }
.redirect-state-icon svg { width: 30px; height: 30px; }
.redirect-kicker { margin: 0; }
.redirect-panel h1 { margin: 12px 0 0; font-size: 28px; line-height: 1.25; }
.redirect-message { max-width: 350px; margin: 14px auto 0; color: var(--muted); font-size: 14px; line-height: 1.75; }
.redirect-primary { width: 100%; min-height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; margin-top: 28px; padding: 0 20px; border: 0; border-radius: 4px; color: #fff; background: var(--red); font-weight: 700; cursor: pointer; }
.redirect-primary:hover { background: #ff1e16; }
.redirect-primary svg { width: 18px; height: 18px; }
.redirect-secondary { display: inline-block; margin-top: 20px; color: #c8c9cc; font-size: 13px; }
.redirect-footnote { display: flex; align-items: flex-start; justify-content: center; gap: 7px; margin: 28px 0 0; padding-top: 20px; border-top: 1px solid var(--line); color: #777980; font-size: 10px; line-height: 1.6; }
.redirect-footnote svg { width: 15px; height: 15px; flex: none; }

.wechat-tip { position: fixed; z-index: 10; top: calc(12px + env(safe-area-inset-top)); right: 14px; display: grid; grid-template-columns: 26px auto; column-gap: 8px; padding: 12px 14px; border: 1px solid rgba(244,196,48,.5); border-radius: 6px; color: #fff3b0; background: rgba(8,8,8,.96); box-shadow: 0 12px 36px rgba(0,0,0,.4); }
.wechat-tip[hidden] { display: none; }
.wechat-tip svg { grid-row: 1 / 3; width: 24px; height: 24px; }
.wechat-tip strong { font-size: 13px; }
.wechat-tip span { margin-top: 3px; color: #d6c982; font-size: 11px; }
.is-wechat .redirect-header { padding-top: 72px; height: 136px; }
.is-wechat .redirect-main { min-height: calc(100svh - 136px); }

@media (max-width: 520px) {
  .redirect-header { width: calc(100% - 32px); height: 64px; }
  .redirect-brand { font-size: 17px; }
  .redirect-brand img { width: 38px; height: 38px; }
  .redirect-main { min-height: calc(100svh - 64px); align-items: center; padding: 24px 16px calc(30px + env(safe-area-inset-bottom)); }
  .redirect-panel { padding: 24px 20px; }
  .redirect-panel h1 { font-size: 25px; }
  .is-wechat .redirect-header { height: 126px; padding-top: 62px; }
  .is-wechat .redirect-main { min-height: calc(100svh - 126px); }
}

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