/* ──────────────────────────────────────────────────────────────────────────
   YANDEX PANEL — FINAL FIXED CSS (PART 1/5)
   Root variables, login page, saved accounts, APK, forms, footer
────────────────────────────────────────────────────────────────────────── */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

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

:root {
  --bg:         #080808;
  --bg-card:    #111111;
  --bg-card2:   #0d0d0d;
  --bg-input:   #111111;
  --border:     #1f1f1f;
  --border2:    #1a1a1a;
  --border3:    #222222;
  --text:       #ffffff;
  --text-dim:   #cccccc;
  --text-muted: #888888;
  --text-faint: #555555;
  --text-ghost: #444444;
  --red:        #ef4444;
  --red-glow:   rgba(239,68,68,0.3);
  --green:      #22c55e;
  --green-glow: rgba(34,197,94,0.3);
  --yellow:     #facc15;
  --purple:     #a855f7;
  --amber:      #f59e0b;
  --blue:       #0088cc;
  --accent-red: #dc2626;
}

html, body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #2a2a2a; border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: #3a3a3a; }

.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ── LOGIN PAGE ── */
#login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 60% 0%, hsla(0,60%,12%,0.5) 0%, transparent 60%),
    radial-gradient(ellipse at 0% 100%, hsl(220,30%,8%) 0%, hsl(220,25%,5%) 100%);
}
.login-grid-bg {
  position: absolute;
  inset: 0;
  opacity: 0.03;
  background-image:
    linear-gradient(hsl(220,15%,92%) 1px, transparent 1px),
    linear-gradient(90deg, hsl(220,15%,92%) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}
.login-glow1 {
  position: absolute;
  top: 0; right: 25%;
  width: 24rem; height: 24rem;
  border-radius: 50%;
  background: radial-gradient(circle, #ef4444, transparent);
  opacity: 0.10;
  filter: blur(60px);
  pointer-events: none;
}
.login-glow2 {
  position: absolute;
  bottom: 0; left: 25%;
  width: 20rem; height: 20rem;
  border-radius: 50%;
  background: radial-gradient(circle, #f97316, transparent);
  opacity: 0.08;
  filter: blur(60px);
  pointer-events: none;
}
.login-container {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 440px;
  padding: 2rem 1rem;
}
.login-logo-wrap { text-align: center; margin-bottom: 2rem; }
.login-logo-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4rem; height: 4rem;
  border-radius: 1rem;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #dc2626, #f97316);
  box-shadow: 0 8px 32px rgba(220,38,38,0.4);
}
.login-logo-icon svg { width: 2rem; height: 2rem; color: white; }
.login-title-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 2.5rem;
}
.login-title {
  font-size: 2.25rem;
  font-weight: 800;
  font-style: italic;
  letter-spacing: -0.03em;
  color: white;
  animation: fadeInUp 0.8s ease-out forwards;
}
.login-title .accent { color: #f97316; }
.login-title .logo-dot {
  width: 0.375rem; height: 0.375rem;
  background: #f97316;
  border-radius: 50%;
  margin-left: -0.2em;
  margin-top: -0.8em;
  box-shadow: 0 0 6px #f97316;
  animation: glint 1.5s infinite;
}
.login-subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  animation: fadeInUp 0.8s ease-out 0.3s both;
}
.glass-card {
  background: rgba(14,14,20,0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 1.5rem;
  padding: 1.75rem;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6);
}
.saved-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.saved-header-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
}
.saved-count {
  font-size: 0.7rem;
  color: var(--text-muted);
  background: rgba(255,255,255,0.05);
  padding: 0.25rem 0.625rem;
  border-radius: 999px;
}
.saved-list {
  max-height: 13rem;
  overflow-y: auto;
  padding-right: 0.25rem;
  margin-bottom: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.saved-empty {
  text-align: center;
  padding: 2rem 0;
  color: var(--text-muted);
  font-size: 0.8rem;
}
.saved-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border-radius: 0.75rem;
  border: 1px solid var(--border3);
  cursor: pointer;
  transition: all 0.2s;
}
.saved-item:hover { border-color: rgba(220,38,38,0.4); background: rgba(220,38,38,0.05); }
.saved-item-info { flex: 1; min-width: 0; }
.saved-item-url {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.saved-item-meta {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-family: monospace;
  margin-top: 0.15rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.saved-item-actions { display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0; }
.btn-icon {
  padding: 0.375rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-icon svg { width: 0.75rem; height: 0.75rem; }
.btn-icon-share {
  background: rgba(30,58,138,0.5);
  border: 1px solid rgba(30,58,138,0.4);
  color: #60a5fa;
}
.btn-icon-share:hover { background: rgba(30,58,138,0.7); }
.btn-icon-del {
  background: rgba(127,29,29,0.5);
  border: 1px solid rgba(127,29,29,0.4);
  color: #f87171;
}
.btn-icon-del:hover { background: rgba(127,29,29,0.7); }
.chevron-right { color: var(--text-muted); }
.btn-new-account {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border-radius: 0.75rem;
  border: 1px dashed var(--border3);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-new-account:hover { border-color: rgba(220,38,38,0.5); background: rgba(220,38,38,0.05); color: #f87171; }
#new-account-form { display: none; }
.form-back-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}
.btn-back {
  padding: 0.375rem;
  border-radius: 0.5rem;
  border: none;
  background: transparent;
  cursor: pointer;
  color: var(--text-muted);
  transition: background 0.2s;
}
.btn-back:hover { background: rgba(255,255,255,0.05); }
.btn-back svg { width: 1rem; height: 1rem; transform: rotate(180deg); display: block; }
.form-title { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.apk-section { margin-bottom: 1.25rem; }
.apk-label-text {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}
.apk-dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.25rem 1rem;
  border-radius: 0.75rem;
  border: 2px dashed #2a2a2a;
  cursor: pointer;
  transition: all 0.2s;
  user-select: none;
}
.apk-dropzone:hover { border-color: rgba(249,115,22,0.4); background: rgba(249,115,22,0.05); }
.apk-dropzone-icon {
  width: 2.5rem; height: 2.5rem;
  border-radius: 0.75rem;
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  display: flex; align-items: center; justify-content: center;
}
.apk-dropzone-icon svg { width: 1.25rem; height: 1.25rem; color: #555; }
.apk-dropzone:hover .apk-dropzone-icon { border-color: rgba(249,115,22,0.3); }
.apk-dropzone:hover .apk-dropzone-icon svg { color: #f97316; }
.apk-dropzone-text { text-align: center; }
.apk-dropzone-title { font-size: 0.8rem; font-weight: 600; color: #666; }
.apk-dropzone:hover .apk-dropzone-title { color: #999; }
.apk-dropzone-sub { font-size: 0.65rem; color: #444; margin-top: 0.125rem; }
.apk-scanning {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.5rem;
  border-radius: 0.75rem;
  border: 1px solid #1f1f1f;
  background: #0d0d0d;
}
.apk-scanning.visible { display: flex; }
.spin { animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.apk-error {
  display: none;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border-radius: 0.75rem;
  background: rgba(127,29,29,0.2);
  border: 1px solid rgba(127,29,29,0.4);
}
.apk-error.visible { display: flex; }
.apk-error p { font-size: 0.75rem; color: #f87171; flex: 1; }
.apk-success {
  display: none;
  border-radius: 0.75rem;
  border: 1px solid rgba(20,83,45,0.4);
  background: rgba(4,47,23,0.2);
  overflow: hidden;
}
.apk-success.visible { display: block; }
.apk-success-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid rgba(20,83,45,0.3);
  background: rgba(4,47,23,0.3);
}
.apk-success-header span { font-size: 0.75rem; font-weight: 600; color: #4ade80; }
.apk-success-body { padding: 0.75rem; display: flex; flex-direction: column; gap: 0.5rem; }
.apk-field-label { font-size: 0.6rem; color: #555; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 0.25rem; }
.apk-field-val {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #0a0a0a;
  border-radius: 0.5rem;
  padding: 0.375rem 0.625rem;
  border: 1px solid #1a1a1a;
}
.apk-field-val span { font-size: 0.7rem; font-family: monospace; color: #4ade80; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.form-fields { display: flex; flex-direction: column; gap: 1rem; }
.field-label {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}
.field-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border3);
  outline: none;
  font-size: 0.8rem;
  color: var(--text);
  font-family: monospace;
  transition: all 0.2s;
}
.field-input::placeholder { color: rgba(136,136,136,0.5); }
.field-input:focus { border-color: #dc2626; box-shadow: 0 0 0 2px rgba(220,38,38,0.2); }
.form-actions { display: flex; gap: 0.75rem; margin-top: 1.5rem; }
.btn-connect {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border-radius: 0.75rem;
  border: none;
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  color: white;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(220,38,38,0.35);
  transition: opacity 0.2s;
}
.btn-connect:hover { opacity: 0.9; }
.btn-connect:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-cancel {
  padding: 0.75rem 1.25rem;
  border-radius: 0.75rem;
  border: none;
  background: rgba(255,255,255,0.05);
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-cancel:hover { background: rgba(255,255,255,0.08); }
.form-error {
  display: none;
  text-align: center;
  font-size: 0.8rem;
  color: #f87171;
  margin-top: 1rem;
  animation: fadeInUp 0.3s ease-out;
}
.form-error.visible { display: block; }
.login-footer {
  text-align: center;
  font-size: 0.7rem;
  color: rgba(136,136,136,0.4);
  margin-top: 1.5rem;
}



/* ──────────────────────────────────────────────────────────────────────────
   YANDEX PANEL — FINAL FIXED CSS (PART 2/5)
   Dashboard header, stats, filters, cards grid, device cards, skeleton, toast
────────────────────────────────────────────────────────────────────────── */

/* ── DASHBOARD ── */
#dashboard-page {
  min-height: 100vh;
  background: var(--bg);
  flex-direction: column;
}
#dashboard-page.visible { display: flex; }

/* ── HEADER ── */
.dash-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(10,10,10,0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border2);
}
.dash-header-inner {
  max-width: 1800px;
  margin: 0 auto;
  padding: 0.6rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.logo-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.logo-icon {
  width: 1.8rem; height: 1.8rem;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, #dc2626, #f97316);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(220,38,38,0.4);
}
.logo-icon svg { width: 0.9rem; height: 0.9rem; color: white; }
.logo-text {
  font-size: 1.2rem;
  font-weight: 800;
  font-style: italic;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 0.02em;
}
.logo-text .accent { color: #f97316; }
.logo-dot {
  width: 0.4rem; height: 0.4rem;
  background: #f97316;
  border-radius: 50%;
  margin-left: -0.15em;
  margin-top: -0.8em;
  box-shadow: 0 0 6px #f97316;
  animation: glint 1.5s infinite;
}
.search-wrap {
  position: relative;
  flex: 1 1 180px;
  min-width: 130px;
  max-width: 260px;
}
.search-wrap svg {
  position: absolute;
  left: 0.7rem;
  top: 50%;
  transform: translateY(-50%);
  width: 0.9rem; height: 0.9rem;
  color: var(--text-ghost);
  pointer-events: none;
}
.search-input {
  width: 100%;
  padding: 0.45rem 0.8rem 0.45rem 2rem;
  border-radius: 0.6rem;
  background: #111;
  border: 1px solid #222;
  outline: none;
  font-size: 0.8rem;
  color: var(--text);
  transition: border-color 0.2s;
}
.search-input::placeholder { color: var(--text-ghost); }
.search-input:focus { border-color: #333; }
.header-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}
.connected-badge {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  background: rgba(4,47,23,0.4);
  border: 1px solid rgba(20,83,45,0.4);
}
.connected-dot {
  width: 0.45rem; height: 0.45rem;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 6px #22c55e;
}
.connected-badge span { font-size: 0.7rem; font-weight: 600; color: #4ade80; }
.clock-badge {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  background: #111;
  border: 1px solid #1e1e1e;
}
.clock-badge svg { width: 0.8rem; height: 0.8rem; color: var(--text-faint); }
.clock-badge span { font-size: 0.7rem; font-family: monospace; font-weight: 700; color: var(--text-muted); }
.btn-logout {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.7rem;
  border-radius: 0.6rem;
  border: 1px solid #222;
  background: #111;
  font-size: 0.7rem;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
  white-space: nowrap;
}
.btn-logout:hover { color: #f87171; border-color: rgba(127,29,29,0.4); }
.btn-logout svg { width: 0.8rem; height: 0.8rem; }

/* ── ERROR BANNER ── */
.error-banner {
  display: none;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(127,29,29,0.2);
  border: 1px solid rgba(127,29,29,0.3);
  border-radius: 0.75rem;
  margin: 0.5rem 1.2rem;
}
.error-banner.visible { display: flex; }
.error-banner svg { width: 1rem; height: 1rem; color: #f87171; flex-shrink: 0; margin-top: 0.1rem; }
.error-banner p { font-size: 0.75rem; color: #fca5a5; flex: 1; line-height: 1.5; }
.error-banner button { color: #7f1d1d; cursor: pointer; border: none; background: transparent; }
.error-banner button:hover { color: #f87171; }
.error-banner button svg { width: 0.875rem; height: 0.875rem; }

/* ── STATS + FILTERS ── */
.stats-bar {
  border-bottom: 1px solid var(--border2);
  background: #0a0a0a;
}
.stats-bar-inner {
  max-width: 1800px;
  margin: 0 auto;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.stats-group {
  display: flex;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  gap: 0;
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #1a1a1a;
}
.stats-group::-webkit-scrollbar { display: none; }
.stat-item {
  flex-shrink: 0;
  padding: 0 1rem;
  border-right: 1px solid #1a1a1a;
}
.stat-item:last-child { border-right: none; }
.stat-label {
  font-size: 0.55rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-ghost);
  margin-bottom: 0.1rem;
}
.stat-value {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
}
.stat-value.green { color: #4ade80; }
.stat-value.dim { color: var(--text-faint); }
.stat-value.purple { color: #c084fc; }
.filters-group {
  display: flex !important;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  align-items: center;
  flex-wrap: nowrap;
}
.filters-group::-webkit-scrollbar { display: none; }
.filter-btn {
  flex-shrink: 0;
  padding: 0.35rem 0.7rem;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  background: transparent;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-faint);
  cursor: pointer;
  text-transform: capitalize;
  transition: all 0.2s;
  white-space: nowrap;
}
.filter-btn:hover { color: var(--text-muted); }
.filter-btn.active { background: rgba(220,38,38,0.15); border-color: rgba(220,38,38,0.35); color: #f87171; }
.filter-btn.active-bank { background: rgba(34,197,94,0.1); border-color: rgba(34,197,94,0.3); color: #4ade80; }
.filter-btn.active-card { background: rgba(168,85,247,0.1); border-color: rgba(168,85,247,0.3); color: #c084fc; }
.divider-v {
  width: 1px;
  height: 1.2rem;
  background: #222;
  flex-shrink: 0;
}
.sort-select {
  background: #111;
  border: 1px solid #222;
  color: #666;
  font-size: 0.7rem;
  border-radius: 0.5rem;
  padding: 0.3rem 0.4rem;
  outline: none;
  cursor: pointer;
  flex-shrink: 0;
}
.btn-refresh {
  padding: 0.4rem;
  border-radius: 0.5rem;
  border: 1px solid #222;
  background: #111;
  color: var(--text-faint);
  cursor: pointer;
  transition: all 0.2s;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.btn-refresh:hover { color: var(--text-muted); border-color: #333; }
.btn-refresh svg { width: 0.9rem; height: 0.9rem; }
.btn-refresh.spinning svg { animation: spin 0.8s linear infinite; }

/* ── MAIN CONTENT ── */
.dash-main {
  flex: 1;
  max-width: 1800px;
  margin: 0 auto;
  width: 100%;
  padding: 1rem;
}

/* ── CARDS GRID ── */
.cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
@media (min-width: 640px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); gap: 1.2rem; }
}
@media (min-width: 1024px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
}

/* ── DEVICE CARD ── */
.device-card {
  background: #111111;
  border: 1px solid #1f1f1f;
  border-radius: 1rem;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}
.device-card:hover {
  border-color: #2a2a2a;
  background: #161616;
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
  transform: translateY(-2px);
}
.device-card:active { transform: translateY(0); }
.device-card.online { border-color: rgba(34,197,94,0.2); }

.card-header {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  margin-bottom: 0.7rem;
}
.card-wifi-icon {
  width: 2.5rem; height: 2.5rem;
  border-radius: 0.7rem;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  border: 1px solid #262626;
  background: #1a1a1a;
}
.card-wifi-icon.online { background: rgba(34,197,94,0.1); border-color: rgba(34,197,94,0.25); }
.card-wifi-icon svg { width: 1.2rem; height: 1.2rem; color: var(--text-ghost); }
.card-wifi-icon.online svg { color: #4ade80; }
.card-name-wrap { flex: 1; min-width: 0; }
.card-name { font-size: 0.85rem; font-weight: 700; color: white; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-id { font-size: 0.6rem; font-family: monospace; color: var(--text-faint); margin-top: 0.1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-badges { display: flex; align-items: center; gap: 0.3rem; flex-shrink: 0; }
.card-badges svg { width: 0.9rem; height: 0.9rem; }
.badge-upi { color: #f59e0b; }
.badge-bank { color: #4ade80; }
.badge-card-b { color: #c084fc; }

.card-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem;
  margin-bottom: 0.7rem;
}
.card-field-label {
  font-size: 0.55rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-ghost);
  margin-bottom: 0.2rem;
}
.card-field-value { font-size: 0.85rem; font-weight: 700; color: #ccc; }
.card-field-mono { font-family: monospace; font-size: 0.75rem; font-weight: 500; color: #aaa; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.battery-widget { display: flex; align-items: center; gap: 0.4rem; }
.battery-body {
  position: relative;
  display: flex;
  align-items: center;
  width: 1.7rem; height: 0.75rem;
  padding: 2px;
  border-radius: 3px;
  border: 1px solid #555;
}
.battery-fill { border-radius: 1.5px; height: 100%; transition: width 0.5s; }
.battery-cap { width: 3px; height: 5px; background: #555; border-radius: 0 2px 2px 0; margin-left: -1px; }
.battery-pct { font-size: 0.7rem; font-weight: 700; font-family: monospace; }

.card-bank-row {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.6rem 0.8rem;
  border-radius: 0.7rem;
  background: linear-gradient(135deg, rgba(4,47,23,0.55) 0%, rgba(5,78,35,0.3) 100%);
  border: 1px solid rgba(74,222,128,0.25);
  margin-bottom: 0.7rem;
}
.card-bank-row-top { display: flex; align-items: center; justify-content: space-between; }
.card-bank-row-bottom { display: flex; align-items: center; justify-content: flex-end; gap: 0.4rem; }
.card-bank-name {
  color: #86efac;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.8rem;
}
.card-bank-name svg { width: 0.9rem; height: 0.9rem; }
.card-bank-amount {
  color: #fff;
  font-weight: 900;
  font-size: 1.1rem;
}
.card-bank-txn {
  color: #4ade80;
  font-weight: 700;
  font-size: 0.8rem;
  background: rgba(74,222,128,0.12);
  border-radius: 0.4rem;
  padding: 0.1rem 0.4rem;
}
.card-bank-txn.debit { color: #f87171; background: rgba(248,113,113,0.12); }

.card-footer { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.status-dot { width: 0.5rem; height: 0.5rem; border-radius: 50%; flex-shrink: 0; }
.status-dot.online { background: #22c55e; box-shadow: 0 0 6px #22c55e; }
.status-dot.offline { background: #333; }
.status-text { font-size: 0.75rem; font-weight: 600; }
.status-text.online { color: #4ade80; }
.status-text.offline { color: var(--text-faint); }
.last-seen { font-size: 0.6rem; font-family: monospace; color: var(--text-ghost); background: #111; padding: 0.1rem 0.4rem; border-radius: 0.25rem; border: 1px solid #1e1e1e; }
.upi-badge { margin-left: auto; padding: 0.1rem 0.5rem; border-radius: 999px; background: rgba(245,158,11,0.1); border: 1px solid rgba(245,158,11,0.2); font-size: 0.6rem; font-weight: 700; color: #fbbf24; }

/* ── SKELETON ── */
.skeleton-card {
  background: #111;
  border: 1px solid #1f1f1f;
  border-radius: 1rem;
  padding: 1rem;
  animation: skelPulse 1.5s ease-in-out infinite;
}
@keyframes skelPulse { 0%,100%{opacity:1} 50%{opacity:0.5} }
.skel-header { display: flex; align-items: flex-start; gap: 0.7rem; margin-bottom: 0.7rem; }
.skel-box { border-radius: 0.5rem; background: #1a1a1a; }
.skel-w10-h10 { width: 2.5rem; height: 2.5rem; }
.skel-line1 { height: 0.7rem; background: #1a1a1a; border-radius: 0.375rem; flex: 1; margin-bottom: 0.3rem; }
.skel-line2 { height: 0.5rem; background: #151515; border-radius: 0.375rem; width: 60%; }
.skel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.7rem; margin-bottom: 0.7rem; }
.skel-field { height: 2rem; background: #151515; border-radius: 0.5rem; }
.skel-footer { height: 2.5rem; background: #131313; border-radius: 0.5rem; }

/* ── TOAST ── */
#toast {
  display: none;
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  padding: 0.7rem 1.2rem;
  border-radius: 0.8rem;
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  box-shadow: 0 16px 48px rgba(0,0,0,0.6);
  white-space: nowrap;
}
#toast.visible { display: block; animation: toastIn 0.3s ease-out; }
@keyframes toastIn { from { opacity:0; transform: translateX(-50%) translateY(12px); } to { opacity:1; transform: translateX(-50%) translateY(0); } }

/* ── LOADING & EMPTY ── */
.loading-state { display: none; }
.loading-state.visible { display: block; }
.loading-spinner-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.spinner {
  width: 1rem; height: 1rem;
  border: 2px solid #333;
  border-top-color: #dc2626;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.spinner.green { border-top-color: #22c55e; }
.spinner.blue { border-top-color: #0088cc; }
.loading-text { font-size: 0.8rem; color: var(--text-faint); }
.empty-state {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6rem 0;
  text-align: center;
}
.empty-state.visible { display: flex; }
.empty-icon {
  width: 4rem; height: 4rem;
  border-radius: 1rem;
  background: #111;
  border: 1px solid #1e1e1e;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.25rem;
}
.empty-icon svg { width: 2rem; height: 2rem; color: #2a2a2a; }
.empty-title { font-size: 0.9rem; font-weight: 700; color: var(--text-ghost); }
.empty-sub { font-size: 0.8rem; color: #333; margin-top: 0.375rem 0 1.25rem; }
.auto-refresh-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  background: #111;
  border: 1px solid #1e1e1e;
  margin-top: 1rem;
}
.pulse-dot {
  width: 0.5rem; height: 0.5rem;
  border-radius: 50%;
  background: #dc2626;
  animation: pulseDot 1.5s ease-in-out infinite;
}
@keyframes pulseDot { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.5;transform:scale(0.8)} }
.auto-refresh-badge span { font-size: 0.7rem; color: var(--text-faint); }
.filter-empty {
  display: none;
  grid-column: 1/-1;
  padding: 4rem 0;
  text-align: center;
}
.filter-empty.visible { display: block; }
.filter-empty p { font-size: 0.8rem; color: var(--text-ghost); }
.sms-loading-banner {
  display: none;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding: 0.5rem 0.75rem;
  border-radius: 0.75rem;
  background: #111;
  border: 1px solid #1e1e1e;
  width: fit-content;
}
.sms-loading-banner.visible { display: flex; }
.sms-loading-banner span { font-size: 0.7rem; color: var(--text-faint); }




/* ──────────────────────────────────────────────────────────────────────────
   YANDEX PANEL — FINAL FIXED CSS (PART 3/5)
   Detail panel: overlay, header, status bar, tabs, info, bank, cards, SMS, send
   Patches applied: header visible, bank/card sizes increased, SMS spacing + white time
────────────────────────────────────────────────────────────────────────── */

/* ── DETAIL PANEL ── */
#detail-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 50;
}
#detail-overlay.visible { display: flex; }
.detail-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.detail-panel {
  position: relative;
  margin-left: auto;
  width: 100%;
  max-width: 32rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  background: #0d0d0d;
  border-left: 1px solid #1f1f1f;
  box-shadow: -24px 0 80px rgba(0,0,0,0.6);
  animation: slideInRight 0.25s ease-out;
}
@keyframes slideInRight { from { transform: translateX(100%); } to { transform: translateX(0); } }

/* ── HEADER (STICKY) ── */
.detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.2rem;
  border-bottom: 1px solid #1a1a1a;
  background: #0d0d0d;
  position: sticky;
  top: 0;
  z-index: 10;
}

.detail-header-left {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.detail-device-icon {
  width: 2.2rem; height: 2.2rem;
  border-radius: 0.7rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1a1a1a;
  border: 1px solid #262626;
}
.detail-device-icon.online { background: rgba(34,197,94,0.1); border-color: rgba(34,197,94,0.25); }
.detail-device-icon svg { width: 1rem; height: 1rem; color: var(--text-ghost); }
.detail-device-icon.online svg { color: #4ade80; }
.detail-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: white;
}
.detail-id {
  font-size: 0.6rem;
  font-family: monospace;
  color: var(--text-faint);
  margin-top: 0.1rem;
}
.detail-header-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.btn-detail-del, .btn-detail-close {
  padding: 0.45rem;
  border-radius: 0.6rem;
  border: 1px solid #262626;
  background: #1a1a1a;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
}
.btn-detail-del:hover { color: #f87171; border-color: rgba(127,29,29,0.4); }
.btn-detail-close:hover { color: white; }
.btn-detail-del svg, .btn-detail-close svg { width: 0.9rem; height: 0.9rem; }

/* ── STATUS BAR (STICKY) ── */
.detail-status-bar {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 1.2rem;
  background: #0a0a0a;
  border-bottom: 1px solid #1a1a1a;
  flex-wrap: wrap;
  position: sticky;
  top: 3.5rem;  /* header ki height ke hisaab se adjust */
  z-index: 9;
}
.detail-status-item {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
}
.detail-bat { font-size: 0.65rem; color: var(--text-faint); }
.detail-bat-val { font-weight: 700; }
.detail-upi-badge,
.detail-bank-badge,
.detail-card-badge {
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 700;
}
.detail-upi-badge { background: rgba(245,158,11,0.1); border: 1px solid rgba(245,158,11,0.2); color: #fbbf24; }
.detail-bank-badge { background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.2); color: #4ade80; }
.detail-card-badge { background: rgba(168,85,247,0.1); border: 1px solid rgba(168,85,247,0.2); color: #c084fc; }

/* ── TABS ── */
.detail-tabs {
  display: flex;
  border-bottom: 1px solid #1a1a1a;
  padding: 0 0.3rem;
  overflow-x: auto;
  scrollbar-width: none;
  flex-wrap: wrap;
  position: sticky;
  top: 5.8rem;  /* header ki height ke hisaab se adjust */
  z-index: 8;
}
.detail-tabs::-webkit-scrollbar { display: none; }
.tab-btn {
  padding: 0.6rem 0.8rem;
  font-size: 0.7rem;
  font-weight: 700;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
  flex-shrink: 0;
}
.tab-btn:hover { color: var(--text-muted); }
.tab-btn.active { border-bottom-color: #dc2626; color: #f87171; }
.tab-btn.active-bank { border-bottom-color: #22c55e; color: #4ade80; }
.tab-btn.active-card-tab { border-bottom-color: #a855f7; color: #c084fc; }
.tab-btn.active-bot { border-bottom-color: #22c55e; color: #4ade80; }

.detail-body { flex: 1; overflow-y: auto; padding-bottom: 0.5rem; }
.tab-pane { display: none; }
.tab-pane.active { display: block; }

/* ── INFO TAB ── */
.info-section { padding: 1rem 1.2rem; }
.info-offline-box {
  margin-bottom: 0.8rem;
  padding: 0.7rem;
  border-radius: 0.7rem;
  background: rgba(127,29,29,0.15);
  border: 1px solid rgba(127,29,29,0.3);
  border-left: 2px solid rgba(220,38,38,0.5);
}
.info-offline-label { font-size: 0.55rem; text-transform: uppercase; letter-spacing: 0.1em; color: #7f1d1d; font-weight: 700; margin-bottom: 0.2rem; }
.info-offline-time { font-size: 1rem; font-weight: 900; color: #f87171; }
.info-offline-ts { font-size: 0.6rem; font-family: monospace; color: rgba(248,113,113,0.5); margin-top: 0.1rem; }
.info-online-box {
  margin-bottom: 0.8rem;
  padding: 0.7rem;
  border-radius: 0.7rem;
  background: rgba(4,47,23,0.15);
  border: 1px solid rgba(20,83,45,0.3);
}
.info-online-label { font-size: 0.55rem; text-transform: uppercase; letter-spacing: 0.1em; color: #14532d; font-weight: 700; margin-bottom: 0.2rem; }
.info-online-ts { font-size: 0.6rem; font-family: monospace; color: #22c55e; }
.info-section-label { font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-ghost); font-weight: 700; margin-bottom: 0.6rem; }
.info-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid #1a1a1a;
}
.info-row:last-child { border-bottom: none; }
.info-row-label { font-size: 0.7rem; color: var(--text-faint); font-weight: 500; flex-shrink: 0; width: 7rem; }
.info-row-value { font-size: 0.7rem; font-weight: 600; color: #ccc; text-align: right; word-break: break-all; }
.info-row-value.mono { font-family: monospace; }
.info-row-value.highlight { color: #60a5fa; }
.info-row-value.highlight2 { color: #c084fc; }

/* ── BANK TAB ── */
.bank-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1.2rem;
  border-bottom: 1px solid #1a1a1a;
}
.bank-header-info { font-size: 0.7rem; color: var(--text-faint); }
.bank-header-count { font-size: 0.6rem; color: rgba(34,197,94,0.6); margin-top: 0.1rem; }
.btn-refresh-sms {
  padding: 0.3rem;
  border-radius: 0.4rem;
  border: none;
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
  transition: all 0.2s;
}
.btn-refresh-sms:hover { background: rgba(255,255,255,0.05); color: var(--text-muted); }
.btn-refresh-sms svg { width: 0.8rem; height: 0.8rem; display: block; }
.bank-list { padding: 0.6rem 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.bank-summary-box {
  padding: 0.7rem;
  border-radius: 0.7rem;
  background: #081410;
  border: 1px solid rgba(20,83,45,0.4);
  margin-bottom: 0.2rem;
}
.bank-summary-label { font-size: 0.55rem; text-transform: uppercase; letter-spacing: 0.1em; color: #22c55e; opacity: 0.6; margin-bottom: 0.2rem; }
.bank-summary-amount { display: flex; align-items: baseline; gap: 0.4rem; }
.bank-summary-symbol { font-size: 1rem; font-weight: 900; color: #4ade80; }
.bank-summary-val { font-size: 1.5rem; font-weight: 900; color: white; }
.bank-summary-acc { font-size: 0.65rem; font-family: monospace; color: #22c55e; opacity: 0.6; }

.bank-item {
  padding: 0.7rem;
  border-radius: 0.7rem;
  background: #0a1410;
  border: 1px solid rgba(20,83,45,0.3);
  border-left: 2px solid rgba(34,197,94,0.6);
}
.bank-item-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.4rem;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.bank-item-left {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.bank-item-icon {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 0.35rem;
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}
.bank-item-icon svg {
  width: 0.9rem;
  height: 0.9rem;
  color: #4ade80;
}
.bank-item-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: #4ade80;
}
.bank-item-sender {
  font-size: 0.7rem;
  color: var(--text-ghost);
  font-family: monospace;
  margin-left: 0.3rem;
}
.bank-item-acc {
  font-size: 0.7rem;
  font-family: monospace;
  color: var(--text-faint);
  background: #111;
  padding: 0.1rem 0.35rem;
  border-radius: 0.2rem;
}
.bank-item-txn {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
}
.bank-item-txn.credit { background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.2); color: #4ade80; }
.bank-item-txn.debit { background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.2); color: #f87171; }
.bank-item-txn svg { width: 0.8rem; height: 0.8rem; }

.bank-item-amounts {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.bank-item-bal-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-ghost);
  margin-bottom: 0.1rem;
}
.bank-item-bal {
  font-size: 1.4rem;
  font-weight: 900;
  color: white;
}
.bank-item-bal-sym {
  font-size: 0.85rem;
  color: #4ade80;
  margin-right: 0.05em;
}
.bank-item-txn-amount { text-align: right; }
.bank-item-txn-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-ghost);
  margin-bottom: 0.1rem;
}
.bank-item-txn-val {
  font-size: 0.9rem;
  font-weight: 700;
}
.bank-item-txn-val.credit { color: #4ade80; }
.bank-item-txn-val.debit { color: #f87171; }

.bank-item-raw {
  font-size: 0.75rem;
  color: #555;
  margin-top: 0.4rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.bank-item-ts {
  font-size: 0.6rem;
  color: #2a2a2a;
  font-family: monospace;
  margin-top: 0.2rem;
}

/* ── EMPTY STATE (BANK, CARDS, SMS) ── */
.tab-empty {
  padding: 1.5rem 0;
  text-align: center;
}
.tab-empty svg {
  width: 1.5rem;
  height: 1.5rem;
  color: #2a2a2a;
  margin: 0 auto 0.5rem;
}
.tab-empty-title {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-ghost);
}
.tab-empty-sub {
  font-size: 0.6rem;
  color: #333;
  margin-top: 0.15rem;
  padding: 0 1rem;
  line-height: 1.4;
}

/* ── CARDS TAB ── */
.card-list { padding: 0.6rem 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.card-item {
  padding: 0.7rem;
  border-radius: 0.7rem;
  background: #0f0a1a;
  border: 1px solid rgba(88,28,135,0.3);
  border-left: 2px solid rgba(168,85,247,0.6);
}
.card-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.4rem;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.card-item-left {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.card-item-icon {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 0.35rem;
  background: rgba(168,85,247,0.1);
  border: 1px solid rgba(168,85,247,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}
.card-item-icon svg {
  width: 0.9rem;
  height: 0.9rem;
  color: #c084fc;
}
.card-item-type {
  font-size: 0.9rem;
  font-weight: 700;
  color: #c084fc;
}
.card-item-exp {
  font-size: 0.7rem;
  color: var(--text-faint);
  font-family: monospace;
}
.card-item-number {
  font-family: monospace;
  font-size: 0.9rem;
  color: #ccc;
  letter-spacing: 0.1em;
}
.card-item-cvv {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.3rem;
}
.card-item-cvv-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-faint);
}
.card-item-cvv-val {
  font-size: 0.8rem;
  font-family: monospace;
  color: #c084fc;
}
.card-item-raw {
  font-size: 0.75rem;
  color: #555;
  margin-top: 0.4rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── SMS TAB ── */
.sms-header {
  display: flex;
  flex-direction: column;
  padding: 0.6rem 1.2rem;
  border-bottom: 1px solid #1a1a1a;
  gap: 0.4rem;
}
.sms-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.sms-header-top span { font-size: 0.7rem; color: var(--text-faint); }
.sms-search-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.sms-search-input {
  flex: 1;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.75rem;
  padding: 0.35rem 0.6rem;
  outline: none;
  transition: border-color 0.2s;
}
.sms-search-input::placeholder { color: var(--text-faint); font-size: 0.7rem; }
.sms-search-input:focus { border-color: rgba(99,102,241,0.5); }
.sms-search-count {
  font-size: 0.65rem;
  color: var(--text-faint);
  white-space: nowrap;
  min-width: 3.5rem;
  text-align: right;
}

.sms-list {
  padding: 0.6rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.sms-item {
  padding: 0.7rem;
  border-radius: 0.7rem;
  border: 1px solid #1e1e1e;
  border-left: 2px solid;
  margin-bottom: 0.6rem;  /* spacing between messages */
}
.sms-item.bank-sms { background: #0a130d; border-left-color: rgba(34,197,94,0.5); }
.sms-item.card-sms { background: #100d18; border-left-color: rgba(168,85,247,0.5); }
.sms-item.other-sms { background: #111; border-left-color: rgba(220,38,38,0.5); }

.sms-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.3rem;
}
.sms-sender {
  font-size: 0.8rem;
  font-weight: 700;
}
.sms-sender.bank-sms { color: #4ade80; }
.sms-sender.card-sms { color: #c084fc; }
.sms-sender.other-sms { color: #f87171; }

.sms-time {
  font-size: 0.7rem;
  font-family: monospace;
  color: white !important;  /* force white */
}
.sms-text {
  font-size: 0.8rem;
  color: #ccc;
  line-height: 1.5;
}

/* ── SEND TAB ── */
.send-section { padding: 0.8rem 1.2rem; display: flex; flex-direction: column; gap: 0.8rem; }
.send-label { font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-faint); margin-bottom: 0.3rem; }
.sim-btns { display: flex; gap: 0.5rem; }
.sim-btn {
  flex: 1;
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: 1px solid #222;
  background: #111;
  font-size: 0.75rem;
  font-weight: 700;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}
.sim-btn:hover { border-color: #333; color: #888; }
.sim-btn.active { background: #dc2626; border-color: #dc2626; color: white; box-shadow: 0 4px 12px rgba(220,38,38,0.35); }
.send-input, .send-textarea {
  width: 100%;
  padding: 0.6rem 0.8rem;
  border-radius: 0.5rem;
  background: #111;
  border: 1px solid #222;
  outline: none;
  font-size: 0.75rem;
  color: white;
  font-family: monospace;
  transition: border-color 0.2s;
}
.send-input::placeholder, .send-textarea::placeholder { color: var(--text-ghost); }
.send-input:focus, .send-textarea:focus { border-color: rgba(220,38,38,0.5); box-shadow: 0 0 0 1px rgba(220,38,38,0.2); }
.send-textarea { resize: none; }
.send-char-count { font-size: 0.6rem; color: var(--text-ghost); text-align: right; margin-top: 0.15rem; }
.btn-send {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.7rem;
  border-radius: 0.5rem;
  border: none;
  background: #dc2626;
  color: white;
  font-weight: 700;
  font-size: 0.75rem;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(220,38,38,0.35);
  transition: all 0.2s;
}
.btn-send:hover { background: #b91c1c; }
.btn-send:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-send svg { width: 0.9rem; height: 0.9rem; }
.btn-use-number {
  width: 100%;
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: 1px solid #222;
  background: #111;
  font-size: 0.7rem;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-use-number:hover { color: #888; border-color: #333; }

/* ── FORWARD SECTIONS ── */
.send-section-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.15rem;
}
.send-section-desc {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}
.forward-section {
  border-top: 1px solid var(--border);
  padding-top: 0.7rem;
  margin-top: 0.1rem;
}
.forward-row {
  display: flex;
  gap: 0.4rem;
  align-items: center;
  flex-wrap: wrap;
}
.forward-input { flex: 1; min-width: 100px; margin-bottom: 0 !important; }
.btn-forward {
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 0.4rem;
  padding: 0.4rem 0.6rem;
  font-size: 0.65rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s;
}
.btn-forward:hover { background: #1d4ed8; }
.btn-forward:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-forward-off {
  background: #374151;
  color: #9ca3af;
  border: none;
  border-radius: 0.4rem;
  padding: 0.4rem 0.6rem;
  font-size: 0.65rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s;
}
.btn-forward-off:hover { background: #4b5563; color: #f3f4f6; }




/* ──────────────────────────────────────────────────────────────────────────
   YANDEX PANEL — FINAL FIXED CSS (PART 4/5)
   Bot tab: status bar, config, directions, log, controls + animations
────────────────────────────────────────────────────────────────────────── */

/* ── BOT TAB ── */
.bot-section { display: flex; flex-direction: column; gap: 0; }
.bot-status-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.2rem;
  background: #0a0a0a;
  border-bottom: 1px solid #1a1a1a;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
}
.bot-status-dot {
  width: 0.45rem; height: 0.45rem;
  border-radius: 50%;
  background: #374151;
  transition: background 0.3s, box-shadow 0.3s;
  flex-shrink: 0;
}
.bot-status-dot.online {
  background: #22c55e;
  box-shadow: 0 0 8px rgba(34,197,94,0.6);
  animation: pulseDot 2s infinite;
}
@keyframes pulseDot {
  0%,100% { box-shadow: 0 0 6px rgba(34,197,94,0.4); }
  50%      { box-shadow: 0 0 14px rgba(34,197,94,0.8); }
}
.bot-status-count {
  margin-left: auto;
  font-size: 0.6rem;
  color: var(--text-faint);
  background: #1a1a1a;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
}
.bot-config-block { padding: 0.8rem 1.2rem; border-bottom: 1px solid #1a1a1a; }
.bot-field { margin-top: 0.7rem; }
.bot-hint { font-size: 0.6rem; color: var(--text-faint); margin-top: 0.15rem; }
.bot-directions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.7rem 1.2rem;
  border-bottom: 1px solid #1a1a1a;
}
.bot-dir-card {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.6rem;
  background: #111;
  border: 1px solid #1f1f1f;
  border-radius: 0.6rem;
}
.bot-dir-icon { font-size: 1.2rem; flex-shrink: 0; line-height: 1; margin-top: 0.05rem; }
.bot-dir-title { font-size: 0.7rem; font-weight: 700; color: var(--text); margin-bottom: 0.15rem; }
.bot-dir-desc { font-size: 0.65rem; color: var(--text-muted); line-height: 1.5; }
.bot-dir-desc code {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 0.2rem;
  padding: 0.05rem 0.3rem;
  font-family: monospace;
  font-size: 0.6rem;
  color: #60a5fa;
}
.bot-log-wrap { padding: 0.7rem 1.2rem; border-bottom: 1px solid #1a1a1a; }
.bot-log-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.3rem;
}
.bot-log-clear {
  font-size: 0.55rem;
  color: var(--text-faint);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.1rem 0.3rem;
  border-radius: 0.2rem;
  transition: color 0.15s;
}
.bot-log-clear:hover { color: #f87171; }
.bot-log {
  background: #060606;
  border: 1px solid #1a1a1a;
  border-radius: 0.4rem;
  padding: 0.5rem;
  max-height: 8rem;
  overflow-y: auto;
  font-size: 0.6rem;
  font-family: monospace;
  line-height: 1.5;
}
.bot-log-empty { color: var(--text-faint); font-style: italic; }
.bot-log-entry { color: #ccc; border-bottom: 1px solid #111; padding: 0.1rem 0; }
.bot-log-entry .log-time { color: var(--text-faint); }
.bot-log-entry .log-ok { color: #4ade80; }
.bot-log-entry .log-err { color: #f87171; }
.bot-log-entry .log-info { color: #60a5fa; }
.bot-log-entry .log-fwd { color: #c084fc; }
.bot-controls {
  display: flex;
  gap: 0.5rem;
  padding: 0.8rem 1.2rem;
}
.bot-btn-start {
  flex: 1;
  padding: 0.5rem;
  border-radius: 0.4rem;
  border: none;
  background: #16a34a;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
}
.bot-btn-start:hover { background: #15803d; }
.bot-btn-start.running { background: #dc2626; }
.bot-btn-start.running:hover { background: #b91c1c; }
.bot-btn-save {
  padding: 0.5rem 0.7rem;
  border-radius: 0.4rem;
  border: 1px solid #333;
  background: #1a1a1a;
  color: var(--text-muted);
  font-size: 0.65rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}
.bot-btn-save:hover { background: #222; color: var(--text); }

/* ── ANIMATIONS ── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes glint {
  0%, 100% { transform: scale(1); opacity: 0; }
  50% { transform: scale(1.5); opacity: 1; }
}



/* ──────────────────────────────────────────────────────────────────────────
   YANDEX PANEL — FINAL FIXED CSS (PART 5/5)
   Responsive media queries for desktop, tablet, mobile
────────────────────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .stats-bar-inner { flex-direction: column; padding: 0; }
  .stats-group { padding: 0.4rem 0.6rem; }
  .stat-item { padding: 0 0.6rem; }
  .stat-value { font-size: 1rem; }
  .filters-group { padding: 0.4rem 0.6rem; gap: 0.3rem; }
  .filter-btn { font-size: 0.6rem; padding: 0.25rem 0.5rem; }
  .sort-select { font-size: 0.6rem; padding: 0.2rem 0.3rem; }
  .btn-refresh { padding: 0.3rem; }
  .btn-refresh svg { width: 0.7rem; height: 0.7rem; }
  .dash-header-inner { padding: 0.4rem 0.6rem; gap: 0.5rem; }
  .logo-text { font-size: 1rem; }
  .logo-icon { width: 1.5rem; height: 1.5rem; }
  .logo-icon svg { width: 0.7rem; height: 0.7rem; }
  .search-wrap { flex: 1 1 100px; max-width: 140px; }
  .search-input { font-size: 0.7rem; padding: 0.3rem 0.5rem 0.3rem 1.6rem; }
  .connected-badge span { font-size: 0.6rem; }
  .clock-badge { display: none; }
  .btn-logout { font-size: 0.6rem; padding: 0.25rem 0.5rem; }
  .btn-logout span { display: none; }
  .btn-logout svg { width: 0.7rem; height: 0.7rem; }
  .dash-main { padding: 0.5rem; }
  .cards-grid { gap: 0.6rem; }
  .device-card { padding: 0.7rem; }

  #detail-overlay { align-items: flex-end; }
  .detail-backdrop { display: none; }
  .detail-panel {
    max-width: 100% !important;
    width: 100% !important;
    height: 92vh !important;
    border-left: none;
    border-top: 1px solid #1f1f1f;
    border-radius: 1.2rem 1.2rem 0 0;
    animation: slideInUp 0.28s cubic-bezier(.32,.72,0,1) !important;
  }
  @keyframes slideInUp {
    from { transform: translateY(100%); }
    to   { transform: translateY(0); }
  }
  .detail-header { padding: 0.6rem 0.8rem; }
  .detail-name { font-size: 0.8rem; }
  .detail-id { font-size: 0.55rem; }
  .detail-status-bar { padding: 0.3rem 0.8rem; gap: 0.4rem; overflow-x: auto; flex-wrap: nowrap; }
  .detail-status-item { font-size: 0.65rem; }
  .detail-tabs { padding: 0 0.2rem; }
  .tab-btn { padding: 0.4rem 0.5rem; font-size: 0.6rem; }
  .info-section { padding: 0.6rem 0.8rem; }
  .info-row { padding: 0.35rem 0; }
  .info-row-label { font-size: 0.6rem; width: 5rem; }
  .info-row-value { font-size: 0.6rem; }
  .bank-list, .sms-list { padding: 0.4rem 0.6rem; }
  .bank-item { padding: 0.5rem; }
  .bank-item-name { font-size: 0.7rem; }
  .bank-item-bal { font-size: 1rem; }
  .card-item { padding: 0.5rem; }
  .card-item-type { font-size: 0.7rem; }
  .card-item-number { font-size: 0.7rem; }
  .sms-item { padding: 0.5rem; }
  .sms-sender { font-size: 0.65rem; }
  .sms-text { font-size: 0.65rem; }
  .send-section { padding: 0.5rem 0.8rem; gap: 0.5rem; }
  .sim-btn { font-size: 0.65rem; padding: 0.35rem; }
  .send-input, .send-textarea { font-size: 0.65rem; padding: 0.4rem 0.6rem; }
  .btn-send { font-size: 0.65rem; padding: 0.5rem; }
  .bot-config-block { padding: 0.5rem 0.8rem; }
  .bot-log-wrap { padding: 0.5rem 0.8rem; }
  .bot-controls { padding: 0.5rem 0.8rem; flex-wrap: wrap; }
  .bot-btn-start { flex: 1 1 100%; }
  .bot-btn-save { flex: 1 1 100%; }
  .forward-row { flex-wrap: wrap; }
  .forward-input { flex: 1 1 100%; }
  .btn-forward, .btn-forward-off { flex: 1; justify-content: center; }
}

@media (max-width: 480px) {
  .detail-panel { height: 95vh !important; }
  .tab-btn { padding: 0.3rem 0.4rem; font-size: 0.55rem; }
  .detail-name { font-size: 0.7rem; }
  .detail-id { font-size: 0.5rem; }
  .detail-bank-badge, .detail-card-badge, .detail-upi-badge { font-size: 0.55rem; padding: 0.05rem 0.35rem; }
  .card-name { font-size: 0.7rem; }
  .card-id { font-size: 0.5rem; }
  .stat-value { font-size: 0.9rem; }
  .filter-btn { font-size: 0.55rem; padding: 0.2rem 0.4rem; }
}