#projects-view { display: none; }
#projects-view.visible { display: flex; flex-direction: column; height: 100%; overflow-y: auto; }

#projectsPanel { display: flex; flex-direction: column; width: 100%; flex: 1; overflow-y: auto; }

/* ── PROJECTS TAB ─────────────────────────────────────────────────────── */
.projects-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 12px;
  border-bottom: 1px solid #2a2a2a;
  gap: 12px;
}
.projects-title {
  font-size: 20px;
  font-weight: 700;
  color: #e0e0e0;
}
.projects-actions {
  display: flex;
  gap: 8px;
}
.proj-btn-new, .proj-btn-catchup {
  padding: 6px 12px;
  border-radius: 6px;
  border: none;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.proj-btn-new {
  background: #e05c2a;
  color: #fff;
}
.proj-btn-catchup {
  background: #1a1a1a;
  border: 1px solid #333;
  color: #aaa;
}
.projects-list {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  flex: 1;
  width: 100%;
  box-sizing: border-box;
}
.projects-empty {
  text-align: center;
  padding: 60px 20px;
  color: #555;
  font-size: 15px;
  width: 100%;
}
.projects-empty-sub {
  font-size: 13px;
  color: #444;
  margin-top: 6px;
}
.project-tile {
  background: #111;
  border: 1px solid #222;
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  transition: border-color 0.15s;
}
.project-tile:hover {
  border-color: #333;
}
.project-tile-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.project-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.project-tile-name {
  font-size: 16px;
  font-weight: 600;
  color: #f0f0f0;
  flex: 1;
}
.project-tile-type {
  font-size: 11px;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: #1a1a1a;
  padding: 2px 8px;
  border-radius: 20px;
  border: 1px solid #2a2a2a;
}
.project-tile-brief {
  font-size: 13px;
  color: #666;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 10px;
}
.project-tile-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.project-tile-meta {
  font-size: 12px;
  color: #444;
}
.project-tile-btns {
  display: flex;
  gap: 6px;
}
.project-tile-btns button {
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid #2a2a2a;
  background: #1a1a1a;
  color: #888;
  font-size: 12px;
  cursor: pointer;
}
.project-tile-btns button.primary {
  background: rgba(224,92,42,0.15);
  border-color: #e05c2a40;
  color: #e05c2a;
}

/* ── PROJECT DETAIL ───────────────────────────────────────────────────── */
.proj-detail-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px;
  border-bottom: 1px solid #1e1e1e;
}
.proj-back {
  background: none;
  border: none;
  color: #666;
  font-size: 13px;
  cursor: pointer;
  padding: 4px;
  white-space: nowrap;
}
.proj-detail-name {
  flex: 1;
  font-size: 17px;
  font-weight: 700;
  color: #f0f0f0;
}
.proj-update-btn {
  padding: 7px 14px;
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 8px;
  color: #aaa;
  font-size: 13px;
  cursor: pointer;
}
.proj-brief-section {
  margin: 16px;
  background: #0f0f0f;
  border: 1px solid #1e1e1e;
  border-radius: 10px;
  padding: 14px;
}
.proj-brief-label {
  font-size: 11px;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}
.proj-brief-content {
  font-size: 13px;
  color: #999;
  line-height: 1.7;
  white-space: pre-wrap;
}
.proj-chats-label {
  font-size: 11px;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0 16px;
  margin-bottom: 8px;
}
.proj-chats-list {
  padding: 0 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}
.proj-chat-item {
  padding: 10px 12px;
  background: #111;
  border: 1px solid #1e1e1e;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  color: #ccc;
}
.proj-chat-start {
  margin: 0 16px;
  width: calc(100% - 32px);
  padding: 13px;
  background: #e05c2a;
  border: none;
  border-radius: 10px;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

/* ── INTERVIEW MODAL ──────────────────────────────────────────────────── */
.interview-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 200;
  display: flex;
  align-items: flex-end;
}
.interview-box {
  background: #0f0f0f;
  border: 1px solid #222;
  border-radius: 20px 20px 0 0;
  padding: 24px 20px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
}
.interview-header {
  margin-bottom: 16px;
}
.interview-mode-label {
  font-size: 11px;
  color: #e05c2a;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}
.interview-project-name {
  font-size: 20px;
  font-weight: 700;
  color: #f0f0f0;
}
.interview-progress {
  height: 3px;
  background: #1e1e1e;
  border-radius: 2px;
  margin-bottom: 24px;
}
.interview-progress-bar {
  height: 100%;
  background: #e05c2a;
  border-radius: 2px;
  transition: width 0.3s;
}
.interview-question {
  font-size: 17px;
  color: #f0f0f0;
  line-height: 1.5;
  margin-bottom: 16px;
  font-weight: 500;
}
.interview-answer {
  width: 100%;
  min-height: 120px;
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  padding: 12px;
  color: #f0f0f0;
  font-size: 15px;
  line-height: 1.6;
  resize: none;
  outline: none;
  font-family: inherit;
  box-sizing: border-box;
  margin-bottom: 14px;
}
.interview-actions {
  display: flex;
  gap: 10px;
}
.interview-back {
  flex: 0;
  padding: 13px 16px;
  background: none;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  color: #555;
  font-size: 14px;
  cursor: pointer;
}
.interview-skip {
  flex: 0;
  padding: 13px 20px;
  background: none;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  color: #555;
  font-size: 14px;
  cursor: pointer;
}
.interview-next {
  flex: 1;
  padding: 13px;
  background: #e05c2a;
  border: none;
  border-radius: 10px;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.interview-generating {
  text-align: center;
  padding: 30px 0;
  color: #888;
  font-size: 14px;
}
.interview-spinner {
  width: 28px;
  height: 28px;
  border: 2px solid #2a2a2a;
  border-top-color: #e05c2a;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 12px;
}
@keyframes spin { to { transform: rotate(360deg); } }
