/* ============================================================================
   ADO DONDURMA — SİBEL HAKTANIR KURUMSAL ERP V14.0 STİL SİSTEMİ
   - FAZ 6: Masaüstü dikey ekran doldurma, iç dikey/yatay scroll, sticky header & footer
   - FAZ 8.1: Accordion Ayarlar yapısı
   - FAZ 8.2: Her zaman Açık Tema (Light Theme) korumalı Login ekranı
   - FAZ 9: 2 Kademeli (Yarı Mamül & Nihai Ürün) MRP ekran düzeni
   ============================================================================ */

:root {
  --bg-body: #f1f5f9;
  --bg-surface: #ffffff;
  --bg-surface-2: #f8fafc;
  --bg-surface-hover: #f1f5f9;
  --text-main: #0f172a;
  --text-primary: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --border: #cbd5e1;
  --border-subtle: #e2e8f0;
  --primary: #0284c7;
  --primary-hover: #0369a1;
  --info-soft: #e0f2fe;
  --success: #16a34a;
  --success-soft: #dcfce7;
  --warning: #d97706;
  --warning-soft: #fef3c7;
  --danger: #dc2626;
  --danger-soft: #fee2e2;
  --purple: #7c3aed;
  --purple-soft: #ede9fe;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.12);
}

[data-theme="dark"] {
  --bg-body: #0b1120;
  --bg-surface: #111827;
  --bg-surface-2: #1e293b;
  --bg-surface-hover: #263349;
  --text-main: #f8fafc;
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --border: #334155;
  --border-subtle: #1e293b;
  --primary: #38bdf8;
  --primary-hover: #0ea5e9;
  --info-soft: rgba(56, 189, 248, 0.16);
  --success: #22c55e;
  --success-soft: rgba(34, 197, 94, 0.16);
  --warning: #f59e0b;
  --warning-soft: rgba(245, 158, 11, 0.16);
  --danger: #ef4444;
  --danger-soft: rgba(239, 68, 68, 0.16);
  --purple: #a78bfa;
  --purple-soft: rgba(167, 139, 250, 0.16);
}

*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 13px;
  color: var(--text-main);
  background: var(--bg-body);
  height: 100%;
}

.font-mono {
  font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

.text-right { text-align: right !important; }
.text-center { text-align: center !important; }
.text-left { text-align: left !important; }
.req-star { color: var(--danger); font-weight: 700; }

/* ==================== FAZ 8.2: HER ZAMAN AÇIK TEMA LOGIN EKRANI ==================== */
#auth-login-overlay {
  --login-bg: #f1f5f9;
  --login-card-bg: #ffffff;
  --login-text: #0f172a;
  --login-muted: #475569;
  --login-border: #cbd5e1;
  --login-input-bg: #ffffff;
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%) !important;
  color: #0f172a !important;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#auth-login-overlay.hidden {
  display: none !important;
}

.auth-login-card {
  width: min(94vw, 420px);
  background: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 14px;
  padding: 28px 26px;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.14);
}

.auth-login-card input.input {
  background: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid #cbd5e1 !important;
}

.auth-login-card .form-label {
  color: #334155 !important;
}

.auth-login-error {
  display: none;
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fee2e2 !important;
  color: #dc2626 !important;
  border: 1px solid #fca5a5 !important;
  font-size: 12.5px;
  font-weight: 600;
}

.auth-login-error.visible {
  display: block;
}

/* ==================== TOP NAVBAR (FAZ 8.3: SOL LOGO + SAĞ ÜST ANA EKRAN BUTONU) ==================== */
.app-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.top-header {
  height: 58px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1 1 auto;
}

.header-brand-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 3px 6px;
  cursor: pointer;
}

.header-brand-box:hover {
  background: var(--bg-surface-2);
  border-color: var(--border);
}

.header-brand-logo {
  height: 36px;
  width: auto;
  display: block;
}

.header-divider {
  width: 1px;
  height: 26px;
  background: var(--border);
}

.page-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.page-subtitle {
  font-size: 11.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ==================== FAZ 6.1: MASAÜSTÜ DİKEY EKRAN DOLDURMA & STICKY SCROLL ==================== */
.content-area {
  flex: 1 1 auto;
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
}

@media (min-width: 769px) {
  .app-shell {
    height: 100vh;
    overflow: hidden;
  }
  .content-area {
    height: calc(100vh - 58px);
    overflow: hidden;
  }
  #tab-launchpad.tab-pane.active,
  #tab-settings.tab-pane.active,
  #tab-mrp.tab-pane.active {
    overflow-y: auto;
  }
  .module-panel {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: 100%;
    overflow: hidden;
  }
  .module-panel > .table-container {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto !important;
  }
}

