* { box-sizing: border-box; }
[hidden] { display: none !important; }

:root {
  color-scheme: dark;
  font-family: "Segoe UI", "Microsoft YaHei", sans-serif;
  color: #f5f3f1;
  background: #0b0b0d;
  --gutter: clamp(22px, 6.1vw, 104px);
  --max-width: 1512px;
  --header-height: 76px;
  --rule: #ffffff1e;
  --muted: #b3b0ad;
}

body { margin: 0; min-height: 100vh; }
.scan-complete {
  display: grid;
  place-items: center;
  padding: 24px;
  background: radial-gradient(ellipse at 50% 25%, #242424, #0b0b0d 68%);
}
.scan-message {
  width: min(100%, 520px);
  padding: clamp(28px, 7vw, 48px);
  border: 1px solid var(--rule);
  border-radius: 24px;
  background: #ffffff08;
}
.scan-message h1 { margin: 28px 0 12px; font-size: clamp(24px, 6vw, 34px); line-height: 1.3; }
.scan-message p { margin: 0 0 28px; color: var(--muted); line-height: 1.7; }
.scan-message a { text-underline-offset: 4px; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button {
  cursor: pointer;
  color: #efeeec;
  border: 1px solid #ffffff24;
  border-radius: 8px;
  background: #1b1b1e;
  padding: 8px 13px;
  transition: background-color .18s, border-color .18s, color .18s;
}
button:hover { background: #28282b; }
button:disabled { cursor: wait; opacity: .66; }
a { color: #f5f3ef; }
:focus-visible { outline: 2px solid #f0cf9e; outline-offset: 4px; }

.top { position: relative; z-index: 1; background: #0b0b0e; border-bottom: 1px solid var(--rule); }
.top-inner {
  min-height: var(--header-height);
  max-width: var(--max-width);
  margin: auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}
.brand { display: flex; align-items: center; gap: 15px; white-space: nowrap; }
.brand img { display: block; width: 94px; height: auto; }
.brand span { color: #e4e1de; border-left: 1px solid #ffffff31; padding-left: 14px; font-size: 13px; font-weight: 600; }
.top nav { display: flex; grid-column: 2; grid-row: 1; align-items: center; gap: 8px; }
.top nav:not(:has([data-tab="usage"]:not([hidden]))) { display: none; }
.top nav button { background: transparent; border-color: transparent; color: var(--muted); white-space: nowrap; font-size: 13px; }
.top nav button[aria-current="page"] { background: #202023; color: #f4f1ee; }
.session { grid-column: 3; grid-row: 1; justify-self: end; min-width: 0; display: flex; align-items: center; gap: 8px; }
.session button {
  display: block;
  white-space: nowrap;
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 13px;
  background: #ffffff0a;
  border-color: #ffffff2b;
  border-radius: 100px;
  padding: 9px 15px;
}
.session button:hover { background: #ffffff18; border-color: #ffffff4d; }

.feedback {
  display: none;
  max-width: var(--max-width);
  margin: auto;
  padding: 13px var(--gutter);
  border-bottom: 1px solid var(--rule);
  font-size: 14px;
  line-height: 1.55;
}
.feedback:has(#notice:not([hidden])) { display: block; }
.feedback p { color: #ebe3da; margin: 0; }

.hero {
  display: flex;
  flex-direction: column;
  min-height: calc(100svh - var(--header-height) - 1px);
  background:
    radial-gradient(ellipse 64% 54% at 50% 35%, #ffffff18, transparent 79%),
    radial-gradient(ellipse 72% 62% at 100% 100%, #0005, transparent 80%),
    #141414;
}
.hero-inner {
  width: min(100%, 780px);
  margin: auto;
  padding: clamp(30px, 6svh, 64px) 30px;
}
.hero-brand {
  text-align: center;
  animation: copy-in .36s ease-out both;
}
.hero-brand h1 {
  display: grid;
  justify-items: center;
  gap: 14px;
  margin: 0;
}
.hero-brand img { display: block; height: auto; }
.hero-logo {
  width: clamp(156px, 18vw, 210px);
  filter: brightness(1.38);
}
.hero-wordmark { width: clamp(138px, 15vw, 178px); }
.platform-title {
  margin: 22px 0 0;
  color: #f0f0f0;
  font-size: clamp(19px, 2.2vw, 24px);
  font-weight: 600;
  letter-spacing: .025em;
}
.platform-description {
  margin: 10px auto 0;
  max-width: 36rem;
  color: #bdbdbd;
  font-size: 14px;
  line-height: 1.65;
  text-wrap: balance;
}
.platform-description span { display: inline-block; }
.hero-download {
  position: relative;
  isolation: isolate;
  max-width: 582px;
  margin: 31px auto 0;
  scroll-margin-top: calc(var(--header-height) + 16px);
  padding: 21px 23px 17px;
  border: 1px solid #ffffff24;
  border-radius: 22px;
  background: linear-gradient(160deg, #ffffff0e, transparent 65%), #2b2b2bd1;
  backdrop-filter: blur(30px);
  box-shadow: inset 0 1px 0 #ffffff10, 0 15px 45px #0007;
  animation: copy-in .42s .07s ease-out both;
  transition: border-color .18s, box-shadow .18s;
}
.hero-download:focus-within {
  border-color: #ffffff56;
  box-shadow: inset 0 1px 0 #ffffff21, 0 15px 45px #0007;
}
@supports (mask-composite: exclude) {
  .hero-download::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1.5px;
    pointer-events: none;
    background: linear-gradient(105deg, transparent 42%, #ffffffe6 50%, transparent 58%) 100% 0 / 240% 100% no-repeat;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    animation: silver-edge 9s linear infinite;
  }
}
.download-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 13px 18px;
}
.download-row h2 { color: #ededed; font-size: 16px; font-weight: 620; }
.download-logins { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 8px; }
.download-logins button { min-height: 43px; white-space: nowrap; }
.file-meta { margin: 6px 0 0; color: #b6b6b6; font-size: 12px; font-variant-numeric: tabular-nums; }
#win-version:not(:empty)::before { content: " · "; color: #a7a7a7; }
.primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f0eae1;
  border: 1px solid #f0eae1;
  color: #191614;
  text-decoration: none;
  font-size: 14px;
  font-weight: 650;
  border-radius: 9px;
  padding: 9px 15px;
}
.primary:hover { background: #fcf8f2; border-color: #fcf8f2; }
.download-button {
  min-height: 43px;
  padding-inline: 16px;
  white-space: nowrap;
  border-radius: 10px;
  border-color: #e8e8e8;
  background: #e8e8e8;
  color: #202020;
  transition: background-color .18s, transform .18s;
}
.download-button:hover { background: #fff; border-color: #fff; transform: translateY(-1px); }
.integrity { color: #c2c2c2; font-size: 12px; margin-top: 16px; padding-top: 13px; border-top: 1px solid #ffffff1a; }
summary { cursor: pointer; width: fit-content; }
.integrity code {
  display: block;
  color: #eee9e2;
  margin-top: 8px;
  overflow-wrap: anywhere;
  font: 12px/1.5 ui-monospace, monospace;
}
.platform-capabilities {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
}
.platform-capabilities li {
  padding: 0 18px;
  border-inline-start: 1px solid var(--rule);
}
.platform-capabilities li:first-child { border-inline-start: 0; }
.platform-capabilities h2 { color: #e8e8e8; font-size: 14px; font-weight: 620; }
.platform-capabilities p { margin: 7px 0 0; color: #aeb0af; font-size: 13px; line-height: 1.55; }
.release-note { margin: 0; padding: 10px var(--gutter) 21px; color: #a7a7a7; text-align: center; font-size: 12px; }

.workspace { max-width: 1160px; margin: 0 auto; padding: 48px var(--gutter) 68px; animation: copy-in .34s ease-out both; }
.title { padding: 0 0 24px; }
.title h1 { font-size: clamp(32px, 4.6vw, 50px); letter-spacing: -.05em; margin: 0; }
.title p { color: var(--muted); margin: 8px 0 0; }
h2 { font-size: 20px; margin: 0; }
dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-block: 1px solid var(--rule); gap: 20px; margin: 0 0 30px; padding: 18px 0; }
dt { font-size: 13px; color: var(--muted); }
dd { margin: 8px 0 0; font-size: clamp(18px, 2.8vw, 27px); font-weight: 600; overflow-wrap: anywhere; }
.table-wrap { overflow: auto; margin-top: 14px; }
table { border-collapse: collapse; width: 100%; min-width: 440px; font-size: 13px; font-variant-numeric: tabular-nums; }
th, td { border-bottom: 1px solid var(--rule); padding: 12px 8px; text-align: right; }
th { color: var(--muted); font-weight: 550; }
th:first-child, td:first-child { text-align: left; }
td:first-child button { font-size: 12px; }
form { display: flex; align-items: end; flex-wrap: wrap; gap: 15px; padding: 0 0 19px; }
form label { color: var(--muted); display: grid; gap: 7px; font-size: 13px; }
input, select { color: #f3f2f0; border: 1px solid #ffffff2e; background: #18181b; border-radius: 7px; padding: 9px; min-width: 124px; }
.workspace h3 { margin: 26px 0 0; font-size: 15px; font-weight: 600; }
.usage-heading { margin: 24px 0 12px; }
.staff-conversations { margin: 20px 0 28px; }
.conversation-heading, .chat-session-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.conversation-heading h2 { margin: 0; }
.chat-session-row, .chat-turn { width: 100%; padding: 14px 16px; margin: 6px 0; text-align: left; border: 1px solid var(--line, #353537); border-radius: 12px; overflow-wrap: anywhere; }
.chat-session-row strong { min-width: 0; }
.chat-session-row small, .chat-turn small { color: var(--muted); }
.chat-turn h3, .chat-turn h4 { margin: 8px 0; }
.chat-turn p { white-space: pre-wrap; margin: 0 0 12px; line-height: 1.55; }
.muted { color: var(--muted); font-size: 13px; }
.usage-plot {
  padding: 12px 10px 8px;
  border: 1px solid var(--rule);
  border-radius: 12px;
  background: #171719;
}
.usage-plot canvas { display: block; width: 100%; height: 192px; }
.usage-plot output { display: block; margin: 2px 10px 5px; color: var(--muted); font-size: 12px; }
.user-directory { margin-top: 0; }
.user-directory table { min-width: 765px; }
.user-directory small { display: block; color: var(--muted); font-size: 11px; line-height: 1.45; }
.permissions-link { color: #d5b99b; white-space: nowrap; text-underline-offset: 3px; }
.user-entry {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 320px;
  padding: 6px 8px;
  border-color: transparent;
  background: transparent;
  text-align: left;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 8px;
  overflow-wrap: anywhere;
}
.user-entry:hover { border-color: #ffffff42; background: #252527; }
.user-entry strong { display: block; font-size: 13px; }
.user-avatar {
  position: relative;
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  height: 34px;
  border-radius: 50%;
  overflow: hidden;
  background: #303032;
  color: #e5d7c6;
  font-weight: 650;
}
.user-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #303032; }
.directory-pages { display: flex; align-items: center; gap: 12px; justify-content: flex-end; margin-top: 14px; }
.directory-pages button:disabled { cursor: default; opacity: .45; }
.directory-pages span, .detail-identity small { color: var(--muted); font-size: 13px; }
#user-search input { width: min(330px, 100%); }
.back-link { display: inline-block; margin-bottom: 20px; color: #c7b39c; font-size: 13px; text-decoration: none; }
.back-link:hover { text-decoration: underline; }
.detail-identity { display: flex; align-items: center; gap: 10px; margin-top: 14px; overflow-wrap: anywhere; }
.detail-identity small { display: block; line-height: 1.55; }
#user-form { border-bottom: 1px solid var(--rule); }
@keyframes copy-in { from { opacity: .35; transform: translateY(7px); } to { opacity: 1; transform: translateY(0); } }
@keyframes silver-edge {
  0%, 8% { background-position: 100% 0; opacity: 0; }
  16%, 39% { opacity: .9; }
  55%, 100% { background-position: 0 0; opacity: 0; }
}

@media (max-width: 850px) {
  .top-inner { gap: 13px; }
  .brand { gap: 10px; }
  .brand span { padding-left: 10px; }
  .brand img { width: 76px; }
}
@media (max-width: 600px) {
  :root { --header-height: 68px; }
  body:has(nav [data-tab="usage"]:not([hidden])) { --header-height: 112px; }
  .top-inner { min-height: var(--header-height); grid-template-columns: 1fr auto; gap: 9px 12px; padding-top: 14px; padding-bottom: 10px; }
  .top nav { grid-row: 2; grid-column: 1 / -1; gap: 4px; flex-wrap: wrap; }
  .top nav button { padding: 7px; font-size: 12px; }
  .session { grid-column: 2; }
  .session button { max-width: 145px; padding: 8px 11px; }
  .platform-capabilities { grid-template-columns: minmax(0, 1fr); margin-top: 22px; }
  .platform-capabilities li { padding: 12px 0; border-inline-start: 0; border-block-end: 1px solid var(--rule); }
  .platform-capabilities li:last-child { border-block-end: 0; }
  .workspace { padding-top: 32px; }
}
@media (max-width: 440px) {
  .top-inner:has(#email-sign-in:not([hidden])) { column-gap: 8px; padding-inline: 14px; }
  .session:has(#email-sign-in:not([hidden])) { gap: 4px; }
  .session:has(#email-sign-in:not([hidden])) button { font-size: 12px; padding-inline: 8px; }
  .hero-inner { padding-inline: var(--gutter); }
  .hero-download { margin-top: 31px; padding: 17px; border-radius: 19px; }
  .download-row { flex-wrap: wrap; }
  .download-logins { width: 100%; }
  .download-logins button { flex: 1 1 auto; }
  .download-logins .download-button { width: auto; }
  .download-button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-download::before { display: none; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
 .model-form {display:flex;align-items:end;flex-wrap:wrap;gap:12px;margin:16px 0 22px}
 .model-form[hidden] {display:none}
 .model-form small {color:#aaa;overflow-wrap:anywhere;max-width:100%}
 .model-form fieldset {min-inline-size:0;border:1px solid #38383b;border-radius:8px;padding:10px 12px}
 #staff-models {display:flex;flex-wrap:wrap;gap:10px 16px}
 .model-cards {display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,340px),1fr));gap:14px;margin-block:20px}
 .model-cards .model-form {margin:0;padding:16px;align-items:center;border:1px solid var(--rule);border-radius:12px;background:#17171a}
 .model-cards .model-form small {flex-basis:100%;order:2}
 .model-cards .model-form > label:first-child {display:grid;gap:6px;flex:1;min-width:128px}
 .model-cards .model-form > label:nth-of-type(2) {white-space:nowrap}
