/* ============================================
   NEURALSHEEP LM — Global Stylesheet
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

/* ---- CSS Variables ---- */
:root {
  --bg-primary:    #FDFBF7;
  --bg-secondary:  #F3EDE2;
  --bg-elevated:   #E6DEC8;
  --accent:        #C85A32;
  --accent-hover:  #FF6600;
  --ink:           #141413;
  --body-text:     #4A453E;
  --divider:       #DCD4C6;
  --border-dark:   #141413;
  --white:         #FDFBF7;

  --font-heading:  'Space Grotesk', 'Plus Jakarta Sans', sans-serif;
  --font-body:     'Inter', sans-serif;
  --font-mono:     'JetBrains Mono', 'Courier New', monospace;

  --radius:        6px;
  --max-width:     1200px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  background-color: var(--bg-primary);
  color: var(--body-text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a svg { pointer-events: none; }
ul { list-style: none; }

/* ---- Typography ---- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.2;
}
h1 { font-size: clamp(2.2rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.75rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.15rem; }
p  { font-size: 1rem; color: var(--body-text); line-height: 1.7; }


/* ---- Layout ---- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}
.section { padding: 5rem 0; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  border-radius: var(--radius);
  padding: 0.72rem 1.5rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s, color 0.18s;
  white-space: nowrap;
}
.btn-primary,
.btn-invert {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
}
.btn-primary:hover,
.btn-invert:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--border-dark);
}
.btn-secondary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-ghost-invert {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}
.btn-ghost-invert:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }

/* ---- Navigation ---- */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #F3EDE2;
  border-bottom: 1px solid var(--divider);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}
.nav-logo img { width: 36px; height: 36px; object-fit: contain; }
.nav-logo-text {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--ink);
  letter-spacing: -0.01em;
  line-height: 1.1;
}
.nav-logo-text span { display: block; font-size: 0.65rem; font-weight: 500; color: var(--body-text); letter-spacing: 0.08em; text-transform: uppercase; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.nav-links a {
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--body-text);
  transition: color 0.15s;
  position: relative;
}
.nav-links a:hover, .nav-links a.active { color: var(--accent-hover); }
.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0; right: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
}
.nav-cta { margin-left: 1rem; }
.nav-mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
  flex-direction: column;
  gap: 5px;
}
.nav-mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  border-radius: 1px;
  transition: all 0.2s;
}
.nav-mobile { display: none; }

/* ---- Hero ---- */
.hero {
  padding: 6rem 0 5rem;
  background: linear-gradient(180deg, #F3EDE2 0%, #FDFBF7 100%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 4rem;
  align-items: center;
}
.hero-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 1.5rem;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 2rem; }
.hero-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--divider);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 2.5rem;
}
.hero-stat {
  background: var(--bg-secondary);
  padding: 1.25rem 1.5rem;
}
.hero-stat-num {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.75rem;
  color: var(--accent);
  letter-spacing: -0.02em;
}
.hero-stat-label {
  font-size: 0.8rem;
  color: var(--body-text);
  margin-top: 0.1rem;
}
.hero-visual {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  padding: 2rem;
}

/* ---- Section Headers ---- */
.section-header { margin-bottom: 3rem; }
.section-header h2 { margin-bottom: 0.75rem; }
.section-header p { max-width: 600px; }
.section-header.center { text-align: center; }
.section-header.center p { margin: 0 auto; }

/* ---- Cards ---- */
.card {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  padding: 2rem;
  transition: background 0.18s, border-color 0.18s;
}
.card:hover { background: var(--bg-elevated); border-color: var(--border-dark); }
.card-icon {
  width: 42px;
  height: 42px;
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  background: var(--bg-primary);
}
.card-icon svg { width: 20px; height: 20px; stroke: var(--accent); fill: none; stroke-width: 1.8; }

/* ---- Grid layouts ---- */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }

/* ---- Divider ---- */
.divider { border: none; border-top: 1px solid var(--divider); margin: 0; }

/* ---- Tags / Badges ---- */
.badge {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink);
}
.badge-accent { color: var(--accent); }

