:root {
  color-scheme: light dark;
  --bg: #f7f7f4;
  --panel: #ffffff;
  --text: #1d2327;
  --muted: #647067;
  --line: #dfe3dc;
  --accent: #176b52;
  --accent-ink: #ffffff;
  --header-bg: rgba(255, 255, 255, 0.86);
  --logo-bg: #f3f5f1;
  --shadow: rgba(26, 33, 29, 0.08);
}

[data-theme="dark"] {
  --bg: #111513;
  --panel: #1a211e;
  --text: #eef4ef;
  --muted: #a1afa8;
  --line: #314039;
  --accent: #67d5aa;
  --accent-ink: #07110d;
  --header-bg: rgba(17, 21, 19, 0.86);
  --logo-bg: #111513;
  --shadow: rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
}

.site-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  min-height: 64px;
  padding: 0 32px;
  border-bottom: 1px solid var(--line);
  background: var(--header-bg);
  position: sticky;
  top: 0;
  backdrop-filter: blur(12px);
  z-index: 10;
}

.brand {
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
}

nav,
.language-switcher,
.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.header-actions {
  justify-content: end;
}

nav a,
.language-switcher a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}

.language-switcher .active {
  color: var(--accent);
  font-weight: 700;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--text);
  box-shadow: 0 8px 20px var(--shadow);
  cursor: pointer;
}

.theme-toggle__icon {
  font-size: 18px;
  line-height: 1;
}

main {
  width: min(1240px, calc(100% - 48px));
  margin: 0 auto;
}

.hero {
  display: grid;
  gap: 22px;
  padding: 72px 0 48px;
  max-width: 840px;
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 18px;
  font-size: 28px;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.lead {
  margin: 0;
  max-width: 680px;
  color: var(--muted);
  font-size: 20px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 16px;
  margin: 0 0 48px;
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 16px;
  margin: 0 0 48px;
}

.tool-card,
.article-card,
.content-panel,
.workflow-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 22px;
}

.tool-card {
  display: grid;
  align-content: start;
  gap: 16px;
  min-width: 0;
}

.workflow-panel {
  display: grid;
  align-content: start;
  gap: 14px;
  min-height: 230px;
}

.workflow-panel p {
  margin: 0;
  color: var(--muted);
}

.tool-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
}

.tool-chip {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 11px;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  font-weight: 650;
  line-height: 1;
  text-decoration: none;
}

.tool-chip:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.tool-card__media {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  text-transform: uppercase;
}

.tool-logo {
  width: 56px;
  height: 56px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--logo-bg);
  padding: 10px;
  object-fit: contain;
}

dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

dt {
  color: var(--muted);
  font-size: 13px;
}

dd {
  margin: 0;
  font-weight: 650;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 40px;
  border-radius: 6px;
  padding: 0 14px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
  text-decoration: none;
}

.article-card a {
  font-weight: 750;
  text-decoration: none;
}

.content-panel {
  margin: 32px 0 72px;
  font-size: 18px;
}

.content-panel h2 {
  margin-top: 32px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.content-panel h2:first-of-type {
  margin-top: 24px;
}

.content-panel p {
  max-width: 820px;
}

.content-panel li {
  max-width: 820px;
  margin: 8px 0;
}

.content-panel a {
  color: var(--accent);
  font-weight: 700;
}

.content-panel dl {
  max-width: 820px;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

@media (max-width: 720px) {
  .site-header {
    grid-template-columns: 1fr;
    align-items: start;
    padding: 14px 20px;
  }

  main {
    width: min(100% - 28px, 1120px);
  }

  .hero {
    padding-top: 44px;
  }
}
