:root {
  --ink: #1f3430;
  --muted: #6c7974;
  --teal: #087f73;
  --teal-dark: #07685e;
  --teal-soft: #e7f3ee;
  --line: #e6e9e3;
  --paper: #fbfcf8;
  --white: #fff;
  --red: #b13b37;
  --shadow: 0 12px 48px #213d3012;
  font-family: Inter,"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif;
  color: var(--ink);
  font-size: 14px;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
}

button,input,textarea {
  font: inherit;
}

button,a,input,textarea {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: default;
  opacity: .55;
}

a {
  color: inherit;
}

button,input,textarea {
  outline: none;
}

button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible,summary:focus-visible,[tabindex="0"]:focus-visible {
  outline: 3px solid #0b8a7c;
  outline-offset: 4px;
}

button,input,textarea {
  transition: background .18s,border-color .18s,box-shadow .18s;
}

button {
  color: inherit;
}

svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

[hidden] {
  display: none!important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 1px;
}

.brand>span:last-child {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.brand small {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .4px;
  color: var(--muted);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 43px;
  height: 43px;
  border-radius: 13px;
  background: var(--teal);
  color: #fff;
  box-shadow: 0 5px 10px #087f7312;
}

.brand-mark svg {
  width: 27px;
  height: 27px;
  stroke-width: 1.6;
}

.eyebrow {
  font-size: 10px;
  letter-spacing: 1.8px;
  font-weight: 600;
  color: var(--teal);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 44px;
  padding: 11px 20px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-weight: 600;
  line-height: 1.5;
}

.button-primary {
  background: var(--teal);
  color: white;
}

.button-primary:hover:not(:disabled) {
  background: var(--teal-dark);
  box-shadow: 0 4px 12px #087f731a;
}

.button-primary svg {
  width: 18px;
  height: 18px;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  border: 0;
  background: transparent;
  border-radius: 10px;
  color: var(--muted);
}

.icon-button:hover {
  background: #eaf0e9;
  color: var(--ink);
}

.text-button {
  min-height: 44px;
  background: transparent;
  border: 0;
  padding: 10px 14px;
  color: var(--teal);
  font-size: 13px;
}

.text-button:hover {
  background: var(--teal-soft);
  border-radius: 8px;
}

.muted {
  color: var(--muted);
}

/* Entry: calm editorial space paired with a concise account form. */
.auth-view {
  display: grid;
  grid-template-columns: minmax(480px,1.05fr) minmax(460px,1fr);
  min-height: 100dvh;
}

.brand-story {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 760px;
  padding: 44px 8%;
  overflow: hidden;
  background: #eaf1e8;
  background-image: radial-gradient(ellipse at 15% 100%,#dbe9d966,transparent 60%);
}

.brand-story:after {
  content: "";
  position: absolute;
  width: 440px;
  height: 440px;
  border: 1px solid #cbd9ca80;
  border-radius: 50%;
  top: -265px;
  right: -240px;
  pointer-events: none;
}

.story-content {
  margin: auto 0;
  position: relative;
  padding: 45px 0 0;
}

.story-content .eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 9px;
  letter-spacing: 1.8px;
}

.eyebrow>span:first-child {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
}

.story-content h1 {
  font-size: clamp(38px,4vw,60px);
  line-height: 1.45;
  letter-spacing: -1.8px;
  font-weight: 650;
  margin: 25px 0 24px;
}

.hand-underlined {
  position: relative;
  white-space: nowrap;
  color: var(--teal);
}

.hand-underlined:after {
  content: "";
  position: absolute;
  left: 0;
  right: 2px;
  bottom: -5px;
  height: 7px;
  background: #b7d3b1;
  border-radius: 50%;
  transform: rotate(-2deg);
  z-index: 0;
}

.story-content>p {
  font-size: 15px;
  color: #627269;
  line-height: 1.9;
  margin: 0;
}

.story-art {
  height: 240px;
  position: relative;
  margin: 8px -5% 0 1%;
  max-width: 510px;
}

.art-orbit {
  position: absolute;
  border: 1px solid #d3dfd1;
  border-radius: 50%;
  width: 180px;
  height: 180px;
  left: 32%;
  top: 20px;
  transform: rotate(-22deg) scaleX(1.5);
}

.orbit-two {
  width: 130px;
  height: 130px;
  top: 43px;
  left: 38%;
  border-style: dashed;
}

.art-card {
  position: absolute;
  background: #fffffff5;
  border: 1px solid #fff;
  box-shadow: 0 15px 35px #415d3910;
  display: flex;
  align-items: center;
  border-radius: 15px;
  gap: 12px;
}

.art-chat {
  top: 35px;
  left: 1%;
  width: 240px;
  padding: 18px;
  transform: rotate(-5deg);
}

.art-avatar {
  background: #e3eee2;
  color: var(--teal);
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 13px;
}

.art-lines {
  flex: 1;
  display: grid;
  gap: 9px;
}

.art-lines i {
  height: 6px;
  width: 100%;
  background: #e5ebe3;
  border-radius: 8px;
}

.art-lines i:last-child {
  width: 65%;
}

.art-dot {
  height: 7px;
  width: 7px;
  background: #bdd3b9;
  border-radius: 50%;
  align-self: flex-start;
  margin-top: 4px;
}

.art-connection {
  position: absolute;
  top: 85px;
  left: 21%;
  width: 230px;
  color: #63715f;
}

.art-connection svg {
  width: 100%;
  height: 100px;
}

.art-file {
  right: 0;
  bottom: 32px;
  max-width: 285px;
  padding: 17px;
  transform: rotate(4deg);
}

.art-file-icon {
  width: 42px;
  height: 50px;
  border-radius: 10px;
  background: #f6ead4;
  color: #63715f;
  display: grid;
  place-items: center;
}

.art-file strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.art-file small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 7px;
  white-space: nowrap;
}

