/**
 * style.css
 * Jadwal Kerja Kuantan Net
 * Konsep C: Industrial Telecom & Field Operations Pro
 *
 * Desain ergonomis bertema NOC / Industrial Telecom dengan aksen Electric Amber,
 * latar charcoal pekat, tipografi tajam, dan split view login modern.
 */

:root,
html[data-theme="dark"] {
  /* Palet Warna Industrial Telecom (Dark Theme) */
  --bg-canvas: #090d16;
  --bg-card: #111827;
  --bg-card-elevated: #161f30;
  --bg-card-inner: #0d1424;
  --bg-input: #0b111e;
  --bg-input-focus: #0f172a;

  --border-subtle: #1f293d;
  --border-active: #334155;
  --border-hover: #475569;

  /* Safety Amber / Electric Gold (Aksen Utama) */
  --amber: #f59e0b;
  --amber-hover: #fbbf24;
  --amber-dark: #d97706;
  --amber-glow: rgba(245, 158, 11, 0.28);
  --amber-subtle: rgba(245, 158, 11, 0.12);
  --amber-border: rgba(245, 158, 11, 0.35);

  /* Telecom Cyan / Fiber Blue */
  --cyan: #0ea5e9;
  --cyan-hover: #38bdf8;
  --cyan-dark: #0284c7;
  --cyan-glow: rgba(14, 165, 233, 0.25);
  --cyan-subtle: rgba(14, 165, 233, 0.12);
  --cyan-border: rgba(14, 165, 233, 0.35);

  /* Emerald Status */
  --green: #10b981;
  --green-hover: #059669;
  --green-glow: rgba(16, 185, 129, 0.25);
  --green-subtle: rgba(16, 185, 129, 0.12);
  --green-border: rgba(16, 185, 129, 0.35);

  /* Danger / Alert */
  --danger: #ef4444;
  --danger-hover: #dc2626;
  --danger-glow: rgba(239, 68, 68, 0.25);
  --danger-subtle: rgba(239, 68, 68, 0.12);
  --danger-border: rgba(239, 68, 68, 0.35);

  /* Tipografi & Warna Teks */
  --text-pure: #ffffff;
  --text-title: #f8fafc;
  --text-body: #cbd5e1;
  --text-muted: #94a3b8;
  --text-faint: #64748b;
  --text-dark: #080c14;

  --grid-line: rgba(255, 255, 255, 0.015);
  --radial-glow-1: rgba(14, 165, 233, 0.08);
  --radial-glow-2: rgba(245, 158, 11, 0.05);

  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-pill: 9999px;

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 20px 40px -10px rgba(0, 0, 0, 0.6);

  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* ================= TEMA TERANG (LIGHT THEME) ================= */
html[data-theme="light"] {
  --bg-canvas: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-elevated: #f1f5f9;
  --bg-card-inner: #f8fafc;
  --bg-input: #ffffff;
  --bg-input-focus: #ffffff;

  --border-subtle: #e2e8f0;
  --border-active: #cbd5e1;
  --border-hover: #94a3b8;

  --amber: #d97706;
  --amber-hover: #b45309;
  --amber-dark: #92400e;
  --amber-glow: rgba(217, 119, 6, 0.2);
  --amber-subtle: rgba(217, 119, 6, 0.1);
  --amber-border: rgba(217, 119, 6, 0.35);

  --cyan: #0284c7;
  --cyan-hover: #0369a1;
  --cyan-dark: #075985;
  --cyan-glow: rgba(2, 132, 199, 0.2);
  --cyan-subtle: rgba(2, 132, 199, 0.1);
  --cyan-border: rgba(2, 132, 199, 0.35);

  --green: #059669;
  --green-hover: #047857;
  --green-glow: rgba(5, 150, 105, 0.2);
  --green-subtle: rgba(5, 150, 105, 0.1);
  --green-border: rgba(5, 150, 105, 0.35);

  --danger: #dc2626;
  --danger-hover: #b91c1c;
  --danger-glow: rgba(220, 38, 38, 0.2);
  --danger-subtle: rgba(220, 38, 38, 0.1);
  --danger-border: rgba(220, 38, 38, 0.35);

  --text-pure: #0f172a;
  --text-title: #1e293b;
  --text-body: #334155;
  --text-muted: #64748b;
  --text-faint: #94a3b8;
  --text-dark: #ffffff;

  --grid-line: rgba(15, 23, 42, 0.04);
  --radial-glow-1: rgba(14, 165, 233, 0.05);
  --radial-glow-2: rgba(217, 119, 6, 0.04);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
}

/* Reset & Dasar */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-canvas);
  background-image: 
    radial-gradient(circle at 50% 0%, var(--radial-glow-1) 0%, transparent 60%),
    radial-gradient(circle at 10% 20%, var(--radial-glow-2) 0%, transparent 40%),
    linear-gradient(to right, var(--grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 36px 36px, 36px 36px;
  color: var(--text-body);
  line-height: 1.5;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.2s ease, color 0.2s ease;
}

/* Utilitas */
.hidden {
  display: none !important;
}

.hidden-visually {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.text-muted {
  color: var(--text-muted);
}

.small {
  font-size: 0.8rem;
}

.italic {
  font-style: italic;
}

.text-success {
  color: var(--green) !important;
}

.highlight-amber {
  color: var(--amber);
  text-shadow: 0 0 16px var(--amber-glow);
}

/* ===================================================
   LAYAR LOGIN (SPLIT HERO & FORMULIR)
   =================================================== */
.login-view {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  position: relative;
  width: 100%;
}

.login-split-card {
  width: 100%;
  max-width: 1140px;
  min-height: 640px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl), 0 0 0 1px rgba(255, 255, 255, 0.04);
  display: grid;
  grid-template-columns: 1.18fr 0.82fr;
  overflow: hidden;
}

/* Sisi Kiri: Hero & Kata-kata Branding */
.login-hero-pane {
  position: relative;
  background: linear-gradient(145deg, #0d1527 0%, #080c14 100%);
  border-right: 1px solid var(--border-subtle);
  padding: 44px 44px 36px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.hero-tech-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.08) 0%, transparent 45%),
                    radial-gradient(circle at 80% 80%, rgba(14, 165, 233, 0.08) 0%, transparent 45%);
  pointer-events: none;
}

.hero-brand-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
}