/* ---- Contrast (dark) sections ---- */
.contrast-section {
  background: var(--ink);
  color: var(--white);
  padding: 5rem 0;
}
.contrast-section h1,
.contrast-section h2,
.contrast-section h3,
.contrast-section h4 { color: var(--white); }
.contrast-section p { color: rgba(253,251,247,0.78); }
.contrast-section .eyebrow { color: var(--accent); }
.contrast-section .divider { border-color: rgba(253,251,247,0.12); }

/* ---- Footer ---- */
.footer {
  background: var(--ink);
  color: var(--white);
  padding: 4rem 0 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(253,251,247,0.12);
  margin-bottom: 2rem;
}
.footer h4 {
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1.25rem;
}
.footer-links li { margin-bottom: 0.6rem; }
.footer-links a {
  font-size: 0.88rem;
  color: rgba(253,251,247,0.65);
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--accent-hover); }
.footer-logo-text { color: var(--white); font-family: var(--font-heading); font-weight: 700; font-size: 1.05rem; }
.footer-logo-text span { display: block; font-size: 0.65rem; font-weight: 500; color: rgba(253,251,247,0.5); letter-spacing: 0.08em; text-transform: uppercase; }
.footer-desc { font-size: 0.88rem; color: rgba(253,251,247,0.65); margin-top: 0.75rem; line-height: 1.6; }
.footer-social { display: flex; gap: 0.75rem; margin-top: 1.25rem; }
.footer-social a {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(253,251,247,0.2);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s, background 0.15s;
}
.footer-social a:hover { border-color: var(--accent); background: rgba(200,90,50,0.15); }
.footer-social svg { width: 16px; height: 16px; stroke: rgba(253,251,247,0.65); fill: none; stroke-width: 1.8; }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: rgba(253,251,247,0.4);
}
.footer-bottom-links { display: flex; gap: 1.5rem; }
.footer-bottom-links a { color: rgba(253,251,247,0.4); transition: color 0.15s; }
.footer-bottom-links a:hover { color: var(--accent-hover); }

/* ---- Accordion / FAQ ---- */
.accordion { border-top: 1px solid var(--divider); }
.accordion-item { border-bottom: 1px solid var(--divider); }
.accordion-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 0;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  gap: 1rem;
}
.accordion-trigger span {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: var(--ink);
}
.accordion-icon {
  width: 22px;
  height: 22px;
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.15s;
  font-size: 1rem;
  color: var(--accent);
}
.accordion-trigger[aria-expanded="true"] .accordion-icon { background: var(--accent); color: var(--white); border-color: var(--accent); }
.accordion-body { display: none; padding-bottom: 1.25rem; }
.accordion-body p { font-size: 0.95rem; }
.accordion-body.open { display: block; }

/* ---- Process steps ---- */
.process-steps { counter-reset: step; }
.process-step {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 1.5rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--divider);
}
.process-step:last-child { border-bottom: none; }
.step-num {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
  line-height: 1;
  padding-top: 0.2rem;
  min-width: 36px;
}

/* ---- Page hero (inner pages) ---- */
.page-hero {
  padding: 4rem 0 3.5rem;
  background: linear-gradient(180deg, #F3EDE2 0%, #FDFBF7 100%);
}
.page-hero-nav {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}
.page-hero-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink);
  background: var(--bg-primary);
  border: 1px solid var(--divider);
  border-radius: 999px;
  padding: 0.4rem 1rem;
  transition: border-color 0.15s, background 0.15s;
}
.page-hero-nav a:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--bg-secondary);
}
.page-hero-nav a .nav-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--accent);
}