.art-check {
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e8f2e7;
  color: var(--teal);
  height: 23px;
  width: 23px;
  margin-left: 6px;
}

.art-check svg {
  height: 14px;
  width: 14px;
  stroke-width: 2;
}

.art-spark {
  position: absolute;
  font-size: 26px;
  color: #63715f;
}

.spark-one {
  right: 15%;
  top: 25px;
}

.spark-two {
  left: 8%;
  bottom: 20px;
  font-size: 20px;
  color: #63715f;
}

.story-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-top: 25px;
  border-top: 1px solid #d3dfd1;
  color: #5c7064;
  font-size: 11px;
  white-space: nowrap;
}

.story-foot>span {
  display: flex;
  align-items: center;
  gap: 7px;
}

.story-foot svg {
  height: 16px;
  width: 16px;
}

.auth-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 35px 40px 24px;
  background: #fcfcf9;
  position: relative;
}

.auth-top-note {
  align-self: flex-end;
  font-size: 11px;
  color: #63715f;
  letter-spacing: 1px;
}

.auth-card {
  width: 100%;
  max-width: 356px;
  margin: auto;
  padding: 40px 0;
}

.auth-badge {
  display: grid;
  place-items: center;
  width: 47px;
  height: 47px;
  border-radius: 14px;
  background: #edf3e9;
  color: var(--teal);
  margin-bottom: 22px;
}

.auth-badge svg {
  width: 25px;
  height: 25px;
}

.auth-card h2 {
  font-size: 28px;
  line-height: 1.4;
  font-weight: 650;
  letter-spacing: -.7px;
  margin: 0 0 10px;
}

.auth-subtitle {
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 28px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  background: #eff2eb;
  border-radius: 10px;
  margin-bottom: 27px;
}

.auth-tabs button {
  min-height: 44px;
  border: 0;
  background: transparent;
  border-radius: 7px;
  color: var(--muted);
  font-size: 13px;
}

.auth-tabs button[aria-selected="true"] {
  background: white;
  color: var(--teal);
  box-shadow: 0 1px 5px #203d3410;
  font-weight: 600;
}

.field {
  margin-bottom: 20px;
}

.field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
}

.field label span {
  font-size: 10px;
  color: var(--muted);
  font-weight: 400;
  margin-left: 6px;
}

.field input {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  border: 1px solid #dfe4dc;
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
}

.field input::placeholder {
  color: #63715f;
}

.field input:hover {
  border-color: #b6c8bd;
}

.field input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px #087f7310;
}

.field input:focus-visible {
  outline: none;
}

.field small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  padding: 6px 1px 0;
}

.password-field {
  position: relative;
}

.password-field input {
  padding-right: 48px;
}

.password-field button {
  position: absolute;
  right: 1px;
  top: 1px;
}

.password-field svg {
  width: 18px;
  height: 18px;
}

.auth-submit {
  width: 100%;
  margin-top: 4px;
  height: 48px;
  justify-content: space-between;
  padding-inline: 20px;
  font-size: 13px;
}

.auth-tip {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 23px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  color: var(--muted);
}

.auth-tip svg {
  width: 17px;
  height: 17px;
  margin-top: 2px;
  color: #63715f;
}

.auth-tip p {
  margin: 0;
  line-height: 1.9;
  font-size: 11px;
}

.auth-tip strong {
  color: #4d6559;
  font-weight: 600;
}

.auth-footer {
  font-size: 10px;
  color: #63715f;
  letter-spacing: .2px;
  text-align: center;
}

.auth-footer>span {
  margin: 0 9px;
}

.inline-error {
  color: var(--red);
  background: #fff0ec;
  border-radius: 8px;
  padding: 11px 13px;
  font-size: 12px;
  line-height: 1.7;
  margin-bottom: 16px;
}

/* Workspace */
.workspace {
  height: 100dvh;
  display: flex;
  overflow: hidden;
}

.sidebar {
  width: 244px;
  flex-shrink: 0;
  background: #f3f5ee;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 31px 18px 0;
}

.sidebar .brand {
  font-size: 23px;
  gap: 10px;
}

.sidebar .brand-mark {
  width: 37px;
  height: 37px;
  border-radius: 11px;
}

.sidebar .brand-mark svg {
  width: 24px;
  height: 24px;
}

.sidebar .brand>span:last-child {
  gap: 7px;
}

.sidebar .brand small {
  font-size: 11px;
}

.sidebar-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 9px;
  margin-bottom: 42px;
}

.sidebar-caption {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  color: #63715f;
  padding: 0 12px;
  margin: 0 0 12px;
}

.sidebar-caption>span {
  font-size: 9px;
  letter-spacing: .6px;
  color: #63715f;
}

.nav-item {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 12px;
  min-height: 46px;
  padding: 12px 14px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  text-align: left;
  font-size: 13px;
  color: #63715f;
  margin-bottom: 6px;
}

.nav-item svg {
  width: 19px;
  height: 19px;
}

.nav-item:hover {
  background: #e8eee3;
}

.nav-item.active {
  background: #dfece1;
  color: #155d49;
  font-weight: 600;
}

.nav-item>span:nth-child(2) {
  flex: 1;
}

.nav-indicator {
  width: 6px;
  height: 6px;
  background: var(--teal);
  border-radius: 50%;
}

.small-count {
  min-width: 21px;
  padding: 2px 5px;
  text-align: center;
  border-radius: 5px;
  background: #e5eae0;
  font-size: 10px;
}