.hero-logo-box {
  width: 46px;
  height: 46px;
  background: linear-gradient(135deg, var(--bg-card-elevated), var(--bg-canvas));
  border: 1px solid var(--amber-border);
  border-radius: var(--radius-md);
  color: var(--amber);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px var(--amber-glow);
}

.hero-brand-meta {
  display: flex;
  flex-direction: column;
}

.hero-brand-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-pure);
  letter-spacing: 0.04em;
}

.hero-badge-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: 0.08em;
}

.hero-body {
  position: relative;
  z-index: 1;
  margin: 32px 0 24px;
}

.hero-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--green-subtle);
  border: 1px solid var(--green-border);
  color: var(--green);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  letter-spacing: 0.06em;
  margin-bottom: 20px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulse-live 1.8s infinite;
}

@keyframes pulse-live {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.hero-headline {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-pure);
  line-height: 1.3;
  margin-bottom: 14px;
  letter-spacing: -0.02em;
}

.hero-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 24px;
}

/* Kartu Grafis Topologi Fiber Optik */
.hero-graphic-card {
  background: rgba(11, 17, 30, 0.7);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  box-shadow: var(--shadow-md);
}

.graphic-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

.node-status {
  color: var(--green);
  font-weight: 600;
}

.latency-pill {
  background: var(--amber-subtle);
  color: var(--amber);
  border: 1px solid var(--amber-border);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-weight: 700;
}

.topology-svg-wrap {
  width: 100%;
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.topology-svg {
  width: 100%;
  height: 100%;
}

.graphic-stats-row {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 12px;
  margin-top: 10px;
  gap: 16px;
}

.g-stat {
  display: flex;
  flex-direction: column;
}

.g-stat-label {
  font-size: 0.7rem;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.g-stat-val {
  font-size: 0.8rem;
  color: var(--text-title);
  font-weight: 600;
  margin-top: 2px;
}

.hero-footer {
  position: relative;
  z-index: 1;
  font-size: 0.75rem;
  color: var(--text-faint);
}

/* Sisi Kanan: Form Login */
.login-form-pane {
  background: var(--bg-card);
  padding: 44px 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-card-inner {
  width: 100%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.login-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.login-header-icon {
  width: 44px;
  height: 44px;
  background: var(--amber-subtle);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.login-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-pure);
  letter-spacing: -0.01em;
}

.login-subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Alert Login */
.login-alert {
  background: var(--danger-subtle);
  border: 1px solid var(--danger-border);
  color: #fca5a5;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.825rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.login-form-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  color: var(--text-faint);
  display: flex;
  align-items: center;
  pointer-events: none;
}

.input-login {
  padding-left: 42px !important;
  padding-right: 42px !important;
}

.btn-input-action {
  position: absolute;
  right: 10px;
  background: transparent;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-xs);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s ease;
}

.btn-input-action:hover {
  color: var(--text-title);
}

.login-options-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
  accent-color: var(--amber);
  cursor: pointer;
}

.btn-amber-glow {
  background: linear-gradient(135deg, var(--amber), var(--amber-dark));
  color: var(--text-dark);
  border: none;
  font-weight: 700;
  box-shadow: 0 4px 16px var(--amber-glow);
  transition: all 0.2s ease;
}

.btn-amber-glow:hover {
  background: linear-gradient(135deg, var(--amber-hover), var(--amber));
  box-shadow: 0 6px 22px rgba(245, 158, 11, 0.4);
  transform: translateY(-1px);
}

.btn-amber-glow:active {
  transform: translateY(0);
}

/* Quick One-Click Demo Logins */
.quick-login-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quick-login-divider {
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--text-faint);
  font-size: 0.725rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.quick-login-divider::before,
.quick-login-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid var(--border-subtle);
}

.quick-login-divider span {
  padding: 0 10px;
}

.quick-login-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.btn-quick-login {
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-quick-login:hover {
  border-color: var(--amber-border);
  background: rgba(245, 158, 11, 0.06);
  transform: translateY(-1px);
}

.quick-icon {
  font-size: 1.1rem;
}

.quick-info strong {
  display: block;
  font-size: 0.8rem;
  color: var(--text-title);
  line-height: 1.2;
}

.quick-info small {
  display: block;
  font-size: 0.675rem;
  color: var(--text-muted);
}

.login-footer-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.725rem;
  color: var(--text-faint);
  margin-top: 6px;
}

.security-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--cyan);
}

/* ===================================================
   DASHBOARD UTAMA APLIKASI (KONSEP C INDUSTRIAL)
   =================================================== */
.app-container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 24px 24px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Header Aplikasi Industrial NOC */
.app-header {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 18px 24px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

/* Baris 1: Logo & Brand di Kiri, Profil Pengguna di Kanan */
.header-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 16px;
  flex-wrap: wrap;
}

.header-brand,
.header-content {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1 1 auto;
  min-width: 280px;
}

.header-logo-wrap {
  position: relative;
}

.header-icon-glow {
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  background: linear-gradient(135deg, var(--amber), var(--cyan));
  border-radius: var(--radius-md);
  opacity: 0.35;
  filter: blur(8px);
  z-index: 0;
}

.header-icon {
  position: relative;
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #1f293d, #0b111e);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px var(--amber-glow);
  z-index: 1;
}

.title-badge-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.app-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-pure);
  letter-spacing: -0.02em;
}

.badge-isp {
  background: var(--amber-subtle);
  color: var(--amber);
  border: 1px solid var(--amber-border);
  font-size: 0.675rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.system-status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid var(--green-border);
  padding: 2px 9px;
  border-radius: var(--radius-pill);
}

.status-live-pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--green);
  box-shadow: 0 0 6px var(--green);
  animation: pulse-live 1.8s infinite;
}

.status-live-text {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--green);
  letter-spacing: 0.06em;
}

.app-subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Baris 2: Toolbar Operasional (Jam di Kiri, Aksi di Kanan) */
.header-toolbar-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
  flex-wrap: wrap;
}

.header-action-buttons,
.header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  margin-left: auto;
}

/* Jam Digital Live */
.live-clock-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--cyan);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 0.785rem;
  font-weight: 600;
}

.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
}

/* Profil Petugas & Logout Button */
.user-profile-widget {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  padding: 3px 4px 3px 10px;
}

.user-profile-badge {
  display: flex;
  align-items: center;
  gap: 8px;
}

