@font-face {
  font-family: "Cabinet Grotesk";
  src: url("fonts/cabinet-grotesk-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Cabinet Grotesk";
  src: url("fonts/cabinet-grotesk-800.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Geist Mono";
  src: url("fonts/geist-mono-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #134e4a;
  --ink-soft: #475569;
  --paper: #f0fdfa;
  --card: #ffffff;
  --line: rgba(19, 78, 74, 0.1);
  --accent: #0d9488;
  --accent-deep: #0f766e;
  --accent-soft: rgba(13, 148, 136, 0.12);
  --accent-glow: rgba(13, 148, 136, 0.35);
  --glass: rgba(255, 255, 255, 0.78);
  --glass-border: rgba(153, 246, 228, 0.45);
  --warn: #b45309;
  --warn-soft: rgba(180, 83, 9, 0.12);
  --danger: #9a3412;
  --danger-soft: rgba(154, 52, 18, 0.1);
  --ok: #0d9488;
  --ok-soft: rgba(13, 148, 136, 0.12);
  --console: #0f1715;
  --console-line: #1a2622;
  --space-panel: 1rem;
  --font-heading: "Cabinet Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "Geist Mono", "JetBrains Mono", ui-monospace, monospace;
  --font-display: var(--font-heading);
  --radius: 16px;
  --shadow: 0 1px 0 rgba(20, 32, 28, 0.04), 0 10px 28px rgba(20, 40, 34, 0.06);
  --shadow-lift: 0 1px 0 rgba(20, 32, 28, 0.05), 0 14px 32px rgba(20, 40, 34, 0.1);
  --layout-max-app: 1180px;
  --layout-max-doc: var(--layout-max-app);
  --layout-max-doc-terms: var(--layout-max-app);
  --layout-max-landing: var(--layout-max-app);
  --layout-max-auth: var(--layout-max-app);
  --layout-gutter: 1rem;
}

* { box-sizing: border-box; }

[hidden] {
  display: none !important;
}

html, body {
  margin: 0;
  height: 100%;
  color: var(--ink);
  font-family: var(--font-body);
  background:
    radial-gradient(920px 540px at 6% -10%, rgba(13, 148, 136, 0.11) 0%, transparent 58%),
    radial-gradient(680px 460px at 98% 4%, rgba(20, 184, 166, 0.09) 0%, transparent 52%),
    radial-gradient(480px 320px at 50% 100%, rgba(153, 246, 228, 0.25) 0%, transparent 55%),
    var(--paper);
}

body {
  min-height: 100vh;
  overflow: hidden;
}

body.app-shell {
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 20;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(19, 78, 74, 0.08);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.75) inset;
}

.app-header__inner {
  width: min(var(--layout-max-app), calc(100% - 2 * var(--layout-gutter)));
  margin: 0 auto;
  padding: 0.7rem 0;
  display: flex;
  align-items: center;
  gap: 0.75rem 1rem;
}

/* Guide + Terms: one shared content column (header + body) */
.doc-column {
  position: relative;
  z-index: 1;
  width: min(var(--layout-max-doc), calc(100% - 2 * var(--layout-gutter)));
  margin: 0 auto;
  padding-bottom: 3rem;
}

.landing-page--terms .doc-column {
  width: min(var(--layout-max-doc-terms), calc(100% - 2 * var(--layout-gutter)));
}

.landing-shell {
  position: relative;
  z-index: 1;
  width: min(var(--layout-max-landing), calc(100% - 2 * var(--layout-gutter)));
  margin: 0 auto;
  padding-bottom: 3.5rem;
}

.landing-page--home {
  overflow-x: hidden;
}

.orb-c {
  width: 320px;
  height: 320px;
  background: #2dd4bf;
  opacity: 0.14;
  right: 18%;
  top: 38%;
}

.app-header--landing {
  padding-top: 0.35rem;
}

.landing-stage--home {
  width: 100%;
  padding: 0.25rem 0 0;
  gap: clamp(1.25rem, 3vw, 2rem);
}

.app-header--doc {
  background: transparent;
  border-bottom: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  position: static;
}

.app-header--doc .app-header__inner {
  width: 100%;
  padding-left: 0;
  padding-right: 0;
}

.landing-stage--in-column {
  width: 100%;
  margin: 0;
  padding: 0.75rem 0 0;
}

.brand-lockup--link {
  text-decoration: none;
  color: inherit;
  flex-shrink: 0;
}

.brand-lockup--link:hover .brand-mark {
  color: var(--accent-deep);
}

.app-header .brand-mark {
  font-size: 1.12rem;
  line-height: 1;
}

.app-header .brand-icon {
  width: 1.95rem;
  height: 1.95rem;
  border-radius: 10px;
}

.app-nav {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  flex: 1 1 auto;
  min-width: 0;
  margin-left: 0.5rem;
}

.app-nav__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.25rem;
  padding: 0.4rem 0.75rem;
  border: 0;
  border-radius: 9px;
  background: transparent;
  font: 600 0.84rem/1.2 var(--font-body);
  color: var(--ink-soft);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.app-nav__link:hover {
  color: var(--ink);
  background: rgba(13, 148, 136, 0.07);
}

.app-nav__link.is-active {
  color: var(--accent-deep);
  background: var(--accent-soft);
}

.app-nav__link--button {
  font: inherit;
}

.app-nav__link--linked {
  color: var(--ok);
}

.app-nav__link--linked:hover {
  color: var(--ok);
  opacity: 0.88;
}

.app-nav__link--warn {
  color: var(--warn, #b45309);
}

.app-nav__link--warn:hover {
  color: var(--warn, #b45309);
  opacity: 0.88;
}

.app-header__end {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-left: auto;
  flex-shrink: 0;
}

/* Signed in: display name + log out only (nav links hidden; Desktop stays in header end) */
body.user-signed-in .brand-lockup,
body.user-signed-in .app-nav {
  display: none;
}

body.user-signed-in #desktopNavBtn:not([hidden]) {
  display: inline-flex;
}

body.user-signed-in.app-shell .page-intro {
  display: none;
}

body.user-signed-in .app-header__inner {
  flex-wrap: nowrap;
  gap: 0.5rem 0.75rem;
}

body.user-signed-in .user-chip:not([hidden]) {
  flex-shrink: 1;
  min-width: 0;
  max-width: min(18rem, 70vw);
}

.btn--compact {
  min-width: 0;
  padding: 0.48rem 0.95rem;
  font-size: 0.84rem;
}

.page-intro {
  padding-bottom: 0.1rem;
}

.page-title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 2.5vw, 1.45rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--ink);
}

.page-lead {
  margin: 0.35rem 0 0;
  max-width: 52ch;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--ink-soft);
}

