:root {
  --bg: #f3f6fb;
  --bg-strong: #eaf0f8;
  --surface: rgba(255, 255, 255, 0.76);
  --surface-strong: rgba(255, 255, 255, 0.92);
  --panel: rgba(246, 249, 253, 0.78);
  --panel-strong: rgba(255, 255, 255, 0.94);
  --text: #111826;
  --muted: #66748b;
  --line: rgba(17, 24, 38, 0.08);
  --line-strong: rgba(17, 24, 38, 0.15);
  --shadow: 0 34px 110px rgba(20, 31, 52, 0.12);
  --shadow-soft: 0 18px 44px rgba(20, 31, 52, 0.1);
  --accent: #2d6df6;
  --accent-strong: #1f5fdd;
  --accent-soft: rgba(45, 109, 246, 0.14);
  --accent-secondary: #4a7cf2;
  --button-text: #f8fbff;
  --hero-highlight: #b89456;
  --hero-spotlight: rgba(86, 117, 231, 0.22);
  --hero-spotlight-alt: rgba(46, 151, 165, 0.14);
  --hero-spotlight-soft: rgba(111, 145, 255, 0.1);
  --glow-primary: rgba(45, 109, 246, 0.16);
  --glow-secondary: rgba(74, 124, 242, 0.12);
  --glow-tertiary: rgba(46, 151, 165, 0.09);
  --glass-top: rgba(255, 255, 255, 0.48);
  --glass-bottom: rgba(255, 255, 255, 0.08);
  --glass-highlight: rgba(255, 255, 255, 0.28);
  --button-shadow: 0 18px 38px rgba(31, 95, 221, 0.24);
  --interactive-shadow: 0 12px 26px rgba(31, 95, 221, 0.12);
  --card-hover-shadow: 0 22px 40px rgba(20, 31, 52, 0.14);
  --support-tint: rgba(184, 148, 86, 0.16);
  --console-bg: rgba(214, 224, 239, 0.74);
  --console-line: rgba(255, 255, 255, 0.35);
  --console-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.38);
  --secondary-bg: rgba(255, 255, 255, 0.66);
  --secondary-line: rgba(17, 24, 38, 0.08);
  --secondary-text: #285fd2;
  --grid-opacity: 0.12;
}

:root[data-theme="dark"] {
  --bg: #000000;
  --bg-strong: #000000;
  --surface: rgba(19, 24, 34, 0.76);
  --surface-strong: rgba(21, 27, 39, 0.9);
  --panel: rgba(18, 24, 35, 0.8);
  --panel-strong: rgba(22, 29, 42, 0.94);
  --text: #f4f7fb;
  --muted: #9ea9bb;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --shadow: 0 42px 120px rgba(0, 0, 0, 0.44);
  --shadow-soft: 0 20px 48px rgba(0, 0, 0, 0.32);
  --accent: #4f97ff;
  --accent-strong: #3d83f3;
  --accent-soft: rgba(79, 151, 255, 0.18);
  --accent-secondary: #506fff;
  --button-text: #f7fbff;
  --hero-highlight: #ebd9ab;
  --hero-spotlight: rgba(87, 112, 255, 0.28);
  --hero-spotlight-alt: rgba(32, 148, 145, 0.16);
  --hero-spotlight-soft: rgba(75, 104, 255, 0.12);
  --glow-primary: rgba(79, 151, 255, 0.15);
  --glow-secondary: rgba(80, 111, 255, 0.13);
  --glow-tertiary: rgba(32, 148, 145, 0.1);
  --glass-top: rgba(255, 255, 255, 0.08);
  --glass-bottom: rgba(255, 255, 255, 0.02);
  --glass-highlight: rgba(255, 255, 255, 0.1);
  --button-shadow: 0 18px 40px rgba(18, 84, 199, 0.34);
  --interactive-shadow: 0 12px 26px rgba(0, 0, 0, 0.2);
  --card-hover-shadow: 0 24px 42px rgba(0, 0, 0, 0.26);
  --support-tint: rgba(235, 217, 171, 0.14);
  --console-bg: rgba(76, 91, 116, 0.42);
  --console-line: rgba(255, 255, 255, 0.08);
  --console-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  --secondary-bg: rgba(255, 255, 255, 0.06);
  --secondary-line: rgba(255, 255, 255, 0.07);
  --secondary-text: #78b5ff;
  --grid-opacity: 0.06;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 12% 18%, var(--glow-primary), transparent 30%),
    radial-gradient(circle at 82% 14%, var(--glow-secondary), transparent 24%),
    radial-gradient(circle at 50% 100%, var(--glow-tertiary), transparent 38%),
    linear-gradient(180deg, var(--bg), var(--bg-strong));
  color: var(--text);
  font-family: "Avenir Next", "SF Pro Display", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