/* ---- Breadcrumb ---- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--body-text);
  margin-bottom: 1.5rem;
  opacity: 0.7;
}
.breadcrumb a:hover { color: var(--accent-hover); }
.breadcrumb-sep { opacity: 0.4; }

/* ---- Table ---- */
.ns-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.ns-table th {
  background: #1a1a18;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #ffffff;
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: none;
}
.ns-table th:not(:first-child) { text-align: center; }
.ns-table td {
  padding: 0.7rem 1.25rem;
  border-bottom: 1px solid var(--divider);
  vertical-align: middle;
  font-size: 0.88rem;
  color: var(--ink);
}
.ns-table td:not(:first-child) { text-align: center; }
.ns-table tr:last-child td { border-bottom: none; }
.ns-table tbody tr:hover:not(.table-group-header) td { background: #f7f3ec; }
.ns-table .table-group-header > td {
  background: #C85A32 !important;
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #ffffff !important;
  padding: 0.4rem 1.25rem;
  border-top: none;
  border-bottom: none;
}
.ns-table .check-cell { color: #16a34a; line-height: 1; }
.ns-table .cross-cell { color: #dc2626; line-height: 1; }

/* ---- Forms ---- */
.form-group { margin-bottom: 1.25rem; }
.form-label { display: block; font-size: 0.85rem; font-weight: 500; color: var(--ink); margin-bottom: 0.4rem; }
.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 0.72rem 1rem;
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s;
}
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--accent); }
.form-textarea { resize: vertical; min-height: 120px; }
.form-select { cursor: pointer; }
.form-input-error { border-color: #dc2626 !important; }
.form-error { display: block; font-size: 0.78rem; color: #dc2626; margin-top: 0.3rem; }

/* ---- Contact info cards (hover via CSS — no inline event handlers) ---- */
.contact-info-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  transition: border-color 0.15s;
  text-decoration: none;
  color: inherit;
}
.contact-info-card:hover { border-color: var(--accent); }

/* ---- Pricing cards ---- */
.pricing-card {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
}
.pricing-card.featured { border-color: var(--accent); }
.pricing-card-header { margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--divider); }
.pricing-tier {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 0.75rem;
  display: block;
}
.pricing-price {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 2rem;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.pricing-price-note { font-size: 0.82rem; color: var(--body-text); margin-top: 0.3rem; }
.pricing-features { flex: 1; margin-bottom: 2rem; }
.pricing-features-group { margin-bottom: 1.5rem; }
.pricing-features-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--body-text);
  margin-bottom: 0.75rem;
  display: block;
}
.pricing-feature-item {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  margin-bottom: 0.5rem;
  font-size: 0.88rem;
  color: var(--body-text);
}
.pricing-feature-item::before {
  content: '';
  display: block;
  width: 5px;
  height: 5px;
  min-width: 5px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 0.52rem;
}
.pricing-more { font-size: 0.8rem; color: var(--body-text); font-style: italic; opacity: 0.7; margin-top: 0.25rem; padding-left: 1.1rem; }

