/* Trimmed fork of Launcher-Shell/shared/shell.css — same design tokens
   for visual consistency across both properties, minus the picker/nav
   classes this single-portal site never uses (no Developer/Client choice
   here — nothing on this site should even hint that a picker exists). */
:root{
  --w-bg:#0f1117;
  --w-surface:#171a23;
  --w-surface-2:#1f2330;
  --w-border:#2a2f3d;
  --w-accent:#6f5bff;
  --w-accent-dim:#241f4d;
  --w-accent-2:#22d3ee;
  --w-text:#f5f6fa;
  --w-text-dim:#a8adba;
  --w-text-faint:#6b7280;
}

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

body{
  background:var(--w-bg); color:var(--w-text);
  font-family:'Segoe UI', Roboto, -apple-system, sans-serif;
  min-height:100vh;
}

.wibini-shell{min-height:100vh; display:flex; flex-direction:column;}

.wibini-header{
  display:flex; align-items:center; justify-content:space-between;
  gap:16px; padding:14px 20px; background:var(--w-surface);
  border-bottom:1px solid var(--w-border); flex-wrap:wrap;
}

.wibini-brand{display:flex; align-items:center; gap:10px;}

.wibini-mark{
  width:32px; height:32px; background:var(--w-accent);
  clip-path:polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  display:flex; align-items:center; justify-content:center;
  font-weight:900; font-size:14px; color:var(--w-bg);
}

.wibini-wordmark{font-size:17px; font-weight:800; letter-spacing:0.5px;}
.wibini-tagline{font-size:10.5px; color:var(--w-text-faint); text-transform:uppercase; letter-spacing:1px;}

.wibini-logout-btn{
  display:inline-flex; align-items:center; gap:6px;
  padding:9px 16px; border-radius:8px; font-size:13px; font-weight:700;
  color:var(--w-text-dim); background:var(--w-surface-2); border:1px solid var(--w-border);
  cursor:pointer; font-family:inherit;
}

.wibini-logout-btn:hover{color:var(--w-text); border-color:var(--w-accent);}

.wibini-body{flex:1; display:flex; width:100%; align-items:stretch;}

.wibini-main{
  flex:1; min-width:0; padding:32px 40px;
  max-width:1800px; width:100%; margin:0 auto;
}

/* Desktop-first card grid — as many columns as fit at >=260px each. */
.wibini-card-grid{
  display:grid; grid-template-columns:repeat(auto-fill, minmax(260px, 1fr));
  gap:20px;
}

.wibini-empty-state{
  text-align:center; padding:80px 20px; color:var(--w-text-faint);
  border:1.5px dashed var(--w-border); border-radius:14px;
}

.wibini-empty-state .icon{font-size:30px; margin-bottom:12px; opacity:0.6;}
.wibini-empty-state p{font-size:13px; max-width:360px; margin:0 auto;}

.wibini-page-header{margin-bottom:24px;}
.wibini-page-title{font-size:22px; font-weight:800;}
.wibini-page-subtitle{font-size:13px; color:var(--w-text-dim); margin-top:6px; max-width:560px; line-height:1.5;}

/* ---------------- APP LAUNCHER CARD ---------------- */
.wibini-app-card{
  display:flex; flex-direction:column; gap:14px;
  background:var(--w-surface); border:1px solid var(--w-border); border-radius:14px;
  padding:20px;
}

.wibini-app-card.is-disabled{opacity:0.6;}

.wibini-app-card-top{display:flex; align-items:flex-start; justify-content:space-between; gap:10px;}

.wibini-app-card-icon{
  width:44px; height:44px; flex:0 0 44px; border-radius:10px; background:var(--w-accent-dim);
  display:flex; align-items:center; justify-content:center; font-size:22px;
}

.wibini-app-card-status{
  font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:0.5px;
  padding:4px 9px; border-radius:6px; white-space:nowrap;
}
.wibini-app-card-status.status-live{background:rgba(34,211,238,0.15); color:var(--w-accent-2);}
.wibini-app-card-status.status-coming_soon{background:rgba(168,173,186,0.15); color:var(--w-text-dim);}
.wibini-app-card-status.status-maintenance{background:rgba(255,159,67,0.15); color:#ff9f43;}

.wibini-app-card-name{font-size:16px; font-weight:800;}
.wibini-app-card-desc{font-size:12.5px; color:var(--w-text-dim); line-height:1.5; margin-top:4px;}

.wibini-app-card-open{
  display:inline-flex; align-items:center; justify-content:center; gap:6px;
  padding:10px 14px; border-radius:8px; font-size:13px; font-weight:800;
  background:var(--w-accent); color:#fff; text-decoration:none; border:none; cursor:pointer;
  margin-top:auto;
}
.wibini-app-card-open:hover{filter:brightness(1.08);}
.wibini-app-card-open.disabled{
  background:var(--w-surface-2); color:var(--w-text-faint); cursor:not-allowed;
}

.wibini-footer{
  padding:14px 20px; text-align:center; font-size:11px; color:var(--w-text-faint);
  border-top:1px solid var(--w-border);
}

/* ---------------- AUTH GATE OVERLAY ---------------- *
 * Injected by shared/auth-guard.js on every gated page. The page itself
 * is hidden (body{visibility:hidden} set inline in that page's <head>)
 * until the guard confirms access; this overlay stays visible on top
 * (visibility:visible overrides the inherited hidden) to show loading /
 * error states in the meantime. */
.wibini-auth-gate{
  position:fixed; inset:0; z-index:1000; background:var(--w-bg);
  display:flex; align-items:center; justify-content:center;
}

.wibini-auth-gate-box{text-align:center; max-width:320px; padding:24px;}

.wibini-auth-gate-message{
  font-size:13.5px; color:var(--w-text-dim); line-height:1.6;
}

.wibini-auth-gate:not(.is-error) .wibini-auth-gate-message::before{
  content:""; display:block; margin:0 auto 16px; width:28px; height:28px;
  border-radius:50%; border:3px solid var(--w-border); border-top-color:var(--w-accent);
  animation:wibini-spin 0.8s linear infinite;
}

@keyframes wibini-spin{ to{ transform:rotate(360deg); } }

.wibini-auth-gate.is-error .wibini-auth-gate-message{color:var(--w-text);}

.wibini-auth-gate-actions{
  display:none; gap:10px; justify-content:center; margin-top:18px;
}

.wibini-auth-gate-btn{
  padding:9px 16px; border-radius:8px; font-size:13px; font-weight:700;
  background:var(--w-accent); color:#fff; border:none; cursor:pointer;
}

.wibini-auth-gate-btn-ghost{
  background:var(--w-surface-2); color:var(--w-text-dim); border:1px solid var(--w-border);
}

@media (max-width:720px){
  .wibini-main{padding:20px 16px;}
}