.module-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.module-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-surface);
  flex-shrink: 0;
  flex-wrap: wrap;
}

.toolbar-filters, .toolbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* ==================== LAUNCHPAD (ANA EKRAN) MINIMALIST CARDS ==================== */
.launchpad-wrap {
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-bottom: 24px;
}

.launchpad-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  box-shadow: var(--shadow-sm);
}

.launchpad-brand-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.launchpad-company {
  font-size: 15.5px;
  font-weight: 800;
  color: var(--text-main);
}

.launchpad-address {
  font-size: 12px;
  color: var(--text-muted);
}

.domain-section {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  box-shadow: var(--shadow-sm);
}

.domain-header {
  margin-bottom: 10px;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--border-subtle);
}

.domain-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--text-secondary);
}

.launchpad-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
  gap: 10px;
}

.lp-tile.lp-tile-minimal {
  height: 58px;
  min-height: 58px;
  padding: 10px 14px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  background: var(--bg-surface-2);
  border: 1px solid var(--border);
  border-radius: 9px;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.14s ease, background-color 0.14s ease, box-shadow 0.14s ease;
}

.lp-tile.lp-tile-minimal:hover {
  border-color: var(--primary);
  background: var(--bg-surface);
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.06);
}

.lp-tile.lp-tile-minimal .lp-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--info-soft);
  color: var(--primary);
  flex-shrink: 0;
}

.lp-tile.lp-tile-minimal .lp-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==================== FAZ 6: ORTAK EXCEL TABLO MOTORU (STICKY HEADER/FOOTER & RESIZE) ==================== */
.table-container {
  width: 100%;
  max-width: 100%;
  overflow: auto;
  position: relative;
}

table.erp-excel-fixed-table {
  table-layout: fixed !important;
  border-collapse: separate;
  border-spacing: 0;
}

table.erp-excel-fixed-table th,
table.erp-excel-fixed-table td {
  padding: 8px 10px;
  font-size: 12.5px;
  border-bottom: 1px solid var(--border-subtle);
  border-right: 1px solid rgba(148, 163, 184, 0.22);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  box-sizing: border-box;
}

table.erp-excel-fixed-table thead th {
  position: sticky;
  top: 0;
  z-index: 15;
  background: var(--bg-surface-2);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  border-bottom: 2px solid var(--border);
  user-select: none;
}

table.erp-excel-fixed-table tfoot td,
table.erp-excel-fixed-table tfoot th {
  position: sticky;
  bottom: 0;
  z-index: 14;
  background: var(--bg-surface-2);
  font-weight: 700;
  border-top: 2px solid var(--border);
  box-shadow: 0 -1px 3px rgba(15, 23, 42, 0.05);
}

table.erp-excel-fixed-table tbody tr:hover td {
  background: var(--bg-surface-hover);
}

table.erp-excel-fixed-table tbody tr.row-selected td {
  background: var(--info-soft);
}

.col-sel {
  width: 38px !important;
  min-width: 38px !important;
  max-width: 38px !important;
  text-align: center !important;
  padding: 6px 4px !important;
}

.col-resizer {
  position: absolute;
  top: 0;
  right: -3px;
  width: 8px;
  height: 100%;
  cursor: col-resize !important;
  z-index: 22;
  background: transparent;
}

.col-resizer:hover,
.col-resizer.is-resizing {
  background: var(--primary) !important;
  opacity: 0.8;
}

th.col-drag-over {
  outline: 2px dashed var(--primary) !important;
  background: var(--info-soft) !important;
}

/* ==================== BUTTONS, INPUTS, BADGES & POP-UPS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 13px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.14s ease;
  white-space: nowrap;
}

.btn-sm { padding: 4px 9px; font-size: 11.5px; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); }
.btn-success { background: var(--success); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-warning { background: var(--warning); color: #fff; }
.btn-outline { background: var(--bg-surface); color: var(--text-main); border-color: var(--border); }
.btn-outline:hover { background: var(--bg-surface-2); border-color: var(--primary); }

.input, .select {
  width: 100%;
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-surface);
  color: var(--text-main);
  font-family: inherit;
  font-size: 12.5px;
}

.input:focus, .select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(2, 132, 199, 0.15);
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.badge-info { background: var(--info-soft); color: var(--primary); }
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-purple { background: var(--purple-soft); color: var(--purple); }
.badge-neutral { background: var(--bg-surface-2); color: var(--text-secondary); border: 1px solid var(--border); }

/* ==================== MODALS (1340px WIDE & BACKDROP CLICK SUPPORT) ==================== */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1100;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(3px);
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-backdrop.open,
.modal-backdrop.active {
  display: flex;
}

