:root {
  --ink: #111827;
  --muted: #5f6b7a;
  --line: rgba(255, 255, 255, 0.46);
  --glass: rgba(255, 255, 255, 0.42);
  --glass-strong: rgba(255, 255, 255, 0.72);
  --panel: rgba(255, 255, 255, 0.5);
  --orange: #ff8a1c;
  --orange-dark: #d85f00;
  --cyan: #13b9d6;
  --blue: #3979ff;
  --pink: #e755ff;
  --green: #10a37f;
  --red: #d52929;
  --shadow: 0 28px 80px rgba(32, 45, 72, 0.2);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
}

.wallpaper-video,
.wallpaper-shade {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
}

.wallpaper-video {
  z-index: -3;
  object-fit: cover;
  background: #eef4ff;
}

.wallpaper-shade {
  z-index: -2;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.74) 0%, rgba(255, 255, 255, 0.43) 42%, rgba(255, 255, 255, 0.18) 100%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.48), rgba(224, 238, 255, 0.2));
}

.app-shell {
  width: min(1480px, calc(100% - 40px));
  margin: 0 auto;
  padding: 16px 0 44px;
}

.topbar {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.48);
  box-shadow: 0 16px 40px rgba(40, 70, 120, 0.14);
  backdrop-filter: blur(18px) saturate(160%);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--orange), #ffd166 46%, var(--pink));
  color: #ffffff;
  font-size: 19px;
  font-weight: 950;
  box-shadow: 0 10px 28px rgba(255, 138, 28, 0.28);
}

.brand strong {
  display: block;
  color: #0d1728;
  font-size: 21px;
  line-height: 1.1;
}

.brand small {
  color: rgba(17, 24, 39, 0.58);
  font-size: 12px;
  font-weight: 800;
}

.topbar nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar a {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 14px;
  color: #15223a;
  text-decoration: none;
  font-size: 13px;
  font-weight: 900;
}

.topbar a:first-child {
  background: rgba(255, 255, 255, 0.68);
  color: var(--orange-dark);
  box-shadow: inset 0 0 0 1px rgba(255, 138, 28, 0.18);
}

.access-badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 13px;
  border-radius: 999px;
  background: rgba(16, 163, 127, 0.12);
  color: #0d7c60;
  font-size: 13px;
  font-weight: 900;
}

.review-announcement {
  margin-top: 16px;
  padding: 14px 18px;
  border: 1px solid rgba(255, 138, 28, 0.28);
  border-radius: 16px;
  background: rgba(255, 248, 231, 0.78);
  color: #6c3c00;
  font-weight: 800;
  box-shadow: 0 16px 40px rgba(255, 138, 28, 0.12);
  backdrop-filter: blur(16px);
}

.review-announcement strong {
  display: block;
  margin-bottom: 4px;
  color: #c45600;
}

.auth-lock {
  width: min(720px, calc(100vw - 40px));
  margin: 20vh auto 0;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px) saturate(160%);
}

.auth-lock span {
  color: var(--orange-dark);
  font-size: 14px;
  font-weight: 950;
}

.auth-lock h1 {
  margin: 12px 0;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.05;
}

.auth-lock p {
  color: var(--muted);
  font-size: 17px;
  font-weight: 700;
}

.auth-lock a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 10px;
  padding: 0 18px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--orange), #ff5f8f);
  text-decoration: none;
  font-weight: 950;
}

.hidden {
  display: none !important;
}

.intro {
  width: min(760px, 100%);
  margin: 78px 0 24px;
  text-shadow: 0 2px 18px rgba(255, 255, 255, 0.58);
}

.intro p {
  margin: 0 0 12px;
  color: var(--orange-dark);
  font-weight: 950;
  letter-spacing: 0;
}

.intro h1 {
  margin: 0;
  color: #111827;
  font-size: clamp(38px, 5vw, 72px);
  line-height: 1.04;
  letter-spacing: 0;
}

.intro span {
  display: block;
  max-width: 650px;
  margin-top: 16px;
  color: #405064;
  font-size: 18px;
  line-height: 1.65;
  font-weight: 700;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(330px, 0.36fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.control-panel,
.result-panel,
.summary-card,
.review-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--glass);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px) saturate(165%);
}

.control-panel {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 16px;
  padding: 18px;
}

.panel-heading,
.result-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.panel-heading {
  justify-content: flex-start;
}

.panel-heading > span,
.result-toolbar span {
  min-width: 50px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 138, 28, 0.95), rgba(231, 85, 255, 0.86));
  color: #ffffff;
  font-size: 12px;
  font-weight: 950;
  flex-shrink: 0;
}

h1,
h2,
p {
  margin-top: 0;
}

