:root {
  --atlas-ink:#08143a;
  --atlas-muted:#5b6b83;
  --atlas-line:#d9e3ef;
  --atlas-blue:#075bf2;
  --atlas-blue-dark:#092a6b;
  --atlas-green:#0d9049;
  --atlas-yellow:#f59e0b;
  --atlas-red:#dc2626;
  --atlas-bg:#f5f8fc;
  --atlas-card:#ffffff;
}

* { box-sizing:border-box; }

body.atlas-ai-page {
  margin:0;
  min-height:100vh;
  color:var(--atlas-ink);
  background:
    radial-gradient(circle at top left, rgba(7,91,242,.12), transparent 32rem),
    linear-gradient(180deg,#fbfdff 0%,#eef4fb 100%);
  font-family:Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.hidden,
[hidden] { display:none !important; }

.atlas-zip-locked {
  overflow:hidden;
}

.atlas-zip-locked .atlas-chat-shell {
  max-height:100vh;
  overflow:hidden;
  filter:blur(7px);
  pointer-events:none;
  user-select:none;
}

.zip-gate {
  position:fixed;
  inset:0;
  z-index:10000;
  display:grid;
  place-items:center;
  padding:22px;
  background:rgba(8,20,58,.58);
  backdrop-filter:blur(10px);
}

.zip-gate-card {
  display:grid;
  gap:14px;
  width:min(100%,460px);
  border:1px solid rgba(207,224,246,.9);
  border-radius:20px;
  padding:28px;
  color:var(--atlas-ink);
  background:#fff;
  box-shadow:0 34px 90px rgba(8,20,58,.28);
}

.zip-gate-card .analyst-orb {
  margin-bottom:4px;
}

.zip-gate-card h2,
.zip-gate-card p {
  margin:0;
}

.zip-gate-card h2 {
  font-size:28px;
  line-height:34px;
  letter-spacing:0;
}

.zip-gate-card p {
  color:#31415b;
  font-size:15px;
  line-height:24px;
}

.zip-gate-input {
  display:grid;
  gap:7px;
  margin-top:2px;
}

.zip-gate-input span {
  color:var(--atlas-ink);
  font-size:13px;
  line-height:18px;
  font-weight:900;
}

.zip-gate-input input {
  width:100%;
  min-height:54px;
  border:1px solid #cfdbe9;
  border-radius:14px;
  padding:13px 15px;
  color:var(--atlas-ink);
  background:#fff;
  font:inherit;
  font-size:20px;
  font-weight:800;
  letter-spacing:0;
  box-shadow:0 10px 22px rgba(8,20,58,.05);
}

.zip-gate-card button {
  min-height:52px;
  border:0;
  border-radius:14px;
  padding:13px 16px;
  color:#fff;
  background:linear-gradient(135deg,#075bf2,#0d9049);
  font:inherit;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 14px 28px rgba(7,91,242,.2);
}

.zip-gate-card small {
  color:var(--atlas-muted);
  font-size:12px;
  line-height:18px;
}

.zip-gate-error {
  min-height:20px;
  color:#b42318 !important;
  font-size:13px !important;
  line-height:20px !important;
  font-weight:800;
}

.atlas-chat-shell {
  width:min(1220px, calc(100% - 28px));
  min-height:100vh;
  margin:0 auto;
  padding:18px 0 28px;
}

.atlas-chat-header {
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:center;
  min-height:64px;
}

.atlas-brand {
  display:flex;
  gap:12px;
  align-items:center;
  color:var(--atlas-ink);
  text-decoration:none;
}

.atlas-brand-mark,
.analyst-orb {
  display:grid;
  place-items:center;
  width:42px;
  height:42px;
  border-radius:14px;
  color:#fff;
  background:linear-gradient(145deg,#075bf2,#092a6b 72%);
  font-weight:900;
  box-shadow:0 16px 34px rgba(7,91,242,.22);
}

.atlas-brand strong,
.atlas-brand small { display:block; }
.atlas-brand strong { font-size:18px; line-height:22px; }
.atlas-brand small { color:var(--atlas-muted); font-size:12px; line-height:16px; }

.chat-stage {
  display:grid;
  grid-template-columns:340px minmax(0,1fr);
  gap:22px;
  align-items:stretch;
  min-height:calc(100vh - 112px);
}

.chat-rail {
  display:grid;
  gap:16px;
  align-content:start;
  padding-top:24px;
}

.analyst-card,
.community-card,
.chat-panel {
  border:1px solid var(--atlas-line);
  border-radius:18px;
  background:rgba(255,255,255,.9);
  box-shadow:0 24px 70px rgba(8,20,58,.08);
}

.analyst-card {
  padding:28px;
}

.community-card {
  padding:22px;
  background:linear-gradient(180deg,rgba(255,255,255,.94) 0%,rgba(248,251,255,.92) 100%);
}

.community-card h2 {
  margin:0 0 12px;
  color:var(--atlas-ink);
  font-size:22px;
  line-height:28px;
  letter-spacing:0;
}

.community-card p {
  margin:0 0 12px;
  color:#31415b;
  font-size:14px;
  line-height:22px;
}

.community-card p:last-child {
  margin-bottom:0;
}

.community-card strong {
  color:var(--atlas-ink);
}

.analyst-orb {
  width:62px;
  height:62px;
  border-radius:20px;
  margin-bottom:22px;
  font-size:28px;
}

.eyebrow {
  margin:0 0 8px;
  color:#075bf2;
  font-size:12px;
  line-height:16px;
  font-weight:900;
  letter-spacing:0;
  text-transform:uppercase;
}

.analyst-card h1 {
  margin:0 0 14px;
  color:var(--atlas-ink);
  font-size:38px;
  line-height:42px;
  letter-spacing:0;
}

.analyst-card p:last-child {
  margin:0;
  color:#31415b;
  font-size:15px;
  line-height:24px;
}

.chat-panel {
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
  overflow:hidden;
}

.chat-panel-head {
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:center;
  padding:18px 22px;
  border-bottom:1px solid var(--atlas-line);
  background:rgba(255,255,255,.92);
}

.chat-panel-head h2 {
  margin:0;
  font-size:20px;
  line-height:26px;
}

.chat-progress {
  border-radius:999px;
  padding:8px 12px;
  color:#0d9049;
  background:#e9f8ef;
  font-size:12px;
  font-weight:900;
}

.chat-log {
  display:flex;
  flex-direction:column;
  gap:14px;
  min-height:520px;
  max-height:calc(100vh - 250px);
  overflow:auto;
  padding:24px;
  scroll-behavior:smooth;
}

.message {
  display:grid;
  grid-template-columns:38px minmax(0,1fr);
  gap:12px;
  max-width:780px;
  animation:message-in .22s ease-out both;
}

.message.user {
  align-self:flex-end;
  grid-template-columns:minmax(0,1fr);
  max-width:min(680px,84%);
}

.avatar {
  display:grid;
  place-items:center;
  width:38px;
  height:38px;
  border-radius:13px;
  color:#fff;
  background:linear-gradient(145deg,#075bf2,#092a6b);
  font-weight:900;
}

.bubble {
  width:max-content;
  max-width:100%;
  border:1px solid var(--atlas-line);
  border-radius:18px;
  border-top-left-radius:6px;
  padding:13px 15px;
  background:#fff;
  color:var(--atlas-ink);
  box-shadow:0 12px 24px rgba(8,20,58,.06);
}

.message.user .bubble {
  justify-self:end;
  border-color:#075bf2;
  border-top-left-radius:18px;
  border-top-right-radius:6px;
  color:#fff;
  background:#075bf2;
  box-shadow:0 14px 28px rgba(7,91,242,.2);
}

.bubble p {
  margin:0;
  font-size:15px;
  line-height:23px;
}

.typing .bubble {
  display:flex;
  gap:5px;
  align-items:center;
  width:64px;
  min-height:42px;
}

.typing i {
  width:7px;
  height:7px;
  border-radius:999px;
  background:#8fa1b8;
  animation:typing-dot 1s ease-in-out infinite;
}

.typing i:nth-child(2) { animation-delay:.12s; }
.typing i:nth-child(3) { animation-delay:.24s; }

.choice-dock {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  width:100%;
}

.choice-dock button,
.report-actions button,
.send-button {
  min-height:48px;
  border:0;
  border-radius:12px;
  padding:12px 16px;
  font:inherit;
  font-weight:900;
  cursor:pointer;
}

.choice-dock button {
  border:1px solid #cfe0f6;
  color:#075bf2;
  background:#fff;
  box-shadow:0 10px 20px rgba(8,20,58,.05);
}

.chat-composer {
  display:grid;
  grid-template-columns:1fr auto;
  gap:12px;
  align-items:end;
  padding:16px;
  border-top:1px solid var(--atlas-line);
  background:rgba(248,251,255,.9);
}

.composer-input {
  display:grid;
  gap:6px;
  margin:0;
}

.composer-input span {
  color:var(--atlas-muted);
  font-size:12px;
  font-weight:800;
}

.composer-input input {
  width:100%;
  min-height:52px;
  border:1px solid #cfdbe9;
  border-radius:14px;
  padding:13px 15px;
  color:var(--atlas-ink);
  background:#fff;
  font:inherit;
  box-shadow:0 10px 22px rgba(8,20,58,.05);
}

.send-button {
  min-width:104px;
  color:#fff;
  background:linear-gradient(135deg,#075bf2,#0d9049);
  box-shadow:0 14px 28px rgba(7,91,242,.2);
}

.send-button:disabled {
  opacity:.58;
  cursor:wait;
}

.upload-dock {
  grid-column:1 / -1;
}

.upload-drop {
  display:grid;
  place-items:center;
  min-height:190px;
  margin:0;
  border:2px dashed #9ebef3;
  border-radius:16px;
  padding:24px;
  color:var(--atlas-ink);
  background:#fff;
  text-align:center;
  cursor:pointer;
}

.upload-drop input {
  position:absolute;
  width:1px;
  height:1px;
  opacity:0;
}

.upload-cloud {
  display:grid;
  place-items:center;
  width:62px;
  height:62px;
  margin-bottom:10px;
  border-radius:999px;
  color:#075bf2;
  background:#eef5ff;
}

.upload-cloud::before {
  content:"";
  width:34px;
  height:34px;
  background:currentColor;
  mask:url("data:image/svg+xml,%3Csvg width='34' height='34' viewBox='0 0 34 34' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.4 25.5H8.6C5.6 25.5 3.2 23.1 3.2 20.1C3.2 17.4 5.2 15.1 7.8 14.7C8.8 10.7 12.4 7.8 16.7 7.8C20.6 7.8 24 10.3 25.2 13.8C28.4 14.2 30.8 16.8 30.8 20.1C30.8 23.1 28.4 25.5 25.4 25.5H23.3' stroke='black' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M17 25.5V15.2M12.8 19.2L17 15L21.2 19.2' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask:url("data:image/svg+xml,%3Csvg width='34' height='34' viewBox='0 0 34 34' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.4 25.5H8.6C5.6 25.5 3.2 23.1 3.2 20.1C3.2 17.4 5.2 15.1 7.8 14.7C8.8 10.7 12.4 7.8 16.7 7.8C20.6 7.8 24 10.3 25.2 13.8C28.4 14.2 30.8 16.8 30.8 20.1C30.8 23.1 28.4 25.5 25.4 25.5H23.3' stroke='black' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M17 25.5V15.2M12.8 19.2L17 15L21.2 19.2' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}

.upload-drop strong,
.upload-drop small,
.upload-drop em { display:block; }
.upload-drop strong { font-size:18px; line-height:24px; }
.upload-drop small { margin-top:4px; color:var(--atlas-muted); font-size:13px; }
.upload-drop em { margin-top:10px; color:#075bf2; font-style:normal; font-weight:800; overflow-wrap:anywhere; }

.process-card,
.extracted-review-card,
.report-card {
  display:grid;
  gap:12px;
  min-width:min(640px,100%);
}

.extracted-review-card h4,
.extracted-review-card p {
  margin:0;
}

.extracted-review-card h4 {
  color:var(--atlas-ink);
  font-size:18px;
  line-height:24px;
}

.extracted-review-card p {
  color:#31415b;
  font-size:14px;
  line-height:22px;
}

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

.extracted-review-grid div {
  display:grid;
  gap:4px;
  border:1px solid #dbe7f5;
  border-radius:12px;
  padding:10px 12px;
  background:#f8fbff;
}

.extracted-review-grid span {
  color:var(--atlas-muted);
  font-size:11px;
  line-height:15px;
  font-weight:800;
  text-transform:uppercase;
}

.extracted-review-grid strong {
  color:var(--atlas-ink);
  font-size:14px;
  line-height:20px;
}

.process-row {
  display:grid;
  grid-template-columns:30px 1fr;
  gap:10px;
  align-items:center;
  min-height:38px;
  border:1px solid #e2e8f0;
  border-radius:12px;
  padding:8px 10px;
  background:#fff;
}

.process-row span {
  display:grid;
  place-items:center;
  width:24px;
  height:24px;
  border-radius:999px;
  color:#fff;
  background:#0d9049;
  font-size:13px;
  font-weight:900;
}

.process-row.is-active span {
  background:#075bf2;
  animation:pulse 1.15s ease-in-out infinite;
}

.report-card {
  border:1px solid var(--atlas-line);
  border-radius:18px;
  padding:18px;
  background:#fff;
  box-shadow:0 20px 46px rgba(8,20,58,.09);
}

.report-top {
  display:grid;
  grid-template-columns:auto 1fr;
  gap:16px;
  align-items:center;
}

.score-ring {
  --score:85;
  display:grid;
  place-items:center;
  width:112px;
  height:112px;
  border-radius:999px;
  background:conic-gradient(from -90deg,#dc2626 0 26%,#f59e0b 26% 66%,#0d9049 66% 100%);
  box-shadow:0 14px 30px rgba(8,20,58,.12);
}

.score-ring strong {
  display:grid;
  place-items:center;
  width:78px;
  height:78px;
  border-radius:999px;
  color:var(--atlas-ink);
  background:#fff;
  font-size:34px;
  line-height:1;
}

.report-card h3,
.report-card h4,
.report-card p { margin:0; }
.report-card h3 { font-size:22px; line-height:28px; }
.report-card h4 { font-size:16px; line-height:22px; }
.report-card p { color:#31415b; font-size:14px; line-height:22px; }

.report-section {
  border-top:1px solid #e2e8f0;
  padding-top:12px;
}

.report-section ul {
  display:grid;
  gap:7px;
  margin:8px 0 0;
  padding:0;
  list-style:none;
}

.report-section li {
  position:relative;
  padding-left:18px;
  color:#31415b;
  font-size:14px;
  line-height:21px;
}

.report-section li::before {
  content:"";
  position:absolute;
  left:0;
  top:8px;
  width:7px;
  height:7px;
  border-radius:999px;
  background:#075bf2;
}

.report-actions {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}

.report-actions button {
  color:#075bf2;
  background:#eef5ff;
}

.report-actions button.primary {
  color:#fff;
  background:#075bf2;
}

.report-actions button.premium-coming-soon {
  display:grid;
  gap:4px;
  place-items:center;
  border:1px solid #b8cde8;
  color:var(--atlas-ink);
  background:linear-gradient(180deg,#eef5ff 0%,#e4edf8 100%);
}

.premium-coming-soon span,
.premium-coming-soon small {
  display:block;
}

.premium-coming-soon small {
  border-radius:999px;
  padding:3px 9px;
  color:#31415b;
  background:#fff;
  font-size:11px;
  line-height:15px;
  font-weight:900;
}

.advisor-gate {
  display:grid;
  gap:10px;
  border:1px solid #cfe0f6;
  border-radius:16px;
  padding:16px;
  background:linear-gradient(180deg,#f8fbff 0%,#ffffff 100%);
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.8);
}

.advisor-gate h4 {
  font-size:18px;
  line-height:24px;
}

.advisor-gate-service {
  border-color:#b8dfc9;
  background:linear-gradient(180deg,#f4fbf7 0%,#ffffff 100%);
}

.advisor-profile {
  display:grid;
  gap:3px;
  border:1px solid #e2e8f0;
  border-radius:14px;
  padding:12px;
  background:#fff;
  color:var(--atlas-ink);
  font-size:14px;
  line-height:21px;
}

.advisor-profile strong {
  margin-bottom:2px;
  color:var(--atlas-ink);
  font-size:13px;
  text-transform:uppercase;
  letter-spacing:.04em;
}

.advisor-profile a {
  color:#075bf2;
  font-weight:800;
  overflow-wrap:anywhere;
}

.what-next {
  display:grid;
  gap:8px;
  border-top:1px solid #d8efe2;
  padding-top:12px;
}

.what-next ul {
  display:grid;
  gap:6px;
  margin:0;
  padding-left:18px;
  color:#31415b;
  font-size:14px;
  line-height:21px;
}

.advisor-options {
  display:grid;
  grid-template-columns:1fr;
  gap:9px;
  margin-top:4px;
}

.advisor-options button {
  min-height:46px;
  border:1px solid #cfe0f6;
  border-radius:12px;
  padding:11px 13px;
  color:#075bf2;
  background:#fff;
  font:inherit;
  font-size:14px;
  font-weight:900;
  cursor:pointer;
}

.advisor-options button.primary {
  border-color:#075bf2;
  color:#fff;
  background:#075bf2;
  box-shadow:0 12px 24px rgba(7,91,242,.2);
}

.post-report-engagement {
  display:grid;
  gap:12px;
}

.referral-card,
.feature-card {
  display:grid;
  gap:10px;
  border:1px solid #d7e5f5;
  border-radius:16px;
  padding:16px;
  background:linear-gradient(180deg,#ffffff 0%,#f8fbff 100%);
}

.feature-card.is-highlighted {
  border-color:#075bf2;
  box-shadow:0 0 0 4px rgba(7,91,242,.12), 0 18px 36px rgba(7,91,242,.14);
}

.referral-card h4,
.feature-card h4,
.referral-card p,
.feature-card p {
  margin:0;
}

.referral-card h4,
.feature-card h4 {
  color:var(--atlas-ink);
  font-size:18px;
  line-height:24px;
}

.referral-card p,
.feature-card p {
  color:#31415b;
  font-size:14px;
  line-height:22px;
}

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

.share-actions button,
.feature-update-button {
  min-height:46px;
  border:1px solid #cfe0f6;
  border-radius:12px;
  padding:11px 13px;
  color:#075bf2;
  background:#fff;
  font:inherit;
  font-size:14px;
  font-weight:900;
  cursor:pointer;
}

.feature-update-button {
  border-color:#075bf2;
  color:#fff;
  background:#075bf2;
  box-shadow:0 12px 24px rgba(7,91,242,.2);
}

.feature-opt-in {
  display:flex;
  gap:10px;
  align-items:flex-start;
  border:1px solid #dbe7f5;
  border-radius:12px;
  padding:11px 12px;
  background:#fff;
  color:var(--atlas-ink);
  font-size:14px;
  line-height:20px;
  font-weight:800;
}

.feature-opt-in input {
  width:18px;
  height:18px;
  margin:1px 0 0;
  accent-color:#075bf2;
}

.share-status {
  min-height:18px;
  color:#0d9049 !important;
  font-size:12px !important;
  line-height:18px !important;
  font-weight:800;
}

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

@keyframes typing-dot {
  0%, 80%, 100% { opacity:.35; transform:translateY(0); }
  40% { opacity:1; transform:translateY(-4px); }
}

@keyframes pulse {
  0%, 100% { box-shadow:0 0 0 0 rgba(7,91,242,.22); }
  50% { box-shadow:0 0 0 8px rgba(7,91,242,0); }
}

@media (max-width:900px) {
  .atlas-chat-shell { width:min(100% - 18px,760px); padding-top:10px; }
  .chat-stage { grid-template-columns:1fr; min-height:auto; }
  .chat-rail { display:grid; padding-top:0; }
  .analyst-card { padding:20px; }
  .analyst-card h1 { font-size:30px; line-height:35px; }
  .community-card { padding:18px; }
  .chat-log { min-height:calc(100vh - 230px); max-height:calc(100vh - 230px); padding:16px; }
  .chat-panel-head { padding:14px 16px; }
  .chat-composer { grid-template-columns:1fr; }
  .send-button { width:100%; }
  .choice-dock { grid-template-columns:1fr; }
  .report-actions { grid-template-columns:1fr; }
  .share-actions { grid-template-columns:1fr; }
  .message.user { max-width:92%; }
  .report-top { grid-template-columns:1fr; }
  .extracted-review-grid { grid-template-columns:1fr; }
}
