/* Blog, affiliate and growth tools follow the site's shared design tokens. */
body.growth-affiliate,
body.growth-blog,
body.growth-console,
body.growth-admin {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
}

body.growth-affiliate a,
body.growth-blog a,
body.growth-console a,
body.growth-admin a { transition: color .16s, border-color .16s, background .16s; }

/* Public affiliate pages */
.growth-affiliate .wrap { max-width: 1160px; padding: 0 28px; }
.growth-affiliate .top {
  min-height: 78px;
  gap: 30px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  font-weight: 500;
}
.growth-affiliate .top a { color: var(--ink-2); }
.growth-affiliate .top a:hover,
.growth-affiliate footer a:hover { color: var(--accent); }
.growth-affiliate .top .last {
  padding: 7px 12px;
  border: 1px solid var(--line-2);
  border-radius: 8px;
  color: var(--ink);
}
.growth-affiliate .top .last:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.growth-affiliate .hero {
  position: relative;
  isolation: isolate;
  padding: 94px 0 72px;
}
.growth-affiliate .hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  height: 100%;
  background: radial-gradient(circle at 81% 43%, rgba(36,84,240,.12), transparent 36%),
    linear-gradient(90deg, transparent 0, rgba(36,84,240,.045) 1px, transparent 1px),
    linear-gradient(transparent 0, rgba(36,84,240,.045) 1px, transparent 1px);
  background-size: auto, 42px 42px, 42px 42px;
  mask-image: linear-gradient(#000, transparent 96%);
}
.growth-affiliate .hero .eyebrow { margin-bottom: 22px; }
.growth-affiliate .hero h1 {
  max-width: 840px;
  margin-bottom: 24px;
  font-size: clamp(40px, 5.2vw, 66px);
  font-weight: 600;
  letter-spacing: -.045em;
  line-height: 1.13;
}
.growth-affiliate .hero p:not(.eyebrow) { max-width: 650px; color: var(--ink-2); font-size: 18px; line-height: 1.75; }
.growth-affiliate .actions { margin-top: 36px; }
.growth-affiliate .button {
  padding: 13px 21px;
  border: 1px solid var(--accent);
  border-radius: 10px;
  background: var(--accent);
  box-shadow: 0 3px 12px rgba(36,84,240,.16);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.25;
  transition: transform .16s, background .16s, box-shadow .16s;
}
.growth-affiliate .button:hover { background: var(--accent-700); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(36,84,240,.22); }
.growth-affiliate .button.secondary {
  color: var(--ink) !important;
  background: var(--surface);
  border-color: var(--line-2);
  box-shadow: var(--shadow-sm);
}
.growth-affiliate .button.secondary:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.growth-affiliate .numbers { gap: 12px; }
.growth-affiliate .numbers .card {
  min-height: 142px;
  padding: 24px 26px;
  border-color: var(--line);
  border-radius: 14px;
  color: var(--ink-2);
  box-shadow: var(--shadow-sm);
}
.growth-affiliate .number {
  margin-bottom: 6px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: clamp(27px, 3vw, 34px);
  font-weight: 600;
  letter-spacing: -.05em;
  line-height: 1.25;
}
.growth-affiliate .section { padding: 72px 0 0; }
.growth-affiliate .section h2 { margin-bottom: 24px; font-size: clamp(27px, 3vw, 36px); letter-spacing: -.035em; }
.growth-affiliate .section > p { max-width: 800px; margin: 0 0 17px; color: var(--ink-2); line-height: 1.85; }
.growth-affiliate .grid { gap: 14px; }
.growth-affiliate .grid .card {
  padding: 28px;
  border-color: var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}
.growth-affiliate .grid h3 { margin-bottom: 14px; font-size: 19px; line-height: 1.35; }
.growth-affiliate .grid p { color: var(--ink-2); line-height: 1.75; }
.growth-affiliate .section:last-child {
  margin: 80px 0 70px;
  padding: 42px;
  border: 1px solid var(--accent-line);
  border-radius: 20px;
  background: linear-gradient(115deg, var(--surface) 40%, rgba(36,84,240,.08));
}
.growth-affiliate .section:last-child h2 { margin-bottom: 22px; }
.growth-affiliate footer { border-color: var(--line); color: var(--ink-3); font-size: 13px; }