h2 {
  margin: 0 0 5px;
  color: #0f172a;
  font-size: 22px;
  line-height: 1.18;
}

.panel-heading p {
  margin: 0;
  color: #526071;
  font-size: 13px;
  line-height: 1.55;
  font-weight: 700;
}

label {
  display: grid;
  gap: 8px;
  color: #243044;
  font-size: 13px;
  font-weight: 950;
}

input,
select {
  min-width: 0;
  min-height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 12px;
  padding: 0 13px;
  background: rgba(255, 255, 255, 0.84);
  color: #111827;
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 10px 24px rgba(30, 56, 90, 0.08);
}

input::placeholder {
  color: #7a8798;
}

input:focus,
select:focus {
  border-color: rgba(255, 138, 28, 0.85);
  box-shadow: 0 0 0 4px rgba(255, 138, 28, 0.16), 0 14px 30px rgba(30, 56, 90, 0.13);
}

.url-field input {
  min-height: 54px;
  background: rgba(255, 255, 255, 0.9);
  font-weight: 800;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.primary-button,
.toolbar-actions button,
.prompt-box button {
  min-height: 40px;
  border: 0;
  border-radius: 12px;
  padding: 0 15px;
  cursor: pointer;
  font-weight: 950;
}

.primary-button {
  min-height: 50px;
  background: linear-gradient(135deg, #1c91ff, #8b5cf6 48%, #ff62d2);
  color: #ffffff;
  box-shadow: 0 16px 32px rgba(76, 80, 230, 0.28);
}

.primary-button:disabled {
  cursor: wait;
  filter: grayscale(0.15);
  opacity: 0.76;
}

.status {
  min-height: 20px;
  margin: 0;
  color: #415169;
  font-size: 13px;
  line-height: 1.45;
  font-weight: 800;
}

.status.is-error {
  color: var(--red);
}

.status.is-success {
  color: var(--green);
}

.result-panel {
  min-height: 520px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.34);
}

.result-toolbar {
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.46);
}

.result-toolbar > div:first-child {
  display: flex;
  align-items: center;
  gap: 10px;
}

.toolbar-actions {
  display: flex;
  gap: 8px;
}

.toolbar-actions button,
.prompt-box button {
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(255, 255, 255, 0.72);
  color: #172033;
  box-shadow: 0 8px 18px rgba(35, 60, 100, 0.08);
}

.toolbar-actions button:disabled {
  cursor: not-allowed;
  color: #8993a1;
}

.summary-card {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.56);
}

.summary-card small {
  color: var(--orange-dark);
  font-size: 12px;
  font-weight: 950;
}

.summary-card strong {
  color: #101827;
  font-size: 21px;
  line-height: 1.25;
}

.summary-card p {
  margin: 0;
  color: #465469;
  line-height: 1.58;
  font-weight: 700;
}

.review-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.review-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.6);
}

.review-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.review-head > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.review-head strong {
  color: #101827;
  font-size: 15px;
}

.review-head span {
  color: #607085;
  font-size: 12px;
  font-weight: 800;
}

.review-head em {
  color: #f59e0b;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.review-card > p {
  margin: 0;
  color: #243044;
  font-size: 14px;
  line-height: 1.68;
  font-weight: 650;
}

.prompt-box {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.42);
}

.prompt-box > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.5);
  padding: 9px 10px;
}

.prompt-box span {
  color: var(--orange-dark);
  font-size: 12px;
  font-weight: 950;
}

.prompt-box button {
  min-height: 30px;
  border-radius: 9px;
  font-size: 12px;
}

pre {
  margin: 0;
  max-height: 180px;
  overflow: auto;
  padding: 10px;
  white-space: pre-wrap;
  word-break: break-word;
  color: #344158;
  font-family: "JetBrains Mono", Consolas, monospace;
  font-size: 12px;
  line-height: 1.58;
}

@media (max-width: 980px) {
  .wallpaper-shade {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.34)),
      linear-gradient(90deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.22));
  }

  .app-shell {
    width: min(100% - 24px, 820px);
    padding-top: 12px;
  }

  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .topbar nav {
    width: 100%;
    overflow-x: auto;
  }

  .intro {
    margin-top: 46px;
  }

  .intro h1 {
    font-size: 42px;
  }

  .workspace,
  .review-list {
    grid-template-columns: 1fr;
  }

  .control-panel {
    position: static;
  }
}

@media (max-width: 560px) {
  .intro h1 {
    font-size: 34px;
  }

  .intro span {
    font-size: 15px;
  }

  .field-grid {
    grid-template-columns: 1fr;
  }

  .result-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .toolbar-actions {
    width: 100%;
  }

  .toolbar-actions button {
    flex: 1;
  }
}