.user-avatar-initials {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--amber), var(--amber-dark));
  color: var(--text-dark);
  font-weight: 800;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.user-profile-details {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.user-profile-name {
  font-size: 0.775rem;
  font-weight: 700;
  color: var(--text-title);
}

.user-profile-role {
  font-size: 0.65rem;
  color: var(--text-faint);
}

.btn-logout {
  border-radius: var(--radius-pill) !important;
  padding: 5px 10px !important;
}

/* Alert Error Validasi */
.alert {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 500;
}

.alert-danger {
  background: var(--danger-subtle);
  border: 1px solid var(--danger-border);
  color: #fca5a5;
}

.alert-icon {
  flex-shrink: 0;
}

/* ===================================================
   NAVIGATION TABS: GENERATOR & HISTORI ARSIP
   =================================================== */
.app-nav-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 6px;
  box-shadow: var(--shadow-sm);
  width: 100%;
}

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.tab-btn:hover {
  color: var(--text-pure);
  background: rgba(255, 255, 255, 0.04);
}

.tab-btn.is-active {
  background: var(--amber-subtle);
  border-color: var(--amber-border);
  color: #fbbf24;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.2);
}

.badge-tab-count {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid var(--amber-border);
  color: #fbbf24;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.tab-btn.is-active .badge-tab-count {
  background: #f59e0b;
  color: #080c14;
}

.tab-view-content {
  width: 100%;
}

.tab-view-content.hidden {
  display: none !important;
}

/* ===================================================
   TAB HISTORI & ARSIP JADWAL
   =================================================== */
.history-view-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
}

.history-control-card {
  padding: 18px 24px;
}

.history-control-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.history-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
}

.history-hero-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: rgba(14, 165, 233, 0.15);
  border: 1px solid rgba(14, 165, 233, 0.35);
  color: var(--cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.history-main-heading {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-pure);
  margin: 0;
}

.history-main-subheading {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 2px 0 0;
}

.history-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.history-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 6px 14px;
  min-width: 260px;
  color: var(--text-muted);
  transition: all 0.15s ease;
}

.history-search-box:focus-within {
  border-color: var(--amber);
  box-shadow: 0 0 0 2px var(--amber-subtle);
  color: var(--amber);
}

.history-search-field {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-pure);
  font-size: 0.825rem;
  width: 100%;
}

.history-search-field::placeholder {
  color: var(--text-dim);
}

.btn-clear-search {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
}

.history-list-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.history-card {
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.history-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
}

.history-card-header {
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.history-card-date-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}

.history-card-calendar-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.history-card-date {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-pure);
  margin: 0;
}

.history-card-meta-chips {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.history-meta-pill {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.history-meta-pill.pill-telegram {
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.35);
  background: rgba(14, 165, 233, 0.12);
}

.history-card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.history-card-body {
  padding: 16px 20px;
  background: #080c14;
}

.history-text-preview {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.825rem;
  line-height: 1.6;
  color: #e2e8f0;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 260px;
  overflow-y: auto;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
}

.history-empty-state {
  text-align: center;
  padding: 56px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.history-empty-icon {
  font-size: 3rem;
  margin-bottom: 12px;
  opacity: 0.8;
}

.history-empty-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-pure);
  margin: 0 0 6px;
}

.history-empty-desc {
  font-size: 0.825rem;
  color: var(--text-muted);
  max-width: 440px;
  margin: 0 auto;
}

/* ===================================================
   LAYOUT UTAMA DUA KOLOM (KIRI: FORMULIR, KANAN: OUTPUT STICKY)
   =================================================== */
.app-layout {
  display: grid;
  grid-template-columns: 1fr 500px;
  gap: 24px;
  align-items: start;
}

.layout-left {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

.layout-right {
  position: -webkit-sticky;
  position: sticky;
  top: 20px;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
  max-height: calc(100vh - 40px);
}

/* Kartu Industrial */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.card:hover {
  border-color: var(--border-active);
}

.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
  background: linear-gradient(to right, rgba(255, 255, 255, 0.02), transparent);
  display: flex;
  align-items: center;
  gap: 14px;
}

.card-header.space-between {
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.header-with-badge {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 0;
}

.card-step {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  background: var(--amber-subtle);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  font-weight: 800;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-pure);
  letter-spacing: -0.01em;
}

.card-desc {
  font-size: 0.775rem;
  color: var(--text-muted);
  margin-top: 1px;
}

.card-body {
  padding: 20px;
}

/* Form Elements Industrial */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--text-title);
  display: flex;
  align-items: center;
  gap: 4px;
}

.required {
  color: var(--amber);
  font-weight: bold;
}

.form-control {
  width: 100%;
  padding: 9px 13px;
  font-family: inherit;
  font-size: 0.875rem;
  background-color: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-title);
  outline: none;
  transition: all 0.15s ease;
}

.form-control:focus {
  background-color: var(--bg-input-focus);
  border-color: var(--amber);
  box-shadow: 0 0 0 3px var(--amber-glow);
}

.form-control::placeholder {
  color: var(--text-faint);
}

.input-highlight {
  border-color: var(--border-active);
}

/* Shortcut Cepat Tanggal */
.date-shortcuts-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.date-shortcut-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.date-pills {
  display: flex;
  gap: 8px;
}

.btn-date-pill {
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.775rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-date-pill:hover {
  background: var(--bg-canvas);
  color: var(--text-title);
  border-color: var(--border-hover);
}

.btn-date-pill.is-active {
  background: var(--amber-subtle);
  border-color: var(--amber);
  color: var(--amber);
  box-shadow: 0 0 10px var(--amber-glow);
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-items: stretch;
}

.label-with-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 24px;
  margin-bottom: 6px;
}

.date-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  height: 44px;
}

.date-input-wrap .form-control {
  height: 44px;
  padding: 0 14px;
  font-size: 0.875rem;
  border-radius: var(--radius-sm);
}

.day-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--cyan-subtle);
  border: 1px solid var(--cyan-border);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 0.725rem;
  color: var(--cyan);
  font-weight: 700;
  line-height: 1.2;
}

/* Radio Format Pemisah Tanggal */
.format-toggle-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  height: 44px;
}

.format-card-label {
  display: block;
  cursor: pointer;
  position: relative;
  height: 100%;
}

.format-card-label input[type="radio"] {
  position: absolute;
  opacity: 0;
}

