/* ---------- AI Powered Community ---------- */

/* 1. ask-anything demo */
.aic-a-in { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.aic-a-in > * { min-width: 0; }
.aic-chat {
  display: flex; flex-direction: column; gap: 1rem; padding: 1.4rem; border-radius: 24px;
  background: linear-gradient(160deg, #15163d, #202158); box-shadow: var(--shadow-lg);
}
.aic-bar {
  display: flex; align-items: center; gap: 0.7rem; padding: 0.55rem 0.55rem 0.55rem 1rem; border-radius: 14px;
  background: #fff; color: var(--muted-2);
}
.aic-bar > .i { width: 1.1rem; height: 1.1rem; flex: none; }
.aic-typed { flex: 1; min-width: 0; font-size: 0.92rem; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aic-go { width: 36px; height: 36px; flex: none; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: var(--orange); color: #fff; }
.aic-go .i { width: 1rem; height: 1rem; }
.aic-msg { display: flex; gap: 0.7rem; }
.aic-msg.you { justify-content: flex-end; }
.aic-msg.you span { max-width: 80%; padding: 0.7rem 1rem; border-radius: 16px 16px 4px 16px; background: rgba(255, 255, 255, 0.12); color: #fff; font-size: 0.92rem; }
.aic-bot-ic { width: 34px; height: 34px; flex: none; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--orange); color: #fff; }
.aic-bot-ic .i { width: 1rem; height: 1rem; }
.aic-msg.bot > div { flex: 1; padding: 1rem; border-radius: 4px 16px 16px 16px; background: #fff; }
.aic-msg.bot p { font-size: 0.92rem; line-height: 1.55; color: var(--text); }
.aic-draft { display: grid; gap: 6px; margin-top: 0.8rem; padding: 0.8rem; border-radius: 10px; background: var(--bg-soft); border: 1px dashed var(--line); }
.aic-draft i { display: block; height: 7px; border-radius: 4px; background: var(--line); }
.aic-draft i:nth-child(1) { width: 60%; background: #fbe0bd; } .aic-draft i:nth-child(2) { width: 95%; } .aic-draft i:nth-child(3) { width: 85%; } .aic-draft i:nth-child(4) { width: 50%; }
.aic-actions { display: flex; gap: 0.5rem; margin-top: 0.8rem; }
.aic-actions span { padding: 0.45rem 0.85rem; border-radius: 9px; font-size: 0.8rem; font-weight: 600; border: 1px solid var(--line); color: var(--navy); }
.aic-actions span.primary { background: var(--navy); border-color: var(--navy); color: #fff; }
@media (prefers-reduced-motion: no-preference) {
  /* the reply appears after the question, like a real exchange */
  .aic-chat.rv.in .aic-msg.you { animation: aic-in 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) 0.35s both; }
  .aic-chat.rv.in .aic-msg.bot { animation: aic-in 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) 0.9s both; }
}
@keyframes aic-in { from { opacity: 0; translate: 0 10px; } to { opacity: 1; translate: 0 0; } }

.aic-try { display: block; margin-top: 1.6rem; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--orange-text); }
.aic-prompts { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.7rem; }
.aic-prompts li {
  display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.5rem 0.9rem; border-radius: 999px;
  background: var(--bg-soft); border: 1px solid var(--line); font-size: 0.9rem; color: var(--navy);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.aic-prompts li:hover { background: var(--orange-50); border-color: #fbe0bd; }
.aic-prompts .i { width: 0.9rem; height: 0.9rem; color: var(--orange-600); }

/* 2. capability matrix */
.aic-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.aic-col { padding: 1.6rem; border-radius: 24px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.aic-col.admin { background: var(--navy); border-color: var(--navy); }
.aic-col h3 { display: flex; align-items: center; gap: 0.7rem; padding-bottom: 1rem; margin-bottom: 0.4rem; border-bottom: 1px solid var(--line-2); font-size: 1.2rem; font-weight: 700; }
.aic-col.admin h3 { color: #fff; border-bottom-color: rgba(255, 255, 255, 0.12); }
.aic-col h3 > span { width: 40px; height: 40px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--orange); color: #fff; }
.aic-col h3 .i { width: 1.15rem; height: 1.15rem; }
.aic-col li { display: flex; gap: 0.85rem; align-items: flex-start; padding-block: 0.85rem; }
.aic-col li + li { border-top: 1px dashed var(--line); }
.aic-col.admin li + li { border-top-color: rgba(255, 255, 255, 0.12); }
.aic-ic { width: 38px; height: 38px; flex: none; border-radius: 11px; display: flex; align-items: center; justify-content: center; background: var(--navy-50); color: var(--navy); }
.aic-col.admin .aic-ic { background: rgba(255, 255, 255, 0.1); color: var(--orange); }
.aic-ic .i { width: 1.1rem; height: 1.1rem; }
.aic-col b { display: block; font-family: var(--f-head); font-weight: 600; color: var(--navy); }
.aic-col.admin b { color: #fff; }
.aic-col li span:not(.aic-ic) { display: block; margin-top: 0.15rem; font-size: 0.92rem; line-height: 1.5; color: var(--muted); }
.aic-col.admin li span:not(.aic-ic) { color: #cfd0e6; }

/* 3. guardrails band */
.aic-guard { padding-block: clamp(3.5rem, 6vw, 5rem); background: linear-gradient(125deg, #101130, #202158); color: #fff; }
.aic-g-in { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.aic-g-copy .eyebrow { color: var(--orange); }
.aic-g-copy h2 { margin-top: 0.8rem; color: #fff; font-size: clamp(1.8rem, 3vw, 2.6rem); font-weight: 700; line-height: 1.15; }
.aic-g-copy p { display: flex; gap: 0.6rem; align-items: flex-start; margin-top: 1.2rem; padding: 1rem 1.1rem; border-radius: 14px; background: rgba(255, 152, 0, 0.1); border: 1px solid rgba(255, 152, 0, 0.35); color: #fde3b8; font-size: 0.98rem; line-height: 1.6; }
.aic-g-copy p .i { width: 1.2rem; height: 1.2rem; flex: none; margin-top: 0.15rem; color: var(--orange); }
.aic-g-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; }
.aic-g-grid li { display: flex; flex-direction: column; gap: 0.35rem; padding: 1.3rem; border-radius: 18px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.12); }
.aic-g-grid li > span { width: 40px; height: 40px; margin-bottom: 0.4rem; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, 0.1); color: var(--orange); }
.aic-g-grid .i { width: 1.15rem; height: 1.15rem; }
.aic-g-grid b { font-family: var(--f-head); font-weight: 600; font-size: 1.05rem; }
.aic-g-grid small { font-size: 0.92rem; line-height: 1.5; color: #cfd0e6; }

@media (max-width: 1100px) {
  .aic-a-in, .aic-g-in { grid-template-columns: minmax(0, 1fr); }
  .aic-chat { max-width: 620px; }
}
@media (max-width: 760px) {
  .aic-cols, .aic-g-grid { grid-template-columns: 1fr; }
}
