:root {
  color-scheme: dark;
  --ink: #080b09;
  --ink-soft: #0d110e;
  --panel: #111712;
  --panel-raised: #171e18;
  --panel-soft: #0d130f;
  --text: #f2f0e7;
  --muted: #aab1a8;
  --soft: #7f887f;
  --signal: #a7e879;
  --signal-bright: #c3f29f;
  --signal-deep: #416a35;
  --line: rgba(232, 239, 226, 0.13);
  --line-strong: rgba(167, 232, 121, 0.34);
  --danger: #ff9a8f;
  --success: #a7e879;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
  --radius-sm: 12px;
  --radius: 20px;
  --radius-lg: 30px;
  --shell: 1160px;
  --reading: 760px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--ink);
  color: var(--text);
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

body::before {
  position: fixed;
  z-index: -2;
  inset: 0;
  content: "";
  pointer-events: none;
  background-image:
    linear-gradient(rgba(167, 232, 121, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(167, 232, 121, 0.025) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(to bottom, black 0%, transparent 78%);
}

body::after {
  position: fixed;
  z-index: -1;
  top: -18rem;
  left: 50%;
  width: 54rem;
  height: 42rem;
  content: "";
  pointer-events: none;
  border: 1px solid rgba(167, 232, 121, 0.06);
  border-radius: 50%;
  transform: translateX(-50%);
  box-shadow: 0 0 160px rgba(75, 120, 58, 0.1);
}

img,
svg {
  display: block;
  max-width: 100%;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--signal-bright);
}

:focus-visible {
  outline: 3px solid var(--signal);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--signal);
  color: #091007;
  font-weight: 800;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-shell,
.hw-wrap {
  width: min(calc(100% - 32px), var(--shell));
  margin-inline: auto;
}

.hw-narrow {
  width: min(calc(100% - 32px), 760px);
  margin-inline: auto;
}

.site-header {
  position: relative;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(8, 11, 9, 0.9);
  backdrop-filter: blur(16px);
}

.site-header .site-shell,
.hw-nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.hw-logo,
.brand-name {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--text);
  font-size: 0.98rem;
  font-weight: 820;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.brand img,
.hw-logo img,
.brand-name img {
  width: 30px;
  height: 30px;
}

.site-nav,
.hw-navlinks,
.mini-links {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 650;
}

.site-nav a,
.hw-navlinks a,
.mini-links a {
  padding: 9px 11px;
  border-radius: 10px;
}

.site-nav a:hover,
.hw-navlinks a:hover,
.mini-links a:hover {
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
}

.eyebrow,
.hw-kicker,
.signal-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  color: var(--signal);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow::before,
.hw-kicker::before,
.signal-label::before {
  width: 7px;
  height: 7px;
  content: "";
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 18px rgba(167, 232, 121, 0.65);
}

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

h1,
h2,
h3 {
  color: var(--text);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

h1 {
  margin-bottom: 20px;
  font-size: clamp(2.55rem, 7vw, 5.8rem);
  font-weight: 760;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(1.65rem, 4vw, 2.75rem);
  font-weight: 720;
}

h3 {
  margin-bottom: 9px;
  font-size: 1.1rem;
  font-weight: 760;
  letter-spacing: -0.02em;
}

p {
  color: var(--muted);
}

.lead,
.lede {
  max-width: 680px;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  line-height: 1.7;
}

.hw-small,
.fine-print,
.note,
.meta {
  color: var(--soft);
  font-size: 0.88rem;
}

.hw-card,
.surface-card,
.panel,
.price-card,
.legal-card,
.signal-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(17, 23, 18, 0.94);
  box-shadow: var(--shadow);
}

.hw-card,
.surface-card,
.panel,
.legal-card {
  padding: clamp(22px, 4vw, 38px);
}

.hw-card.soft,
.panel.soft {
  background: var(--panel-soft);
  box-shadow: none;
}

.hw-btn,
.button,
button.hw-btn,
a.hw-btn,
.ghost,
.session-new,
#send {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-raised);
  color: var(--text);
  font-weight: 780;
  line-height: 1;
  text-align: center;
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.hw-btn:hover,
.button:hover,
.ghost:hover,
.session-new:hover {
  border-color: var(--line-strong);
  background: #1b251c;
  color: var(--text);
}

.hw-btn.primary,
.button-primary,
#send {
  border-color: var(--signal);
  background: var(--signal);
  color: #0a1008;
}