.page-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.bg-orb,
.bg-grid {
  position: absolute;
  display: block;
}

.bg-orb {
  border-radius: 999px;
  filter: blur(90px);
  opacity: 0.9;
}

.orb-a {
  top: -6rem;
  left: -7rem;
  width: 24rem;
  height: 24rem;
  background: var(--glow-primary);
}

.orb-b {
  top: 12%;
  right: -5rem;
  width: 22rem;
  height: 22rem;
  background: var(--glow-secondary);
}

.orb-c {
  bottom: -8rem;
  left: 40%;
  width: 20rem;
  height: 20rem;
  background: var(--glow-tertiary);
}

.bg-grid {
  inset: 0;
  opacity: var(--grid-opacity);
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.9), transparent 78%);
  mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.9), transparent 78%);
}

.page {
  position: relative;
  z-index: 1;
  width: min(1500px, calc(100% - 32px));
  min-height: 100vh;
  min-height: 100svh;
  margin: 0 auto;
  padding: 16px 0;
  display: flex;
  align-items: center;
}

.hero {
  width: 100%;
}

.hero-shell,
.tool-card,
.button,
.tool-section {
  backdrop-filter: blur(18px);
}

.hero-shell {
  position: relative;
  overflow: hidden;
  width: 100%;
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid var(--line);
  border-radius: 44px;
  background:
    linear-gradient(135deg, var(--glass-top), var(--glass-bottom)),
    var(--surface-strong);
  box-shadow: var(--shadow);
}

.hero-shell::before,
.hero-shell::after {
  content: "";
  position: absolute;
  inset: auto;
  border-radius: 999px;
  pointer-events: none;
}

.hero-shell::before {
  top: -8rem;
  right: 20%;
  width: 20rem;
  height: 20rem;
  background: radial-gradient(circle, var(--glow-primary), transparent 68%);
}

.hero-shell::after {
  bottom: -10rem;
  left: 8%;
  width: 26rem;
  height: 26rem;
  background: radial-gradient(circle, var(--glow-secondary), transparent 70%);
}

.hero-grid {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero-grid::before {
  content: "";
  position: absolute;
  inset: -6rem auto auto 50%;
  width: min(52rem, 92vw);
  height: min(52rem, 92vw);
  border-radius: 999px;
  transform: translateX(-50%);
  background:
    radial-gradient(circle at 55% 38%, var(--hero-spotlight), transparent 34%),
    radial-gradient(circle at 38% 68%, var(--hero-spotlight-alt), transparent 32%),
    radial-gradient(circle at center, var(--hero-spotlight-soft), transparent 64%);
  filter: blur(18px);
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(100%, 920px);
  padding: 26px 0 6px;
  text-align: center;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-title {
  margin: 20px 0 0;
  font-size: clamp(2.8rem, 5.6vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: -0.05em;
  font-weight: 740;
}

.hero-subtitle {
  max-width: 44rem;
  margin: 22px auto 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.18rem);
  letter-spacing: -0.01em;
}

.hero-console {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  width: min(100%, 560px);
  margin-top: 28px;
  padding: 12px 14px 12px 18px;
  border: 1px solid var(--console-line);
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent),
    var(--console-bg);
  box-shadow: var(--console-shadow);
}

.hero-console-url,
.hero-console-suffix {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  white-space: nowrap;
  font-size: clamp(0.96rem, 1.4vw, 1.06rem);
  font-weight: 600;
}

.hero-console-url {
  color: var(--text);
}

.hero-console-suffix {
  padding: 0 16px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--accent);
}

.hero-note {
  max-width: 42rem;
  margin: 18px auto 0;
  color: var(--muted);
  font-size: 0.98rem;
}

