/* ============================================================
   XEN AI — Dashboard Shell
   ============================================================ */

.app-shell { display: flex; min-height: 100vh; }

/* ---------- Sidebar ---------- */
.sidebar {
  width: 250px;
  flex-shrink: 0;
  background: var(--panel);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 24px 16px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar .brand { padding: 8px 10px 26px; }

.sidebar-nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 13.5px;
  color: var(--grey);
  transition: background var(--dur-fast), color var(--dur-fast);
}
.nav-item svg { width: 17px; height: 17px; flex-shrink: 0; }
.nav-item:hover { background: rgba(255,255,255,0.04); color: var(--white); }
.nav-item.is-active { background: rgba(255,107,0,0.1); color: var(--orange); }

.nav-divider { height: 1px; background: var(--line); margin: 14px 6px; }

.sidebar-foot {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: #4a4a4a;
  padding: 14px 14px 4px;
  letter-spacing: 0.04em;
}

/* ---------- Main content ---------- */
.dash-main { flex: 1; min-width: 0; }

.dash-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 34px;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: rgba(5,5,5,0.85);
  backdrop-filter: blur(14px);
  z-index: 10;
}

.dash-topbar h2 { font-size: 18px; }

.dash-section { display: none; padding: 40px 34px 80px; }
.dash-section.is-active { display: block; }

/* ---------- Home hero ---------- */
.dash-hero {
  border-radius: 24px;
  padding: 60px 50px;
  position: relative;
  overflow: hidden;
  background: radial-gradient(ellipse 70% 100% at 20% 0%, rgba(255,107,0,0.18), transparent 60%), var(--panel);
  border: 1px solid var(--line);
}
.dash-hero h1 { font-size: clamp(32px, 4vw, 48px); margin-top: 16px; max-width: 640px; }
.dash-hero p { color: var(--grey); margin-top: 16px; max-width: 480px; font-size: 15px; line-height: 1.7; }
.dash-hero .btn-row { display: flex; gap: 14px; margin-top: 32px; flex-wrap: wrap; }

.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 1100px) { .grid-4 { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 700px) { .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.section-label { margin: 46px 0 20px; }
.section-label:first-child { margin-top: 0; }

.info-card {
  padding: 26px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  transition: border-color var(--dur-fast), transform var(--dur-fast);
}
.info-card:hover { border-color: rgba(255,107,0,0.3); transform: translateY(-3px); }
.info-card .cat-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255,107,0,0.1); color: var(--orange);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.info-card h4 { font-size: 16.5px; }
.info-card p { color: var(--grey-dim); font-size: 13px; margin-top: 8px; line-height: 1.6; }
.info-card .badge-soon {
  display: inline-block; margin-top: 12px; font-family: var(--font-mono); font-size: 10px;
  padding: 4px 10px; border-radius: 100px; background: rgba(255,255,255,0.06); color: var(--grey-dim); letter-spacing: .06em;
}

/* ---------- Stat strip ---------- */
.stat-strip { display: grid; grid-template-columns: repeat(4,1fr); gap: 20px; margin-top: 40px; }
@media (max-width: 700px) { .stat-strip { grid-template-columns: repeat(2,1fr); } }
.stat-box { padding: 22px; border-radius: 16px; background: var(--panel); border: 1px solid var(--line); text-align: center; }
.stat-box .num { font-family: var(--font-display); font-size: 30px; background: var(--grad-orange); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-box .lbl { font-size: 11.5px; color: var(--grey-dim); font-family: var(--font-mono); margin-top: 6px; text-transform: uppercase; letter-spacing: .05em; }

/* ---------- Founder ---------- */
.founder-card { display: grid; grid-template-columns: 220px 1fr; gap: 40px; padding: 40px; }
@media (max-width: 700px) { .founder-card { grid-template-columns: 1fr; } }
.founder-photo {
  aspect-ratio: 1/1; border-radius: 18px;
  background: radial-gradient(circle at 30% 20%, rgba(255,107,0,0.25), transparent 60%), #0d0d0d;
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center; color: var(--orange);
}
.founder-photo svg { width: 40%; }
.founder-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.founder-tags span { font-size: 11px; font-family: var(--font-mono); padding: 6px 12px; border-radius: 100px; border: 1px solid var(--line); color: var(--grey); }

/* ---------- Knowledge base ---------- */
.kb-search { display: flex; gap: 10px; margin-bottom: 30px; }
.kb-search input {
  flex: 1; padding: 15px 20px; border-radius: 100px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--glass-border); color: var(--white); font-size: 14px;
}
.kb-search input:focus { outline: none; border-color: var(--orange); }
.kb-result { padding: 20px 24px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line); margin-bottom: 14px; }
.kb-result .kb-q { font-family: var(--font-mono); font-size: 11px; color: var(--orange); text-transform: uppercase; letter-spacing: .05em; }
.kb-result p { margin-top: 8px; color: var(--grey); font-size: 14px; line-height: 1.6; }
.kb-category { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--grey-dim); margin: 30px 0 14px; }

