@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/InterVariable.woff2") format("woff2");
}

@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/CormorantGaramond-SemiBold-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/CormorantGaramond-SemiBold-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light;
  --canvas: #f6f7f4;
  --surface: #ffffff;
  --surface-subtle: #eef2ee;
  --text: #1f2723;
  --text-soft: #66706a;
  --border: #dce3de;
  --border-strong: #aeb9b2;
  --brand: #315f52;
  --brand-hover: #274c42;
  --brand-soft: #e8f0ec;
  --companion: #486b78;
  --companion-soft: #eaf0f2;
  --warmth: #a45e65;
  --warmth-soft: #f5eaeb;
  --progress: #a17c3f;
  --progress-soft: #f5f0e6;
  --danger: #a64046;
  --danger-soft: #f8e9ea;
  --success: #3f745f;
  --success-soft: #e8f1ed;
  --shadow-subtle: 0 1px 2px rgba(31, 39, 35, 0.05);
  --shadow-floating: 0 8px 24px rgba(31, 39, 35, 0.1);
  --ink: var(--text);
  --muted: var(--text-soft);
  --paper: var(--canvas);
  --wash: var(--surface-subtle);
  --panel: var(--surface);
  --line: var(--border);
  --coral: var(--warmth);
  --coral-dark: #824a51;
  --teal: var(--brand);
  --teal-soft: var(--brand-soft);
  --plum: #6c596f;
  --blue: var(--companion);
  --gold: var(--progress);
  --sage: #718879;
  --shadow: var(--shadow-floating);
  --soft-shadow: var(--shadow-subtle);
  --display-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

html {
  min-width: 320px;
  min-height: 100%;
  background: var(--canvas);
  scrollbar-gutter: stable;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background: var(--canvas);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-size: 15px;
  font-kerning: normal;
  font-synthesis: none;
  line-height: 1.5;
  letter-spacing: 0;
  text-rendering: optimizeLegibility;
}

body.booting .auth-screen,
body.booting .app-shell {
  visibility: hidden;
}

button,
input,
textarea,
select {
  color: inherit;
  font: inherit;
  letter-spacing: 0;
}

button,
a,
input,
textarea,
select,
summary {
  outline: none;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px rgba(49, 95, 82, 0.12);
}

button {
  border: 0;
}

a {
  color: var(--brand);
  text-underline-offset: 3px;
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
  letter-spacing: 0;
}

h1,
h2,
h3,
h4,
strong {
  color: var(--text);
}

@supports (text-wrap: balance) {
  h1,
  h2,
  h3,
  h4 {
    text-wrap: balance;
  }

  .message-body p,
  .lab-result-card p,
  .memory-card p {
    text-wrap: pretty;
  }
}

svg {
  flex: 0 0 auto;
  stroke-width: 1.8;
}

.primary,
.secondary,
.ghost {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
}

.primary {
  color: #fff;
  border: 1px solid var(--brand);
  background: var(--brand);
  box-shadow: none;
}

.primary:hover {
  border-color: var(--brand-hover);
  background: var(--brand-hover);
  transform: none;
}

.primary:active,
.secondary:active,
.ghost:active {
  transform: translateY(1px);
}

.secondary {
  color: var(--brand);
  border: 1px solid var(--border-strong);
  background: var(--surface);
}

.secondary:hover {
  color: var(--brand-hover);
  border-color: var(--brand);
  background: var(--surface);
}

.ghost {
  color: var(--text-soft);
  border: 1px solid transparent;
  background: transparent;
}

.ghost:hover {
  color: var(--text);
  background: var(--surface-subtle);
}

input[type="text"],
input[type="email"],
input[type="password"] {
  min-width: 0;
  height: 46px;
  padding: 0 13px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  background: var(--surface);
}

input::placeholder,
textarea::placeholder {
  color: #89928d;
}

input:focus,
textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(49, 95, 82, 0.12);
}

.soft-label {
  display: inline-flex;
  width: fit-content;
  min-height: 26px;
  align-items: center;
  padding: 0 8px;
  border: 0;
  border-radius: 4px;
  color: var(--brand);
  background: var(--brand-soft);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  text-transform: none;
}

.muted {
  color: var(--text-soft);
}

/* Authentication */
.auth-screen {
  display: grid;
  height: 100vh;
  min-height: 100vh;
  grid-template-columns: minmax(420px, 0.88fr) minmax(480px, 1.12fr);
  align-items: stretch;
  overflow: hidden;
  background: var(--canvas);
}

.auth-visual {
  min-width: 0;
  height: 100vh;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  background: var(--brand);
}

.auth-portrait {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 0;
  overflow: hidden;
}

.auth-portrait > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 22%;
}

.auth-dimensional-stage {
  position: absolute;
  z-index: 1;
  inset: 0;
  overflow: hidden;
}

.auth-dimensional-stage canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.auth-dimensional-stage[data-motion-state="fallback"]::before,
.auth-dimensional-stage[data-motion-state="disabled"]::before {
  position: absolute;
  top: 18%;
  right: 13%;
  width: 116px;
  height: 116px;
  border: 2px solid rgba(239, 108, 84, 0.74);
  content: "";
  transform: rotate(45deg);
}

.auth-motion-control {
  position: absolute;
  z-index: 4;
  top: 24px;
  right: 24px;
  display: inline-grid;
  width: 44px;
  height: 44px;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 50%;
  color: #fff;
  background: rgba(23, 34, 31, 0.58);
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.auth-motion-control svg {
  width: 17px;
  height: 17px;
}

.auth-portrait-shade {
  position: absolute;
  z-index: 2;
  inset: 48% 0 0;
  background: linear-gradient(180deg, rgba(31, 39, 35, 0), rgba(31, 39, 35, 0.82));
}

.auth-portrait-copy {
  position: absolute;
  z-index: 3;
  right: 40px;
  bottom: 40px;
  left: 40px;
  max-width: 520px;
  color: #fff;
}

.auth-presence {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 18px;
  font-size: 13px;
  font-weight: 700;
}

.auth-presence::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #bfe2cf;
  content: "";
}

.auth-portrait-copy blockquote {
  margin: 0 0 12px;
  color: #fff;
  font-family: var(--display-serif);
  font-size: 28px;
  font-weight: 600;
  line-height: 1.28;
  text-shadow: 0 2px 18px rgba(12, 21, 18, 0.46);
}

.auth-portrait-copy p {
  margin: 0;
  color: rgba(255, 255, 255, 0.74);
  font-size: 13px;
}

.auth-panel {
  display: flex;
  width: min(520px, 100%);
  min-width: 0;
  height: 100vh;
  min-height: 0;
  justify-content: flex-start;
  flex-direction: column;
  margin: 0 auto;
  padding: 32px 40px 40px;
  border: 0;
  background: var(--canvas);
  overflow: auto;
}

.brand-row {
  gap: 12px;
}

.brand-avatar {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 27%;
}

.auth-panel .brand-row {
  margin-bottom: 28px;
}

.brand-row strong {
  font-size: 15px;
}

.brand-row span {
  color: var(--text-soft);
  font-size: 12px;
}

.auth-kicker {
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.auth-panel h1 {
  max-width: 440px;
  margin: 12px 0 10px;
  font-family: var(--display-serif);
  font-size: 40px;
  font-weight: 600;
  line-height: 1.12;
}

.auth-panel > .muted {
  max-width: 420px;
  margin: 0 0 18px;
  color: var(--text-soft);
}

.auth-tabs {
  display: grid;
  max-width: none;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.auth-tabs button {
  min-height: 44px;
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  color: var(--text-soft);
  background: transparent;
  font-weight: 700;
}

.auth-tabs button.active {
  color: var(--brand);
  border-color: var(--brand);
  background: transparent;
}

.auth-form {
  display: grid;
  max-width: none;
  gap: 12px;
}

@media (min-width: 761px) and (min-height: 1200px) {
  .auth-panel {
    justify-content: center;
    padding-top: 48px;
    padding-bottom: 48px;
  }
}

@media (min-width: 1000px) and (max-height: 980px) {
  .auth-panel .brand-row {
    display: none;
  }

  .auth-panel h1 {
    margin-top: 7px;
    font-size: 36px;
  }

  .auth-panel > .muted {
    margin-bottom: 10px;
  }

  .auth-value-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin: 10px 0 2px;
  }

  .auth-value-list > div {
    grid-template-columns: 20px minmax(0, 1fr);
    gap: 6px;
  }

  .auth-value-list small {
    display: none;
  }

  .auth-tabs {
    margin-bottom: 10px;
  }

  .auth-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px 10px;
  }

  #displayNameLabel,
  #legalConsentGroup,
  .auth-form > button {
    grid-column: 1 / -1;
  }

  .legal-consent-group {
    gap: 6px;
    padding-top: 8px;
  }

  .auth-note {
    margin-top: 9px !important;
  }

  .auth-legal-links {
    margin-top: 10px;
  }
}

@media (min-width: 1000px) and (max-height: 760px) {
  .auth-panel {
    padding: 20px 32px 24px;
  }

  .auth-kicker {
    font-size: 11px;
  }

  .auth-panel h1 {
    margin-bottom: 7px;
    font-size: 32px;
    line-height: 1.05;
  }

  .auth-panel > .muted {
    margin-bottom: 6px;
    font-size: 13px;
    line-height: 1.45;
  }

  .auth-value-list {
    margin-top: 4px;
  }

  .auth-journey > div {
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 5px;
    padding: 3px 0;
    font-size: 12px;
  }

  .auth-journey > div:not(:last-child)::after {
    display: none;
  }

  .auth-journey-icon {
    width: 28px;
    height: 28px;
  }

  .auth-journey-icon svg {
    width: 13px;
    height: 13px;
  }

  .auth-tabs button {
    min-height: 38px;
  }

  .auth-form {
    gap: 6px 9px;
  }

  .auth-form label {
    gap: 4px;
    font-size: 12px;
  }

  .auth-form input[type="text"],
  .auth-form input[type="email"],
  .auth-form input[type="password"] {
    height: 42px;
  }

  .legal-consent-group {
    gap: 4px;
    padding-top: 6px;
  }

  .legal-consent {
    padding: 7px 9px;
  }
}

