:root {
  --bg: #060606;
  --card: #101010;
  --line: rgba(255, 255, 255, 0.1);
  --text: #f6f6f6;
  --muted: #9a9a9a;
  --ok: #3ecf8e;
  --warn: #f0b429;
  --bad: #ff6b6b;
  --sans: "Plus Jakarta Sans", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(920px 520px at 12% -8%, rgba(255, 255, 255, 0.1), transparent 58%),
    radial-gradient(780px 460px at 92% 4%, rgba(255, 255, 255, 0.04), transparent 52%),
    var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
}

button, input, select, textarea { font: inherit; color: inherit; }

a { color: inherit; text-decoration: none; }

button {
  cursor: pointer;
  border: 0;
  background: none;
}

img { display: block; max-width: 100%; }

#app { min-height: 100vh; }

.top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 12px 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(6, 6, 6, 0.78);
  backdrop-filter: blur(18px) saturate(1.2);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand img {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  object-fit: cover;
}

.brand span,
.brand {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: 8px;
}

.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.nav a:hover, .nav a.is-active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.top-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile {
  position: relative;
}

.profile-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 14px 0 16px;
  border: 1px solid #2c2c2c;
  border-radius: 999px;
  background: #111;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
}

.profile-btn svg {
  width: 16px;
  height: 16px;
}

.profile-btn[aria-expanded="true"] {
  background: #1a1a1a;
}

.profile-menu {
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 20;
  min-width: 180px;
  padding-top: 8px;
}

.profile-panel {
  min-width: 180px;
  padding: 6px;
  background: #141414;
  border: 1px solid #2c2c2c;
  border-radius: 14px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

.profile-meta {
  padding: 10px 12px 12px;
  margin-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.profile-meta strong {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.profile-panel a,
.profile-panel button {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-align: left;
  cursor: pointer;
}

.profile-panel a:hover,
.profile-panel button:hover,
.profile-panel a:focus-visible,
.profile-panel button:focus-visible {
  background: #222;
}

.page {
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 28px 0 40px;
}

.hero {
  display: grid;
  gap: 18px;
  padding: 28px 0 10px;
  animation: rise 0.45s ease both;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero p {
  margin: 0;
  max-width: 46ch;
  color: var(--muted);
  font-size: 1.05rem;
}

.search {
  display: flex;
  gap: 10px;
  max-width: 560px;
}

.search input:focus,
.field input:focus,
.field select:focus,
.field textarea:focus,
.composer textarea:focus {
  border-color: rgba(255, 255, 255, 0.28);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 14px 20px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
  border: 0;
  transition: transform 0.12s ease, background 0.15s ease, border-color 0.15s ease;
}

.btn:hover { transform: translateY(0); }

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: #fff;
  color: #111;
}

.btn-primary:hover {
  background: #ececec;
}

.btn-ghost,
.ghost-btn {
  border: 1px solid var(--line);
  color: #fff;
  background: transparent;
}

.btn-ghost:hover,
.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.22);
}

.btn-danger {
  border: 1px solid rgba(255, 107, 107, 0.35);
  color: #ffb4b4;
  background: transparent;
}

.grid-cats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
  margin-top: 22px;
}

