@font-face {
  font-family: 'Exo';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/exo-latin.woff2') format('woff2');
}

:root {
  color-scheme: light;
  --font-main: 'Exo', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --ink: #14264A;
  --ink-muted: #536485;
  --navy: #0B1235;
  --teal: #2DD4BF;
  --teal-dark: #0F766E;
  --cyan: #22D3EE;
  --purple: #A855F7;
  --pink: #D4007A;
  --blue: #3F63C8;
  --glass-bg: linear-gradient(135deg, rgba(255,255,255,.88), rgba(255,255,255,.55));
  --glass-border: rgba(255,255,255,.95);
  --glass-shadow: 0 10px 40px rgba(20,60,70,.10), 0 0 34px rgba(45,212,191,.25);
  --grad-primary: linear-gradient(90deg, #3F63C8, #A21CE0, #D4007A);
  --grad-text: linear-gradient(90deg, #0F766E, #3F63C8, #A21CE0);
}

* { box-sizing: border-box; }
html { width: 100%; }
body {
  margin: 0;
  font-family: var(--font-main);
  color: var(--ink);
  background: radial-gradient(ellipse 50% 12% at 15% 100%,rgba(94,234,212,.30),transparent),
              radial-gradient(ellipse 50% 12% at 50% 100%,rgba(125,211,252,.28),transparent),
              radial-gradient(ellipse 50% 12% at 85% 100%,rgba(94,234,212,.30),transparent),
              radial-gradient(circle at 88% 6%,rgba(94,234,212,.22),transparent 32%),
              radial-gradient(circle at 8% 22%,rgba(125,211,252,.18),transparent 32%),
              linear-gradient(180deg,#FFFEFA 0%,#FBF7EC 50%,#EEF9F5 100%);
  background-attachment: fixed;
  min-height: 100vh;
}

button { font: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  top: -60px;
  left: 20px;
  z-index: 100;
  padding: 12px 18px;
  background: #fff;
  color: var(--ink);
  font-weight: 700;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.2);
  transition: top .2s;
}
.skip-link:focus { top: 16px; }

/* Shell Layout */
.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
}

/* Sidebar V1 */
.sidebar {
  background: var(--navy);
  color: #fff;
  display: flex;
  flex-direction: column;
  height: 100vh;
  position: sticky;
  top: 0;
  overflow-y: auto;
  box-shadow: 0 8px 30px rgba(45,212,191,.35);
  border-right: 1px solid rgba(45,212,191,.4);
  z-index: 30;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 24px 20px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.brand-logo {
  height: 38px;
  width: auto;
  display: block;
}
.brand-text strong {
  display: block;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -.02em;
}
.brand-text small {
  display: block;
  color: var(--teal);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .25em;
  margin-top: 2px;
}

.sidebar-caption {
  padding: 18px 20px 10px;
  color: rgba(255,255,255,.5);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .18em;
}

#navigation {
  display: grid;
  gap: 5px;
  padding: 0 12px 20px;
}

.nav-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0;
  border-radius: 14px;
  padding: 12px 14px;
  color: rgba(255,255,255,.8);
  background: transparent;
  text-align: left;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all .15s ease;
}
.nav-item:hover {
  background: rgba(255,255,255,.1);
  color: #fff;
}
.nav-item[aria-current="page"] {
  background: var(--grad-primary);
  color: #fff;
  box-shadow: 0 0 20px rgba(45,212,191,.5);
}
.nav-icon {
  font-size: 16px;
  width: 20px;
  text-align: center;
  flex: none;
}

.sidebar-foot {
  margin-top: auto;
  padding: 18px 20px;
  border-top: 1px solid rgba(255,255,255,.08);
  background: rgba(0,0,0,.2);
}
.sidebar-foot p {
  color: rgba(255,255,255,.55);
  font-size: 11px;
  line-height: 1.5;
  margin: 8px 0 0;
}
.instance-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
}
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #64748b;
}
.status-dot.connected {
  background: var(--teal);
  box-shadow: 0 0 10px var(--teal);
}

