/* ==========================================================================
   SIGAP — komponen tampilan per halaman
   ========================================================================== */

/* --------------------------------------------------------------------------
   Umum
   -------------------------------------------------------------------------- */

.section-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 18px; margin-bottom: 18px; flex-wrap: wrap;
}
.section-head h2 { font-size: 21px; line-height: 1.25; letter-spacing: -.025em; color: var(--navy-900); }
.section-head p { margin-top: 4px; font-size: 12.5px; color: var(--muted); max-width: 620px; line-height: 1.55; }
.section-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-xs);
}
.card-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 14px;
  padding: 17px 19px 12px;
}
.card-title { font-size: 14px; font-weight: 750; letter-spacing: -.01em; color: var(--navy-900); }
.card-sub { margin-top: 2px; font-size: 11.5px; color: var(--muted); }
.card-body { padding: 0 19px 18px; }
.card-link {
  display: inline-flex; align-items: center; gap: 4px;
  border: 0; background: none; color: var(--teal-700);
  font-size: 11.5px; font-weight: 700;
}
.card-link:hover { text-decoration: underline; }
.card-link .icon { width: 14px; height: 14px; }

.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 8px; border-radius: 999px;
  font-size: 10px; font-weight: 800; letter-spacing: .02em;
  background: var(--surface-3); color: var(--muted);
}
.status-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 9px; border-radius: 999px;
  font-size: 10.5px; font-weight: 750; white-space: nowrap;
}
.status-badge::before {
  content: ""; width: 6px; height: 6px; flex: none; border-radius: 50%;
  background: currentColor;
}
.status-draft { background: #eef1f6; color: #5c6b80; }
.status-terjadwal { background: #e9f1fe; color: #1d4ed8; }
.status-berlangsung { background: #fdf4dc; color: #a16207; }
.status-selesai { background: #e8f6ee; color: #157347; }
.status-dibatalkan { background: #fdeef0; color: #bd2f3b; }

.priority { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; font-weight: 650; color: var(--muted); }
.priority::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--muted-2); }
.priority-tinggi::before { background: #dc4a55; }
.priority-sedang::before { background: var(--gold-500); }
.priority-rendah::before { background: #8b9ab0; }

.role-badge {
  display: inline-flex; align-items: center; padding: 3px 8px;
  border-radius: 6px; font-size: 10px; font-weight: 800; letter-spacing: .03em;
  text-transform: uppercase;
}
.role-admin { background: #eaf0ff; color: #2447a8; }
.role-pimpinan { background: var(--gold-100); color: #7a5800; }
.role-staf { background: #eef1f6; color: #5c6b80; }

.demo-banner {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 14px; margin-bottom: 18px;
  border: 1px solid #f0dfb0; border-radius: 12px;
  background: linear-gradient(90deg, #fffaf0, #fdf6e3);
  color: #7a5300; font-size: 12.2px; line-height: 1.45;
}
.demo-banner .icon { color: var(--gold-600); flex: none; }
.demo-banner strong { font-weight: 800; }
.demo-banner .btn { margin-left: auto; flex: none; }
.demo-banner-close { flex: none; color: #9a7416; }

/* --------------------------------------------------------------------------
   Dashboard
   -------------------------------------------------------------------------- */

.hero {
  position: relative; overflow: hidden;
  display: flex; align-items: center; gap: 24px;
  padding: 27px 30px; border-radius: 22px;
  color: #fff; box-shadow: 0 18px 40px rgba(10, 32, 61, .16);
  background:
    radial-gradient(900px 500px at 92% -20%, rgba(20,184,166,.38), transparent 55%),
    radial-gradient(600px 400px at 100% 120%, rgba(217,165,33,.22), transparent 55%),
    linear-gradient(115deg, var(--navy-950), var(--navy-800) 58%, #0b4a55);
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image:
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(90deg, black, transparent 75%);
}
.hero::after {
  content: ""; position: absolute; width: 330px; height: 330px; right: -70px; top: -140px;
  border-radius: 50%; border: 1px solid rgba(243,212,138,.25);
  box-shadow: inset 0 0 80px rgba(20,184,166,.12); pointer-events: none;
}
.hero-copy { position: relative; z-index: 1; flex: 1; min-width: 0; }
.hero-eyebrow {
  display: flex; align-items: center; gap: 8px; margin-bottom: 7px;
  font-size: 10px; font-weight: 800; letter-spacing: .17em; text-transform: uppercase;
  color: var(--gold-300);
}
.hero-eyebrow::before { content: ""; width: 22px; height: 1px; background: rgba(243,212,138,.55); }
.hero h2 { font-size: clamp(22px, 2.2vw, 30px); line-height: 1.18; letter-spacing: -.03em; font-weight: 760; }
.hero h2 span { color: var(--gold-300); }
.hero p {
  margin-top: 8px; max-width: 620px;
  font-size: 12.7px; line-height: 1.6; color: rgba(226,235,247,.72);
}
.hero-actions { position: relative; z-index: 1; display: flex; align-items: center; gap: 9px; flex-wrap: wrap; flex: none; }
.btn-on-dark {
  --btn-bg: rgba(255,255,255,.09); --btn-color: #fff; --btn-border: rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
}
.btn-on-dark:hover { --btn-bg: rgba(255,255,255,.15); }
.btn-gold-solid {
  --btn-bg: linear-gradient(135deg, var(--gold-300), var(--gold-500));
  --btn-color: #2b1f00; --btn-border: transparent;
  box-shadow: 0 8px 20px rgba(217,165,33,.25);
}
.hero-art {
  position: absolute; right: 28px; bottom: -28px; z-index: 0;
  width: 190px; height: 190px; opacity: .07; color: #fff; pointer-events: none;
}
.hero-art .icon { width: 100%; height: 100%; stroke-width: .8; }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-top: 16px; }
.stat-card {
  position: relative; overflow: hidden;
  display: flex; align-items: flex-start; gap: 13px;
  padding: 16px 16px 15px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-xs); transition: .18s ease;
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); border-color: var(--line-strong); }
.stat-icon {
  display: grid; place-items: center; flex: none;
  width: 40px; height: 40px; border-radius: 11px;
  background: var(--teal-100); color: var(--teal-700);
}
.stat-icon .icon { width: 20px; height: 20px; }
.stat-icon-blue { background: #e9f1fe; color: #1d4ed8; }
.stat-icon-green { background: #e8f6ee; color: #157347; }
.stat-icon-gold { background: var(--gold-100); color: #a16f00; }
.stat-icon-red { background: var(--danger-bg); color: var(--danger); }
.stat-text { min-width: 0; flex: 1; }
.stat-label { font-size: 10.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.stat-value { margin-top: 2px; font-size: 27px; line-height: 1.1; font-weight: 780; letter-spacing: -.03em; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.stat-sub { margin-top: 3px; font-size: 10.5px; color: var(--muted-2); line-height: 1.35; }

.dash-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(310px, 1fr); gap: 15px; margin-top: 15px; align-items: start; }
.stack { display: flex; flex-direction: column; gap: 15px; }

.chart-bars { display: flex; align-items: stretch; gap: 7px; height: 188px; padding: 16px 2px 0; }
.chart-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; }
.chart-count { font-size: 10.5px; font-weight: 750; color: var(--text-soft); font-variant-numeric: tabular-nums; }
.chart-track { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; }
.chart-bar {
  width: min(34px, 66%); min-height: 4px; border-radius: 7px 7px 3px 3px;
  background: linear-gradient(180deg, #2dd4bf, var(--teal-700));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35);
  transition: height .5s cubic-bezier(.22,.8,.3,1);
}
.chart-col.today .chart-bar { background: linear-gradient(180deg, var(--gold-300), var(--gold-600)); }
.chart-col.today .chart-count { color: var(--gold-600); }
.chart-day { font-size: 9.5px; font-weight: 700; color: var(--muted-2); text-transform: uppercase; letter-spacing: .04em; }
.chart-col.today .chart-day { color: var(--text-soft); }
.chart-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 8px; padding-top: 11px; border-top: 1px solid var(--line);
  font-size: 10.8px; color: var(--muted);
}
.chart-total { display: flex; align-items: center; gap: 5px; }
.chart-total strong { color: var(--navy-900); font-size: 12px; }

.upcoming-list { display: flex; flex-direction: column; }
.agenda-mini {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 10px 7px; border-radius: 10px; border: 1px solid transparent;
  cursor: pointer; text-align: left; background: transparent; width: 100%;
  transition: .15s ease;
}
.agenda-mini + .agenda-mini { border-top: 1px solid #edf1f7; border-radius: 0; }
.agenda-mini:hover { background: var(--surface-2); border-color: transparent; }
.agenda-mini:first-child:hover { border-radius: 10px; }
.agenda-date {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  flex: none; width: 43px; height: 46px; border-radius: 10px;
  background: var(--surface-3); color: var(--navy-800); line-height: 1.05;
}
.agenda-date strong { font-size: 16px; font-weight: 800; }
.agenda-date span { font-size: 8.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.agenda-date.is-today { background: var(--gold-100); color: #8a6200; }
.agenda-date.is-today span { color: #a17a16; }
.agenda-mini-body { min-width: 0; flex: 1; }
.agenda-mini-title {
  font-size: 12.5px; font-weight: 700; color: var(--text); line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.agenda-mini-meta {
  display: flex; align-items: center; gap: 9px; flex-wrap: wrap;
  margin-top: 3px; font-size: 10.5px; color: var(--muted);
}
.agenda-mini-meta span { display: inline-flex; align-items: center; gap: 3px; }
.agenda-mini-meta .icon { width: 11px; height: 11px; }
.agenda-mini-right { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.agenda-mini-right .status-badge { font-size: 9.5px; padding: 2px 7px; }

.timeline { position: relative; display: flex; flex-direction: column; gap: 1px; }
.timeline-item { display: flex; gap: 11px; padding: 8px 0; position: relative; }
.timeline-time {
  flex: none; width: 44px; padding-top: 2px;
  font-size: 10.5px; font-weight: 800; color: var(--teal-700); font-variant-numeric: tabular-nums;
}
.timeline-line { position: relative; flex: none; width: 9px; display: flex; justify-content: center; }
.timeline-line::before { content: ""; position: absolute; top: 8px; bottom: -18px; width: 1px; background: var(--line); }
.timeline-item:last-child .timeline-line::before { display: none; }
.timeline-dot {
  position: relative; z-index: 1; width: 9px; height: 9px; margin-top: 5px;
  border-radius: 50%; background: var(--teal-500);
  box-shadow: 0 0 0 3px rgba(20,184,166,.14);
}
.timeline-dot.gold { background: var(--gold-500); box-shadow: 0 0 0 3px rgba(217,165,33,.16); }
.timeline-dot.gray { background: var(--muted-2); box-shadow: 0 0 0 3px rgba(139,154,176,.14); }
.timeline-body { min-width: 0; flex: 1; padding-bottom: 2px; }
.timeline-title { font-size: 12px; font-weight: 700; color: var(--text); line-height: 1.35; }
.timeline-meta { display: flex; align-items: center; gap: 7px; margin-top: 2px; font-size: 10.3px; color: var(--muted); }
.timeline-meta .icon { width: 11px; height: 11px; flex: none; }

.cat-bars { display: flex; flex-direction: column; gap: 11px; }
.cat-row { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: center; }
.cat-name { font-size: 11.5px; font-weight: 600; color: var(--text-soft); }
.cat-count { font-size: 11px; font-weight: 750; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.cat-track { grid-column: 1 / -1; height: 6px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.cat-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--teal-500), var(--teal-700)); transition: width .5s ease; }
.cat-fill.gold { background: linear-gradient(90deg, var(--gold-300), var(--gold-600)); }
.cat-fill.blue { background: linear-gradient(90deg, #60a5fa, #1d4ed8); }
.cat-fill.purple { background: linear-gradient(90deg, #a78bfa, #6d28d9); }
.cat-fill.gray { background: linear-gradient(90deg, #b6c2d3, #7b8ca3); }

.activity-list { display: flex; flex-direction: column; }
.activity-item { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; }
.activity-item + .activity-item { border-top: 1px solid #edf1f7; }
.activity-icon {
  display: grid; place-items: center; flex: none;
  width: 28px; height: 28px; border-radius: 8px;
  background: var(--surface-3); color: var(--muted);
}
.activity-icon .icon { width: 14px; height: 14px; }
.activity-icon.ok { background: var(--success-bg); color: var(--success); }
.activity-icon.warn { background: var(--warning-bg); color: var(--warning); }
.activity-icon.bad { background: var(--danger-bg); color: var(--danger); }
.activity-icon.info { background: var(--info-bg); color: var(--info); }
.activity-body { min-width: 0; flex: 1; }
.activity-text { font-size: 11.5px; line-height: 1.4; color: var(--text-soft); }
.activity-text strong { color: var(--text); font-weight: 700; }
.activity-time { margin-top: 1px; font-size: 9.8px; color: var(--muted-2); }

/* --------------------------------------------------------------------------
   Agenda — toolbar, tabel, paginasi
   -------------------------------------------------------------------------- */

.toolbar-card { padding: 15px 16px; margin-bottom: 14px; }
.filter-form { display: flex; flex-direction: column; gap: 11px; }
.filter-grid {
  display: grid; grid-template-columns: minmax(200px, 1.6fr) repeat(4, minmax(120px, .72fr));
  gap: 9px;
}
.filter-grid .field { margin: 0; gap: 4px; }
.filter-grid label {
  font-size: 9.5px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase;
  color: var(--muted-2);
}
.filter-grid input, .filter-grid select { min-height: 39px; font-size: 12.3px; border-radius: 9px; }
.search-box { position: relative; display: flex; align-items: center; }
.search-box .icon {
  position: absolute; left: 11px; width: 16px; height: 16px; color: var(--muted-2); pointer-events: none;
}
.search-box input { padding-left: 35px !important; }
.filter-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
}
.quick-chips { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 9px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface-2); color: var(--muted);
  font-size: 10.5px; font-weight: 650; transition: .15s ease;
}
.chip:hover { border-color: var(--teal-500); color: var(--teal-700); background: #f0fdfa; }
.chip.active { background: var(--teal-100); border-color: #99f6e4; color: var(--teal-700); }
.filter-actions { display: flex; align-items: center; gap: 7px; margin-left: auto; }
.filter-actions .btn { min-height: 34px; padding: 6px 11px; font-size: 11.5px; border-radius: 8px; }

.export-wrap { position: relative; }
.export-menu {
  position: fixed; left: 0; top: 0; z-index: 1300;
  width: 210px; max-width: calc(100vw - 24px); padding: 5px;
  background: #fff; border: 1px solid var(--line); border-radius: 11px;
  box-shadow: var(--shadow); animation: popIn .15s ease backwards;
}
.export-menu button {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 8px 9px; border: 0; border-radius: 7px;
  background: transparent; color: var(--text-soft); text-align: left; font-size: 12px;
}
.export-menu button:hover { background: var(--surface-2); }
.export-menu .icon { width: 15px; height: 15px; color: var(--muted); }
.export-menu .menu-sep { margin: 4px 6px; }

.table-card { overflow: hidden; }
.table-meta {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 17px; border-bottom: 1px solid var(--line);
  font-size: 11.5px; color: var(--muted);
}
.table-meta strong { color: var(--text-soft); }
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
  padding: 10px 14px; text-align: left; white-space: nowrap;
  background: var(--surface-2); border-bottom: 1px solid var(--line);
  font-size: 9.5px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase;
  color: var(--muted-2);
}
.data-table td {
  padding: 12px 14px; border-bottom: 1px solid #edf1f7;
  font-size: 12px; color: var(--text-soft); vertical-align: middle;
}
.data-table tbody tr { transition: background .12s ease; }
.data-table tbody tr:hover { background: #fbfcfe; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table .row-click { cursor: pointer; }
.cell-agenda { min-width: 250px; }
.agenda-title { font-size: 12.6px; font-weight: 700; color: var(--text); line-height: 1.35; }
.agenda-sub { display: flex; align-items: center; gap: 8px; margin-top: 3px; flex-wrap: wrap; }
.agenda-sub .badge { font-size: 9px; padding: 2px 6px; }
.attachment-count {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 9.5px; font-weight: 700; color: var(--teal-700);
  background: var(--teal-100); border-radius: 999px; padding: 2px 7px;
}
.attachment-count .icon { width: 11px; height: 11px; }
.cell-date strong { display: block; font-size: 12px; color: var(--text); font-weight: 650; }
.cell-date span { font-size: 10.3px; color: var(--muted); }
.cell-time { font-variant-numeric: tabular-nums; color: var(--text-soft); white-space: nowrap; }
.cell-time strong { font-weight: 700; color: var(--text); }
.cell-loc { max-width: 190px; }
.cell-loc span {
  display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-size: 11.5px;
}
.row-actions { display: flex; align-items: center; gap: 2px; justify-content: flex-end; opacity: .45; transition: opacity .15s ease; }
.data-table tr:hover .row-actions, .row-actions:focus-within { opacity: 1; }
.row-actions .icon-btn { width: 30px; height: 30px; border-radius: 7px; }
.row-actions .icon-btn .icon { width: 15px; height: 15px; }
.row-actions .danger:hover { background: var(--danger-bg); color: var(--danger); }

.pagination {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 16px; border-top: 1px solid var(--line); flex-wrap: wrap;
}
.pagination-info { font-size: 11px; color: var(--muted); }
.pagination-btns { display: flex; align-items: center; gap: 4px; }
.page-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 30px; height: 30px; padding: 0 7px;
  border: 1px solid transparent; border-radius: 7px;
  background: transparent; color: var(--muted); font-size: 11.5px; font-weight: 650;
}
.page-btn:hover { background: var(--surface-3); color: var(--text); }
.page-btn.active { background: var(--navy-900); color: #fff; border-color: var(--navy-900); }
.page-btn:disabled { opacity: .35; cursor: not-allowed; }
.page-btn .icon { width: 14px; height: 14px; }

/* --------------------------------------------------------------------------
   Formulir agenda & detail
   -------------------------------------------------------------------------- */

.modal .field { margin-bottom: 14px; }
.modal .field > label, .modal .field-label { font-size: 11.5px; }
.modal input, .modal select, .modal textarea { font-size: 12.8px; }
.agenda-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.agenda-form-grid .span-2 { grid-column: 1 / -1; }
.time-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.detail-banner {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 18px 22px; border-bottom: 1px solid var(--line);
  background: linear-gradient(120deg, #f8fbff, #f2f7fb);
}
.detail-date {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  flex: none; width: 56px; height: 60px; border-radius: 12px;
  background: var(--navy-900); color: #fff; line-height: 1.05;
  box-shadow: 0 6px 14px rgba(10,32,61,.18);
}
.detail-date strong { font-size: 21px; font-weight: 800; }
.detail-date span { font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--gold-300); }
.detail-title-wrap { min-width: 0; flex: 1; }
.detail-title-wrap h3 { font-size: 18px; line-height: 1.3; letter-spacing: -.02em; color: var(--navy-900); }
.detail-badges { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 7px; }
.meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.meta-item { display: flex; align-items: flex-start; gap: 9px; min-width: 0; }
.meta-icon {
  display: grid; place-items: center; flex: none; width: 30px; height: 30px;
  border-radius: 8px; background: var(--surface-3); color: var(--muted);
}
.meta-icon .icon { width: 15px; height: 15px; }
.meta-item div { min-width: 0; }
.meta-item small { display: block; font-size: 9.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted-2); }
.meta-item strong, .meta-item span { display: block; font-size: 11.8px; color: var(--text-soft); line-height: 1.4; overflow-wrap: anywhere; }
.meta-item strong { font-weight: 650; }
.detail-desc {
  margin-top: 18px; padding: 14px 15px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 11px;
  font-size: 12.3px; line-height: 1.65; color: var(--text-soft); white-space: pre-line;
}
.detail-desc-label { margin-top: 18px; margin-bottom: 6px; font-size: 9.5px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--muted-2); }
.detail-meta-foot { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 10.3px; color: var(--muted-2); }
.detail-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.detail-status-select { min-width: 140px; min-height: 34px; font-size: 11.5px; padding: 5px 30px 5px 9px; border-radius: 8px; }

/* Lampiran surat */
.attachment-panel {
  margin-top: 8px; border: 1px solid var(--line); border-radius: 12px;
  overflow: hidden; background: var(--surface-2);
}
.attachment-list { display: flex; flex-direction: column; }
.attachment-item {
  display: flex; align-items: center; gap: 11px; padding: 10px 12px;
  background: var(--surface); border-bottom: 1px solid var(--line);
}
.attachment-item:last-child { border-bottom: 0; }
.attachment-icon {
  display: grid; place-items: center; flex: none; width: 32px; height: 32px;
  border-radius: 8px; background: var(--surface-3); color: var(--teal-700);
}
.attachment-icon .icon { width: 16px; height: 16px; }
.attachment-info { flex: 1; min-width: 0; }
.attachment-info strong {
  display: block; font-size: 11.8px; font-weight: 650; color: var(--text-soft);
  overflow-wrap: anywhere;
}
.attachment-info span {
  display: block; margin-top: 2px; font-size: 10.2px; color: var(--muted-2);
}
.attachment-actions { display: flex; align-items: center; gap: 4px; flex: none; }
.attachment-empty {
  padding: 14px 12px; font-size: 11.5px; color: var(--muted); background: var(--surface);
}
.attachment-upload {
  position: relative; display: flex; align-items: center; gap: 11px;
  padding: 12px; cursor: pointer;
  border-top: 1px dashed var(--line-strong); background: var(--surface-2);
  transition: .18s ease;
}
.attachment-upload:hover { background: #f0fdfa; }
.attachment-upload .icon { width: 22px; height: 22px; color: var(--teal-600); flex: none; }
.attachment-upload span { min-width: 0; }
.attachment-upload strong { display: block; font-size: 11.8px; color: var(--text-soft); }
.attachment-upload small { display: block; margin-top: 2px; font-size: 10.2px; color: var(--muted); }
.attachment-upload input[type="file"] {
  position: absolute; inset: 0; opacity: 0; cursor: pointer;
}

/* --------------------------------------------------------------------------
   Impor Excel/CSV
   -------------------------------------------------------------------------- */

.import-help {
  display: flex; gap: 10px; padding: 11px 12px; margin-bottom: 14px;
  background: var(--info-bg); border: 1px solid #d8e4fb; border-radius: 10px;
  font-size: 11.5px; line-height: 1.55; color: #24457f;
}
.import-help .icon { color: var(--info); flex: none; margin-top: 1px; }
.dropzone {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 7px; padding: 28px 18px; text-align: center;
  border: 1.5px dashed var(--line-strong); border-radius: 14px;
  background: var(--surface-2); transition: .18s ease; cursor: pointer;
}
.dropzone:hover, .dropzone.dragover { border-color: var(--teal-500); background: #f0fdfa; }
.dropzone .icon { width: 30px; height: 30px; color: var(--teal-600); }
.dropzone strong { font-size: 12.8px; color: var(--text-soft); }
.dropzone span { font-size: 10.8px; color: var(--muted); }
.dropzone input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.file-chip {
  display: flex; align-items: center; gap: 9px;
  margin-top: 12px; padding: 9px 11px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 9px;
  font-size: 11.5px; color: var(--text-soft);
}
.file-chip .icon { width: 16px; height: 16px; color: var(--teal-700); }
.file-chip .name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.file-chip .size { color: var(--muted-2); font-size: 10.5px; }
.import-result { margin-top: 14px; }
.import-summary { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 10px; background: var(--success-bg); border: 1px solid #c8e8d3; }
.import-summary.has-errors { background: var(--warning-bg); border-color: #f0dfb0; }
.import-summary strong { font-size: 18px; color: var(--success); line-height: 1; }
.import-summary.has-errors strong { color: var(--warning); }
.import-summary span { font-size: 11.5px; color: var(--text-soft); }
.error-table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 11px; }
.error-table th, .error-table td { padding: 6px 8px; text-align: left; border-bottom: 1px solid var(--line); }
.error-table th { font-size: 9.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted-2); }
.error-table td:first-child { width: 46px; color: var(--muted); font-variant-numeric: tabular-nums; }
.error-scroll { max-height: 190px; overflow-y: auto; }

/* --------------------------------------------------------------------------
   Pengguna
   -------------------------------------------------------------------------- */

.user-cell { display: flex; align-items: center; gap: 10px; min-width: 190px; }
.user-cell-text { min-width: 0; }
.user-cell-text strong { display: block; font-size: 12.3px; color: var(--text); line-height: 1.35; }
.user-cell-text span { display: block; font-size: 10.5px; color: var(--muted); }
.status-line { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 650; color: var(--success); }
.status-line::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-line.off { color: var(--muted-2); }
.status-line.locked { color: var(--danger); }
.self-tag { font-size: 9px; font-weight: 800; padding: 1px 5px; border-radius: 4px; background: var(--teal-100); color: var(--teal-700); margin-left: 4px; }

/* --------------------------------------------------------------------------
   Audit
   -------------------------------------------------------------------------- */

.audit-badge {
  display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 6px;
  background: var(--surface-3); color: var(--text-soft);
  font-size: 9.5px; font-weight: 750; white-space: nowrap;
}
.audit-badge.good { background: var(--success-bg); color: var(--success); }
.audit-badge.bad { background: var(--danger-bg); color: var(--danger); }
.audit-badge.warn { background: var(--warning-bg); color: var(--warning); }
.audit-badge.info { background: var(--info-bg); color: var(--info); }
.audit-detail { max-width: 430px; line-height: 1.45; font-size: 11.5px; }
.ip-chip {
  display: inline-block; padding: 2px 6px; border-radius: 5px;
  background: var(--surface-2); border: 1px solid var(--line);
  font-family: "Consolas", "SFMono-Regular", monospace; font-size: 10px; color: var(--muted);
}
.audit-time { font-size: 10.8px; color: var(--muted); white-space: nowrap; }
.audit-user { display: flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 650; color: var(--text-soft); }

/* --------------------------------------------------------------------------
   Keamanan
   -------------------------------------------------------------------------- */

.security-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; align-items: start; }
.security-card { padding: 20px; }
.security-wide { grid-column: 1 / -1; }
.security-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.security-icon {
  display: grid; place-items: center; flex: none; width: 38px; height: 38px;
  border-radius: 10px; background: var(--surface-3); color: var(--text-soft);
}
.security-icon .icon { width: 19px; height: 19px; }
.security-icon.teal { background: var(--teal-100); color: var(--teal-700); }
.security-icon.gold { background: var(--gold-100); color: var(--gold-600); }
.security-icon.blue { background: var(--info-bg); color: var(--info); }
.security-icon.red { background: var(--danger-bg); color: var(--danger); }
.security-head-text { flex: 1; min-width: 0; }
.security-head-text h3 { font-size: 14px; font-weight: 750; color: var(--navy-900); }
.security-head-text p { margin-top: 3px; font-size: 11.5px; color: var(--muted); line-height: 1.5; }
.security-status {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 8px; border-radius: 999px;
  font-size: 9.5px; font-weight: 800;
}
.security-status.on { background: var(--success-bg); color: var(--success); }
.security-status.off { background: var(--surface-3); color: var(--muted); }
.security-status::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

.password-strength { margin-top: 4px; }
.strength-head { display: flex; align-items: center; justify-content: space-between; font-size: 10px; color: var(--muted); margin-bottom: 5px; }
.strength-head strong { font-weight: 750; }
.strength-track { height: 5px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.strength-fill { height: 100%; width: 0; border-radius: inherit; background: var(--danger); transition: .25s ease; }
.strength-fill.s2 { background: var(--gold-500); }
.strength-fill.s3 { background: #65a30d; }
.strength-fill.s4 { background: var(--success); }
.req-list { list-style: none; padding: 0; margin: 10px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 5px 12px; }
.req-list li { display: flex; align-items: center; gap: 5px; font-size: 10.3px; color: var(--muted-2); }
.req-list li .icon { width: 12px; height: 12px; color: var(--line-strong); }
.req-list li.ok { color: var(--success); }
.req-list li.ok .icon { color: var(--success); }

.policy-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; }
.policy-list li { display: flex; align-items: flex-start; gap: 8px; font-size: 11.3px; color: var(--text-soft); line-height: 1.45; }
.policy-list .icon { width: 15px; height: 15px; color: var(--teal-600); margin-top: 1px; flex: none; }
.policy-list strong { font-weight: 750; }

.sessions-list { display: flex; flex-direction: column; }
.session-item { display: flex; align-items: flex-start; gap: 11px; padding: 11px 0; }
.session-item + .session-item { border-top: 1px solid #edf1f7; }
.session-device {
  display: grid; place-items: center; flex: none; width: 34px; height: 34px;
  border-radius: 9px; background: var(--surface-3); color: var(--muted);
}
.session-device .icon { width: 17px; height: 17px; }
.session-device.current { background: var(--teal-100); color: var(--teal-700); }
.session-body { flex: 1; min-width: 0; }
.session-title { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; font-size: 11.8px; font-weight: 700; color: var(--text-soft); }
.session-title .pill { font-size: 8.5px; padding: 1px 6px; }
.session-meta { margin-top: 2px; font-size: 10.2px; color: var(--muted); line-height: 1.45; overflow-wrap: anywhere; }
.session-item .btn { flex: none; }

.code-display {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 14px 16px; border-radius: 12px;
  background: var(--navy-950); color: var(--gold-300);
  font-family: "Consolas", "SFMono-Regular", monospace;
  font-size: 14px; font-weight: 700; letter-spacing: .14em;
  overflow-wrap: anywhere;
}
.code-display .icon-btn { color: #c8d7ea; flex: none; }
.code-display .icon-btn:hover { background: rgba(255,255,255,.1); color: #fff; }
.setup-steps { margin: 14px 0 0; padding-left: 20px; font-size: 11.5px; color: var(--text-soft); line-height: 1.6; }
.setup-steps li { margin-bottom: 6px; }
.setup-steps code {
  padding: 1px 5px; border-radius: 4px; background: var(--surface-3);
  font-family: "Consolas", monospace; font-size: 10.5px; color: var(--teal-700);
}
.otpauth-row {
  display: flex; align-items: center; gap: 8px; margin-top: 9px; padding: 8px 10px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px;
}
.otpauth-row code { flex: 1; min-width: 0; font-size: 9.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recovery-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 12px; }
.recovery-code {
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 7px;
  background: var(--surface-2); text-align: center;
  font-family: "Consolas", monospace; font-size: 12.5px; font-weight: 700;
  color: var(--text); letter-spacing: .05em;
}
.warning-box {
  display: flex; align-items: flex-start; gap: 10px; padding: 11px 12px;
  background: var(--warning-bg); border: 1px solid #f0dfb0; border-radius: 10px;
  font-size: 11.5px; line-height: 1.55; color: #7a5300;
}
.warning-box .icon { color: var(--gold-600); flex: none; margin-top: 1px; }

/* --------------------------------------------------------------------------
   Layar kunci
   -------------------------------------------------------------------------- */

.lock-screen {
  position: fixed; inset: 0; z-index: 900;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  background:
    radial-gradient(800px 500px at 15% 0%, rgba(20,184,166,.24), transparent 55%),
    radial-gradient(700px 500px at 100% 100%, rgba(217,165,33,.16), transparent 55%),
    linear-gradient(145deg, var(--navy-950), var(--navy-900) 60%, #082033);
  overflow-y: auto;
}
.lock-screen::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .4;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(ellipse at 50% 40%, black, transparent 75%);
}
.lock-card {
  position: relative; width: 100%; max-width: 392px;
  padding: 26px 28px 22px; text-align: center;
  background: #fff; border-radius: 22px; box-shadow: var(--shadow-lg);
  animation: riseIn .4s ease both;
}
.lock-brand { display: flex; align-items: center; justify-content: center; gap: 9px; margin-bottom: 17px; }
.lock-brand .brand-mark { width: 32px; height: 32px; border-radius: 9px; background: var(--navy-900); border-color: var(--navy-800); }
.lock-brand .brand-mark svg { width: 22px; height: 22px; }
.lock-brand > span { font-size: 14px; font-weight: 800; letter-spacing: .14em; color: var(--navy-900); }
.lock-icon {
  display: grid; place-items: center; width: 42px; height: 42px; margin: 0 auto 8px;
  border-radius: 50%; background: var(--gold-100); color: var(--gold-600);
}
.lock-icon .icon { width: 20px; height: 20px; }
.lock-card .avatar-xl { margin-bottom: 10px; }
.lock-card h2 { font-size: 21px; letter-spacing: -.02em; color: var(--navy-900); }
.lock-card > p { margin: 5px auto 18px; max-width: 280px; font-size: 12px; color: var(--muted); line-height: 1.5; }
.lock-card form { text-align: left; }
.lock-card .field { margin-bottom: 12px; }
.lock-card .btn { margin-top: 3px; }
.lock-card .link-btn { margin-top: 13px; font-size: 11.5px; color: var(--muted); }
.lock-card .link-btn:hover { color: var(--danger); }
.lock-foot {
  display: flex; align-items: flex-start; justify-content: center; gap: 5px;
  margin-top: 16px !important; padding-top: 12px; border-top: 1px solid var(--line);
  font-size: 9.5px !important; color: var(--muted-2) !important; line-height: 1.45 !important;
}
.lock-foot .icon { width: 12px; height: 12px; margin-top: 1px; flex: none; }

/* --------------------------------------------------------------------------
   Responsif halaman
   -------------------------------------------------------------------------- */

@media (max-width: 1280px) {
  .dash-grid { grid-template-columns: 1fr; }
  .dash-grid .stack { display: grid; grid-template-columns: 1fr 1fr; align-items: start; }
}
@media (max-width: 1080px) {
  .filter-grid { grid-template-columns: minmax(180px, 1.5fr) repeat(2, 1fr); }
  .filter-grid .filter-date { grid-row: 2; }
}
@media (max-width: 900px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .security-grid { grid-template-columns: 1fr; }
  .hero { flex-direction: column; align-items: flex-start; gap: 16px; }
  .hero-actions { width: 100%; }
  .hero-art { display: none; }
  .dash-grid .stack { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .section-head h2 { font-size: 19px; }
  .stat-card { padding: 13px; gap: 10px; }
  .stat-value { font-size: 23px; }
  .stat-icon { width: 35px; height: 35px; border-radius: 9px; }
  .hero { padding: 22px 20px; border-radius: 18px; }
  .hero h2 { font-size: 23px; }
  .hero-actions .btn { flex: 1; }
  .card-head { padding: 15px 15px 10px; }
  .card-body { padding: 0 15px 15px; }
  .filter-grid { grid-template-columns: 1fr 1fr; }
  .filter-grid .filter-search { grid-column: 1 / -1; }
  .filter-grid .filter-date { grid-row: auto; }
  .filter-actions { width: 100%; margin-left: 0; }
  .filter-actions .btn { flex: 1; }
  .data-table thead { display: none; }
  .data-table, .data-table tbody, .data-table tr, .data-table td { display: block; width: 100%; }
  .data-table tr { position: relative; padding: 12px 14px 9px; border-bottom: 1px solid var(--line); }
  .data-table tbody tr:hover { background: transparent; }
  .data-table td { padding: 4px 0; border: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
  .data-table td::before {
    content: attr(data-label); flex: none; width: 84px; padding-top: 1px;
    font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em;
    color: var(--muted-2);
  }
  .data-table td.cell-agenda { display: block; padding-right: 74px; }
  .data-table td.cell-agenda::before { display: none; }
  .data-table td.cell-actions { position: absolute; top: 10px; right: 8px; width: auto; padding: 0; }
  .data-table td.cell-actions::before { display: none; }
  .row-actions { opacity: 1; }
  .cell-agenda { min-width: 0; }
  .cell-loc, .cell-time, .cell-date { max-width: none; }
  .cell-loc span { white-space: normal; }
  .pagination { padding: 11px 13px; }
  .pagination-info { width: 100%; }
  .meta-grid { grid-template-columns: 1fr; }
  .detail-banner { padding: 15px 16px; }
  .detail-title-wrap h3 { font-size: 16px; }
  .agenda-form-grid { grid-template-columns: 1fr; }
  .agenda-form-grid .span-2 { grid-column: auto; }
  .recovery-grid { grid-template-columns: 1fr; }
  .policy-list { grid-template-columns: 1fr; }
  .security-card { padding: 16px; }
  .demo-banner { flex-wrap: wrap; }
  .demo-banner .btn { margin-left: 28px; }
  .audit-detail { max-width: none; }
}
@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr; }
  .filter-grid { grid-template-columns: 1fr; }
  .quick-chips { width: 100%; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .chart-bars { gap: 4px; height: 160px; }
  .chart-bar { width: min(26px, 70%); }
  .req-list { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   Cetak
   -------------------------------------------------------------------------- */

@media print {
  @page { size: A4 landscape; margin: 12mm; }
  body { background: #fff; font-size: 10pt; }
  .sidebar, .topbar, .app-footer, #banner-root,
  .section-actions, .toolbar-card, .pagination, .row-actions,
  .modal-overlay, .toast-root, .mobile-menu, .detail-actions { display: none !important; }
  .main { margin-left: 0 !important; }
  .view-root { padding: 0 !important; max-width: none !important; }
  .card, .table-card { border: 1px solid #bbb !important; box-shadow: none !important; border-radius: 0 !important; }
  .table-meta { border-bottom: 1px solid #bbb; }
  .data-table th, .data-table td { border-bottom: 1px solid #ddd; padding: 6px 8px; font-size: 8.4pt; }
  .data-table th { background: #eee !important; color: #000; }
  .data-table thead { display: table-header-group !important; }
  .data-table tr { break-inside: avoid; }
  .status-badge { border: 1px solid #bbb; background: none !important; color: #000 !important; }
  .agenda-title { color: #000; }
  .section-head { margin-bottom: 10px; }
  .section-head h2 { font-size: 16pt; }
  .print-only { display: block !important; }
}