.modal-content {
  width: min(94vw, 760px);
  max-width: 760px;
  max-height: 92vh;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-content.modal-lg {
  width: min(96vw, 1340px) !important;
  max-width: 1340px !important;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-surface-2);
}

.modal-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-main);
}

.modal-body {
  padding: 16px 18px;
  overflow-y: auto;
  flex: 1 1 auto;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 18px;
  border-top: 1px solid var(--border);
  background: var(--bg-surface-2);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.form-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.form-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.form-group.full {
  grid-column: 1 / -1;
}
.form-label {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* ==================== FAZ 8.1: ACCORDION AYARLAR EKRANI ==================== */
.settings-accordion-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
}

.settings-accordion-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  overflow: hidden;
}

.settings-accordion-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  background: var(--bg-surface-2);
  border: none;
  color: var(--text-main);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
  transition: background-color 0.14s ease;
}

.settings-accordion-header:hover {
  background: var(--bg-surface-hover);
}

.settings-accordion-body {
  display: none;
  padding: 16px;
  border-top: 1px solid var(--border);
  background: var(--bg-surface);
}

.settings-accordion-item.expanded .settings-accordion-body {
  display: block;
}

.settings-accordion-chevron {
  transition: transform 0.18s ease;
  font-size: 12px;
  color: var(--text-muted);
}

.settings-accordion-item.expanded .settings-accordion-chevron {
  transform: rotate(180deg);
}

/* ==================== FAZ 9: 2 KADEMELİ MRP EKRAN DÜZENİ ==================== */
.mrp-stage-tabs {
  display: flex;
  gap: 10px;
  padding: 12px 16px;
  background: var(--bg-surface-2);
  border-bottom: 1px solid var(--border);
}

.mrp-stage-btn {
  padding: 9px 18px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-surface);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
}

.mrp-stage-btn.active {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
}

.mrp-dual-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 14px 16px;
}

.mrp-panel-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  overflow: hidden;
}

.mrp-panel-hdr {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  background: var(--bg-surface-2);
  border-bottom: 1px solid var(--border);
  font-weight: 800;
  font-size: 13px;
}

/* Filter & Column Config Popovers */
.adv-filter-panel {
  display: none;
  padding: 14px 16px;
  background: var(--bg-surface-2);
  border-bottom: 1px solid var(--border);
}
.adv-filter-panel.open { display: block; }
.adv-filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}
.adv-filter-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
}
.adv-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 6px 14px;
}
.adv-filter-chips:empty { display: none; }
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--info-soft);
  color: var(--primary);
  font-size: 11.5px;
}
.bulk-action-bar {
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  background: var(--info-soft);
  border-bottom: 1px solid var(--primary);
}
.bulk-action-bar.active { display: flex; }

.col-config-wrap { position: relative; }
.col-config-popover {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  width: 240px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 10px;
  z-index: 90;
}
.col-config-popover.open { display: block; }

