/* ================================================================
   QUALZY — Proactive AI Page Styles
   All styles specific to features/proactive-ai.html
   ================================================================ */


/* ── Hero ──────────────────────────────────────────────────────── */

.pai-hero {
  position: relative;
  background: var(--wh);
  overflow: hidden;
  padding-top: 64px;
}

.pai-hd1 {
  position: absolute;
  top: -80px; right: -80px;
  width: 460px; height: 460px;
  background: radial-gradient(circle, rgba(250,88,2,.09) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.pai-hd2 {
  position: absolute;
  bottom: -60px; left: -60px;
  width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(250,88,2,.06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.pai-hsvg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.pai-hi {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  padding: 60px 48px 80px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pai-back {
  font-size: 13px;
  font-weight: 500;
  color: var(--mu);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 28px;
  align-self: flex-start;
  transition: color var(--t-base);
}

.pai-back:hover { color: var(--o); }

.pai-hi h1 {
  font-family: var(--font-display);
  font-size: clamp(48px, 6.5vw, 86px);
  font-weight: 900;
  line-height: 1.0;
  color: var(--dk);
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.pai-hi h1 em {
  font-style: italic;
  color: var(--o);
}

.pai-hsub {
  font-size: 19px;
  color: var(--mid);
  max-width: 640px;
  line-height: 1.65;
  margin: 0 0 36px;
}

.pai-hbtns {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}


/* ── Pipeline (dark) ───────────────────────────────────────────── */

.pai-pipe {
  background: var(--dk);
}

.pai-pipe-inn {
  max-width: 1200px;
  margin: 0 auto;
  padding: 96px 48px;
}

.pai-pipe-hd {
  max-width: 680px;
  margin: 0 auto 64px;
  text-align: center;
}

.pai-pipe-sub {
  color: rgba(255,255,255,.5);
  margin-top: 16px;
}

.pai-pipe-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 760px;
  margin: 0 auto;
}

.pai-pst {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 24px;
  position: relative;
}

.pai-pst-left {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pai-pst-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  flex-shrink: 0;
  color: rgba(255,255,255,.4);
}

.pai-pst--active .pai-pst-circle {
  background: rgba(250,88,2,.12);
  border-color: rgba(250,88,2,.3);
  color: var(--o);
}

.pai-pst--highlight .pai-pst-circle {
  background: var(--o);
  border-color: var(--o);
  color: #fff;
}

.pai-pst-circle svg {
  width: 20px; height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pai-pst-n {
  position: absolute;
  top: -8px;
  right: -8px;
  font-size: 10px;
  font-weight: 700;
  color: var(--o);
  background: var(--dk);
  padding: 1px 4px;
  border-radius: 4px;
  line-height: 1.4;
}

.pai-pst--highlight .pai-pst-n {
  color: var(--o);
  background: var(--dk);
}

.pai-pst-connector {
  flex: 1;
  width: 1px;
  background: rgba(255,255,255,.08);
  margin: 8px 0;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
}

.pai-pst-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--o);
  opacity: 0.5;
  animation: pstDot 1.8s ease-in-out infinite;
}

.pai-pst-dot--delay {
  animation-delay: 0.6s;
}

@keyframes pstDot {
  0%, 100% { opacity: 0.2; transform: translateY(-4px); }
  50%       { opacity: 0.7; transform: translateY(4px); }
}

.pai-pst-card {
  padding: 28px 0 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pai-pst-card--highlight {
  background: rgba(250,88,2,.05);
  border: 1px solid rgba(250,88,2,.2);
  border-radius: 16px;
  padding: 28px;
  margin-bottom: 0;
}

.pai-pst-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--o);
  background: rgba(250,88,2,.12);
  border-radius: 20px;
  padding: 4px 12px;
  align-self: flex-start;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.pai-pst-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.pai-pst--highlight .pai-pst-title {
  color: #fff;
}

.pai-pst-body {
  font-size: 15px;
  color: rgba(255,255,255,.5);
  line-height: 1.7;
  margin: 0;
}

.pai-ps-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.pai-tag {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255,255,255,.4);
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 20px;
  padding: 4px 12px;
}

.pai-tag--bright {
  color: var(--o);
  background: rgba(250,88,2,.1);
  border-color: rgba(250,88,2,.2);
}


/* ── Key Points (light) ────────────────────────────────────────── */

/* Two-column layout: copy left, demo right */
.pai-kp-cols {
  display: flex;
  align-items: flex-start;
  gap: 64px;
}

.pai-kp-txt {
  flex: 1;
  min-width: 0;
}

.pai-kp-txt .slbl,
.pai-kp-txt .stit,
.pai-kp-txt .sbod {
  text-align: left;
}

.pai-kp-txt .stit {
  margin-bottom: 20px;
}

.pai-kp-txt .sbod {
  margin-bottom: 14px;
}

.pai-kp-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.pai-kp-pill {
  font-size: 12px;
  font-weight: 600;
  color: var(--o);
  background: var(--op);
  border: 1px solid rgba(250,88,2,.18);
  border-radius: 20px;
  padding: 5px 13px;
}

.pai-kp-foot {
  text-align: center;
  font-size: 13px;
  color: var(--mu);
  margin-top: 28px;
}

/* ── Transcript scroll animation ─────────────────────────────── */

@keyframes kpd-tr-scroll {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-55%); }
}

.kpd-tr-scroll {
  /* animation applied only when stage is active */
}

.kpd-stage.kpd-active .kpd-tr-scroll {
  animation: kpd-tr-scroll 5s linear forwards;
}

/* ── Animated demo container ─────────────────────────────────── */

.kp-demo {
  position: relative;
  flex: 0 0 440px;
  height: 480px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 2px 0 var(--rule), 0 8px 40px rgba(0,0,0,.08);
  overflow: hidden;
  border: 1px solid var(--rule);
}

/* All stages share absolute positioning and crossfade */
/* They stop 52px from the bottom — reserved for the persistent footer */
.kpd-stage {
  position: absolute;
  inset: 0 0 52px 0;
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.kpd-stage.kpd-active {
  opacity: 1;
}

/* Persistent orange footer — always visible, text driven by JS */
.kpd-foot {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 10px;
  padding: 0 20px;
  background: var(--o);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: .01em;
  z-index: 10;
}

.kpd-foot-txt {
  transition: opacity 0.25s ease;
}

/* ── Stage 1: Transcript ─────────────────────────────────────── */

.kpd-s1 {
  display: flex;
  flex-direction: column;
}

.kpd-tr {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 20px 28px 0;
}

.kpd-tr-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 12px;
  flex-shrink: 0;
}

.kpd-tr-lbl {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--dk);
}