.desktop-banner {
  margin: 0 0 1.25rem;
  padding: 0.75rem 1rem;
  border-radius: 0.65rem;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  background: color-mix(in srgb, var(--accent) 8%, var(--card));
  color: var(--ink);
  font-size: 0.88rem;
  line-height: 1.45;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
}

.desktop-banner__action {
  margin-left: auto;
}

.desktop-agent-config-status[data-tone="ok"] {
  color: var(--ok, #0d7a4a);
}

.desktop-agent-config-status[data-tone="error"] {
  color: var(--danger, #b42318);
}

.desktop-dialog {
  border: none;
  border-radius: 0.85rem;
  padding: 0;
  max-width: min(32rem, calc(100vw - 2rem));
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
  background: var(--card);
  color: var(--ink);
}

.desktop-dialog::backdrop {
  background: rgba(8, 10, 18, 0.55);
}

.desktop-dialog__panel {
  padding: 1.25rem 1.35rem 1.35rem;
  margin: 0;
}

.desktop-dialog--linked-only .desktop-dialog__panel {
  padding-bottom: 1.15rem;
}

.desktop-dialog__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.desktop-dialog__title {
  margin: 0;
  font-size: 1.15rem;
}

.desktop-dialog__close {
  font-size: 1.35rem;
  line-height: 1;
  padding: 0.15rem 0.45rem;
}

.desktop-dialog__lead {
  margin: 0.75rem 0 0;
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--ink-soft);
}

.desktop-dialog__status {
  margin-top: 0.75rem;
  font-size: 0.85rem;
}

.desktop-dialog__status[data-tone="ok"] {
  color: var(--ok, #0a7a3e);
}

.desktop-dialog__status[data-tone="error"] {
  color: var(--danger, #b42318);
}

.desktop-dialog__status[data-tone="warn"] {
  color: var(--warn, #b45309);
}

.desktop-dialog__actions {
  margin-top: 1rem;
}

.desktop-dialog__reveal {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
}

.desktop-dialog__reveal textarea {
  width: 100%;
  box-sizing: border-box;
  margin-top: 0.35rem;
  font-family: ui-monospace, monospace;
  font-size: 0.8rem;
  padding: 0.5rem 0.65rem;
  border-radius: 0.45rem;
  border: 1px solid color-mix(in srgb, var(--ink) 18%, transparent);
  background: var(--bg, #fff);
  color: var(--ink);
}

.desktop-dialog__list-wrap {
  margin-top: 1.25rem;
}

.desktop-dialog__subhead {
  margin: 0 0 0.35rem;
  font-size: 0.92rem;
}

.desktop-token-list {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.desktop-token-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.75rem;
  padding: 0.55rem 0.65rem;
  border-radius: 0.5rem;
  border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
  font-size: 0.85rem;
}

.desktop-token-item__label {
  font-weight: 600;
}

.desktop-token-item__meta {
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.desktop-token-item .text-btn {
  margin-left: auto;
}

.desktop-onboarding__field {
  margin: 0 0 1rem;
}

.desktop-onboarding__field input {
  width: 100%;
}

body.desktop-onboarding-blocked .stage--app {
  pointer-events: none;
  user-select: none;
  filter: saturate(0.88) brightness(0.96);
}

.desktop-onboarding::backdrop {
  background: color-mix(in srgb, var(--ink) 55%, transparent);
}

.desktop-onboarding__head {
  align-items: flex-start;
}

.desktop-onboarding__steps {
  margin: 0.35rem 0 0;
  display: flex;
  gap: 0.75rem;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.desktop-onboarding__step.is-active {
  color: var(--accent);
  font-weight: 600;
}

.desktop-onboarding__step.is-done {
  color: var(--ink);
}

.desktop-banner[hidden] {
  display: none !important;
}

.noise {
  pointer-events: none;
  position: fixed;
  inset: 0;
  opacity: 0.18;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.45'/%3E%3C/svg%3E");
  z-index: 0;
}

.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(48px);
  opacity: 0.22;
  z-index: 0;
}

.orb-a {
  width: 260px;
  height: 260px;
  background: #5eead4;
  top: -40px;
  left: -100px;
}

.orb-b {
  width: 280px;
  height: 280px;
  background: #99f6e4;
  right: -110px;
  bottom: 8%;
}

.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;
}

.stage {
  position: relative;
  z-index: 1;
  width: min(var(--layout-max-app), calc(100% - 2 * var(--layout-gutter)));
  height: 100vh;
  margin: 0 auto;
  padding: 1.1rem 0 1.1rem;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.9rem;
  overflow: hidden;
}

body.app-shell .stage--app {
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
  width: min(var(--layout-max-app), calc(100% - 2 * var(--layout-gutter)));
  padding: 0.85rem 0 1rem;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 0.75rem;
}

.brand-glass {
  padding: 0.65rem 1rem;
  border-radius: calc(var(--radius) + 4px);
  background: var(--glass);
  border: 1px solid var(--glass-border);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.85) inset, var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .brand-glass,
  .auth-card--glass {
    background: var(--card);
  }
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 12px;
  color: var(--accent-deep);
  background: linear-gradient(145deg, rgba(153, 246, 228, 0.55), rgba(13, 148, 136, 0.18));
  border: 1px solid rgba(13, 148, 136, 0.22);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset;
}

.brand-icon--lg {
  width: 3rem;
  height: 3rem;
  border-radius: 14px;
}

.brand {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1rem;
}

.brand-copy {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.65rem 1rem;
  min-width: 0;
}

.brand-user {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-left: auto;
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  max-width: min(18rem, 42vw);
  padding: 0.22rem 0.55rem 0.22rem 0.28rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--line);
}

.user-avatar {
  flex: 0 0 auto;
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #f0fdfa;
  background: linear-gradient(145deg, var(--accent), var(--accent-deep));
}

.user-chip--name-only {
  padding: 0.28rem 0.65rem;
}

.user-chip--name-only .user-avatar {
  display: none;
}

.linkedin-connected {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem 0.65rem;
}

.linkedin-connected-name {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
  word-break: break-word;
}

#linkedinField.is-connected .linkedin-form {
  display: none;
}

.user-email {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-soft);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand-mark {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: clamp(1.65rem, 3.4vw, 2.05rem);
  letter-spacing: -0.05em;
  line-height: 1;
  color: var(--ink);
}

.brand-line {
  margin: 0;
  font-size: 0.92rem;
  color: var(--ink-soft);
  font-weight: 500;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 300px);
  gap: 1rem;
  align-items: stretch;
  min-height: 0;
  height: 100%;
}

.panel {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}

.panel-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-panel);
  padding-right: 2px;
}

