/* ===== Boujie dashboard styling (no JS, no extra packages) ===== */

html, body { height: 100%; }

body{
  background:
    radial-gradient(900px 520px at 10% 0%, rgba(181, 134, 255, 0.18), transparent 55%),
    radial-gradient(900px 520px at 90% 10%, rgba(0, 212, 255, 0.14), transparent 55%),
    radial-gradient(1000px 700px at 55% 110%, rgba(255, 199, 0, 0.10), transparent 55%),
    #f6f7fb !important;
}

/* Hero */
.app-hero{
  padding: 20px 18px 8px 18px;
}
.hero-inner{
  border-radius: 22px;
  padding: 18px 18px;
  border: 1px solid rgba(15,23,42,0.08);
  background: rgba(255,255,255,0.80);
  box-shadow: 0 18px 45px rgba(15,23,42,0.08);
  backdrop-filter: blur(10px);
}
.hero-title{
  font-size: 46px;
  font-weight: 900;
  letter-spacing: -0.03em;
  margin: 0;
}
.hero-sub{
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 10px;
}
.hero-pill{
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 13px;
  border: 1px solid rgba(15,23,42,0.12);
  background: rgba(255,255,255,0.85);
}
.hero-muted{
  color: rgba(15,23,42,0.55);
  font-weight: 600;
}

/* Sidebar glass */
.sidebar-glass{
  border-radius: 22px;
  border: 1px solid rgba(15,23,42,0.08);
  background: rgba(255,255,255,0.82);
  box-shadow: 0 18px 45px rgba(15,23,42,0.08);
  backdrop-filter: blur(10px);
  padding: 14px;
}
.sidebar-title{
  margin-bottom: 10px;
}
.sidebar-title-text{
  font-weight: 900;
  letter-spacing: -0.02em;
}
.sidebar-actions{
  margin-top: 10px;
}

/* Cards */
.card-glass{
  border-radius: 22px !important;
  border: 1px solid rgba(15,23,42,0.08) !important;
  background: rgba(255,255,255,0.84) !important;
  box-shadow: 0 18px 45px rgba(15,23,42,0.08) !important;
  backdrop-filter: blur(10px);
  overflow: hidden;
}

/* KPI */
.kpi { padding: 16px; }
.kpi-label{
  font-weight: 800;
  color: rgba(15,23,42,0.70);
  margin-bottom: 6px;
}
.kpi-value{
  font-size: 40px;
  font-weight: 950;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.kpi-foot{
  margin-top: 6px;
  color: rgba(15,23,42,0.55);
  font-weight: 600;
}

/* Card titles */
.card-title-row{
  display:flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 14px 16px 8px 16px;
}
.card-title{
  font-weight: 900;
  letter-spacing: -0.02em;
  padding: 14px 16px 8px 16px;
}
.card-hint{
  color: rgba(15,23,42,0.55);
  font-weight: 600;
  padding-right: 16px;
}

.kpi-sub {
  margin: 6px 16px 12px 16px;
  color: #cca300;
  font-weight: 600;
  font-size: 12px;
  line-height: 1.35;
}

/* =========================================
   PLACEHOLDER (WHEN NO DATA SELECTED)
   ========================================= */
.placeholder-glass {
  margin: 6px 16px 16px 16px;
  padding: 22px;
  border-radius: 18px;
  border: 1px dashed rgba(15,23,42,0.18);
  background: rgba(249,250,251,0.65);
  color: rgba(15,23,42,0.55);
  font-weight: 650;
}

/* Make fill page breathe */
.bslib-page-fill { padding: 10px 16px 20px 16px; }

/* Inputs polish */
.selectize-control.multi .selectize-input{
  border-radius: 14px !important;
  border: 1px solid rgba(15,23,42,0.14) !important;
  box-shadow: none !important;
}
.selectize-control.multi .selectize-input.focus{
  border-color: rgba(17,17,17,0.55) !important;
  box-shadow: 0 0 0 0.18rem rgba(17,17,17,0.10) !important;
}

.btn{ border-radius: 14px !important; font-weight: 800 !important; }

/* Prevent Altair chart cross-contamination */
.altair-map,
.altair-chart {
    display: block;
    width: 100%;
    overflow: hidden;
}

/* Ensure each Altair embed is isolated */
.altair-map > div,
.altair-chart > div {
    width: 100% !important;
    height: auto !important;
}

/* Add spacing between dashboard rows */
.shiny-layout-columns {
  margin-bottom: 18px;
}

/* Add spacing between cards */
.card {
  margin-bottom: 16px;
}