#toast-container {
  position: fixed;
  bottom: 18px;
  right: 18px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast-msg {
  padding: 11px 16px;
  border-radius: 8px;
  background: #0f172a;
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: var(--shadow-md);
}
.toast-msg.error { background: #dc2626; }


/* ==================== V14.4: FREEZE TOP ROW (STICKY THEAD) & LOCKED ACTION COLUMN ==================== */
.table-container {
  width: 100%;
  max-width: 100%;
  max-height: calc(100vh - 175px);
  overflow-y: auto !important;
  overflow-x: auto !important;
  position: relative;
}

.mrp-panel-card .table-container {
  max-height: 340px !important;
  overflow-y: auto !important;
}

table.erp-excel-fixed-table thead tr th {
  position: sticky !important;
  top: 0 !important;
  z-index: 30 !important;
  background: var(--bg-surface-2) !important;
  box-shadow: 0 2px 4px rgba(15, 23, 42, 0.08);
}

table.erp-excel-fixed-table th[data-col-id="islem"],
table.erp-excel-fixed-table td[data-col-id="islem"],
table.erp-excel-fixed-table th[data-col-id="aktarim"],
table.erp-excel-fixed-table td[data-col-id="aktarim"] {
  overflow: visible !important;
  text-overflow: clip !important;
  white-space: nowrap !important;
}

table.erp-excel-fixed-table td[data-col-id="islem"] .btn,
table.erp-excel-fixed-table td[data-col-id="aktarim"] .btn {
  flex-shrink: 0 !important;
}


/* ==================== V14.7: ELEGANT, MINIMALIST & EYE-FRIENDLY LAUNCHPAD ==================== */
.launchpad-wrap {
  max-width: 1120px;
  width: 100%;
  margin: 18px auto 32px auto;
  padding: 0 8px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.domain-section {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 18px 22px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.035);
}

.domain-header {
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.domain-title {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

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

.lp-tile.lp-tile-minimal {
  height: 62px;
  min-height: 62px;
  padding: 12px 16px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 11px;
  cursor: pointer;
  text-align: left;
  transition: transform 0.15s ease, border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.lp-tile.lp-tile-minimal:hover {
  border-color: var(--primary);
  background: var(--bg-surface);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.08);
  transform: translateY(-1px);
}

.lp-tile-left {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
  flex: 1;
}

.lp-tile.lp-tile-minimal .lp-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--info-soft);
  color: var(--primary);
  flex-shrink: 0;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.lp-tile.lp-tile-minimal:hover .lp-icon {
  background: var(--primary);
  color: #ffffff;
}

.lp-tile.lp-tile-minimal .lp-icon svg {
  width: 19px;
  height: 19px;
  stroke: currentColor;
}

.lp-tile.lp-tile-minimal .lp-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-main);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lp-tile-arrow {
  color: var(--text-muted);
  opacity: 0.45;
  display: inline-flex;
  align-items: center;
  transition: opacity 0.15s ease, transform 0.15s ease, color 0.15s ease;
}

.lp-tile.lp-tile-minimal:hover .lp-tile-arrow {
  opacity: 1;
  color: var(--primary);
  transform: translateX(2px);
}


/* ==================== V14.7: MRP KPI STRIP & FULL MOBILE RESPONSIVENESS (360px - 768px) ==================== */
.mrp-kpi-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(195px, 1fr));
  gap: 10px;
  padding: 12px 16px 4px 16px;
}

.mrp-kpi-card {
  background: var(--bg-surface-2);
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 10px 14px;
}

.mrp-kpi-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.mrp-kpi-value {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-main);
  font-family: 'JetBrains Mono', monospace;
}

@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
  }
  .top-header {
    padding: 8px 10px;
    flex-wrap: wrap;
    height: auto;
    min-height: 54px;
    gap: 8px;
  }
  .header-right {
    gap: 6px;
    flex-wrap: wrap;
  }
  .content-area {
    padding: 8px;
    height: auto;
    min-height: calc(100vh - 60px);
    overflow-y: auto;
    overflow-x: hidden;
  }
  .launchpad-wrap {
    margin: 8px auto 20px auto;
    padding: 0 2px;
    gap: 12px;
  }
  .domain-section {
    padding: 12px 14px;
  }
  .launchpad-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .module-toolbar {
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
  }
  .toolbar-filters, .toolbar-actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }
  .toolbar-filters .select,
  .toolbar-filters .input,
  .toolbar-actions .btn {
    width: 100% !important;
  }
  .mrp-stage-tabs {
    flex-direction: column;
    gap: 6px;
    padding: 10px;
  }
  .mrp-stage-btn {
    width: 100%;
    text-align: center;
  }
  .form-grid, .form-grid-3, .form-grid-4 {
    grid-template-columns: 1fr !important;
  }
  .form-group[style*="grid-column"] {
    grid-column: 1 / -1 !important;
  }
  .modal-backdrop {
    padding: 6px;
  }
  .modal-content, .modal-content.modal-lg {
    width: 98vw !important;
    max-width: 98vw !important;
    max-height: 94vh;
  }
  .modal-footer {
    flex-wrap: wrap;
  }
  .modal-footer .btn {
    flex: 1 1 auto;
  }
}


/* ==================== V14.9: REMOVE NUMBER INPUT SPINNERS (UP/DOWN ARROWS) ==================== */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none !important;
  margin: 0 !important;
}
input[type="number"] {
  -moz-appearance: textfield !important;
  appearance: textfield !important;
}
