/* =========================================================
   GLOBAL VARIABLES & RESET
========================================================= */
:root {
  --clr-bg: #f0f4f8;
  --clr-surface: #ffffff;
  --clr-text: #1e293b;
  --clr-primary: #2196f3;
  --clr-primary-light: #64b5f6;

  --radius: 10px;
  --shadow: 0 2px 8px rgba(0,0,0,0.08);
  --max-width: 900px;

  --font-main: "Montserrat", sans-serif;
  --font-heading: "Manrope", sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.5;
  background: var(--clr-bg);
  color: var(--clr-text);
  scroll-behavior: smooth;
}
/* ===============================
   CLEAN SIDEBAR NAVIGATION
=============================== */

.nav-header {
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.nav-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0.9rem 1.2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.2rem;
  text-decoration: none;
  color: var(--clr-text);
}

.nav-desktop {
  display: flex;
  gap: 1.6rem;
}

.nav-desktop a,
.nav-panel a {
  position: relative;
  text-decoration: none;
  color: var(--clr-text);
  font-weight: 600;
}

.nav-close {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  background: none;
  border: none;
  font-size: 1.6rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--clr-text);
}

/* BURGER BUTTON */
.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-burger span {
  width: 26px;
  height: 3px;
  background: var(--clr-text);
  border-radius: 4px;
  transition: 0.3s;
}

/* MOBILE SIDEBAR PANEL */
.nav-panel {
  position: fixed;
  top: 0;
  right: -260px; /* hidden start */
  width: 240px;
  height: 100vh;
  background: white;
  box-shadow: -4px 0 20px rgba(0,0,0,0.1);
  padding: 5rem 1.6rem;
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
  transition: 0.35s ease;
}

.nav-panel.open {
  right: 0;
}

.nav-panel nav a {
  display: block;
  width: 100%;
  text-decoration: none;
  font-size: 1.2rem;
  font-weight: 600;
  padding: 0.8rem 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  color: var(--clr-text);
}

/* OVERLAY */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.28);
  opacity: 0;
  pointer-events: none;
  transition: 0.3s;
}

.nav-overlay.show {
  opacity: 1;
  pointer-events: auto;
}
/* ===============================
   NAVIGATION UNDERLINE (HOVER + ACTIVE)
=============================== */

/* UNDERLINE BASIS */
.nav-desktop a::after,
.nav-panel a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 2px;
  background: var(--clr-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.nav-desktop a:hover::after,
.nav-desktop a.active::after,
.nav-panel a:hover::after,
.nav-panel a.active::after {
  transform: scaleX(1);
}

/* ACTIVE TEXT FARBE */
.nav-desktop a.active,
.nav-panel a.active {
  color: var(--clr-primary);
}


/* MOBILE RESPONSIVE */
@media (max-width: 768px) {
  .nav-desktop {
    display: none;
  }

  .nav-burger {
    display: flex;
  }
}

/* =========================================================
   HERO SECTION – Portrait + Gradient
========================================================= */
#hero {
  min-height: 100vh;
  padding: 8rem 1.5rem 4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  position: relative;
  overflow: hidden;

  background: radial-gradient(circle at top left, #cee9ff 0%, #68b4f3 38%, #303d5a 100%);
}

#hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at bottom right, rgba(15,23,42,0.6), transparent 55%);
  pointer-events: none;
}

#hero * {
  position: relative;
  z-index: 1;
}

.hero-inner {
  width: 100%;
  max-width: var(--max-width);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.4fr);
  gap: 3rem;
  align-items: center;
}

/* Portrait */
.hero-left {
  display: flex;
  justify-content: center;
}

.hero-avatar {
  width: 260px;
  height: 550px;
  border-radius: 32px;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,0.28);
  box-shadow: 0 26px 60px rgba(15,23,42,0.75);
  background: rgba(15,23,42,0.5);
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}

/* Text */
.hero-right h1 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: clamp(2.2rem, 4vw, 3.3rem);
  margin-bottom: 0.75rem;
}

.hero-kicker {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  opacity: 0.85;
  margin-bottom: 0.4rem;
}

.hero-subtitle {
  font-size: 1rem;
  max-width: 30rem;
  color: rgba(241,245,249,0.9);
  margin-bottom: 1.5rem;
}

/* Hero Buttons */
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn-primary {
  background-color: #ffffff;
  color: var(--clr-primary);
  padding: 0.7rem 1.4rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  font-size: 0.95rem;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
  box-shadow: 0 12px 30px rgba(15,23,42,0.35);
}

.btn-primary:hover {
  background: var(--clr-primary);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 18px 40px rgba(15,23,42,0.55);
}

.btn-ghost {
  background: rgba(15,23,42,0.2);
  color: #e5e7eb;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  font-weight: 500;
  text-decoration: none;
  font-size: 0.95rem;
  border: 1px solid rgba(148,163,184,0.5);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.btn-ghost:hover {
  background: rgba(15,23,42,0.65);
  border-color: rgba(248,250,252,0.7);
  color: #ffffff;
  transform: translateY(-1px);
}

/* =========================================================
   MAIN SECTIONS & CARDS
========================================================= */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.5rem 2rem;
}

