:root {
  --bg: #f2ead9;
  --panel-bg: #fffcf5;
  --sidebar-bg: #ece2cc;
  --text: #2b2620;
  --text-muted: #55503f;
  --text-faint: #837c68;
  --border: #e3d8bd;
  --accent: #c2410c;
  --accent-dim: #9a3410;
  --accent-ink: #fffaf0;

  --indigo-bg: #eef2ff;   --indigo-text: #4338ca;
  --violet-bg: #f5f3ff;   --violet-text: #6d28d9;
  --amber-bg:  #fff3d6;   --amber-text:  #92400e;
  --pink-bg:   #fdf2f8;   --pink-text:   #be185d;
  --teal-bg:   #ecfeff;   --teal-text:   #0e7490;
  --cyan-bg:   #ecfeff;   --cyan-text:   #0e7490;
  --emerald-bg:#ecfdf5;   --emerald-text:#047857;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

a { color: inherit; }

.layout {
  display: flex;
  min-height: 100vh;
}

/* ---------- Sidebar ---------- */

.sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  padding: 68px 20px 28px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}

.brand {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.01em;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 40px;
  flex: 1;
}

.sidebar-nav a {
  text-decoration: none;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.92rem;
  padding: 10px 12px;
  border-radius: 10px;
  transition: background 0.15s ease, color 0.15s ease;
}

.sidebar-nav a:hover {
  background: rgba(194,65,12,0.1);
  color: var(--accent);
}

.sidebar-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.connect-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
  font-size: 0.88rem;
  padding: 12px 16px;
  border-radius: 999px;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.connect-btn--outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.connect-btn:hover {
  transform: translateY(-2px);
}

/* ---------- Main ---------- */

.main {
  flex: 1;
  min-width: 0;
  display: flex;
  justify-content: center;
}

.content {
  width: 100%;
  max-width: 900px;
  padding: 40px 48px 60px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.eyebrow-line {
  width: 24px;
  height: 2px;
  background: var(--accent);
  display: inline-block;
}

/* ---------- Hero ---------- */

.hero {
  display: flex;
  align-items: center;
  gap: 48px;
  padding: 20px 0 56px;
  flex-wrap: wrap;
}

.hero-text {
  flex: 1 1 380px;
  min-width: 300px;
}

.hero h1 {
  margin: 0 0 20px;
  font-size: 2.6rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.accent {
  color: var(--accent);
}

.hero-bio {
  margin: 0 0 28px;
  font-size: 1.02rem;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 46ch;
}

.stats {
  display: flex;
  gap: 40px;
  margin-top: 8px;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat-num {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--accent);
}

.stat-label {
  font-size: 0.82rem;
  color: var(--text-faint);
  margin-top: 2px;
}

.hero-photo {
  position: relative;
  flex: 0 0 auto;
  width: 260px;
  height: 260px;
}

.photo-ring {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  padding: 8px;
  background: conic-gradient(from 200deg, var(--accent), transparent 60%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-ring img,
.photo-fallback {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: var(--panel-bg);
}

.photo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  font-weight: 800;
  color: var(--accent);
}

.badge {
  position: absolute;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 800;
  padding: 6px 10px;
  border-radius: 10px;
  box-shadow: 0 6px 16px rgba(43,38,32,0.12);
}

.badge-1 { top: 6px; left: -14px; }
.badge-2 { bottom: 20px; right: -18px; }

.deco-chart {
  position: absolute;
  bottom: -34px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 55px;
  opacity: 0.9;
}

/* ---------- Panels ---------- */

.panel {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 36px 40px;
  margin-bottom: 24px;
  scroll-margin-top: 24px;
}

.panel h2 {
  margin: 0 0 18px;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.panel > p {
  margin: 0;
  font-size: 0.97rem;
  line-height: 1.75;
  color: var(--text-muted);
  max-width: 65ch;
}

/* ---------- Timeline ---------- */

.timeline-item + .timeline-item {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.timeline-role {
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 4px;
}

.timeline-org {
  font-size: 0.85rem;
  color: var(--accent);
  line-height: 1.4;
  margin-bottom: 8px;
  font-weight: 700;
}

.timeline-item p {
  margin-top: 8px;
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 65ch;
}

/* ---------- Highlights ---------- */

.highlight-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.highlight-grid li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-muted);
}

.h-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  margin-top: 2px;
}

.highlights {
  margin: 0;
  padding-left: 20px;
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-muted);
}

.highlights li + li {
  margin-top: 10px;
}

/* ---------- Skills ---------- */

.skill-group + .skill-group {
  margin-top: 22px;
}

.skill-group h3 {
  margin: 0 0 10px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  border-radius: 999px;
  padding: 7px 15px;
  font-size: 0.85rem;
  font-weight: 600;
  transition: transform 0.15s ease;
}

.chip:hover {
  transform: translateY(-1px);
}

.chip-indigo  { background: var(--indigo-bg);  color: var(--indigo-text); }
.chip-violet  { background: var(--violet-bg);  color: var(--violet-text); }
.chip-amber   { background: var(--amber-bg);   color: var(--amber-text); }
.chip-pink    { background: var(--pink-bg);    color: var(--pink-text); }
.chip-teal    { background: var(--teal-bg);    color: var(--teal-text); }
.chip-cyan    { background: var(--cyan-bg);    color: var(--cyan-text); }
.chip-emerald { background: var(--emerald-bg); color: var(--emerald-text); }

/* ---------- Footer ---------- */

.footer {
  padding: 12px 0 20px;
}

.footer .links {
  display: flex;
  gap: 12px;
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .layout {
    flex-direction: column;
  }

  .sidebar {
    position: sticky;
    top: 0;
    width: 100%;
    height: auto;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    padding: 14px 20px;
    z-index: 10;
    row-gap: 10px;
  }

  .sidebar-top {
    order: 1;
  }

  .sidebar-links {
    order: 2;
    flex-direction: row;
    margin-left: auto;
  }

  .connect-btn {
    white-space: nowrap;
  }

  .sidebar-nav {
    order: 3;
    flex: 1 0 100%;
    flex-direction: row;
    margin-top: 0;
    gap: 2px;
    overflow-x: auto;
  }

  .content {
    padding: 28px 20px 40px;
  }

  .hero {
    flex-direction: column-reverse;
    text-align: center;
    gap: 32px;
  }

  .hero-bio {
    max-width: none;
  }

  .stats {
    justify-content: center;
  }

  .panel {
    padding: 28px 22px;
  }

  .highlight-grid {
    grid-template-columns: 1fr;
  }
}
