/*
THESIS: OJay articles read like one calm operating manual, not a collection of campaign microsites.
OWN-WORLD: Near-black fields, white editorial type, hot-pink actions, fine rules, and compact operational panels.
STORY: Understand the topic, scan the takeaways, inspect the evidence, then choose the OJay process or application.
FIRST VIEWPORT: A restrained persistent bar leads into the article hero; desktop keeps TOC, reading column, and action rail visible.
FORM: SEED[user-approved-client-acquisition-template] - the approved Jeremy Haynes-inspired three-column reading structure, extended across the blog without copying his visual identity.
*/

:root {
  --ojay-canvas: #030305;
  --ojay-surface: #0c0c11;
  --ojay-surface-raised: #14131a;
  --ojay-ink: #ffffff;
  --ojay-muted: rgba(255, 255, 255, 0.7);
  --ojay-quiet: rgba(255, 255, 255, 0.48);
  --ojay-line: rgba(255, 255, 255, 0.12);
  --ojay-accent: #ff2d95;
  --ojay-accent-hover: #ff58aa;
  --ojay-focus: #ffd0e7;
  --ojay-radius: 16px;
  --ojay-header-height: 72px;
}

.ojay-blog-system {
  background: var(--ojay-canvas);
  color: var(--ojay-ink);
  overflow-x: clip;
}

.ojay-blog-system *,
.ojay-blog-system *::before,
.ojay-blog-system *::after {
  box-sizing: border-box;
}

.ojay-blog-system img,
.ojay-blog-system svg,
.ojay-blog-system video,
.ojay-blog-system iframe {
  max-width: 100%;
}

.ojay-blog-system .hero {
  background: var(--ojay-canvas) !important;
}

.ojay-blog-system .morph-canvas,
.ojay-blog-system .grid-overlay,
.ojay-blog-system .noise-texture {
  display: none !important;
}

.ojay-blog-system .hero::before,
.ojay-blog-system .hero::after {
  display: none !important;
}

.ojay-blog-system .hero h1,
.ojay-blog-system .hero h1 * {
  background: none !important;
  color: var(--ojay-ink) !important;
  -webkit-text-fill-color: var(--ojay-ink) !important;
}

.ojay-blog-system .hero .breadcrumb,
.ojay-blog-system .hero .breadcrumbs {
  display: none !important;
}

@media (min-width: 901px) {
  .ojay-blog-system .hero,
  .ojay-blog-system .hero-inner {
    max-width: 1060px !important;
    margin-inline: auto !important;
    text-align: center !important;
  }

  .ojay-blog-system .hero .byline,
  .ojay-blog-system .hero .hero-meta,
  .ojay-blog-system .hero .meta-row {
    justify-content: center !important;
  }

  .ojay-blog-system .hero .hero-rule {
    margin-inline: auto !important;
  }
}

.ojay-blog-system .author-avatar img.avatar {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 24%;
}

.ojay-author-card {
  width: min(720px, calc(100% - 2rem));
  margin: clamp(2.75rem, 6vw, 5rem) auto 0;
  padding: clamp(1.25rem, 3vw, 1.6rem);
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  align-items: start;
  gap: 1.15rem;
  border: 1px solid var(--ojay-line);
  border-radius: var(--ojay-radius);
  background: var(--ojay-surface);
  color: var(--ojay-muted);
  font-family: Inter, system-ui, sans-serif;
}

.ojay-author-photo {
  width: 84px;
  height: 84px;
  display: block;
  border: 1px solid rgba(255, 45, 149, 0.48);
  border-radius: 50%;
  object-fit: cover;
  object-position: center 24%;
}

.ojay-author-copy {
  min-width: 0;
}

.ojay-author-card h2 {
  margin: 0 0 0.2rem !important;
  color: var(--ojay-ink) !important;
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-size: 1.18rem !important;
  line-height: 1.2 !important;
  letter-spacing: -0.02em;
}

.ojay-author-card p {
  margin: 0 !important;
  color: var(--ojay-muted) !important;
  font-size: 0.9rem !important;
  line-height: 1.58 !important;
}