.kpd-tr-wc {
  font-size: 11px;
  color: var(--mu);
  background: #f0efec;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 500;
}

.kpd-tr-body {
  flex: 1;
  font-size: 11.5px;
  line-height: 1.75;
  color: #444;
  overflow: hidden;
  position: relative;
}

/* Gradient fade at top of transcript — suggests text above viewport */
.kpd-tr-body::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 48px;
  background: linear-gradient(#fff, transparent);
  pointer-events: none;
  z-index: 1;
}

/* Gradient fade at bottom of transcript — suggests it goes on forever */
.kpd-tr-body::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 90px;
  background: linear-gradient(transparent, #fff);
  pointer-events: none;
}

/* ── Stage 2: Processing ─────────────────────────────────────── */

.kpd-s2 {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fafaf8;
}

.kpd-proc {
  text-align: center;
  width: 300px;
}

.kpd-proc-icon {
  width: 48px;
  height: 48px;
  background: var(--op);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  color: var(--o);
}

.kpd-proc-icon svg {
  width: 22px;
  height: 22px;
}

.kpd-proc-lbl {
  font-size: 15px;
  font-weight: 600;
  color: var(--dk);
  margin-bottom: 20px;
}

.kpd-proc-track {
  height: 4px;
  background: var(--rule);
  border-radius: 4px;
  overflow: hidden;
}

.kpd-proc-fill {
  height: 100%;
  width: 0%;
  background: var(--o);
  border-radius: 4px;
}

/* ── Stage 3: Key points ─────────────────────────────────────── */

.kpd-s3 {
  padding: 20px 24px 20px;
  display: flex;
  flex-direction: column;
}

.kpd-s3-hd {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  flex-shrink: 0;
}

.kpd-s3-count {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--o);
}