/* ---- Chatbot ---- */
.chatbot-toggle {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  z-index: 9999;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  transition: background 0.18s, transform 0.18s;
}
#chatbot-badge {
  position: absolute !important;
  top: -4px !important;
  right: -4px !important;
  pointer-events: none;
}
.chatbot-toggle:hover { background: var(--accent-hover); }
.chatbot-toggle img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.chatbot-window {
  position: fixed;
  bottom: 5.5rem;
  right: 1.75rem;
  z-index: 9998;
  width: 350px;
  max-height: 540px;
  background: #FDFBF7;
  border: 1px solid #DCD4C6;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  display: none;
  box-shadow: 0 8px 32px rgba(20,20,19,0.14), 0 2px 8px rgba(20,20,19,0.08);
  overflow: hidden;
}
.chatbot-window.open { display: flex; }
.chatbot-header {
  background: linear-gradient(135deg, #1a1a18 0%, #2d2d2a 100%);
  color: #FDFBF7;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}
.chatbot-header img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid rgba(200,90,50,0.6);
  box-shadow: 0 0 0 3px rgba(200,90,50,0.15);
}
.chatbot-header-info { flex: 1; }
.chatbot-header-name { font-family: var(--font-heading); font-weight: 700; font-size: 0.92rem; color: #FDFBF7; }
.chatbot-header-status {
  font-size: 0.7rem;
  color: rgba(253,251,247,0.65);
  display: flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.1rem;
}
.chatbot-header-status::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  flex-shrink: 0;
}
.chatbot-close {
  background: rgba(253,251,247,0.08);
  border: 1px solid rgba(253,251,247,0.12);
  color: rgba(253,251,247,0.7);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.chatbot-close:hover { background: rgba(253,251,247,0.18); color: #FDFBF7; }
.chatbot-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1.1rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  max-height: 340px;
  background: #F7F2EA;
}
.chat-msg { max-width: 82%; }
.chat-msg.bot { align-self: flex-start; }
.chat-msg.user { align-self: flex-end; }
.chat-bubble {
  padding: 0.6rem 0.95rem;
  border-radius: 18px;
  font-size: 0.875rem;
  line-height: 1.55;
}
.chat-msg.bot .chat-bubble {
  background: #ffffff;
  border: 1px solid #E6DEC8;
  color: #141413;
  border-bottom-left-radius: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.chat-msg.user .chat-bubble {
  background: #C85A32;
  color: #FDFBF7;
  border-bottom-right-radius: 4px;
}

/* Typing indicator */
.chat-typing .chat-bubble {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 0.7rem 0.95rem;
  min-width: 56px;
  background: #ffffff;
  border: 1px solid #E6DEC8;
  border-bottom-left-radius: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.chat-typing .chat-bubble span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #9d8f7e;
  opacity: 0.5;
  animation: typingDot 1.2s infinite ease-in-out;
  display: inline-block;
}
.chat-typing .chat-bubble span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing .chat-bubble span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingDot {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30%           { transform: translateY(-5px); opacity: 1; }
}
.chatbot-input-area {
  padding: 0.85rem 1rem;
  border-top: 1px solid #E6DEC8;
  display: flex;
  gap: 0.5rem;
  background: #FDFBF7;
  flex-shrink: 0;
}
.chatbot-input {
  flex: 1;
  padding: 0.55rem 0.85rem;
  border: 1px solid #DCD4C6;
  border-radius: 999px;
  background: #F3EDE2;
  font-size: 0.875rem;
  color: #141413;
  outline: none;
  font-family: var(--font-body);
  transition: border-color 0.15s;
}
.chatbot-input::placeholder { color: #9d8f7e; }
.chatbot-input:focus { border-color: #C85A32; background: #fff; }
.chatbot-send {
  background: #C85A32;
  border: none;
  color: #FDFBF7;
  border-radius: 999px;
  padding: 0.55rem 1.1rem;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 700;
  font-family: var(--font-heading);
  letter-spacing: 0.02em;
  transition: background 0.15s;
  white-space: nowrap;
}
.chatbot-send:hover { background: #FF6600; }

/* ---- Utility ---- */
.text-accent { color: var(--accent); }
.text-muted { color: var(--body-text); opacity: 0.6; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

/* ---- Section fade transitions (no hard colour cuts) ---- */
.fade-section-down {
  background: linear-gradient(180deg, #FDFBF7 0%, #F3EDE2 100%);
}
.fade-section-up {
  background: linear-gradient(180deg, #F3EDE2 0%, #FDFBF7 100%);
}
.fade-section-mid {
  background: linear-gradient(180deg, #FDFBF7 0%, #F3EDE2 50%, #FDFBF7 100%);
}

/* ---- Marquee ticker ---- */
.marquee-outer {
  width: 100%;
  overflow: hidden;
  margin-top: 2.5rem;
  position: relative;
}
.marquee-outer::before,
.marquee-outer::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 120px;
  z-index: 2;
  pointer-events: none;
}
.marquee-outer::before {
  left: 0;
  background: linear-gradient(to right, #FDFBF7, transparent);
}
.marquee-outer::after {
  right: 0;
  background: linear-gradient(to left, #FDFBF7, transparent);
}
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee-scroll 28s linear infinite;
}
.marquee-track:hover { animation-play-state: paused; }
.marquee-inner {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 1rem;
  white-space: nowrap;
}
.marquee-inner span {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink);
  padding: 0 1.5rem;
}
.marquee-dot {
  display: inline-block !important;
  width: 5px !important;
  height: 5px !important;
  min-width: 5px !important;
  border-radius: 50% !important;
  background: var(--accent) !important;
  padding: 0 !important;
  vertical-align: middle;
  flex-shrink: 0;
}
@keyframes bubblePop {
  0%   { opacity: 0; transform: scale(0.85) translateY(8px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes marquee-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
@keyframes marquee-scroll-reverse {
  0%   { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}

/* ---- Service card marquee ---- */
.svc-marquee-outer {
  width: 100%;
  overflow: hidden;
  position: relative;
}
.svc-marquee-outer::before,
.svc-marquee-outer::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 100px;
  z-index: 2;
  pointer-events: none;
}
.svc-marquee-outer::before { left: 0; background: linear-gradient(to right, var(--bg-primary), transparent); }
.svc-marquee-outer::after  { right: 0; background: linear-gradient(to left,  var(--bg-primary), transparent); }
.svc-marquee-track {
  display: flex;
  width: max-content;
  gap: 1rem;
  padding: 0.5rem 0;
  animation: marquee-scroll 32s linear infinite;
}
.svc-marquee-track.reverse {
  animation: marquee-scroll-reverse 36s linear infinite;
}
.svc-marquee-track:hover { animation-play-state: paused; }
.svc-marquee-card {
  background: var(--bg-secondary);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  min-width: 220px;
  flex-shrink: 0;
}
.svc-marquee-card h4 {
  font-size: 0.88rem;
  margin-bottom: 0.25rem;
}
.svc-marquee-card p {
  font-size: 0.78rem;
  color: var(--body-text);
  line-height: 1.4;
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
  .marquee-outer::before, .marquee-outer::after { display: none; }
  .marquee-track { flex-wrap: wrap; justify-content: center; gap: 1rem; }
}

/* ---- Process step pop-in (JS-driven — js-ready class guards visibility) ---- */
.js-ready .process-step {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.js-ready .process-step.visible {
  opacity: 1;
  transform: translateY(0);
}
.js-ready .process-step:nth-child(1) { transition-delay: 0s; }
.js-ready .process-step:nth-child(2) { transition-delay: 0.2s; }
.js-ready .process-step:nth-child(3) { transition-delay: 0.4s; }
.js-ready .process-step:nth-child(4) { transition-delay: 0.6s; }
@media (prefers-reduced-motion: reduce) {
  .js-ready .process-step { opacity: 1; transform: none; }
}

/* ---- Pop-in cards (JS-driven — js-ready class guards visibility) ---- */
.pop-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}
.js-ready .pop-card {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.js-ready .pop-card.visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .js-ready .pop-card { opacity: 1; transform: none; }
}
.js-ready .pop-card:nth-child(1) { transition-delay: 0s; }
.js-ready .pop-card:nth-child(2) { transition-delay: 0.15s; }
.js-ready .pop-card:nth-child(3) { transition-delay: 0.3s; }

/* ---- Responsive ---- */

/* Large tablet / small laptop — nav starts to compress */
@media (max-width: 900px) {
  .nav-links { gap: 1.2rem; }
  .nav-links a { font-size: 0.82rem; }
  .nav-cta { display: none; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .cols-pricing { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
}
@media (max-width: 768px) {
  .pop-grid { grid-template-columns: 1fr; }
  .nav-links, .nav-cta { display: none; }
  .nav-mobile-toggle { display: flex; }
  .nav-mobile.open {
    display: block;
    background: var(--bg-primary);
    border-top: 1px solid var(--divider);
    padding: 1rem 2rem 1.5rem;
  }
  .nav-mobile a {
    display: block;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--divider);
    font-size: 0.95rem;
    color: var(--body-text);
  }
  .nav-mobile a:last-child { border-bottom: none; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .hero { padding: 3.5rem 0 3rem; }
  .section { padding: 3rem 0; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 1rem; align-items: flex-start; }
  .hero-stats { grid-template-columns: 1fr 1fr; }
  .chatbot-window {
    width: calc(100vw - 2rem);
    max-height: 75vh;
    right: 1rem;
    bottom: 5rem;
    border-radius: 12px;
  }
  .chatbot-toggle { right: 1rem; bottom: 1rem; }
  .ns-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
}
@media (max-width: 480px) {
  .container { padding: 0 1.25rem; }
  h1 { font-size: 1.9rem; }
  .hero-stats { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .grid-4 { grid-template-columns: 1fr; }
  .chatbot-window { max-height: 70vh; }
}

/* ---- Tools marquee (about page) ---- */
.tools-marquee-outer {
  width: 100%;
  overflow: hidden;
  position: relative;
  margin-top: 2rem;
  padding: 0.5rem 0;
}
.tools-marquee-outer::before,
.tools-marquee-outer::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 100px;
  z-index: 2;
  pointer-events: none;
}
.tools-marquee-outer::before {
  left: 0;
  background: linear-gradient(to right, var(--bg-secondary), transparent);
}
.tools-marquee-outer::after {
  right: 0;
  background: linear-gradient(to left, var(--bg-secondary), transparent);
}
.tools-marquee-track {
  display: flex;
  width: max-content;
  animation: tools-scroll 32s linear infinite;
}
.tools-marquee-track:hover { animation-play-state: paused; }
.tools-marquee-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0 0.75rem;
  white-space: nowrap;
}
.tool-chip {
  display: inline-flex;
  align-items: center;
  background: var(--bg-primary);
  border: 1px solid var(--divider);
  border-radius: 4px;
  padding: 0.5rem 1.1rem;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  transition: border-color 0.15s, background 0.15s;
}
.tool-chip:hover { border-color: var(--accent); background: var(--bg-elevated); }
@keyframes tools-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .tools-marquee-track { animation: none; flex-wrap: wrap; justify-content: center; gap: 0.75rem; }
  .tools-marquee-outer::before, .tools-marquee-outer::after { display: none; }
}

/* ---- Work We Deliver section — static vertical gradient ---- */
.work-deliver-section {
  background: linear-gradient(180deg, #F3EDE2 0%, #E6DEC8 50%, #F3EDE2 100%);
}

/* ---- AI Impact hero — static vertical gradient ---- */
.ai-impact-hero {
  background: linear-gradient(180deg, #FDFBF7 0%, #F3EDE2 100%);
}

/* ---- TOC Sidebar (ai-impact page) ---- */
.toc-sidebar {
  background: var(--bg-primary);
  border: 1px solid var(--divider);
  border-radius: var(--radius);
  padding: 1.5rem;
  position: sticky;
  top: 5.5rem;
}
.toc-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--divider);
}
.toc-link {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--divider);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--body-text);
  text-decoration: none;
  transition: color 0.15s, padding-left 0.15s;
  line-height: 1.4;
}
.toc-link:hover { color: var(--accent); padding-left: 4px; }
.toc-num {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent);
  min-width: 20px;
  padding-top: 0.1rem;
}


/* ============================================================
   RESPONSIVE LAYOUT UTILITY CLASSES
   Replaces all inline display:grid;grid-template-columns:...
   so every layout collapses cleanly on mobile.
   ============================================================ */

/* ---- Two-column 1:1 split (used in about, services, index how-we-work, etc.) ---- */
.cols-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

/* ---- Two-column 1:2 split (FAQ sidebar + content, contact, case-studies hero) ---- */
.cols-1-2 {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 4rem;
  align-items: start;
}

/* ---- Two-column 2:1 split (ai-impact TOC layout) ---- */
.cols-2-1 {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 4rem;
  align-items: start;
}

/* ---- Two-column 1:2.5 split (legal docs) ---- */
.cols-1-2h {
  display: grid;
  grid-template-columns: 1fr 2.5fr;
  gap: 4rem;
  align-items: start;
}

/* ---- Four-column pricing grid ---- */
.cols-pricing {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  align-items: start;
}

/* ---- Three-column stats (ai-impact) ---- */
.cols-3-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

/* ---- Two-column form row (contact page name/email, phone/company) ---- */
.cols-form-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

/* ---- Two-column gap-2 (case-studies what-we-need grid) ---- */
.cols-2-gap2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

/* ---- Pricing note (auto + 1fr) ---- */
.cols-pricing-note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.5rem;
  align-items: start;
}

/* ---- Legal info box (1fr 2fr) ---- */
.cols-legal-info {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
  align-items: start;
}

/* ---- Centre-aligned two-column (case-studies process hero) ---- */
.cols-2-center {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 4rem;
  align-items: center;
}

/* ---- Breakpoints ---- */

/* Tablet — 1024px */
@media (max-width: 1024px) {
  .cols-pricing { grid-template-columns: repeat(2, 1fr); }
  .cols-3-stats  { grid-template-columns: repeat(2, 1fr); }
}

/* Mobile — 768px: collapse all multi-col layouts to single column */
@media (max-width: 768px) {
  .cols-2,
  .cols-1-2,
  .cols-2-1,
  .cols-1-2h,
  .cols-pricing,
  .cols-2-gap2,
  .cols-pricing-note,
  .cols-legal-info,
  .cols-2-center { grid-template-columns: 1fr; gap: 2rem; }

  .cols-3-stats  { grid-template-columns: 1fr; gap: 1.25rem; }
  .cols-form-2   { grid-template-columns: 1fr; gap: 0; }

  /* Page hero inner navigation pills — wrap nicely */
  .page-hero-nav { gap: 0.4rem; }
  .page-hero-nav a { font-size: 0.75rem; padding: 0.35rem 0.75rem; }

  /* Process steps: remove fixed 2-col layout */
  .process-steps { margin-top: 2rem; }

  /* Pricing: reset the "featured" card negative margin */
  .pricing-card.featured { margin-top: 0 !important; }

  /* About page dark numbered box — reduce padding */
  .cols-2 > div > div[style*="background:var(--ink)"] { padding: 1.5rem !important; }

  /* Section header on mobile */
  .section-header { margin-bottom: 2rem; }

  /* Contrast section padding */
  .contrast-section { padding: 3.5rem 0; }

  /* Page hero */
  .page-hero { padding: 2.5rem 0 2rem; }
  .page-hero h1 { font-size: clamp(1.6rem, 6vw, 2.4rem); }

  /* FAQ section — tighter */
  .cols-1-2 .accordion { margin-top: 0; }
}

/* Small mobile — 480px */
@media (max-width: 480px) {
  .cols-pricing { grid-template-columns: 1fr; }
  .cols-3-stats  { grid-template-columns: 1fr; }

  /* Buttons full-width in CTA sections */
  .contrast-section .btn { width: 100%; justify-content: center; text-align: center; }

  /* Hero actions already handled, make sure CTA band also stacks */
  .contrast-section > .container > div[style*="display:flex"] {
    flex-direction: column;
    align-items: stretch;
  }
}

/* ---- Case-study section rows (1fr 1fr with border/padding, anchored) ---- */
.case-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
  padding: 3rem 0;
  border-bottom: 1px solid var(--divider);
}
.case-row:last-of-type { border-bottom: none; }

/* ---- Icon + text micro-grid (28px/18px/52px fixed left col) ---- */
/* These are fine as-is on mobile — fixed col stays small */
.icon-row-28 { display: grid; grid-template-columns: 28px 1fr; gap: 0.75rem; align-items: start; }
.icon-row-18 { display: grid; grid-template-columns: 18px 1fr; gap: 0.75rem; align-items: start; }
.icon-row-52 { display: grid; grid-template-columns: 52px 1fr; gap: 1.25rem; align-items: start; }

@media (max-width: 768px) {
  .case-row { grid-template-columns: 1fr; gap: 2rem; padding: 2rem 0; }
}

/* ---- Additional mobile polish ---- */
@media (max-width: 768px) {
  /* TOC sidebar: remove sticky on mobile, it goes above content */
  .toc-sidebar { position: static; top: auto; }

  /* Contact form: add gap between stacked form groups */
  .cols-form-2 .form-group { margin-bottom: 1.25rem; }

  /* Case-study rows: reverse order so description comes first on mobile */
  /* (keep default order — no reversal needed) */

  /* About numbered box rows: reduce internal padding */
  .icon-row-52 { padding-top: 1rem !important; padding-bottom: 1rem !important; }

  /* Reduce hero h1 on mobile */
  .hero h1 { font-size: clamp(1.8rem, 7vw, 2.8rem); }

  /* Wider section header text on mobile */
  .section-header p { max-width: 100%; }

  /* Make the full-width CTA buttons in hero actions gap smaller */
  .hero-actions { gap: 0.75rem; }

  /* Nav height reduce slightly on small screens */
  .nav-inner { height: 60px; }

  /* Pricing note box: single column is fine, remove auto col */
  .cols-pricing-note { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  /* Page hero heading */
  .page-hero h1 { font-size: 1.5rem; }

  /* Tighter section padding on very small screens */
  .section { padding: 2.5rem 0; }

  /* Pricing card buttons */
  .pricing-card .btn { font-size: 0.85rem; }

  /* Accordion trigger text size */
  .accordion-trigger span { font-size: 0.95rem; }

  /* Chatbot toggle: a little smaller on tiny screens */
  .chatbot-toggle { width: 50px; height: 50px; }
  .chatbot-toggle img { width: 32px; height: 32px; }

  /* Process step text */
  .process-step { gap: 1rem; }
  .step-num { font-size: 1.25rem; }
}
