/* Minimal app shell layer on top of your existing style.css */

.appShell {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

.sidebar {
  border-right: 1px solid var(--border);
  background: var(--surface);
}

.sidebarInner {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 100vh;
  position: sticky;
  top: 0;
}

.wsLabel {
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted2);
  font-size: 12px;
}

.wsName {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -0.01em;
  margin-top: 2px;
}

.sideNav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sideLink {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--border);
  background: var(--surface2);
  padding: 10px 12px;
  border-radius: 14px;
  text-decoration: none;
  color: var(--text);
}

.sideLink:hover { filter: brightness(.98); }
.sideLink.active { outline: 2px solid rgba(34,197,94,.18); }

.sideMeta {
  margin-top: auto;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.accountChip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  background: var(--surface2);
  padding: 8px 10px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--muted);
}

.mainPane { background: var(--bg); }

.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  position: sticky;
  top: 0;
  z-index: 5;
}

.topTitle {
  margin: 0;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.01em;
}

.topSub {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.mainContent {
  padding: 20px;
  max-width: 1100px;
}

.sectionTitle {
  margin: 0 0 10px 0;
  font-size: 16px;
  font-weight: 900;
}

.sectionSub {
  color: var(--muted);
  margin-bottom: 12px;
}

.listGrid { display: grid; gap: 10px; }

/* Device cards with score ring */
.deviceRow2{display:flex; align-items:center; justify-content:space-between; gap:18px;}
.deviceMeta{min-width:0;}
.deviceName{margin:0 0 6px 0; font-size:18px; letter-spacing:-0.01em;}
.deviceSub{color:var(--muted); font-size:13px;}

.pillRevoked{
  display:inline-block; margin-left:8px;
  padding:4px 10px; border-radius:999px;
  font-size:12px; font-weight:800;
  border:1px solid var(--border);
  background:var(--surface2); color:var(--muted);
}
.pillTag{
  display:inline-block; margin-left:8px;
  padding:4px 10px; border-radius:999px;
  font-size:12px; font-weight:800;
  border:1px solid var(--border);
  background:var(--surface2); color:var(--muted);
}

.btnTiny{padding:8px 10px; font-size:13px;}
.btnDanger{border-color: rgba(239,68,68,.35);}

.deviceRing{width:132px; height:132px; display:flex; align-items:center; justify-content:center; flex:0 0 auto;}
.ringSvg{width:122px; height:122px;}
.ringTrack{fill:none; stroke:rgba(15,23,42,.10); stroke-width:10;}
.ringValue{fill:none; stroke-width:10; stroke-linecap:round;}
.ringSvg.good .ringValue{stroke:#22c55e;}
.ringSvg.warn .ringValue{stroke:#f59e0b;}
.ringSvg.bad .ringValue{stroke:#ef4444;}
.ringSvg.unknown .ringValue{stroke:#94a3b8;}
.ringTextMain{font-size:22px; font-weight:800; fill:var(--text);}
.ringTextSub{font-size:10px; fill:var(--muted2);}
.ringPlaceholder{
  width:122px; height:122px; border-radius:18px; border:1px solid var(--border);
  background:var(--surface2); display:flex; align-items:center; justify-content:center;
  font-size:28px; font-weight:800; color:var(--muted2);
}

/* Drawer */
.drawerOverlay {
  position: fixed;
  inset: 0;
  background: rgba(2,6,23,.35);
  z-index: 50;
}
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: min(520px, 92vw);
  background: var(--surface);
  border-left: 1px solid var(--border);
  box-shadow: 0 20px 50px rgba(2,6,23,.25);
  padding: 18px;
  overflow: auto;
}
.drawerHeader {
  display:flex; align-items:flex-start; justify-content:space-between; gap:12px;
  padding-bottom: 12px; border-bottom: 1px solid var(--border);
}
.drawerTitle { margin: 0; font-size: 18px; font-weight: 900; }
.drawerClose { border: 1px solid var(--border); background: var(--surface2); padding: 8px 10px; border-radius: 12px; cursor: pointer; }
.drawerClose:hover { filter: brightness(.98); }

.historyBox { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); }
.historyRow { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:10px 0; border-bottom:1px solid var(--border); }
.historyRow:last-child { border-bottom: none; }
.historyTitle { font-weight: 900; font-size: 13px; }
.historySub { color: var(--muted); font-size: 12px; }
.historyScore { font-weight: 900; font-size: 18px; }

@media (max-width: 980px) {
  .appShell { grid-template-columns: 1fr; }
  .sidebar { border-right: none; border-bottom: 1px solid var(--border); }
  .sidebarInner { min-height: auto; position: relative; }
}

.pillGood{
  display:inline-block;
  padding:4px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  border:1px solid rgba(34,197,94,.35);
  background:rgba(34,197,94,.10);
  color:#16a34a;
}

.pillBad{
  display:inline-block;
  padding:4px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  border:1px solid rgba(239,68,68,.35);
  background:rgba(239,68,68,.10);
  color:#dc2626;
}

/* Workspace picker: keep menu on-screen + improve text */
.sidebar, .sidebarInner { overflow: visible; }

.wsPicker, .workspacePicker, #wsPicker { position: relative; }

.wsMenu, .workspaceMenu, .wsDropdownMenu, .workspaceDropdownMenu, #wsMenu, #workspaceMenu {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 80;
  margin-top: 8px;
  max-height: min(420px, calc(100vh - 220px));
  overflow-y: auto;
  overflow-x: hidden;
}

.wsMenu .card div[style*="font-weight"]:not(.wsOptionTitle),
.workspaceMenu .card div[style*="font-weight"]:not(.wsOptionTitle),
.wsDropdownMenu .card div[style*="font-weight"]:not(.wsOptionTitle),
.workspaceDropdownMenu .card div[style*="font-weight"]:not(.wsOptionTitle),
#wsMenu .card div[style*="font-weight"]:not(.wsOptionTitle),
#workspaceMenu .card div[style*="font-weight"]:not(.wsOptionTitle) {
  overflow: hidden;
  text-overflow: ellipsis;
}

.wsMenu .card div[style*="font-weight"],
.workspaceMenu .card div[style*="font-weight"],
.wsDropdownMenu .card div[style*="font-weight"],
.workspaceDropdownMenu .card div[style*="font-weight"],
#wsMenu .card div[style*="font-weight"],
#workspaceMenu .card div[style*="font-weight"] {
  font-size: 16px !important;
  line-height: 1.15 !important;
}

