:root {
  --ink: #10283d;
  --muted: #71808e;
  --navy: #0c263b;
  --paper: #f5f3ee;
  --white: #fff;
  --coral: #d96c4a;
  --coral-dark: #b95135;
  --line: #e7e4dc;
  --green: #217a5b;
  --gold: #d4a34d;
  --blue: #5687a6;
  --shadow: 0 16px 40px rgba(25, 42, 55, .08);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Avenir Next", Avenir, Inter, system-ui, sans-serif;
}
button, input { font: inherit; }
button { cursor: pointer; }

.demo-shell { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; padding: 30px 20px;
  display: flex; flex-direction: column; background: var(--navy); color: white;
}
.brand { display: flex; gap: 12px; align-items: center; padding: 0 10px 34px; color: white; text-decoration: none; }
.brand-mark {
  display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px;
  background: var(--coral); font-family: Georgia, serif; font-size: 25px;
}
.brand strong, .brand small { display: block; }
.brand strong { font: 700 21px Georgia, serif; letter-spacing: .02em; }
.brand small { margin-top: 2px; color: #9eb0bd; font-size: 11px; text-transform: uppercase; letter-spacing: .13em; }
.main-nav { display: grid; gap: 7px; }
.nav-item {
  width: 100%; padding: 13px 15px; border: 0; border-radius: 10px; display: flex; gap: 13px;
  background: transparent; color: #b9c6cf; text-align: left; transition: .2s ease;
}
.nav-item span { width: 20px; color: #91a4b2; font-size: 18px; text-align: center; }
.nav-item:hover, .nav-item.active { color: white; background: rgba(255,255,255,.09); }
.nav-item.active span { color: #ef987c; }
.demo-note { margin-top: auto; padding: 16px; border: 1px solid rgba(255,255,255,.12); border-radius: 12px; background: rgba(255,255,255,.05); }
.demo-note span { color: #ef987c; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.demo-note p { margin: 7px 0 0; color: #aebcc6; font-size: 12px; line-height: 1.45; }

.main { min-width: 0; }
.topbar {
  height: 98px; padding: 0 42px; display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--line); background: rgba(245,243,238,.9); backdrop-filter: blur(12px);
}
.topbar h1 { margin: 3px 0 0; font: 600 27px Georgia, serif; }
.eyebrow { margin: 0; color: var(--coral); font-size: 11px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.profile { display: flex; align-items: center; gap: 12px; }
.profile-copy { text-align: right; }
.profile-copy strong, .profile-copy small { display: block; }
.profile-copy strong { font-size: 13px; }
.profile-copy small { margin-top: 3px; color: var(--muted); font-size: 11px; }
.avatar { display: grid; place-items: center; width: 43px; height: 43px; border-radius: 50%; background: #dae4e8; color: var(--navy); font-weight: 800; font-size: 13px; }
.menu-button { display: none; border: 0; background: none; color: var(--ink); font-size: 24px; }
.content { max-width: 1440px; margin: auto; padding: 34px 42px 60px; }

.welcome-card {
  min-height: 178px; padding: 34px 38px; display: flex; align-items: center; justify-content: space-between; gap: 25px;
  border-radius: 18px; overflow: hidden; position: relative; background: var(--navy); color: white; box-shadow: var(--shadow);
}
.welcome-card::after {
  content: ""; position: absolute; width: 280px; height: 280px; right: 13%; top: -145px;
  border: 55px solid rgba(217,108,74,.2); border-radius: 50%;
}
.pill { color: #ef987c; font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.welcome-card h2 { max-width: 650px; margin: 12px 0 8px; font: 500 31px/1.15 Georgia, serif; }
.welcome-card p { margin: 0; color: #b9c7d0; }
.primary-button {
  position: relative; z-index: 1; border: 0; border-radius: 10px; padding: 13px 18px;
  background: var(--coral); color: white; font-weight: 750; box-shadow: 0 8px 18px rgba(0,0,0,.15);
}
.primary-button:hover { background: var(--coral-dark); transform: translateY(-1px); }

.metrics { margin: 22px 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.metric-card { position: relative; min-height: 155px; padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--white); box-shadow: var(--shadow); }
.metric-card p { margin: 0 38px 14px 0; color: var(--muted); font-size: 12px; }
.metric-card > strong { display: block; font: 600 27px Georgia, serif; }
.metric-card small { display: block; margin-top: 11px; color: var(--green); font-size: 11px; }
.metric-icon { position: absolute; top: 19px; right: 19px; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: #f7e7e1; color: var(--coral); font-weight: 800; }

.dashboard-grid { margin-bottom: 22px; display: grid; grid-template-columns: 1.05fr .95fr; gap: 22px; }
.panel { padding: 24px; border: 1px solid var(--line); border-radius: 15px; background: var(--white); box-shadow: var(--shadow); }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.panel-heading h2 { margin: 5px 0 0; font: 600 20px Georgia, serif; }
.text-button { padding: 0; border: 0; background: transparent; color: var(--coral); font-size: 12px; font-weight: 700; }
.positive { color: var(--green); font-size: 12px; font-weight: 800; }
.session-list { display: grid; }
.session { padding: 12px 0; display: grid; grid-template-columns: 52px 1fr 28px; align-items: center; gap: 15px; border-top: 1px solid #efede8; }
.session:first-child { border-top: 0; padding-top: 0; }
.session time { width: 49px; height: 52px; display: grid; place-content: center; border-radius: 9px; text-align: center; }
.session time.coral { background: #f8e6df; color: var(--coral-dark); }
.session time.blue { background: #e4eff5; color: #3b6d8b; }
.session time.gold { background: #f8efd9; color: #9c7024; }
.session time strong, .session time small { display: block; }
.session time strong { font: 700 19px Georgia, serif; line-height: 1; }
.session time small { margin-top: 4px; font-size: 8px; font-weight: 900; letter-spacing: .1em; }
.session div strong, .session div span { display: block; }
.session div strong { font-size: 13px; }
.session div span { margin-top: 4px; color: var(--muted); font-size: 11px; }
.session button { border: 0; background: transparent; color: var(--muted); }

.bar-chart { height: 200px; padding-top: 25px; display: flex; align-items: end; justify-content: space-around; gap: 12px; border-bottom: 1px solid var(--line); }
.bar-item { position: relative; height: 100%; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: end; gap: 7px; }
.bar { width: min(34px, 70%); min-height: 10px; border-radius: 6px 6px 0 0; background: #b8cad4; transition: .25s; }
.bar-item:last-child .bar { background: var(--coral); }
.bar-item:hover .bar { filter: brightness(.9); }
.bar-value { opacity: 0; position: absolute; top: -6px; padding: 4px 6px; border-radius: 5px; background: var(--navy); color: white; font-size: 9px; transition: .2s; }
.bar-item:hover .bar-value { opacity: 1; }
.bar-item small { margin-bottom: -25px; color: var(--muted); font-size: 10px; }

.gantt-panel { margin-bottom: 22px; }
.gantt-range { color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.gantt-chart { min-width: 0; }
.gantt-head, .gantt-row { display: grid; grid-template-columns: minmax(190px, 26%) 1fr; }
.gantt-head { align-items: end; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.gantt-head > span { padding: 0 14px 10px 0; }
.gantt-head > div { display: grid; grid-template-columns: repeat(3, 1fr); padding-bottom: 10px; }
.gantt-head > div span { padding-left: 10px; border-left: 1px solid var(--line); }
.gantt-row { min-height: 64px; border-top: 1px solid var(--line); }
.gantt-project { display: flex; flex-direction: column; justify-content: center; padding: 10px 14px 10px 0; }
.gantt-project strong { font-size: 12px; }
.gantt-project span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.gantt-track { position: relative; overflow: hidden; background-image: linear-gradient(to right, var(--line) 1px, transparent 1px); background-size: 33.333% 100%; }
.gantt-bar { position: absolute; left: var(--start); top: 17px; width: var(--span); height: 30px; overflow: hidden; border-radius: 7px; background: #f5d4c9; color: var(--coral-dark); }
.gantt-bar > span { position: absolute; inset: 0 auto 0 0; border-radius: inherit; background: var(--coral); opacity: .82; }
.gantt-bar b { position: relative; z-index: 1; display: block; padding: 8px 9px; color: var(--navy); font-size: 9px; }
.gantt-bar.blue { background: #dceaf1; color: #3b6d8b; }
.gantt-bar.blue > span { background: var(--blue); }
.gantt-bar.gold { background: #f7ead0; color: #8b641d; }
.gantt-bar.gold > span { background: var(--gold); }
.gantt-bar.green { background: #dcece5; color: var(--green); }
.gantt-bar.green > span { background: #69a48d; }
.gantt-legend { padding-top: 12px; display: flex; justify-content: space-between; color: var(--muted); font-size: 9px; }
.gantt-legend i { display: inline-block; width: 9px; height: 9px; margin-right: 5px; border-radius: 2px; background: var(--coral); vertical-align: -1px; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th { padding: 11px 14px; background: #f7f6f2; color: var(--muted); font-size: 9px; letter-spacing: .1em; text-align: left; text-transform: uppercase; }
td { padding: 15px 14px; border-bottom: 1px solid #eeece7; white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fcfbf8; }
.status { display: inline-block; padding: 5px 9px; border-radius: 999px; font-size: 9px; font-weight: 800; }
.status.success { background: #e2f2eb; color: var(--green); }
.status.warning { background: #fbefd6; color: #93651a; }
.status.neutral { background: #e9eef1; color: #60717e; }

.section-heading { margin-bottom: 25px; display: flex; align-items: end; justify-content: space-between; gap: 20px; }
.section-heading h2 { margin: 7px 0 4px; font: 600 32px Georgia, serif; }
.section-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.toolbar { margin-bottom: 20px; display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 11px; }
.search { width: min(380px, 75%); padding: 10px 13px; display: flex; gap: 9px; border: 1px solid var(--line); border-radius: 9px; background: #faf9f6; }
.search input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); }

@media (max-width: 1050px) {
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .demo-shell { display: block; }
  .sidebar { position: fixed; z-index: 20; width: 250px; left: -270px; box-shadow: 20px 0 50px rgba(0,0,0,.2); transition: left .25s ease; }
  .sidebar.open { left: 0; }
  .menu-button { display: block; }
  .topbar { height: 80px; padding: 0 18px; justify-content: flex-start; gap: 15px; }
  .topbar h1 { font-size: 21px; }
  .profile { margin-left: auto; }
  .profile-copy { display: none; }
  .content { padding: 20px 16px 40px; }
  .welcome-card { padding: 27px 24px; align-items: flex-start; flex-direction: column; }
  .welcome-card h2 { font-size: 25px; }
  .metrics { grid-template-columns: 1fr 1fr; }
  .metric-card { min-height: 140px; padding: 18px; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .gantt-panel { overflow-x: auto; }
  .gantt-panel .panel-heading { position: sticky; left: 0; width: calc(100vw - 80px); }
  .gantt-chart { min-width: 680px; }
}
@media (max-width: 480px) {
  .metrics { grid-template-columns: 1fr; }
  .profile { display: none; }
  .welcome-card .primary-button { width: 100%; }
}