.device-section {
  margin-top: 35px;
  border-top: 1px solid #e2e7db;
  padding-top: 24px;
}

.device-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 5px 12px;
  max-height: 25vh;
  overflow: auto;
}

.device-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.device-icon {
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  flex-shrink: 0;
  border-radius: 8px;
  background: #e7ece2;
  color: #63715f;
}

.device-icon svg {
  height: 16px;
  width: 16px;
}

.device-info {
  min-width: 0;
  flex: 1;
}

.device-info strong {
  display: block;
  font-size: 11px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.device-info small {
  display: block;
  font-size: 9px;
  color: #63715f;
  margin-top: 3px;
}

.device-dot {
  height: 6px;
  width: 6px;
  background: #5f9362;
  border-radius: 50%;
}

.sidebar-muted {
  font-size: 11px;
  line-height: 1.8;
  color: #63715f;
  margin: 0;
}

.sidebar-bottom {
  margin-top: auto;
  padding-top: 25px;
}

.space-note {
  margin: 0 10px 25px;
}

.space-note>svg {
  display: block;
  height: 20px;
  width: 20px;
  color: #63715f;
  margin-bottom: 10px;
}

.space-note strong {
  font-size: 11px;
  font-weight: 500;
  color: #536d57;
}

.space-note p {
  font-size: 10px;
  line-height: 1.9;
  color: #63715f;
  margin: 8px 0;
}

.account {
  border-top: 1px solid #dfe6da;
  min-height: 85px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 7px;
}

.account-avatar {
  width: 35px;
  height: 35px;
  border-radius: 10px;
  background: #dce8d4;
  color: #40633f;
  display: grid;
  place-items: center;
  font-size: 14px;
  flex-shrink: 0;
  font-weight: 600;
}

.account>div {
  flex: 1;
  min-width: 0;
}

.account strong {
  font-size: 12px;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account>div>span {
  display: block;
  font-size: 10px;
  color: #63715f;
  margin-top: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account .icon-button {
  margin-right: -8px;
}

.account svg {
  height: 18px;
  width: 18px;
}

.chat-main {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
  background: #fbfcf9;
}

.chat-header {
  min-height: 97px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 23px 39px;
  border-bottom: 1px solid var(--line);
  background: #ffffffc7;
  gap: 16px;
  flex-shrink: 0;
}

.chat-heading .eyebrow {
  font-size: 8px;
  letter-spacing: 1.8px;
  color: #63715f;
  margin-bottom: 7px;
}

.chat-heading h1 {
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 19px;
  letter-spacing: .2px;
  font-weight: 600;
  margin: 0;
}

.heading-dot {
  height: 6px;
  width: 6px;
  background: #adc6a1;
  border-radius: 50%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 17px;
}

.connection-status {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  font-size: 10px;
  color: #496b4d;
  background: #eff5e9;
  border: 1px solid #e3eddc;
  padding: 6px 10px;
  border-radius: 6px;
}

.connection-status i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #669662;
}

.connection-status.connecting {
  background: #f8f2e7;
  color: #7b653b;
  border-color: #eee3ce;
}

.connection-status.connecting i {
  background: #b89961;
}

.file-toggle {
  border: 1px solid var(--line);
  min-height: 44px;
  min-width: 44px;
  height: 44px;
  background: #fff;
}

.file-toggle svg {
  height: 18px;
  width: 18px;
}

.space-banner {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 7px;
  padding: 11px 20px;
  background: #f4f7ef;
  border-bottom: 1px solid #eaf0e3;
  font-size: 10px;
  color: #63715f;
  flex-shrink: 0;
}

.space-banner svg {
  height: 13px;
  width: 13px;
}

.messages-scroll {
  flex: 1;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 10px 40px 22px;
  scrollbar-width: thin;
  scrollbar-color: #dbe2d6 transparent;
  position: relative;
}

.history-top {
  min-height: 30px;
  text-align: center;
  font-size: 11px;
}

.empty-state {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  text-align: center;
  pointer-events: none;
  padding: 25px;
}

.empty-illustration {
  width: 120px;
  height: 108px;
  display: grid;
  place-items: center;
  position: relative;
  margin-bottom: 17px;
}

.empty-circle {
  width: 99px;
  height: 99px;
  border: 1px solid #dfebd5;
  border-radius: 35px;
  background: #eef4e8;
  position: absolute;
  transform: rotate(-9deg);
}

.empty-illustration>svg {
  height: 44px;
  width: 44px;
  color: #63715f;
  stroke-width: 1.2;
  position: relative;
}

.empty-small {
  display: grid;
  place-items: center;
  position: absolute;
  width: 34px;
  height: 34px;
  right: 0;
  bottom: 0;
  background: #fff;
  border: 1px solid #e4eadc;
  border-radius: 11px;
  transform: rotate(10deg);
  box-shadow: 0 4px 8px #4c71320a;
  color: #63715f;
}

.empty-small svg {
  width: 18px;
  height: 18px;
}

.empty-eyebrow {
  font-size: 8px;
  letter-spacing: 2px;
  color: #63715f;
  margin: 9px 0 12px;
}

.empty-state h2 {
  font-size: 23px;
  letter-spacing: .5px;
  font-weight: 500;
  margin: 0 0 12px;
}

.empty-state p {
  font-size: 12px;
  color: #63715f;
  line-height: 1.9;
  margin: 0;
}

.empty-tags {
  display: flex;
  gap: 18px;
  margin-top: 25px;
  color: #63715f;
  font-size: 10px;
}

.empty-tags span {
  display: flex;
  gap: 5px;
  align-items: center;
}

.empty-tags svg {
  height: 13px;
  width: 13px;
}

.messages {
  max-width: 1020px;
  margin: auto;
}

.day-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-size: 10px;
  color: #63715f;
  margin: 25px 0 22px;
}

.day-divider:before,.day-divider:after {
  content: "";
  width: 42px;
  height: 1px;
  background: #e3e8dd;
}

.message {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  margin: 0 0 22px;
  animation: appear .15s ease-out;
}

.message.own {
  flex-direction: row-reverse;
}

.message-avatar {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: #e9eee1;
  color: #63715f;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
  margin-top: 2px;
}

.message.own .message-avatar {
  background: #d6e9de;
  color: var(--teal);
}

.message-body {
  max-width: min(76%,650px);
  min-width: 0;
}

.message-meta {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 0 0 7px;
  font-size: 10px;
  color: #63715f;
}

.message.own .message-meta {
  justify-content: flex-end;
}

.message-device {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 220px;
}

.message-time {
  font-size: 9px;
  color: #63715f;
  white-space: nowrap;
}

.message-bubble {
  background: #fff;
  border: 1px solid #e4e9dd;
  border-radius: 0 13px 13px;
  padding: 12px 15px;
  font-size: 13px;
  line-height: 1.8;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
  box-shadow: 0 2px 3px #52643c03;
}

.message.own .message-bubble {
  background: #e2f0e7;
  border-color: #d5e8dc;
  border-radius: 13px 0 13px 13px;
  color: #234c3f;
}

.file-bubble {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
  max-width: 100%;
  text-decoration: none;
  white-space: normal;
  padding: 14px;
}

.file-bubble:hover {
  border-color: #90b59a;
}

.file-type-icon {
  width: 39px;
  height: 45px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: #f3ecdd;
  color: #63715f;
}

.file-type-icon svg {
  width: 23px;
  height: 23px;
}

.file-details {
  min-width: 0;
  flex: 1;
}

.file-name {
  display: block;
  font-size: 12px;
  font-weight: 500;
  overflow-wrap: anywhere;
  line-height: 1.6;
}

.file-size {
  font-size: 10px;
  color: #63715f;
  margin-top: 4px;
  display: block;
}

.file-download {
  width: 17px;
  height: 17px;
  color: #63715f;
  margin-left: 6px;
}

.composer-section {
  padding: 0 35px 15px;
  flex-shrink: 0;
  background: #fbfcf9;
  position: relative;
  z-index: 2;
}

.composer {
  background: #fff;
  border: 1px solid #dce5d7;
  border-radius: 13px;
  box-shadow: 0 4px 15px #3b632108;
  padding: 14px 16px 10px;
}

.composer:focus-within {
  border-color: #9bb9a0;
  box-shadow: 0 0 0 3px #087f7306;
}

.composer textarea {
  display: block;
  resize: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  width: 100%;
  min-height: 58px;
  max-height: 150px;
  line-height: 1.8;
  font-size: 13px;
  padding: 0 2px;
}

.composer textarea:focus-visible {
  outline: none;
}

.composer textarea::placeholder {
  color: #63715f;
}

.composer-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding-top: 6px;
}

