/* Two-column grid: FAQ list + interests */
.faq-care-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.faq-care-grid .about-care-list {
  padding-top: 0;
}

@media (max-width: 900px) {
  .faq-care-grid {
    grid-template-columns: 1fr;
  }

  .north-chat {
    min-height: 560px;
  }

  .north-chat-thread {
    min-height: 370px;
  }
}

@media (max-width: 640px) {
  .north-chat {
    min-height: 500px;
  }

  .north-chat-thread {
    min-height: 310px;
  }
}

/* North chat widget container */
.north-chat {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow);
  min-height: 620px;
  scroll-margin-top: 120px;
}

/* Header */
.north-chat-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--line);
  background: var(--moonstone);
}

.north-chat-avatar {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.north-chat-name {
  display: block;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1rem;
  color: var(--harbor);
  line-height: 1.2;
}

.north-chat-tagline {
  display: block;
  font-size: 0.75rem;
  color: var(--slate);
  line-height: 1.2;
}

/* Message thread */
.north-chat-thread {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.25rem;
  flex: 1;
  min-height: 430px;
  max-height: 680px;
  overflow-y: auto;
}

/* Individual messages */
.north-message {
  max-width: 88%;
  padding: 0.65rem 0.9rem;
  border-radius: 12px;
  font-size: 0.875rem;
  line-height: 1.55;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 200ms ease-out, transform 200ms var(--ease-out);
}

@starting-style {
  .north-message {
    opacity: 0;
    transform: translateY(6px);
  }
}

.north-message--north {
  background: var(--moonstone-2);
  color: var(--harbor-soft);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.north-message--user {
  background: var(--harbor);
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

/* Input form */
.north-chat-form {
  padding: 0.85rem 1.25rem;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  background: var(--moonstone);
}

.north-chat-input-row {
  display: flex;
  gap: 0.5rem;
}

.north-chat-input-row input {
  flex: 1;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: var(--sans);
  font-size: 0.875rem;
  color: var(--harbor);
  background: #fff;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.north-chat-input-row input:focus-visible {
  border-color: var(--blueprint);
  box-shadow: var(--focus-ring);
  outline: 2px solid var(--blueprint);
  outline-offset: 2px;
}

.north-chat-input-row button {
  padding: 0.5rem 1rem;
  background: var(--harbor);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  transition: opacity 180ms ease, transform 160ms var(--ease-out);
}

.north-chat-input-row button:active {
  transform: scale(0.97);
}

.north-chat-input-row button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Typing indicator */
.north-typing {
  display: flex;
  align-items: center;
  gap: 5px;
}

.north-typing span {
  animation: north-dot 1.4s ease-in-out infinite;
  background: var(--slate);
  border-radius: 50%;
  height: 6px;
  opacity: 0.4;
  width: 6px;
}

.north-typing span:nth-child(2) { animation-delay: 0.2s; }
.north-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes north-dot {
  0%, 60%, 100% {
    opacity: 0.4;
    transform: scale(0.85);
  }
  30% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Character counter */
.north-chat-counter {
  font-size: 0.72rem;
  color: var(--slate);
  text-align: right;
}

.north-chat-counter.near-limit {
  color: #c0392b;
}

@media (hover: hover) and (pointer: fine) {
  .north-chat-input-row button:hover {
    opacity: 0.75;
  }
}

@media (prefers-reduced-motion: reduce) {
  .north-chat-input-row button:active,
  .north-message {
    transform: none;
    transition: none;
  }

  .north-typing span {
    animation: none;
    opacity: 0.5;
  }
}