.auth-form label {
  display: grid;
  gap: 7px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

.legal-consent-group {
  display: grid;
  gap: 9px;
  padding: 12px 0 2px;
  border-top: 1px solid var(--border);
}

.legal-consent {
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: flex-start;
  color: var(--text-soft) !important;
  font-size: 12px !important;
  font-weight: 400 !important;
}

.legal-consent input {
  width: 16px;
  height: 16px;
  margin: 2px 0 0;
  accent-color: var(--brand);
}

.legal-consent a {
  color: var(--brand);
  text-underline-offset: 2px;
}

.auth-note {
  max-width: none;
  margin: 16px 0 0 !important;
  color: var(--text-soft);
  font-size: 12px;
  text-align: center;
}

.auth-legal-links {
  justify-content: center;
  margin-top: 22px;
  font-size: 12px;
}

.auth-journey {
  gap: 0;
}

.auth-journey > div {
  position: relative;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 11px;
  padding: 7px 0;
}

.auth-journey > div:not(:last-child)::after {
  position: absolute;
  top: 39px;
  bottom: -4px;
  left: 16px;
  width: 1px;
  background: var(--border);
  content: "";
}

.auth-journey-icon {
  position: relative;
  z-index: 1;
  display: grid !important;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--brand);
  background: var(--surface);
}

.auth-journey-icon svg {
  width: 16px;
  height: 16px;
  margin: 0;
}

.auth-journey-icon small {
  position: absolute;
  top: -4px;
  right: -3px;
  display: grid;
  width: 15px;
  height: 15px;
  place-items: center;
  margin: 0;
  border-radius: 50%;
  color: #fff;
  background: var(--brand);
  font-size: 8px;
  font-weight: 800;
  line-height: 1;
}

/* App shell */
.app-shell:not(.hidden) {
  display: grid;
  min-height: 100vh;
  grid-template-columns: 248px minmax(0, 1fr);
  background: var(--canvas);
}

.sidebar {
  position: sticky;
  z-index: 25;
  top: 0;
  display: flex;
  width: 248px;
  height: 100vh;
  min-height: 0;
  flex-direction: column;
  overflow: auto;
  padding: 24px 16px 18px;
  border-right: 1px solid var(--border);
  background: var(--surface);
}

.sidebar-brand {
  padding: 0 8px;
}

.sidebar .sidebar-brand strong {
  color: var(--text);
}

.presence {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  color: var(--success) !important;
  font-weight: 600;
}

#queueStatus,
#queueStatus.busy {
  display: inline;
  width: auto;
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: var(--success);
  background: transparent;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
}

.presence::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  content: "";
}

.main-nav {
  display: grid;
  gap: 4px;
  margin-top: 30px;
  overflow: visible;
}

.main-nav button,
.nav-more > summary {
  display: flex;
  width: 100%;
  min-height: 44px;
  align-items: center;
  gap: 12px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  color: var(--text-soft);
  background: transparent;
  font-size: 14px;
  font-weight: 650;
  text-align: left;
}

.main-nav button svg,
.nav-more > summary svg {
  width: 18px;
  height: 18px;
}

.main-nav button::before {
  display: none;
  content: none;
}

.main-nav button:hover,
.nav-more > summary:hover {
  color: var(--text);
  background: var(--surface-subtle);
}

.main-nav button.active {
  color: var(--brand);
  background: var(--brand-soft);
  box-shadow: none;
}

.nav-more.active-section > summary {
  color: var(--brand);
  background: var(--brand-soft);
}

.nav-more {
  margin-top: 4px;
}

.nav-more > summary {
  cursor: pointer;
  list-style: none;
}

.nav-more > summary::-webkit-details-marker {
  display: none;
}

.nav-more .nav-chevron {
  width: 16px;
  height: 16px;
  margin-left: auto;
  transition: transform 160ms ease;
}

.nav-more[open] .nav-chevron {
  transform: rotate(180deg);
}

.nav-more-menu {
  display: grid;
  gap: 2px;
  padding: 4px 0 0 12px;
}

.nav-more-menu button {
  min-height: 40px;
  font-size: 13px;
}

.sidebar-bottom {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.sidebar-profile {
  display: grid;
  min-width: 0;
  grid-template-columns: 38px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 10px;
  padding: 7px 8px;
  border-radius: 8px;
  background: transparent;
  text-align: left;
}

.sidebar-profile:hover {
  background: var(--surface-subtle);
}

.profile-initial {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  color: var(--brand);
  background: var(--brand-soft);
  font-weight: 750;
}

.sidebar-profile-copy {
  display: grid;
  min-width: 0;
}

.sidebar-profile-copy strong,
.sidebar-profile-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-profile-copy strong {
  font-size: 13px;
}

.sidebar-profile-copy small {
  color: var(--text-soft);
  font-size: 11px;
}

.sidebar-profile > svg {
  width: 16px;
  height: 16px;
  color: var(--text-soft);
}

.sidebar-legal-links {
  justify-content: flex-start;
  padding: 0 8px;
  font-size: 11px;
}

.sidebar-logout {
  display: flex;
  min-height: 38px;
  align-items: center;
  gap: 9px;
  padding: 0 10px;
  border-radius: 8px;
  color: var(--text-soft);
  background: transparent;
  font-size: 12px;
}

.sidebar-logout:hover {
  color: var(--danger);
  background: var(--danger-soft);
}

.sidebar-logout svg {
  width: 16px;
  height: 16px;
}

.workspace {
  min-width: 0;
  padding: 0;
  background: var(--canvas);
}

.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  flex-direction: row;
  height: 72px;
  min-height: 72px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 0;
  padding: 0 32px;
  border-bottom: 1px solid var(--border);
  background: rgba(246, 247, 244, 0.96);
  backdrop-filter: blur(14px);
}

@supports (animation-timeline: scroll()) {
  .topbar::after {
    position: absolute;
    right: 0;
    bottom: -1px;
    left: 0;
    height: 2px;
    background: var(--brand);
    content: "";
    transform: scaleX(0);
    transform-origin: left center;
    animation: page-scroll-progress linear both;
    animation-timeline: scroll(root block);
  }
}

@keyframes page-scroll-progress {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.topbar-title {
  min-width: 0;
}

.topbar .eyebrow {
  margin: 0 0 2px;
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 500;
  text-transform: none;
}

.topbar h2 {
  overflow: hidden;
  max-width: 720px;
  margin: 0;
  font-size: 17px;
  font-weight: 720;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.token-balance,
.topbar-profile-button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  background: var(--surface);
}

.token-balance {
  gap: 6px;
  padding: 0 11px;
  font-size: 13px;
}

.token-balance svg {
  width: 16px;
  height: 16px;
  color: var(--progress);
}

.token-balance span {
  color: var(--text-soft);
  font-weight: 500;
}

.topbar-profile-button {
  width: 40px;
  padding: 0;
  color: var(--text-soft);
}

.topbar-profile-button svg {
  width: 18px;
  height: 18px;
}

.token-balance:hover,
.topbar-profile-button:hover {
  border-color: var(--border-strong);
}

.bottom-nav {
  display: none;
}

.view {
  display: none;
  width: min(1120px, calc(100% - 64px));
  margin: 0 auto;
  padding: 38px 0 64px;
}

.view.active {
  display: block;
  animation: view-in 180ms ease-out;
}

html[data-transition-kind="view"] .view.active {
  view-transition-name: app-content;
}

html[data-transition-kind="intent"] .dashboard-next-step {
  view-transition-name: intent-card;
}

::view-transition-old(root) {
  opacity: 0;
  animation: none;
}

::view-transition-new(root) {
  opacity: 1;
  animation: none;
}

::view-transition-old(app-content) {
  animation: app-content-out 140ms ease-in both;
}

::view-transition-new(app-content) {
  animation: app-content-in 210ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

::view-transition-old(intent-card) {
  animation: intent-card-out 110ms ease-in both;
}

::view-transition-new(intent-card) {
  animation: intent-card-in 180ms ease-out both;
}

@keyframes app-content-out {
  to {
    opacity: 0;
    transform: translateY(-4px);
  }
}

@keyframes app-content-in {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
}

@keyframes intent-card-out {
  to {
    opacity: 0;
  }
}

@keyframes intent-card-in {
  from {
    opacity: 0;
  }
}

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

/* Today */
.quick-start-strip {
  display: none;
}

.first-run-guide {
  display: none;
  min-height: 570px;
  grid-template-columns: minmax(0, 1fr) 310px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

body[data-first-run="1"] #view-chat .chat-layout {
  grid-template-columns: minmax(0, 1fr);
}

body[data-first-run="1"] #view-chat .action-rail {
  display: none;
}

.first-run-main {
  display: flex;
  min-width: 0;
  justify-content: center;
  flex-direction: column;
  padding: 42px;
}

.first-run-main h1 {
  max-width: 700px;
  margin: 16px 0 12px;
  font-family: var(--display-serif);
  font-size: 34px;
  font-weight: 600;
  line-height: 1.16;
}

.first-run-lead {
  max-width: 650px;
  margin: 0 0 24px;
  color: var(--text-soft);
  font-size: 15px;
}

.first-run-choices {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.first-run-choices button {
  display: grid;
  min-width: 0;
  min-height: 86px;
  grid-template-columns: 34px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 12px;
  padding: 15px;
  border: 0;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  color: var(--text);
  background: transparent;
  text-align: left;
}

.first-run-choices button:hover {
  color: var(--brand);
  background: var(--brand-soft);
}

.first-run-choices button > svg:first-child {
  width: 34px;
  height: 34px;
  padding: 8px;
  border-radius: 8px;
  color: var(--brand);
  background: var(--brand-soft);
}

.first-run-choices button > svg:last-child {
  width: 17px;
  height: 17px;
  color: var(--text-soft);
  transition: transform 180ms ease, color 180ms ease;
}

.first-run-choices button:hover > svg:last-child {
  color: var(--brand);
  transform: translateX(3px);
}

.first-run-choices span {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.first-run-choices strong {
  font-size: 14px;
  line-height: 1.25;
}

.first-run-choices small {
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.35;
}

.first-run-result {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 22px;
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 650;
}

.first-run-result span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.first-run-result strong {
  display: inline-grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 50%;
  color: var(--surface);
  background: var(--brand);
  font-size: 11px;
}

.first-run-token-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 18px 0 0;
  color: var(--text-soft);
  font-size: 12px;
}

.first-run-token-note svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  color: var(--warmth);
}

.first-run-portrait {
  position: relative;
  min-height: 100%;
  overflow: hidden;
  background: var(--brand);
}

.first-run-portrait > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 24%;
}

