/* ============================================================
   MYCFO — ceo.css  (Milestone 2)
   CEO Dashboard 전용 스타일
   ============================================================ */

/* ── CEO Header ──────────────────────────────────────────────── */
.ceo-header {
  background: linear-gradient(135deg, #1e3a5f 0%, #1e40af 100%);
  border-radius: var(--radius-xl);
  padding: 24px;
  color: #fff;
  margin-bottom: 20px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}
.ceo-header .page-title { color: #fff; }
.ceo-header .page-subtitle { color: rgba(255,255,255,0.7); }
.ceo-date-badge {
  font-size: 12px;
  background: rgba(255,255,255,0.15);
  color: #fff;
  padding: 6px 12px;
  border-radius: 20px;
  white-space: nowrap;
}

/* ── CEO Top Row ─────────────────────────────────────────────── */
.ceo-top-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
@media (max-width: 800px) { .ceo-top-row { grid-template-columns: 1fr; } }

/* ── CEO Section ─────────────────────────────────────────────── */
.ceo-section {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  margin-bottom: 16px;
}
.ceo-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.ceo-section-title { font-size: 15px; font-weight: 600; color: var(--color-text-primary); }
.ceo-section-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  background: #fee2e2;
  color: #991b1b;
  border-radius: 10px;
}
.see-all-link { font-size: 12px; color: var(--color-brand-blue); text-decoration: none; }
.see-all-link:hover { text-decoration: underline; }

/* ── Action Items ────────────────────────────────────────────── */
.action-items-list { display: flex; flex-direction: column; gap: 6px; }
.action-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  text-decoration: none;
  color: inherit;
  transition: background 0.1s;
}
.action-item:hover { background: var(--color-surface-hover); }
.action-urgent  { border-left: 3px solid #ef4444; background: #fff5f5; }
.action-warning { border-left: 3px solid #f97316; background: #fff7ed; }
.action-normal  { border-left: 3px solid var(--color-border); }
.action-icon { font-size: 16px; }
.action-label { flex: 1; font-size: 13px; color: var(--color-text-primary); }
.action-count {
  font-size: 14px;
  font-weight: 700;
  min-width: 24px;
  text-align: center;
  padding: 2px 6px;
  border-radius: 8px;
}
.count-urgent  { background: #fee2e2; color: #991b1b; }
.count-warning { background: #fff7ed; color: #9a3412; }
.count-normal  { background: var(--color-surface-alt); color: var(--color-text-secondary); }

/* ── Cash Summary ────────────────────────────────────────────── */
.cash-total-card {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  text-align: center;
  margin-bottom: 12px;
}
.cash-total-label { font-size: 11px; color: #1e40af; font-weight: 500; }
.cash-total-value { font-size: 24px; font-weight: 700; color: #1e40af; margin: 4px 0; }
.cash-total-sub { font-size: 11px; color: #93c5fd; }

.cash-entity-rows { display: flex; flex-direction: column; gap: 8px; }
.cash-entity-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}
.cash-entity-icon { font-size: 14px; flex-shrink: 0; }
.cash-entity-name { min-width: 90px; color: var(--color-text-secondary); }
.cash-entity-bar-wrap { flex: 1; }
.cash-entity-bar-bg { height: 6px; background: var(--color-surface-alt); border-radius: 3px; overflow: hidden; }
.cash-entity-bar-fill { height: 100%; background: var(--color-brand-blue); border-radius: 3px; }
.cash-entity-amount { min-width: 90px; text-align: right; font-weight: 600; color: var(--color-text-primary); }

/* ── AI Rec Strip ────────────────────────────────────────────── */
.ai-rec-strip {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.ai-rec-card {
  background: #fff5f5;
  border: 1px solid #fca5a5;
  border-radius: var(--radius-lg);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ai-rec-header { display: flex; align-items: center; justify-content: space-between; }
.ai-rec-priority { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; }
.priority-urgent { background: #fee2e2; color: #991b1b; }
.ai-rec-risk { font-size: 11px; color: var(--color-danger); font-weight: 600; }
.ai-rec-title { font-size: 13px; font-weight: 600; color: var(--color-text-primary); line-height: 1.4; }
.ai-rec-confidence { font-size: 11px; color: var(--color-text-tertiary); }
.ai-rec-action-btn {
  display: inline-block;
  font-size: 12px;
  color: var(--color-brand-blue);
  text-decoration: none;
  font-weight: 500;
  margin-top: 4px;
}
.ai-rec-action-btn:hover { text-decoration: underline; }

/* ── Filing Due ──────────────────────────────────────────────── */
.filing-due-list { display: flex; flex-direction: column; gap: 6px; }
.filing-due-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-size: 13px;
}
.due-urgent  { background: #fff5f5; border-left: 3px solid #ef4444; }
.due-warning { background: #fff7ed; border-left: 3px solid #f97316; }
.filing-due-icon { font-size: 14px; }
.filing-due-title { flex: 1; font-weight: 500; }
.filing-due-entity { font-size: 11px; color: var(--color-text-tertiary); white-space: nowrap; }
.filing-due-days { font-size: 12px; font-weight: 700; white-space: nowrap; min-width: 32px; text-align: right; }
.days-urgent  { color: #dc2626; }
.days-warning { color: #f97316; }
.filing-due-progress-bar-bg { width: 60px; height: 5px; background: var(--color-surface-alt); border-radius: 3px; overflow: hidden; }
.filing-due-progress-fill { height: 100%; background: #3b82f6; border-radius: 3px; }
.filing-due-pct { font-size: 11px; color: var(--color-text-tertiary); min-width: 28px; text-align: right; }

/* ── Entity Summary Grid ─────────────────────────────────────── */
.entity-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.entity-summary-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 14px;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: box-shadow 0.15s, border-color 0.15s;
}
.entity-summary-card:hover { box-shadow: var(--shadow-md); border-color: var(--color-border-strong); }
.entity-summary-card.filing-alert { border-top: 3px solid #f97316; }
.entity-card-header { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.entity-icon { font-size: 20px; }
.entity-card-name { font-size: 13px; font-weight: 600; flex: 1; }
.filing-alert-badge { font-size: 10px; padding: 2px 5px; background: #fff7ed; color: #9a3412; border-radius: 6px; font-weight: 600; }
.entity-card-cash { margin-bottom: 8px; }
.cash-label { font-size: 11px; color: var(--color-text-tertiary); }
.cash-value { font-size: 15px; font-weight: 700; color: var(--color-text-primary); display: block; }
.entity-card-stats { display: flex; gap: 0; border-top: 1px solid var(--color-border); padding-top: 8px; }
.entity-stat { flex: 1; text-align: center; }
.entity-stat + .entity-stat { border-left: 1px solid var(--color-border); }
.estat-num { font-size: 14px; font-weight: 600; color: var(--color-text-primary); display: block; }
.estat-label { font-size: 10px; color: var(--color-text-tertiary); }
.entity-stat.estat-warn .estat-num { color: #f97316; }

/* ── Project Summary Table ───────────────────────────────────── */
.project-summary-table {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.proj-table-header {
  display: grid;
  grid-template-columns: 2fr 1.5fr 1.5fr 0.8fr;
  gap: 12px;
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 600;
  color: var(--color-text-tertiary);
  background: var(--color-surface-alt);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  border: 1px solid var(--color-border);
  border-bottom: none;
}
.project-summary-row {
  display: grid;
  grid-template-columns: 2fr 1.5fr 1.5fr 0.8fr;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-top: none;
  text-decoration: none;
  color: inherit;
  transition: background 0.1s;
}
.project-summary-row:hover { background: var(--color-surface-hover); }
.project-summary-row:last-child { border-radius: 0 0 var(--radius-md) var(--radius-md); }
@media (max-width: 700px) {
  .proj-table-header, .project-summary-row {
    grid-template-columns: 1fr 1fr;
  }
  .proj-table-header .proj-progress-col, .project-summary-row .proj-progress-col { display: none; }
}
.proj-name { font-size: 13px; font-weight: 500; }
.proj-entity { font-size: 11px; color: var(--color-text-tertiary); }
.proj-progress-col { display: flex; align-items: center; gap: 6px; }
.proj-progress-bar-bg { flex: 1; height: 6px; background: var(--color-surface-alt); border-radius: 3px; overflow: hidden; }
.proj-progress-bar-fill { height: 100%; background: #3b82f6; border-radius: 3px; }
.proj-progress-pct { font-size: 12px; font-weight: 600; min-width: 30px; }
.proj-revenue { font-size: 13px; font-weight: 600; display: block; }
.proj-margin { font-size: 11px; }
.proj-status { font-size: 11px; padding: 2px 8px; border-radius: 10px; font-weight: 500; }
.status-active  { background: #dbeafe; color: #1e40af; }
.status-running { background: #d1fae5; color: #065f46; }

/* ── Quick Nav ───────────────────────────────────────────────── */
.quicknav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 10px;
}
.quicknav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.15s, border-color 0.15s;
}
.quicknav-item:hover { box-shadow: var(--shadow-md); border-color: var(--color-brand-blue); }
.quicknav-icon { font-size: 22px; }
.quicknav-label { font-size: 12px; color: var(--color-text-secondary); text-align: center; }
