/* ════════════════════════════════════════════
   HDD As-Built Profile Maker — Main Stylesheet
   ════════════════════════════════════════════ */

:root {
  --primary:       #1a6fc4;
  --primary-dark:  #135299;
  --primary-light: #e8f0fb;
  --accent:        #f59e0b;
  --success:       #16a34a;
  --danger:        #dc2626;
  --danger-light:  #fee2e2;
  --surface:       #ffffff;
  --bg:            #f0f4f9;
  --border:        #d1d9e6;
  --text:          #1e293b;
  --text-muted:    #64748b;
  --text-light:    #94a3b8;
  --shadow:        0 2px 12px rgba(0,0,0,0.09);
  --shadow-lg:     0 8px 32px rgba(0,0,0,0.13);
  --radius:        10px;
  --radius-sm:     6px;
  --font:          'Inter', sans-serif;
  --font-mono:     'Roboto Mono', monospace;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.5;
}

/* ── HEADER ── */
.app-header {
  background: linear-gradient(135deg, #0f2d5e 0%, #1a6fc4 100%);
  color: #fff;
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: 0 3px 16px rgba(15,45,94,0.35);
  position: sticky;
  top: 0;
  z-index: 100;
}

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

.logo-icon {
  width: 46px; height: 46px;
  background: rgba(255,255,255,0.15);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.app-header h1 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.3px;
}

.subtitle {
  font-size: 11.5px;
  opacity: 0.75;
  font-weight: 400;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* ── TABS ── */
.tab-bar {
  background: var(--surface);
  border-bottom: 2px solid var(--border);
  display: flex;
  gap: 0;
  padding: 0 20px;
  overflow-x: auto;
}

.tab-btn {
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 13px 22px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 7px;
  transition: all 0.2s;
  white-space: nowrap;
  margin-bottom: -2px;
}

.tab-btn:hover { color: var(--primary); background: var(--primary-light); }

.tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  font-weight: 600;
}

/* ── MAIN CONTENT ── */
.main-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px 20px 60px;
}

/* ── TAB PANELS ── */
.tab-panel { display: none; flex-direction: column; gap: 20px; }
.tab-panel.active { display: flex; }

/* ── CARDS ── */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  overflow: hidden;
}

.card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  background: linear-gradient(to right, #f8faff, #f0f4fb);
  border-bottom: 1px solid var(--border);
  font-weight: 600;
  font-size: 14px;
  color: #1e3a5f;
  flex-wrap: wrap;
}

.card-header i { color: var(--primary); }

.card-body { padding: 20px; }
.card-footer {
  padding: 12px 20px;
  background: #f8faff;
  border-top: 1px solid var(--border);
}

/* ── FORMS ── */
.project-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-group label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 8px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 13.5px;
  color: var(--text);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(26,111,196,0.12);
}

/* ── ENTRY / EXIT GRID ── */
.entry-exit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.param-group {
  background: #f8faff;
  border-radius: var(--radius-sm);
  padding: 16px;
  border: 1px solid #dce8f8;
}

.param-group h4 {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary-dark);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.param-group .form-group { margin-bottom: 10px; }

/* ── UNIT TOGGLE ── */
.unit-toggle {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
}

.toggle-group {
  display: flex;
  border: 1.5px solid var(--primary);
  border-radius: 20px;
  overflow: hidden;
}

.toggle-btn {
  padding: 5px 14px;
  border: none;
  background: transparent;
  color: var(--primary);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.toggle-btn.active {
  background: var(--primary);
  color: #fff;
}

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 18px;
  border: none;
  border-radius: 7px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(26,111,196,0.3);
}
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); }

.btn-outline {
  background: rgba(255,255,255,0.15);
  color: #fff;
  border: 1.5px solid rgba(255,255,255,0.4);
}
.btn-outline:hover { background: rgba(255,255,255,0.25); }

.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #15803d; }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; }

.btn-sm { padding: 5px 12px; font-size: 12px; border-radius: 5px; }

.btn-sm.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn-sm.btn-outline:hover { background: var(--primary-light); }

