/* ─────────────────────────────────────────────────────────────────────────────
   ai-agents-overrides.css
   Enforces the homepage cream/dark design system across all /ai-agents/ pages.
   Overrides any residual Tailwind utility classes and inline colour tokens
   that were originally set for a dark/purple theme.
───────────────────────────────────────────────────────────────────────────── */

/* ── 1. Base Page Background & Text ── */
html, body {
  background-color: #f0ede8 !important;
  color: #111111 !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

/* ── 2. Headings → Playfair Display ── */
h1, h2, h3, h4, h5, h6,
.font-display, .font-heading, [class*="font-bold"], [class*="font-extrabold"] {
  color: #111111 !important;
}
h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif !important;
  letter-spacing: -0.02em !important;
}

/* ── 3. Tailwind Colour Overrides ── */

/* Text colours → dark neutral */
.text-white,
.text-zinc-100, .text-zinc-200, .text-zinc-300,
.text-gray-100, .text-gray-200, .text-gray-300,
.text-neutral-100, .text-neutral-200 {
  color: #111111 !important;
}

.text-zinc-400, .text-zinc-500, .text-zinc-600, .text-zinc-700,
.text-gray-400, .text-gray-500, .text-gray-600,
.text-neutral-400, .text-neutral-500 {
  color: rgba(17, 17, 17, 0.65) !important;
}

.text-zinc-800, .text-zinc-900, .text-gray-800, .text-gray-900 {
  color: #111111 !important;
}