/* Server-rendered blog */
.growth-blog .blog-nav {
  min-height: 78px;
  gap: 28px;
  border-color: var(--line);
  background: var(--paper);
  font-size: 14px;
  font-weight: 500;
}
.growth-blog .blog-nav a { color: var(--ink-2); }
.growth-blog .blog-nav a:hover,
.growth-blog .blog-wrap a:hover { color: var(--accent); }
.growth-blog .blog-lang { display: inline-flex; gap: 6px; }
.growth-blog .blog-lang a {
  margin-left: 0;
  padding: 6px 10px;
  border: 1px solid var(--line-2);
  border-radius: 8px;
}
.growth-blog .blog-lang a:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.growth-blog .blog-wrap { max-width: 920px; padding: 66px 24px 100px; }
.growth-blog .blog-wrap > h1 { margin-bottom: 12px; font-size: clamp(38px, 5vw, 56px); letter-spacing: -.045em; }
.growth-blog .blog-wrap > .blog-muted { margin-bottom: 44px; font-size: 17px; }
.growth-blog .blog-muted { color: var(--ink-2); }
.growth-blog .blog-card {
  margin: 14px 0;
  padding: 28px 32px;
  border-color: var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: border-color .16s, transform .16s, box-shadow .16s;
}
.growth-blog .blog-card:hover { transform: translateY(-2px); border-color: var(--accent-line); box-shadow: var(--shadow); }
.growth-blog .blog-card small { color: var(--ink-3); font-family: var(--mono); font-size: 12px; }
.growth-blog .blog-card small a { color: var(--accent); }
.growth-blog .blog-card h2 { margin: 13px 0 10px; font-size: clamp(22px, 3vw, 28px); line-height: 1.3; }
.growth-blog .blog-card p { color: var(--ink-2); }
.growth-blog .blog-wrap > nav[aria-label="Pagination"] { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 32px; }
.growth-blog .blog-wrap > nav[aria-label="Pagination"] a { padding: 8px 13px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface); }
.growth-blog .blog-wrap article {
  padding: clamp(26px, 5vw, 60px);
  border-color: var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
}
.growth-blog .blog-wrap article h1 { margin: 12px 0 22px; font-size: clamp(34px, 5vw, 52px); letter-spacing: -.04em; }
.growth-blog .blog-wrap article h2 { margin: 1.8em 0 .6em; font-size: clamp(25px, 3vw, 32px); }
.growth-blog .blog-wrap article h3 { margin: 1.7em 0 .6em; font-size: 22px; }
.growth-blog .blog-wrap article p { margin: 16px 0; }
.growth-blog .blog-wrap article ul,
.growth-blog .blog-wrap article ol { padding-left: 1.5em; margin: 16px 0; }
.growth-blog .blog-wrap article a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.growth-blog .blog-wrap article nav[aria-label="Contents"] {
  margin: 32px 0;
  padding: 20px 24px;
  border-left: 3px solid var(--accent);
  border-radius: 0 10px 10px 0;
  background: var(--accent-soft);
}
.growth-blog .blog-wrap article nav[aria-label="Contents"] a { display: inline-block; margin: 4px 10px 4px 0; }
.growth-blog .blog-wrap article pre { margin: 22px 0; background: #141b2e; }
.growth-blog .blog-wrap article blockquote { margin: 22px 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--accent-line); color: var(--ink-2); }
.growth-blog .blog-wrap article img { border-radius: 10px; }
.growth-blog .blog-wrap > h2 { margin: 46px 0 18px; font-size: 28px; }