.composer-toolbar>div {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.attach-button {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  background: none;
  font-size: 11px;
  color: #63715f;
  padding: 0 8px;
  margin-left: -6px;
  white-space: nowrap;
}

.attach-button:hover {
  background: #f1f5ec;
}

.attach-button svg {
  height: 17px;
  width: 17px;
}

.file-limit {
  font-size: 9px;
  color: #63715f;
  white-space: nowrap;
}

.keyboard-hint {
  font-size: 9px;
  color: #63715f;
  white-space: nowrap;
  margin-right: 7px;
}

.keyboard-hint>span {
  margin: 0 4px;
}

.send-button {
  font-size: 11px;
  border-radius: 8px;
  min-height: 44px;
  padding: 8px 14px;
  gap: 10px;
}

.send-button svg {
  height: 14px;
  width: 14px;
}

.send-button:disabled {
  background: #a5bcaa;
  opacity: .8;
}

.message-length {
  font-size: 10px;
  color: #63715f;
  white-space: nowrap;
}

.composer-footnote {
  text-align: center;
  font-size: 9px;
  color: #63715f;
  margin: 10px 0 0;
}

.composer-error {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #f0dacf;
  background: #fff4ef;
  border-radius: 10px;
  font-size: 12px;
  padding: 5px 9px 5px 13px;
  color: var(--red);
  margin-bottom: 10px;
}

.composer-error>span {
  flex: 1;
  overflow-wrap: anywhere;
}

.composer-error .text-button {
  white-space: nowrap;
  padding: 6px;
  color: var(--red);
}

.composer-error .icon-button {
  min-width: 44px;
  color: var(--red);
}

.composer-error .icon-button svg {
  height: 16px;
  width: 16px;
}

.upload-status {
  border: 1px solid #dde8d6;
  border-radius: 10px;
  padding: 4px 12px 10px;
  background: #f3f8ee;
  margin-bottom: 10px;
}

.upload-top {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 11px;
  color: #536b4a;
}

.upload-top>svg {
  height: 17px;
  width: 17px;
}

.upload-top>span:first-of-type {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-top .icon-button {
  min-width: 44px;
  min-height: 44px;
}

.upload-top .icon-button svg {
  height: 15px;
  width: 15px;
}

progress {
  display: block;
  height: 4px;
  width: 100%;
  appearance: none;
  border: 0;
  border-radius: 5px;
  overflow: hidden;
  background: #dfe9d7;
}

progress::-webkit-progress-bar {
  background: #dfe9d7;
}

progress::-webkit-progress-value {
  background: var(--teal);
}

progress::-moz-progress-bar {
  background: var(--teal);
}

.new-messages {
  position: absolute;
  bottom: 200px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  background: white;
  color: var(--teal);
  border-color: #cbded0;
  box-shadow: var(--shadow);
  font-size: 11px;
  min-height: 44px;
  padding: 7px 15px;
  white-space: nowrap;
}

.drop-overlay {
  position: absolute;
  z-index: 10;
  inset: 16px;
  border: 2px dashed #73a37c;
  background: #f0f7eded;
  border-radius: 18px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  gap: 16px;
  pointer-events: none;
}

.drop-overlay>svg {
  height: 52px;
  width: 52px;
  color: var(--teal);
  stroke-width: 1.2;
}

.drop-overlay>strong {
  font-size: 22px;
  font-weight: 500;
}

.drop-overlay>span {
  font-size: 12px;
  color: var(--muted);
}

/* A native dialog keeps file browsing accessible on every screen. */
.files-dialog {
  position: fixed;
  inset: 0 0 0 auto;
  margin: 0;
  width: 350px;
  max-width: 100%;
  height: 100dvh;
  max-height: 100dvh;
  border: 0;
  border-left: 1px solid var(--line);
  padding: 30px 24px 22px;
  background: #fbfcf8;
  color: var(--ink);
  box-shadow: -15px 0 50px #16382216;
}

.files-dialog[open] {
  display: flex;
  flex-direction: column;
}

.files-dialog::backdrop {
  background: #1f392c2e;
  backdrop-filter: blur(2px);
}

.files-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.files-header .eyebrow {
  font-size: 8px;
  color: #63715f;
}

.files-header h2 {
  font-size: 22px;
  font-weight: 550;
  margin: 7px 0;
}

.files-description {
  font-size: 11px;
  color: #63715f;
  line-height: 1.8;
  margin: 16px 0;
}

.files-search {
  display: flex;
  align-items: center;
  border: 1px solid #dce4d6;
  border-radius: 9px;
  background: #fff;
  padding: 0 11px;
  gap: 9px;
  flex-shrink: 0;
}

.files-search>svg {
  width: 17px;
  height: 17px;
  color: #63715f;
}

.files-search input {
  min-width: 0;
  width: 100%;
  height: 44px;
  border: 0;
  background: none;
  font-size: 12px;
  color: var(--ink);
}

.files-search:focus-within {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
}

.files-search input:focus-visible {
  outline: 0;
}

.shared-files {
  overflow-y: auto;
  margin-top: 20px;
  min-height: 0;
}

.shared-file {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.shared-file:hover .file-name {
  color: var(--teal);
  text-decoration: underline;
}

.shared-file .file-details {
  min-width: 0;
}

.shared-file .file-type-icon {
  width: 35px;
  height: 40px;
}

.shared-file .file-name {
  font-size: 11px;
}

.shared-file .file-size {
  font-size: 9px;
  line-height: 1.6;
}

.files-empty {
  text-align: center;
  color: #63715f;
  font-size: 12px;
  line-height: 2;
  margin: 70px 0;
}

.files-footer {
  margin-top: auto;
  padding-top: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 10px;
  color: #63715f;
}

.files-footer svg {
  height: 12px;
  width: 12px;
}

.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  background: #254c3e;
  color: #fff;
  border-radius: 10px;
  padding: 13px 20px;
  font-size: 12px;
  z-index: 50;
  box-shadow: var(--shadow);
  max-width: calc(100vw - 40px);
  text-align: center;
  line-height: 1.6;
}

.mobile-only,.sidebar-backdrop {
  display: none;
}

@keyframes appear {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media(min-width:1600px) {
  .brand-story {
    padding-left: 12%;
    padding-right: 12%;
  }
  .story-art {
    max-width: 540px;
  }
  .auth-card {
    max-width: 390px;
  }
  .auth-side {
    padding-inline: 60px;
  }
  .auth-card h2 {
    font-size: 31px;
  }
  .field input {
    height: 50px;
  }
  .field {
    margin-bottom: 24px;
  }
  .sidebar {
    width: 268px;
  }
  .chat-header {
    padding-inline: 48px;
  }
  .messages-scroll {
    padding-inline: 58px;
  }
  .composer-section {
    padding-inline: 48px;
  }
  .message-bubble {
    font-size: 14px;
  }
}

@media(max-width:1100px) {
  .auth-view {
    grid-template-columns: 1fr 1fr;
  }
  .brand-story {
    padding: 32px 7%;
    min-height: 730px;
  }
  .story-content h1 {
    font-size: 42px;
  }
  .story-content .eyebrow {
    font-size: 8px;
    letter-spacing: 1.2px;
  }
  .story-foot {
    font-size: 9px;
    gap: 7px;
  }
  .story-foot svg {
    height: 14px;
    width: 14px;
  }
  .art-chat {
    width: 200px;
  }
  .art-file {
    max-width: 250px;
    padding: 14px;
    gap: 8px;
  }
  .story-art {
    height: 230px;
    margin-left: -2%;
  }
  .auth-side {
    padding: 32px 35px 23px;
  }
  .sidebar {
    width: 218px;
    padding-inline: 13px;
  }
  .sidebar .brand small {
    font-size: 9px;
  }
  .sidebar .brand {
    font-size: 21px;
  }
  .sidebar-caption {
    padding-inline: 10px;
  }
  .chat-header {
    padding-inline: 27px;
  }
  .messages-scroll {
    padding-inline: 26px;
  }
  .composer-section {
    padding-inline: 24px;
  }
  .file-limit {
    display: none;
  }
  .keyboard-hint {
    font-size: 8px;
  }
  .header-actions {
    gap: 9px;
  }
}

@media(max-width:800px) {
  .auth-view {
    grid-template-columns: 1fr;
  }
  .brand-story {
    min-height: auto;
    padding: 24px 32px 30px;
  }
  .brand-story .brand {
    font-size: 22px;
  }
  .story-content {
    padding: 25px 0 0;
  }
  .story-content .eyebrow {
    font-size: 8px;
  }
  .story-content h1 {
    font-size: 35px;
    margin: 14px 0 12px;
    line-height: 1.4;
  }
  .story-content h1 br {
    display: none;
  }
  .story-content>p {
    font-size: 12px;
  }
  .story-content>p br {
    display: none;
  }
  .story-art,.story-foot {
    display: none;
  }
  .auth-side {
    padding: 25px 32px 22px;
  }
  .auth-top-note,.auth-badge {
    display: none;
  }
  .auth-card {
    padding: 6px 0 23px;
    max-width: 440px;
  }
  .auth-card h2 {
    font-size: 23px;
  }
  .auth-subtitle {
    font-size: 12px;
    margin-bottom: 20px;
  }
  .auth-tabs {
    margin-bottom: 22px;
  }
  .field {
    margin-bottom: 17px;
  }
  .field input {
    height: 48px;
    font-size: 16px;
  }
  .field label {
    font-size: 12px;
  }
  .auth-footer {
    font-size: 9px;
  }
  .auth-tip {
    margin-top: 21px;
  }
  .sidebar {
    width: 195px;
    padding-inline: 10px;
  }
  .sidebar-brand-row {
    padding-inline: 6px;
  }
  .sidebar .brand {
    font-size: 20px;
    gap: 8px;
  }
  .sidebar .brand>span:last-child {
    display: block;
  }
  .sidebar .brand small {
    display: block;
    margin-top: 2px;
  }
  .sidebar-brand-row {
    margin-bottom: 35px;
  }
  .sidebar-caption span {
    font-size: 8px;
  }
  .chat-header {
    min-height: 88px;
    padding: 20px;
  }
  .chat-heading h1 {
    font-size: 17px;
  }
  .header-actions {
    gap: 4px;
  }
  .connection-status {
    font-size: 9px;
    padding: 5px 6px;
  }
  .space-banner {
    font-size: 9px;
    padding: 10px 12px;
  }
  .messages-scroll {
    padding-inline: 20px;
  }
  .composer-section {
    padding: 0 18px 14px;
  }
  .keyboard-hint {
    display: none;
  }
  .composer {
    padding: 12px;
  }
  .message-body {
    max-width: 83%;
  }
  .file-bubble {
    min-width: 210px;
  }
  .file-download {
    display: none;
  }
  .space-note {
    margin-inline: 7px;
  }
  .device-list {
    padding-inline: 9px;
  }
  .account {
    padding-inline: 5px;
    gap: 7px;
  }
  .account-avatar {
    height: 31px;
    width: 31px;
  }
  .account .icon-button {
    min-width: 44px;
  }
  .empty-state h2 {
    font-size: 22px;
  }
  .empty-tags {
    gap: 12px;
  }
  .empty-tags svg {
    width: 12px;
    height: 12px;
  }
}

@media(max-width:600px) {
  .workspace {
    height: 100dvh;
  }
  .mobile-only {
    display: inline-flex;
  }
  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: 267px;
    z-index: 30;
    transform: translateX(-100%);
    transition: transform .2s ease;
    box-shadow: 10px 0 40px #1a382b1a;
    visibility: hidden;
    padding: 24px 18px 0;
  }
  .workspace.sidebar-open .sidebar {
    transform: translateX(0);
    visibility: visible;
  }
  .sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 20;
    background: #213d2e4d;
    border: 0;
    padding: 0;
  }
  .sidebar-backdrop:not([hidden]) {
    display: block;
  }
  .sidebar .brand>span:last-child {
    display: flex;
  }
  .sidebar .brand small {
    display: inline;
    font-size: 11px;
  }
  .sidebar .brand {
    font-size: 23px;
  }
  .sidebar-brand-row {
    padding: 0 4px;
    margin-bottom: 36px;
  }
  .sidebar .close-sidebar {
    margin-right: -8px;
  }
  .sidebar-caption span {
    font-size: 9px;
  }
  .device-list {
    max-height: 29vh;
  }
  .sidebar .device-info strong {
    font-size: 12px;
  }
  .sidebar .device-info small {
    font-size: 10px;
  }
  .account {
    min-height: 87px;
  }
  .account-avatar {
    width: 35px;
    height: 35px;
  }
  .account strong {
    font-size: 13px;
  }
  .account>div>span {
    font-size: 11px;
  }
  .space-note strong {
    font-size: 12px;
  }
  .space-note p {
    font-size: 11px;
  }
  .sidebar .icon-button {
    min-width: 44px;
  }
  .chat-header {
    min-height: 79px;
    padding: 13px 12px 13px 6px;
    gap: 5px;
  }
  .chat-heading {
    flex: 1;
  }
  .chat-heading .eyebrow {
    font-size: 7px;
    letter-spacing: 1.1px;
    margin-bottom: 7px;
  }
  .chat-heading h1 {
    font-size: 16px;
    gap: 7px;
  }
  .heading-dot {
    display: none;
  }
  .header-actions {
    gap: 3px;
  }
  .connection-status {
    padding: 5px 6px;
    font-size: 9px;
    border-radius: 5px;
  }
  .header-actions .file-toggle {
    border: 0;
    background: none;
    min-width: 44px;
  }
  .space-banner {
    font-size: 9px;
    padding: 9px 9px;
    gap: 5px;
  }
  .space-banner svg {
    height: 12px;
    width: 12px;
  }
  .messages-scroll {
    padding: 8px 15px 14px;
  }
  .history-top {
    min-height: 24px;
    font-size: 10px;
  }
  .message {
    gap: 8px;
    margin-bottom: 20px;
  }
  .message-avatar {
    width: 28px;
    height: 28px;
    border-radius: 9px;
    font-size: 10px;
  }
  .message-body {
    max-width: calc(100% - 47px);
  }
  .message-bubble {
    font-size: 14px;
    padding: 10px 12px;
  }
  .message-meta {
    font-size: 10px;
    gap: 8px;
  }
  .message-device {
    max-width: 170px;
  }
  .file-bubble {
    min-width: 225px;
    gap: 10px;
    padding: 12px;
  }
  .file-name {
    font-size: 12px;
  }
  .file-size {
    font-size: 10px;
  }
  .file-type-icon {
    height: 42px;
    width: 35px;
  }
  .composer-section {
    padding: 0 11px calc(9px + env(safe-area-inset-bottom));
  }
  .composer {
    padding: 11px 12px 6px;
    border-radius: 12px;
  }
  .composer textarea {
    font-size: 16px;
    min-height: 53px;
    line-height: 1.7;
  }
  .composer-toolbar {
    padding-top: 0;
  }
  .attach-button {
    font-size: 11px;
  }
  .send-button {
    min-height: 44px;
    font-size: 12px;
    padding: 8px 13px;
  }
  .composer-footnote {
    font-size: 8px;
    margin-top: 8px;
  }
  .message-length {
    font-size: 9px;
  }
  .composer-error {
    font-size: 11px;
    gap: 2px;
  }
  .composer-error .text-button {
    font-size: 11px;
  }
  .empty-state {
    padding: 15px;
    justify-content: center;
  }
  .empty-illustration {
    margin-bottom: 10px;
    transform: scale(.9);
  }
  .empty-eyebrow {
    font-size: 7px;
    margin-bottom: 10px;
  }
  .empty-state h2 {
    font-size: 21px;
  }
  .empty-state p {
    font-size: 11px;
  }
  .empty-tags {
    font-size: 9px;
    margin-top: 21px;
  }
  .files-dialog {
    width: min(350px,94vw);
    padding: 25px 20px 20px;
  }
  .files-search input {
    font-size: 16px;
  }
  .new-messages {
    bottom: 185px;
    min-height: 44px;
  }
  .drop-overlay {
    inset: 8px;
  }
  .drop-overlay>strong {
    font-size: 20px;
  }
}

@media(max-width:380px) {
  .brand-story {
    padding: 22px 24px 25px;
  }
  .story-content h1 {
    font-size: 30px;
    letter-spacing: -1px;
  }
  .story-content .eyebrow {
    font-size: 7px;
  }
  .auth-side {
    padding-inline: 24px;
  }
  .field label span {
    font-size: 9px;
    margin-left: 3px;
  }
  .chat-heading h1 {
    font-size: 15px;
  }
  .header-actions .file-toggle {
    min-width: 44px;
  }
  .connection-status {
    font-size: 8px;
    padding: 5px;
  }
  .space-banner {
    font-size: 8px;
  }
  .empty-tags {
    gap: 10px;
  }
  .file-bubble {
    min-width: 210px;
  }
  .message-device {
    max-width: 140px;
  }
}

@media(max-height:700px) and (min-width:801px) {
  .brand-story {
    min-height: 680px;
  }
  .story-content {
    padding-top: 30px;
  }
  .story-art {
    height: 200px;
  }
  .auth-card {
    padding: 25px 0;
  }
  .auth-badge {
    margin-bottom: 15px;
  }
}

@media(max-height:650px) and (max-width:600px) {
  .empty-illustration {
    display: none;
  }
  .empty-tags {
    display: none;
  }
  .empty-state h2 {
    font-size: 19px;
  }
  .empty-eyebrow {
    margin-top: 0;
  }
  .sidebar-brand-row {
    margin-bottom: 24px;
  }
  .device-section {
    margin-top: 20px;
    padding-top: 20px;
  }
  .space-note {
    display: none;
  }
}

@media(prefers-reduced-motion:reduce) {
  *,*:before,*:after {
    animation: none!important;
    transition: none!important;
    scroll-behavior: auto!important;
  }
}

.auth-tabs.registration-closed {
  grid-template-columns: 1fr;
}

/* Account security: native dialog, contained scrolling, no external assets. */
.security-dialog {
  width: min(680px, calc(100vw - 40px));
  max-width: calc(100vw - 40px);
  max-height: min(850px, calc(100dvh - 48px));
  padding: 0;
  border: 1px solid #dce5d7;
  border-radius: 20px;
  color: var(--ink);
  background: var(--paper);
  box-shadow: 0 24px 100px #16382229;
  scrollbar-width: thin;
  scrollbar-color: #cddac7 transparent;
}

.security-dialog::backdrop {
  background: #1f392c66;
  backdrop-filter: blur(3px);
}

.security-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 27px 30px 23px;
  border-bottom: 1px solid var(--line);
  background: #f2f6ed;
}

