/* Nextpoint Architecture Portal — Custom Styles */

:root {
  --md-primary-fg-color: #1a2942;
  --md-accent-fg-color: #3182ce;
}

/* Drift status colors */
.drift-p0 { color: #e53e3e; font-weight: bold; }
.drift-p1 { color: #d69e2e; font-weight: bold; }
.drift-ok { color: #38a169; font-weight: bold; }

/* Chat widget */
#ask-architecture-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--md-primary-fg-color);
  color: white;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  font-size: 24px;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}
#ask-architecture-btn:hover {
  transform: scale(1.1);
}

#ask-panel {
  position: fixed;
  bottom: 90px;
  right: 24px;
  width: 420px;
  max-height: 520px;
  background: var(--md-default-bg-color);
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
  z-index: 100;
  display: none;
  flex-direction: column;
  overflow: hidden;
}
#ask-panel.open { display: flex; }

#ask-panel-header {
  padding: 12px 16px;
  background: var(--md-primary-fg-color);
  color: white;
  font-weight: 600;
  font-size: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#ask-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  font-size: 14px;
  line-height: 1.6;
}

#ask-panel-input {
  display: flex;
  border-top: 1px solid var(--md-default-fg-color--lightest);
  padding: 8px;
}
#ask-panel-input input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 6px;
  font-size: 14px;
  outline: none;
  background: var(--md-default-bg-color);
  color: var(--md-default-fg-color);
}
#ask-panel-input button {
  margin-left: 8px;
  padding: 8px 16px;
  background: var(--md-primary-fg-color);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}
#ask-panel-input button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Source citations */
.ask-source {
  display: inline-block;
  background: var(--md-accent-fg-color--transparent);
  color: var(--md-accent-fg-color);
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
  margin: 2px 4px 2px 0;
  text-decoration: none;
}
.ask-source:hover {
  background: var(--md-accent-fg-color);
  color: white;
}

/* Loading spinner */
.ask-loading {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid var(--md-default-fg-color--lightest);
  border-top-color: var(--md-accent-fg-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