/* Purple brand → teal accent */
.text-\[\#6c47ff\], .text-\[\#7c5cff\], .text-\[\#8b5cf6\],
.text-purple-600, .text-purple-500, .text-purple-400,
.text-violet-600, .text-violet-500, .text-indigo-600, .text-indigo-500,
[class*="text-\[#6c47ff\]"], [class*="text-\[#7c5c"] {
  color: #0d9488 !important;
}

/* Background overrides */
.bg-zinc-900, .bg-zinc-800, .bg-neutral-900, .bg-neutral-800,
.bg-gray-900, .bg-gray-800, .bg-black {
  background-color: #f0ede8 !important;
}

.bg-zinc-50, .bg-zinc-100, .bg-gray-50, .bg-gray-100,
.bg-neutral-50, .bg-neutral-100 {
  background-color: #e8e4dd !important;
}

.bg-white { background-color: #ffffff !important; }

/* Purple bg → light cream */
.bg-\[\#6c47ff\], .bg-\[\#7c5cff\],
.bg-purple-600, .bg-purple-500, .bg-purple-100, .bg-purple-50,
.bg-violet-600, .bg-violet-500,
.bg-indigo-600, .bg-indigo-500, .bg-indigo-100, .bg-indigo-50 {
  background-color: rgba(13, 148, 136, 0.08) !important;
  color: #0d9488 !important;
}

/* Purple bg with opacity notations */
[class*="bg-\[#6c47ff\]\/"],
[class*="bg-\[#7c5c"],
[class*="bg-purple-"],
[class*="bg-indigo-"],
[class*="bg-violet-"] {
  background-color: rgba(13, 148, 136, 0.06) !important;
}

/* ── 4. Border Colours ── */
.border-zinc-700, .border-zinc-800, .border-zinc-900,
.border-white, .border-white\/10, .border-white\/20,
.border-white\/30 {
  border-color: rgba(0, 0, 0, 0.12) !important;
}

.border-purple-600, .border-indigo-600, .border-violet-600,
.border-\[\#6c47ff\], .border-\[\#7c5cff\] {
  border-color: rgba(13, 148, 136, 0.3) !important;
}

/* ── 5. Gradient Text → Dark Editorial ── */
.gradient-text,
.grad-text,
[class*="bg-gradient-to-r"],
[class*="bg-clip-text"] {
  background: linear-gradient(120deg, #111111 0%, #333333 100%) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  background-clip: text !important;
}

/* But keep teal accent elements clearly teal */
.text-teal-600, .text-teal-500, .text-teal-400 {
  color: #0d9488 !important;
  -webkit-text-fill-color: #0d9488 !important;
}
.text-amber-600, .text-amber-500, .text-amber-400 {
  color: #d97706 !important;
  -webkit-text-fill-color: #d97706 !important;
}

/* ── 6. Section / Layout Backgrounds ── */
section {
  background-color: #f0ede8 !important;
}
/* Alternate sections */
section:nth-of-type(even) {
  background-color: #e8e4dd !important;
}

/* Override bg-section-light, bg-section-gray if from light-overrides */
.bg-section-light, .bg-section-gray { background-color: #e8e4dd !important; }
.bg-primary-bg { background-color: #f0ede8 !important; }

/* ── 7. Feature Cards → White with border ── */
.feature-card,
.card,
.solution-card,
.problem-card,
.workflow-step,
.case-study-card,
.faq-card-bg,
.prompt-box {
  background: #ffffff !important;
  background-color: #ffffff !important;
  border: 1px solid rgba(0, 0, 0, 0.10) !important;
  border-radius: 6px !important;
  color: #111111 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03) !important;
}

/* ── 8. Step Numbers → Dark square ── */
.step-num {
  background: #111111 !important;
  color: #ffffff !important;
  border-radius: 4px !important;
}

/* ── 9. Icon containers → Neutral ── */
.icon-container, .ic-purple, .stat-icon {
  background: rgba(0, 0, 0, 0.05) !important;
  color: #111111 !important;
  border-radius: 4px !important;
}
.icon { color: #111111 !important; }

/* ── 10. Buttons → Sharp system ── */
.button-primary,
a.button-primary,
button.button-primary {
  background: #111111 !important;
  color: #f0ede8 !important;
  border: 1.5px solid #111111 !important;
  border-radius: 4px !important;
  box-shadow: none !important;
}
.button-primary:hover {
  background: #2d2d2d !important;
  border-color: #2d2d2d !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15) !important;
}

.button-secondary,
a.button-secondary,
button.button-secondary {
  background: transparent !important;
  color: #111111 !important;
  border: 1.5px solid rgba(0, 0, 0, 0.22) !important;
  border-radius: 4px !important;
}
.button-secondary:hover {
  background: rgba(0, 0, 0, 0.05) !important;
  border-color: rgba(0, 0, 0, 0.5) !important;
}

/* Teal CTA accent */
.btn-teal, a.btn-teal {
  background: #0d9488 !important;
  color: #ffffff !important;
  border-color: #0d9488 !important;
  border-radius: 4px !important;
}
.btn-teal:hover {
  background: #0f766e !important;
  border-color: #0f766e !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 6px 20px rgba(13, 148, 136, 0.25) !important;
}

/* Remove glowing purple buttons */
[class*="bg-gradient-to"][class*="purple"],
[class*="bg-gradient-to"][class*="indigo"] {
  background: #111111 !important;
  background-image: none !important;
  color: #f0ede8 !important;
}

/* Rounded pills → sharp corners */
.rounded-full:not(img):not(video):not(.online-dot):not(.wave-bar):not(.track-bar-fill) {
  border-radius: 4px !important;
}
.rounded-xl, .rounded-2xl, .rounded-3xl {
  border-radius: 6px !important;
}
.rounded-lg { border-radius: 6px !important; }
.rounded-md { border-radius: 4px !important; }

/* ── 11. Tags & Badges ── */
.section-title,
.badge,
.tag,
.badge-pill,
.leak-badge,
.agency-badge-pill,
.tag-badge-light,
.user-badge-light,
.section-eyebrow,
[class*="badge"],
[class*="-badge"] {
  background: rgba(0, 0, 0, 0.04) !important;
  border: 1px solid rgba(0, 0, 0, 0.15) !important;
  color: #111111 !important;
  border-radius: 4px !important;
  font-family: 'Inter', sans-serif !important;
}

/* ── 12. Subtext classes ── */
.subtext-light-md, .subtext-light-xs, .hero-subtitle, .section-desc {
  color: rgba(17, 17, 17, 0.65) !important;
}

/* ── 13. Stats & Metrics containers ── */
.metrics-card-white, .stats-container-outline {
  background: #ffffff !important;
  border: 1px solid rgba(0, 0, 0, 0.10) !important;
  color: #111111 !important;
}
.stats-container-outline { border-radius: 6px !important; }

/* Stat gradient numbers → teal or amber */
.stats-container-outline .gradient-text,
.metric-card .gradient-text {
  background: linear-gradient(120deg, #0d9488, #d97706) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  background-clip: text !important;
}

/* ── 14. Prompt / Code Box ── */
.prompt-box {
  background: #ffffff !important;
  border: 1.5px solid rgba(0, 0, 0, 0.15) !important;
}
.prompt-cursor { background: #111111 !important; }
#typed-text { color: #111111 !important; }

/* ── 15. Chat Bubbles ── */
.chat-bot {
  background: rgba(0, 0, 0, 0.04) !important;
  border: 1px solid rgba(0, 0, 0, 0.10) !important;
  color: #111111 !important;
  border-radius: 4px !important;
}
.chat-user {
  background: #ffffff !important;
  border: 1px solid rgba(0, 0, 0, 0.10) !important;
  color: #111111 !important;
  border-radius: 4px !important;
}

/* ── 16. FAQ Items ── */
.faq-q, .faq-card, .faq-item {
  background: #ffffff !important;
  border: 1px solid rgba(0, 0, 0, 0.10) !important;
  border-radius: 6px !important;
  color: #111111 !important;
}
.faq-a p { color: rgba(17, 17, 17, 0.7) !important; }

/* ── 17. Table Styles ── */
table thead th {
  background: #e8e4dd !important;
  color: #111111 !important;
  border-color: rgba(0, 0, 0, 0.10) !important;
}
table tbody td {
  background: #ffffff !important;
  color: #111111 !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
}
table tbody tr:nth-child(even) td {
  background: #f8f5f0 !important;
}

/* ── 18. Dividers & Borders ── */
.border-zinc-200, .border-zinc-700, .border-zinc-800,
.border-gray-200, .border-gray-700, .divide-zinc-800,
.divide-white\/10 {
  border-color: rgba(0, 0, 0, 0.10) !important;
}

/* ── 19. Workflow arrow connectors ── */
.workflow-arrow, .text-purple-lg, .tag-purple-caps, .mono-purple-caps {
  color: rgba(17, 17, 17, 0.4) !important;
}

/* ── 20. Links inside content ── */
main a[href*="#"]:not(.button-primary):not(.button-secondary):not([class*="btn"]),
main a[href^="/ai-agents"]:not([class*="btn"]):not([class*="button"]) {
  color: #0d9488 !important;
  text-decoration: none !important;
}
main a[href^="/ai-agents"]:hover:not([class*="btn"]) {
  color: #0f766e !important;
  text-decoration: underline !important;
}

/* ── 21. Remove dark glow radial effects ── */
.radial-blur-glow,
[class*="radial-blur"],
[class*="animate-pulse-slow"] {
  opacity: 0 !important;
  display: none !important;
}

/* ── 22. Opacity / Transparency fixes ── */
.opacity-5, .opacity-8 { opacity: 0 !important; } /* remove dark bg blobs */

/* ── 23. Hero grid bg → subtle cream lines ── */
.hero-grid-bg {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.05) 1px, transparent 1px) !important;
  background-size: 60px 60px !important;
  opacity: 0.6 !important;
}

/* ── 24. Section eyebrow tag ── */
.section-eyebrow {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0d9488 !important;
  background: rgba(13, 148, 136, 0.07) !important;
  border: 1px solid rgba(13, 148, 136, 0.2) !important;
  padding: 4px 12px;
  border-radius: 4px !important;
  margin-bottom: 16px;
}

/* Override inline text-[#6c47ff] links — Tailwind JIT arbitrary values */
[style*="color: rgb(108, 71, 255)"],
[style*="color:#6c47ff"],
[style*="color: #6c47ff"] {
  color: #0d9488 !important;
}

/* ── 25. Ensure no dark backgrounds sneak in on hero ── */
.min-h-screen, .relative.min-h-screen {
  background-color: transparent !important;
}