.kpd-s3-src {
  font-size: 11px;
  color: var(--mu);
}

.kpd-kp-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  overflow: hidden;
}

/* Individual key point row */
.kpd-kp {
  border: 1.5px solid var(--rule);
  border-radius: 9px;
  padding: 10px 14px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.35s ease, transform 0.35s ease, border-color 0.3s, box-shadow 0.3s;
  background: #fff;
}

.kpd-kp.kpd-kp-in {
  opacity: 1;
  transform: translateY(0);
}

.kpd-kp.kpd-kp-active {
  border-color: var(--o);
  box-shadow: 0 2px 14px rgba(250,88,2,.13);
}

.kpd-kp-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.kpd-kp-n {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  background: var(--op);
  color: var(--o);
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
}

.kpd-kp-active .kpd-kp-n {
  background: var(--o);
  color: #fff;
}

.kpd-kp-title {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--dk);
  line-height: 1.35;
}

/* Body text — visible initially, collapses when condensed */
.kpd-kp-body {
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--mid);
  padding-left: 32px;
  margin-top: 5px;
  max-height: 40px;
  overflow: hidden;
  transition: max-height 0.4s ease, margin-top 0.35s ease, opacity 0.3s ease;
  opacity: 1;
}

.kpd-kp.kpd-kp-condensed .kpd-kp-body {
  max-height: 0;
  margin-top: 0;
  opacity: 0;
}

/* Verbatims — collapsed by default, expand on active */
.kpd-vbs {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.55s ease, margin-top 0.4s ease;
  margin-top: 0;
}

.kpd-vbs.kpd-vbs-open {
  max-height: 240px;
  margin-top: 10px;
}

.kpd-vb {
  display: flex;
  gap: 10px;
  background: #f5f4f1;
  border-radius: 7px;
  padding: 9px 11px;
  border-left: 3px solid var(--o);
}

.kpd-vb-thumb {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--o);
}

.kpd-vb-thumb svg {
  width: 28px;
  height: 28px;
}

.kpd-vb-body {
  flex: 1;
  min-width: 0;
}

.kpd-vb-hd {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--dk);
  margin-bottom: 4px;
  flex-wrap: wrap;
}

.kpd-vb-time {
  font-weight: 500;
  color: var(--mu);
  font-size: 10.5px;
  margin-left: auto;
  font-family: 'DM Mono', monospace;
  letter-spacing: .02em;
}

.kpd-vb-quote {
  font-size: 11px;
  color: #4a4946;
  line-height: 1.55;
  font-style: italic;
}


/* ── Maizy Chat (dark) ─────────────────────────────────────────── */

.pai-maizy {
  background: var(--d2);
}

.pai-maizy-grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 96px 48px;
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 72px;
  align-items: center;
}

.pai-maizy-note {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 28px;
  padding: 16px 20px;
  background: rgba(250,88,2,.08);
  border: 1px solid rgba(250,88,2,.2);
  border-radius: 10px;
  font-size: 14px;
  color: rgba(255,255,255,.6);
  line-height: 1.55;
}

.pai-maizy-note svg {
  width: 16px; height: 16px;
  fill: none;
  stroke: var(--o);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
  margin-top: 2px;
}

.pai-maizy-examples {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 28px;
}

.pai-mex-q {
  font-size: 14px;
  color: rgba(255,255,255,.6);
  line-height: 1.5;
  padding: 14px 18px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  font-style: italic;
}

.pai-mex-q::before {
  content: '"';
  color: var(--o);
  font-style: normal;
  font-weight: 700;
}

.pai-mex-q::after {
  content: '"';
  color: var(--o);
  font-style: normal;
  font-weight: 700;
}

.pai-screenshot {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,.07);
}

.pai-screen-frame {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 24px 72px rgba(0,0,0,.13), 0 0 0 1px rgba(0,0,0,.05);
}

.pai-screen-frame--dark {
  box-shadow: 0 24px 72px rgba(0,0,0,.4), 0 0 0 1px rgba(255,255,255,.06);
}


/* ── AI Idea Playground (light) ────────────────────────────────── */

.pai-play-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
}

/* Chat-style mockup card */
.pai-play-card {
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,.07);
}

.pai-play-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--rule);
  background: var(--wh);
}