.card,
.actions-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.15rem 1.2rem 1.2rem;
  display: grid;
  gap: 0.7rem;
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.pace-choice:hover {
  border-color: rgba(13, 148, 136, 0.32);
  box-shadow: var(--shadow-lift);
  transform: translateY(-1px);
}

.card:focus-within {
  border-color: rgba(13, 148, 136, 0.32);
  box-shadow: 0 0 0 1px rgba(13, 148, 136, 0.12), var(--shadow);
}

.actions-card {
  box-shadow: var(--shadow-lift);
}

.field {
  display: grid;
  gap: 0.55rem;
}

.field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.field-tools {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.45rem;
}

.card > .field-head > label,
.card > .field-head > .field-label {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--ink);
}

.input-label {
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
}

.meta {
  font-size: 0.75rem;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.meta.tip { opacity: 0.85; }

.insert-name-chip {
  display: none;
}

.count-pill {
  min-width: auto;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
}

.field-hint {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--ink-soft);
}

.pace-choices {
  display: grid;
  gap: 0.45rem;
}

.pace-choice {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.65rem;
  align-items: start;
  margin: 0;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
}

.pace-choice:has(input:checked) {
  border-color: rgba(13, 148, 136, 0.45);
  background: var(--accent-soft);
  box-shadow: 0 0 0 1px rgba(13, 148, 136, 0.15);
}

.pace-choice input {
  margin-top: 0.2rem;
  accent-color: var(--accent);
}

.pace-choice strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
}

.pace-choice span span {
  display: block;
  margin-top: 0.12rem;
  font-size: 0.75rem;
  line-height: 1.35;
  color: var(--ink-soft);
}

.pace-choice:has(input:disabled) {
  cursor: default;
  opacity: 0.72;
}

.text-btn,
.pace-choice,
.btn,
.icon-btn,
a.btn {
  cursor: pointer;
}

