/* ai188: reference-aligned home and ChatGPT-style sidebar. */
:root {
  --slm-sidebar: 278px !important;
  --slm-home-max: 1120px;
  --slm-control-radius: 16px;
  --slm-panel-radius: 14px;
}

.taste-mode-switch {
  display: none !important;
}

.app {
  background:
    radial-gradient(circle at 76% 18%, rgba(0, 110, 230, .06), transparent 30%),
    linear-gradient(180deg, var(--slm-surface, #fff) 0%, var(--slm-surface-muted, #f6f9fd) 100%) !important;
}

.sidebar {
  width: var(--slm-sidebar) !important;
  padding: 38px 30px 22px !important;
  border-right: 1px solid var(--slm-line, rgba(20, 36, 59, .1)) !important;
  background: rgba(248, 251, 255, .94) !important;
  box-shadow: none !important;
}

.side-top {
  display: flex !important;
  align-items: flex-start !important;
  justify-content: flex-start !important;
  min-height: 76px !important;
  margin: 0 !important;
}

.brand-lockup {
  width: auto !important;
  min-height: 44px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.brand-lockup {
  display: inline-flex !important;
  align-items: center !important;
  gap: 11px !important;
}

.brand-lockup:hover {
  background: transparent !important;
  transform: none !important;
}

.brand-logo-shell {
  width: 34px !important;
  height: 34px !important;
  border: 0 !important;
  border-radius: 9px !important;
  background: transparent !important;
  box-shadow: none !important;
}

.brand-logo-full {
  width: 34px !important;
  height: auto !important;
  max-height: 34px !important;
  object-fit: contain !important;
}

.side-role-context,
.side-nav-group-title,
.side-top .side-icon-btn,
.side-user-settings {
  display: none !important;
}

.brand-text {
  display: grid !important;
  gap: 2px !important;
  color: var(--slm-ink, #0b1220) !important;
  line-height: 1 !important;
}

.brand-text strong {
  color: var(--slm-ink, #0b1220) !important;
  font-size: 18px !important;
  font-weight: 720 !important;
  letter-spacing: .01em !important;
}

.brand-text em {
  color: var(--slm-ink, #0b1220) !important;
  font-size: 9px !important;
  font-style: normal !important;
  font-weight: 620 !important;
  letter-spacing: .34em !important;
}

.side-primary-actions {
  display: grid !important;
  gap: 12px !important;
  padding: 0 0 22px !important;
  border-bottom: 1px solid var(--slm-line-soft, rgba(20, 36, 59, .08)) !important;
}

.side-primary-actions::before,
.side-primary-actions::after {
  display: none !important;
  content: none !important;
}

.side-action-btn,
.side-search {
  min-height: 52px !important;
  padding: 0 16px !important;
  border: 1px solid var(--slm-line, rgba(20, 36, 59, .12)) !important;
  border-radius: 10px !important;
  background: rgba(255, 255, 255, .74) !important;
  color: var(--slm-ink, #0b1220) !important;
  box-shadow: none !important;
}

.side-action-btn {
  justify-content: flex-start !important;
  gap: 12px !important;
  font-size: 14px !important;
  font-weight: 560 !important;
}

.side-action-btn.is-on,
.side-action-btn:hover,
.side-search:focus-within {
  border-color: rgba(0, 110, 230, .32) !important;
  background: rgba(255, 255, 255, .9) !important;
  color: var(--slm-brand, #006ee6) !important;
}

.side-action-btn span,
.side-search > span {
  color: currentColor !important;
}

.side-action-btn strong {
  font-size: 14px !important;
  font-weight: 560 !important;
}

.side-search {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  color: var(--slm-muted, #667085) !important;
}

.side-search input {
  font-size: 14px !important;
  color: var(--slm-ink, #0b1220) !important;
}

.side-search input::placeholder {
  color: var(--slm-muted, #667085) !important;
}

.side-nav {
  display: grid !important;
  gap: 12px !important;
  margin: 26px 0 0 !important;
  padding: 0 0 26px !important;
  border-bottom: 1px solid var(--slm-line-soft, rgba(20, 36, 59, .08)) !important;
}

.side-nav::before,
.side-nav-item::before {
  display: none !important;
}

.side-nav-item {
  min-height: 40px !important;
  padding: 0 14px !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  color: var(--slm-ink-soft, #344054) !important;
  box-shadow: none !important;
}

.side-nav-item:hover,
.side-nav-item.is-on {
  background: rgba(0, 110, 230, .07) !important;
  color: var(--slm-brand, #006ee6) !important;
}

.side-nav-ico {
  width: 22px !important;
  height: 22px !important;
  color: currentColor !important;
}

.side-nav-copy {
  display: block !important;
}

.side-nav-copy strong {
  color: currentColor !important;
  font-size: 14px !important;
  font-weight: 530 !important;
  letter-spacing: 0 !important;
}

.side-nav-copy em {
  display: none !important;
}

.side-history {
  flex: 1 1 auto !important;
  margin: 24px 0 18px !important;
  padding: 0 !important;
  overflow: auto !important;
}

.side-history::-webkit-scrollbar {
  width: 0 !important;
  height: 0 !important;
}

.side-section-title {
  margin: 0 0 12px !important;
  padding: 0 12px !important;
  color: var(--slm-muted, #667085) !important;
  font-size: 12px !important;
  font-weight: 520 !important;
  letter-spacing: 0 !important;
}

.side-history-item {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: baseline !important;
  min-height: 32px !important;
  margin: 0 0 8px !important;
  padding: 0 12px !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: transparent !important;
  box-shadow: none !important;
}

.side-history-item:hover,
.side-history-item.is-on {
  background: rgba(0, 110, 230, .06) !important;
}

.side-history-item span {
  min-width: 0 !important;
  overflow: hidden !important;
  color: var(--slm-ink, #0b1220) !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  line-height: 1.35 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.side-history-item time {
  color: var(--slm-muted, #667085) !important;
  font-size: 12px !important;
  font-weight: 440 !important;
}

.side-user-wrap {
  padding-top: 18px !important;
  border-top: 1px solid var(--slm-line-soft, rgba(20, 36, 59, .08)) !important;
}

.side-user {
  display: block !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

.side-user-main {
  min-height: 54px !important;
  padding: 0 4px !important;
  border-radius: 10px !important;
  background: transparent !important;
}

.side-user-main:hover {
  background: rgba(0, 110, 230, .06) !important;
}

.side-user-av-wrap,
.side-user-av {
  width: 42px !important;
  height: 42px !important;
}

.side-user-text strong {
  color: var(--slm-ink, #0b1220) !important;
  font-size: 14px !important;
  font-weight: 560 !important;
}

.side-user-text span {
  margin-top: 2px !important;
  color: var(--slm-muted, #667085) !important;
  font-size: 12px !important;
}

.app.view-today .stage,
.app.view-followup .stage,
.app.view-training .stage,
.app.view-analysis .stage {
  width: 100% !important;
  max-width: none !important;
  min-height: 100dvh !important;
  padding: 0 !important;
}

.slm-home {
  min-height: 100dvh;
  padding: 148px 48px 132px;
  color: var(--slm-ink, #0b1220);
}

.slm-home-shell {
  width: min(var(--slm-home-max), 100%);
  margin: 0 auto;
}

.slm-home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  align-items: center;
  gap: 40px;
}

.slm-home-greeting {
  margin: 0 0 28px;
  color: var(--slm-ink, #0b1220);
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 0;
}

.slm-home-copy h1 {
  margin: 0;
  color: var(--slm-ink, #0b1220);
  font-size: clamp(42px, 3.7vw, 52px);
  font-weight: 680;
  letter-spacing: -.035em;
  line-height: 1.08;
  white-space: nowrap;
}

.slm-home-copy h1 span {
  color: var(--slm-brand, #006ee6);
}

.slm-home-state {
  display: grid;
  gap: 8px;
  justify-self: end;
  width: 240px;
  padding: 20px;
  border: 1px solid var(--slm-line-soft, rgba(20, 36, 59, .08));
  border-radius: var(--slm-panel-radius);
  background: rgba(255, 255, 255, .62);
}

.slm-home-state span,
.slm-home-state em {
  color: var(--slm-muted, #667085);
  font-size: 12px;
  font-style: normal;
}

.slm-home-state strong {
  color: var(--slm-ink, #0b1220);
  font-size: 16px;
  font-weight: 560;
}

.slm-command {
  display: grid;
  grid-template-rows: 1fr auto;
  min-height: 178px;
  margin-top: 82px;
  padding: 28px 28px 24px;
  border: 1px solid rgba(20, 36, 59, .14);
  border-radius: var(--slm-control-radius);
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 22px 52px rgba(23, 45, 78, .06);
}

.slm-command:focus-within {
  border-color: rgba(0, 110, 230, .34);
  box-shadow: 0 0 0 4px rgba(0, 110, 230, .08), 0 20px 46px rgba(23, 45, 78, .06);
}

.slm-command textarea {
  width: 100%;
  min-height: 82px;
  padding: 0;
  resize: none;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--slm-ink, #0b1220);
  font: inherit;
  font-size: 16px;
  line-height: 1.65;
}

.slm-command textarea::placeholder {
  color: var(--slm-muted, #667085);
}

.slm-command-bar {
  display: flex;
  align-items: center;
  gap: 12px;
}

.slm-tool-btn,
.slm-mode-btn,
.slm-send {
  min-height: 44px;
  border: 1px solid var(--slm-line, rgba(20, 36, 59, .12));
  border-radius: 999px;
  background: rgba(255, 255, 255, .82);
  color: var(--slm-ink-soft, #344054);
}

.slm-tool-btn {
  display: inline-grid;
  width: 44px;
  place-items: center;
  padding: 0;
}

.slm-mode-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  font-size: 13px;
  font-weight: 520;
}

.slm-tool-btn:hover,
.slm-mode-btn:hover {
  border-color: rgba(0, 110, 230, .24);
  color: var(--slm-brand, #006ee6);
}

.slm-send {
  display: inline-grid;
  width: 48px;
  min-height: 48px;
  margin-left: auto;
  place-items: center;
  padding: 0;
  border: 0;
  background: linear-gradient(135deg, var(--slm-brand, #006ee6), #86a7ff);
  color: #fff;
  box-shadow: 0 10px 24px rgba(0, 110, 230, .24);
}

.slm-send.is-mute,
.slm-send[aria-disabled="true"] {
  background: var(--slm-surface-muted, #f1f5f9);
  color: var(--slm-muted, #667085);
  box-shadow: none;
}

.slm-home-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-top: 38px;
}

.slm-home-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 18px;
  min-height: 148px;
  padding: 28px 26px;
  text-align: left;
  border: 1px solid var(--slm-line, rgba(20, 36, 59, .12));
  border-radius: var(--slm-panel-radius);
  background: rgba(255, 255, 255, .72);
  box-shadow: none;
}

.slm-home-card:hover {
  border-color: rgba(0, 110, 230, .28);
  background: rgba(255, 255, 255, .92);
}

.slm-card-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(0, 110, 230, .14);
  border-radius: 10px;
  background: rgba(0, 110, 230, .06);
  color: var(--slm-brand, #006ee6);
}

.slm-card-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.slm-card-copy strong {
  color: var(--slm-ink, #0b1220);
  font-size: 18px;
  font-weight: 620;
}

.slm-card-copy em {
  color: var(--slm-ink, #0b1220);
  font-size: 14px;
  font-style: normal;
  font-weight: 560;
}

.slm-card-copy small {
  display: block;
  max-width: 430px;
  color: var(--slm-muted, #667085);
  font-size: 13px;
  line-height: 1.65;
}

.slm-card-facts {
  display: grid;
  gap: 5px;
  margin-top: 4px;
}

.slm-card-facts span {
  overflow: hidden;
  color: var(--slm-muted, #667085);
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.slm-card-arrow {
  align-self: center;
  color: var(--slm-muted, #667085);
}

.bottom-nav {
  grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
}

@media (max-width: 1180px) {
  :root {
    --slm-sidebar: 260px !important;
    --slm-home-max: 960px;
  }

  .sidebar {
    padding-inline: 24px !important;
  }

  .slm-home-hero {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .slm-home-copy h1 {
    white-space: normal;
  }

  .slm-home-state {
    justify-self: start;
  }
}

@media (max-width: 720px) {
  :root {
    --slm-sidebar: 0px !important;
  }

  .sidebar {
    display: none !important;
  }

  .app.view-today .stage,
  .app.view-followup .stage,
  .app.view-training .stage,
  .app.view-analysis .stage {
    width: 100vw !important;
    max-width: 100vw !important;
  }

  .slm-home {
    min-height: 100dvh;
    padding: 58px 18px 120px;
  }

  .slm-home-hero {
    display: block;
  }

  .slm-home-greeting {
    margin-bottom: 18px;
    font-size: 18px;
  }

  .slm-home-copy h1 {
    font-size: 36px;
    letter-spacing: -.025em;
    white-space: normal;
  }

  .slm-home-state {
    width: 100%;
    margin-top: 22px;
    padding: 16px;
  }

  .slm-command {
    min-height: 166px;
    margin-top: 32px;
    padding: 22px 18px 18px;
    border-radius: 14px;
  }

  .slm-command textarea {
    min-height: 76px;
    font-size: 15px;
  }

  .slm-mode-btn span {
    display: none;
  }

  .slm-home-card-grid {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 20px;
  }

  .slm-home-card {
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 14px;
    min-height: 0;
    padding: 18px;
  }

  .slm-card-icon {
    width: 36px;
    height: 36px;
  }

  .slm-card-copy strong {
    font-size: 16px;
  }

  .slm-card-facts {
    display: none;
  }
}