.format-card-content {
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 4px 12px;
  height: 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-sizing: border-box;
  transition: all 0.15s ease;
}

.format-card-label:hover .format-card-content {
  border-color: var(--border-active);
}

.format-card-label input[type="radio"]:checked + .format-card-content {
  background: var(--amber-subtle);
  border-color: var(--amber);
  box-shadow: 0 0 10px var(--amber-glow);
}

.format-symbol {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-title);
  line-height: 1.2;
}

.format-preview {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--amber);
  margin-top: 1px;
  line-height: 1.1;
}

/* Personel Tim Tersimpan Permanen */
.field-hint-permanent {
  font-size: 0.725rem;
  color: var(--green);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.save-status-dot {
  color: var(--green);
  font-size: 0.8rem;
  line-height: 1;
}

.add-member-input-wrap {
  display: flex;
  gap: 8px;
  align-items: center;
}

.flex-grow {
  flex: 1;
}

.input-with-icon-padding {
  height: 44px !important;
  padding-left: 38px !important;
  padding-right: 12px !important;
  border-radius: var(--radius-sm) !important;
}

.btn-member-add {
  height: 44px;
  padding: 0 20px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  font-size: 0.825rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  box-shadow: 0 2px 8px var(--amber-glow);
}

.team-badges-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.team-chip {
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-body);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.team-chip:hover {
  border-color: var(--cyan-border);
  color: var(--cyan);
}

.btn-remove-chip {
  background: transparent;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  padding: 0 2px;
  transition: color 0.15s ease;
}

.btn-remove-chip:hover {
  color: var(--danger);
}

/* ================= MASTER TOPIK TUGAS ================= */
.new-topic-box {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.box-title-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.box-title-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.box-title {
  font-size: 0.925rem;
  font-weight: 700;
  color: var(--text-title);
}

.badge-edit-mode {
  background: var(--amber-subtle);
  color: var(--amber);
  border: 1px solid var(--amber-border);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.textarea-subtasks {
  font-family: var(--font-mono);
  font-size: 0.825rem;
  resize: vertical;
}

.field-hint {
  font-size: 0.725rem;
  color: var(--text-faint);
  margin-top: 2px;
}

.topic-form-actions {
  display: flex;
  gap: 8px;
}

.topics-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.section-label {
  font-size: 0.775rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.topics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
}

.topic-card {
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.topic-card:hover {
  border-color: var(--amber-border);
  background: rgba(255, 255, 255, 0.03);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

.topic-card.is-active-topic {
  border-color: var(--amber);
  background: rgba(245, 158, 11, 0.05);
  box-shadow: 0 0 14px var(--amber-glow);
}

.topic-card-header,
.topic-card-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.topic-title-wrap,
.topic-top-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.topic-badge-icon {
  width: 26px;
  height: 26px;
  border-radius: var(--radius-xs);
  background: var(--amber-subtle);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.topic-name {
  font-size: 0.925rem;
  font-weight: 700;
  color: var(--text-pure);
  line-height: 1.35;
  margin: 0 0 6px;
  word-break: break-word;
}

.topic-card-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.btn-icon-action {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-xs);
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  color: var(--text-faint);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
}

.btn-icon-action:hover {
  color: var(--amber);
  border-color: var(--amber-border);
  background: var(--amber-subtle);
}

.btn-icon-action.btn-delete-topic:hover {
  color: var(--danger);
  border-color: var(--danger-border);
  background: var(--danger-subtle);
}

.btn-icon-action.btn-pin-topic {
  width: 28px;
  height: 28px;
  padding: 0;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-icon-action.btn-pin-topic.is-active-pin {
  width: auto;
  min-width: 28px;
  padding: 0 8px;
  gap: 5px;
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.5);
  background: rgba(245, 158, 11, 0.16);
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}

.btn-icon-action.btn-pin-topic.is-active-pin:hover {
  background: rgba(245, 158, 11, 0.26);
  border-color: #fbbf24;
}

.btn-icon-action.btn-pin-topic .pin-label-text {
  font-size: 0.685rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1;
}

[data-theme="light"] .btn-icon-action.btn-pin-topic.is-active-pin {
  color: #b45309;
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.5);
}

.topic-card.is-pinned-card {
  border-color: rgba(245, 158, 11, 0.5);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25), 0 0 14px rgba(245, 158, 11, 0.18);
  position: relative;
}

.topic-card.is-pinned-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #f59e0b, #fbbf24, transparent);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}


.topic-card-body {
  flex: 1;
}

.topic-subtasks-summary {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.topic-subtasks-summary li {
  display: flex;
  align-items: center;
  gap: 6px;
}

.topic-subtasks-summary li::before {
  content: '•';
  color: var(--amber);
  font-weight: bold;
}

.topic-card-footer {
  margin-top: auto;
  padding-top: 4px;
}

.btn-card-assign {
  width: 100%;
  height: 34px;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  background: var(--amber-subtle);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  font-size: 0.775rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-card-assign:hover {
  background: var(--amber);
  color: var(--text-dark);
  box-shadow: 0 0 14px var(--amber-glow);
}

/* ================= LANGKAH 3: PILIH TOPIK & TENTUKAN TIM ================= */
.selected-topic-display {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-top: 10px;
}

.topic-preview-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.badge-accent {
  background: var(--cyan-subtle);
  color: var(--cyan);
  border: 1px solid var(--cyan-border);
  font-size: 0.675rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
}

.active-topic-title {
  font-size: 0.95rem;
  color: var(--text-pure);
}

.label-inline {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.preview-subtask-list {
  list-style: none;
  margin-top: 4px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.preview-subtask-list li {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-title);
  display: flex;
  align-items: center;
  gap: 6px;
}

.preview-subtask-list li::before {
  content: '-';
  color: var(--amber);
  font-weight: bold;
}

/* Interactive Member Picker (Avatar Pills) */
.quick-select-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
}

.btn-link {
  background: transparent;
  border: none;
  color: var(--cyan);
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0;
}

.btn-link:hover {
  text-decoration: underline;
  color: var(--cyan-hover);
}

.divider {
  color: var(--text-faint);
}

.interactive-member-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.member-avatar-pill {
  background: #151f32;
  border: 1px solid #2a3b5c;
  border-radius: var(--radius-pill);
  padding: 5px 14px 5px 6px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
  font-family: inherit;
  color: #ffffff;
  outline: none;
}

.member-avatar-pill:hover {
  border-color: #38bdf8;
  background: #1c2b45;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.2);
}

.member-avatar-pill.is-selected {
  background: rgba(245, 158, 11, 0.18) !important;
  border-color: #f59e0b !important;
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.35) !important;
}

.avatar-circle,
.pill-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #ffffff !important;
  font-size: 0.72rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  border: 1px solid rgba(56, 189, 248, 0.4);
  flex-shrink: 0;
  letter-spacing: 0.5px;
  transition: all 0.15s ease;
}

.member-avatar-pill.is-selected .avatar-circle,
.member-avatar-pill.is-selected .pill-avatar {
  background: linear-gradient(135deg, #f59e0b, #d97706) !important;
  color: #000000 !important;
  border-color: #fbbf24 !important;
}

.member-name-label,
.pill-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: #f8fafc !important;
  letter-spacing: 0.2px;
}

.member-avatar-pill.is-selected .member-name-label,
.member-avatar-pill.is-selected .pill-name {
  color: #fbbf24 !important;
}

.check-indicator,
.pill-check {
  font-size: 0.85rem;
  font-weight: 800;
  color: #38bdf8;
  display: inline-block;
  transition: all 0.15s ease;
}

.member-avatar-pill.is-selected .check-indicator,
.member-avatar-pill.is-selected .pill-check {
  color: #f59e0b !important;
}

/* Personel yang sudah bertugas dibatasi 1 topik per hari */
.member-avatar-pill.is-assigned-disabled {
  opacity: 0.55;
  cursor: not-allowed !important;
  border-style: dashed !important;
  border-color: rgba(148, 163, 184, 0.35) !important;
  background: rgba(15, 23, 42, 0.5) !important;
  box-shadow: none !important;
}

.member-avatar-pill.is-assigned-disabled:hover {
  border-color: rgba(148, 163, 184, 0.35) !important;
  background: rgba(15, 23, 42, 0.5) !important;
  box-shadow: none !important;
}

.member-avatar-pill.is-assigned-disabled .avatar-circle {
  background: #334155 !important;
  color: #94a3b8 !important;
  border-color: #475569 !important;
}

.member-avatar-pill.is-assigned-disabled .member-name-label {
  color: #94a3b8 !important;
  text-decoration: line-through;
}

.assigned-task-tag {
  font-size: 0.68rem;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  font-weight: 700;
  font-family: var(--font-mono);
  margin-left: 2px;
  white-space: nowrap;
}

.selected-members-box {
  margin-top: 10px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.btn-add-schedule {
  margin-top: 16px;
  background: var(--bg-card-elevated);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  font-weight: 700;
  transition: all 0.2s ease;
}

.btn-add-schedule:hover {
  background: var(--amber);
  color: var(--text-dark);
  box-shadow: 0 0 16px var(--amber-glow);
}

/* ================= LANGKAH 4: DAFTAR TUGAS TERJADWAL ================= */
.badge-count {
  white-space: nowrap !important;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: rgba(14, 165, 233, 0.12);
  border: 1px solid rgba(14, 165, 233, 0.35);
  color: #38bdf8;
  font-family: var(--font-mono);
  font-size: 0.775rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.badge-dot {
  font-size: 0.65rem;
  line-height: 1;
}

.badge-dot.dot-amber {
  color: #f59e0b;
}

.badge-dot.dot-green {
  color: #10b981;
}

.task-list-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

.empty-task-placeholder {
  padding: 24px;
  text-align: center;
  color: var(--text-faint);
  font-size: 0.85rem;
  border: 1px dashed var(--border-subtle);
  border-radius: var(--radius-md);
}

.task-card {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--amber);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: all 0.15s ease;
}

.task-card:hover {
  border-color: var(--border-hover);
  border-left-color: var(--amber);
  background: rgba(255, 255, 255, 0.02);
}

.task-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.task-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.task-number-pill {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 800;
  background: var(--amber-subtle);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  flex-shrink: 0;
}

.task-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-pure);
  margin: 0;
  line-height: 1.3;
}

.task-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-task-pin-toggle {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 30px;
  padding: 0 10px;
  border-radius: var(--radius-xs);
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-task-pin-toggle:hover {
  color: var(--amber);
  border-color: var(--amber-border);
  background: var(--amber-subtle);
}

.btn-task-pin-toggle.is-pinned {
  color: #fbbf24 !important;
  background: rgba(245, 158, 11, 0.18) !important;
  border-color: rgba(245, 158, 11, 0.5) !important;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}

.task-card.task-card-pinned {
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.1);
  background: linear-gradient(to right, rgba(245, 158, 11, 0.04), transparent);
}

.btn-icon-danger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 10px;
  border-radius: var(--radius-xs);
  background: var(--danger-subtle);
  border: 1px solid var(--danger-border);
  color: #f87171;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-icon-danger:hover {
  background: var(--danger);
  border-color: var(--danger-hover);
  color: #ffffff;
  box-shadow: 0 0 10px var(--danger-glow);
}

.task-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.task-meta-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.task-meta-label {
  font-size: 0.725rem;
  font-weight: 700;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  min-width: 65px;
}

.task-members-assigned {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.badge-member {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-card-elevated);
  border: 1px solid var(--cyan-border);
  color: var(--cyan);
  font-size: 0.775rem;
  font-weight: 600;
  padding: 2px 10px 2px 4px;
  border-radius: var(--radius-pill);
}

.member-chip-avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--cyan-subtle);
  color: var(--cyan);
  font-size: 0.65rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.task-subtasks-preview {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.task-subtasks-content {
  flex: 1;
}

.task-subtask-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  padding: 0;
}