.text-btn {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.32rem 0.7rem;
  background: #fff;
  color: var(--accent-deep);
  font: 600 0.75rem/1.2 var(--font-body);
  letter-spacing: 0;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

a.text-btn {
  color: var(--accent-deep);
  display: inline-flex;
  align-items: center;
}

.text-btn:hover {
  background: var(--accent-soft);
  border-color: rgba(13, 148, 136, 0.28);
  color: var(--accent);
}

.text-btn:focus-visible,
.icon-btn:focus-visible,
.btn:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.text-btn:disabled,
.icon-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.field.drop-ready textarea,
.card.drop-ready textarea {
  border-color: rgba(13, 148, 136, 0.55);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.field.drop-ready .attach-row,
.card.drop-ready .attach-row {
  border-radius: 12px;
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.upload-progress {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 0.7rem;
}

.upload-progress[hidden] {
  display: none !important;
}

.progress-track {
  height: 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: var(--accent);
  transition: width 0.16s ease;
}

.progress-label {
  min-width: 3.2ch;
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  color: var(--ink-soft);
}

textarea,
input[type="text"],
input[type="password"],
input[type="email"],
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcfb;
  color: var(--ink);
  font: 500 0.92rem/1.45 var(--font-body);
  padding: 0.7rem 0.85rem;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

textarea:hover,
input[type="text"]:hover,
input[type="password"]:hover,
input[type="email"]:hover {
  border-color: rgba(20, 32, 28, 0.18);
}

textarea:focus,
input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus {
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 3px var(--accent-soft);
}

textarea:disabled,
input:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  background: #eef1ef;
}

.cred-grid {
  display: grid;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .cred-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.password-wrap {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcfb;
  padding-right: 0.35rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.password-wrap:hover {
  border-color: rgba(20, 32, 28, 0.18);
}

.password-wrap:focus-within {
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.password-wrap input[type="password"],
.password-wrap input[type="text"] {
  border: 0;
  background: transparent;
  box-shadow: none;
  flex: 1 1 auto;
  min-width: 0;
  padding-right: 0.3rem;
}

.password-wrap input:focus {
  box-shadow: none;
  outline: none;
}

.icon-btn {
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink-soft);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.icon-btn:hover {
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.icon-btn .icon-eye-off { display: none; }
.icon-btn[aria-pressed="true"] .icon-eye { display: none; }
.icon-btn[aria-pressed="true"] .icon-eye-off { display: block; }

#names,
#message {
  background: #eef1ef;
}

#names {
  min-height: 168px;
  resize: vertical;
  font-family: var(--font-mono);
  font-size: 0.84rem;
  line-height: 1.55;
}

.names-preview {
  margin-top: 0.75rem;
  padding: 0.65rem 0.75rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.names-preview[hidden] {
  display: none !important;
}

.names-preview-label {
  margin: 0 0 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink-soft);
  letter-spacing: 0.02em;
}

.names-preview-scroll {
  max-height: 220px;
  overflow: auto;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.names-preview-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
  line-height: 1.45;
}

.names-preview-table th,
.names-preview-table td {
  padding: 0.45rem 0.65rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}

.names-preview-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  background: #eef1ef;
}

.names-preview-table tbody tr:last-child td {
  border-bottom: none;
}

.names-preview-table td:last-child {
  color: var(--ink);
}

.names-preview-table td:first-child {
  font-weight: 600;
  color: var(--ink);
  width: 42%;
}

#message {
  min-height: 140px;
  resize: vertical;
}

#names:focus,
#message:focus {
  background: #f7f8f7;
}

.attach-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.attach-name {
  flex: 1 1 8rem;
  min-width: 0;
  font-size: 0.86rem;
  color: var(--ink-soft);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.attach-name.has-file {
  color: var(--ink);
  font-weight: 600;
}

.actions-card {
  flex: 0 0 auto;
  margin-top: 0;
  z-index: 2;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  justify-content: flex-end;
}

.btn {
  position: relative;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 0.68rem 1.1rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, opacity 0.15s ease, color 0.15s ease;
}

.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

.btn.ghost {
  background: #fff;
  border-color: var(--line);
  color: var(--ink);
}

.btn.ghost:hover {
  background: #f3f6f4;
  border-color: rgba(20, 32, 28, 0.18);
}

.btn.primary {
  background: linear-gradient(165deg, #14b8a6 0%, var(--accent) 45%, var(--accent-deep) 100%);
  color: #f0fdfa;
  min-width: 10rem;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.25) inset, 0 8px 20px var(--accent-glow);
}

.btn.primary:hover {
  background: linear-gradient(165deg, #0d9488 0%, var(--accent-deep) 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.2) inset, 0 10px 24px rgba(13, 148, 136, 0.38);
}

.btn-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 35%,
    rgba(255, 255, 255, 0.35) 50%,
    transparent 65%
  );
  transform: translateX(-120%);
  animation: btn-shine 4.5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes btn-shine {
  0%, 72% { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}

.btn.danger {
  background: var(--danger-soft);
  border-color: rgba(154, 52, 18, 0.22);
  color: var(--danger);
}

.btn.danger:hover { background: #fde8e0; }

.status {
  display: none;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 0;
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--ink-soft);
  background: #f3f5f4;
}

.status:not(:empty) {
  display: flex;
}

.status-icon {
  flex: 0 0 1.1rem;
  width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.08rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.status-icon svg {
  width: 1.05rem;
  height: 1.05rem;
}

.status.ok {
  color: var(--accent-deep);
  background: var(--ok-soft);
}

.status.stopped {
  color: #9a4d0a;
  background: var(--warn-soft);
}

.status.error {
  color: var(--danger);
  background: var(--danger-soft);
}

.status.running {
  color: var(--accent-deep);
  background: var(--accent-soft);
}

.log-panel {
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 0;
  height: 100%;
  max-height: 100%;
  overflow: hidden;
  background: var(--console);
  border: 1px solid #1c2a24;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(15, 23, 21, 0.12);
}

.log-body {
  position: relative;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.log-empty {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  padding: 1.25rem;
  text-align: center;
  color: #6b857c;
  pointer-events: none;
}

.log-empty svg {
  opacity: 0.45;
}

.log-empty-title {
  margin: 0.45rem 0 0;
  font-size: 0.86rem;
  font-weight: 600;
  color: #8aa99f;
}

.log-empty-hint {
  margin: 0;
  font-size: 0.76rem;
  line-height: 1.45;
  max-width: 20ch;
  color: #5f756d;
}

.log-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: #0d1512;
}

.log-head-left {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.window-dots {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-right: 0.15rem;
}

.window-dot {
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 999px;
  opacity: 0.92;
}

.window-dot--close { background: #ff5f57; }
.window-dot--min { background: #febc2e; }
.window-dot--max { background: #28c840; }

.log-title {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #c5d4cc;
}

.log-follow {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6b7c74;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.log-panel:has(#pulse[data-state="running"]) .log-follow {
  opacity: 1;
  color: #8fd4bf;
}

.pulse {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #5c6b64;
}

.pulse[data-state="running"] {
  background: var(--accent);
  animation: beat 1.2s ease-out infinite;
}

.pulse[data-state="done"] { background: #5ee0b5; }
.pulse[data-state="stopped"] { background: #e0b15a; }
.pulse[data-state="error"] { background: #f0a07a; }

@keyframes beat {
  0% { box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.45); }
  70% { box-shadow: 0 0 0 8px rgba(13, 148, 136, 0); }
  100% { box-shadow: 0 0 0 0 rgba(13, 148, 136, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .btn-shine,
  .pulse[data-state="running"],
  .pace-choice,
  .btn,
  .text-btn,
  .card,
  .progress-fill {
    animation: none !important;
    transition-duration: 0.01ms !important;
  }

  .pace-choice:hover {
    transform: none;
  }

  .landing-preview__frame {
    transform: none;
  }
}

.log {
  position: relative;
  z-index: 2;
  margin: 0;
  padding: 0.9rem 1rem 1.15rem;
  overflow-y: auto;
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  max-height: none;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.65;
  color: #7d9a92;
  white-space: pre-wrap;
  word-break: break-word;
  background: var(--console);
}

.log-line {
  display: block;
  color: #7d9a92;
}

.log-line--info { color: #e0b15a; }
.log-line--ok { color: #7dccb0; }
.log-line--err { color: #ef7a6a; }
.log-line--warn { color: #e89a4a; }

@media (max-width: 880px) {
  body.app-shell {
    height: auto;
    min-height: 100vh;
    overflow: auto;
  }

  body {
    height: auto;
    overflow: auto;
  }

  .stage,
  body.app-shell .stage--app {
    height: auto;
    max-height: none;
    overflow: visible;
    grid-template-rows: auto auto auto;
  }

  .workspace {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 0;
  }

  .panel {
    height: auto;
    overflow: visible;
  }

  .panel-scroll {
    overflow: visible;
  }

  .actions-card {
    position: sticky;
    bottom: 0;
  }

  .log-panel {
    height: min(42vh, 360px);
    min-height: 240px;
  }

  .app-header__inner {
    flex-wrap: wrap;
  }

  body.user-signed-in .app-header__inner {
    flex-wrap: nowrap;
  }

  .app-nav {
    order: 3;
    flex: 1 1 100%;
    margin-left: 0;
    padding-top: 0.15rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .actions {
    justify-content: stretch;
  }

  .btn {
    flex: 1 1 auto;
    text-align: center;
  }
}

.auth-page {
  overflow: auto;
  height: auto;
  min-height: 100vh;
}

.auth-shell {
  position: relative;
  z-index: 1;
  width: min(var(--layout-max-auth), calc(100% - 2 * var(--layout-gutter)));
  margin: 0 auto;
  padding: clamp(1.5rem, 4vh, 2.75rem) 0 3rem;
  display: grid;
  gap: 1.75rem;
  align-items: center;
  min-height: calc(100vh - 3.5rem);
}

@media (min-width: 840px) {
  .auth-shell {
    grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
    gap: clamp(2rem, 5vw, 3.5rem);
  }
}

.auth-panel-title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.85rem, 4.5vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.08;
  color: var(--ink);
}

.auth-panel-lead {
  margin: 0.85rem 0 0;
  max-width: 42ch;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink-soft);
}

.auth-trust {
  list-style: none;
  margin: 1.35rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.auth-trust li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.65rem;
  align-items: start;
  font-size: 0.9rem;
  line-height: 1.45;
  color: #3d5249;
}

.auth-trust svg {
  flex-shrink: 0;
  margin-top: 0.1rem;
  color: var(--accent);
}

.auth-panel-foot {
  margin: 1.35rem 0 0;
  font-size: 0.88rem;
  color: var(--ink-soft);
}

.auth-panel-foot a {
  color: var(--accent-deep);
  font-weight: 600;
  text-decoration: none;
}

.auth-panel-foot a:hover {
  text-decoration: underline;
}

.auth-form-wrap {
  width: 100%;
}

.auth-card {
  padding: 1.35rem 1.35rem 1.4rem;
  gap: 0.85rem;
  box-shadow: var(--shadow-lift);
}

.auth-card .field {
  gap: 0.42rem;
}

.auth-card-head {
  display: grid;
  gap: 0.25rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 0.15rem;
}

.auth-card-title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.auth-card-sub {
  margin: 0;
  font-size: 0.84rem;
  color: var(--ink-soft);
}

.input-wrap {
  display: flex;
  align-items: stretch;
  min-height: 3rem;
  border: 1px solid rgba(19, 78, 74, 0.14);
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f6fbfb 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 1px 2px rgba(19, 78, 74, 0.05);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease;
}

.input-wrap:hover {
  border-color: rgba(13, 148, 136, 0.26);
  background: #fff;
}

.input-wrap:focus-within {
  border-color: rgba(13, 148, 136, 0.55);
  background: #fff;
  box-shadow:
    0 0 0 3px var(--accent-soft),
    inset 0 0 0 1px rgba(13, 148, 136, 0.1);
}

.input-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 2.75rem;
  align-self: center;
  margin: 0.35rem 0;
  padding-right: 0.05rem;
  border-right: 1px solid rgba(19, 78, 74, 0.08);
  color: rgba(71, 85, 105, 0.72);
  transition: color 0.18s ease, border-color 0.18s ease;
}

.input-wrap:focus-within .input-icon {
  color: var(--accent-deep);
  border-color: rgba(13, 148, 136, 0.18);
}

.input-wrap input {
  flex: 1 1 auto;
  min-width: 0;
  width: auto;
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0.72rem 0.85rem 0.72rem 0.65rem;
  font: 500 0.9375rem/1.45 var(--font-body);
  color: var(--ink);
}

.input-wrap input::placeholder {
  color: rgba(71, 85, 105, 0.5);
  font-weight: 400;
}

.input-wrap input:focus {
  box-shadow: none;
  outline: none;
}

.input-wrap--password {
  padding-right: 0.2rem;
}

.input-wrap .input-reveal {
  align-self: center;
  flex-shrink: 0;
  margin: 0.3rem 0.35rem 0.3rem 0.15rem;
}

.auth-submit {
  width: 100%;
  margin-top: 0.25rem;
}

.auth-stage {
  position: relative;
  z-index: 1;
  width: min(420px, calc(100% - 2rem));
  margin: 12vh auto 3rem;
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.auth-tagline {
  margin-top: 0.55rem;
}

.auth-card--glass {
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-color: var(--glass-border);
  box-shadow: var(--shadow-lift);
}

.auth-card .btn.primary {
  width: 100%;
}

.admin-stage {
  height: auto;
  max-height: none;
  overflow: visible;
}

body.app-shell .admin-stage.stage--app {
  grid-template-rows: auto auto;
  overflow: auto;
}

.admin-grid {
  display: grid;
  gap: 1rem;
  min-height: 0;
}

@media (min-width: 900px) {
  .admin-grid {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .admin-grid .card:nth-child(3),
  .admin-grid .admin-users-card {
    grid-column: 1 / -1;
  }

  .admin-grid .card:nth-child(2) .admin-form {
    max-width: 26rem;
  }
}

.admin-users-card {
  overflow: hidden;
}

.admin-form {
  display: grid;
  gap: 0.7rem;
}

.admin-form select,
.admin-form textarea,
.admin-form input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  font: 500 0.95rem/1.3 var(--font-body);
  color: var(--ink);
  background: #fff;
}

.admin-form textarea {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 0.82rem;
  min-height: 8rem;
  resize: vertical;
}

.queue-list {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.admin-table th,
.admin-table td {
  text-align: left;
  padding: 0.55rem 0.4rem;
  border-bottom: 1px solid var(--line);
}

.admin-table th {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.admin-table td:last-child {
  white-space: nowrap;
}

.admin-table td:last-child .text-btn + .text-btn {
  margin-left: 0.75rem;
}

.landing-stage {
  position: relative;
  z-index: 1;
  width: min(var(--layout-max-doc), calc(100% - 2 * var(--layout-gutter)));
  margin: 0 auto;
  padding: 1rem 0 3.5rem;
  display: grid;
  gap: 1.15rem;
}

.landing-page--terms .terms-table {
  font-size: 0.9rem;
}

.landing-page--terms .terms-table th,
.landing-page--terms .terms-table td {
  padding: 0.55rem 0.5rem;
}

.landing-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.landing-bar-glass {
  padding: 0.65rem 1rem;
  border-radius: calc(var(--radius) + 4px);
}

.landing-bar .btn.primary {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 0.5rem 0.95rem;
}

.landing-hero .landing-kicker {
  margin: 0 0 0.7rem;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.landing-hero h1,
.step h2,
.landing-note h2 {
  margin: 0;
  font-family: var(--font-heading);
  letter-spacing: -0.03em;
  color: var(--ink);
}

.landing-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.1rem, 5vw, 2.85rem);
  font-weight: 700;
  line-height: 1.05;
}

.landing-hero--epic {
  display: grid;
  gap: clamp(1.75rem, 4vw, 2.75rem);
  padding: clamp(0.5rem, 2vw, 1.25rem) 0 clamp(1rem, 3vw, 1.75rem);
  align-items: center;
}

@media (min-width: 920px) {
  .landing-hero--epic {
    grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
    gap: clamp(2rem, 4vw, 3.25rem);
  }
}

.landing-hero--epic h1 {
  font-size: clamp(2.35rem, 4.2vw, 3.35rem);
  letter-spacing: -0.045em;
  max-width: 14ch;
}

.landing-gradient-text {
  background: linear-gradient(120deg, var(--accent-deep), #14b8a6 55%, #0ea5e9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.landing-hero-lead {
  margin: 1.1rem 0 0;
  max-width: 48ch;
  font-size: clamp(1rem, 1.8vw, 1.08rem);
  line-height: 1.65;
  color: var(--ink-soft);
}

.landing-hero-lead code {
  padding: 0.1em 0.4em;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-family: var(--font-mono);
  font-size: 0.92em;
}

.landing-hero-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
  margin-top: 1.45rem;
}

.landing-hero-btn {
  min-width: 11rem;
}

.landing-hero-note {
  margin: 0.85rem 0 0;
  font-size: 0.82rem;
  color: var(--ink-soft);
}

.landing-preview__frame {
  border-radius: calc(var(--radius) + 6px);
  border: 1px solid rgba(19, 78, 74, 0.12);
  background: linear-gradient(165deg, #fff 0%, #f0fdfa 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 24px 60px rgba(13, 148, 136, 0.14),
    var(--shadow-lift);
  overflow: hidden;
  transform: perspective(1200px) rotateY(-4deg) rotateX(2deg);
  transform-origin: center right;
}

@media (max-width: 919px) {
  .landing-preview__frame {
    transform: none;
    max-width: 28rem;
    margin: 0 auto;
  }
}

.landing-preview__chrome {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 0.85rem;
  background: #ecfdf5;
  border-bottom: 1px solid rgba(19, 78, 74, 0.08);
}

.landing-preview__title {
  margin-left: 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.landing-preview__body {
  padding: 0.85rem;
  display: grid;
  gap: 0.65rem;
}

.preview-card {
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0.65rem 0.75rem;
  display: grid;
  gap: 0.45rem;
}

.preview-card--wide {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.preview-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.preview-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.preview-lines {
  grid-column: 1 / -1;
  display: grid;
  gap: 0.35rem;
}

.preview-lines span {
  height: 0.45rem;
  border-radius: 999px;
  background: #e2e8e6;
}

.preview-lines span:nth-child(2) { width: 88%; }
.preview-lines span:nth-child(3) { width: 72%; }

.preview-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.preview-msg {
  margin: 0;
  font-size: 0.78rem;
  color: var(--ink-soft);
  line-height: 1.45;
}

.preview-msg em {
  font-style: normal;
  font-weight: 700;
  color: var(--accent-deep);
}

.preview-card--log {
  background: #0f1715;
  border-color: #1c2a24;
}

.preview-card--log .preview-label {
  color: #8aa99f;
}

.preview-log {
  display: grid;
  gap: 0.28rem;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  line-height: 1.4;
}

.landing-highlights {
  display: grid;
  gap: 0.85rem;
}

@media (min-width: 768px) {
  .landing-highlights {
    grid-template-columns: repeat(3, 1fr);
  }
}

.highlight-card {
  padding: 1.1rem 1.15rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
}

.highlight-card h2 {
  margin: 0.55rem 0 0;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.highlight-card h2 code {
  font-family: var(--font-mono);
  font-size: 0.92em;
}

.highlight-card p {
  margin: 0.45rem 0 0;
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--ink-soft);
}

.highlight-card p a {
  color: var(--accent-deep);
  font-weight: 600;
}

.highlight-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 11px;
  color: var(--accent-deep);
  background: var(--accent-soft);
}

.landing-section-head {
  text-align: center;
  max-width: 40rem;
  margin: 0.5rem auto 0;
}

.landing-section-title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  letter-spacing: -0.03em;
  color: var(--ink);
}

.landing-section-lead {
  margin: 0.55rem 0 0;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

.landing-rule--center {
  max-width: 52rem;
  margin-left: auto;
  margin-right: auto;
}

.steps--bento {
  gap: 0.85rem;
}

@media (min-width: 768px) {
  .steps--bento {
    grid-template-columns: 1fr 1fr;
  }

  .steps--bento .step--span {
    grid-column: 1 / -1;
  }
}

.landing-note--wide p {
  max-width: none;
}

.landing-cta--band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.25rem;
  padding: 1.25rem 1.35rem;
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid rgba(13, 148, 136, 0.22);
  background: linear-gradient(135deg, rgba(153, 246, 228, 0.35), rgba(255, 255, 255, 0.95));
  box-shadow: var(--shadow);
}

.landing-cta--band h2 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.landing-cta--band p {
  margin: 0.35rem 0 0;
  font-size: 0.88rem;
  color: var(--ink-soft);
}

.landing-cta__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
}

.landing-hero > p,
.step p,
.landing-note p {
  max-width: 68ch;
  margin: 1rem 0 0;
  color: #3d5249;
  font-size: 1rem;
  line-height: 1.6;
}

.landing-hero .landing-rule {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  max-width: 68ch;
  margin-top: 1.45rem;
  padding: 0.9rem 1rem;
  border: 1px solid #6faf98;
  border-radius: 10px;
  background: #b7dccb;
  color: #0b3d30;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.6;
}

.landing-rule-icon {
  flex: 0 0 auto;
  width: 1.15rem;
  height: 1.15rem;
  margin-top: 0.22rem;
}

.landing-page .card:hover {
  transform: none;
  box-shadow: var(--shadow);
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.15rem;
}

.step {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  column-gap: 0.9rem;
  padding: 1.15rem 1.2rem 1.2rem;
  border-left: 0;
  box-shadow: var(--shadow);
}

.step h2,
.landing-note h2 {
  font-family: var(--font-heading);
  font-size: 1.28rem;
  font-weight: 700;
  line-height: 1.25;
}

.step p {
  margin-top: 0.6rem;
}

.landing-note p {
  margin-top: 0;
}

.landing-note p + p {
  margin-top: 0.75rem;
}

.step-num {
  width: 1.85rem;
  height: 1.85rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: baseline;
  background: var(--accent);
  color: #f4fffb;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1;
}

.landing-note {
  background: #fff;
  gap: 0.6rem;
  padding: 1.3rem 1.3rem 1.35rem;
}

.step code {
  display: inline-block;
  margin: 0 0.15em;
  padding: 0.08em 0.42em;
  border-radius: 6px;
  background: #d7efe6;
  color: #0b3d30;
  font-family: var(--font-mono);
  font-size: 0.86em;
  font-weight: 500;
  line-height: 1.45;
  vertical-align: baseline;
}

.landing-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.7rem;
}

.landing-cta .btn.primary {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.terms-table-wrap {
  overflow-x: auto;
  margin-top: 0.85rem;
}

.terms-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.terms-table th,
.terms-table td {
  padding: 0.62rem 0.35rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: baseline;
}

.terms-table thead th {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.terms-table tbody th {
  font-weight: 600;
  color: var(--ink);
}

.terms-table td {
  font-variant-numeric: tabular-nums;
  color: #3d5249;
}

.landing-note .terms-table-wrap + p {
  margin-top: 0.9rem;
}

.auth-aside {
  margin: 1rem 0 0;
  text-align: center;
  font-size: 0.88rem;
}

.auth-aside a {
  color: var(--accent-deep);
  font-weight: 600;
}

.panel-stack {
  display: contents;
}

.panel-footer-shell {
  display: contents;
}

.panel-footer-fade {
  display: none;
}

.brand-user .btn.primary {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 0.5rem 0.95rem;
}

/* —— Sendline Desktop (Electron) native shell —— */
html.is-sendline-desktop {
  --desktop-header-height: 44px;
  --desktop-scrollbar-size: 8px;
  --desktop-actions-gap: 0.85rem;
}

body.is-sendline-desktop {
  --font-body: "Segoe UI", system-ui, sans-serif;
}

body.is-sendline-desktop .noise,
body.is-sendline-desktop .orb {
  display: none !important;
}

body.is-sendline-desktop .app-header {
  height: var(--desktop-header-height);
  min-height: var(--desktop-header-height);
  padding: 0;
  background: #ffffff;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: none;
  border-bottom: 1px solid var(--line);
  -webkit-app-region: drag;
}

body.is-sendline-desktop .app-header a,
body.is-sendline-desktop .app-header button,
body.is-sendline-desktop .app-header input,
body.is-sendline-desktop .app-header select,
body.is-sendline-desktop .app-header textarea,
body.is-sendline-desktop .user-chip {
  -webkit-app-region: no-drag;
}

body.is-sendline-desktop .app-header__inner {
  width: calc(100% - 2 * var(--layout-gutter));
  max-width: none;
  height: 100%;
  margin: 0 auto;
  padding: 0;
  padding-right: calc(100vw - env(titlebar-area-width, calc(100vw - 140px)));
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.65rem;
}

body.is-sendline-desktop .app-nav,
body.is-sendline-desktop #adminLink {
  display: none !important;
}

body.is-sendline-desktop .brand-lockup {
  flex-shrink: 0;
}

body.is-sendline-desktop .app-header .brand-mark {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

body.is-sendline-desktop .app-header .brand-icon {
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 8px;
}

body.is-sendline-desktop.user-signed-in .brand-lockup {
  display: inline-flex;
  order: 1;
}

body.is-sendline-desktop.user-signed-in .user-chip {
  order: 3;
  margin-left: 0;
}

body.is-sendline-desktop.user-signed-in .app-header__end {
  order: 4;
  margin-left: 0;
}

body.is-sendline-desktop .desktop-linked-chip {
  order: 2;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.25rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: var(--ok-soft);
  border: 1px solid rgba(13, 148, 136, 0.22);
  font: 600 0.84rem/1.2 var(--font-body);
  color: var(--ok);
  -webkit-app-region: no-drag;
}

body.is-sendline-desktop .desktop-linked-chip[hidden] {
  display: none !important;
}

body.is-sendline-desktop .desktop-linked-chip--warn {
  background: rgba(180, 83, 9, 0.12);
  border-color: rgba(180, 83, 9, 0.28);
  color: var(--warn, #b45309);
}

body.is-sendline-desktop #logoutBtn {
  font: 600 0.84rem/1.2 var(--font-body);
  min-height: 2.25rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid rgba(19, 78, 74, 0.14);
  border-radius: 9px;
  background: #fff;
  color: var(--accent-deep);
}

body.is-sendline-desktop #logoutBtn:hover {
  background: var(--accent-soft);
  color: var(--accent-deep);
}

body.is-sendline-desktop .page-intro {
  display: none;
}

body.is-sendline-desktop .stage--app {
  width: min(1200px, calc(100% - 2 * var(--layout-gutter)));
  max-width: 1200px;
  padding-top: 0.65rem;
  padding-bottom: calc(28px + 0.5rem);
}

body.is-sendline-desktop .desktop-statusbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  height: 28px;
  min-height: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0 0.85rem;
  font: 500 0.72rem/1 var(--font-body);
  color: var(--ink-soft);
  background: #ffffff;
  border-top: 1px solid var(--line);
  -webkit-app-region: drag;
}

body.is-sendline-desktop .desktop-statusbar[hidden] {
  display: none !important;
}

body.is-sendline-desktop .desktop-statusbar__text {
  -webkit-app-region: no-drag;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.is-sendline-desktop .desktop-statusbar[data-tone="linked"] .desktop-statusbar__text {
  color: var(--accent-deep);
}

body.is-sendline-desktop .desktop-statusbar[data-tone="warn"] .desktop-statusbar__text {
  color: var(--warn);
}

body.is-sendline-desktop .desktop-statusbar[data-tone="error"] .desktop-statusbar__text {
  color: var(--danger);
}

body.is-sendline-desktop .desktop-statusbar__version {
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
  color: rgba(71, 85, 105, 0.85);
  -webkit-app-region: no-drag;
}

body.is-sendline-desktop .panel-stack {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  position: relative;
}

body.is-sendline-desktop .panel-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding-right: 0;
  padding-bottom: calc(5.5rem + var(--desktop-actions-gap));
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: rgba(100, 116, 139, 0.45) transparent;
}

body.is-sendline-desktop .panel-scroll::-webkit-scrollbar {
  width: var(--desktop-scrollbar-size);
}

body.is-sendline-desktop .panel-scroll::-webkit-scrollbar-track {
  background: transparent;
}

body.is-sendline-desktop .panel-scroll::-webkit-scrollbar-button {
  display: none;
  height: 0;
  width: 0;
}

body.is-sendline-desktop .panel-scroll::-webkit-scrollbar-thumb {
  background: rgba(100, 116, 139, 0.42);
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}

body.is-sendline-desktop .panel-footer-shell {
  display: block;
  position: absolute;
  left: 0;
  right: var(--desktop-scrollbar-size);
  bottom: 0;
  z-index: 3;
  pointer-events: none;
}

body.is-sendline-desktop .panel-footer-fade {
  display: block;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 2rem;
  background: linear-gradient(to bottom, transparent, var(--paper));
  pointer-events: none;
}

body.is-sendline-desktop .panel-footer-shell .actions-card {
  pointer-events: auto;
  margin-top: 0;
}

body.is-sendline-desktop .log-panel .window-dots {
  display: none;
}

body.is-sendline-desktop .log-panel .pulse[data-state="idle"] {
  background: #64748b;
  animation: none;
  box-shadow: none;
}

body.is-sendline-desktop .log-panel .pulse[data-state="running"] {
  background: var(--accent);
  animation: beat 1.2s ease-out infinite;
}

body.is-sendline-desktop .log-panel .pulse[data-state="error"] {
  background: #dc2626;
  animation: none;
  box-shadow: none;
}

body.is-sendline-desktop .log-empty svg {
  display: none;
}

body.is-sendline-desktop .log-empty-title {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 500;
  color: #6b857c;
}

body.is-sendline-desktop #namesField > .field-hint {
  font-size: 12px;
  line-height: 1.45;
  color: #334155;
}

body.is-sendline-desktop .insert-name-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.65rem;
  padding: 0.15rem 0.55rem;
  border: 1px solid rgba(19, 78, 74, 0.14);
  border-radius: 999px;
  background: #fff;
  font: 600 0.72rem/1 var(--font-mono);
  color: var(--accent-deep);
  cursor: pointer;
}

body.is-sendline-desktop .insert-name-chip:hover {
  background: var(--accent-soft);
}

body.is-sendline-desktop #messageField .meta.tip {
  display: none;
}

body.is-sendline-desktop textarea,
body.is-sendline-desktop input[type="text"],
body.is-sendline-desktop input[type="password"],
body.is-sendline-desktop input[type="email"],
body.is-sendline-desktop input[type="url"],
body.is-sendline-desktop select {
  background: #ffffff;
  border: 1px solid rgba(19, 78, 74, 0.16);
  border-radius: 10px;
}

body.is-sendline-desktop textarea::placeholder,
body.is-sendline-desktop input::placeholder {
  color: rgba(71, 85, 105, 0.72);
}

body.is-sendline-desktop textarea:focus,
body.is-sendline-desktop input[type="text"]:focus,
body.is-sendline-desktop input[type="password"]:focus,
body.is-sendline-desktop input[type="email"]:focus,
body.is-sendline-desktop input[type="url"]:focus,
body.is-sendline-desktop select:focus {
  border-color: #14b8a6;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.18);
}

body.is-sendline-desktop #names:focus,
body.is-sendline-desktop #message:focus {
  background: #fff;
}

body.is-sendline-desktop.auth-page .app-header {
  height: var(--desktop-header-height);
  padding: 0;
}

body.is-sendline-desktop.auth-page .app-header__inner {
  height: 100%;
  padding-right: calc(100vw - env(titlebar-area-width, calc(100vw - 140px)));
}

body.is-sendline-desktop.auth-page .auth-panel-lead {
  max-width: 28rem;
}

body.is-sendline-desktop.auth-page #headerLoginBtn {
  display: none;
}

body.is-sendline-desktop.auth-page .input-wrap {
  min-height: 3.125rem;
}

body.is-sendline-desktop.auth-page .input-label {
  font-size: 0.8rem;
  letter-spacing: 0.01em;
  color: rgba(19, 78, 74, 0.82);
}