.hw-btn.primary:hover,
.button-primary:hover,
#send:hover {
  background: var(--signal-bright);
  color: #070c06;
  transform: translateY(-1px);
}

.hw-btn.secondary {
  border-color: var(--line-strong);
  background: rgba(167, 232, 121, 0.08);
}

.hw-btn.quiet,
.button-quiet,
.ghost {
  background: transparent;
  color: var(--muted);
}

.hw-btn.danger {
  border-color: rgba(255, 154, 143, 0.35);
  color: var(--danger);
}

.hw-btn:disabled,
.button:disabled,
button:disabled,
select:disabled,
textarea:disabled,
input:disabled {
  cursor: not-allowed;
  opacity: 0.48;
  transform: none;
}

.hw-actions,
.form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 11px;
  margin-top: 22px;
}

label {
  display: block;
  margin: 16px 0 7px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: none;
  background: #0c110d;
  color: var(--text);
}

input,
textarea {
  padding: 13px 14px;
}

select {
  min-height: 42px;
  padding: 0 34px 0 12px;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--signal);
  box-shadow: 0 0 0 4px rgba(167, 232, 121, 0.1);
}

.hw-msg,
.status,
#status,
.checkout-status {
  min-height: 0;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.9rem;
  white-space: pre-wrap;
}

.hw-msg:not(:empty),
.status:not(:empty),
.checkout-status:not(:empty) {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-soft);
}

.hw-msg.ok,
.status.ok {
  border-color: rgba(167, 232, 121, 0.45);
  color: var(--success);
}

.hw-msg.err,
.status.error,
.hw-msg[data-kind="err"] {
  border-color: rgba(255, 154, 143, 0.44);
  color: var(--danger);
}

.hw-center,
.auth-main {
  min-height: calc(100vh - 154px);
  display: grid;
  place-items: center;
  padding: 54px 0 74px;
}

.gate-main {
  min-height: calc(100vh - 76px);
  display: grid;
  place-items: center;
  padding: 54px 16px;
}

.gate-card {
  width: min(100%, 560px);
  padding: clamp(30px, 7vw, 58px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.gate-card h1 {
  font-size: clamp(2.3rem, 8vw, 4rem);
}

.gate-mark {
  width: 64px;
  margin-bottom: 30px;
}

.signal-line {
  margin: 28px 0 0;
  color: var(--text);
  font-weight: 700;
}

.form-note {
  margin: 20px 0 0;
  color: var(--soft);
  font-size: 0.86rem;
}

.form-note a {
  color: var(--signal);
}

.site-footer,
.hw-footer {
  border-top: 1px solid var(--line);
  color: var(--soft);
}

.site-footer .site-shell,
.hw-footer {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 0.84rem;
}

.site-footer nav {
  display: flex;
  gap: 18px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

/* Home */
.home-main {
  overflow: hidden;
}

.hero {
  min-height: min(820px, calc(100vh - 76px));
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  align-items: center;
  gap: clamp(40px, 8vw, 110px);
  padding: clamp(72px, 10vw, 130px) 0;
}

.hero h1 {
  max-width: 850px;
}

.hero-copy .lead {
  max-width: 620px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.signal-visual {
  position: relative;
  min-height: 430px;
  display: grid;
  place-items: center;
}

.signal-visual::before,
.signal-visual::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(167, 232, 121, 0.18);
  border-radius: 50%;
}

.signal-visual::before {
  width: 330px;
  height: 330px;
}

.signal-visual::after {
  width: 430px;
  height: 430px;
  border-color: rgba(167, 232, 121, 0.08);
}

.signal-visual img {
  position: relative;
  z-index: 2;
  width: min(52vw, 210px);
  filter: drop-shadow(0 24px 50px rgba(0, 0, 0, 0.5));
}

.signal-readout {
  position: absolute;
  z-index: 3;
  right: 0;
  bottom: 35px;
  width: min(260px, 74%);
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: rgba(10, 15, 11, 0.93);
  color: var(--muted);
  font-size: 0.82rem;
}

.signal-readout strong {
  display: block;
  margin-bottom: 5px;
  color: var(--signal);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section {
  padding: clamp(70px, 9vw, 120px) 0;
  border-top: 1px solid var(--line);
}

.section-heading {
  max-width: 720px;
  margin-bottom: 42px;
}

.principle-grid,
.use-grid,
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.principle-card,
.use-card {
  min-height: 210px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(13, 19, 15, 0.72);
}

.principle-number {
  display: block;
  margin-bottom: 34px;
  color: var(--signal);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.14em;
}

.statement {
  max-width: 930px;
  color: var(--text);
  font-size: clamp(2rem, 5.5vw, 4.7rem);
  font-weight: 710;
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.closing-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 36px;
  padding: clamp(28px, 6vw, 58px);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--panel-soft);
}

/* Interior and auth pages */
.page-main {
  min-height: calc(100vh - 168px);
  padding: clamp(54px, 8vw, 96px) 0;
}

.page-intro {
  max-width: 760px;
  margin-bottom: 36px;
}

.page-intro h1,
.auth-card h1 {
  font-size: clamp(2.3rem, 6vw, 4.4rem);
}

.auth-layout {
  width: min(calc(100% - 32px), 980px);
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(340px, 1.1fr);
  gap: 20px;
  margin-inline: auto;
}

.auth-context,
.auth-card {
  padding: clamp(26px, 5vw, 46px);
}

.auth-context {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.auth-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 24px 0;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--ink-soft);
}

.tab {
  min-height: 42px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-weight: 760;
}

.tab[data-active="1"] {
  background: var(--panel-raised);
  color: var(--text);
}

.signal-list {
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.signal-list li {
  position: relative;
  margin-top: 12px;
  padding-left: 22px;
  color: var(--muted);
}

.signal-list li::before {
  position: absolute;
  top: 0.62em;
  left: 0;
  width: 8px;
  height: 2px;
  content: "";
  background: var(--signal);
}

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
}

.form-row a,
.inline-link {
  color: var(--signal);
}

/* Pricing */
.pricing-grid {
  align-items: stretch;
}

.pricing-grid + .hw-card {
  margin-top: 16px;
}

.price-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 28px;
  box-shadow: none;
}

.price-card.featured {
  border-color: var(--signal-deep);
  background: #141d15;
}

.price-card .pill {
  align-self: flex-start;
  margin-bottom: 25px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--signal);
  font-size: 0.7rem;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.price {
  margin: 18px 0;
  color: var(--text);
  font-size: clamp(2.3rem, 5vw, 3.5rem);
  font-weight: 750;
  letter-spacing: -0.05em;
}

.price span {
  color: var(--soft);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0;
}

.price-card ul {
  flex: 1;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.price-card li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.055);
  color: var(--muted);
  font-size: 0.92rem;
}

