:root{
  --bg: #0b0f17;
  --panel: rgba(255,255,255,0.06);
  --panel2: rgba(255,255,255,0.08);
  --text: rgba(255,255,255,0.92);
  --muted: rgba(255,255,255,0.66);
  --border: rgba(255,255,255,0.12);
  --shadow: 0 20px 60px rgba(0,0,0,0.35);
  --accent: #7c3aed;
  --accent2: #22c55e;
  --max: 1120px;
  --radius: 16px;
  --radius2: 12px;
  --font: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

[data-theme="light"]{
  --bg: #f6f7fb;
  --panel: rgba(0,0,0,0.04);
  --panel2: rgba(0,0,0,0.06);
  --text: rgba(9,12,18,0.92);
  --muted: rgba(9,12,18,0.62);
  --border: rgba(9,12,18,0.12);
  --shadow: 0 20px 60px rgba(15,23,42,0.12);
  --accent: #6d28d9;
  --accent2: #16a34a;
}

*{ box-sizing: border-box; }
html,body{ height:100%; }
body{
  margin:0;
  background:
    radial-gradient(1000px 500px at 20% 0%, rgba(124,58,237,0.35), transparent 60%),
    radial-gradient(900px 500px at 90% 10%, rgba(34,197,94,0.22), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.55;
}

a{ color: inherit; text-decoration: none; }
a:hover{ text-decoration: underline; text-underline-offset: 4px; }

.container{
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

.skip{
  position:absolute; left:-9999px; top:auto; width:1px; height:1px; overflow:hidden;
}
.skip:focus{
  left: 20px; top: 20px; width:auto; height:auto;
  background: var(--panel);
  padding: 10px 12px; border-radius: 10px; border:1px solid var(--border);
}

.topbar{
  position: sticky;
  top:0;
  z-index: 10;
  backdrop-filter: blur(16px);
  background: linear-gradient(to bottom, rgba(0,0,0,0.35), rgba(0,0,0,0.06));
  border-bottom: 1px solid var(--border);
}
[data-theme="light"] .topbar{
  background: linear-gradient(to bottom, rgba(255,255,255,0.9), rgba(255,255,255,0.65));
}
.topbar__inner{
  display:flex;
  align-items:center;
  gap: 18px;
  padding: 14px 0;
}
.brand{
  display:flex; align-items:center; gap:10px;
  min-width: 140px;
}
.brand__dot{
  width:10px; height:10px; border-radius:999px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: 0 0 0 6px rgba(124,58,237,0.16);
}
.brand__name{ font-weight: 600; letter-spacing: 0.2px; }

.nav{
  display:flex; gap: 14px;
  flex: 1;
  justify-content: center;
}
.nav a{
  font-size: 14px;
  color: var(--muted);
  padding: 8px 10px;
  border-radius: 10px;
}
.nav a:hover{
  color: var(--text);
  background: var(--panel);
  text-decoration:none;
}

.topbar__actions{
  display:flex;
  gap: 10px;
  align-items:center;
}

.btn{
  display:inline-flex; align-items:center; justify-content:center;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel);
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  text-decoration:none;
}
.btn:hover{ background: var(--panel2); text-decoration:none; }
.btn--primary{
  border-color: rgba(124,58,237,0.45);
  background: linear-gradient(135deg, rgba(124,58,237,0.85), rgba(124,58,237,0.45));
}
.btn--ghost{
  background: transparent;
}

.hero{
  padding: 44px 0 26px;
}
.hero__grid{
  display:grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 18px;
  align-items:start;
}
.kicker{
  margin:0 0 10px;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 0.2px;
}
h1{
  margin: 0 0 12px;
  font-size: clamp(34px, 4vw, 48px);
  line-height: 1.1;
}
.subtitle{
  margin: 0 0 18px;
  color: var(--muted);
  max-width: 62ch;
}

.meta{
  display:flex;
  gap: 14px;
  flex-wrap: wrap;
  margin: 18px 0 18px;
}
.meta__item{
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 10px 12px;
  background: var(--panel);
  min-width: 180px;
}
.meta__label{
  display:block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 4px;
}
.meta__value{
  display:block;
  font-weight: 600;
}

.cta{ display:flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }

.downloads{
  display:flex; flex-wrap: wrap; gap: 10px;
  margin-top: 18px;
}
.pill{
  display:inline-flex;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  font-size: 13px;
}
.pill:hover{
  background: var(--panel);
  color: var(--text);
  text-decoration:none;
}

.section{
  padding: 26px 0;
}
.section h2{
  margin: 0 0 14px;
  font-size: 22px;
}
.prose{
  color: var(--muted);
  max-width: 86ch;
}

.card{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 16px 16px;
  box-shadow: var(--shadow);
}
.card__title{
  margin: 0 0 10px;
  font-size: 16px;
}
h3{
  margin: 0 0 10px;
  font-size: 16px;
}
.desc{ color: var(--muted); margin: 0 0 10px; }

.bullets{
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}
.bullets li{ margin: 6px 0; }

.grid-2{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.timeline{
  display:flex;
  flex-direction: column;
  gap: 14px;
}
.timeline__item{
  display:grid;
  grid-template-columns: 0.9fr 1.6fr;
  gap: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 16px;
}
.role{ font-weight: 700; }
.company{ color: var(--muted); margin-top: 4px; }
.time{ color: var(--muted); margin-top: 4px; font-size: 13px; }
.timeline__right .desc{ margin-top: 0; }

.chips{
  display:flex;
  flex-wrap: wrap;
  gap: 10px;
}
.chip{
  display:inline-flex;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.22);
  color: var(--text);
  font-size: 13px;
  white-space: nowrap;
}
[data-theme="light"] .chip{
  background: rgba(124,58,237,0.08);
  border-color: rgba(124,58,237,0.18);
}

.contacts{
  list-style:none;
  padding:0;
  margin:0;
}
.contacts li{
  display:grid;
  grid-template-columns: 110px 1fr;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border);
}
.contacts li:last-child{ border-bottom: none; }
.contacts span:first-child{ color: var(--muted); }

.footer{
  display:flex;
  gap: 10px;
  align-items:center;
  justify-content:center;
  margin-top: 16px;
  color: var(--muted);
  font-size: 13px;
}
.footer__sep{ opacity: 0.6; }
.mt-16{ margin-top: 14px; }

@media (max-width: 900px){
  .nav{ display:none; }
  .hero__grid{ grid-template-columns: 1fr; }
  .grid-2{ grid-template-columns: 1fr; }
  .timeline__item{ grid-template-columns: 1fr; }
  .meta__item{ min-width: unset; flex: 1; }
}

/* Print */
@media print{
  .topbar, .downloads, #printBtn, #themeToggle { display:none !important; }
  body{ background: #fff !important; color: #111 !important; }
  .card, .timeline__item{ box-shadow: none !important; }
  a{ text-decoration:none; }
  .section{ padding: 14px 0; }
}

/* Theme toggle icon button */
.themeToggle{
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.themeToggle:hover{ background: var(--panel); }
.themeToggle__icon{ font-size: 18px; line-height: 1; }

/* Cookie modal (centered) */
.cookie{
  position: fixed;
  inset: 0;
  display: none;              /* shown via JS */
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(6px);
}
.cookie__card{
  width: min(760px, calc(100% - 24px));
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(5, 10, 18, 0.92);
  box-shadow: var(--shadow);
  padding: 18px;
}
[data-theme="light"] .cookie__card{
  background: rgba(255, 255, 255, 0.94);
}
.cookie__title{
  font-weight: 800;
  font-size: 18px;
  margin-bottom: 6px;
}
.cookie__text{
  color: var(--muted);
  margin-bottom: 14px;
}
.cookie__actions{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}
.cookie a{
  text-decoration: underline;
  text-underline-offset: 3px;
}
/* Mobile: force perfectly uniform background (no gradients, no bands) */
@media (max-width: 900px){
  html, body{
    background: var(--bg) !important;
  }
  body{
    background-image: none !important;
    background-attachment: scroll !important;
  }
}

/* Theme switch (pill) */
.themeSwitch{
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 38px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(10,14,22,0.18);
  backdrop-filter: blur(10px);
  cursor: pointer;
}

[data-theme="light"] .themeSwitch{
  background: rgba(255,255,255,0.45);
}

.themeSwitch__icon{
  width: 16px;
  height: 16px;
  display: inline-block;
  position: relative;
  opacity: 0.7;
}

/* Sun icon */
.themeSwitch__icon--sun{
  border-radius: 50%;
  background: #facc15;
  box-shadow: 0 0 0 3px rgba(250,204,21,0.25);
}

/* Moon icon */
.themeSwitch__icon--moon{
  border-radius: 50%;
  background: #e5e7eb;
}
.themeSwitch__icon--moon::after{
  content: "";
  position: absolute;
  top: -2px;
  left: 4px;
  width: 14px;
  height: 14px;
  background: var(--bg);
  border-radius: 50%;
}

/* Track */
.themeSwitch__track{
  width: 58px;
  height: 26px;
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.10);
  position: relative;
}

[data-theme="light"] .themeSwitch__track{
  background: rgba(0,0,0,0.06);
  border-color: rgba(0,0,0,0.10);
}

/* Thumb */
.themeSwitch__thumb{
  position: absolute;
  top: 50%;
  left: 4px;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 8px 18px rgba(34,197,94,0.28);
  transition: left 180ms ease;
}

[data-theme="light"] .themeSwitch__thumb{
  left: 36px;
}