/* ==========================================================================
   AIVORA THEME — AI Agent & SaaS Startup
   Design language: dark glass, violet → cyan gradients, crisp mono details.
   Edit the tokens below to rebrand the whole template in seconds.
   ========================================================================== */
:root {
  --bg: #fbfbfe; --bg-2: #f3f3fa; --surface: #ffffff; --surface-2: #f1f1f8;
  --text: #0a0a14; --muted: #5d6078; --line: rgba(10, 10, 20, .09);
  --primary: #6d4aff; --primary-2: #00b8f5; --accent: #ff4fd8; --on-primary: #fff;
  --font-head: "Geist", system-ui, sans-serif; --font-body: "Geist", system-ui, sans-serif; --font-mono: "Geist Mono", ui-monospace, monospace;
  --head-weight: 600; --head-tracking: -0.045em;
  --font-logo: "Michroma", sans-serif; --logo-weight: 400; --logo-size: 1.05rem; --logo-tracking: .04em;
  --radius-sm: 10px; --radius: 18px; --radius-lg: 26px; --radius-btn: 12px;
  --gradient: linear-gradient(120deg, #6d4aff 0%, #8f5bff 40%, #00b8f5 100%);
}
[data-theme="dark"] {
  --bg: #07070d; --bg-2: #0c0c16; --surface: #10101b; --surface-2: #171726;
  --text: #eef0ff; --muted: #9a9db8; --line: rgba(255, 255, 255, .08);
  --shadow: 0 20px 50px -20px rgba(0, 0, 0, .8); --shadow-lg: 0 50px 100px -30px rgba(0, 0, 0, .9);
}
[data-theme="dark"] .blob { opacity: .35; }
[data-theme="dark"] .card, [data-theme="dark"] .step, [data-theme="dark"] .plan:not(.plan--featured) { background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.01)); }
[data-theme="dark"] .plan--featured { background: linear-gradient(180deg, #1a1333, #0d0d19); }
.hero__title { font-weight: 600; }
.btn { letter-spacing: -0.01em; }
.eyebrow { font-family: var(--font-mono); font-weight: 500; letter-spacing: .08em; }
.eyebrow::before { width: 8px; height: 8px; border-radius: 50%; background: var(--gradient); }
.badge b { border-radius: 6px; }
.icon-box { background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 18%, transparent), color-mix(in srgb, var(--primary-2) 14%, transparent)); border: 1px solid color-mix(in srgb, var(--primary) 25%, transparent); }
.site-footer { background: var(--bg-2); }
.footer-mega { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; opacity: .16; }
.hide-sm { display: none; }
@media (min-width: 640px) { .hide-sm { display: block; } }