/* Account */
.account-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.account-row {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel-soft);
}

.account-row .label {
  margin-bottom: 6px;
  color: var(--soft);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.account-row .value {
  color: var(--text);
  font-weight: 700;
  overflow-wrap: anywhere;
}

.plan-pill {
  display: inline-flex;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--signal);
  font-size: 0.78rem;
}

/* Legal */
.legal-shell {
  width: min(calc(100% - 32px), var(--reading));
  margin-inline: auto;
  padding: clamp(54px, 8vw, 96px) 0;
}

.legal-head {
  margin-bottom: 32px;
}

.legal-card h2 {
  margin-top: 38px;
  font-size: 1.35rem;
}

.legal-card h2:first-child {
  margin-top: 0;
}

.legal-card p,
.legal-card li {
  color: var(--muted);
}

.legal-card a {
  color: var(--signal);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-card ul {
  padding-left: 20px;
}

.updated {
  color: var(--soft);
  font-size: 0.82rem;
}

/* Contact */
#turnstileWidget {
  min-height: 68px;
  margin-top: 22px;
}

#contactMessage {
  min-height: 150px;
  resize: vertical;
}

/* Chat */
.chat-page {
  height: 100dvh;
  overflow: hidden;
}

.chat-shell {
  width: min(calc(100% - 24px), 1440px);
  height: 100dvh;
  display: flex;
  flex-direction: column;
  margin-inline: auto;
}

.chat-top {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--line);
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.tagline {
  color: var(--soft);
  font-size: 0.76rem;
  white-space: nowrap;
}

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

.controls select {
  width: auto;
}

.chat-layout {
  min-height: 0;
  flex: 1;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 14px;
  padding: 14px 0;
}

