/* =========================================================
     KeSCO Hub — aligned to newindex.css theme (nav/footer/bg)
     Uses your base vars: --blue, --blue2, --red, --radius,
     --radius2, --shadow, --shadow2, --muted, --padX
     ========================================================= */

  .hub-wrap{
    position: relative;
    z-index: 10;
    padding: 18px var(--padX) 28px;
  }

  /* page shell (same feel as hero-card) */
  .hub-shell{
    width:100%;
    border-radius: calc(var(--radius) + 4px);
    background: linear-gradient(180deg, rgba(255,255,255,.72), rgba(255,255,255,.50));
    border: 1px solid rgba(15,23,42,.12);
    box-shadow: var(--shadow);
    backdrop-filter: blur(12px);
    overflow:hidden;
    position:relative;
  }
  .hub-shell:before{
    content:"";
    position:absolute; inset:-40% -20%;
    background:
      radial-gradient(circle at 18% 28%, rgba(21,120,190,.18), transparent 56%),
      radial-gradient(circle at 78% 30%, rgba(212,0,0,.10), transparent 56%),
      radial-gradient(circle at 62% 85%, rgba(4,64,124,.12), transparent 58%);
    transform: rotate(10deg);
    opacity:.92;
    pointer-events:none;
  }
  .hub-shell > *{ position:relative; }

  .hub-head{
    padding: 16px 16px 12px;
    border-bottom: 1px solid rgba(15,23,42,.08);
  }
  @media(min-width:768px){
    .hub-head{ padding: 20px 22px 14px; }
  }

  .hub-title{
    font-weight: 1100;
    font-size: clamp(1.15rem, 1.4vw, 1.55rem);
    margin: 10px 0 4px;
    letter-spacing: -.03em;
    color: rgba(11,18,32,.96);
    line-height: 1.1;
  }

  .hub-sub{
    margin: 0;
    color: var(--muted);
    font-weight: 800;
    line-height: 1.45;
    font-size: .95rem;
  }

  /* top-right tag */
  .tag{
    padding: .22rem .55rem;
    font-size: .78rem;
    border-radius: 999px;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.52);
    white-space: nowrap;
    font-weight: 1000;
    color: rgba(11,18,32,.82);
  }
  .code-pill{
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-weight: 1100;
  }

  /* controls */
  .hub-controls{
    margin-top: 10px;
  }

  .input-compact{
    padding: .55rem .8rem;
    border-radius: 14px;
    border: 1px solid rgba(15,23,42,.12);
    background: rgba(255,255,255,.62);
    box-shadow: 0 10px 24px rgba(2,10,28,.08);
  }
  .input-compact:focus{
    outline: none;
    box-shadow: var(--ring);
    border-color: rgba(21,120,190,.22);
    background: rgba(255,255,255,.72);
  }

  /* use your themed buttons, but slightly smaller */
  .btn-compact{
    padding: .52rem .86rem !important;
    border-radius: 999px !important;
    font-size: .9rem;
    font-weight: 1000 !important;
    line-height: 1.15;
  }

  /* panels */
  .panel{
    border-radius: var(--radius);
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.55);
    box-shadow: var(--shadow2);
    overflow:hidden;
    position:relative;
  }

  .panel-hd{
    padding: 10px 12px;
    border-bottom: 1px solid rgba(15,23,42,.08);
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap: 10px;
  }

  .panel-hd strong{
    font-weight: 1100;
    letter-spacing: -.02em;
    color: rgba(11,18,32,.94);
  }

  .panel-bd{
    padding: 10px 12px 12px;
  }

  /* scrolling areas */
  .results-wrap{
    max-height: 470px;
    overflow:auto;
    border-radius: 16px;
    border: 1px solid rgba(15,23,42,.08);
    background: rgba(255,255,255,.62);
  }
  .selected-wrap{
    max-height: 280px;
    overflow:auto;
    border-radius: 16px;
    border: 1px solid rgba(15,23,42,.08);
    background: rgba(255,255,255,.62);
  }

  /* tables */
  .table thead th{
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    background: rgba(255,255,255,.82);
    padding: .46rem .55rem;
    position: sticky;
    top: 0;
    z-index: 2;
    border-bottom: 1px solid rgba(15,23,42,.08);
  }
  .table tbody td{
    padding: .42rem .55rem;
    vertical-align: middle;
    border-color: rgba(15,23,42,.08);
  }
  .table-hover tbody tr:hover{
    background: rgba(21,120,190,.08);
  }

  /* Occupation cell */
  .occ-cell{
    display:flex;
    justify-content:space-between;
    gap: .65rem;
    align-items:flex-start;
  }
  .occ-title{
    font-weight: 1100;
    line-height: 1.15;
    color: rgba(11,18,32,.94);
  }
  .occ-meta{
    font-size: .82rem;
    color: rgba(11,18,32,.68);
    margin-top: .12rem;
    font-weight: 800;
  }
  .btn-view{
    padding: .42rem .7rem !important;
    border-radius: 999px !important;
    font-size: .82rem !important;
    font-weight: 1000 !important;
    white-space: nowrap;
  }

  /* details (right) */
  .sticky-panel{ position: sticky; top: 12px; }

  .right-panel label{
    color: rgba(11,18,32,.62);
    font-weight: 1000;
    font-size: .76rem;
    letter-spacing:.10em;
    text-transform: uppercase;
    margin-bottom: 6px;
  }
  .right-panel input,
  .right-panel textarea{
    background: rgba(255,255,255,.62);
    border: 1px solid rgba(15,23,42,.12);
    border-radius: 14px;
    padding: .5rem .65rem;
    font-weight: 800;
  }
  .right-panel textarea{ min-height: 120px; resize: vertical; }

  .muted-sm{ color: rgba(11,18,32,.70); font-weight: 800; font-size: .92rem; }
  .muted-xs{ color: rgba(11,18,32,.66); font-weight: 800; font-size: .82rem; }

  /* footer-like action row */
  .actions{
    display:flex;
    justify-content:center;
    gap: 10px;
    flex-wrap:wrap;
    margin-top: 10px;
  }

  /* toast */
  .toast-fixed{
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1080;
    max-width: 420px;
  }

  @media (max-width: 991.98px){
    .sticky-panel{ position: static; }
  }