/* Workspace & Topbar */
.workspace {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.topbar {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 36px;
  background: rgba(255,255,255,.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(15,157,147,.25);
  position: sticky;
  top: 0;
  z-index: 20;
}

.crumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-muted);
}
.crumb strong {
  color: var(--ink);
  font-weight: 700;
}
.crumb-separator { color: rgba(20,38,74,.3); }

.topbar-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.environment-badge {
  border: 1px solid rgba(15,157,147,.3);
  background: rgba(45,212,191,.15);
  color: var(--teal-dark);
  padding: 6px 12px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
}
.auth-button {
  background: var(--grad-primary);
  color: #fff;
  border: 0;
  border-radius: 12px;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 0 16px rgba(45,212,191,.4);
}
.user-badge {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: var(--navy);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(11,18,53,.2);
}
.menu-button {
  display: none;
  background: transparent;
  border: 0;
  font-size: 24px;
  color: var(--ink);
  cursor: pointer;
}

/* Main Content */
main {
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  padding: 32px 36px 60px;
}

.notice {
  display: none;
  padding: 16px 20px;
  border: 1px solid rgba(245,158,11,.4);
  border-radius: 16px;
  background: rgba(254,243,199,.9);
  color: #92400e;
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 24px;
}
.notice.visible { display: block; }

/* Page Header V1 */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 28px;
}
.eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--teal-dark);
}
h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 700;
  line-height: 1.15;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lead {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-muted);
  max-width: 800px;
}
.date-line {
  font-size: 12px;
  color: var(--ink-muted);
  white-space: nowrap;
}

/* Hero V1 */
.hero {
  background-image: linear-gradient(135deg, rgba(168,85,247,.85), rgba(244,114,182,.65), rgba(45,212,191,.75), rgba(163,230,53,.4)),
                    linear-gradient(rgba(255,255,255,.25) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255,255,255,.25) 1px, transparent 1px);
  background-size: 100% 100%, 44px 44px, 44px 44px;
  border: 1px solid rgba(255,255,255,.95);
  border-radius: 28px;
  padding: 36px 44px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 28px;
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.hero-content {
  flex: 1;
  min-width: 280px;
}
.hero-content h2 {
  margin: 0 0 12px;
  font-size: clamp(24px, 2.5vw, 36px);
  line-height: 1.15;
  font-weight: 700;
  text-shadow: 0 2px 14px rgba(11,18,53,.4);
}
.hero-content p {
  margin: 0 0 20px;
  font-size: 15px;
  line-height: 1.6;
  max-width: 600px;
  text-shadow: 0 1px 8px rgba(11,18,53,.4);
}
.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.hero-orb {
  background: conic-gradient(#2DD4BF,#22D3EE,#A855F7,#F472B6,#A3E635,#2DD4BF);
  border-radius: 50%;
  box-shadow: 0 0 70px rgba(45,212,191,.7), 0 40px 60px -10px rgba(34,211,238,.5);
  width: 140px;
  height: 140px;
  flex: none;
}

/* Glassmorphism Panel V1 */
.panel {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  margin-bottom: 24px;
  overflow: hidden;
}
.panel-heading {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid rgba(20,38,74,.1);
}
.panel-heading h2, .panel-heading h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
}
.panel-heading span {
  font-size: 12px;
  color: var(--ink-muted);
}
.panel-body {
  padding: 22px 24px;
}

/* Stats Cards V1 */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}
.stat-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 22px;
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
}
.stat-card .label {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-muted);
  margin-bottom: 8px;
}
.stat-card .value {
  font-size: 32px;
  font-weight: 700;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.1;
}
.stat-card .detail {
  font-size: 11px;
  color: var(--teal-dark);
  font-weight: 600;
  margin-top: 8px;
}

/* Section Grid */
.section-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(320px, 1fr);
  gap: 24px;
  align-items: start;
}

/* Buttons */
.btn-primary {
  background: var(--grad-primary);
  color: #fff;
  border: 0;
  border-radius: 14px;
  padding: 12px 24px;
  font: 600 14px var(--font-main);
  min-height: 44px;
  cursor: pointer;
  box-shadow: 0 0 22px rgba(45,212,191,.5);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: transform .1s ease, box-shadow .15s ease;
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 28px rgba(45,212,191,.7);
}
.btn-primary:disabled {
  opacity: .55;
  cursor: wait;
}