.pai-play-av {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--o);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.pai-play-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--dk);
}

.pai-play-sub {
  font-size: 12px;
  color: var(--mu);
}

.pai-play-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
}

.pai-play-msg {
  font-size: 13px;
  line-height: 1.6;
  border-radius: 10px;
  padding: 12px 16px;
  max-width: 90%;
}

.pai-play-msg--user {
  background: var(--op);
  color: var(--dk);
  align-self: flex-end;
  border-bottom-right-radius: 3px;
}

.pai-play-msg--ai {
  background: var(--wh);
  border: 1px solid var(--rule);
  color: var(--mid);
  align-self: flex-start;
  border-bottom-left-radius: 3px;
}

.pai-play-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.pai-play-tag {
  font-size: 12px;
  font-weight: 500;
  color: var(--o);
  background: var(--op);
  border: 1px solid rgba(250,88,2,.15);
  border-radius: 20px;
  padding: 5px 14px;
}


/* ── Key capabilities (warm) ───────────────────────────────────── */

.pai-feats-hd {
  text-align: center;
  margin-bottom: 48px;
}

.pai-feats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.pai-feat {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px;
  background: #fff;
  border: 1px solid rgba(250,88,2,.12);
  border-radius: 14px;
  transition: border-color .2s, box-shadow .2s;
}

.pai-feat:hover {
  border-color: rgba(250,88,2,.3);
  box-shadow: 0 4px 20px rgba(250,88,2,.07);
}

.pai-feat-icon {
  width: 40px; height: 40px;
  background: var(--op);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--o);
  flex-shrink: 0;
}

.pai-feat-icon svg {
  width: 20px; height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pai-feat h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--dk);
  margin: 0;
}

.pai-feat p {
  font-size: 14px;
  color: var(--mid);
  line-height: 1.6;
  margin: 0;
}


/* ── Responsive ────────────────────────────────────────────────── */

@media (max-width: 1024px) {
  /* Stack the two-column KP layout at tablet */
  .pai-kp-cols {
    flex-direction: column;
    gap: 40px;
  }

  .kp-demo {
    flex: none;
    width: 100%;
    height: 480px;
  }

  .pai-maizy-grid {
    grid-template-columns: 1fr;
    gap: 48px;
    padding: 72px 48px;
  }

  .pai-play-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }


  .pai-feats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .pai-hi {
    padding: 40px 24px 56px;
  }

  .pai-pipe-inn {
    padding: 64px 24px;
  }

  .pai-maizy-grid {
    padding: 64px 24px;
  }

  .kp-demo { height: 420px; }
}

@media (max-width: 480px) {
  .pai-feats-grid {
    grid-template-columns: 1fr;
  }

  .pai-hbtns {
    flex-direction: column;
    align-items: center;
    width: 100%;
  }
}


/* ── Maizy Chat Demo (light theme — matches real product) ─────────────────── */

.mai-demo {
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,.1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 580px;
  box-shadow: 0 12px 48px rgba(0,0,0,.18), 0 2px 8px rgba(0,0,0,.08);
}

/* Header */
.mai-hd {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 15px;
  border-bottom: 1px solid rgba(0,0,0,.07);
  background: #FAFAF8;
  flex-shrink: 0;
}

.mai-av {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: #00B2A9;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 13px; color: #fff;
  font-family: var(--font-body);
  flex-shrink: 0;
}

.mai-hd-name {
  font-size: 13px; font-weight: 600; color: var(--dk);
  font-family: var(--font-body); line-height: 1.2;
}

.mai-hd-sub {
  font-size: 10px; color: var(--mu);
  font-family: var(--font-body); line-height: 1.2;
}

.mai-badge {
  margin-left: auto;
  background: rgba(0,178,169,.12);
  color: #00B2A9;
  font-size: 9px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 100px;
  font-family: var(--font-body);
}

/* Message area */
.mai-msgs {
  flex: 1;
  overflow-y: auto;
  padding: 16px 15px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  scroll-behavior: smooth;
  background: #fff;
}

.mai-msgs::-webkit-scrollbar { width: 3px; }
.mai-msgs::-webkit-scrollbar-track { background: transparent; }
.mai-msgs::-webkit-scrollbar-thumb { background: rgba(0,0,0,.15); border-radius: 2px; }