/* Signed-in partner and admin tools */
.growth-console main,
.growth-admin main { padding-top: 48px; }
.growth-console header,
.growth-admin header { padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.growth-console header h1,
.growth-admin header h1,
.growth-admin main > h1 { margin: 12px 0 8px; font-size: clamp(30px, 4vw, 40px); letter-spacing: -.04em; }
.growth-console header > a,
.growth-admin header > a { align-self: flex-start; margin-top: 8px; }
.growth-console a,
.growth-admin a { color: var(--accent); }
.growth-console a:hover,
.growth-admin a:hover { color: var(--accent-700); }
.growth-console .muted,
.growth-admin .hint { color: var(--ink-2); }
.growth-console section,
.growth-admin section {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.growth-console section h2,
.growth-admin section h2 { margin-bottom: 18px; font-size: 22px; }
.growth-console section > p,
.growth-admin section > p { color: var(--ink-2); }
.growth-console label,
.growth-admin label { color: var(--ink); font-size: 14px; }
.growth-console input,
.growth-console textarea,
.growth-console select,
.growth-admin input,
.growth-admin textarea,
.growth-admin select {
  min-height: 42px;
  border-color: var(--line-2);
  border-radius: 9px;
  background: var(--surface);
  color: var(--ink);
}
.growth-console input:focus,
.growth-console textarea:focus,
.growth-console select:focus,
.growth-admin input:focus,
.growth-admin textarea:focus,
.growth-admin select:focus { border-color: var(--accent); outline: 3px solid var(--accent-soft); }
.growth-console input[type="checkbox"],
.growth-admin input[type="checkbox"] { min-height: 0; }
.growth-console button,
.growth-admin button { border-radius: 9px; font-weight: 600; transition: background .16s, transform .16s, border-color .16s; }
.growth-console button { background: var(--accent); }
.growth-console button:hover,
.growth-admin button.primary:hover { background: var(--accent-700); transform: translateY(-1px); }
.growth-console .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.growth-console .stats div {
  min-height: 106px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-2);
  color: var(--ink-2);
  font-size: 13px;
}
.growth-console .stats strong { margin-top: 8px; color: var(--ink); font-family: var(--mono); font-size: 25px; font-weight: 600; }
.growth-console #available { color: var(--accent); }
.growth-console th,
.growth-admin th { color: var(--ink-2); font-size: 13px; font-weight: 600; background: var(--surface-2); }
.growth-console td,
.growth-console th,
.growth-admin td,
.growth-admin th { padding: 13px 12px; border-color: var(--line); }
.growth-console tbody tr:hover,
.growth-admin tbody tr:hover { background: var(--surface-2); }
.growth-console #message:not(:empty),
.growth-admin #notice:not(:empty) { padding: 10px 14px; border-radius: 9px; background: var(--accent-soft); color: var(--accent-700); }
.growth-admin button { border-color: var(--line-2); background: var(--surface); color: var(--accent); }
.growth-admin button:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.growth-admin button.primary { border-color: var(--accent); background: var(--accent); color: white; }
.growth-admin .cols { grid-template-columns: 260px minmax(0, 1fr); }
.growth-admin .cols > section:first-child { align-self: start; }
.growth-admin .toolbar { border-color: var(--line); background: var(--surface-2); }
.growth-admin .toolbar button { margin: 0; font-size: 13px; }
.growth-admin .editor { border-color: var(--line); }
.growth-admin .editor:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.growth-admin .post-row { border-color: var(--line-2); text-align: left; }
.growth-admin .post-row:hover { background: var(--accent-soft); }
.growth-admin #preview { border-color: var(--line); }

@media (max-width: 800px) {
  .growth-console .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .growth-admin .cols { grid-template-columns: 1fr; }
}
@media (max-width: 650px) {
  .growth-affiliate .wrap { padding: 0 20px; }
  .growth-affiliate .top { gap: 14px 18px; padding: 14px 0; }
  .growth-affiliate .top a:first-child { width: 100%; }
  .growth-affiliate .top .last { margin-left: 0; }
  .growth-affiliate .hero { padding: 62px 0 42px; }
  .growth-affiliate .hero h1 { font-size: clamp(37px, 10vw, 48px); }
  .growth-affiliate .hero p:not(.eyebrow) { font-size: 16px; }
  .growth-affiliate .actions { gap: 10px; }
  .growth-affiliate .numbers,
  .growth-affiliate .grid { grid-template-columns: 1fr; }
  .growth-affiliate .numbers .card { min-height: 0; }
  .growth-affiliate .section { padding-top: 54px; }
  .growth-affiliate .section:last-child { margin: 60px 0 50px; padding: 30px 24px; }
  .growth-blog .blog-nav { padding: 14px 20px; gap: 12px 18px; }
  .growth-blog .blog-nav > a:first-child { width: 100%; }
  .growth-blog .blog-nav .push { margin-left: 0; }
  .growth-blog .blog-wrap { padding: 44px 18px 70px; }
  .growth-blog .blog-card { padding: 22px; }
  .growth-console main,
  .growth-admin main { padding: 28px 16px 60px; }
  .growth-console header,
  .growth-admin header { align-items: flex-start; flex-direction: column; gap: 12px; }
  .growth-console section,
  .growth-admin section { padding: 20px; }
  .growth-console .inline { display: block; }
  .growth-console .stats { gap: 10px; }
  .growth-console .stats div { padding: 14px; }
  .growth-console .stats strong { font-size: 20px; }
}