.security-header > div {
  flex: 1;
  min-width: 0;
}

.security-header .eyebrow {
  font-size: 9px;
}

.security-header h2 {
  font-size: 24px;
  font-weight: 600;
  margin: 5px 0;
}

.security-header p {
  font-size: 12px;
  color: #63715f;
  margin: 0;
  overflow-wrap: anywhere;
}

.security-mark {
  width: 49px;
  height: 53px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: var(--teal);
  background: #e0ecdc;
  flex-shrink: 0;
}

#security-body {
  padding: 20px 30px 30px;
}

.security-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
  margin-bottom: 22px;
}

.security-tabs button {
  min-height: 44px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #63715f;
  font-size: 13px;
}

.security-tabs button[aria-selected="true"] {
  color: var(--teal-dark);
  background: #e6f0e5;
  font-weight: 600;
}

.security-panel h3, .recovery-panel h3 {
  margin: 0 0 9px;
  font-size: 18px;
  font-weight: 600;
}

.security-panel h4 {
  margin: 0 0 7px;
  font-size: 14px;
  font-weight: 600;
}

.security-description {
  margin: 0 0 23px;
  color: #63715f;
  font-size: 12px;
  line-height: 1.9;
}

.security-form .field {
  margin-bottom: 18px;
}

.security-form .field label, .totp-setup .field label {
  font-size: 12px;
}