.task-subtask-list li {
  font-family: var(--font-mono);
  font-size: 0.775rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.task-subtask-list li::before {
  content: '•';
  color: var(--amber);
  font-weight: bold;
}

/* ================= KETERANGAN PERSONEL BELUM MASUK JADWAL (GAMBAR 4) ================= */
.unscheduled-personnel-box {
  margin-top: 14px;
  margin-bottom: 16px;
  background: rgba(245, 158, 11, 0.05);
  border: 1px dashed rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.unscheduled-box-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.unscheduled-header-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.unscheduled-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.unscheduled-heading {
  font-size: 0.88rem;
  font-weight: 700;
  color: #fbbf24;
  margin: 0;
  line-height: 1.3;
}

.unscheduled-subheading {
  font-size: 0.74rem;
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}

.badge-unscheduled-count {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  white-space: nowrap;
}

.unscheduled-chips-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.unscheduled-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 12px 4px 6px;
  border-radius: var(--radius-pill);
  background: #151f32;
  border: 1px solid #2a3b5c;
  color: #f1f5f9;
  font-size: 0.82rem;
  font-weight: 600;
  transition: all 0.15s ease;
}

.unscheduled-chip:hover {
  border-color: #f59e0b;
  background: #1c2b45;
}

.unscheduled-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #334155;
  color: #f8fafc;
  font-size: 0.65rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
}