.ojay-author-card .ojay-author-role {
  margin-bottom: 0.55rem !important;
  color: rgba(255, 255, 255, 0.84) !important;
  font-size: 0.78rem !important;
  font-weight: 700;
}

.ojay-blog-system .table-wrap,
.ojay-blog-system .table-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  -webkit-overflow-scrolling: touch;
}

.ojay-blog-system pre {
  max-width: 100%;
  overflow-x: auto;
}

.ojay-blog-system :not(pre) > code {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.ojay-blog-system a:focus-visible,
.ojay-blog-system button:focus-visible,
.ojay-blog-system input:focus-visible,
.ojay-blog-system dialog:focus-visible {
  outline: 3px solid var(--ojay-focus);
  outline-offset: 3px;
}

.blog-global-header {
  position: sticky;
  inset: 0 0 auto;
  z-index: 1000;
  min-height: var(--ojay-header-height);
  border-bottom: 1px solid var(--ojay-line);
  background: rgba(3, 3, 5, 0.94);
  backdrop-filter: blur(18px);
}

.blog-global-header.scrolled {
  background: rgba(3, 3, 5, 0.985);
}

.blog-header-inner {
  width: min(1440px, 100%);
  min-height: var(--ojay-header-height);
  margin: 0 auto;
  padding: 0 clamp(1rem, 3vw, 2.5rem);
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 2rem);
}

.blog-wordmark {
  flex: 0 0 auto;
  color: var(--ojay-ink) !important;
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-size: 1rem;
  font-weight: 750;
  letter-spacing: -0.025em;
  text-decoration: none !important;
}

.blog-global-nav {
  min-width: 0;
  margin-left: auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(0.85rem, 1.8vw, 1.5rem);
}

.blog-global-nav > a {
  color: var(--ojay-muted) !important;
  font-family: Inter, system-ui, sans-serif;
  font-size: 0.82rem;
  font-weight: 650;
  line-height: 1.25;
  text-decoration: none !important;
  white-space: nowrap;
}

.blog-global-nav > a:hover {
  color: var(--ojay-ink) !important;
}

.blog-global-nav .blog-header-action {
  min-height: 42px;
  padding: 0.65rem 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ojay-line);
  border-radius: 999px;
  color: var(--ojay-ink) !important;
}

.blog-global-nav .blog-header-action.primary {
  border-color: var(--ojay-accent);
  background: var(--ojay-accent);
}

.blog-global-nav .blog-header-action.primary:hover {
  background: var(--ojay-accent-hover);
}

.blog-menu-toggle {
  min-width: 44px;
  min-height: 44px;
  margin-left: auto;
  padding: 0.55rem 0.8rem;
  display: none;
  border: 1px solid var(--ojay-line);
  border-radius: 999px;
  background: transparent;
  color: var(--ojay-ink);
  font: 700 0.8rem/1 Inter, system-ui, sans-serif;
  cursor: pointer;
}

.ojay-blog-system .article-wrap {
  width: min(1440px, 100%);
  max-width: 1440px;
  padding-inline: clamp(1rem, 3vw, 2.5rem);
  display: grid;
  grid-template-columns: minmax(170px, 210px) minmax(0, 720px) minmax(260px, 310px);
  justify-content: center;
  align-items: start;
  gap: clamp(1.5rem, 3vw, 3rem);
}

.ojay-blog-system .article-wrap > *,
.ojay-blog-system .page-grid > * {
  min-width: 0;
}

.ojay-blog-system .article-wrap > .toc {
  top: calc(var(--ojay-header-height) + 24px);
}

.ojay-blog-system .prose,
.ojay-blog-system .article {
  width: 100%;
  max-width: 720px;
}

.ojay-rail {
  position: sticky;
  top: calc(var(--ojay-header-height) + 24px);
  min-width: 0;
  display: grid;
  gap: 1rem;
  color: var(--ojay-muted);
  font-family: Inter, system-ui, sans-serif;
}

.ojay-rail-card {
  min-width: 0;
  padding: 1.15rem;
  overflow: hidden;
  border: 1px solid var(--ojay-line);
  border-radius: var(--ojay-radius);
  background: var(--ojay-surface);
}