.security-form .button {
  font-size: 12px;
}

.security-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.security-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 9px;
}

.security-section-title h3 {
  margin: 0;
}

.security-status {
  display: inline-block;
  color: #446746;
  background: #e7efdf;
  padding: 5px 9px;
  border-radius: 6px;
  font-size: 10px;
  white-space: nowrap;
}

.security-notice {
  padding: 12px 14px;
  border: 1px solid #dce8d3;
  border-radius: 9px;
  font-size: 12px;
  color: #586e4d;
  background: #f0f6e9;
  line-height: 1.8;
}

.security-feedback {
  position: sticky;
  top: 0;
  z-index: 1;
  margin: 0;
  padding: 12px 24px;
  color: #416242;
  background: #e7f1df;
  border-bottom: 1px solid #d6e4cd;
  font-size: 12px;
  line-height: 1.7;
}

.security-session-info p {
  white-space: pre-line;
}

.button-secondary {
  color: var(--teal-dark);
  background: white;
  border-color: #cbdcca;
}

.button-secondary:hover {
  background: #edf5e9;
}

.button-danger {
  color: #a43f36;
  background: #fff7f2;
  border-color: #ebd0c4;
}

.button-danger:hover {
  background: #f9e8df;
}

.security-copy-row, .security-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.security-copy-row input {
  min-width: 0;
  flex: 1;
}

