:root {
  --support-bg: #071014;
  --support-panel: #10191f;
  --support-panel-2: #13232b;
  --support-border: rgba(255,255,255,0.09);
  --support-text: #e7f0f3;
  --support-muted: #8ca0a8;
  --support-teal: #00c9a7;
  --support-teal-soft: rgba(0,201,167,0.13);
  --support-warn: #f4b860;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--support-bg);
  color: var(--support-text);
}

.support-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px;
}

.support-panel {
  width: min(900px, 100%);
  min-height: min(760px, calc(100vh - 56px));
  background: var(--support-panel);
  border: 1px solid var(--support-border);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 90px rgba(0,0,0,0.34);
}

.support-header {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  border-bottom: 1px solid var(--support-border);
  color: var(--support-muted);
  font-size: 0.9rem;
}

.brand-link img {
  height: 38px;
  width: auto;
  display: block;
}

.intro-view,
.result-view {
  padding: clamp(28px, 7vw, 72px);
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--support-teal);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0 0 16px;
  color: var(--support-text);
  font-family: Syne, system-ui, sans-serif;
  line-height: 1.08;
  font-size: clamp(2rem, 6vw, 4.1rem);
  letter-spacing: 0;
}

h2 { font-size: clamp(1.8rem, 5vw, 3.2rem); }

.lede {
  max-width: 620px;
  margin: 0 0 28px;
  color: var(--support-muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.start-form {
  display: grid;
  gap: 16px;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--support-muted);
  font-size: 0.84rem;
  font-weight: 700;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--support-border);
  border-radius: 8px;
  background: #0b1419;
  color: var(--support-text);
  font: inherit;
  padding: 13px 14px;
  outline: none;
}

textarea {
  resize: none;
  min-height: 52px;
  max-height: 140px;
}

input:focus,
textarea:focus {
  border-color: rgba(0,201,167,0.58);
  box-shadow: 0 0 0 3px rgba(0,201,167,0.09);
}

button {
  border: 0;
  border-radius: 8px;
  background: var(--support-teal);
  color: #071014;
  min-height: 48px;
  padding: 0 20px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

button:disabled {
  opacity: 0.48;
  cursor: wait;
}

.chat-view {
  display: none;
  flex: 1;
  min-height: 0;
  flex-direction: column;
  padding: 24px;
}

.chat-view.active { display: flex; }
.intro-view.hidden,
.result-view { display: none; }
.result-view.active { display: block; }

.messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 6px 4px 18px;
}

.message {
  width: fit-content;
  max-width: min(690px, 88%);
  padding: 13px 16px;
  border-radius: 8px;
  line-height: 1.58;
  white-space: pre-wrap;
}

.message.assistant {
  background: var(--support-panel-2);
  border: 1px solid var(--support-border);
}

.message.user {
  align-self: flex-end;
  background: var(--support-teal-soft);
  border: 1px solid rgba(0,201,167,0.34);
  color: #b9fff2;
}

.typing {
  display: none;
  align-self: flex-start;
  background: var(--support-panel-2);
  border: 1px solid var(--support-border);
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 12px;
}

.typing span {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 4px;
  border-radius: 50%;
  background: var(--support-muted);
  animation: pulse 1.1s infinite ease-in-out;
}

.typing span:nth-child(2) { animation-delay: 0.14s; }
.typing span:nth-child(3) { animation-delay: 0.28s; }

.chat-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: end;
}

.result-block {
  margin-top: 20px;
  padding: 20px;
  background: var(--support-panel-2);
  border: 1px solid var(--support-border);
  border-radius: 8px;
}

.result-block.muted {
  background: transparent;
}

.result-block h3 {
  margin: 0 0 10px;
  font-size: 0.95rem;
  color: var(--support-teal);
}

.result-block p {
  margin: 0;
  color: var(--support-muted);
  line-height: 1.62;
}

.option {
  margin: 0 0 10px;
  color: var(--support-text);
  line-height: 1.55;
}

.option:last-child { margin-bottom: 0; }

@keyframes pulse {
  0%, 80%, 100% { transform: scale(0.4); opacity: 0.55; }
  40% { transform: scale(1); opacity: 1; }
}

@media (max-width: 720px) {
  .support-shell { padding: 0; }
  .support-panel {
    min-height: 100vh;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }
  .support-header {
    height: 66px;
    padding: 0 18px;
  }
  .support-header span { display: none; }
  .intro-view,
  .result-view {
    padding: 26px 18px;
  }
  .field-grid {
    grid-template-columns: 1fr;
  }
  .chat-view {
    padding: 16px;
  }
  .message {
    max-width: 94%;
  }
}