/* Product window + dashboard ---------------------------------------------- */
.window { position: relative; border-radius: 20px; padding: 0; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg), 0 0 0 8px color-mix(in srgb, var(--surface) 40%, transparent); overflow: hidden; text-align: left; }
.window::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; background: linear-gradient(180deg, color-mix(in srgb, var(--primary) 60%, transparent), transparent 60%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none; }
.window__bar { display: flex; align-items: center; gap: 7px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.window__bar > span { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.window__bar > span:nth-child(2) { background: #febc2e; } .window__bar > span:nth-child(3) { background: #28c840; }
.window__url { margin: 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 5px 14px; border-radius: 8px; background: var(--surface-2); font-family: var(--font-mono); font-size: .75rem; color: var(--muted); }
.dash { display: grid; grid-template-columns: 1fr; min-height: 420px; }
@media (min-width: 768px) { .dash { grid-template-columns: 210px 1fr; } }
.dash__side { display: none; padding: 18px 12px; border-right: 1px solid var(--line); background: color-mix(in srgb, var(--surface-2) 50%, transparent); }
@media (min-width: 768px) { .dash__side { display: flex; flex-direction: column; gap: 4px; } }
.dash__brand { display: flex; align-items: center; gap: 8px; font-weight: 700; padding: 6px 10px 16px; }
.dash__brand .ti { color: var(--primary); }
.dash__side a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; font-size: .88rem; color: var(--muted); }
.dash__side a.is-on { background: color-mix(in srgb, var(--primary) 14%, transparent); color: var(--text); }
.dash__main { padding: 18px; display: grid; gap: 14px; }
.dash__kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 640px) { .dash__kpis { grid-template-columns: repeat(3, 1fr); } }
.dash__kpis > div { padding: 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); display: grid; gap: 4px; }
.dash__kpis small { color: var(--muted); font-size: .78rem; }
.dash__kpis b { font-size: 1.5rem; letter-spacing: -0.03em; }
.dash__kpis em { font-style: normal; font-size: .75rem; display: inline-flex; gap: 4px; align-items: center; }
.up { color: #16a34a; }
.dash__chart { padding: 16px; border-radius: 14px; border: 1px solid var(--line); }
.dash__chart-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-size: .9rem; }
.bars { display: flex; align-items: flex-end; gap: 8px; height: 120px; }
.bars span { flex: 1; border-radius: 6px 6px 3px 3px; background: linear-gradient(180deg, var(--primary), color-mix(in srgb, var(--primary-2) 60%, transparent)); transform-origin: bottom; animation: grow 1.4s var(--ease) both; }
.bars span:nth-child(odd) { opacity: .55; }
@keyframes grow { from { transform: scaleY(0); } }
.dash__list { display: grid; gap: 6px; }
.dash__row { display: grid; grid-template-columns: 10px 1fr auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 10px; font-size: .85rem; background: var(--surface-2); }
.dash__row .muted { display: none; }
@media (min-width: 768px) { .dash__row { grid-template-columns: 10px 1fr 120px 80px; } .dash__row .muted { display: block; } }
.dot { width: 8px; height: 8px; border-radius: 50%; }
.pill { justify-self: end; padding: 3px 10px; border-radius: 999px; font-size: .72rem; font-weight: 600; }
.pill.ok { background: rgba(34,197,94,.15); color: #16a34a; } .pill.run { background: rgba(0,184,245,.15); color: #0891b2; } .pill.wait { background: var(--line); color: var(--muted); }

/* Chat agent ------------------------------------------------------------ */
.chatbox { border-radius: 24px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg); overflow: hidden; max-width: 540px; margin-left: auto; }
.chatbox__head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.chatbox__head > .ti { margin-left: auto; color: var(--muted); }
.chatbox__head small { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: .78rem; }
.avatar-ai { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--gradient); color: #fff; font-size: 1.1rem; flex: none; }
.live { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34,197,94,.25); }
.chatbox__body { display: grid; gap: 12px; padding: 20px 18px; }
.msg { max-width: 88%; padding: 12px 16px; border-radius: 16px; font-size: .92rem; line-height: 1.5; }
.msg--me { justify-self: end; background: var(--gradient); color: #fff; border-bottom-right-radius: 4px; }
.msg--ai { background: var(--surface-2); border-bottom-left-radius: 4px; }
.steps { display: grid; gap: 6px; font-size: .85rem; }
.steps span { display: flex; gap: 8px; align-items: center; }
.steps .ti-circle-check { color: #22c55e; }
.typing .ti { animation: spin 1s linear infinite; color: var(--primary); }
@keyframes spin { to { transform: rotate(360deg); } }
.chatbox__input { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 14px 14px; padding: 8px 8px 8px 16px; border-radius: 14px; border: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.chatbox__input .btn { min-height: 38px; width: 38px; padding: 0; }
.mini-chat { display: grid; gap: 8px; }
.mini-chat .msg { font-size: .85rem; }

/* Terminal & code ------------------------------------------------------- */
.terminal { border-radius: 20px; background: #0b0b14; color: #d7d9f0; border: 1px solid rgba(255,255,255,.08); box-shadow: var(--shadow-lg); overflow: hidden; --line: rgba(255,255,255,.08); --surface-2: #151524; --muted: #8b8fb0; }
.terminal pre, .code { margin: 0; padding: 22px; overflow-x: auto; font-family: var(--font-mono); font-size: .84rem; line-height: 1.75; }
.code { border-radius: 18px; background: #0b0b14; color: #d7d9f0; border: 1px solid var(--line); }
.terminal .c { color: #6b6f8e; } .terminal .k { color: #b69cff; } .terminal .s { color: #5eead4; } .terminal .f { color: #7dd3fc; } .terminal .ok { color: #4ade80; }
.install { display: inline-flex; align-items: center; gap: 12px; padding: 6px 6px 6px 18px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-family: var(--font-mono); font-size: .9rem; }
.install .icon-btn { width: 36px; height: 36px; border-radius: 8px; }
.tabs__btn { border-radius: 10px; font-family: var(--font-mono); font-size: .85rem; }

/* Phones ---------------------------------------------------------------- */
.phones { position: relative; height: 560px; max-width: 620px; margin-inline: auto; }
.phone { position: absolute; width: 270px; height: 550px; border-radius: 44px; padding: 10px; background: #0b0b14; box-shadow: var(--shadow-lg), inset 0 0 0 2px rgba(255,255,255,.08); }
.phone__screen { height: 100%; border-radius: 36px; background: var(--surface); padding: 46px 18px 18px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; text-align: left; position: relative; }
.phone__screen::before { content: ""; position: absolute; top: 12px; left: 50%; width: 90px; height: 24px; transform: translateX(-50%); border-radius: 20px; background: #0b0b14; }
.phone--front { left: 50%; top: 0; transform: translateX(-10%); z-index: 2; }
.phone--back { left: 50%; top: 40px; transform: translateX(-100%) rotate(-6deg); opacity: .95; }
@media (max-width: 639px) { .phone--back { display: none; } .phone--front { transform: translateX(-50%); } .phones { height: 570px; } }
.ps__head { display: flex; align-items: center; gap: 10px; }
.ps__head > .ti:last-child { margin-left: auto; color: var(--muted); }
.ps__card { padding: 18px; border-radius: 20px; color: #fff; display: grid; }
.ps__card.grad { background: var(--gradient); }
.ps__card b { font-size: 2.6rem; line-height: 1.1; }
.ps__card span, .ps__card small { font-size: .78rem; opacity: .85; }
.ps__row { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 14px; background: var(--surface-2); font-size: .85rem; }
.ps__row em { margin-left: auto; font-style: normal; color: var(--muted); font-size: .75rem; }
.ps__bubble { padding: 12px 14px; border-radius: 16px; font-size: .85rem; line-height: 1.45; }
.ps__bubble.me { align-self: flex-end; background: var(--gradient); color: #fff; border-bottom-right-radius: 4px; max-width: 85%; }
.ps__bubble.ai { background: var(--surface-2); border-bottom-left-radius: 4px; }
.ps__wave { display: flex; gap: 4px; align-items: center; justify-content: center; height: 60px; margin-top: auto; }
.ps__wave span { width: 5px; height: calc(var(--h) * 1%); border-radius: 4px; background: var(--gradient); animation: wave 1.2s ease-in-out infinite alternate; animation-delay: calc(var(--h) * -12ms); }
@keyframes wave { to { transform: scaleY(.3); } }
.ps__mic { align-self: center; display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%; background: var(--gradient); color: #fff; font-size: 1.5rem; box-shadow: 0 0 0 10px color-mix(in srgb, var(--primary) 18%, transparent); }
.store-btns .btn .ti { font-size: 1.4rem; }

/* Orbit integrations ---------------------------------------------------- */
.orbit { position: relative; width: min(100%, 460px); aspect-ratio: 1; margin-inline: auto; }
.orbit__core { position: absolute; inset: 50% auto auto 50%; transform: translate(-50%, -50%); display: grid; place-items: center; width: 96px; height: 96px; border-radius: 28px; background: var(--gradient); color: #fff; font-size: 2.6rem; box-shadow: 0 0 80px color-mix(in srgb, var(--primary) 60%, transparent); z-index: 2; }
.orbit__ring { position: absolute; inset: 50% auto auto 50%; border-radius: 50%; border: 1px dashed var(--line); animation: rotate 50s linear infinite; }
.orbit__ring.r1 { width: 58%; aspect-ratio: 1; margin: -29% 0 0 -29%; }
.orbit__ring.r2 { width: 96%; aspect-ratio: 1; margin: -48% 0 0 -48%; animation-duration: 80s; animation-direction: reverse; }
.orbit__ring span { --a: calc(360deg / var(--n) * var(--i)); position: absolute; top: 50%; left: 50%; width: 52px; height: 52px; margin: -26px; display: grid; place-items: center; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: 1.5rem; transform: rotate(var(--a)) translate(calc(var(--r, 1) * 50%)) rotate(calc(-1 * var(--a))); }
.orbit__ring.r1 span { transform: rotate(var(--a)) translateX(calc(min(460px, 100vw) * .29)) rotate(calc(-1 * var(--a))); }
.orbit__ring.r2 span { transform: rotate(var(--a)) translateX(calc(min(460px, 100vw) * .48)) rotate(calc(-1 * var(--a))); }
.orbit__ring .ti { animation: rotate 50s linear infinite reverse; }
.orbit__ring.r2 .ti { animation-duration: 80s; animation-direction: normal; }
@keyframes rotate { to { transform: rotate(360deg); } }
@media (max-width: 480px) { .orbit__ring span { width: 40px; height: 40px; margin: -20px; font-size: 1.15rem; } }

/* Bento visuals --------------------------------------------------------- */
.flow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.flow span { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); font-size: .82rem; font-weight: 500; }
.flow span:not(:last-child)::after { content: "→"; margin-left: 10px; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.spark svg { width: 100%; height: 90px; }

/* Pricing compare table ------------------------------------------------- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--line); background: var(--surface); }
.compare { width: 100%; border-collapse: collapse; min-width: 640px; }
.compare th, .compare td { padding: 18px 22px; text-align: left; border-bottom: 1px solid var(--line); font-size: .95rem; }
.compare thead th { font-family: var(--font-head); font-size: 1.05rem; background: var(--surface-2); }
.compare tbody th { font-weight: 500; color: var(--muted); }
.compare tr:last-child > * { border-bottom: 0; }
.compare td:nth-child(3), .compare th:nth-child(3) { background: color-mix(in srgb, var(--primary) 6%, transparent); }