.cat {
  text-align: left;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(16, 16, 16, 0.85);
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.cat:hover {
  border-color: rgba(255, 255, 255, 0.28);
  transform: translateY(-2px);
}

.cat strong {
  display: block;
  margin-bottom: 6px;
}

.cat span {
  color: var(--muted);
  font-size: 13px;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(16, 16, 16, 0.9);
  padding: 18px;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  margin: 8px 0 16px;
}

.section-head h2 {
  margin: 0;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}

.muted { color: var(--muted); }

.hint {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.ok,
.form-ok {
  margin: 12px 0 0;
  color: #d7d7d7;
  font-size: 14px;
}

.error,
.form-error {
  margin: 12px 0 0;
  color: #ffb4b4;
  font-size: 14px;
}

.form-error:empty,
.form-ok:empty { display: none; }

.search input,
.composer textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  background: #161616;
  border-radius: 12px;
  padding: 10px 14px;
  outline: none;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 44px;
  background: #161616;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 14px;
  outline: none;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tabs button {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-weight: 600;
  font-size: 13px;
}

.tabs button.is-active {
  background: #fff;
  color: #111;
  border-color: #fff;
}

.ticket-list {
  display: grid;
  gap: 10px;
}

.ticket-row {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
}

.ticket-row:hover { border-color: rgba(255, 255, 255, 0.22); }

.ticket-row .id {
  font-weight: 800;
  letter-spacing: -0.02em;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid var(--line);
}

.badge.open { color: #fff; border-color: rgba(255,255,255,0.35); }
.badge.solved { color: var(--ok); border-color: rgba(62,207,142,0.35); }
.badge.closed { color: var(--muted); }
.badge.high, .badge.urgent { color: var(--warn); border-color: rgba(240,180,41,0.35); }
.badge.urgent { color: var(--bad); border-color: rgba(255,107,107,0.35); }

.form {
  display: grid;
  gap: 14px;
  max-width: 640px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 14px;
  font-size: 13px;
  font-weight: 600;
}

.field textarea { min-height: 110px; resize: vertical; }

.field .hint {
  margin: 0;
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}

.btn.start {
  width: auto;
  margin: 18px 0 0;
  min-height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: #fff;
  color: #111;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
}

.btn.start:hover { background: #ececec; }

.top-actions .btn {
  width: auto;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.thread {
  display: grid;
  gap: 12px;
  margin: 18px 0;
}

.msg {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.02);
}

.msg.staff { border-color: rgba(255, 255, 255, 0.22); background: rgba(255,255,255,0.04); }
.msg.system { color: var(--muted); font-size: 13px; background: transparent; }
.msg.internal { border-style: dashed; border-color: rgba(240,180,41,0.35); }

.msg-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  font-size: 13px;
  color: var(--muted);
}

.msg-body {
  white-space: pre-wrap;
  word-break: break-word;
}

.msg-body code, .msg-body pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
}

.msg-body pre {
  margin: 8px 0 0;
  padding: 12px;
  border-radius: 12px;
  background: #000;
  overflow: auto;
}

.composer {
  display: grid;
  gap: 10px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.stat {
  padding: 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(16,16,16,0.9);
}

.stat strong {
  display: block;
  font-size: 1.6rem;
  letter-spacing: -0.03em;
}

.stat span { color: var(--muted); font-size: 13px; }

.meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.meta-grid div {
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.02);
}

.meta-grid dt { color: var(--muted); font-size: 12px; }
.meta-grid dd { margin: 4px 0 0; font-weight: 600; }

.kb-list {
  display: grid;
  gap: 10px;
}

.kb-item {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
}

.kb-item h3 { margin: 0 0 6px; font-size: 1rem; }
.kb-item p { margin: 0; color: var(--muted); font-size: 14px; }

.login-box {
  width: min(420px, 100%);
  margin: 48px auto;
  padding: 24px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: rgba(16,16,16,0.92);
  display: grid;
  gap: 12px;
  animation: rise 0.4s ease both;
}

.login-box h1 {
  margin: 0;
  font-size: 1.6rem;
  letter-spacing: -0.03em;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.settings {
  width: min(1040px, 100%);
  margin: 8px auto 0;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
  container-type: inline-size;
  container-name: settings;
}

.settings-nav {
  display: grid;
  gap: 4px;
  position: sticky;
  top: 88px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.settings-nav .nav-label,
.nav-label {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.settings-nav button,
.settings-nav a {
  width: 100%;
  text-align: left;
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  display: flex;
  align-items: center;
}

.settings-nav button:hover,
.settings-nav a:hover,
.settings-nav button[aria-current="page"],
.settings-nav button[aria-current="page"]:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.settings-nav .signout {
  margin-top: 8px;
  color: #ffb4b4;
}

.settings-nav .signout:hover {
  background: rgba(255, 92, 92, 0.08);
  color: #ffc9c9;
}

.settings-main {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.settings h1,
.settings-main h1 {
  font-size: clamp(36px, 5cqw, 52px);
  margin: 0;
  letter-spacing: -0.04em;
}

.settings h2,
.settings-main h2 {
  font-size: 20px;
  margin: 28px 0 12px;
}

.settings h3,
.settings-main h3 {
  margin: 22px 0 0;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.settings .hint a { text-decoration: underline; text-underline-offset: 3px; }

.settings-main > .hint {
  margin: 10px 0 0;
}

.info-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.info-cell {
  position: relative;
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.025);
}

.info-label {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.info-line {
  display: flex;
  align-items: center;
  gap: 8px;
}

.info-field {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: 0 8px 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.28);
}

.info-value {
  margin: 0;
  min-width: 0;
  font-size: 15px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.tip { flex: 0 0 auto; margin-left: auto; }

.tip-btn {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: #2a2a2a;
  color: #d7d7d7;
  cursor: pointer;
}

.tip-btn svg { width: 16px; height: 16px; }

.tip-btn:hover,
.tip-btn:focus-visible { background: #3a3a3a; color: #fff; }

.tip-bubble {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: calc(100% - 52px);
  padding: 12px 14px;
  border-radius: 10px;
  background: #2a2a2a;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
  z-index: 8;
}

.info-cell:not(:has(.icon-btn)) .tip-bubble { width: 100%; }

.tip-bubble strong { font-weight: 700; }

.tip-bubble::after {
  content: "";
  position: absolute;
  bottom: 100%;
  right: 16px;
  border: 7px solid transparent;
  border-bottom-color: #2a2a2a;
}

.icon-btn {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 12px;
  background: #fff;
  color: #111;
  cursor: pointer;
}

.icon-btn:hover { background: #e8e8e8; }

.method-icon {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  display: grid;
  place-items: center;
  border: 1px solid #2c2c2c;
  border-radius: 12px;
  background: #181818;
  color: #fff;
}

.connected-list {
  display: grid;
  gap: 12px;
  margin: 14px 0 8px;
}

.connected-card {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.025);
}

.connected-card.is-on {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
}

.connected-card.no-action {
  grid-template-columns: 44px 1fr;
}

.connected-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: #161616;
  border: 1px solid var(--line);
}

.g-mark {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: conic-gradient(#ea4335, #fbbc05, #34a853, #4285f4, #ea4335);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  flex: 0 0 auto;
}

.d-mark {
  width: 20px;
  height: 20px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  color: #fff;
}

.connected-copy {
  min-width: 0;
}

.connected-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.connected-title strong {
  font-size: 15px;
}

.connected-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.connected-pill.on {
  color: #d8d8d8;
  border-color: rgba(255, 255, 255, 0.22);
}

.connected-copy .hint {
  margin: 0;
}

.connected-action {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.connected-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 112px;
  min-height: 38px;
  padding: 0 16px;
  margin: 0;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: -0.01em;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.12s ease;
}

.connected-btn:active {
  transform: translateY(1px);
}

.connected-btn.connect {
  background: #f4f4f4;
  color: #0d0d0d;
  border: 1px solid transparent;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12) inset, 0 8px 20px rgba(0, 0, 0, 0.28);
}

.connected-btn.connect:hover {
  background: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset, 0 10px 24px rgba(0, 0, 0, 0.34);
}

.connected-btn.disconnect {
  background: rgba(255, 255, 255, 0.03);
  color: #cfcfcf;
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.connected-btn.disconnect:hover {
  background: rgba(255, 92, 92, 0.08);
  border-color: rgba(255, 120, 120, 0.35);
  color: #ffb4b4;
}

.delete-block {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.delete-block h2 { margin-bottom: 8px; }

.delete-block .btn { margin-top: 16px; }

.method {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #111;
}

.method-copy { flex: 1; min-width: 0; }

.method-copy .hint { margin: 4px 0 0; }

.method-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  margin-left: auto;
}

.method-btn {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.method-btn.setup {
  border: 0;
  background: #fff;
  color: #111;
}

.method-btn.setup:hover { background: #e8e8e8; }

.method-btn.off {
  border: 1px solid #3a3a3a;
  background: transparent;
  color: #e8e8e8;
}

.method-btn.off:hover { background: #1c1c1c; }

.make-primary {
  border: 0;
  background: none;
  color: #fff;
  padding: 0;
  font-size: 13px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.pill {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #fff;
  color: #111;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  vertical-align: 1px;
}

.guard {
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #3d3420;
  border-radius: 14px;
  background: #17140e;
  color: #f3e6c4;
  font-size: 14px;
}

.btn.slim { margin-left: auto; width: auto; }

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.66);
}

.modal-card {
  width: min(440px, 100%);
  max-height: min(88vh, 760px);
  overflow: auto;
  background: #101010;
  border: 1px solid #2a2a2a;
  border-radius: 16px;
  padding: 18px 18px 16px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 0;
}

.modal-head h3 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -0.03em;
  font-weight: 700;
}

.modal-close {
  width: 32px;
  height: 32px;
  min-width: 32px;
  min-height: 32px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #cfcfcf;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.modal-close:hover {
  background: #1c1c1c;
  color: #fff;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
}

.modal-actions .btn,
.modal-actions .btn-primary,
.modal-actions .btn-ghost,
.modal-actions .ghost-btn {
  width: auto;
  min-width: 104px;
  min-height: 40px;
  margin-top: 0;
  padding: 0 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.modal-actions .btn,
.modal-actions .btn-primary {
  border: 0;
  background: #fff;
  color: #111;
}

.modal-actions .btn:hover,
.modal-actions .btn-primary:hover { background: #ececec; }

.modal-actions .btn-ghost,
.modal-actions .ghost-btn {
  background: #161616;
  border: 1px solid #3a3a3a;
  color: #eee;
}

.modal-actions .btn-ghost:hover,
.modal-actions .ghost-btn:hover { background: #222; }

.modal-actions .btn[hidden],
.modal-card [hidden] { display: none; }

.totp-secret {
  margin: 0;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #0c0c0c;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  overflow-wrap: anywhere;
}

@media (max-width: 720px) {
  .ticket-row {
    grid-template-columns: 1fr;
  }
  .nav { display: none; }
  .top { gap: 10px; }
  .settings {
    grid-template-columns: 1fr;
  }
  .settings-nav {
    position: static;
    grid-template-columns: 1fr 1fr;
  }
  .settings-nav .nav-label,
  .settings-nav .signout {
    grid-column: 1 / -1;
  }
  .info-row {
    grid-template-columns: 1fr;
  }
  .connected-card {
    grid-template-columns: 44px 1fr;
  }
  .method {
    flex-direction: column;
    align-items: stretch;
  }
  .connected-action,
  .method-actions {
    width: 100%;
    align-items: stretch;
  }
  .connected-btn,
  .method-btn {
    width: 100%;
    min-width: 0;
  }
}
