/* Destiny AI — conversational shell for the existing Destiny Matrix engine. */

html.dmc-root.dmc-ai-app {
  --dai-bg: #0a0b0f;
  --dai-elev: #14161d;
  --dai-field: #1b1e27;
  --dai-line: rgba(255, 255, 255, 0.12);
  --dai-line-2: rgba(255, 255, 255, 0.18);
  --dai-ink: #f5f3ee;
  --dai-muted: #a9a6a0;
  --dai-gold: #e3c67f;
  --dai-gold-soft: rgba(227, 198, 127, 0.14);
  --dai-me: #232838;
  --dai-orb: radial-gradient(circle at 32% 28%, #f6e7bb 0%, #dfc07c 40%, #8a6230 100%);
  color-scheme: dark;
}

html.dmc-root.dmc-ai-app,
html.dmc-root.dmc-ai-app body {
  background: var(--dai-bg) !important;
  color: var(--dai-ink) !important;
  /* The page scrolls so the guide under the chat can be read. The chat keeps
     its own scroll area, and overscroll-behavior stops the two from fighting. */
  overflow-x: hidden;
  overflow-y: auto;
}

html.dmc-root.dmc-ai-app body {
  margin: 0;
}

/* The original page stays in the DOM (the engine renders the SVG into it) but
   is not shown; Destiny AI is the whole screen. */
html.dmc-root.dmc-ai-app .dm-form-shell,
html.dmc-root.dmc-ai-app .show-charts,
html.dmc-root.dmc-ai-app .dm-reading-catalog,
html.dmc-root.dmc-ai-app .dm-unlock,
html.dmc-root.dmc-ai-app .dm-report-header,
html.dmc-root.dmc-ai-app .dmc-ask,
html.dmc-root.dmc-ai-app .dm-health-map,
html.dmc-root.dmc-ai-app .dm-advanced-profile-mount,
html.dmc-root.dmc-ai-app .dmc-noscript {
  display: none !important;
}

/* First-paint placeholder for the chat shell. Only shown while the AI app is in
   charge, so a visitor with JavaScript off never sees a stuck skeleton. */
.dai-boot {
  display: none;
}

html.dmc-root.dmc-ai-app .dai-boot {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
  background:
    radial-gradient(120% 60% at 50% 0%, #15161f 0%, rgba(10, 11, 15, 0) 60%),
    var(--dai-bg);
}

html.dmc-root .dai-boot__top {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 56px;
  padding: 0 12px;
  border-bottom: 1px solid var(--dai-line);
  background: rgba(10, 11, 15, 0.88);
}

html.dmc-root .dai-boot__orb {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-image: var(--dai-orb);
  box-shadow: 0 0 0 4px rgba(227, 198, 127, 0.1);
}

html.dmc-root .dai-boot__text b {
  display: block;
  font-size: 0.98rem;
  font-weight: 700;
  color: #fff;
}

html.dmc-root .dai-boot__text small {
  display: block;
  margin-top: 1px;
  font-size: 0.74rem;
  color: var(--dai-muted);
}

html.dmc-root .dai-boot__body {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

html.dmc-root .dai-boot__dots {
  display: flex;
  gap: 6px;
}

html.dmc-root .dai-boot__dots i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--dai-gold);
  opacity: 0.35;
  animation: dai-boot-pulse 1.1s ease-in-out infinite;
}

html.dmc-root .dai-boot__dots i:nth-child(2) {
  animation-delay: 0.15s;
}

html.dmc-root .dai-boot__dots i:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes dai-boot-pulse {
  0%, 100% { opacity: 0.25; transform: translateY(0); }
  50% { opacity: 0.9; transform: translateY(-3px); }
}

@media (prefers-reduced-motion: reduce) {
  html.dmc-root .dai-boot__dots i {
    animation: none;
    opacity: 0.6;
  }
}

html.dmc-root .dai-app,
html.dmc-root .dai-app *,
html.dmc-root .dai-app *::before,
html.dmc-root .dai-app *::after {
  box-sizing: border-box;
}

html.dmc-root .dai-app {
  /* First screen of the page, exactly one viewport tall. Everything inside
     still lays out as header + its own scroll area + composer. */
  position: relative;
  z-index: 90;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  background:
    radial-gradient(120% 60% at 50% 0%, #15161f 0%, rgba(10, 11, 15, 0) 60%),
    var(--dai-bg);
  color: var(--dai-ink) !important;
  -webkit-text-fill-color: var(--dai-ink);
  font-size: 16px;
  line-height: 1.5;
}

html.dmc-root .dai-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* ---------- top bar ---------- */

html.dmc-root .dai-top {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 56px;
  padding: 0 12px;
  border-bottom: 1px solid var(--dai-line);
  background: rgba(10, 11, 15, 0.88);
}

html.dmc-root .dai-top__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

html.dmc-root .dai-top__text {
  min-width: 0;
}

html.dmc-root .dai-orb {
  display: block;
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-image: var(--dai-orb);
  box-shadow: 0 0 0 4px rgba(227, 198, 127, 0.1);
}

html.dmc-root .dai-top__name {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dmc-root .dai-top__who {
  margin: 1px 0 0;
  font-size: 0.74rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--dai-muted) !important;
  -webkit-text-fill-color: var(--dai-muted) !important;
}

html.dmc-root .dai-ghost {
  appearance: none;
  flex-shrink: 0;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--dai-line-2);
  border-radius: 999px;
  background: transparent;
  color: var(--dai-ink) !important;
  -webkit-text-fill-color: var(--dai-ink) !important;
  font: inherit;
  font-size: 0.84rem;
  cursor: pointer;
}

html.dmc-root .dai-ghost:hover {
  border-color: rgba(227, 198, 127, 0.5);
}

/* ---------- conversation ---------- */

html.dmc-root .dai-scroll {
  flex: 1;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

html.dmc-root .dai-thread {
  display: flex;
  flex-direction: column;
  gap: 18px;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 18px 14px 10px;
}

html.dmc-root .dai-msg {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  animation: dai-in 0.3s ease backwards;
}

html.dmc-root .dai-msg--me {
  justify-content: flex-end;
}

html.dmc-root .dai-msg__orb {
  margin-top: 2px;
  width: 26px;
  height: 26px;
}

html.dmc-root .dai-msg__col {
  flex: 1;
  min-width: 0;
}

html.dmc-root .dai-msg__from {
  margin: 0 0 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-msg__text {
  margin: 0 0 10px;
  font-size: 1rem;
  line-height: 1.66;
  color: var(--dai-ink) !important;
  -webkit-text-fill-color: var(--dai-ink) !important;
}

html.dmc-root .dai-msg__text:last-child {
  margin-bottom: 0;
}

/* Streaming text keeps the model's own line breaks until it is formatted. */
html.dmc-root .dai-msg__text[data-dai-live] {
  white-space: pre-wrap;
}

html.dmc-root .dai-msg__text strong {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dmc-root .dai-msg__h {
  margin: 12px 0 6px;
  font-size: 0.98rem;
  font-weight: 700;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dmc-root .dai-msg__h:first-child {
  margin-top: 0;
}

html.dmc-root .dai-msg__hint {
  margin: 8px 0 0;
  font-size: 0.8rem;
  color: var(--dai-muted) !important;
  -webkit-text-fill-color: var(--dai-muted) !important;
}

html.dmc-root .dai-list {
  margin: 0 0 10px;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--dai-ink) !important;
}

html.dmc-root .dai-bubble {
  margin: 0;
  max-width: min(520px, 88%);
  padding: 11px 15px;
  border-radius: 20px 20px 6px 20px;
  background: var(--dai-me);
  font-size: 0.98rem;
  line-height: 1.5;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dmc-root .dai-thinking {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 0.95rem;
  color: var(--dai-muted) !important;
  -webkit-text-fill-color: var(--dai-muted) !important;
}

html.dmc-root .dai-dots {
  display: inline-flex;
  gap: 4px;
}

html.dmc-root .dai-dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--dai-gold);
  animation: dai-dot 1s ease-in-out infinite;
}

html.dmc-root .dai-dots i:nth-child(2) { animation-delay: 0.15s; }
html.dmc-root .dai-dots i:nth-child(3) { animation-delay: 0.3s; }

/* ---------- date of birth step ---------- */

html.dmc-root .dai-dob {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.3fr) minmax(0, 0.85fr);
  gap: 8px;
  margin-top: 12px;
}

html.dmc-root .dai-dob.is-done {
  opacity: 0.45;
  pointer-events: none;
}

html.dmc-root .dai-dob__box {
  position: relative;
  display: block;
  min-width: 0;
}

/* Name takes its own row above the date fields. */
html.dmc-root .dai-dob__box--wide {
  grid-column: 1 / -1;
}

html.dmc-root .dai-dob__box > span {
  position: absolute;
  top: 7px;
  left: 12px;
  z-index: 1;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  pointer-events: none;
  color: #8e8b85 !important;
  -webkit-text-fill-color: #8e8b85 !important;
}

html.dmc-root .dai-dob select,
html.dmc-root .dai-dob input {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  min-height: 54px;
  padding: 20px 12px 6px;
  border: 1px solid var(--dai-line-2);
  border-radius: 14px;
  background: var(--dai-field);
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  font: inherit;
  font-size: 16px;
}

html.dmc-root .dai-dob select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23E3C67F' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 8px;
  padding-right: 30px;
}

html.dmc-root .dai-dob select:focus,
html.dmc-root .dai-dob input:focus {
  outline: none;
  border-color: var(--dai-gold);
}

html.dmc-root .dai-primary {
  appearance: none;
  grid-column: 1 / -1;
  min-height: 50px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: var(--dai-gold);
  color: #171208 !important;
  -webkit-text-fill-color: #171208 !important;
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

html.dmc-root .dai-primary:hover {
  filter: brightness(1.05);
}

/* ---------- chart card ---------- */

html.dmc-root .dai-chart {
  margin-top: 12px;
  padding: 10px 12px 8px;
  border: 1px solid rgba(227, 198, 127, 0.32);
  border-radius: 20px;
  background: #f7f3eb;
  transition: border-color 0.2s ease;
}

html.dmc-root .dai-chart.is-lit {
  border-color: rgba(227, 198, 127, 0.8);
}

html.dmc-root .dai-chart__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

html.dmc-root .dai-chart__meta {
  min-width: 0;
}

/* Narrow screens: focus name keeps a full line, buttons drop below it. */
@media (max-width: 819px) {
  html.dmc-root .dai-chart__bar {
    flex-wrap: wrap;
  }

  html.dmc-root .dai-chart__meta {
    flex: 1 0 100%;
  }

  html.dmc-root .dai-chart__acts {
    margin-left: auto;
  }
}

html.dmc-root .dai-chart__kicker {
  margin: 0;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8a6230 !important;
  -webkit-text-fill-color: #8a6230 !important;
}

html.dmc-root .dai-chart__focus {
  margin: 2px 0 0;
  font-size: 0.92rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #1e5147 !important;
  -webkit-text-fill-color: #1e5147 !important;
}

html.dmc-root .dai-chart__acts {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 6px;
}

html.dmc-root .dai-chart__zoom {
  appearance: none;
  flex-shrink: 0;
  min-height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: #17130b;
  color: #f7f3eb !important;
  -webkit-text-fill-color: #f7f3eb !important;
  font: inherit;
  font-size: 0.84rem;
  cursor: pointer;
}

/* Only offered while part of the chart is highlighted. */
html.dmc-root .dai-chart__clear {
  appearance: none;
  display: none;
  flex-shrink: 0;
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid rgba(30, 81, 71, 0.35);
  border-radius: 999px;
  background: rgba(30, 81, 71, 0.08);
  color: #1e5147 !important;
  -webkit-text-fill-color: #1e5147 !important;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

html.dmc-root .dai-chart.is-lit .dai-chart__clear {
  display: inline-flex;
  align-items: center;
}

html.dmc-root .dai-chart__legend {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 2px 0 0;
  font-size: 0.72rem;
  font-weight: 600;
  color: #6b6558 !important;
  -webkit-text-fill-color: #6b6558 !important;
}

html.dmc-root .dai-chart__legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

html.dmc-root .dai-dot {
  width: 16px;
  height: 3px;
  border-radius: 2px;
}

html.dmc-root .dai-dot--love {
  background: #d6342f;
}

html.dmc-root .dai-dot--money {
  background: #12873a;
}

html.dmc-root .dai-chart__note {
  margin: 4px 0 0;
  font-size: 0.68rem;
  letter-spacing: 0.02em;
  color: #7b7566 !important;
  -webkit-text-fill-color: #7b7566 !important;
}

html.dmc-root .dai-chart__zoom-out {
  display: none;
}

html.dmc-root .dai-chart.is-zoom {
  position: fixed;
  inset: 56px 0 0;
  z-index: 120;
  margin: 0;
  padding: 14px;
  border-radius: 0;
  overflow: auto;
}

html.dmc-root .dai-chart.is-zoom .dai-chart__zoom-out { display: inline; }
html.dmc-root .dai-chart.is-zoom .dai-chart__zoom-in { display: none; }

/* ---------- reading cards ---------- */

html.dmc-root .dai-reads {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

html.dmc-root .dai-read {
  border: 1px solid var(--dai-line);
  border-radius: 16px;
  background: var(--dai-elev);
  overflow: hidden;
  transition: border-color 0.18s ease, background 0.18s ease;
}

html.dmc-root .dai-read.is-open {
  border-color: rgba(227, 198, 127, 0.45);
  background: #191c25;
  /* clip, not hidden, so the open header can stick to the thread's top */
  overflow: clip;
}

/* The open reading keeps its title in reach the whole way down. */
html.dmc-root .dai-read.is-open .dai-read__head {
  position: sticky;
  top: 0;
  z-index: 3;
  background: #191c25;
  border-bottom: 1px solid rgba(227, 198, 127, 0.16);
}

html.dmc-root .dai-read__head {
  appearance: none;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 60px;
  padding: 11px 12px;
  border: 0;
  background: none;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

html.dmc-root .dai-read__icon {
  font-size: 1.1rem;
  line-height: 1;
}

html.dmc-root .dai-read__main {
  min-width: 0;
}

html.dmc-root .dai-read__title {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dmc-root .dai-read__n {
  margin-right: 7px;
  font-size: 0.7rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-read__preview {
  display: block;
  margin-top: 3px;
  font-size: 0.8rem;
  line-height: 1.4;
  color: var(--dai-muted) !important;
  -webkit-text-fill-color: var(--dai-muted) !important;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

html.dmc-root .dai-read.is-open .dai-read__preview {
  display: none;
}

html.dmc-root .dai-read__seats {
  display: none;
}

html.dmc-root .dai-read__chev {
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--dai-gold);
  border-bottom: 2px solid var(--dai-gold);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

html.dmc-root .dai-read.is-open .dai-read__chev {
  transform: rotate(225deg);
}

html.dmc-root .dai-read__body {
  padding: 0 12px 14px;
  animation: dai-open 0.24s ease backwards;
}

html.dmc-root .dai-read__end {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--dai-line);
}

html.dmc-root .dai-read__fold,
html.dmc-root .dai-read__nextread {
  appearance: none;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--dai-line-2);
  border-radius: 999px;
  background: transparent;
  color: var(--dai-muted) !important;
  -webkit-text-fill-color: var(--dai-muted) !important;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
}

html.dmc-root .dai-read__nextread {
  flex: 1 1 auto;
  min-width: 0;
  border-color: rgba(227, 198, 127, 0.4);
  background: rgba(227, 198, 127, 0.1);
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
  text-align: left;
}

html.dmc-root .dai-read__seatline {
  margin: 0 0 10px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-read__karmic {
  margin: 0 0 8px;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dai-muted) !important;
  -webkit-text-fill-color: var(--dai-muted) !important;
}

html.dmc-root .dai-read__lead {
  margin: 0 0 12px;
  font-size: 0.98rem;
  line-height: 1.6;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

html.dmc-root .dai-read__p {
  margin: 0 0 10px;
  font-size: 0.92rem;
  line-height: 1.62;
  color: #d9d5cc !important;
  -webkit-text-fill-color: #d9d5cc !important;
}

html.dmc-root .dai-read__slot {
  margin: 16px 0 8px;
  padding-top: 12px;
  border-top: 1px solid var(--dai-line);
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-read__slot:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

html.dmc-root .dai-read__h {
  margin: 14px 0 6px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8f8b82 !important;
  -webkit-text-fill-color: #8f8b82 !important;
}

html.dmc-root .dai-read__guide {
  margin: 0;
  padding: 10px 12px;
  border-left: 2px solid rgba(227, 198, 127, 0.5);
  border-radius: 0 10px 10px 0;
  background: rgba(227, 198, 127, 0.07);
  font-size: 0.9rem;
  line-height: 1.55;
  color: #e7e2d6 !important;
  -webkit-text-fill-color: #e7e2d6 !important;
}

html.dmc-root .dai-read__ask {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--dai-line);
}

html.dmc-root .dai-next {
  margin-top: 14px;
  padding: 12px 14px 14px;
  border: 1px solid rgba(227, 198, 127, 0.24);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(227, 198, 127, 0.08), rgba(227, 198, 127, 0.02));
  animation: dai-open 0.24s ease backwards;
}

html.dmc-root .dai-next__title {
  margin: 0 0 9px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-next .dai-chip {
  background: rgba(255, 255, 255, 0.06);
}

html.dmc-root .dai-chip--open {
  border-color: rgba(227, 198, 127, 0.5);
  color: #f7ead0 !important;
  -webkit-text-fill-color: #f7ead0 !important;
  font-weight: 600;
}

html.dmc-root .dai-chip--open::before {
  content: '❯';
  margin-right: 7px;
  font-size: 0.72rem;
  color: var(--dai-gold);
}

html.dmc-root .dai-chip--chart {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 12px;
  border-color: rgba(227, 198, 127, 0.45);
  background: rgba(227, 198, 127, 0.1);
  color: #f2e2b8 !important;
  -webkit-text-fill-color: #f2e2b8 !important;
  font-weight: 600;
}

html.dmc-root .dai-chip--chart::before {
  content: '◈';
  color: var(--dai-gold);
}

html.dmc-root .dai-read__ask-title {
  margin: 0 0 8px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

html.dmc-root .dai-chip {
  appearance: none;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--dai-line-2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--dai-ink) !important;
  -webkit-text-fill-color: var(--dai-ink) !important;
  font: inherit;
  font-size: 0.86rem;
  text-align: left;
  cursor: pointer;
}

html.dmc-root .dai-chip:hover {
  border-color: rgba(227, 198, 127, 0.55);
  background: var(--dai-gold-soft);
}

html.dmc-root .dai-more {
  appearance: none;
  width: 100%;
  min-height: 46px;
  margin-top: 8px;
  border: 1px dashed rgba(227, 198, 127, 0.4);
  border-radius: 14px;
  background: transparent;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

/* ---------- sticky bottom ---------- */

html.dmc-root .dai-bottom {
  flex-shrink: 0;
  padding: 8px 14px calc(10px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--dai-line);
  background: rgba(10, 11, 15, 0.94);
}

html.dmc-root .dai-error {
  margin: 0 auto 8px;
  max-width: 760px;
  padding: 9px 12px;
  border: 1px solid rgba(226, 61, 61, 0.4);
  border-radius: 12px;
  background: rgba(226, 61, 61, 0.1);
  font-size: 0.85rem;
  color: #f6d3ce !important;
  -webkit-text-fill-color: #f6d3ce !important;
}

html.dmc-root .dai-error[hidden] {
  display: none;
}

html.dmc-root .dai-suggest {
  max-width: 760px;
  margin: 0 auto 8px;
}

html.dmc-root .dai-suggest[hidden] {
  display: none;
}

html.dmc-root .dai-suggest__label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 6px;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8f8b82 !important;
  -webkit-text-fill-color: #8f8b82 !important;
}

html.dmc-root .dai-suggest__count {
  padding-left: 6px;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  color: var(--dai-gold) !important;
  -webkit-text-fill-color: var(--dai-gold) !important;
}

html.dmc-root .dai-suggest__label::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--dai-gold);
  box-shadow: 0 0 0 3px rgba(227, 198, 127, 0.18);
  animation: dai-pulse 2.4s ease-in-out infinite;
}

html.dmc-root .dai-ctas {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

html.dmc-root .dai-ctas::-webkit-scrollbar {
  display: none;
}

html.dmc-root .dai-ctas[hidden] {
  display: none;
}

/* Desktop has room to show every suggestion at once. */
@media (min-width: 820px) {
  html.dmc-root .dai-ctas {
    flex-wrap: wrap;
    overflow-x: visible;
  }
}

/*
 * Mobile: suggestions stack full width so every question is readable in full.
 * A cut-off question has no pull, so nothing is truncated here.
 */
@media (max-width: 819px) {
  html.dmc-root .dai-suggest {
    margin-bottom: 6px;
  }

  html.dmc-root .dai-suggest__label {
    margin-bottom: 4px;
    font-size: 0.6rem;
  }

  html.dmc-root .dai-ctas {
    flex-direction: column;
    gap: 5px;
    padding-bottom: 0;
    overflow-x: visible;
  }

  html.dmc-root .dai-cta {
    width: 100%;
    justify-content: flex-start;
    gap: 7px;
    min-height: 36px;
    padding: 6px 12px;
    font-size: 0.83rem;
    text-align: left;
  }

  html.dmc-root .dai-cta__emoji {
    font-size: 0.9rem;
  }

  html.dmc-root .dai-cta__label {
    white-space: normal;
    line-height: 1.25;
  }

  html.dmc-root .dai-cta__go {
    margin-left: auto;
    padding-left: 6px;
    font-size: 0.85rem;
  }
}

html.dmc-root .dai-cta {
  appearance: none;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(227, 198, 127, 0.38);
  border-radius: 999px;
  background: var(--dai-gold-soft);
  color: #f7ead0 !important;
  -webkit-text-fill-color: #f7ead0 !important;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

html.dmc-root .dai-cta:hover {
  border-color: rgba(227, 198, 127, 0.75);
  background: rgba(227, 198, 127, 0.2);
  transform: translateY(-1px);
}

html.dmc-root .dai-cta:active {
  transform: translateY(0);
}

/* The first suggestion is the one Destiny AI most recommends. */
html.dmc-root .dai-cta--lead {
  border-color: transparent;
  background: linear-gradient(135deg, #f0d79a 0%, #e3c67f 55%, #cfa858 100%);
  color: #191207 !important;
  -webkit-text-fill-color: #191207 !important;
  font-weight: 700;
  box-shadow: 0 6px 18px rgba(227, 198, 127, 0.22);
}

html.dmc-root .dai-cta--lead:hover {
  background: linear-gradient(135deg, #f6e3b4 0%, #ebd193 55%, #d9b465 100%);
}

html.dmc-root .dai-cta__emoji {
  font-size: 1.02rem;
}

html.dmc-root .dai-cta__go {
  font-size: 0.95rem;
  opacity: 0.7;
}

html.dmc-root .dai-input {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  max-width: 760px;
  margin: 0 auto;
  padding: 7px 7px 7px 16px;
  border: 1px solid var(--dai-line-2);
  border-radius: 26px;
  background: var(--dai-field);
}

html.dmc-root .dai-input:focus-within {
  border-color: rgba(227, 198, 127, 0.6);
}

html.dmc-root .dai-input textarea {
  flex: 1;
  min-width: 0;
  min-height: 26px;
  max-height: 140px;
  padding: 6px 0;
  border: 0;
  background: transparent;
  color: var(--dai-ink) !important;
  -webkit-text-fill-color: var(--dai-ink) !important;
  font: inherit;
  font-size: 16px;
  line-height: 1.45;
  resize: none;
}

html.dmc-root .dai-input textarea:focus {
  outline: none;
}

html.dmc-root .dai-input textarea::placeholder {
  color: #8e8b85 !important;
  -webkit-text-fill-color: #8e8b85 !important;
  opacity: 1;
}

html.dmc-root .dai-input button {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--dai-gold);
  color: #171208 !important;
  -webkit-text-fill-color: #171208 !important;
  font: inherit;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

html.dmc-root .dai-input button:disabled,
html.dmc-root .dai-input textarea:disabled {
  opacity: 0.45;
}

html.dmc-root .dai-fine {
  max-width: 760px;
  margin: 8px auto 0;
  font-size: 0.7rem;
  text-align: center;
  color: #7d7a74 !important;
  -webkit-text-fill-color: #7d7a74 !important;
}

html.dmc-root .dai-ghost:focus-visible,
html.dmc-root .dai-chip:focus-visible,
html.dmc-root .dai-cta:focus-visible,
html.dmc-root .dai-primary:focus-visible,
html.dmc-root .dai-read__head:focus-visible,
html.dmc-root .dai-more:focus-visible {
  outline: 2px solid var(--dai-gold);
  outline-offset: 2px;
}

/* ---------- the calculated chart (engine SVG, restyled for the card) ---------- */

html.dmc-root .dmc-coach-chart {
  --dmc-dim: 0.36;
  --canvas: #f7f3eb;
  --surface: #fffdf8;
  --tint: #f3eee4;
  --line: #d9d0c2;
  --ink: #13151a;
  --ink-2: #3d414d;
  --ink-3: #6b7080;
  --pine: #1e5147;
  --pine-dark: #163c35;
  --bronze: #a2762f;
  --dm-text-primary: #13151a;
  color: #13151a;
}

html.dmc-root .dmc-coach-chart,
html.dmc-root .dmc-coach-chart * {
  color: inherit;
  -webkit-text-fill-color: unset;
}

html.dmc-root .dmc-coach-chart .cls-18,
html.dmc-root .dmc-coach-chart .cls-3,
html.dmc-root .dmc-coach-chart .cls-4 {
  stroke: #16362f !important;
  fill: none !important;
  stroke-width: 1.85px !important;
  opacity: 1;
}

/* Money current (green) and love current (red), with their $ and heart marks. */
html.dmc-root .dmc-coach-chart .cls-5,
html.dmc-root .dmc-coach-chart .cls-6 {
  stroke: #12873a !important;
  fill: #12873a !important;
  stroke-width: 2.6px !important;
}

html.dmc-root .dmc-coach-chart .cls-7,
html.dmc-root .dmc-coach-chart .cls-8 {
  stroke: #d6342f !important;
  fill: #d6342f !important;
  stroke-width: 2.6px !important;
}

html.dmc-root .dmc-coach-chart path.cls-53 {
  fill: #d6342f !important;
}

html.dmc-root .dmc-coach-chart .cls-56 {
  fill: #12873a !important;
  font-size: 30px !important;
  font-weight: 800 !important;
}

html.dmc-root .dmc-coach-chart #matrix-frame svg {
  width: 34px !important;
  height: 34px !important;
  overflow: visible;
}

html.dmc-root .dmc-coach-chart #points-basic circle:not(.cls-25),
html.dmc-root .dmc-coach-chart .cls-10,
html.dmc-root .dmc-coach-chart .cls-13,
html.dmc-root .dmc-coach-chart .cls-15,
html.dmc-root .dmc-coach-chart .cls-19,
html.dmc-root .dmc-coach-chart .cls-21,
html.dmc-root .dmc-coach-chart .cls-22,
html.dmc-root .dmc-coach-chart .cls-23,
html.dmc-root .dmc-coach-chart .cls-24,
html.dmc-root .dmc-coach-chart .cls-26 {
  fill: #fff !important;
  stroke: #16362f !important;
  stroke-width: 1.8px !important;
}

html.dmc-root .dmc-coach-chart #points-basic circle.cls-25,
html.dmc-root .dmc-coach-chart .cls-25,
html.dmc-root .dmc-coach-chart circle.cls-25 {
  fill: #1e5147 !important;
  stroke: #163c35 !important;
}

html.dmc-root .dmc-coach-chart .matrix-value-point,
html.dmc-root .dmc-coach-chart .cls-54,
html.dmc-root .dmc-coach-chart .cls-55,
html.dmc-root .dmc-coach-chart .cls-57,
html.dmc-root .dmc-coach-chart .cls-58,
html.dmc-root .dmc-coach-chart .cls-59,
html.dmc-root .dmc-coach-chart .cls-60,
html.dmc-root .dmc-coach-chart .cls-33,
html.dmc-root .dmc-coach-chart .cls-28,
html.dmc-root .dmc-coach-chart .cls-29,
html.dmc-root .dmc-coach-chart .cls-43,
html.dmc-root .dmc-coach-chart .cls-44,
html.dmc-root .dmc-coach-chart .cls-61,
html.dmc-root .dmc-coach-chart #points-years text,
html.dmc-root .dmc-coach-chart #points-basic text {
  fill: #14110d !important;
  font-weight: 800 !important;
  stroke: #f7f3eb;
  stroke-width: 2.4px;
  paint-order: stroke fill;
}

html.dmc-root .dmc-coach-chart #points-years text {
  fill: #3d3224 !important;
  font-weight: 700 !important;
}

html.dmc-root .dmc-coach-chart #epoint {
  fill: #f6e7b8 !important;
  stroke: none;
}

/* Dimming skips the love/money currents so those markers never disappear. */
html.dmc-root .dmc-coach-chart.active-highlight .cls-3,
html.dmc-root .dmc-coach-chart.active-highlight .cls-4,
html.dmc-root .dmc-coach-chart.active-highlight .cls-18,
html.dmc-root .dmc-coach-chart.active-highlight .cls-44,
html.dmc-root .dmc-coach-chart.active-highlight #points-basic circle,
html.dmc-root .dmc-coach-chart.active-highlight #points-basic text,
html.dmc-root .dmc-coach-chart.active-highlight #points-years text {
  opacity: var(--dmc-dim);
  transition: opacity 0.2s ease;
}

html.dmc-root .dmc-coach-chart.active-highlight [data-id].highlighted {
  opacity: 1 !important;
}

html.dmc-root .dmc-coach-chart.active-highlight circle[data-id].highlighted {
  stroke-width: 3.5px !important;
}

html.dmc-root .dmc-coach-chart .dm-chart-area {
  display: block !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
}

html.dmc-root .dmc-coach-chart .dm-chart-board {
  display: block !important;
  grid-template-columns: none !important;
  max-width: 100% !important;
  margin: 0 auto;
}

html.dmc-root .dmc-coach-chart .dm-chart-board > :not(.pento) {
  display: none !important;
}

html.dmc-root .dmc-coach-chart .dm-health-map,
html.dmc-root .dmc-coach-chart .dm-chart-group {
  display: none !important;
}

/* dmc-app.css pins #matrix to max-width:none !important, so match it here. */
html.dmc-root .dai-chart .dmc-coach-chart #matrix {
  display: block;
  width: 100% !important;
  max-width: 420px !important;
  max-height: none;
  height: auto;
  margin: 0 auto !important;
}

html.dmc-root .dai-chart:not(.is-zoom) .dmc-coach-chart #points-years text {
  display: none;
}

html.dmc-root .dai-chart.is-zoom .dmc-coach-chart {
  --dmc-dim: 0.4;
}

html.dmc-root .dai-chart.is-zoom .dmc-coach-chart #matrix {
  width: auto !important;
  max-width: 100% !important;
  height: calc(100vh - 170px);
  max-height: 720px;
  margin: 0 auto !important;
}

/* ---------- animations ---------- */

@keyframes dai-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

@keyframes dai-open {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: none; }
}

