:root {
  color-scheme: light dark;
  --background: #f3f7f6;
  --surface: #ffffff;
  --surface-muted: #ecf7f4;
  --text: #17211f;
  --muted: #596966;
  --border: #d8e4e1;
  --brand: #0f766e;
  --brand-strong: #0a5c56;
  --brand-contrast: #ffffff;
  --shadow: 0 22px 60px rgb(20 60 52 / 10%);
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #0d1413;
    --surface: #141d1b;
    --surface-muted: #172723;
    --text: #edf7f4;
    --muted: #a6b9b4;
    --border: #2b3c38;
    --brand: #35c3a0;
    --brand-strong: #5ad5b5;
    --brand-contrast: #071612;
    --shadow: 0 22px 60px rgb(0 0 0 / 24%);
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 12% 0%, rgb(16 185 129 / 12%), transparent 32rem),
    var(--background);
  color: var(--text);
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  line-height: 1.7;
}

a {
  color: var(--brand);
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--brand-strong);
}

.shell {
  width: min(100% - 2rem, 860px);
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 2rem 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-decoration: none;
}

.logo {
  display: grid;
  width: 2.75rem;
  height: 2.75rem;
  place-items: center;
  border-radius: 0.85rem;
  background: var(--brand);
  color: var(--brand-contrast);
}

.pill-link {
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 650;
  text-decoration: none;
}

.page-card {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 1.4rem;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero {
  padding: clamp(2rem, 6vw, 4rem);
  background: linear-gradient(145deg, var(--surface-muted), var(--surface));
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  margin: 0 0 0.6rem;
  color: var(--brand);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 8vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.intro {
  max-width: 42rem;
  margin: 1rem 0 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.updated {
  display: inline-block;
  margin-top: 1.35rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.85rem;
}

.content {
  padding: clamp(1.5rem, 5vw, 3.5rem);
}

section + section {
  margin-top: 2.4rem;
  padding-top: 2.4rem;
  border-top: 1px solid var(--border);
}

h2 {
  margin: 0 0 0.75rem;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
}

p {
  margin: 0.65rem 0 0;
}

ul {
  margin: 0.85rem 0 0;
  padding-left: 1.25rem;
}

li + li {
  margin-top: 0.45rem;
}

code {
  padding: 0.12rem 0.35rem;
  border-radius: 0.35rem;
  background: var(--surface-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
}

.summary {
  padding: 1.15rem 1.25rem;
  border-left: 4px solid var(--brand);
  border-radius: 0.2rem 0.8rem 0.8rem 0.2rem;
  background: var(--surface-muted);
  font-weight: 600;
}

.extension-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.extension-card {
  padding: 1.35rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface-muted);
}

.extension-card h2 {
  margin-bottom: 0.4rem;
}

.extension-card--shopee {
  --brand: #e9422a;
  --brand-strong: #c83320;
  --surface-muted: #fff1ec;
  border-color: #ffd1c5;
}

.extension-card--devutil {
  --brand: #5b57e8;
  --brand-strong: #4642c9;
  --surface-muted: #f1f0ff;
  border-color: #d9d7ff;
}

.extension-card--devkit {
  --brand: #0788e8;
  --brand-strong: #006dbd;
  --surface-muted: #edf8ff;
  border-color: #c6e8ff;
}

.theme-devkit {
  --background: #f4f8fc;
  --surface-muted: #edf8ff;
  --border: #d3e4f2;
  --brand: #0788e8;
  --brand-strong: #006dbd;
  --shadow: 0 22px 60px rgb(7 89 150 / 11%);
  background:
    radial-gradient(circle at 12% 0%, rgb(7 136 232 / 14%), transparent 32rem),
    var(--background);
}

.theme-devutil {
  --background: #f5f6fb;
  --surface-muted: #f0f1ff;
  --border: #dcdff0;
  --brand: #5b57e8;
  --brand-strong: #4642c9;
  --shadow: 0 22px 60px rgb(69 65 180 / 11%);
  background:
    radial-gradient(circle at 12% 0%, rgb(91 87 232 / 14%), transparent 32rem),
    var(--background);
}

.theme-shopee-assistant {
  --background: #fff8f5;
  --surface-muted: #fff0eb;
  --border: #f1d8d0;
  --brand: #e9422a;
  --brand-strong: #c83320;
  --shadow: 0 22px 60px rgb(130 46 28 / 10%);
  background:
    radial-gradient(circle at 12% 0%, rgb(244 81 50 / 13%), transparent 32rem),
    var(--background);
}

@media (prefers-color-scheme: dark) {
  .theme-shopee-assistant {
    --background: #170f0d;
    --surface: #211714;
    --surface-muted: #2d1c17;
    --text: #fff5f1;
    --muted: #d4b8af;
    --border: #4b3028;
    --brand: #ff775d;
    --brand-strong: #ff9a86;
    --brand-contrast: #2b0d07;
    --shadow: 0 22px 60px rgb(0 0 0 / 28%);
  }

  .theme-devutil {
    --background: #0d101b;
    --surface: #151927;
    --surface-muted: #1d2135;
    --text: #f2f3ff;
    --muted: #b6bbd0;
    --border: #30364e;
    --brand: #918cff;
    --brand-strong: #b2aeff;
    --brand-contrast: #111326;
    --shadow: 0 22px 60px rgb(0 0 0 / 28%);
  }

  .theme-devkit {
    --background: #07101b;
    --surface: #101923;
    --surface-muted: #142638;
    --text: #edf8ff;
    --muted: #a8bed0;
    --border: #28435a;
    --brand: #37c9ff;
    --brand-strong: #74dcff;
    --brand-contrast: #03121c;
    --shadow: 0 22px 60px rgb(0 0 0 / 28%);
  }
}

.card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.card-links a {
  font-weight: 700;
}

.site-footer {
  padding-block: 1.5rem 3rem;
  color: var(--muted);
  font-size: 0.88rem;
  text-align: center;
}

@media (max-width: 560px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }
}