.unscheduled-name {
  font-weight: 600;
}

.unscheduled-status-dot {
  color: #f59e0b;
  font-size: 0.65rem;
  line-height: 1;
  margin-left: 2px;
}

/* Status jika semua personel sudah terjadwal */
.all-scheduled-box {
  margin-top: 14px;
  margin-bottom: 16px;
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-md);
  padding: 12px 16px;
}

.all-scheduled-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.all-scheduled-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.all-scheduled-heading {
  font-size: 0.88rem;
  font-weight: 700;
  color: #34d399;
  margin: 0;
  line-height: 1.3;
}

.all-scheduled-subheading {
  font-size: 0.74rem;
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}

.btn-generate-main {
  background: linear-gradient(135deg, var(--green), var(--green-hover));
  color: #ffffff;
  border: none;
  font-weight: 700;
  box-shadow: 0 4px 16px var(--green-glow);
  transition: all 0.2s ease;
}

.btn-generate-main:hover {
  box-shadow: 0 6px 22px rgba(16, 185, 129, 0.4);
  transform: translateY(-1px);
}

/* ===================================================
   KOLOM KANAN: OUTPUT TERMINAL INDUSTRIAL DISPATCH
   =================================================== */
.sticky-output {
  position: -webkit-sticky;
  position: sticky;
  top: 20px;
  max-height: calc(100vh - 40px);
  display: flex;
  flex-direction: column;
}

.terminal-window-header {
  background: #080c14 !important;
  border-bottom: 1px solid #1f293d !important;
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  min-height: 48px;
}

.terminal-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  min-width: 0;
}

.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dot-red { background: #ef4444; }
.dot-yellow { background: #f59e0b; }
.dot-green { background: #10b981; }

.terminal-filename {
  font-family: var(--font-mono);
  font-size: 0.725rem;
  font-weight: 600;
  color: #94a3b8 !important;
  background: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  margin-left: 4px;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.terminal-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  margin-left: auto;
}

.btn-copy {
  background: rgba(245, 158, 11, 0.15) !important;
  border: 1px solid rgba(245, 158, 11, 0.4) !important;
  color: #fbbf24 !important;
  font-size: 0.75rem;
  font-weight: 700;
  height: 32px;
  padding: 0 11px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  box-sizing: border-box;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-copy:hover:not(:disabled) {
  background: #f59e0b !important;
  color: #080c14 !important;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}

.btn-copy:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.terminal-body {
  background: #080c14;
  padding: 20px;
}

.output-placeholder-box {
  padding: 48px 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.placeholder-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-faint);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-title);
}

.placeholder-text {
  font-size: 0.8rem;
  color: var(--text-muted);
  max-width: 320px;
  line-height: 1.5;
}

.output-content-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.copy-success-banner {
  display: none;
  background: var(--green-subtle);
  border: 1px solid var(--green-border);
  color: var(--green);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  align-items: center;
  gap: 8px;
}

.copy-success-banner.visible {
  display: flex;
}

.terminal-editor-container {
  background: #05080e;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  overflow-x: auto;
  overflow-y: auto;
  max-height: calc(100vh - 240px);
}

.schedule-output {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.6;
  color: #e2e8f0;
  white-space: pre-wrap;
  word-break: break-word;
}

.terminal-title-bold {
  font-weight: 800;
  color: #ffffff;
  display: inline-block;
}

.terminal-divider-line {
  color: var(--amber);
  opacity: 0.85;
  font-weight: 700;
  display: inline-block;
}

html[data-theme="light"] .terminal-title-bold {
  color: #0f172a;
}

.terminal-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  border-top: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.725rem;
  color: var(--text-faint);
}

.ready-badge {
  color: var(--green);
  font-weight: 600;
}

.terminal-status-tools {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-terminal-download-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-xs);
  color: #94a3b8;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  text-decoration: none;
}

.btn-terminal-download-link:hover:not(:disabled) {
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.12);
}

.btn-terminal-download-link:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  display: none;
}

/* ================= FLOATING ACTION BUTTON (POJOK KANAN BAWAH) ================= */
.floating-schedule-pill {
  position: fixed;
  bottom: 24px;
  right: 28px;
  z-index: 9000;
  background: linear-gradient(135deg, #0ea5e9, #0284c7);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius-pill);
  padding: 10px 18px 10px 14px;
  color: #ffffff;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: 0 10px 25px -5px rgba(14, 165, 233, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  outline: none;
}

.floating-schedule-pill:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -4px rgba(14, 165, 233, 0.65), 0 10px 12px -5px rgba(0, 0, 0, 0.4);
  background: linear-gradient(135deg, #38bdf8, #0ea5e9);
}

.floating-pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 8px #34d399;
  animation: pulse-live 1.8s infinite;
}

.floating-pill-badge {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-size: 0.725rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
}

/* ================= FLOATING SCHEDULE DRAWER ================= */
.floating-drawer-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  padding: 24px;
  pointer-events: none;
}

.floating-drawer-container.hidden {
  display: none !important;
}

.floating-drawer-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(4, 7, 14, 0.55);
  backdrop-filter: blur(3px);
  pointer-events: auto;
  opacity: 1;
  transition: opacity 0.2s ease;
}