.security-copy-row .button, .security-actions .button {
  font-size: 12px;
  white-space: nowrap;
}

.security-code {
  font-family: Consolas, "SFMono-Regular", monospace;
  letter-spacing: 1px;
}

.setup-step {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin: 25px 0 16px;
}

.setup-step > span {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e2eedc;
  color: var(--teal-dark);
  font-size: 11px;
  flex-shrink: 0;
}

.setup-step p {
  color: #63715f;
  font-size: 11px;
  line-height: 1.8;
  margin: 0;
}

.totp-uri-details {
  color: #63715f;
  font-size: 12px;
}

.totp-uri-details summary {
  cursor: pointer;
  padding: 14px 0;
  min-height: 44px;
}

.totp-uri-details textarea, .recovery-codes {
  display: block;
  width: 100%;
  resize: vertical;
  border: 1px solid #dce5d7;
  border-radius: 10px;
  background: white;
  color: var(--ink);
  padding: 13px;
  line-height: 1.8;
  font-size: 12px;
}

.security-small {
  font-size: 11px;
  margin: 15px 0 0;
}

.security-session-list {
  margin: 0 0 25px;
}

.security-session {
  display: flex;
  align-items: center;
  gap: 11px;
  border: 1px solid var(--line);
  background: white;
  border-radius: 11px;
  padding: 13px;
  margin-bottom: 9px;
}

