:root {
  --bg: #ffffff;
  --ink: #14161a;
  --mute: #8a8f98;
  --line: #ececec;
  --hit: #ff5a3d;
  --hit-soft: #fff1ee;
  --chip: #f4f5f7;
  --shadow: 0 0 0 1px var(--line);
  --ui: "Inter", ui-sans-serif, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--ink); font-family: var(--ui); }
button, input, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--hit);
  outline-offset: 2px;
}

.shell {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr);
}

.rail {
  position: sticky;
  top: 0;
  height: 100svh;
  display: flex;
  flex-direction: column;
  padding: 22px 18px;
  border-right: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 8px 28px;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.04em;
}

.logo {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--hit);
  color: #fff;
  display: grid;
  place-items: center;
}

.rail nav { display: flex; flex-direction: column; gap: 4px; }
.rail nav button, .rail .create {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 999px;
  text-align: left;
  font-size: 16px;
  font-weight: 650;
}
.rail nav button:hover { background: #f6f6f6; }
.rail nav button.active { background: var(--ink); color: #fff; }
.rail nav .badge {
  margin-left: auto;
  min-width: 18px;
  height: 18px;
  border-radius: 99px;
  background: var(--hit);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  display: grid;
  place-items: center;
}
.rail .create {
  margin-top: 14px;
  justify-content: center;
  background: var(--hit);
  color: #fff;
  font-weight: 800;
}
.rail .create:hover { filter: brightness(0.95); }
.me-btn {
  margin-top: auto;
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 8px;
  border-radius: 16px;
  text-align: left;
}
.me-btn:hover { background: #f6f6f6; }
.me-btn b { display: block; font-size: 14px; }
.me-btn small { color: var(--mute); font-size: 12px; }

.stage { min-width: 0; }
.layout {
  display: grid;
  grid-template-columns: minmax(0, 680px) 320px;
  gap: 28px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

.tabs {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.tabs button {
  flex: 1;
  min-height: 54px;
  color: var(--mute);
  font-weight: 700;
  position: relative;
}
.tabs button.active { color: var(--ink); }
.tabs button.active:after {
  content: "";
  position: absolute;
  left: 24%;
  right: 24%;
  bottom: 0;
  height: 3px;
  border-radius: 99px;
  background: var(--hit);
}
.note-btn { width: 54px; color: var(--mute); position: relative; }
.note-btn .dot {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 8px;
  height: 8px;
  border-radius: 99px;
  background: var(--hit);
}

.search {
  display: grid;
  grid-template-columns: 1fr auto;
  margin: 16px 0 12px;
  border: 1px solid #e2e2e2;
  border-radius: 16px;
  overflow: hidden;
}
.search input {
  border: 0;
  min-width: 0;
  height: 48px;
  padding: 0 16px;
  background: #fff;
}
.search button {
  padding: 0 18px;
  background: var(--ink);
  color: #fff;
  font-weight: 800;
}

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button {
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--chip);
  font-size: 13px;
  font-weight: 650;
}
.chips button.active { background: var(--ink); color: #fff; }

.stories {
  display: flex;
  gap: 14px;
  margin: 18px 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.stories::-webkit-scrollbar { display: none; }
.story {
  min-width: 72px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 650;
}
.story .ava { width: 58px; height: 58px; }
.story.results .ava {
  background: #19c37d;
  color: #fff;
  border: 0;
  font-size: 18px;
}

.composer {
  width: 100%;
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--mute);
  text-align: left;
}
.plus { color: var(--hit); font-size: 22px; font-weight: 700; }

.card {
  margin-bottom: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
}
.card-head {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 14px 16px 0;
}
.who b { display: flex; align-items: center; gap: 4px; font-size: 14px; }
.who span { color: var(--mute); font-size: 12px; }
.card-copy { padding: 8px 16px 12px; }
.kind {
  color: var(--hit);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
}
.card-copy h2 {
  margin: 8px 0 8px;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.03em;
}
.card-copy p { margin: 0; color: #3a3f47; line-height: 1.5; }
.media { width: 100%; max-height: 420px; object-fit: cover; display: block; }
.audio, .collection, .trust {
  margin: 12px 16px 0;
  padding: 12px;
  border-radius: 14px;
  background: var(--chip);
}
.audio { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.collection button, .place {
  display: block;
  width: 100%;
  text-align: left;
  padding: 8px 0;
  border-top: 1px solid #e6e6e6;
}
.place:first-child { border: 0; }
.place b { display: block; }
.place small { color: var(--mute); }
.trust { background: none; color: var(--mute); font-size: 13px; padding: 10px 16px 0; }
.why-link { margin-left: 8px; color: var(--ink); font-weight: 700; }
.actions {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 10px 12px;
}
.ico { width: 40px; height: 40px; border-radius: 12px; color: #555; }
.ico.on { color: var(--hit); }
.ico.saved { color: var(--ink); }
.count { color: var(--mute); font-size: 13px; font-weight: 700; min-width: 18px; }
.cta {
  margin-left: auto;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.cta:hover { background: var(--hit); }

.stop {
  padding: 28px 8px;
  text-align: center;
}
.stop h3 { margin: 0 0 6px; font-size: 22px; }
.stop p { color: var(--mute); margin: 0 0 14px; }
.ghost {
  min-height: 40px;
  padding: 0 14px;
  font-weight: 700;
  color: var(--mute);
}

.side { padding-top: 18px; }
.widget {
  margin-bottom: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
}
.widget.intro { border-top: 3px solid var(--hit); }
.widget h2 { margin: 8px 0; font-size: 20px; letter-spacing: -0.03em; }
.widget h3 { margin: 0 0 10px; font-size: 14px; }
.widget p { color: var(--mute); font-size: 14px; line-height: 1.45; }
.kicker { color: var(--hit); font-size: 11px; font-weight: 800; letter-spacing: 0.12em; }
.full {
  width: 100%;
  min-height: 44px;
  margin-top: 12px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-weight: 800;
}
.row {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 10px;
  width: 100%;
  padding: 8px 0;
  text-align: left;
}
.row b { display: block; font-size: 13px; }
.row small { color: var(--mute); font-size: 12px; }
.topic {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 8px;
  width: 100%;
  padding: 8px 0;
  text-align: left;
  font-weight: 700;
}
.demo { color: var(--mute); font-size: 12px; line-height: 1.4; }

.avatar, .ava {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
  color: #fff;
  background: #222;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}
.tone-olga { background: #14161a; }
.tone-marina { background: #3d6bff; }
.tone-lena { background: #b44adf; }
.tone-anna { background: #e09b2d; }
.tone-ilya { background: #1f8a70; }
.tone-dina { background: #d4537e; }
.tone-new { background: var(--hit); }
.check { color: #3d8bff; font-size: 13px; }

.layer { position: fixed; inset: 0; z-index: 40; }
.scrim { position: absolute; inset: 0; background: rgba(20,22,26,0.28); }
.panel {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: min(440px, 100%);
  background: #fff;
  overflow: auto;
  box-shadow: -12px 0 40px rgba(0,0,0,0.08);
}
.panel header {
  position: sticky;
  top: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 64px;
  padding: 0 18px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.panel header h2 { margin: 0; font-size: 20px; }
.body { padding: 20px 18px 40px; }
.lead { margin: 0 0 16px; font-size: 22px; letter-spacing: -0.03em; }
.types button, .item {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
}
.types button { grid-template-columns: 1fr; }
.types b { display: block; }
.types small, .item small, .item em { color: var(--mute); font-style: normal; font-size: 13px; }
label > span, .lbl {
  display: block;
  margin: 12px 0 6px;
  color: var(--mute);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
textarea, select, .field {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  resize: vertical;
}
.hint { color: var(--mute); font-size: 13px; line-height: 1.45; margin: 12px 0; }
.back { margin-bottom: 12px; color: var(--mute); font-weight: 700; }
.bubble {
  max-width: 82%;
  width: fit-content;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 16px;
  background: var(--chip);
  line-height: 1.4;
}
.bubble.out { margin-left: auto; background: var(--ink); color: #fff; }
.chat-form, .composer-form {
  display: grid;
  grid-template-columns: 1fr 44px;
  gap: 8px;
  margin-top: 16px;
  border-bottom: 2px solid var(--ink);
}
.chat-form input, .composer-form input { border: 0; height: 42px; }
.chat-head { display: flex; gap: 10px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.hero-p { display: flex; gap: 12px; align-items: center; }
.big-av { width: 72px; height: 72px; font-size: 22px; }
.now { margin: 18px 0; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ptabs { display: flex; gap: 16px; border-bottom: 1px solid var(--line); }
.ptabs button { padding: 10px 0; color: var(--mute); font-weight: 700; }
.ptabs button.active { color: var(--ink); box-shadow: inset 0 -2px 0 var(--hit); }
.stats div {
  display: flex;
  justify-content: space-between;
  min-height: 48px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.why div { display: grid; grid-template-columns: 28px 1fr; gap: 8px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.why i { color: var(--hit); font-style: normal; font-weight: 800; }
.step { display: grid; grid-template-columns: 12px 1fr; gap: 12px; padding-bottom: 14px; }
.dot { width: 10px; height: 10px; margin-top: 6px; border-radius: 50%; background: var(--hit); }
.comment { display: grid; grid-template-columns: 36px 1fr; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }

.gate {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #fff;
}
.gate-card { width: min(420px, 100%); }
.gate-card h1 { margin: 8px 0 6px; font-size: 36px; letter-spacing: -0.05em; }
.gate-card p { color: var(--mute); }
.gate-card form { display: flex; flex-direction: column; gap: 8px; margin-top: 18px; }
.switch { margin-top: 10px; color: var(--mute); font-weight: 700; }
.err { color: var(--hit); font-size: 13px; min-height: 18px; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 70;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}
.dock { display: none; }
.verified { color: #3d8bff; }

.test-bar {
  position: sticky;
  top: 0;
  z-index: 9;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 0 auto;
  max-width: 1080px;
  padding: 12px 24px 0;
  font-size: 13px;
  font-weight: 650;
}
.test-bar span { color: var(--mute); }
.test-actions { display: flex; gap: 8px; flex-shrink: 0; }
.test-bar button {
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--hit-soft);
  color: var(--hit);
  font-weight: 800;
  font-size: 12px;
}
.office {
  max-width: 1080px;
  margin: 0 auto;
  padding: 18px 24px 80px;
}
.office-head {
  display: grid;
  grid-template-columns: 1fr minmax(180px, 240px);
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
}
.office h1 { margin: 4px 0 8px; font-size: 32px; letter-spacing: -0.05em; }
.office-head p, .office p { color: var(--mute); }
.office-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 18px 0;
}
.office-stats div {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
}
.office-stats span { display: block; color: var(--mute); font-size: 12px; font-weight: 700; }
.office-stats strong { font-size: 22px; }
.letter {
  white-space: pre-wrap;
  padding: 14px;
  border-radius: 16px;
  background: var(--chip);
  font: inherit;
  font-size: 14px;
  line-height: 1.45;
}
.table-wrap { overflow: auto; }
.office-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.office-table th {
  text-align: left;
  color: var(--mute);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 10px 8px;
}
.office-table td { padding: 12px 8px; border-top: 1px solid var(--line); vertical-align: top; }
.office-table small { display: block; color: var(--mute); }
.note-card {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.note-card.read { opacity: 0.62; }
.note-card header { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; }
.mood {
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--hit-soft);
  color: var(--hit);
  font-size: 12px;
  font-weight: 800;
}
.invite-row {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  align-items: center;
}
.invite-form { display: grid; gap: 8px; margin-top: 16px; }
.chip-opt {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--chip);
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 1100px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .side { display: none; }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .rail { display: none; }
  .layout { padding: 0 12px 88px; }
  .test-bar, .office { padding-left: 12px; padding-right: 12px; }
  .office-head, .office-stats, .invite-row { grid-template-columns: 1fr; }
  .dock {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    height: 68px;
    background: #fff;
    border-top: 1px solid var(--line);
    z-index: 20;
  }
  .dock button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: 10px;
    font-weight: 700;
    color: var(--mute);
  }
  .dock button.active { color: var(--ink); }
  .dock .make {
    width: 34px; height: 34px;
    display: grid; place-items: center;
    border-radius: 10px;
    background: var(--hit); color: #fff; font-size: 20px;
  }
  .panel { top: 8vh; border-radius: 18px 18px 0 0; }
}