.first-run-portrait::after {
  position: absolute;
  inset: 48% 0 0;
  background: linear-gradient(180deg, rgba(31, 39, 35, 0), rgba(31, 39, 35, 0.86));
  content: "";
}

.first-run-portrait > div {
  position: absolute;
  z-index: 1;
  right: 24px;
  bottom: 26px;
  left: 24px;
  display: grid;
  gap: 6px;
  color: #fff;
}

.first-run-portrait strong {
  font-family: var(--display-serif);
  font-size: 21px;
  font-weight: 600;
  line-height: 1.2;
}

.first-run-portrait span {
  color: rgba(255, 255, 255, 0.76);
  font-size: 12px;
}

.dashboard-motion-stage {
  position: relative;
  isolation: isolate;
  display: grid;
  min-height: 430px;
  grid-template-columns: minmax(0, 1fr) 250px;
  align-items: center;
  overflow: hidden;
  margin: 0 0 26px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: #edf2ef;
}

.chat-motion-stage {
  margin-top: 0;
  box-shadow: 0 22px 70px rgba(35, 55, 47, 0.08);
}

.view.active .dashboard-motion-stage,
.view.active .support-intent,
.view.active .chat-layout {
  animation: chat-surface-in 520ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.view.active .support-intent {
  animation-delay: 70ms;
}

.view.active .chat-layout {
  animation-delay: 120ms;
}

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

.dashboard-motion-canvas {
  position: absolute;
  z-index: 0;
  inset: 0;
  pointer-events: none;
}

.dashboard-motion-canvas canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.dashboard-motion-copy {
  position: relative;
  z-index: 2;
  min-width: 0;
  padding: 42px 28px 38px 40px;
}

.dashboard-intro {
  display: grid;
  gap: 8px;
  max-width: 610px;
  margin-bottom: 22px;
}

.dashboard-intro h1 {
  margin: 0;
  font-family: var(--display-serif);
  font-size: 34px;
  font-weight: 600;
  line-height: 1.2;
}

.dashboard-intro p {
  max-width: 560px;
  margin: 0;
  color: var(--text-soft);
  font-size: 16px;
}

.dashboard-motion-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 30px;
}

.dashboard-motion-actions button {
  min-height: 44px;
}

.dashboard-motion-actions svg {
  width: 17px;
  height: 17px;
}

.dashboard-motion-path {
  display: grid;
  max-width: 620px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid rgba(49, 95, 82, 0.26);
}

.dashboard-motion-path span {
  position: relative;
  display: grid;
  min-width: 0;
  gap: 3px;
  padding: 13px 14px 0 0;
}

.dashboard-motion-path span:not(:last-child)::after {
  position: absolute;
  top: -4px;
  right: 14px;
  width: 7px;
  height: 7px;
  border: 1px solid var(--brand);
  border-radius: 50%;
  background: #edf2ef;
  content: "";
}

.dashboard-motion-path b {
  color: var(--brand);
  font-size: 10px;
  font-weight: 800;
}

.dashboard-motion-path small {
  color: var(--text-soft);
  font-size: 11px;
  line-height: 1.3;
}

.dashboard-motion-portrait {
  position: relative;
  z-index: 2;
  align-self: center;
  width: 205px;
  margin: 0 30px 0 0;
}

.dashboard-motion-portrait img {
  display: block;
  width: 205px;
  height: 286px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  object-fit: cover;
  object-position: 50% 23%;
  box-shadow: 0 18px 44px rgba(31, 39, 35, 0.15);
}

.dashboard-motion-portrait figcaption {
  display: grid;
  gap: 2px;
  padding-top: 10px;
}

.dashboard-motion-portrait strong {
  font-size: 12px;
}

.dashboard-motion-portrait span {
  color: var(--text-soft);
  font-size: 10px;
  line-height: 1.35;
}

.dashboard-motion-stage[data-motion-state="fallback"] .dashboard-motion-canvas,
.dashboard-motion-stage[data-motion-state="disabled"] .dashboard-motion-canvas,
.dashboard-motion-stage[data-motion-state="idle"] .dashboard-motion-canvas {
  display: none;
}

.support-intent {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) auto;
  align-items: end;
  gap: 24px;
  margin-bottom: 18px;
  padding: 16px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.support-intent-copy {
  min-width: 0;
}

.support-intent h2 {
  margin: 8px 0 2px;
  font-size: 18px;
  font-weight: 720;
  line-height: 1.25;
}

.support-intent p {
  max-width: 650px;
  margin: 0;
  color: var(--text-soft);
  font-size: 13px;
}

.support-intent-control {
  display: grid;
  grid-template-columns: repeat(3, minmax(128px, 1fr));
  gap: 3px;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-subtle);
}

.support-intent-control button {
  display: inline-flex;
  min-width: 0;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 11px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--text-soft);
  background: transparent;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.support-intent-control button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.72);
}

.support-intent-control button.active {
  color: var(--brand);
  border-color: var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-subtle);
}

.support-intent-control button:active {
  transform: translateY(1px);
}

.support-intent-control svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}

/* Local screen capture */
.studio-capture-guide {
  display: grid;
  gap: 14px;
  margin: 4px 0 16px;
  padding: 16px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.studio-capture-guide-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.studio-capture-guide-head > div {
  display: grid;
  gap: 5px;
}

.studio-capture-guide-head > div > strong {
  font-family: var(--display-serif);
  font-size: 20px;
  font-weight: 600;
}

#studioCaptureGuideStatus {
  color: var(--brand);
  font-size: 12px;
  font-weight: 750;
  text-align: right;
}

.studio-capture-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.studio-capture-steps li {
  position: relative;
  display: grid;
  min-width: 0;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: start;
  gap: 9px;
  padding: 10px 14px 10px 0;
  color: var(--text-soft);
}

.studio-capture-steps li:not(:last-child)::after {
  position: absolute;
  top: 24px;
  right: 8px;
  width: 16px;
  border-top: 1px solid var(--border-strong);
  content: "";
}

.studio-capture-steps b {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--border-strong);
  border-radius: 50%;
  background: var(--surface);
  font-size: 11px;
}

.studio-capture-steps span {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.studio-capture-steps strong {
  color: inherit;
  font-size: 12px;
}

.studio-capture-steps small {
  font-size: 10px;
  line-height: 1.35;
}

.studio-capture-steps li.current,
.studio-capture-steps li.done {
  color: var(--brand);
}

.studio-capture-steps li.current b {
  color: var(--surface);
  border-color: var(--brand);
  background: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-soft);
}

.studio-capture-steps li.done b {
  border-color: var(--brand);
  background: var(--brand-soft);
}

.studio-capture-presets {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

#studioCameraPositionField[hidden] {
  display: none;
}

@media (max-width: 1120px) {
  .studio-capture-presets {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.studio-capture-presets button {
  display: grid;
  min-width: 0;
  min-height: 62px;
  grid-template-columns: 32px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  color: var(--text-soft);
  background: var(--surface);
  text-align: left;
}

.studio-capture-presets button:hover,
.studio-capture-presets button.active {
  color: var(--brand);
  border-color: rgba(49, 95, 82, 0.42);
  background: var(--brand-soft);
}

.studio-capture-presets svg {
  width: 32px;
  height: 32px;
  padding: 7px;
  border-radius: 7px;
  background: var(--surface);
}

.studio-capture-presets span {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.studio-capture-presets strong {
  font-size: 12px;
}

.studio-capture-presets small {
  font-size: 10px;
  line-height: 1.3;
}

.studio-capture-readiness {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin: 0 0 14px;
  color: var(--text-soft);
  font-size: 11px;
}

.studio-capture-readiness span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.studio-capture-readiness span::before {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: var(--brand);
  content: "";
}

.studio-capture-readiness .warning::before {
  background: var(--warmth);
}

.studio-capture-readiness .error::before {
  background: #a43b42;
}

.studio-capture-actions {
  margin-bottom: 14px;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-subtle);
}

.dashboard-focus {
  display: grid;
  max-width: none;
  gap: 12px;
  margin: 0 0 18px;
}

.dashboard-next-step {
  display: grid;
  min-height: 156px;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 24px 26px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: none;
}

.dashboard-next-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  align-self: start;
  border-radius: 8px;
  color: var(--brand);
  background: var(--brand-soft);
}

.dashboard-next-icon svg {
  width: 20px;
  height: 20px;
}

.dashboard-next-copy {
  min-width: 0;
}

.dashboard-next-copy h3 {
  display: grid;
  margin: 7px 0 6px;
  font-size: 19px;
  font-weight: 740;
  line-height: 1.25;
}

.dashboard-next-copy > p {
  max-width: 680px;
  margin: 0;
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.5;
}

.dashboard-next-context {
  margin-top: 8px !important;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  color: var(--text) !important;
  font-size: 12px !important;
}

.dashboard-next-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  max-width: 310px;
}