.security-session > svg {
  width: 23px;
  color: #6a8061;
}

.security-session-info {
  flex: 1;
  min-width: 0;
}

.security-session-name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  line-height: 1.7;
  overflow-wrap: anywhere;
}

.security-session-info p {
  margin: 4px 0 0;
  color: #63715f;
  font-size: 10px;
  line-height: 1.8;
}

.security-session .text-button {
  color: #a43f36;
  flex-shrink: 0;
  padding-inline: 8px;
  font-size: 12px;
}

.revoke-others-form {
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.recovery-panel {
  padding: 28px 30px 32px;
}

.recovery-panel h3 {
  margin-top: 15px;
}

.recovery-codes {
  min-height: 236px;
  text-align: center;
  font-size: 14px;
}

.recovery-panel .security-actions {
  margin-top: 22px;
}

@media (max-width: 600px) {
  .security-dialog {
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
    max-height: calc(100dvh - 24px);
    border-radius: 15px;
  }
  .security-header {
    padding: 20px 18px 17px;
    gap: 11px;
  }
  .security-header h2 {
    font-size: 21px;
  }
  .security-header .eyebrow {
    font-size: 8px;
  }
  .security-mark {
    width: 41px;
    height: 46px;
  }
  #security-body {
    padding: 16px 18px 24px;
  }
  .security-field-row {
    display: block;
  }
  .security-tabs button {
    font-size: 12px;
  }
  .security-panel h3, .recovery-panel h3 {
    font-size: 17px;
  }
  .security-description {
    font-size: 12px;
  }
  .security-form .field input, .totp-setup .field input, .totp-uri-details textarea {
    font-size: 16px;
  }
  .security-copy-row {
    align-items: stretch;
    flex-direction: column;
  }
  .security-copy-row input {
    flex: auto;
  }
  .security-session {
    gap: 9px;
    padding: 11px;
  }
  .security-session-info p {
    font-size: 10px;
  }
  .recovery-panel {
    padding: 23px 18px 25px;
  }
  .recovery-panel .security-actions {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 420px) {
  .header-actions .connection-status span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }
  .header-actions .connection-status {
    padding: 7px;
    border-radius: 50%;
  }
}