/* Messages */
.mai-msg {
  display: flex;
  animation: maiFadeUp 0.22s ease forwards;
}
.mai-msg--u  { justify-content: flex-end; }
.mai-msg--ai { justify-content: flex-start; }

@keyframes maiFadeUp {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.mai-bubble {
  max-width: 88%;
  padding: 9px 13px;
  font-size: 12px;
  line-height: 1.6;
  font-family: var(--font-body);
  border-radius: 14px;
}

/* User bubble — orange */
.mai-bubble--u {
  background: var(--o);
  color: #fff;
  border-bottom-right-radius: 3px;
  font-weight: 500;
}

/* AI bubble — light grey, dark text */
.mai-bubble--ai {
  background: #F2F1EE;
  color: #1A1917;
  border-bottom-left-radius: 3px;

  border: 1px solid rgba(0,0,0,.06);
}

/* Thinking dots */
.mai-thinking {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 11px 14px;
}

.mai-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #00B2A9;
  opacity: 0.5;
  animation: maiDot 1.1s ease-in-out infinite;
}
.mai-dot:nth-child(2) { animation-delay: 0.18s; }
.mai-dot:nth-child(3) { animation-delay: 0.36s; }

@keyframes maiDot {
  0%, 60%, 100% { transform: translateY(0);    opacity: 0.4; }
  30%           { transform: translateY(-5px); opacity: 1;   }
}

/* Input footer */
.mai-foot {
  flex-shrink: 0;
  padding: 10px 12px 11px;
  border-top: 1px solid rgba(0,0,0,.07);
  background: #FAFAF8;
}

.mai-input-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid rgba(0,0,0,.12);
  border-radius: 8px;
  padding: 8px 10px;
  min-height: 38px;
}

.mai-input {
  flex: 1;
  font-size: 12px;
  color: #1A1917;
  font-family: var(--font-body);
  line-height: 1.4;
  word-break: break-word;
}

.mai-input:empty::before {
  content: 'Hey Julian, what can I help you with?';
  color: rgba(0,0,0,.3);
}

.mai-cursor {
  display: inline-block;
  width: 1.5px; height: 13px;
  background: var(--o);
  vertical-align: middle;
  margin-left: 1px;
  animation: maiCursor 0.75s step-end infinite;
}
@keyframes maiCursor { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

.mai-send {
  width: 28px; height: 28px;
  border-radius: 7px;
  background: var(--o);
  border: none; cursor: default;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  opacity: 0.3;
  transition: opacity 0.2s ease;
  color: #fff;
}
.mai-send.mai-active { opacity: 1; }
.mai-send svg { width: 12px; height: 12px; }

.mai-hint {
  font-size: 9.5px;
  color: rgba(0,0,0,.3);
  font-family: var(--font-body);
  text-align: center;
  margin-top: 5px;
}

/* ── Maizy Chat — formatted response elements ─────────────────────────────── */

.mai-bubble--ai .mai-ln   { margin: 0; line-height: 1.58; }
.mai-bubble--ai .mai-sp   { height: 7px; }

/* Quote block — inset grey card with italic text */
.mai-bubble--ai .mai-qt {
  background: rgba(0,0,0,.055);
  border-radius: 5px;
  padding: 7px 11px;
  margin: 3px 0 1px;
  font-style: italic;
  color: rgba(26,25,23,.78);
  font-size: 11.5px;
  line-height: 1.52;
}

/* Attribution — small, muted, below the quote */
.mai-bubble--ai .mai-at {
  font-size: 10.5px;
  color: rgba(26,25,23,.42);
  font-style: normal;
  padding-left: 3px;
  margin-bottom: 3px;
  font-weight: 500;
}

/* Bold section headers */
.mai-bubble--ai .mai-hdr {
  font-weight: 700;
  color: #1A1917;
  margin-top: 2px;
}


/* Playground avatar — amber/orange to distinguish from teal Maizy */
.play-av   { background: #C85E1A; font-size: 10px; font-weight: 700; letter-spacing: 0.04em; }
.play-badge { background: rgba(200,94,26,.12); color: #C85E1A; }


/* Playground thinking dots — amber colour */
.play-dot { background: #C85E1A !important; }