.sessions-panel {
  min-height: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.sessions-head {
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.sessions-title {
  margin-bottom: 11px;
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 800;
}

.session-new {
  width: 100%;
  min-height: 40px;
  font-size: 0.8rem;
}

.sessions-note {
  margin-top: 10px;
  color: var(--soft);
  font-size: 0.72rem;
  line-height: 1.45;
}

.sessions-list {
  max-height: calc(100dvh - 190px);
  overflow-y: auto;
  padding: 8px;
}

.session-wrap {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 32px;
  gap: 4px;
  margin-bottom: 4px;
}

.session-item,
.session-delete {
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
}

.session-item {
  min-width: 0;
  padding: 11px;
  text-align: left;
}

.session-item:hover,
.session-item.active {
  background: rgba(167, 232, 121, 0.08);
  color: var(--text);
}

.session-delete:hover {
  background: rgba(255, 154, 143, 0.1);
  color: var(--danger);
}

.session-title {
  overflow: hidden;
  font-size: 0.78rem;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.session-meta {
  margin-top: 3px;
  color: var(--soft);
  font-size: 0.68rem;
}

.chat-main {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.mobile-session-bar {
  display: none;
}

.box {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  padding: clamp(18px, 4vw, 44px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(13, 18, 14, 0.9);
  scroll-behavior: smooth;
}

.empty {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 20px;
}

.signal-check {
  width: min(100%, 760px);
}

.signal-check h1 {
  max-width: 700px;
  margin-bottom: 14px;
  font-size: clamp(2rem, 6vw, 4rem);
}

.signal-check p {
  max-width: 620px;
  margin-bottom: 24px;
}

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

.signal-prompt {
  min-height: 58px;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  color: var(--muted);
  text-align: left;
}

.signal-prompt:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.row {
  width: min(100%, 820px);
  display: flex;
  margin: 0 auto 16px;
}

.row.user {
  justify-content: flex-end;
}

.msg {
  max-width: min(82%, 680px);
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-raised);
  color: var(--text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.row.user .msg {
  border-color: rgba(167, 232, 121, 0.28);
  background: rgba(167, 232, 121, 0.1);
}

.bar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: end;
  gap: 10px;
  margin-top: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
}

.bar textarea {
  min-height: 48px;
  max-height: 150px;
  resize: vertical;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.bar input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.attach {
  min-width: 46px;
  min-height: 46px;
  display: inline-grid;
  place-items: center;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--muted);
}

.attach:hover {
  border-color: var(--line-strong);
  color: var(--signal);
}

.attach.disabled {
  cursor: not-allowed;
  opacity: 0.4;
}

.attach-text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.fileName {
  margin: 7px 4px 0;
  color: var(--soft);
  font-size: 0.76rem;
}

body.no-memory .sessions-panel,
body.no-memory .mobile-session-bar {
  display: none !important;
}

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

/* Responsive */
@media (max-width: 900px) {
  .hero,
  .auth-layout,
  .closing-panel {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .signal-visual {
    min-height: 360px;
  }

  .principle-grid,
  .use-grid,
  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .price-card {
    min-height: auto;
  }

  .tagline,
  .mini-links {
    display: none;
  }

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

  .sessions-panel {
    display: none;
  }

  .mobile-session-bar:not([hidden]) {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 7px;
    margin-bottom: 8px;
  }

  .mobile-session-bar .sessions-note {
    grid-column: 1 / -1;
  }
}

@media (max-width: 680px) {
  .site-shell,
  .hw-wrap,
  .hw-narrow,
  .legal-shell {
    width: min(calc(100% - 22px), var(--shell));
  }

  .site-header .site-shell,
  .hw-nav {
    min-height: 68px;
  }

  .site-nav a:not(.nav-primary),
  .hw-navlinks a:not(.nav-primary) {
    display: none;
  }

  h1 {
    font-size: clamp(2.35rem, 13vw, 3.8rem);
  }

  .hero {
    gap: 22px;
    padding: 64px 0 74px;
  }

  .signal-visual::before {
    width: 250px;
    height: 250px;
  }

  .signal-visual::after {
    width: 320px;
    height: 320px;
  }

  .signal-readout {
    right: 12px;
  }

  .auth-layout {
    width: min(calc(100% - 22px), 980px);
  }

  .auth-context {
    min-height: 240px;
  }

  .account-grid,
  .signal-prompts {
    grid-template-columns: 1fr;
  }

  .site-footer .site-shell,
  .hw-footer {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding: 24px 0;
  }

  .chat-shell {
    width: min(calc(100% - 12px), 1440px);
  }

  .chat-top {
    min-height: 64px;
  }

  .controls {
    gap: 5px;
  }

  .controls select {
    max-width: 92px;
  }

  .chat-layout {
    padding: 7px 0;
  }

  .box {
    padding: 18px 12px;
    border-radius: 15px;
  }

  .msg {
    max-width: 92%;
  }

  .bar {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 6px;
    padding: 7px;
  }

  #send {
    min-width: 60px;
    padding-inline: 12px;
  }
}

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