.btn-secondary {
  background: rgba(255,255,255,.8);
  color: var(--ink);
  border: 1px solid rgba(15,157,147,.5);
  border-radius: 14px;
  padding: 12px 22px;
  font: 600 14px var(--font-main);
  min-height: 44px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: background .15s ease;
}
.btn-secondary:hover {
  background: rgba(255,255,255,1);
}

/* Assistance & Invite Cards */
.assistance-card {
  background: linear-gradient(135deg, rgba(255,255,255,.9), rgba(240,253,250,.75));
  border: 1px solid rgba(45,212,191,.5);
  border-radius: 24px;
  padding: 24px;
  display: flex;
  gap: 24px;
  align-items: center;
  flex-wrap: wrap;
  box-shadow: var(--glass-shadow);
  margin-bottom: 24px;
}
.assistance-qr {
  width: 110px;
  height: 110px;
  background: #fff;
  border: 2px solid var(--teal);
  border-radius: 18px;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 16px rgba(45,212,191,.3);
  flex: none;
  position: relative;
  overflow: hidden;
}
.qr-mock {
  width: 80px;
  height: 80px;
  background-image: repeating-linear-gradient(0deg, #0B1235 0px, #0B1235 8px, transparent 8px, transparent 16px),
                    repeating-linear-gradient(90deg, #0B1235 0px, #0B1235 8px, transparent 8px, transparent 16px);
  border-radius: 8px;
}
.assistance-content {
  flex: 1;
  min-width: 250px;
}
.assistance-content h3 {
  margin: 0 0 8px;
  font-size: 19px;
  color: var(--ink);
}
.assistance-content p {
  margin: 0 0 16px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink-muted);
}
.assistance-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* Organigramme Communication V1 */
.organigramme {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.org-human-node {
  background: linear-gradient(135deg, #0B1235, #1E293B);
  color: #fff;
  border-radius: 22px;
  padding: 22px 28px;
  box-shadow: 0 8px 30px rgba(11,18,53,.35);
  border: 1px solid rgba(45,212,191,.5);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.org-teams-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.org-team-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 20px;
  box-shadow: var(--glass-shadow);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.org-team-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.org-team-title {
  font-size: 15px;
  font-weight: 700;
  margin: 0;
  color: var(--ink);
}
.agent-pill-list {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.agent-pill {
  background: rgba(15,157,147,.12);
  color: var(--teal-dark);
  border: 1px solid rgba(15,157,147,.3);
  border-radius: 8px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
}

/* Forms & Inputs V1 */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-field.full {
  grid-column: 1 / -1;
}
.form-field label {
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
}
.form-field input, .form-field select, .form-field textarea {
  background: rgba(255,255,255,.9);
  border: 1px solid rgba(15,157,147,.35);
  border-radius: 14px;
  padding: 12px 14px;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  min-height: 44px;
  box-sizing: border-box;
}
.form-field textarea {
  min-height: 80px;
  resize: vertical;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 12px rgba(45,212,191,.4);
}

/* Dropzone & File Upload V1 */
.dropzone {
  border: 2px dashed rgba(15,157,147,.5);
  background: rgba(255,255,255,.6);
  border-radius: 20px;
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: all .2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.dropzone:hover, .dropzone.dragover {
  background: rgba(240,253,250,.9);
  border-color: var(--teal);
  box-shadow: 0 0 24px rgba(45,212,191,.35);
}
.dropzone-icon {
  font-size: 32px;
}
.dropzone-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}
.dropzone-sub {
  font-size: 12px;
  color: var(--ink-muted);
}
.file-preview-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #fff;
  border: 1px solid rgba(15,157,147,.3);
  border-radius: 14px;
  padding: 12px 16px;
  margin-top: 12px;
}
.hash-pill {
  font-family: monospace;
  font-size: 11px;
  background: rgba(0,0,0,.06);
  padding: 4px 8px;
  border-radius: 6px;
  word-break: break-all;
}

/* Module Grid */
.module-grid, .project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.module-card, .project-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 22px;
  padding: 22px;
  box-shadow: var(--glass-shadow);
  display: flex;
  flex-direction: column;
}
.module-card h3, .project-card h3 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}
.module-card p, .project-card p {
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--ink-muted);
}
.module-state {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  margin-top: 14px;
  align-self: flex-start;
  background: rgba(245,158,11,.15);
  color: #b45309;
}
.module-state.active {
  background: rgba(45,212,191,.2);
  color: #0F766E;
}

/* Table styles V1 */
.table-scroll { overflow-x: auto; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
th {
  text-align: left;
  padding: 12px 16px;
  font-size: 11px;
  font-weight: 700;
  color: var(--ink-muted);
  text-transform: uppercase;
  letter-spacing: .05em;
  border-bottom: 2px solid rgba(20,38,74,.1);
}
td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(20,38,74,.08);
  color: var(--ink);
}
tbody tr:hover td {
  background: rgba(255,255,255,.5);
}

/* Status Pills */
.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 99px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.pill.running, .pill.assigned { background: rgba(59,130,246,.15); color: #1E40AF; border: 1px solid #1E40AF40; }
.pill.review { background: rgba(245,158,11,.15); color: #B45309; border: 1px solid #B4530940; }
.pill.done, .pill.approved { background: rgba(45,212,191,.2); color: #0F766E; border: 1px solid #0F766E40; }
.pill.blocked, .pill.failed, .pill.rejected { background: rgba(239,68,68,.15); color: #B91C1C; border: 1px solid #B91C1C40; }
.pill.todo, .pill.cancelled { background: rgba(100,116,139,.15); color: #475569; border: 1px solid #47556940; }

/* Activity list */
.activity-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.activity-item {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(20,38,74,.08);
}
.activity-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 6px var(--teal);
  margin-top: 6px;
  flex: none;
}
.activity-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--ink);
}
.activity-time {
  display: block;
  font-size: 11px;
  color: var(--ink-muted);
  margin-top: 3px;
}

/* Info Strip */
.info-strip {
  margin-top: 24px;
  padding: 14px 20px;
  border-radius: 16px;
  background: rgba(240,253,250,.8);
  border: 1px solid rgba(45,212,191,.4);
  color: #0F766E;
  font-size: 12px;
  line-height: 1.6;
}

/* Empty State */
.empty {
  padding: 36px 20px;
  text-align: center;
  color: var(--ink-muted);
  font-size: 13px;
}
.empty-symbol {
  font-size: 28px;
  margin-bottom: 8px;
  color: var(--teal);
}

/* Responsive */
@media (max-width: 1180px) {
  .org-teams-grid, .module-grid, .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .section-grid { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
  .app-shell { grid-template-columns: minmax(0, 1fr); }
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: 270px;
    transform: translateX(-100%);
    transition: transform .25s ease;
  }
  .sidebar.open { transform: translateX(0); }
  .menu-button { display: block; }
  .topbar { padding: 0 20px; height: 64px; }
  main { padding: 20px 16px 40px; }
  .hero { padding: 24px 20px; flex-direction: column; align-items: flex-start; }
  .hero-orb { display: none; }
  .form-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .stat-grid, .org-teams-grid, .module-grid, .project-grid { grid-template-columns: 1fr; }
  .crumb > span:first-child, .crumb-separator { display: none; }
  .page-header { flex-direction: column; align-items: flex-start; gap: 8px; }
}

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

/* Device Management & Zero-Trust Styles */
.badge-zt-active {
  background: rgba(45, 212, 191, 0.15);
  border: 1px solid rgba(45, 212, 191, 0.5);
  color: #0F766E;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.key-box-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(11, 18, 53, 0.05);
  border: 1px solid rgba(15, 157, 147, 0.25);
  border-radius: 14px;
  padding: 12px 18px;
  margin-top: 18px;
  font-size: 13px;
}
.key-code {
  background: #0B1235;
  color: #2DD4BF;
  padding: 4px 8px;
  border-radius: 6px;
  font-family: monospace;
  font-size: 13px;
  margin-left: 6px;
}
.btn-mini {
  background: rgba(15, 118, 110, 0.12);
  border: 1px solid rgba(15, 118, 110, 0.3);
  color: #0F766E;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all .2s;
}
.btn-mini:hover {
  background: #0F766E;
  color: #fff;
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.data-table th {
  text-align: left;
  padding: 12px 14px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--ink-muted);
  border-bottom: 2px solid rgba(20, 38, 74, 0.1);
}
.data-table td {
  padding: 14px;
  border-bottom: 1px solid rgba(20, 38, 74, 0.06);
  vertical-align: middle;
}
.data-table tr:hover td {
  background: rgba(45, 212, 191, 0.05);
}
.current-device-row td {
  background: rgba(162, 28, 224, 0.05);
}
.device-name-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}
.badge-current {
  background: linear-gradient(90deg, #A21CE0, #D4007A);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
}
.code-cell {
  font-family: monospace;
  font-size: 12px;
  color: #0F766E;
}
.small-cell {
  font-size: 11px;
  color: var(--ink-muted);
}
.bold-cell {
  font-weight: 700;
}
.action-cell {
  display: flex;
  gap: 8px;
  align-items: center;
}
.btn-action {
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all .2s;
}
.btn-approve {
  background: rgba(15, 118, 110, 0.15);
  color: #0F766E;
  border: 1px solid rgba(15, 118, 110, 0.3);
}
.btn-approve:hover {
  background: #0F766E;
  color: #fff;
}
.btn-reject, .btn-revoke {
  background: rgba(212, 0, 122, 0.1);
  color: #D4007A;
  border: 1px solid rgba(212, 0, 122, 0.3);
}
.btn-reject:hover, .btn-revoke:hover {
  background: #D4007A;
  color: #fff;
}
.btn-delete {
  background: none;
  border: 1px solid rgba(0,0,0,0.1);
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 6px;
}
.btn-delete:hover {
  background: rgba(212,0,122,0.1);
  border-color: #D4007A;
}
.status-pill {
  display: inline-block;
  padding: 4px 9px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
}
.status-pill.status-authorized {
  background: rgba(45, 212, 191, 0.15);
  color: #0F766E;
  border: 1px solid rgba(45, 212, 191, 0.4);
}
.status-pill.status-pending {
  background: rgba(245, 158, 11, 0.15);
  color: #B45309;
  border: 1px solid rgba(245, 158, 11, 0.4);
}
.status-pill.status-revoked {
  background: rgba(212, 0, 122, 0.15);
  color: #D4007A;
  border: 1px solid rgba(212, 0, 122, 0.4);
}
.protected-label {
  font-size: 11px;
  color: var(--ink-muted);
  font-style: italic;
}
.panel-warning {
  border-color: rgba(245, 158, 11, 0.5);
  box-shadow: 0 10px 40px rgba(245, 158, 11, 0.15);
}
.enroll-result-box {
  background: rgba(240, 253, 250, 0.9);
  border: 1px solid rgba(45, 212, 191, 0.5);
  border-radius: 14px;
  padding: 16px;
  margin-top: 14px;
}
.enroll-result-box h4 {
  margin: 0 0 6px;
  color: #0F766E;
}
.enroll-result-box p {
  margin: 0 0 10px;
  font-size: 12px;
  color: var(--ink);
}
.link-wrap-flex {
  display: flex;
  gap: 8px;
}
.link-input {
  flex: 1;
  background: #fff;
  border: 1px solid rgba(15, 157, 147, 0.4);
  border-radius: 8px;
  padding: 8px 12px;
  font-family: monospace;
  font-size: 12px;
  color: #0F766E;
}

/* Alert Banner for pending devices */
.pending-device-banner {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(212, 0, 122, 0.12));
  border: 1px solid rgba(245, 158, 11, 0.6);
  border-radius: 18px;
  padding: 16px 20px;
  margin-bottom: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.2);
  animation: glow-banner 3s infinite alternate;
}
@keyframes glow-banner {
  from { box-shadow: 0 4px 20px rgba(245, 158, 11, 0.2); }
  to { box-shadow: 0 6px 28px rgba(245, 158, 11, 0.35); }
}
.pending-alert-info {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--ink);
  flex-wrap: wrap;
}
.pending-alert-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.pulse-dot-orange {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #F59E0B;
  box-shadow: 0 0 10px #F59E0B;
  animation: pulse-orange 1.5s infinite;
}
@keyframes pulse-orange {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}
.btn-banner-approve {
  background: #0F766E;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all .2s;
}
.btn-banner-approve:hover {
  background: #115E59;
  transform: translateY(-1px);
}
.btn-banner-reject {
  background: rgba(212, 0, 122, 0.15);
  color: #D4007A;
  border: 1px solid rgba(212, 0, 122, 0.4);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.btn-banner-reject:hover {
  background: #D4007A;
  color: #fff;
}
.btn-banner-link {
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
  text-decoration: underline;
  padding: 6px;
}
.nav-alert-badge {
  background: #F59E0B;
  color: #0B1235;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 10px;
  margin-left: auto;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.6);
  animation: pulse-badge 2s infinite;
}
@keyframes pulse-badge {
  0% { opacity: 0.85; }
  50% { opacity: 1; transform: scale(1.08); }
  100% { opacity: 0.85; }
}