section {
  background: var(--clr-surface);
  padding: 3rem 1.5rem;
  margin-bottom: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.section-accent {
  position: relative;
}

.section-accent::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: clamp(80px, 20%, 300px);
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--clr-primary), var(--clr-primary-light));
  box-shadow: 0 4px 10px rgba(33,150,243,0.12);
}

h2 {
  font-family: var(--font-heading);
  margin-bottom: 2rem;
}

/* =========================================================
   ABOUT SECTION
========================================================= */
.about-grid {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) 2fr;
  gap: 1.5rem 2.5rem;
  align-items: center;
}

.profile {
  text-align: center;
}

.profile-pic {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(0,122,204,0.1);
  box-shadow: var(--shadow);
  transition: transform 0.25s ease;
}

.profile-pic:hover {
  transform: translateY(-6px) rotate(-1deg);
}

.muted {
  font-size: 0.85rem;
  color: #6b7280;
}

.about-content p {
  font-size: 1rem;
  line-height: 1.6;
}

/* Divider */
.about-divider {
  border: none;
  border-top: 1px solid rgba(0,0,0,0.08);
  margin: 2rem 0;
}

/* CV GRID */
.about-cv-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem 4rem;
  align-items: start;
  margin-top: 1.5rem;
  padding: 0 0.5rem;
}

.about-cv-grid h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  margin-bottom: 0.8rem;
  color: var(--clr-text);
}

.about-cv-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.about-cv-grid li {
  margin-bottom: 0.45rem;
  padding-left: 1.2rem;
  position: relative;
  font-size: 0.96rem;
  line-height: 1.45;
}

.about-cv-grid li::before {
  content: "•";
  position: absolute;
  left: 0;
  top: 0.1rem;
  color: var(--clr-primary);
  font-weight: bold;
}

/* =========================================================
   SKILLS
========================================================= */
.skills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.skills-list span {
  background: rgba(33,150,243,0.12);
  color: var(--clr-primary);
  font-weight: 600;
  padding: 0.5rem 0.8rem;
  font-size: 0.85rem;
  border-radius: 12px;
  display: inline-block;
  white-space: nowrap;
}

/* =========================================================
   RUNNING SECTION
========================================================= */
#latest-run {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.run-card {
  background: var(--clr-surface);
  padding: 1.3rem 1.4rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: 0.15s ease;
}

.run-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.run-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 0.25rem;
}

.run-date {
  opacity: 0.7;
  margin-bottom: 0.9rem;
}

.run-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--clr-text);
  margin-bottom: 0.45rem;
}

.run-row .icon {
  display: inline-flex;
  width: 1.1rem;
  height: 1.1rem;
  color: var(--clr-primary);
}

.run-row .icon svg {
  width: 100%;
  height: 100%;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.run-row .dot {
  opacity: 0.4;
  margin: 0 0.2rem;
}

.run-updated {
  margin-top: 0.7rem;
  opacity: 0.6;
  font-size: 0.75rem;
}

#running h2 {
  margin-top: 0;
  margin-bottom: 1.5rem;
}

#running h3 {
  margin-top: 1.5rem;
  margin-bottom: 1rem;
}

/* WEEKLY CHART */
.chart-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  margin: 2.5rem 0 1rem 0;
  color: var(--clr-text);
}

.chart-card {
  background: var(--clr-surface);
  padding: 1.5rem;
  border-radius: 14px;
  box-shadow: var(--shadow);
  margin-bottom: 3rem;
  position: relative;
  overflow: hidden;
}

.chart-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(33,150,243,0.03) 1px, transparent 1px),
    linear-gradient(180deg, rgba(33,150,243,0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.3;
  pointer-events: none;
}

#weeklyChart {
  width: 100% !important;
  height: 320px !important;
  display: block;
  border-radius: 10px;
}

.weekly-total {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--clr-primary);
  margin-bottom: 1rem;
  opacity: 0.9;
}

/* =========================================================
   FOOTER
========================================================= */
footer {
  text-align: center;
  padding: 2rem;
  color: #777;
}

/* =========================================================
   RESPONSIVE
========================================================= */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-left {
    order: -1;
  }

  .hero-right {
    align-items: center;
    justify-content: center;
    display: flex;
    flex-direction: column;
  }

  .hero-subtitle {
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
 .about-cv-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }

  .about-cv-grid li {
    padding-left: 0;
  }

  .about-cv-grid li::before {
    display: none;
  }
  #weeklyChart {
    height: 240px !important;
  }
}

@media (max-width: 480px) {
  #hero {
    padding-top: 7rem;
  }

  .hero-avatar {
    width: 130px;
    height: 280px;
  }

  .hero-right h1 {
    font-size: clamp(1.9rem, 9vw, 2.4rem);
  }
}

body.nav-open {
  overflow: hidden;
  touch-action: none;
}