.wsMenu .small,
.workspaceMenu .small,
.wsDropdownMenu .small,
.workspaceDropdownMenu .small,
#wsMenu .small,
#workspaceMenu .small {
  font-size: 12px !important;
}

.wsMenu .card,
.workspaceMenu .card,
.wsDropdownMenu .card,
.workspaceDropdownMenu .card,
#wsMenu .card,
#workspaceMenu .card {
  padding: 10px 12px !important;
}

.wsOptionTitle{
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: normal;
  line-height: 1.15;
}
/* -----------------------------
   Integrations page: tiles + panels
   Add to: public/assets/app-shell.css
   ----------------------------- */

/* Slightly tighter main content rhythm */
.mainContent {
  padding-top: 10px;
}

/* Make topbar spacing feel more “app” */
.topbar {
  gap: 12px;
}

/* Tiles container */
#integrationTiles {
  margin-bottom: 16px;
}

/* Tile refinement: more “card” and less “website block” */
#integrationTiles .tile {
  padding: 14px 14px;
  border-radius: 18px;
  box-shadow: none;
  align-items: center; /* centers icon + text better */
}

/* Icon: reduce harshness, more consistent */
#integrationTiles .tileIcon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  font-size: 16px;
  background: rgba(2, 6, 23, .25);  /* slightly darker */
}

/* Title/subtitle typography: slightly smaller */
#integrationTiles .tileTitle {
  font-size: 14px;
  letter-spacing: .01em;
}

#integrationTiles .tileSub {
  font-size: 12px;
  line-height: 1.45;
}

/* Status pill alignment */
#integrationTiles .tileMetaRow {
  margin-top: 8px;
}

/* Panel cards: more breathing room + consistent borders */
#panel-entra .card,
#panel-okta .card {
  border-radius: 18px;
}

/* Reduce “tall rows” feel in forms */
#panel-entra .ctaRow,
#panel-okta .ctaRow {
  gap: 10px;
}

/* Inputs: small polish for long IDs/URLs */
#panel-entra input.input,
#panel-okta input.input {
  height: 42px;
  border-radius: 14px;
}

/* Codeboxes: stop them from feeling huge and blocky */
#panel-entra .codebox,
#panel-okta .codebox {
  border-radius: 14px;
  padding: 10px 12px;
}

/* Buttons: make tiny buttons look more consistent */
.btn.btnTiny {
  height: 36px;
  border-radius: 12px;
  padding: 8px 12px;
}

/* Lists: slightly tighter */
#panel-entra ol.small,
#panel-okta ol.small {
  margin-top: 10px;
  padding-left: 18px;
}

/* Make panel switching feel crisp (no layout jank) */
.panel {
  animation: fadeIn .12s ease-out;
}
@keyframes fadeIn {
  from { opacity: .6; transform: translateY(2px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Mobile: reduce tile padding and icon size */
@media (max-width: 640px) {
  #integrationTiles .tile { padding: 12px; }
  #integrationTiles .tileIcon { width: 38px; height: 38px; border-radius: 12px; }
}