.ojay-rail-card.primary {
  border-color: rgba(255, 45, 149, 0.42);
  background: #161018;
}

.ojay-rail-card h2 {
  margin: 0 0 0.65rem;
  color: var(--ojay-ink);
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-size: 1.22rem;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.ojay-rail-card p {
  margin: 0 0 0.9rem;
  color: var(--ojay-muted);
  font-size: 0.84rem;
  line-height: 1.48;
}

.ojay-lead-form {
  display: grid;
  gap: 0.65rem;
}

.ojay-lead-form label:not(.ojay-consent) {
  display: grid;
  gap: 0.3rem;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.74rem;
  font-weight: 700;
}

.ojay-lead-form input[type="text"],
.ojay-lead-form input[type="email"] {
  width: 100%;
  min-height: 46px;
  padding: 0.68rem 0.78rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ojay-ink);
  font: inherit;
}

.ojay-lead-form input::placeholder {
  color: rgba(255, 255, 255, 0.52);
}

.ojay-consent {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.68rem;
  line-height: 1.4;
}

.ojay-consent input {
  flex: 0 0 auto;
  margin-top: 0.2rem;
}

.ojay-honeypot {
  position: absolute !important;
  left: -100vw !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

.ojay-button,
.ojay-lead-form button {
  min-height: 46px;
  padding: 0.72rem 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ojay-line);
  border-radius: 999px;
  background: transparent;
  color: var(--ojay-ink) !important;
  font: 800 0.8rem/1.25 Inter, system-ui, sans-serif;
  text-align: center;
  text-decoration: none !important;
  cursor: pointer;
}

.ojay-button.primary,
.ojay-lead-form button {
  border-color: var(--ojay-accent);
  background: var(--ojay-accent);
}

.ojay-button.primary:hover,
.ojay-lead-form button:hover {
  background: var(--ojay-accent-hover);
}

.ojay-button + .ojay-button {
  margin-top: 0.62rem;
}

.ojay-form-status {
  min-height: 1.2em;
  margin: 0 !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-size: 0.72rem !important;
}

.ojay-takeaways {
  margin: 1.7rem 0 2.6rem;
  padding: clamp(1rem, 2.5vw, 1.45rem);
  border: 1px solid rgba(255, 45, 149, 0.34);
  border-radius: var(--ojay-radius);
  background: rgba(255, 45, 149, 0.055);
}

.ojay-takeaways h2 {
  margin: 0 0 0.8rem !important;
  font-size: 1.3rem !important;
}

.ojay-takeaways ul {
  margin: 0;
}

.ojay-faq {
  margin-top: 4rem;
}

.ojay-faq details {
  border-top: 1px solid var(--ojay-line);
}

.ojay-faq details:last-child {
  border-bottom: 1px solid var(--ojay-line);
}

.ojay-faq summary {
  min-height: 52px;
  padding: 0.9rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--ojay-ink);
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-weight: 650;
  cursor: pointer;
}

.ojay-faq details > div {
  padding: 0 0 1.1rem;
  color: var(--ojay-muted);
}

.ojay-bottom-cta {
  width: min(1180px, calc(100% - 2rem));
  margin: clamp(3.5rem, 7vw, 7rem) auto;
  padding: clamp(2rem, 5vw, 4.8rem);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 45, 149, 0.36);
  border-radius: 24px;
  background: #130d15;
  text-align: center;
}

.ojay-bottom-cta::after {
  content: "";
  position: absolute;
  width: 280px;
  height: 280px;
  right: -160px;
  bottom: -190px;
  border-radius: 50%;
  background: rgba(255, 45, 149, 0.18);
  filter: blur(30px);
  pointer-events: none;
}