.dashboard-next-actions button {
  min-height: 42px;
}

.dashboard-next-actions svg {
  width: 17px;
  height: 17px;
}

.retention-nudge {
  display: flex;
  min-height: 92px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 20px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.retention-nudge h3 {
  margin: 6px 0 2px;
  font-size: 16px;
}

.retention-nudge p {
  margin: 0;
  color: var(--text-soft);
  font-size: 13px;
}

.dashboard-secondary {
  max-width: none;
  border-top: 1px solid var(--border);
}

.dashboard-secondary summary {
  padding: 16px 0;
  color: var(--text-soft);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
}

.memory-preview-card {
  margin-bottom: 14px;
}

/* Shared product surfaces */
.command-card,
.history-block,
.work-panel,
.conversation-panel,
.center-panel,
.call-stage,
.memory-hero,
.lab-mode-banner,
.billing-value-card,
.price-card,
.tool-card,
.test-card,
.result-box {
  border-color: var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: none;
}

.command-card.memory-preview-card {
  color: var(--text);
  background: var(--surface-subtle);
}

.memory-preview-card p,
.memory-preview-card #memoryPreviewText {
  color: var(--text-soft);
}

.memory-preview-card .soft-label {
  border-color: var(--border-strong);
  color: var(--brand);
  background: var(--brand-soft);
}

.memory-preview-card .memory-mini-stats div {
  border-color: var(--border);
  background: var(--surface);
}

.memory-preview-card .memory-mini-stats strong {
  color: var(--warmth);
}

.memory-preview-card .memory-mini-stats span {
  color: var(--text-soft);
}

.memory-preview-card .ghost {
  border-color: var(--border-strong);
  color: var(--brand);
  background: var(--surface);
}

.history-block,
.work-panel,
.center-panel {
  padding: 20px;
}

.history-block h3,
.work-panel h3,
.center-panel h3 {
  font-size: 17px;
}

.section-head {
  gap: 12px;
  margin-bottom: 16px;
}

.section-head h3 {
  margin: 0;
}

.history-row {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.history-row:last-child {
  border-bottom: 0;
}

.history-row p,
.result-box {
  color: var(--text-soft);
}

.skeleton-line {
  border-radius: 4px;
  background: linear-gradient(90deg, #eef1ef 25%, #f8f9f7 50%, #eef1ef 75%);
  background-size: 200% 100%;
  animation: skeleton-shift 1.2s ease-in-out infinite;
}

@keyframes skeleton-shift {
  from {
    background-position: 200% 0;
  }
  to {
    background-position: -200% 0;
  }
}

/* Chat */
.chat-layout {
  display: grid;
  min-height: calc(100vh - 174px);
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 20px;
}

.conversation-panel {
  display: flex;
  min-width: 0;
  min-height: 640px;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--border);
}

.conversation-presence {
  display: flex;
  min-height: 62px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.conversation-presence-person {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
}

.conversation-presence-person img {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 25%;
}

.conversation-presence-person > span {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.conversation-presence-person strong {
  font-size: 13px;
}

.conversation-presence-person small {
  overflow: hidden;
  color: var(--text-soft);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.conversation-presence-wave {
  display: flex;
  width: 32px;
  height: 26px;
  flex: 0 0 32px;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--brand);
}

.conversation-presence-wave i {
  width: 2px;
  height: 5px;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.45;
}

.conversation-presence.is-busy .conversation-presence-wave i {
  animation: conversation-wave 820ms ease-in-out infinite alternate;
}

.conversation-presence.is-busy .conversation-presence-wave i:nth-child(2) { animation-delay: 120ms; }
.conversation-presence.is-busy .conversation-presence-wave i:nth-child(3) { animation-delay: 240ms; }
.conversation-presence.is-busy .conversation-presence-wave i:nth-child(4) { animation-delay: 360ms; }

.messages {
  min-height: 0;
  flex: 1;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 24px;
  background: var(--surface);
}

.message {
  max-width: min(78%, 660px);
  margin-bottom: 16px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.message.user {
  margin-left: auto;
  background: transparent;
}

.message.zinaida {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  margin-right: auto;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.message-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 25%;
}

.message-body {
  min-width: 0;
  padding: 11px 13px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-subtle);
}

.message.user .message-body {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}

.message.user .message-body strong,
.message.user .message-body p {
  color: #fff;
}

.message-body strong {
  display: block;
  margin-bottom: 3px;
  font-size: 11px;
}

.message-body p {
  margin: 0;
  line-height: 1.55;
}

.message.message-enter {
  animation: message-arrive 360ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.chat-media-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.chat-media-actions button {
  min-height: 44px;
  gap: 7px;
  padding: 0 12px;
  font-size: 12px;
}

.chat-media-actions button svg {
  width: 16px;
  height: 16px;
}

.chat-media-actions button.recording {
  color: var(--danger);
  border-color: rgba(166, 64, 70, 0.38);
  background: var(--danger-soft);
}

.chat-media-actions #chatMediaHint {
  min-width: 180px;
  flex: 1;
  color: var(--text-soft);
  font-size: 11px;
  text-align: right;
}

.chat-media-actions .button-label {
  min-width: 0;
  flex: 0 1 auto;
  color: inherit;
  font-size: inherit;
  text-align: inherit;
}

.chat-intent-row {
  display: flex;
  min-width: 0;
  gap: 7px;
  overflow-x: auto;
  padding: 9px 14px 0;
  border-top: 1px solid var(--border);
  background: var(--surface);
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
}

.chat-intent-row::-webkit-scrollbar {
  display: none;
}

.chat-intent-row button {
  min-height: 40px;
  flex: 0 0 auto;
  padding: 0 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-soft);
  background: var(--surface);
  font-size: 12px;
  white-space: nowrap;
}

.chat-intent-row button:hover {
  color: var(--brand);
  border-color: var(--border-strong);
  background: var(--brand-soft);
}

.composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 14px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.composer input,
.composer textarea {
  width: 100%;
}

.composer textarea {
  min-width: 0;
  min-height: 46px;
  max-height: 144px;
  resize: none;
  overflow-y: auto;
  padding: 11px 13px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  background: var(--surface);
  line-height: 1.45;
}

.composer-submit {
  align-self: end;
  gap: 7px;
}

.composer-submit svg {
  width: 17px;
  height: 17px;
}

.active-lab-notice {
  margin: 12px 12px 0;
  border: 1px solid #d9cbb1;
  border-radius: 8px;
  background: var(--progress-soft);
}

.action-rail {
  display: grid;
  height: fit-content;
  gap: 10px;
}

.action-tile {
  min-height: 90px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  text-align: left;
}

.action-tile:hover {
  border-color: var(--border-strong);
}

.action-tile strong,
.action-tile span {
  display: block;
}

.action-tile span {
  margin-top: 5px;
  color: var(--text-soft);
  font-size: 12px;
}

.mini-history {
  padding: 16px;
  border-top: 1px solid var(--border);
}

/* Lab and tests */
.assessment-spotlight {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  margin-bottom: 20px;
  padding: 24px 26px;
  border: 1px solid var(--border);
  border-top: 3px solid var(--brand);
  border-radius: 8px;
  background: var(--surface);
}

.assessment-spotlight h3 {
  margin: 10px 0 5px;
  font-family: var(--display-serif);
  font-size: 28px;
  font-weight: 600;
  line-height: 1.16;
}

.assessment-spotlight p {
  max-width: 720px;
  margin: 0;
  color: var(--text-soft);
}

.assessment-spotlight-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 13px;
}

.assessment-spotlight-meta span {
  padding: 4px 7px;
  border: 1px solid var(--border);
  border-radius: 5px;
  color: var(--text-soft);
  background: var(--surface-subtle);
  font-size: 11px;
  font-weight: 650;
}

.section-overline {
  display: block;
  margin-bottom: 4px;
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.section-head h3 small {
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 600;
}

#view-assessments .split-view {
  grid-template-columns: minmax(400px, 0.96fr) minmax(420px, 1.04fr);
}

.lab-mode-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
  padding: 20px;
  border: 1px solid var(--border);
}

.lab-mode-banner h3 {
  margin: 7px 0 3px;
  font-family: var(--display-serif);
  font-size: 28px;
  font-weight: 600;
  line-height: 1.15;
}

.lab-mode-banner p {
  max-width: 720px;
  margin: 0;
  color: var(--text-soft);
}