.btn-sm.btn-reset-meas {
  background: transparent;
  color: #d97706;
  border: 1.5px solid #d97706;
}
.btn-sm.btn-reset-meas:hover { background: #fffbeb; }

.btn-sm.btn-reset-inc {
  background: transparent;
  color: #6366f1;
  border: 1.5px solid #6366f1;
}
.btn-sm.btn-reset-inc:hover { background: #eef2ff; }

.btn-sm.btn-reset-azi {
  background: transparent;
  color: #0891b2;
  border: 1.5px solid #0891b2;
}
.btn-sm.btn-reset-azi:hover { background: #ecfeff; }

.btn-sm.btn-success { background: var(--success); color: #fff; }

/* ── GENERATE BAR ── */
.generate-bar {
  display: flex;
  justify-content: center;
  padding: 10px 0;
}

.btn-generate {
  background: linear-gradient(135deg, #1a6fc4, #0f4a8a);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  padding: 14px 48px;
  border-radius: 50px;
  box-shadow: 0 6px 24px rgba(26,111,196,0.4);
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-generate:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(26,111,196,0.5);
}

/* ── TABLE ACTIONS ── */
.table-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.chart-actions { margin-left: auto; }

/* ── SURVEY TABLE ── */
.table-wrapper { overflow-x: auto; }

.survey-table, .data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.survey-table th, .data-table th {
  background: #1a3a5f;
  color: #e8f0fb;
  padding: 10px 12px;
  text-align: center;
  font-weight: 600;
  font-size: 12px;
  white-space: nowrap;
}

.survey-table td, .data-table td {
  padding: 7px 10px;
  border-bottom: 1px solid #edf2f8;
  text-align: center;
  vertical-align: middle;
}

.survey-table tbody tr:hover { background: #f0f7ff; }
.survey-table tbody tr:nth-child(even) { background: #f8faff; }
.survey-table tbody tr:nth-child(even):hover { background: #e8f0fb; }

.survey-table td input {
  width: 100%;
  min-width: 80px;
  padding: 5px 8px;
  border: 1.5px solid var(--border);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  text-align: center;
  background: #fff;
  outline: none;
  transition: border-color 0.2s;
}

.survey-table td input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(26,111,196,0.12);
}

.survey-table td input.notes-input { min-width: 120px; font-family: var(--font); text-align: left; }

.row-num {
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-mono);
  min-width: 36px;
}

/* ── DATA TABLE ── */
.data-table tbody tr:nth-child(even) { background: #f8faff; }
.data-table tbody tr:hover { background: #e8f4ff; }
.data-table td { font-family: var(--font-mono); font-size: 12.5px; }

/* ── SUMMARY STATS ── */
.summary-stats {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 13px;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 7px;
}

.stat-label { color: var(--text-muted); font-weight: 500; }
.stat-value { font-weight: 700; color: var(--primary-dark); font-family: var(--font-mono); }

/* ── CHART CARD ── */
.chart-card .card-body { padding: 16px; }

/* ── REPORT ── */
.report-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 6px;
}

.report-container {
  background: #fff;
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius);
  padding: 40px 48px;
  max-width: 960px;
  margin: 0 auto;
}

.report-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 3px solid var(--primary);
  padding-bottom: 18px;
  margin-bottom: 24px;
}

.report-title h2 { font-size: 22px; font-weight: 700; color: #0f2d5e; }
.report-title p { color: var(--text-muted); font-size: 13px; margin-top: 4px; }

.report-badge {
  background: #0f2d5e;
  color: #fff;
  padding: 8px 18px;
  border-radius: 8px;
  text-align: center;
}
.report-badge .badge-title { font-size: 10px; opacity: 0.7; text-transform: uppercase; }
.report-badge .badge-value { font-size: 15px; font-weight: 700; }

.report-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 32px;
  margin-bottom: 24px;
  padding: 18px;
  background: #f8faff;
  border-radius: 8px;
  border: 1px solid #dce8f8;
}

.report-info-item {
  display: flex;
  gap: 8px;
  font-size: 13px;
}

.ri-label { font-weight: 600; color: var(--text-muted); min-width: 120px; }
.ri-value { color: var(--text); font-weight: 500; }

.report-section-title {
  font-size: 14px;
  font-weight: 700;
  color: #0f2d5e;
  border-left: 4px solid var(--primary);
  padding-left: 10px;
  margin: 24px 0 12px;
}

.report-charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 16px 0;
}

.report-chart-box {
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.report-chart-box h5 {
  background: #1a3a5f;
  color: #fff;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 600;
}

.report-chart-box canvas { display: block; width: 100% !important; }

.report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 4px;
}

.report-table th {
  background: #1a3a5f;
  color: #fff;
  padding: 8px 10px;
  text-align: center;
  font-weight: 600;
}

.report-table td {
  padding: 6px 10px;
  border-bottom: 1px solid #e8eef8;
  text-align: center;
  font-family: var(--font-mono);
}

.report-table tbody tr:nth-child(even) { background: #f4f8ff; }

.report-footer {
  margin-top: 32px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
}

.sig-block {
  text-align: center;
}

.sig-line {
  border-top: 1px solid #aaa;
  margin-bottom: 6px;
  margin-top: 36px;
}

.sig-label { font-size: 11px; color: var(--text-muted); font-weight: 600; }

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background: #1a3a5f;
  color: #fff;
  padding: 12px 22px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 500;
  box-shadow: 0 6px 24px rgba(0,0,0,0.25);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.3s, transform 0.3s;
  z-index: 9999;
  pointer-events: none;
}

.toast.show { opacity: 1; transform: translateY(0); }
.toast.success { background: #15803d; }
.toast.error   { background: #b91c1c; }

/* ── EMPTY STATE ── */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.empty-state i { font-size: 48px; color: var(--border); margin-bottom: 16px; }
.empty-state p { font-size: 15px; }

/* ── DIFF CELLS ── */
.diff-pos { color: #16a34a; font-weight: 600; }
.diff-neg { color: #dc2626; font-weight: 600; }

/* ── SURVEY TABLE — wider inputs for new columns ── */
.survey-table td input.meas-input {
  min-width: 72px;
  background: #fffbf0;
  border-color: #d97706;
}
.survey-table td input.meas-input:focus {
  border-color: #b45309;
  box-shadow: 0 0 0 2px rgba(217,119,6,0.15);
}

/* ── Calculated Depth Cell ── */
.calc-depth-cell {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 600;
  color: #0e7490;
  background: #ecfeff;
  min-width: 72px;
  white-space: nowrap;
}

/* ── Ground Level Cell ── */
.ground-lvl-cell {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 600;
  color: #16a34a;
  background: #f0fdf4;
  min-width: 72px;
  white-space: nowrap;
}

/* ── MISC ── */
.ml-auto { margin-left: auto; }
.text-center { text-align: center; }
.mono { font-family: var(--font-mono); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .app-header { padding: 12px 16px; flex-direction: column; align-items: flex-start; gap: 10px; }
  .header-right { width: 100%; justify-content: flex-end; }
  .entry-exit-grid { grid-template-columns: 1fr; }
  .main-content { padding: 16px 12px 40px; }
  .tab-btn { padding: 11px 14px; font-size: 12.5px; }
  .report-container { padding: 24px 20px; }
  .report-info-grid { grid-template-columns: 1fr; }
  .report-charts { grid-template-columns: 1fr; }
  .report-footer { grid-template-columns: 1fr; }
}

/* ══════════════════════════════
   PRINT STYLES
   ══════════════════════════════ */
@media print {
  .no-print, .app-header, .tab-bar, .generate-bar,
  .table-actions, .chart-actions, .header-right { display: none !important; }

  body { background: #fff; font-size: 11px; }

  .main-content { padding: 0; max-width: 100%; }

  .tab-panel { display: none !important; }
  #tab-report { display: flex !important; }

  .report-container {
    box-shadow: none;
    padding: 0;
    border-radius: 0;
    max-width: 100%;
  }

  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }

  .report-charts { grid-template-columns: 1fr 1fr; }

  .report-chart-box {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .report-chart-box img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    color-adjust: exact;
  }

  .report-table {
    break-inside: auto;
    page-break-inside: auto;
  }

  .report-table thead {
    display: table-header-group;
  }

  .report-table tr {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  @page { margin: 18mm 15mm; }

  @page annexure-landscape {
    size: landscape;
    margin: 10mm;
  }
}

/* ══════════════════════════════
   ANNEXURE PAGES — Chart Landscape Pages
   ══════════════════════════════ */
.annexure-page {
  position: relative;
  page: annexure-landscape;
  break-before: page;
  page-break-before: always;
  overflow: hidden;
}

/* Watermark — centered, behind content */
.annexure-watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 0;
  pointer-events: none;
  opacity: 0.045;
}
.annexure-watermark-img {
  width: 340px;
  height: 340px;
  object-fit: contain;
}

/* Header row */
.annexure-header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0 10px;
  border-bottom: 2px solid #1a6fc4;
  margin-bottom: 12px;
}
.annexure-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.annexure-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 6px;
}
.annexure-title {
  font-size: 16px;
  font-weight: 700;
  color: #1e293b;
}
.annexure-subtitle {
  font-size: 11px;
  color: #64748b;
  margin-top: 1px;
}
.annexure-header-right {
  text-align: right;
}
.annexure-meta {
  font-size: 10px;
  color: #64748b;
}

/* Chart area — fills remaining space */
.annexure-chart-wrap {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  min-height: 0;
}
.annexure-chart-img {
  width: 100%;
  height: auto;
  max-height: 100%;
  display: block;
  object-fit: contain;
}
.annexure-no-chart {
  padding: 40px;
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
}

/* Footer row */
.annexure-footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0 0;
  border-top: 1px solid #cbd5e1;
  margin-top: 12px;
  font-size: 9px;
  color: #94a3b8;
}

/* Screen preview styling */
@media screen {
  .annexure-page {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 24px 28px;
    margin-top: 28px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    min-height: 500px;
  }
  .annexure-watermark-img {
    width: 240px;
    height: 240px;
  }
}

/* Print-specific annexure overrides */
@media print {
  .annexure-page {
    page: annexure-landscape;
    break-before: page;
    page-break-before: always;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    padding: 0;
    margin: 0;
    border: none;
    box-shadow: none;
    border-radius: 0;
  }
  .annexure-watermark {
    opacity: 0.04;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    color-adjust: exact;
  }
  .annexure-watermark-img {
    width: 400px;
    height: 400px;
  }
  .annexure-chart-wrap {
    flex: 1;
  }
  .annexure-chart-img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    color-adjust: exact;
  }
  .annexure-header {
    border-bottom-color: #1a6fc4;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .annexure-logo {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}

/* ══════════════════════════════
   PROJECT MANAGER STYLES
   ══════════════════════════════ */

/* Project indicator in header */
.project-indicator {
  display: none;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: rgba(255,255,255,0.85);
  padding: 4px 12px;
  background: rgba(255,255,255,0.1);
  border-radius: 20px;
  white-space: nowrap;
}

.project-indicator small {
  font-size: 10.5px;
}

/* Modal Overlay */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.modal-overlay.show {
  opacity: 1;
  pointer-events: auto;
}

/* Project Modal */
.project-modal {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 640px;
  max-width: 95vw;
  max-height: 85vh;
  background: var(--surface);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  z-index: 201;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
}

.project-modal.show {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(to right, #f8faff, #f0f4fb);
  border-radius: 16px 16px 0 0;
}

.modal-header h3 {
  font-size: 16px;
  font-weight: 700;
  color: #0f2d5e;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-header h3 i { color: var(--primary); }

.modal-close {
  width: 32px; height: 32px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 16px;
  cursor: pointer;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.modal-close:hover { background: var(--danger-light); color: var(--danger); }

.modal-toolbar {
  display: flex;
  gap: 8px;
  padding: 12px 24px;
  border-bottom: 1px solid var(--border);
  background: #fafbfc;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px 16px;
  min-height: 200px;
  max-height: 50vh;
}

.modal-footer {
  padding: 10px 24px;
  border-top: 1px solid var(--border);
  background: #fafbfc;
  border-radius: 0 0 16px 16px;
  text-align: center;
  color: var(--text-light);
}

.modal-footer small { font-size: 11px; }
.modal-footer i { margin-right: 4px; }

/* Project List Items */
.project-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 10px;
  margin-bottom: 6px;
  transition: all 0.15s;
  border: 1.5px solid transparent;
  cursor: pointer;
}

.project-item:hover {
  background: var(--primary-light);
  border-color: rgba(26,111,196,0.2);
}

.project-item.active {
  background: #e8f4ff;
  border-color: var(--primary);
}

.project-item-main {
  flex: 1;
  min-width: 0;
}

.project-item-name {
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
  display: flex;
  align-items: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.project-item-meta {
  display: flex;
  gap: 12px;
  margin-top: 4px;
  font-size: 11.5px;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.project-item-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.project-item-meta i {
  font-size: 10px;
  color: var(--text-light);
}

.project-item-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
  opacity: 0;
  transition: opacity 0.15s;
}

.project-item:hover .project-item-actions {
  opacity: 1;
}

.project-item-actions .btn-sm {
  padding: 4px 8px;
}

/* Empty projects state */
.empty-projects {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-muted);
}

.empty-projects i {
  font-size: 42px;
  color: var(--border);
  margin-bottom: 14px;
  display: block;
}

.empty-projects p {
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 4px;
}

.empty-projects small {
  font-size: 12.5px;
  color: var(--text-light);
}

/* Responsive modal */
@media (max-width: 768px) {
  .project-modal {
    width: 100%;
    max-width: 100%;
    max-height: 100vh;
    border-radius: 0;
    top: 0; left: 0;
    transform: translateY(100%);
  }
  .project-modal.show {
    transform: translateY(0);
  }
  .project-item-actions { opacity: 1; }
  .header-right { gap: 6px; }
  .project-indicator { display: none !important; }
}