.ojay-bottom-cta h2 {
  max-width: 820px;
  margin: 0 auto 1rem;
  color: var(--ojay-ink);
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.ojay-bottom-cta p {
  max-width: 720px;
  margin: 0 auto;
  color: var(--ojay-muted);
  font: 400 clamp(1rem, 1.7vw, 1.15rem)/1.55 Inter, system-ui, sans-serif;
}

.ojay-bottom-actions {
  margin-top: 1.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.ojay-bottom-actions .ojay-button {
  min-width: 210px;
  margin: 0;
}

.ojay-bottom-note {
  margin-top: 1rem !important;
  color: var(--ojay-quiet) !important;
  font-size: 0.76rem !important;
}

.ojay-email-dialog {
  width: min(520px, calc(100% - 2rem));
  max-height: min(760px, calc(100dvh - 2rem));
  padding: 0;
  overflow: auto;
  border: 1px solid rgba(255, 45, 149, 0.42);
  border-radius: 20px;
  background: #0d0c11;
  color: var(--ojay-ink);
}

.ojay-email-dialog::backdrop {
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(5px);
}

.ojay-dialog-inner {
  padding: clamp(1.25rem, 4vw, 2rem);
}

.ojay-dialog-close {
  width: 44px;
  height: 44px;
  margin-left: auto;
  display: grid;
  place-items: center;
  border: 1px solid var(--ojay-line);
  border-radius: 999px;
  background: transparent;
  color: var(--ojay-ink);
  font: 700 1rem/1 Inter, system-ui, sans-serif;
  cursor: pointer;
}

.ojay-email-dialog h2 {
  margin: 0.8rem 0 0.7rem;
  color: var(--ojay-ink);
  font-family: Outfit, Inter, system-ui, sans-serif;
  font-size: clamp(1.7rem, 5vw, 2.5rem);
  line-height: 1.05;
  letter-spacing: -0.035em;
}

.ojay-email-dialog p {
  color: var(--ojay-muted);
  font-family: Inter, system-ui, sans-serif;
}

@media (max-width: 1120px) {
  .ojay-blog-system .article-wrap {
    grid-template-columns: minmax(155px, 190px) minmax(0, 1fr) minmax(235px, 275px);
    gap: 1.3rem;
  }

  .blog-global-nav > a:not(.blog-header-action) {
    display: none;
  }
}

@media (max-width: 900px) {
  :root {
    --ojay-header-height: 64px;
  }

  .blog-header-inner {
    position: relative;
    min-height: var(--ojay-header-height);
  }

  .blog-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .blog-global-nav {
    position: absolute;
    top: calc(100% + 1px);
    left: 0.75rem;
    right: 0.75rem;
    padding: 0.8rem;
    display: none;
    align-items: stretch;
    border: 1px solid var(--ojay-line);
    border-radius: 14px;
    background: #0b0a0e;
  }

  .blog-global-header[data-menu-open="true"] .blog-global-nav {
    display: grid;
  }

  .blog-global-nav > a,
  .blog-global-nav > a:not(.blog-header-action) {
    min-height: 44px;
    padding: 0.7rem 0.8rem;
    display: flex;
    align-items: center;
    border-radius: 10px;
    white-space: normal;
  }

  .ojay-blog-system .article-wrap,
  .ojay-blog-system .page-grid {
    display: block;
  }

  .ojay-rail {
    position: static;
    margin-top: 3rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ojay-rail-card.primary {
    grid-column: 1 / -1;
  }
}

@media (max-width: 600px) {
  .ojay-blog-system {
    overflow-wrap: anywhere;
  }

  .ojay-rail {
    grid-template-columns: 1fr;
  }

  .ojay-rail-card.primary {
    grid-column: auto;
  }

  .ojay-bottom-cta {
    width: min(100% - 1.25rem, 1180px);
    padding: 2.25rem 1rem;
    border-radius: 18px;
  }

  .ojay-bottom-actions {
    display: grid;
  }

  .ojay-bottom-actions .ojay-button {
    width: 100%;
    min-width: 0;
  }

  .ojay-email-dialog {
    width: calc(100% - 1rem);
    max-height: calc(100dvh - 1rem);
  }

  .ojay-author-card {
    width: calc(100% - 1.25rem);
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 0.9rem;
    padding: 1rem;
  }

  .ojay-author-photo {
    width: 64px;
    height: 64px;
  }
}

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