/* ---------- Calculator ---------- */
.calc-card { padding: 34px; max-width: 520px; }
.calc-field { margin-bottom: 18px; }
.calc-field label { display: block; font-size: 12px; color: var(--grey-dim); font-family: var(--font-mono); margin-bottom: 8px; text-transform: uppercase; letter-spacing: .05em; }
.calc-field input, .calc-field select {
  width: 100%; padding: 13px 16px; border-radius: 10px; background: rgba(255,255,255,0.04);
  border: 1px solid var(--glass-border); color: var(--white); font-size: 14px;
}
.calc-field input:focus, .calc-field select:focus { outline: none; border-color: var(--orange); }
.calc-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.calc-result {
  margin-top: 24px; padding: 20px; border-radius: 14px;
  background: rgba(255,107,0,0.08); border: 1px solid rgba(255,107,0,0.25);
  font-family: var(--font-mono); font-size: 14px;
}
.calc-result .val { font-family: var(--font-display); font-size: 26px; color: var(--orange); }

/* ---------- Settings ---------- */
.settings-group { padding: 30px; margin-bottom: 20px; }
.settings-group h4 { font-size: 15px; margin-bottom: 20px; }
.settings-row { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; border-top: 1px solid var(--line); gap: 20px; }
.settings-row:first-of-type { border-top: none; }
.settings-row label { font-size: 13.5px; color: var(--grey); flex-shrink: 0; }
.settings-row select, .settings-row input[type=range] { max-width: 220px; width: 100%; }
.settings-row select { padding: 9px 14px; border-radius: 8px; background: rgba(255,255,255,0.04); border: 1px solid var(--glass-border); color: var(--white); font-size: 13px; }

.toggle { position: relative; width: 46px; height: 26px; border-radius: 100px; background: #2a2a2a; flex-shrink: 0; transition: background var(--dur-fast); }
.toggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--white); transition: transform var(--dur-fast); }
.toggle.is-on { background: var(--grad-orange); }
.toggle.is-on::after { transform: translateX(20px); }

/* ---------- Contact ---------- */
.contact-row { display: flex; gap: 16px; align-items: flex-start; padding: 22px; }
.contact-row svg { width: 20px; height: 20px; color: var(--orange); flex-shrink: 0; margin-top: 2px; }
.contact-row h4 { font-size: 14.5px; }
.contact-row p { font-size: 13px; color: var(--grey-dim); margin-top: 4px; }

/* ---------- Mobile sidebar collapse ---------- */
.dash-burger { display: none; }
@media (max-width: 900px) {
  .sidebar { position: fixed; left: -260px; z-index: 200; transition: left var(--dur-med) var(--ease-out); box-shadow: 30px 0 60px rgba(0,0,0,0.5); }
  .sidebar.is-open { left: 0; }
  .dash-burger { display: flex; }
  .founder-card { padding: 24px; }
}