.lab-clarity {
  display: grid;
  grid-template-columns: minmax(260px, 0.7fr) minmax(440px, 1.3fr);
  align-items: stretch;
  gap: 0;
  margin-bottom: 20px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.lab-clarity-copy {
  display: flex;
  min-width: 0;
  justify-content: center;
  flex-direction: column;
  padding: 24px;
  border-right: 1px solid var(--border);
}

.lab-clarity-copy h3 {
  margin: 9px 0 6px;
  font-family: var(--display-serif);
  font-size: 25px;
  font-weight: 600;
  line-height: 1.16;
}

.lab-clarity-copy p {
  max-width: 430px;
  margin: 0;
  color: var(--text-soft);
  font-size: 13px;
}

.lab-compare {
  min-width: 0;
  padding: 14px;
  background: var(--surface-subtle);
}

.lab-compare-stage {
  --lab-facts-opacity: 1;
  --lab-versions-opacity: 1;
  position: relative;
  display: grid;
  min-height: 208px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 7px;
  cursor: ew-resize;
  touch-action: pan-y;
  user-select: none;
}

.lab-compare-layer {
  position: relative;
  display: grid;
  min-width: 0;
  align-content: start;
  gap: 12px;
  padding: 18px 20px;
  transition: opacity 180ms ease-out;
}

.lab-compare-layer > strong {
  font-size: 12px;
  text-transform: uppercase;
}

.lab-compare-facts {
  color: var(--companion);
  background: var(--companion-soft);
  opacity: var(--lab-facts-opacity);
}

.lab-compare-versions {
  color: var(--warmth);
  background: var(--warmth-soft);
  opacity: var(--lab-versions-opacity);
}

.lab-compare-list {
  display: grid;
  grid-template-rows: repeat(3, minmax(50px, auto));
}

.lab-compare-list span {
  position: relative;
  display: flex;
  min-height: 43px;
  align-items: center;
  padding: 9px 8px 9px 24px;
  border-top: 1px solid var(--border-strong);
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
}

.lab-compare-list span::before {
  position: absolute;
  left: 7px;
  width: 7px;
  height: 7px;
  border: 1px solid currentColor;
  border-radius: 50%;
  content: "";
}

.lab-compare-divider {
  position: absolute;
  z-index: 4;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  color: var(--brand);
  background: currentColor;
  transform: translateX(-50%);
  pointer-events: none;
}

.lab-compare-divider svg {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 30px;
  height: 30px;
  padding: 6px;
  border: 1px solid var(--border-strong);
  border-radius: 50%;
  background: var(--surface);
  transform: translate(-50%, -50%);
}

.lab-compare-control {
  display: grid;
  grid-template-columns: auto minmax(120px, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 700;
}

.lab-compare-control input {
  width: 100%;
  accent-color: var(--brand);
  cursor: ew-resize;
}

.lab-compare-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 10px 2px 0;
  color: var(--text-soft);
  font-size: 11px;
  line-height: 1.45;
}

.lab-compare-note svg {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
  margin-top: 1px;
  color: var(--brand);
}

.lab-compare-stage.is-refreshing .lab-compare-layer {
  animation: lab-principle-refresh 360ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.lab-compare-stage.is-refreshing .lab-compare-versions {
  animation-delay: 90ms;
}

@keyframes lab-principle-refresh {
  from {
    opacity: 0.55;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lab-session-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.lab-session-meta span {
  padding: 5px 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-soft);
  background: var(--surface);
  font-size: 11px;
  font-weight: 650;
}

.lab-session-meta span:first-child {
  color: var(--brand);
  border-color: color-mix(in srgb, var(--brand) 24%, var(--border));
  background: var(--brand-soft);
}

.split-view {
  display: grid;
  grid-template-columns: minmax(320px, 0.78fr) minmax(440px, 1.22fr);
  gap: 20px;
  align-items: start;
}

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

.tool-card,
.test-card {
  min-height: 136px;
  padding: 16px;
  border: 1px solid var(--border);
  text-align: left;
}

.tool-card:hover,
.test-card:hover {
  border-color: var(--border-strong);
  transform: none;
}

.tool-card[aria-pressed="true"] {
  border-color: var(--brand);
  background: var(--brand-soft);
  box-shadow: inset 3px 0 0 var(--brand);
}

.tool-card.motion-enter,
.test-card.motion-enter {
  animation: surface-arrive 420ms cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(var(--motion-order, 0) * 45ms);
}

.tool-card.featured {
  grid-column: 1 / -1;
  border-color: color-mix(in srgb, var(--warmth) 28%, var(--border));
  background: var(--warmth-soft);
}

.tool-card-rose .tool-icon { background: var(--warmth); }
.tool-card-ink .tool-icon { background: var(--text); }
.tool-card-blue .tool-icon { background: var(--companion); }
.tool-card-sage .tool-icon { background: var(--sage); }
.tool-card-gold .tool-icon { background: var(--progress); }
.tool-card-plum .tool-icon { background: var(--plum); }

.tool-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.8;
}

.tool-card h4,
.test-card h4 {
  margin: 0 0 6px;
  font-size: 15px;
}

.tool-card p,
.test-card p {
  color: var(--text-soft);
  font-size: 12px;
}

.test-card {
  position: relative;
  display: grid;
  min-height: 188px;
  align-content: start;
  gap: 7px;
}

.test-card.is-new {
  border-color: color-mix(in srgb, var(--brand) 38%, var(--border));
}

.test-card.is-completed {
  background: color-mix(in srgb, var(--surface) 88%, var(--brand-soft));
}

.test-card.is-active,
.test-card.is-starting {
  border-color: var(--brand);
  background: var(--brand-soft);
  box-shadow: inset 3px 0 0 var(--brand);
}

.test-card.is-starting {
  cursor: progress;
}

.test-card.is-starting::after {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 16px;
  height: 16px;
  border: 2px solid var(--border);
  border-top-color: var(--brand);
  border-radius: 50%;
  content: "";
  animation: control-spin 720ms linear infinite;
}

.test-card-kicker {
  width: fit-content;
  color: var(--brand) !important;
  font-size: 10px !important;
  font-weight: 750;
  text-transform: uppercase;
}

.test-card h4,
.test-card > strong {
  font-size: 15px;
  line-height: 1.28;
}

.test-card p {
  display: -webkit-box;
  min-height: 35px;
  margin: 0;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.test-card-meta {
  color: var(--text-soft) !important;
  font-size: 11px !important;
}

.test-card-footer {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 5px;
}

.test-card-cost {
  color: var(--text-soft) !important;
  font-size: 11px !important;
  white-space: nowrap;
}

.assessment-history-card {
  gap: 7px;
  padding: 15px 0;
}

.assessment-history-result {
  white-space: pre-line;
}

.assessment-history-full summary {
  color: var(--brand);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

.assessment-history-full .assessment-history-result {
  margin-top: 9px;
  padding: 11px;
  border-left: 2px solid var(--border-strong);
  background: var(--surface-subtle);
}

#view-lab .work-panel {
  position: sticky;
  top: 92px;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--border);
  box-shadow: none;
}

#view-lab .work-panel::before {
  margin: 0;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  color: var(--brand);
  background: var(--brand-soft);
  content: "Рабочий чат Лаборатории";
  font-size: 12px;
}

#labMessages,
#assessmentMessages {
  min-height: 420px;
  max-height: 58vh;
  background: var(--surface);
}

.lab-result-cards {
  padding: 0 14px 14px;
}

.lab-result-card {
  border-color: var(--border);
  border-radius: 8px;
  background: var(--surface-subtle);
}

.lab-result-header h3,
.memory-hero h3,
#viewTitle {
  font-family: var(--display-serif);
  font-weight: 600;
}

.lab-result-header h3 {
  font-size: 26px;
}

.result-badges .quality-fallback {
  color: #2f6658;
  background: #edf6f1;
  border-color: #c8ded4;
}

.lab-result-section {
  padding: 12px 0 0;
  border: 0;
  border-top: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
}

.lab-version {
  display: grid;
  gap: 7px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(34, 54, 48, 0.1);
}

.lab-version:last-child {
  border-bottom: 0;
}

.lab-version > strong {
  color: var(--text);
  font-size: 14px;
}

.lab-version > p {
  margin: 0;
}

.lab-version-detail {
  display: grid;
  grid-template-columns: minmax(72px, 92px) minmax(0, 1fr);
  gap: 9px;
  align-items: start;
}

.lab-version-detail > span,
.lab-version > small {
  color: var(--text-soft);
  font-size: 12px;
}

.lab-version-detail > p {
  margin: 0;
  font-size: 13px;
}

.lab-feedback,
.lab-outcome,
.lab-full-result {
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.lab-feedback {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-soft);
  font-size: 13px;
}

.lab-feedback-buttons,
.lab-outcome-status {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.lab-feedback button,
.lab-outcome-status button {
  min-height: 34px;
  padding: 0 10px;
  font-size: 12px;
}

.lab-outcome summary,
.lab-full-result summary {
  color: var(--brand);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
}

.lab-outcome-form {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.lab-outcome-status button.active {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}

.lab-outcome-form textarea {
  width: 100%;
  min-height: 82px;
  resize: vertical;
}

.lab-outcome-form .secondary {
  width: fit-content;
}

.lab-outcome-saved {
  margin: 10px 0 0;
  color: var(--text-soft);
}

.lab-full-result-text {
  margin: 12px 0 0;
  color: var(--text-soft);
  white-space: pre-wrap;
}

.inline-actions {
  padding: 0 14px 14px;
}

.history-block {
  margin-top: 16px;
  border: 1px solid var(--border);
}

.prompt-row button {
  min-height: 36px;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-soft);
  background: var(--surface);
  font-size: 12px;
}

.prompt-row button:hover {
  color: var(--brand);
  border-color: var(--border-strong);
}

/* Map */
.memory-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
  padding: 24px;
  border: 1px solid var(--border);
}

.memory-hero h3 {
  margin: 8px 0 5px;
  font-size: 28px;
}

.memory-hero p {
  margin: 0;
  color: var(--text-soft);
}

.memory-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

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

.memory-grid .history-block {
  min-width: 0;
  margin: 0;
}

.memory-grid .history-block:first-child,
.memory-grid .history-block:nth-child(2) {
  grid-column: span 1;
}