/* Image Bank & Visual Gallery Styles */
.bank-filter-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 20px;
}
.bank-filter-btn {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(15, 157, 147, 0.25);
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  transition: all .15s ease;
}
.bank-filter-btn:hover {
  background: #fff;
  border-color: var(--teal);
  box-shadow: 0 2px 8px rgba(45, 212, 191, 0.2);
}
.bank-filter-btn.active {
  background: var(--grad-primary);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(162, 28, 224, 0.3);
}

.bank-img-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 22px;
}
.bank-img-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: var(--glass-shadow);
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease;
}
.bank-img-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 44px rgba(20, 60, 70, 0.15), 0 0 40px rgba(45, 212, 191, 0.35);
}
.bank-img-thumb-wrap {
  width: 100%;
  height: 190px;
  background: radial-gradient(circle, rgba(20, 38, 74, 0.06) 0%, rgba(20, 38, 74, 0.15) 100%), #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  border-bottom: 1px solid rgba(15, 157, 147, 0.15);
}
.bank-img-thumb {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform .25s ease;
}
.bank-img-thumb-wrap:hover .bank-img-thumb {
  transform: scale(1.04);
}
.bank-category-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(11, 18, 53, 0.82);
  backdrop-filter: blur(6px);
  color: var(--teal);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 12px;
  letter-spacing: 0.02em;
  border: 1px solid rgba(45, 212, 191, 0.3);
}
.bank-format-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(6px);
  color: var(--ink);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.bank-img-card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 10px;
}
.bank-img-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
}
.bank-tags-row {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}
.bank-tag {
  background: rgba(15, 118, 110, 0.08);
  color: var(--teal-dark);
  border-radius: 6px;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 600;
}
.bank-meta-details {
  font-size: 11px;
  color: var(--ink-muted);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.bank-sha256-row {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(11, 18, 53, 0.04);
  padding: 5px 8px;
  border-radius: 8px;
  font-family: monospace;
  font-size: 11px;
  color: var(--ink);
  cursor: pointer;
}
.bank-sha256-row:hover {
  background: rgba(45, 212, 191, 0.15);
}
.bank-sha256-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bank-card-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}
.btn-bank-action {
  flex: 1;
  padding: 7px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 10px;
  border: 1px solid rgba(15, 157, 147, 0.3);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  text-decoration: none;
  transition: all .15s ease;
}
.btn-bank-action:hover {
  background: rgba(240, 253, 250, 0.9);
  border-color: var(--teal);
  color: var(--teal-dark);
}
.btn-bank-action.danger {
  flex: none;
  border-color: rgba(212, 0, 122, 0.3);
  color: #D4007A;
}
.btn-bank-action.danger:hover {
  background: rgba(212, 0, 122, 0.1);
}