@keyframes dai-pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(227, 198, 127, 0.18); }
  50% { box-shadow: 0 0 0 6px rgba(227, 198, 127, 0.05); }
}

@keyframes dai-dot {
  0%, 80%, 100% { opacity: 0.25; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-3px); }
}

/* ---------- larger screens ---------- */

@media (min-width: 820px) {
  html.dmc-root .dai-top {
    height: 60px;
    padding: 0 20px;
  }

  html.dmc-root .dai-thread {
    gap: 22px;
    padding: 26px 20px 12px;
  }

  html.dmc-root .dai-msg {
    gap: 14px;
  }

  html.dmc-root .dai-msg__orb {
    width: 30px;
    height: 30px;
  }

  html.dmc-root .dai-bottom {
    padding: 10px 20px 16px;
  }

  html.dmc-root .dai-read__head {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
  }

  html.dmc-root .dai-read__seats {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
    color: var(--dai-gold) !important;
    -webkit-text-fill-color: var(--dai-gold) !important;
  }

  html.dmc-root .dai-chart {
    padding: 12px 14px 10px;
  }

  html.dmc-root .dai-chart .dmc-coach-chart #matrix {
    max-width: 460px !important;
  }

  html.dmc-root .dai-chart.is-zoom {
    inset: 60px 0 0;
    padding: 20px;
  }

  html.dmc-root .dai-primary {
    grid-column: auto;
    align-self: end;
  }

  html.dmc-root .dai-dob {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.1fr) minmax(0, 0.8fr) auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.dmc-root .dai-msg,
  html.dmc-root .dai-read__body {
    animation: none;
  }

  html.dmc-root .dai-dots i,
  html.dmc-root .dai-suggest__label::before,
  html.dmc-root .dai-next {
    animation: none;
  }

  html.dmc-root .dai-cta:hover {
    transform: none;
  }
}
