/* ============ Base ============ */
* { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --indigo: #4f46e5;
  --indigo-dark: #4338ca;
  --indigo-light: #e0e7ff;
  --blue: #2563eb;
  --blue-light: #dbeafe;
  --purple: #7c3aed;
  --purple-light: #ede9fe;
  --green: #16a34a;
  --green-light: #dcfce7;
  --amber: #d97706;
  --amber-light: #fef3c7;
  --pink: #db2777;
  --pink-light: #fce7f3;
  --slate: #475569;
  --slate-light: #f1f5f9;
  --teal: #0d9488;
  --teal-light: #ccfbf1;
  --ink: #1a1f2b;
  --muted: #667085;
  --border: #e5e7eb;
  --bg: #eef0f7;
}
html { scrollbar-gutter: stable; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
  font-size: 15px;
}

/* ============ Login page ============ */
.login-body {
  display: flex; align-items: center; justify-content: center; min-height: 100vh;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #db2777 100%);
}
.login-card {
  background: #fff; padding: 2.75rem; border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.25); width: 100%; max-width: 380px;
}
.login-card h1 { font-size: 1.5rem; margin-bottom: 0.25rem; color: var(--ink); }
.subtitle { color: var(--muted); margin-bottom: 1.75rem; font-size: 0.9rem; }
.login-card form { display: flex; flex-direction: column; gap: 0.4rem; }
.login-card label { font-size: 0.82rem; color: var(--slate); margin-top: 0.6rem; font-weight: 600; }
.login-card input {
  padding: 0.7rem 0.85rem; border: 1.5px solid #d1d5db; border-radius: 10px; font-size: 0.95rem;
  transition: border-color 0.15s;
}
.login-card input:focus { outline: none; border-color: var(--indigo); }
.login-card button {
  margin-top: 1.4rem; padding: 0.8rem; background: var(--indigo); color: #fff; border: none;
  border-radius: 10px; font-size: 0.95rem; font-weight: 600; cursor: pointer; transition: background 0.15s;
}
.login-card button:hover { background: var(--indigo-dark); }
.alert { background: #fee2e2; color: #b91c1c; padding: 0.7rem 0.9rem; border-radius: 8px; margin-bottom: 1rem; font-size: 0.85rem; }

/* ============ Top bar — full width ============ */
.topbar {
  background: #fff; border-bottom: 1px solid var(--border); padding: 1rem 2.5rem;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.6rem;
  position: sticky; top: 0; z-index: 20; box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  width: 100%;
}
.brand {
  font-weight: 800; font-size: 1.2rem;
  background: linear-gradient(90deg, var(--indigo), var(--purple));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.topbar nav { display: flex; align-items: center; gap: 1.5rem; }
.topbar nav a { text-decoration: none; color: var(--slate); font-size: 0.92rem; font-weight: 600; transition: color 0.15s; }
.topbar nav a:hover { color: var(--indigo); }
.topbar nav a.active { color: var(--indigo); }
.user-pill {
  font-size: 0.85rem; color: var(--muted); background: var(--slate-light);
  padding: 0.4rem 0.9rem; border-radius: 20px; font-weight: 600;
}
.logout { color: #dc2626 !important; }

/* ============ Layout — true full width, edge to edge with generous padding ============ */
.container {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 2rem 3rem 5rem;
}
.container-wide { max-width: 1750px; }

/* ============ Quote & progress ============ */
.quote-banner {
  background: linear-gradient(90deg, #6366f1, #a855f7, #ec4899);
  color: #fff; padding: 1.3rem 1.8rem; border-radius: 16px;
  font-style: italic; font-weight: 600; margin-bottom: 2rem; font-size: 1.05rem;
  box-shadow: 0 8px 24px rgba(124,58,237,0.25);
}

.progress-wrap {
  margin-bottom: 2.2rem; background: #fff; border-radius: 16px; padding: 1.4rem 1.8rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.progress-label { font-size: 0.92rem; color: var(--muted); margin-bottom: 0.7rem; }
.progress-count { font-weight: 800; color: var(--indigo); font-size: 1.1rem; }
.progress-bar { background: #e9eaf3; border-radius: 8px; height: 14px; overflow: hidden; }
.progress-fill {
  background: linear-gradient(90deg, var(--indigo), var(--purple), var(--pink));
  height: 100%; transition: width 0.4s ease; border-radius: 8px;
}

/* ============ Module cards (collapsed) ============ */
.module-card {
  background: #fff; border-radius: 16px; margin-bottom: 1.1rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06); border: 2px solid transparent;
  transition: box-shadow 0.15s, border-color 0.15s, transform 0.1s;
  overflow: hidden;
}
.module-card:hover { box-shadow: 0 10px 30px rgba(79,70,229,0.14); }
.module-card.module-complete { border-color: #86efac; background: linear-gradient(180deg, #f0fdf4 0%, #fff 12%); }
.module-card:not(.module-complete) { border-color: #eceef5; }

.module-header {
  display: flex; align-items: center; gap: 1rem; padding: 1.3rem 1.6rem;
}
.module-badge {
  flex-shrink: 0; width: 38px; height: 38px; border-radius: 50%;
  background: linear-gradient(135deg, var(--indigo), var(--purple)); color: #fff;
  font-weight: 800; font-size: 0.95rem;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 8px rgba(79,70,229,0.35);
}
.module-complete .module-badge { background: linear-gradient(135deg, #22c55e, #16a34a); box-shadow: 0 3px 8px rgba(22,163,74,0.35); }

.checkbox-row { display: flex; align-items: center; gap: 0.9rem; cursor: pointer; flex: 1; min-width: 0; }
.checkbox-row input {
  width: 22px; height: 22px; accent-color: var(--indigo); cursor: pointer; flex-shrink: 0;
}
.module-title { font-weight: 700; font-size: 1.08rem; color: var(--ink); }
.module-complete .module-title { color: #15803d; }

.toggle-btn {
  background: var(--indigo-light); border: none; border-radius: 10px; padding: 0.55rem 1.1rem;
  font-size: 0.85rem; cursor: pointer; color: var(--indigo-dark); font-weight: 700; flex-shrink: 0;
  transition: background 0.15s;
}
.toggle-btn:hover { background: #c7d2fe; }

/* ============ Module details (expanded) ============ */
.module-details {
  padding: 0 1.6rem 1.8rem;
  animation: fadeIn 0.2s ease;
}
@keyframes fadeIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

.module-overview {
  font-size: 0.98rem; color: #374151; padding: 0.4rem 0 1.2rem; line-height: 1.7;
  border-bottom: 1px dashed var(--border); margin-bottom: 1.3rem;
}

.meta-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 1.3rem; }
.meta-chip {
  background: var(--slate-light); border: 1px solid var(--border); border-radius: 24px;
  padding: 0.5rem 1.1rem; font-size: 0.85rem; color: var(--slate);
}
.meta-chip-label { font-weight: 800; color: var(--ink); margin-right: 0.5rem; }

/* Content blocks — bold, colorful, clearly separated cards */
.content-block {
  border-radius: 14px; padding: 1.3rem 1.5rem; margin-bottom: 1.2rem;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.block-label {
  font-weight: 800; font-size: 0.82rem; margin-bottom: 0.8rem;
  display: flex; align-items: center; gap: 0.5rem;
  text-transform: uppercase; letter-spacing: 0.04em;
}

.block-neutral { background: var(--slate-light); border: 2px solid #e2e8f0; }
.block-neutral .block-label { color: var(--slate); }

.block-deliverable { background: var(--purple-light); border: 2px solid #ddd6fe; }
.block-deliverable .block-label { color: #6d28d9; }
.block-deliverable p { font-size: 0.95rem; color: #4c1d95; font-weight: 500; }

.block-takeaway { background: var(--green-light); border: 2px solid #bbf7d0; }
.block-takeaway .block-label { color: #15803d; }

.block-prompt { background: var(--indigo-light); border: 2px solid #c7d2fe; }
.block-prompt .block-label { color: var(--indigo-dark); }

.block-video { background: var(--pink-light); border: 2px solid #fbcfe8; }
.block-video .block-label { color: #be185d; }

.block-interview { background: var(--amber-light); border: 2px solid #fde68a; }
.block-interview .block-label { color: #92400e; }

.block-notes { background: var(--blue-light); border: 2px solid #bfdbfe; }
.block-notes .block-label { color: #1d4ed8; }

.block-feedback { background: var(--teal-light); border: 2px solid #99f6e4; }
.block-feedback .block-label { color: #0f766e; }
.block-feedback p { font-size: 0.92rem; color: #115e59; font-weight: 500; }

/* Bullet lists — real cards with colored markers */
.bullet-list { list-style: none; padding: 0; margin: 0; }
.bullet-list li {
  position: relative; padding: 0.5rem 0 0.5rem 1.6rem; font-size: 0.92rem; color: #334155;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}
.bullet-list li:last-child { border-bottom: none; padding-bottom: 0; }
.bullet-list li:first-child { padding-top: 0; }
.bullet-list li::before {
  content: "▸"; position: absolute; left: 0; top: 0.5rem; font-weight: 900; font-size: 1rem;
}
.block-neutral .bullet-list li::before { color: var(--slate); }
.block-takeaway .bullet-list li::before { color: var(--green); content: "✓"; }

/* Prompt box */
.prompt-box {
  background: #fff; border: 1px solid #c7d2fe; border-radius: 12px; padding: 1.1rem;
  display: flex; justify-content: space-between; align-items: flex-start; gap: 1.2rem;
}
.prompt-text { font-size: 0.89rem; color: #374151; white-space: pre-wrap; line-height: 1.6; }
.copy-btn {
  background: var(--indigo); color: #fff; border: none; border-radius: 10px; padding: 0.6rem 1.2rem;
  font-size: 0.85rem; font-weight: 700; cursor: pointer; white-space: nowrap; transition: background 0.15s, transform 0.1s;
}
.copy-btn:hover { background: var(--indigo-dark); transform: translateY(-1px); }

/* Video embed */
.video-embed iframe { border-radius: 12px; display: block; box-shadow: 0 4px 16px rgba(0,0,0,0.12); }
.video-caption { font-size: 0.85rem; color: var(--muted); margin-top: 0.6rem; font-weight: 500; }

/* Q&A cards — question and hint VISUALLY SEPARATE */
.qa-list { display: flex; flex-direction: column; gap: 0.9rem; }
.qa-item {
  background: #fff; border: 1px solid #fde68a; border-radius: 12px; overflow: hidden;
}
.qa-question {
  font-weight: 700; font-size: 0.92rem; color: #78350f;
  padding: 0.9rem 1.1rem; background: #fef9e7;
}
.qa-hint {
  font-size: 0.87rem; color: #713f12; padding: 0.8rem 1.1rem;
  background: #fffdf5; border-top: 1px dashed #fde68a;
  font-style: italic;
}
.qa-hint::before { content: "💡 "; font-style: normal; }

/* Notes textarea */
.module-notes {
  width: 100%; min-height: 100px; padding: 0.85rem; border: 1.5px solid #bfdbfe; border-radius: 10px;
  font-size: 0.89rem; font-family: inherit; resize: vertical; background: #fff;
}
.module-notes:focus { outline: none; border-color: var(--blue); }
.save-status { font-size: 0.8rem; color: var(--green); height: 1.1rem; margin-top: 0.4rem; font-weight: 700; }

/* ============ Mentor view ============ */
.mentee-tabs { display: flex; gap: 0.8rem; margin-bottom: 1.6rem; flex-wrap: wrap; }
.tab-btn {
  background: #fff; border: 2px solid var(--border); border-radius: 14px; padding: 0.8rem 1.4rem;
  cursor: pointer; font-size: 0.95rem; text-align: left; color: var(--slate); font-weight: 700;
  transition: all 0.15s; box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.tab-btn:hover { border-color: #c7d2fe; }
.tab-btn.active { border-color: var(--indigo); background: var(--indigo-light); color: var(--indigo-dark); }
.tab-meta { display: block; font-size: 0.78rem; color: var(--muted); font-weight: 500; margin-top: 0.25rem; }
.tab-btn.active .tab-meta { color: var(--indigo); }

.portfolio-link {
  display: inline-block; margin-bottom: 1.3rem; color: var(--indigo-dark); font-size: 0.94rem; text-decoration: none;
  font-weight: 800; background: var(--indigo-light); padding: 0.6rem 1.2rem; border-radius: 10px;
}
.mentor-module-card .module-title { display: flex; align-items: center; gap: 0.5rem; }
.mentee-notes-display {
  background: var(--slate-light); border: 2px solid var(--border); border-radius: 12px; padding: 1rem;
  font-size: 0.89rem; margin-bottom: 1rem; color: #374151; white-space: pre-wrap;
}
.feedback-input {
  width: 100%; min-height: 85px; padding: 0.85rem; border: 1.5px solid #c7d2fe; border-radius: 12px;
  font-size: 0.89rem; font-family: inherit; resize: vertical; background: #fdfdff;
}
.feedback-input:focus { outline: none; border-color: var(--indigo); }
.feedback-save-btn { margin-top: 0.7rem; }

/* ============ Portfolio (print page) ============ */
.portfolio-toolbar {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 850px; margin: 0 auto; padding: 1.3rem 1.5rem;
}
.portfolio-toolbar a { color: var(--indigo); text-decoration: none; font-size: 0.9rem; font-weight: 700; }
.portfolio-toolbar button {
  background: var(--indigo); color: #fff; border: none; border-radius: 10px; padding: 0.65rem 1.3rem;
  cursor: pointer; font-size: 0.9rem; font-weight: 700;
}
.portfolio-page {
  max-width: 850px; margin: 0 auto; padding: 2.75rem; background: #fff; min-height: 100vh;
  border-radius: 18px; box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}
.portfolio-page h1 { font-size: 1.7rem; margin-bottom: 0.35rem; }
.portfolio-subtitle { color: var(--muted); font-size: 0.94rem; }
.portfolio-progress { font-size: 0.88rem; color: var(--indigo); margin-top: 0.45rem; font-weight: 700; }
.portfolio-page hr { margin: 1.5rem 0; border: none; border-top: 1px solid var(--border); }
.portfolio-module { margin-bottom: 1.9rem; page-break-inside: avoid; }
.portfolio-module h2 { font-size: 1.12rem; margin-bottom: 0.5rem; }
.portfolio-deliverable-label { font-size: 0.85rem; color: var(--muted); margin-bottom: 0.55rem; }
.portfolio-notes { font-size: 0.94rem; line-height: 1.7; white-space: pre-wrap; }
.portfolio-empty { color: #9ca3af; font-size: 0.88rem; }

@media print {
  .no-print { display: none !important; }
  .topbar { display: none; }
  body { background: #fff; }
  .portfolio-page { box-shadow: none; border-radius: 0; }
}

/* ============ Responsive ============ */
@media (max-width: 900px) {
  .container { padding: 1.2rem; }
  .topbar { padding: 0.9rem 1.2rem; }
}
@media (max-width: 700px) {
  .prompt-box { flex-direction: column; }
  .module-header { flex-wrap: wrap; }
}