.action-row {
  align-items: flex-start;
}

.memory-more {
  margin-top: 18px;
  border-top: 1px solid var(--border);
}

.memory-more > summary {
  display: flex;
  min-height: 52px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-soft);
  cursor: pointer;
  list-style: none;
  font-size: 13px;
  font-weight: 700;
}

.memory-more > summary::-webkit-details-marker {
  display: none;
}

.memory-more > summary svg {
  width: 17px;
  height: 17px;
  transition: transform 160ms ease;
}

.memory-more[open] > summary svg {
  transform: rotate(180deg);
}

.memory-more-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding-bottom: 16px;
}

.memory-more-grid .history-block {
  min-width: 0;
  margin: 0;
}

/* Billing and secondary pages */
.billing-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.billing-layout > section:first-child {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.billing-value-card {
  padding: 16px;
  border: 1px solid var(--border);
}

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

.price-card {
  padding: 18px;
  border: 1px solid var(--border);
}

.price-card:hover {
  border-color: var(--border-strong);
  transform: none;
}

.center-panel {
  width: min(680px, 100%);
  margin: 0 auto;
  border: 1px solid var(--border);
}

.promo-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.result-box {
  border: 1px solid var(--border);
}

/* Profile */
.profile-layout {
  width: min(800px, 100%);
  margin: 0 auto;
}

.profile-identity {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 24px 0 28px;
  border-bottom: 1px solid var(--border);
}

.profile-zinaida-photo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 24%;
}

.profile-identity h3 {
  margin: 6px 0 2px;
  font-size: 22px;
}

.profile-identity p {
  margin: 0;
  color: var(--text-soft);
}

.profile-balance {
  display: grid;
  justify-items: end;
}

.profile-balance span {
  color: var(--text-soft);
  font-size: 12px;
}

.profile-balance strong {
  font-size: 18px;
}

.profile-balance strong span {
  color: var(--text);
  font-size: inherit;
}

.profile-section {
  padding: 28px 0;
  border-bottom: 1px solid var(--border);
}

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

.profile-action-list button {
  display: grid;
  min-width: 0;
  min-height: 76px;
  grid-template-columns: 36px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  text-align: left;
}

.profile-action-list button:hover {
  border-color: var(--border-strong);
}

.profile-action-list button > svg:first-child {
  width: 36px;
  height: 36px;
  padding: 8px;
  border-radius: 8px;
  color: var(--brand);
  background: var(--brand-soft);
}

.profile-action-list button > svg:last-child {
  width: 17px;
  height: 17px;
  color: var(--text-soft);
}

.profile-action-list button span {
  display: grid;
}

.profile-action-list button small {
  overflow: hidden;
  color: var(--text-soft);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-legal-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px 20px;
  margin: 14px 0 20px;
}

.profile-legal-links a {
  color: var(--text-soft);
  font-size: 13px;
}

.profile-privacy .section-head {
  align-items: center;
}

.privacy-status {
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
}

.privacy-preference {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) minmax(220px, 300px);
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.privacy-preference > svg {
  width: 42px;
  height: 42px;
  padding: 10px;
  border-radius: 8px;
  color: var(--brand);
  background: var(--brand-soft);
}

.privacy-preference > div {
  min-width: 0;
}

.privacy-preference strong {
  font-size: 14px;
}

.privacy-preference p {
  margin: 5px 0 0;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.5;
}

.privacy-preference button {
  min-height: 44px;
  white-space: normal;
}

.privacy-preference.is-opted-out > svg {
  color: var(--warmth);
  background: var(--warmth-soft);
}

.profile-motion .section-head {
  align-items: center;
}

.motion-status {
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
}

.motion-preference {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.motion-preference > svg {
  width: 42px;
  height: 42px;
  padding: 10px;
  border-radius: 8px;
  color: var(--companion);
  background: var(--companion-soft);
}

.motion-preference > div {
  min-width: 0;
}

.motion-preference strong {
  font-size: 14px;
}

.motion-preference p {
  margin: 5px 0 0;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.5;
}

.setting-switch {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 9px;
  color: var(--text);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
}

.setting-switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.setting-switch-track {
  display: flex;
  width: 42px;
  height: 24px;
  align-items: center;
  padding: 3px;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  background: var(--surface-subtle);
  transition: background 160ms ease, border-color 160ms ease;
}

.setting-switch-track span {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--text-soft);
  transition: transform 160ms ease, background 160ms ease;
}

.setting-switch input:checked + .setting-switch-track {
  border-color: var(--brand);
  background: var(--brand-soft);
}

.setting-switch input:checked + .setting-switch-track span {
  background: var(--brand);
  transform: translateX(18px);
}

.setting-switch input:focus-visible + .setting-switch-track {
  outline: 3px solid rgba(49, 95, 82, 0.22);
  outline-offset: 2px;
}

@keyframes auth-portrait-presence {
  0% {
    transform: scale(1.015) translate3d(0, 0, 0);
  }
  100% {
    transform: scale(1.04) translate3d(0, -0.5%, 0);
  }
}

@keyframes auth-content-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes presence-breathe {
  0%, 100% {
    opacity: 0.72;
    box-shadow: 0 0 0 0 rgba(191, 226, 207, 0.3);
  }
  50% {
    opacity: 1;
    box-shadow: 0 0 0 5px rgba(191, 226, 207, 0);
  }
}

@keyframes conversation-wave {
  from { height: 5px; opacity: 0.42; }
  to { height: 18px; opacity: 1; }
}

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

@keyframes surface-arrive {
  from { opacity: 0; transform: translateY(9px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes control-spin {
  to { transform: rotate(360deg); }
}

.auth-screen:not(.hidden) .auth-portrait > img {
  animation: auth-portrait-presence 14s ease-in-out infinite alternate;
  will-change: transform;
}

.auth-screen:not(.hidden) .auth-portrait-copy,
.auth-screen:not(.hidden) .auth-panel > * {
  animation: auth-content-in 560ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.auth-screen:not(.hidden) .auth-journey > div {
  animation: auth-content-in 460ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.auth-screen:not(.hidden) .auth-journey > div:nth-child(1) { animation-delay: 180ms; }
.auth-screen:not(.hidden) .auth-journey > div:nth-child(2) { animation-delay: 235ms; }
.auth-screen:not(.hidden) .auth-journey > div:nth-child(3) { animation-delay: 290ms; }

.auth-screen:not(.hidden) .auth-panel > :nth-child(2) { animation-delay: 60ms; }
.auth-screen:not(.hidden) .auth-panel > :nth-child(3) { animation-delay: 100ms; }
.auth-screen:not(.hidden) .auth-panel > :nth-child(4) { animation-delay: 140ms; }
.auth-screen:not(.hidden) .auth-panel > :nth-child(n + 5) { animation-delay: 180ms; }

.auth-presence::before {
  animation: presence-breathe 2.8s ease-in-out infinite;
}

body[data-first-run="1"] .first-run-guide:not(.hidden) {
  animation: auth-content-in 480ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.profile-logout-button svg {
  width: 17px;
  height: 17px;
}

/* Call */
.call-layout {
  display: grid;
  grid-template-columns: minmax(360px, 0.92fr) minmax(420px, 1.08fr);
  gap: 20px;
  align-items: start;
}

.call-stage {
  position: sticky;
  top: 92px;
  padding: 14px;
  color: var(--text);
  border: 1px solid var(--border);
}

#view-call .messages.compact .message.zinaida {
  display: block;
}

.call-mode-switch {
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-subtle);
}

.call-mode-switch button {
  color: var(--text-soft);
  border-color: transparent;
  background: transparent;
}

.call-mode-switch button.active {
  color: var(--text);
  border-color: var(--border-strong);
  background: var(--surface);
}

.video-frame {
  min-height: 520px;
  border: 0;
  border-radius: 8px;
  background: var(--text);
}

.call-avatar-photo {
  object-position: 50% 22%;
}

.live-portrait-shell {
  position: relative;
  width: min(290px, 70vw);
  height: auto;
  overflow: hidden;
  aspect-ratio: 29 / 32;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: #1d1b1c;
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.24);
  transform: scale(var(--voice-scale, 1));
  transform-origin: 50% 64%;
  transition: transform 90ms linear, filter 220ms ease;
}

.live-portrait-shell .call-avatar-photo,
.live-portrait-canvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: inherit;
  box-shadow: none;
}

.live-portrait-shell .call-avatar-photo {
  object-fit: cover;
  object-position: 50% 22%;
  opacity: 1;
  transform: none;
  transition: opacity 160ms ease;
}

.live-portrait-canvas {
  z-index: 2;
  opacity: 0;
  background: #1d1b1c;
  transition: opacity 160ms ease;
}

.live-portrait-ready .live-portrait-canvas {
  opacity: 1;
}

.live-portrait-ready .call-avatar-photo {
  opacity: 0;
}

.live-portrait-source-frame {
  display: none !important;
}

.live-portrait-paused .live-portrait-canvas {
  transition-duration: 80ms;
}

.call-motion-control {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 3;
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 7px;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.9);
  background: rgba(25, 24, 25, 0.72);
  backdrop-filter: blur(10px);
  cursor: pointer;
  font-size: 11px;
  font-weight: 650;
}

.call-motion-control input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.call-motion-track {
  position: relative;
  width: 28px;
  height: 16px;
  flex: 0 0 28px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  transition: background-color 160ms ease;
}

.call-motion-track span {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  transition: transform 160ms ease;
}

.call-motion-control input:checked + .call-motion-track {
  background: var(--brand);
}

.call-motion-control input:checked + .call-motion-track span {
  transform: translateX(12px);
}

.call-motion-control:has(input:focus-visible) {
  outline: 2px solid rgba(255, 255, 255, 0.92);
  outline-offset: 2px;
}

.call-panel {
  margin: 0;
  border: 1px solid var(--border);
}

.call-status-board,
.call-buttons,
.call-metrics {
  border-color: var(--border);
}

.call-status-board {
  background: var(--surface-subtle);
}

.call-status-board strong {
  color: var(--text-soft);
}

.debug {
  color: var(--text-soft);
  font-size: 11px;
}

.toast {
  right: 22px;
  bottom: 22px;
  max-width: min(380px, calc(100vw - 32px));
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  background: var(--surface);
  box-shadow: var(--shadow-floating);
}

@media (min-width: 961px) {
  #view-chat {
    padding-bottom: 0;
  }

  #view-chat .chat-layout {
    height: min(720px, calc(100vh - 164px));
    height: min(720px, calc(100dvh - 164px));
    min-height: 520px;
  }

  #view-chat .conversation-panel {
    height: 100%;
    min-height: 0;
  }

  #view-chat .action-rail {
    height: 100%;
    min-height: 0;
    align-content: start;
    overflow-y: auto;
  }
}