.floating-drawer-card {
  position: relative;
  z-index: 10001;
  pointer-events: auto;
  width: 580px;
  max-width: calc(100vw - 48px);
  max-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.85), 0 0 30px rgba(14, 165, 233, 0.2);
  border: 1px solid var(--border-active);
  border-radius: var(--radius-lg);
  overflow: hidden;
  animation: drawer-pop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes drawer-pop {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.btn-close-drawer {
  background: transparent;
  border: none;
  color: var(--text-faint);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  transition: all 0.15s ease;
  margin-left: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-close-drawer:hover {
  color: var(--danger);
  background: var(--danger-subtle);
}

.terminal-controls .dot-red {
  cursor: pointer;
}

/* ================= TOMBOL UMUM ================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s ease;
}

.btn-sm {
  padding: 5px 10px;
  font-size: 0.75rem;
}

.btn-lg {
  padding: 11px 18px;
  font-size: 0.925rem;
}

.btn-block {
  width: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, var(--amber), var(--amber-dark));
  color: var(--text-dark);
  border: none;
  font-weight: 700;
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--amber-hover), var(--amber));
  box-shadow: 0 0 16px var(--amber-glow);
}

.btn-outline-amber {
  background: transparent;
  border: 1px solid var(--amber-border);
  color: var(--amber);
}

.btn-outline-amber:hover {
  background: var(--amber-subtle);
  border-color: var(--amber);
}

.btn-outline-secondary {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
}

.btn-outline-secondary:hover {
  background: var(--bg-card-elevated);
  color: var(--text-title);
  border-color: var(--border-hover);
}

.btn-outline-danger {
  background: transparent;
  border: 1px solid var(--danger-border);
  color: #f87171;
}

.btn-outline-danger:hover {
  background: var(--danger-subtle);
  color: #fca5a5;
  border-color: var(--danger);
}

.btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff !important;
  border: 1px solid rgba(239, 68, 68, 0.4);
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
  background: linear-gradient(135deg, #f87171, #ef4444);
  border-color: #f87171;
  box-shadow: 0 6px 18px rgba(239, 68, 68, 0.45);
  color: #ffffff !important;
}

.btn-danger:active {
  transform: translateY(1px);
}

/* Footer Aplikasi */
.app-footer {
  text-align: center;
  padding: 16px 0;
  color: var(--text-faint);
  font-size: 0.75rem;
  border-top: 1px solid var(--border-subtle);
}

/* Toast Pop-up */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--bg-card-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-pure);
  padding: 12px 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  font-size: 0.85rem;
  font-weight: 600;
  z-index: 9999;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.25s ease;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast-success {
  border-color: var(--green-border);
  background: #064e3b;
  color: #d1fae5;
}

.toast-info {
  border-color: var(--cyan-border);
  background: #0c4a6e;
  color: #e0f2fe;
}

.btn-outline-cyan {
  background: transparent;
  border: 1px solid var(--cyan-border);
  color: var(--cyan);
}

.btn-outline-cyan:hover {
  background: var(--cyan-subtle);
  border-color: var(--cyan);
}

/* Tombol Kirim ke Telegram */
.btn-telegram {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #ffffff;
  border: 1px solid #38bdf8;
  font-weight: 700;
  height: 32px;
  padding: 0 11px;
  font-size: 0.75rem;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  box-sizing: border-box;
  box-shadow: 0 2px 8px rgba(2, 132, 199, 0.3);
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-telegram:hover:not(:disabled) {
  background: linear-gradient(135deg, #0ea5e9, #0284c7);
  box-shadow: 0 4px 14px rgba(14, 165, 233, 0.45);
  transform: translateY(-1px);
}

.btn-telegram:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  box-shadow: none;
}

/* ================= MODAL PENUGASAN PERSONEL KERJA (GAMBAR 1) ================= */
.modal-card-assign {
  max-width: 520px;
}

.modal-icon-topic {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--amber-subtle);
  border: 1px solid var(--amber-border);
  color: var(--amber);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.assign-topic-preview {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--amber);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.assign-topic-header-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.assign-topic-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-pure);
}

.assign-topic-subtasks {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.assign-subtasks-list {
  list-style: none;
  margin-top: 4px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0;
}

.assign-subtasks-list li {
  font-family: var(--font-mono);
  font-size: 0.775rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.assign-subtasks-list li::before {
  content: '•';
  color: var(--amber);
  font-weight: bold;
}

.assign-member-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
  max-height: 180px;
  overflow-y: auto;
  padding: 2px;
}

.assign-pill {
  padding: 6px 14px 6px 8px;
  cursor: pointer;
  border-radius: var(--radius-pill);
}

.assign-quick-add-box {
  background: var(--bg-card-inner);
  border: 1px dashed var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.quick-add-label {
  font-size: 0.725rem;
  font-weight: 600;
  color: var(--text-faint);
}

.quick-add-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.quick-add-row input {
  height: 34px;
  padding: 0 10px;
  font-size: 0.8rem;
  flex: 1;
}

.quick-add-row button {
  height: 34px;
  padding: 0 14px;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

.btn-confirm-add {
  height: 36px;
  padding: 0 18px;
  font-weight: 700;
  font-size: 0.825rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Status Dot Telegram */
.tele-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
  margin-left: 2px;
}

.tele-status-dot.dot-active {
  background-color: var(--green);
  box-shadow: 0 0 6px var(--green);
}

.tele-status-dot.dot-inactive {
  background-color: var(--text-faint);
}

/* Tombol Ganti Tema (Theme Toggle) */
.btn-theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.theme-icon-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-theme-bar {
  position: absolute;
  top: 24px;
  right: 28px;
  z-index: 20;
  display: flex;
  justify-content: flex-end;
}

/* ================= MODAL DIALOG TELEGRAM ================= */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(4, 7, 14, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 20px;
  animation: modal-fade-in 0.2s ease-out;
}

@keyframes modal-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-card {
  width: 100%;
  max-width: 540px;
  background: var(--bg-card) !important;
  border: 1px solid var(--border-active);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8), 0 0 20px rgba(14, 165, 233, 0.2);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 10001;
  animation: modal-slide-in 0.2s ease-out;
}

@keyframes modal-slide-in {
  from { transform: translateY(15px); }
  to { transform: translateY(0); }
}

.modal-header {
  padding: 16px 20px;
  background-color: var(--bg-card-elevated);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-icon-tele {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--cyan-subtle);
  border: 1px solid var(--cyan-border);
  color: var(--cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.modal-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-pure);
}

.modal-subtitle {
  font-size: 0.775rem;
  color: var(--text-muted);
  margin-top: 1px;
}

.btn-modal-close {
  background: transparent;
  border: none;
  color: var(--text-faint);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  border-radius: var(--radius-xs);
  transition: all 0.15s ease;
}

.btn-modal-close:hover {
  color: var(--text-pure);
  background: var(--bg-card-inner);
}

.modal-body {
  padding: 20px;
  background-color: var(--bg-card);
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 75vh;
  overflow-y: auto;
}

.tele-status-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
}

.tele-status-banner.banner-active {
  background: var(--green-subtle);
  border: 1px solid var(--green-border);
  color: var(--green);
}

.tele-status-banner.banner-inactive {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
}

.status-indicator-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.field-link {
  font-size: 0.75rem;
  color: var(--cyan);
  text-decoration: none;
  font-weight: 600;
}

.field-link:hover {
  text-decoration: underline;
}

.tele-format-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.tele-radio-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.825rem;
  color: var(--text-body);
  cursor: pointer;
}

