:root {
  --bg: #07111f;
  --bg-soft: #0b1830;
  --surface: rgba(12, 24, 48, 0.82);
  --surface-strong: #10203f;
  --ink: #f5f8ff;
  --muted: #b8c3de;
  --line: rgba(182, 196, 235, 0.16);
  --accent: #7d5cff;
  --accent-2: #315fe8;
  --accent-3: #8db7ff;
  --shadow: 0 20px 44px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(125, 92, 255, 0.22), transparent 28%),
    radial-gradient(circle at 88% 10%, rgba(49, 95, 232, 0.2), transparent 24%),
    linear-gradient(180deg, #050d18 0%, #091426 46%, #101c37 100%);
}

a {
  color: var(--accent-3);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.hero,
.section {
  padding: 28px 5vw;
}

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding-top: 48px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-top: 8px;
}

.brand {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
}

.nav-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--muted);
  font-weight: 600;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 28px;
  align-items: start;
}

.hero-copy,
.panel-card,
.project-card,
.skill-block,
.embed-card,
.contact-section {
  background: var(--surface);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 36px;
}

.hero-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 22px;
  align-items: start;
}

.eyebrow,
.section-tag,
.project-kicker,
.panel-label {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--accent);
}

h1,
h2,
h3 {
  font-family: "Space Grotesk", sans-serif;
  margin: 0 0 12px;
}

h1 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.02;
  margin-top: 6px;
  max-width: 8ch;
}

h2 {
  font-size: clamp(1.7rem, 3vw, 2.5rem);
}

.hero-text,
.section-text,
.panel-note,
.contact-section p,
.timeline p,
.project-card p {
  color: var(--muted);
  line-height: 1.7;
}

.cta-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin: 24px 0 20px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 800;
  border: 1px solid transparent;
}

.button:hover {
  text-decoration: none;
}

.button.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
}

.button.secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  border-color: var(--line);
}

.quick-facts {
  margin: 16px 0 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.8;
}

.hero-panel {
  display: grid;
  gap: 18px;
  align-content: start;
}

.panel-card {
  padding: 26px;
}

.portrait-card {
  padding: 12px;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  width: 100%;
  max-width: 220px;
  justify-self: end;
}

.portrait-image {
  display: block;
  width: 100%;
  aspect-ratio: 0.84 / 1;
  object-fit: cover;
  object-position: center 10%;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 18px 36px rgba(0,0,0,0.28);
}

.chart-card {
  min-height: 0;
}

.focus-visual {
  margin-top: 12px;
}

.focus-screen {
  padding: 16px;
  border-radius: 22px;
  border: 1px solid rgba(255,255,255,0.08);
  background:
    radial-gradient(circle at top right, rgba(125,92,255,0.18), transparent 34%),
    linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
}

.focus-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.focus-chart {
  min-height: 104px;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.07);
  background: rgba(7, 17, 31, 0.52);
  overflow: hidden;
}

.focus-metric {
  padding: 16px;
}

.focus-metric strong {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
  font-family: "Space Grotesk", sans-serif;
  font-size: 1rem;
}

.focus-metric span {
  display: block;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.92rem;
}

.focus-forecast {
  padding: 14px;
  min-height: 140px;
  background:
    radial-gradient(circle at 85% 20%, rgba(125,92,255,0.2), transparent 28%),
    radial-gradient(circle at 20% 85%, rgba(49,95,232,0.18), transparent 34%),
    rgba(7, 17, 31, 0.52);
}

.focus-forecast svg {
  width: 100%;
  height: 100%;
}

.focus-forecast .forecast-bar {
  stroke: rgba(255,255,255,0.18);
  stroke-width: 1.2;
}

.focus-forecast .bar-1,
.focus-forecast .bar-2 {
  fill: #7ed6b1;
}

.focus-forecast .bar-3,
.focus-forecast .bar-4 {
  fill: #ead86c;
}

.focus-forecast .bar-5,
.focus-forecast .bar-6 {
  fill: #78b6f3;
}

.focus-forecast .forecast-line {
  fill: none;
  stroke-width: 7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.focus-forecast .up-line {
  stroke: #59d58b;
  filter: drop-shadow(0 0 8px rgba(89, 213, 139, 0.28));
}

.focus-forecast .mid-line {
  stroke: #f0c54b;
  filter: drop-shadow(0 0 8px rgba(240, 197, 75, 0.24));
}

.focus-forecast .down-line {
  stroke: #f06a5f;
  filter: drop-shadow(0 0 8px rgba(240, 106, 95, 0.24));
}

.focus-wide {
  grid-column: 1 / -1;
  min-height: 0;
}

.panel-note {
  margin: 14px 0 0;
  line-height: 1.6;
}

.section {
  max-width: 1400px;
  margin: 0 auto;
}

.alt {
  background: rgba(255, 255, 255, 0.03);
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 24px;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.filter-button {
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.05);
  color: var(--muted);
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 700;
  cursor: pointer;
}

.filter-button.active {
  background: var(--accent);
  color: #fff;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
  align-items: start;
}

.project-card {
  padding: 0;
  overflow: hidden;
}

.project-card summary {
  list-style: none;
  padding: 18px 18px 12px;
  cursor: pointer;
}

.project-card summary::-webkit-details-marker {
  display: none;
}

.project-card h3 {
  margin-bottom: 8px;
}

.project-summary {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.92rem;
}

.project-toggle {
  display: inline-flex;
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--accent-3);
  font-size: 0.85rem;
  font-weight: 800;
  background: rgba(255,255,255,0.04);
}

.project-card[open] .project-toggle {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}

.project-details {
  padding: 0 18px 18px;
  border-top: 1px solid var(--line);
  background: rgba(255,255,255,0.02);
}

.project-details a {
  display: inline-block;
  margin-top: 10px;
  font-weight: 700;
}

.project-card ul,
.plain-list {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.8;
}

.skills-layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.skill-block {
  padding: 24px;
}

.chip-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.chip-group span {
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(125,92,255,0.12);
  border: 1px solid rgba(141,183,255,0.16);
  color: var(--ink);
  font-weight: 700;
}

.bars {
  display: grid;
  gap: 14px;
}

.bars div {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 12px;
  align-items: center;
}

.bars span {
  color: var(--muted);
  font-weight: 700;
}

.bars i {
  display: block;
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2), var(--accent-3));
}

.timeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
}

.timeline article {
  padding: 20px 4px 0 18px;
  border-left: 4px solid rgba(125,92,255,0.45);
}

.embed-card {
  padding: 18px;
}

.embed-card iframe {
  width: 100%;
  min-height: 540px;
  border: 0;
  border-radius: 18px;
  background: #091426;
}

.embed-note {
  margin: 12px 6px 2px;
  color: var(--muted);
}

.panel-note {
  margin: 14px 0 0;
  line-height: 1.6;
}

.contact-section {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  padding: 28px;
}

.contact-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    max-width: none;
  }

  .hero-intro {
    grid-template-columns: 1fr;
  }

  .portrait-card {
    max-width: 210px;
    justify-self: start;
  }

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

  .contact-section {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .hero,
  .section {
    padding-left: 18px;
    padding-right: 18px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero {
    padding-top: 28px;
  }

  .hero-intro {
    gap: 18px;
  }

  .hero-copy,
  .panel-card,
  .project-card,
  .skill-block,
  .embed-card,
  .contact-section {
    border-radius: 18px;
  }

  .bars div {
    grid-template-columns: 1fr;
  }
}