@media (max-width: 1120px) {
  .view {
    width: min(100% - 40px, 1080px);
  }

  .split-view {
    grid-template-columns: minmax(300px, 0.8fr) minmax(380px, 1.2fr);
  }
}

@media (max-width: 960px) {
  .app-shell:not(.hidden) {
    display: block;
    padding-bottom: 72px;
  }

  .sidebar {
    display: none;
  }

  .lab-clarity {
    grid-template-columns: minmax(0, 1fr);
  }

  .lab-clarity-copy {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .topbar {
    height: 64px;
    min-height: 64px;
    padding: 0 18px;
    background: rgba(255, 255, 255, 0.96);
  }

  .bottom-nav {
    position: fixed;
    z-index: 60;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    height: 68px;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;
    padding: 6px 8px 5px;
    border: 0;
    border-top: 1px solid var(--border);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 -4px 18px rgba(31, 39, 35, 0.06);
    backdrop-filter: blur(14px);
  }

  .bottom-nav button {
    display: grid;
    min-width: 0;
    min-height: 54px;
    place-items: center;
    align-content: center;
    gap: 3px;
    padding: 0 2px;
    border: 0;
    border-radius: 8px;
    color: var(--text-soft);
    background: transparent;
    font-size: 10px;
    font-weight: 650;
  }

  .bottom-nav button svg {
    width: 19px;
    height: 19px;
  }

  .bottom-nav button.active {
    color: var(--brand);
    background: var(--brand-soft);
  }

  .view {
    width: auto;
    margin: 0;
    padding: 26px 20px 46px;
  }

  .chat-layout,
  .split-view,
  .call-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .action-rail {
    display: none;
  }

  #view-lab .work-panel,
  .call-stage {
    position: static;
  }

  .memory-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .memory-more-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  #view-assessments .split-view {
    grid-template-columns: minmax(0, 1fr);
  }

  .price-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .studio-capture-guide-head {
    align-items: start;
    flex-direction: column;
    gap: 6px;
  }

  #studioCaptureGuideStatus {
    text-align: left;
  }

  .studio-capture-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 10px;
  }

  .studio-capture-steps li:not(:last-child)::after {
    display: none;
  }

  .studio-capture-presets {
    grid-template-columns: minmax(0, 1fr);
  }

  .studio-capture-actions {
    z-index: 8;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #studioPanelScreen[data-capture-phase="record"] .studio-capture-actions,
  #studioPanelScreen[data-capture-phase="review"] .studio-capture-actions {
    position: sticky;
    bottom: 76px;
  }

  .auth-screen {
    display: grid;
    height: auto;
    min-height: 100vh;
    min-height: 100svh;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(210px, 32svh) auto;
    overflow: visible;
  }

  .auth-visual {
    display: block;
    width: 100%;
    height: auto;
    min-height: 210px;
  }

  .auth-portrait {
    height: 100%;
    min-height: 210px;
  }

  .auth-dimensional-stage {
    opacity: 0.92;
  }

  .auth-motion-control {
    top: 14px;
    right: 14px;
    width: 40px;
    height: 40px;
  }

  .auth-portrait-shade {
    inset: 35% 0 0;
  }

  .auth-portrait-copy {
    right: 22px;
    bottom: 18px;
    left: 22px;
  }

  .auth-presence {
    margin-bottom: 8px;
  }

  .auth-portrait-copy blockquote {
    max-width: 360px;
    margin-bottom: 0;
    font-size: 21px;
    line-height: 1.2;
  }

  .auth-portrait-copy p {
    display: none;
  }

  .auth-panel {
    width: min(500px, 100%);
    height: auto;
    min-height: 0;
    padding: 28px 22px 44px;
  }

  .auth-panel .brand-row {
    margin-bottom: 28px;
  }

  .auth-panel h1 {
    font-size: 34px;
  }

  .auth-journey > div {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .auth-journey-icon {
    width: 32px;
    height: 32px;
  }

  .auth-journey > div:not(:last-child)::after {
    top: 37px;
    left: 15px;
  }

  .privacy-preference,
  .motion-preference {
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .privacy-preference > svg,
  .motion-preference > svg {
    width: 38px;
    height: 38px;
  }

  .privacy-preference button {
    grid-column: 1 / -1;
    width: 100%;
  }

  .setting-switch {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .dashboard-intro h1 {
    font-size: 28px;
  }

  .dashboard-motion-stage {
    min-height: 570px;
    grid-template-columns: minmax(0, 1fr);
    align-items: end;
  }

  .dashboard-motion-copy {
    align-self: end;
    padding: 236px 20px 26px;
  }

  .dashboard-motion-portrait {
    position: absolute;
    z-index: 2;
    top: 24px;
    right: 22px;
    width: 116px;
    margin: 0;
  }

  .dashboard-motion-portrait img {
    width: 116px;
    height: 164px;
  }

  .dashboard-motion-portrait figcaption {
    display: none;
  }

  .dashboard-motion-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    margin-bottom: 24px;
  }

  .dashboard-motion-actions button {
    width: 100%;
  }

  .first-run-guide {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
  }

  .first-run-portrait {
    min-height: 170px;
    grid-row: 1;
  }

  .first-run-portrait > img {
    position: absolute;
    inset: 0;
  }

  .first-run-portrait > div {
    right: 20px;
    bottom: 18px;
    left: 20px;
  }

  .first-run-portrait strong {
    font-size: 18px;
  }

  .first-run-main {
    grid-row: 2;
    padding: 26px 20px;
  }

  .first-run-main h1 {
    margin-top: 12px;
    font-size: 27px;
  }

  .first-run-choices {
    grid-template-columns: minmax(0, 1fr);
  }

  .first-run-choices button {
    min-height: 76px;
  }

  .first-run-result {
    display: grid;
    gap: 8px;
  }

  .support-intent {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 14px;
    padding: 14px 0;
  }

  .support-intent-control {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .support-intent-control button {
    display: grid;
    min-height: 56px;
    place-items: center;
    align-content: center;
    gap: 3px;
    padding: 5px 3px;
    font-size: 11px;
    white-space: normal;
  }

  .dashboard-next-step {
    grid-template-columns: 40px minmax(0, 1fr);
    align-items: start;
    gap: 14px;
    padding: 20px;
  }

  .dashboard-next-icon {
    width: 40px;
    height: 40px;
  }

  .dashboard-next-actions {
    grid-column: 1 / -1;
    width: 100%;
    max-width: none;
    justify-content: stretch;
  }

  .dashboard-next-actions button {
    flex: 1 1 180px;
  }

  .assessment-spotlight {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
    padding: 20px;
  }

  .assessment-spotlight h3 {
    font-size: 24px;
  }

  .assessment-spotlight .primary {
    width: 100%;
  }

  .memory-hero,
  .lab-mode-banner,
  .retention-nudge {
    align-items: stretch;
    flex-direction: column;
  }

  .lab-clarity-copy {
    padding: 20px;
  }

  .lab-clarity-copy h3 {
    font-size: 23px;
  }

  .lab-compare {
    padding: 10px;
  }

  .lab-compare-stage {
    min-height: 224px;
  }

  .lab-compare-layer {
    padding: 16px 14px;
  }

  .memory-hero-actions,
  .hero-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  .memory-hero-actions button,
  .hero-actions button,
  .retention-nudge button {
    width: 100%;
  }

  .tool-grid,
  .test-list,
  .price-grid,
  .profile-action-list,
  .profile-legal-links {
    grid-template-columns: minmax(0, 1fr);
  }

  .profile-identity {
    grid-template-columns: 60px minmax(0, 1fr);
  }

  .profile-zinaida-photo {
    width: 60px;
    height: 60px;
  }

  .profile-balance {
    grid-column: 1 / -1;
    justify-items: start;
    padding-top: 12px;
    border-top: 1px solid var(--border);
  }

  #view-chat {
    padding-bottom: 0;
  }

  .chat-layout {
    height: calc(100vh - 162px);
    height: calc(100dvh - 162px);
    min-height: 420px;
  }

  .conversation-panel {
    height: 100%;
    min-height: 0;
  }

  .conversation-presence {
    min-height: 56px;
    padding: 8px 12px;
  }

  .messages {
    padding: 16px 12px;
  }

  .message {
    max-width: 91%;
  }

  .chat-media-actions #chatMediaHint {
    display: none;
  }

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

  .chat-media-actions button {
    width: 100%;
    min-width: 0;
    min-height: 56px;
    flex-direction: column;
    gap: 3px;
    padding: 5px 4px;
    justify-content: center;
  }

  .chat-media-actions .button-label {
    display: block;
    min-width: 0;
    line-height: 1.15;
    white-space: normal;
  }

  .composer {
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 10px;
  }

  .chat-intent-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    overflow-x: visible;
    padding-right: 10px;
    padding-left: 10px;
  }

  .chat-intent-row button {
    min-width: 0;
    min-height: 48px;
    padding-right: 5px;
    padding-left: 5px;
    white-space: normal;
    line-height: 1.2;
  }

  .prompt-row button,
  .row-actions button,
  .inline-actions button {
    min-height: 44px;
  }

  .composer .primary {
    padding: 0 13px;
  }

  .video-frame {
    min-height: 440px;
  }

  .live-portrait-shell {
    width: min(280px, 76vw);
  }
}