.tele-radio-label input[type="radio"] {
  accent-color: var(--cyan);
}

.tele-test-feedback {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.785rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tele-test-feedback.is-success {
  background: var(--green-subtle);
  border: 1px solid var(--green-border);
  color: var(--green);
}

.tele-test-feedback.is-error {
  background: var(--danger-subtle);
  border: 1px solid var(--danger-border);
  color: #fca5a5;
}

.modal-footer {
  padding: 14px 20px;
  background: var(--bg-card-elevated);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.modal-footer-right {
  display: flex;
  gap: 10px;
  margin-left: auto;
}

/* ================= MODAL KONFIRMASI KUSTOM (INDUSTRIAL NOC) ================= */
.modal-card-confirm {
  max-width: 440px !important;
  border-color: rgba(239, 68, 68, 0.45) !important;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.85), 0 0 24px rgba(239, 68, 68, 0.2) !important;
  animation: modalScaleIn 0.22s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

@keyframes modalScaleIn {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.confirm-modal-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  background: var(--bg-card-elevated);
  border-bottom: 1px solid var(--border-subtle);
}

.confirm-modal-icon-wrap {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #f87171;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.confirm-modal-icon-wrap.is-warning {
  background: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

.confirm-modal-title-box {
  flex: 1;
}

.confirm-modal-title-box .modal-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-pure);
  margin: 0;
}

.confirm-badge {
  font-size: 0.675rem;
  font-weight: 700;
  color: #f87171;
  margin: 2px 0 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.confirm-modal-body {
  padding: 20px 24px;
}

.confirm-message-text {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-pure);
  line-height: 1.5;
  margin: 0 0 6px;
}

.confirm-submessage-text {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin: 0;
}

.confirm-modal-footer {
  padding: 14px 24px;
  background: rgba(0, 0, 0, 0.18);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

[data-theme="light"] .confirm-modal-footer {
  background: #f8fafc;
}

[data-theme="light"] .modal-card-confirm {
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.18), 0 0 15px rgba(239, 68, 68, 0.15) !important;
}

/* ================= RESPONSIVE DESIGN ================= */
@media (max-width: 992px) {
  .login-split-card {
    grid-template-columns: 1fr;
  }

  .login-hero-pane {
    border-right: none;
    border-bottom: 1px solid var(--border-subtle);
    padding: 32px 24px;
  }

  .login-form-pane {
    padding: 32px 24px;
  }

  .app-layout {
    grid-template-columns: 1fr;
  }

  .layout-right {
    position: static;
    max-height: none;
  }

  .sticky-output {
    position: static;
    max-height: none;
  }

  .form-grid-2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .app-container {
    padding: 14px 12px 36px;
  }

  .app-header {
    padding: 14px 16px;
  }

  .app-title {
    font-size: 1.2rem;
  }

  .hero-headline {
    font-size: 1.45rem;
  }

  .quick-login-buttons {
    grid-template-columns: 1fr;
  }
}

/* ================= OVERRIDES TEMA TERANG (LIGHT THEME) ================= */
html[data-theme="light"] .member-avatar-pill {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}

html[data-theme="light"] .member-avatar-pill:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
}

html[data-theme="light"] .member-avatar-pill.is-selected {
  background: #fef3c7 !important;
  border-color: #d97706 !important;
  box-shadow: 0 0 12px rgba(217, 119, 6, 0.25) !important;
}

html[data-theme="light"] .member-avatar-pill.is-selected .member-name-label {
  color: #92400e !important;
}

html[data-theme="light"] .member-avatar-pill .member-name-label {
  color: #0f172a !important;
}

html[data-theme="light"] .badge-count {
  background: #e0f2fe;
  border-color: #bae6fd;
  color: #0369a1;
}

html[data-theme="light"] .unscheduled-personnel-box {
  background: #fffbeb;
  border-color: #fcd34d;
}

html[data-theme="light"] .unscheduled-heading {
  color: #b45309;
}

html[data-theme="light"] .badge-unscheduled-count {
  background: #fef3c7;
  border-color: #fcd34d;
  color: #b45309;
}

html[data-theme="light"] .unscheduled-chip {
  background: #ffffff;
  border-color: #cbd5e1;
  color: #1e293b;
}

html[data-theme="light"] .unscheduled-avatar {
  background: #e2e8f0;
  color: #334155;
}

html[data-theme="light"] .all-scheduled-box {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

html[data-theme="light"] .all-scheduled-heading {
  color: #059669;
}

/* ================= RESPONSIVE HEADER & FLOATING DRAWER ================= */
@media (max-width: 900px) {
  .header-top-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .user-profile-widget {
    align-self: flex-start;
  }

  .header-toolbar-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .header-action-buttons {
    margin-left: 0;
    width: 100%;
    justify-content: flex-start;
  }
}

html[data-theme="light"] .floating-schedule-pill {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #ffffff;
  box-shadow: 0 10px 25px -5px rgba(2, 132, 199, 0.4);
}

html[data-theme="light"] .floating-drawer-backdrop {
  background: rgba(15, 23, 42, 0.4);
}

html[data-theme="light"] .terminal-window-header {
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
}

html[data-theme="light"] .terminal-filename {
  color: #334155 !important;
  background: #e2e8f0 !important;
  border-color: #cbd5e1 !important;
}

html[data-theme="light"] .btn-close-drawer {
  color: #64748b;
}

html[data-theme="light"] .btn-close-drawer:hover {
  color: #dc2626;
  background: #fee2e2;
}

html[data-theme="light"] .terminal-body {
  background: #ffffff;
}