.hero-actions {
  margin-top: 26px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 158px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 650;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    color 180ms ease;
}

.button.primary {
  color: var(--button-text);
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: var(--button-shadow);
}

.button.secondary {
  color: var(--secondary-text);
  border-color: var(--secondary-line);
  background:
    linear-gradient(180deg, var(--glass-top), var(--glass-bottom)),
    var(--secondary-bg);
  box-shadow: var(--shadow-soft);
}

.button:hover,
.button:focus-visible,
.tool-card:hover,
.tool-card:focus-visible {
  transform: translateY(-2px);
}

.button:focus-visible,
.tool-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.tool-icon-mask {
  display: block;
  background-color: currentColor;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}

.tool-icon-mask-openai {
  -webkit-mask-image: url("./icon/openai.svg");
  mask-image: url("./icon/openai.svg");
}

.tool-icon-mask-opencode {
  -webkit-mask-image: url("./icon/opencode.svg");
  mask-image: url("./icon/opencode.svg");
}

.tool-sections {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 52px;
}

.tool-section {
  display: flex;
  flex-direction: column;
  padding: 18px 20px 20px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(135deg, var(--glass-top), transparent),
    var(--panel);
  box-shadow: var(--shadow-soft);
}

.tool-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.tool-section-title {
  margin: 0;
  color: var(--muted);
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.tool-section-link {
  margin: 0;
  font-size: 0.94rem;
  letter-spacing: -0.01em;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  transition: color 180ms ease, opacity 180ms ease;
}

.tool-section-link:hover,
.tool-section-link:focus-visible {
  color: var(--accent);
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.tool-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 120px;
  padding: 18px 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    linear-gradient(180deg, var(--glass-top), var(--glass-bottom)),
    var(--panel-strong);
  box-shadow: var(--shadow-soft);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease,
    background-color 180ms ease;
}

.tool-card:hover,
.tool-card:focus-visible {
  border-color: var(--line-strong);
  box-shadow: var(--card-hover-shadow);
}

.tool-mark {
  display: inline-grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, var(--glass-top), var(--glass-bottom)),
    var(--surface);
  box-shadow:
    inset 0 1px 0 var(--glass-highlight),
    var(--interactive-shadow);
}

.tool-mark-openai {
  color: var(--text);
}

.tool-mark-opencode {
  color: var(--text);
}

.tool-icon-mask {
  width: 30px;
  height: 30px;
}

.tool-mark-fallback {
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.tool-mark-support {
  background:
    linear-gradient(135deg, var(--accent-soft), var(--support-tint)),
    var(--surface);
}

.tool-icon-image {
  display: block;
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.tool-name {
  font-size: 0.96rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

@media (max-width: 980px) {
  .page {
    width: min(100%, calc(100% - 24px));
    padding: 12px 0;
    align-items: stretch;
  }

  .hero-shell {
    border-radius: 30px;
  }

  .hero-copy {
    padding-top: 6px;
  }

  .tool-sections,
  .tool-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  body {
    background:
      radial-gradient(circle at 16% 12%, var(--hero-spotlight), transparent 26%),
      radial-gradient(circle at 84% 16%, var(--hero-spotlight-alt), transparent 20%),
      linear-gradient(180deg, var(--bg), var(--bg-strong));
  }

  .page {
    width: calc(100% - 20px);
  }

  .hero-shell {
    padding: 18px;
    border-radius: 26px;
  }

  .hero-title {
    margin-top: 14px;
    font-size: clamp(2.2rem, 11vw, 3.2rem);
  }

  .hero-console {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    padding: 10px 10px 10px 14px;
  }

  .hero-console-url,
  .hero-console-suffix {
    min-height: 38px;
    font-size: 0.95rem;
  }

  .hero-console-url {
    min-width: 0;
    text-align: center;
    word-break: break-all;
  }

  .hero-console-suffix {
    padding: 0 14px;
  }

  .hero-actions {
    margin-top: 22px;
  }

  .button,
  .hero-actions .button {
    width: 100%;
  }

  .button.secondary {
    width: 100%;
  }

  .tool-sections {
    gap: 14px;
  }

  .tool-section {
    padding: 16px;
    border-radius: 24px;
  }

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

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
