:root {
  --bg: #f8fafc;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #475569;
  --soft: #64748b;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --success: #16a34a;
  --warning: #f59e0b;
  --error: #dc2626;
  --border: #e2e8f0;
  --shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  --radius: 8px;
  --container: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  scroll-behavior: smooth;
}

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

img,
canvas {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-dark);
}

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

h1 {
  font-size: 2rem;
  line-height: 1.15;
  letter-spacing: 0;
}

h2 {
  font-size: 1.35rem;
  line-height: 1.25;
  letter-spacing: 0;
}

h3 {
  font-size: 1rem;
  line-height: 1.3;
  letter-spacing: 0;
}

p {
  color: var(--muted);
}

input,
textarea,
select,
button {
  font: inherit;
}

.container {
  width: min(100% - 32px, var(--container));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 20;
  padding: 10px 12px;
  background: var(--text);
  color: #ffffff;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.header-inner {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 750;
  line-height: 1;
}

.brand-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: #dbeafe;
  border: 1px solid var(--border);
}

.nav-toggle {
  width: 42px;
  height: 42px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--text);
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 999px;
}

.nav-toggle-bars {
  position: relative;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
}

.nav-toggle-bars::before {
  top: -6px;
}

.nav-toggle-bars::after {
  top: 6px;
}

.site-nav {
  position: absolute;
  left: 16px;
  right: 16px;
  top: 64px;
  display: none;
  padding: 10px;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.site-nav.is-open {
  display: grid;
}

.site-nav a {
  padding: 10px 12px;
  border-radius: 6px;
  color: var(--text);
  font-weight: 650;
}

.site-nav a:hover {
  background: #eff6ff;
  color: var(--accent-dark);
}

.button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  background: var(--accent);
  color: #ffffff;
  padding: 10px 14px;
  font-weight: 750;
  cursor: pointer;
  text-align: center;
}

.button:hover {
  color: #ffffff;
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

.button-muted {
  background: #ffffff;
  color: var(--accent);
  border-color: #bfdbfe;
}

.button-muted:hover {
  background: #eff6ff;
  color: var(--accent-dark);
  border-color: #93c5fd;
}

.button-ghost {
  background: #ffffff;
  color: var(--muted);
  border-color: var(--border);
}

.button-ghost:hover {
  background: #f1f5f9;
  color: var(--text);
  border-color: #cbd5e1;
}

.eyebrow {
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.breadcrumbs {
  padding: 18px 0 10px;
  font-size: 0.86rem;
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.breadcrumbs li {
  color: var(--soft);
}

.breadcrumbs li + li::before {
  content: "/";
  margin-right: 6px;
  color: #94a3b8;
}

.page-main {
  padding: 16px 0 54px;
}

.page-section,
.narrow-page {
  padding: 24px 0 64px;
}

.narrow-page {
  max-width: 760px;
}

.legal-copy h2,
.profile-content h2 {
  margin-top: 28px;
}

.check-list {
  padding-left: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 10px;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.social-links a {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #ffffff;
  padding: 8px 10px;
  color: var(--text);
  font-weight: 650;
}

.social-links a:hover {
  background: #eff6ff;
  color: var(--accent-dark);
  border-color: #bfdbfe;
}

.tool-card-grid {
  display: grid;
  gap: 14px;
}

.tool-card-link,
.mini-tool-card,
.category-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--text);
  padding: 16px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}

.tool-card-link:hover,
.mini-tool-card:hover,
.category-card:hover {
  border-color: #bfdbfe;
  color: var(--text);
  transform: translateY(-1px);
}

.tool-icon {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border-radius: var(--radius);
  background: #eff6ff;
  color: var(--accent-dark);
  font-size: 0.82rem;
  font-weight: 850;
}

.tool-card-link small,
.mini-tool-card small,
.category-card span {
  color: var(--muted);
}

.ad-box {
  width: 100%;
  min-height: 250px;
  margin: 18px 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #ffffff;
  overflow: hidden;
}

.ad-box .adsbygoogle {
  display: block;
  width: 100%;
  min-height: 250px;
}

.ad-label {
  margin-bottom: 8px;
  color: var(--soft);
  font-size: 0.72rem;
  font-weight: 700;
  text-align: center;
  text-transform: uppercase;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: #ffffff;
}

.footer-grid {
  display: grid;
  gap: 26px;
  padding: 34px 0;
}

.footer-grid h2 {
  margin-bottom: 12px;
  font-size: 1rem;
}

.footer-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-list a {
  color: var(--muted);
}

.footer-list a:hover {
  color: var(--accent-dark);
}

.footer-bottom {
  padding: 14px 0 24px;
  border-top: 1px solid var(--border);
}

.footer-bottom p {
  margin: 0;
  font-size: 0.9rem;
}

.is-hidden {
  display: none !important;
}

@media (min-width: 720px) {
  h1 {
    font-size: 2.6rem;
  }

  .nav-toggle {
    display: none;
  }

  .site-nav {
    position: static;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }

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

  .footer-grid {
    grid-template-columns: 1.3fr 1fr 1fr;
  }
}