@media (max-width: 430px) {
  .auth-screen {
    grid-template-rows: minmax(190px, 26svh) auto;
  }

  .auth-visual,
  .auth-portrait {
    min-height: 190px;
  }

  .auth-panel {
    padding-top: 24px;
  }

  .auth-panel .brand-row {
    display: none;
  }

  .auth-value-list small {
    display: none;
  }

  .topbar {
    padding: 0 14px;
  }

  .topbar .eyebrow {
    display: none;
  }

  .topbar h2 {
    font-size: 16px;
  }

  .topbar-profile-button {
    display: none;
  }

  .lab-feedback {
    align-items: stretch;
    flex-direction: column;
  }

  .lab-feedback-buttons button,
  .lab-outcome-status button {
    flex: 1 1 auto;
  }

  .lab-outcome-form .secondary {
    width: 100%;
  }

  .token-balance {
    min-height: 44px;
    padding: 0 9px;
  }

  .token-balance span {
    display: none;
  }

  .view {
    padding: 22px 14px 38px;
  }

  .dashboard-intro p {
    font-size: 14px;
  }

  .dashboard-next-step {
    padding: 18px 15px;
  }

  .dashboard-next-copy h3 {
    font-size: 18px;
  }

  .tool-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .tool-card.featured {
    grid-column: auto;
  }

  .composer input,
  .composer textarea {
    min-width: 0;
  }

  #chatForm .primary {
    width: 44px;
    overflow: hidden;
    padding: 0;
  }

  #chatForm .primary span {
    display: none;
  }

  .call-stage,
  .work-panel,
  .history-block,
  .center-panel,
  .memory-hero {
    padding: 16px;
  }

  .call-motion-control {
    top: 12px;
    right: 12px;
  }

  #view-lab .work-panel {
    padding: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .topbar::after {
    display: none !important;
  }

  .live-portrait-shell {
    transform: none !important;
  }

  .dashboard-motion-canvas {
    opacity: 0.72;
  }

  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation-duration: 0.01ms !important;
  }
}

/* State-driven motion: chat, voice, Laboratory, tests and visible memory. */
.brand-avatar.avatar-arrival {
  animation: avatar-arrival 720ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes avatar-arrival {
  0% { opacity: 0; transform: translateY(18px) scale(2.1); filter: blur(5px); }
  62% { opacity: 1; transform: translateY(0) scale(0.94); filter: blur(0); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

.message-copy + .message-copy {
  margin-top: 9px;
}

.message-copy-segment {
  animation: message-segment-arrive 430ms cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: var(--message-segment-delay, 0ms);
}

@keyframes message-segment-arrive {
  from { opacity: 0; transform: translateY(7px); }
  to { opacity: 1; transform: translateY(0); }
}

.chat-audio-shell {
  display: grid;
  width: min(100%, 360px);
  gap: 5px;
  margin-top: 10px;
}

.chat-audio-waveform {
  display: block;
  width: 100%;
  height: 44px;
  cursor: pointer;
}

.chat-audio-shell .chat-audio {
  width: 100%;
  margin: 0;
}

.message.is-voice-playing .message-avatar {
  box-shadow: 0 0 0 5px rgba(25, 115, 102, var(--voice-level, 0.18));
}

.lab-result-card {
  overflow: hidden;
}

.lab-thread-step {
  position: relative;
  margin-left: 8px;
  padding-left: 30px;
  opacity: 1;
  transform: none;
}

.lab-thread-step::before {
  position: absolute;
  z-index: 2;
  top: 17px;
  left: 4px;
  width: 10px;
  height: 10px;
  border: 3px solid var(--surface-subtle);
  border-radius: 50%;
  content: "";
  background: var(--brand);
  box-shadow: 0 0 0 1px var(--brand);
}

.lab-thread-step::after {
  position: absolute;
  top: 25px;
  bottom: -18px;
  left: 10px;
  width: 1px;
  content: "";
  background: var(--border-strong);
  transform: scaleY(0);
  transform-origin: top;
}

.lab-thread-step:last-of-type::after {
  display: none;
}

.lab-result-card.lab-thread-connected .lab-thread-step {
  animation: lab-thread-step-arrive 440ms cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(var(--lab-thread-index, 0) * 150ms);
}

.lab-result-card.lab-thread-connected .lab-thread-step::after {
  animation: lab-thread-line-grow 360ms ease forwards;
  animation-delay: calc(160ms + var(--lab-thread-index, 0) * 150ms);
}

@keyframes lab-thread-step-arrive {
  from { opacity: 0; transform: translateY(9px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes lab-thread-line-grow {
  to { transform: scaleY(1); }
}

.assessment-profile-build {
  display: grid;
  gap: 9px;
  margin-top: 5px;
  padding: 12px;
  border-left: 2px solid var(--brand);
  background: var(--surface-subtle);
}

.assessment-profile-label {
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 750;
}

.assessment-profile-scale {
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) minmax(100px, 1.2fr);
  align-items: center;
  gap: 10px;
  font-size: 12px;
}

.assessment-profile-track {
  display: block;
  height: 6px;
  overflow: hidden;
  border-radius: 3px;
  background: var(--border);
}

.assessment-profile-track i {
  display: block;
  width: var(--assessment-scale-value, 0%);
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
  transform: scaleX(1);
  transform-origin: left;
}

.assessment-history-card.is-assembling .assessment-profile-track i {
  animation: assessment-scale-grow 740ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(160ms + var(--assessment-scale-index, 0) * 120ms);
}

.assessment-history-card.is-assembled .assessment-profile-track i {
  transform: scaleX(1);
}

@keyframes assessment-scale-grow {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.history-row.action-row {
  position: relative;
  transition: opacity 260ms ease, transform 320ms cubic-bezier(0.4, 0, 1, 1), max-height 320ms ease, padding 320ms ease;
}

.history-row.action-row.is-memory-removing {
  opacity: 0;
  transform: translateX(18px);
}

.history-row.action-row.is-memory-pending {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  overflow: hidden;
  border: 0;
}

.history-row.memory-item-saved {
  animation: memory-item-saved 820ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.history-row.memory-item-saved::after {
  position: absolute;
  top: 8px;
  right: 0;
  padding: 3px 7px;
  border-radius: 4px;
  color: var(--brand);
  background: var(--brand-soft);
  content: attr(data-memory-status);
  font-size: 10px;
  font-weight: 750;
  animation: memory-status-fade 2.4s 1s both;
}

@keyframes memory-item-saved {
  from { background: rgba(25, 115, 102, 0.18); transform: translateY(-5px); }
  to { background: transparent; transform: translateY(0); }
}

@keyframes memory-status-fade {
  0%, 65% { opacity: 1; }
  100% { opacity: 0; }
}

.toast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.toast.hidden {
  display: none;
}

.toast-undo {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--brand);
  border-radius: 5px;
  color: var(--brand);
  background: transparent;
  font-weight: 750;
  cursor: pointer;
}

.studio-publication-camera-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(150px, 0.55fr);
  align-items: end;
  gap: 12px;
  padding-top: 15px;
  border-top: 1px solid var(--border);
}

#studioPublicationCameraPositionField[hidden],
#studioPublicationCameraDeviceField[hidden],
#studioPublicationMicrophoneField[hidden] {
  display: none;
}

.studio-publication-camera-controls > .studio-toggle {
  grid-column: 1 / -1;
}

.studio-microphone-toggle {
  padding: 11px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface-subtle);
}

.studio-option-switch button {
  min-height: 44px;
  line-height: 1.18;
  overflow-wrap: anywhere;
  white-space: normal;
}

@media (max-width: 1400px) {
  .studio-customization-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .studio-control-block:first-child {
    grid-column: auto;
  }
}

.studio-publication-camera-controls > p {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: var(--text-soft);
  font-size: 11px;
}

.studio-publication-camera-controls > p svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}

.studio-publication-camera-controls > p[data-state="ready"] {
  color: var(--brand);
}

.studio-publication-camera-controls > p[data-state="warning"],
.studio-publication-camera-controls > p[data-state="error"] {
  color: #8a3e2f;
}

.studio-publication-camera-source {
  position: fixed !important;
  top: -2px !important;
  left: -2px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0.001;
  pointer-events: none;
}

.studio-video-stage canvas.is-playing-preview {
  box-shadow: 0 0 0 1px rgba(25, 115, 102, 0.28);
}

@media (max-width: 640px) {
  .assessment-profile-scale,
  .studio-publication-camera-controls {
    grid-template-columns: minmax(0, 1fr);
  }

  .studio-publication-camera-controls > p {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .message-copy-segment,
  .lab-compare-layer,
  .lab-thread-step,
  .assessment-profile-track i,
  .history-row.action-row,
  .history-row.memory-item-saved,
  .brand-avatar.avatar-arrival {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }

  .lab-thread-step::after,
  .assessment-profile-track i {
    transform: scale(1) !important;
  }
}
