﻿:root {
  --bg-900: #0c0b11;
  --bg-850: #111019;
  --bg-800: #171522;
  --surface: rgba(25, 22, 36, 0.88);
  --surface-strong: rgba(27, 24, 40, 0.96);
  --line: rgba(185, 174, 220, 0.18);
  --text: #f2edff;
  --muted: #c4bdd4;
  --accent: #8c75df;
  --accent-2: #b4a7e5;
  --shadow: 0 8px 18px rgba(4, 3, 10, 0.24);
  --radius-lg: 14px;
  --radius-md: 10px;
  --header-h: 70px;
  --texture-ink: rgba(255, 255, 255, 0.045);
  --texture-mark: rgba(180, 167, 229, 0.18);
}


* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 28px);
}

body {
  margin: 0;
  font-family: "Sora", "Segoe UI", sans-serif;
  color: var(--text);
  overflow-x: hidden;
  background-color: var(--bg-900);
}


body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-color: var(--bg-900);
  background-image:
    url("data:image/svg+xml,%3Csvg width='150' height='150' viewBox='0 0 150 150' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23f2edff' fill-opacity='0.045'%3E%3Ccircle cx='18' cy='24' r='0.75'/%3E%3Ccircle cx='64' cy='18' r='0.5'/%3E%3Ccircle cx='121' cy='36' r='0.65'/%3E%3Ccircle cx='35' cy='96' r='0.55'/%3E%3Ccircle cx='104' cy='115' r='0.75'/%3E%3C/g%3E%3Cg fill='none' stroke='%238c75df' stroke-opacity='0.075' stroke-width='1'%3E%3Cpath d='M20 74h18l10-10h18'/%3E%3Cpath d='M90 54h19l8 8h17'/%3E%3Cpath d='M48 126h22l9-9h16'/%3E%3Cpath d='M118 96l10-10h16'/%3E%3C/g%3E%3Cg fill='%238c75df' fill-opacity='0.09'%3E%3Ccircle cx='48' cy='64' r='1.4'/%3E%3Ccircle cx='117' cy='62' r='1.2'/%3E%3Ccircle cx='79' cy='117' r='1.15'/%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.94;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    url("data:image/svg+xml,%3Csvg width='420' height='420' viewBox='0 0 420 420' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%23b4a7e5' stroke-opacity='0.045' stroke-width='1'%3E%3Cpath d='M38 84c46-18 87-18 123 0 35 17 76 18 124 0'/%3E%3Cpath d='M94 296c52 20 102 20 151 0 43-18 82-18 119 0'/%3E%3Cpath d='M312 42v48h48'/%3E%3Cpath d='M76 372v-42h42'/%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.68;
}

.surface-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.78;
}

body.modal-open {
  overflow: hidden;
}

.site-header,
main,
.site-footer {
  position: relative;
  z-index: 1;
}

h1, h2, h3, p, ul, figure { margin: 0; }
ul { list-style: none; padding: 0; }
a { color: inherit; text-decoration: none; }
button, select { font: inherit; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.container { width: min(1120px, 92vw); margin-inline: auto; }
.navbar.container { width: min(1360px, 94vw); }
.section { position: relative; padding: clamp(34px, 5vw, 58px) 0; }

main section[id] { scroll-margin-top: calc(var(--header-h) + 28px); }
.portfolio { padding-bottom: clamp(42px, 6vw, 72px); }

.skip-link {
  position: absolute;
  left: 12px;
  top: -100%;
  z-index: 200;
  background: var(--accent);
  color: #120a2a;
  font-weight: 700;
  padding: 10px 14px;
  border-radius: 10px;
}

.skip-link:focus { top: 12px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 5, 20, 0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}


.navbar {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 10px 0;
}

.brand { display: grid; gap: 2px; }
.brand-latin { font-family: "Space Grotesk", "Sora", sans-serif; font-size: 1.05rem; font-weight: 700; }
.brand-latin em { font-style: normal; color: var(--accent); }
.brand-cyrillic { font-size: 0.72rem; color: var(--muted); }

.nav-toggle {
  margin-left: auto;
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.nav-toggle span { width: 22px; height: 2px; background: var(--text); }

.nav-list {
  width: 100%;
  display: none;
  flex-direction: column;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 8px;
}

.nav-list.is-open { display: flex; }

.nav-list a { padding: 10px 12px; border-radius: 10px; color: var(--muted); font-weight: 600; }
.nav-list a { white-space: nowrap; }
.nav-list a:hover,
.nav-list a:focus-visible,
.nav-list a.is-active { color: var(--text); background: rgba(152, 122, 255, 0.16); }

.language-switch {
  width: auto;
  display: flex;
  gap: 5px;
  flex-wrap: nowrap;
  align-items: center;
  position: relative;
}

.lang-menu-button {
  border: 1px solid var(--line);
  background: rgba(20, 17, 31, 0.72);
  color: var(--text);
  border-radius: 999px;
  min-height: 40px;
  min-width: 86px;
  padding: 0 12px;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  white-space: nowrap;
}

.lang-menu-button::after {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-1px);
  opacity: 0.72;
}

.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 80;
  display: grid;
  gap: 4px;
  min-width: 132px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(12, 10, 20, 0.98);
  box-shadow: var(--shadow);
}

.lang-menu[hidden] {
  display: none;
}

.lang-option {
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: 10px;
  padding: 8px 9px;
  font-size: 0.8rem;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-align: left;
}

.lang-option:hover,
.lang-option:focus-visible,
.lang-option.is-active {
  color: var(--text);
  background: rgba(141, 108, 255, 0.18);
}

.lang-btn {
  border: 1px solid var(--line);
  background: rgba(20, 17, 31, 0.62);
  color: var(--muted);
  border-radius: 999px;
  min-width: 38px;
  padding: 5px 8px;
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap;
}

.flag {
  width: 18px;
  height: 12px;
  flex: 0 0 auto;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.20), 0 0 0 2px rgba(0, 0, 0, 0.16);
  overflow: hidden;
  position: relative;
}

.flag-de {
  background: linear-gradient(#111 0 33.33%, #dd0000 33.33% 66.66%, #ffce00 66.66%);
}

.flag-fr {
  background: linear-gradient(90deg, #0055a4 0 33.33%, #fff 33.33% 66.66%, #ef4135 66.66%);
}

.flag-rs {
  background: linear-gradient(#c6363c 0 33.33%, #0c4076 33.33% 66.66%, #fff 66.66%);
}

.flag-gb {
  background:
    linear-gradient(32deg, transparent 41%, #fff 41% 47%, #c8102e 47% 52%, #fff 52% 58%, transparent 58%),
    linear-gradient(-32deg, transparent 41%, #fff 41% 47%, #c8102e 47% 52%, #fff 52% 58%, transparent 58%),
    #012169;
}

.flag-gb::before,
.flag-gb::after {
  content: "";
  position: absolute;
  inset: 0;
}

.flag-gb::before {
  background:
    linear-gradient(90deg, transparent 39%, #fff 39% 61%, transparent 61%),
    linear-gradient(0deg, transparent 32%, #fff 32% 68%, transparent 68%);
}

.flag-gb::after {
  background:
    linear-gradient(90deg, transparent 45%, #c8102e 45% 55%, transparent 55%),
    linear-gradient(0deg, transparent 42%, #c8102e 42% 58%, transparent 58%);
}

.lang-btn.is-active {
  color: var(--text);
  border-color: rgba(150, 122, 255, 0.65);
  background: rgba(141, 108, 255, 0.22);
}


.hero { overflow: clip; padding-top: clamp(24px, 4vw, 38px); padding-bottom: clamp(28px, 4vw, 44px); }
.bg-glow { display: none; }

.hero-grid,
.about-grid,
.stats-grid,
.cards-grid,
.contact-wrap {
  display: grid;
  gap: 16px;
}

.hero-grid { display: block; }

.hero-copy,
.hero-projects,
.about-card,
.profile-card,
.empty-state,
.item-card,
.contact-wrap,
.modal-card {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.hero-copy,
.hero-projects,
.about-card,
.profile-card,
.contact-wrap { padding: 20px; }

.hero-copy {
  max-width: none;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.hero-copy::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: -1;
  opacity: 0.5;
  background-color: rgba(255, 255, 255, 0.018);
  background-image:
    url("data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.035'%3E%3Ccircle cx='9' cy='11' r='0.65'/%3E%3Ccircle cx='31' cy='34' r='0.55'/%3E%3Ccircle cx='61' cy='22' r='0.6'/%3E%3Ccircle cx='70' cy='63' r='0.45'/%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
  transition: opacity 0.18s ease;
}

.hero-copy:hover::before {
  opacity: 1;
}

.kicker {
  color: var(--accent-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.78rem;
  font-weight: 700;
}

h1 { font-family: "Space Grotesk", "Sora", sans-serif; font-size: clamp(1.9rem, 4.2vw, 2.85rem); line-height: 1.05; }
h1 span { color: var(--accent); }
.hero-copy p { color: var(--muted); line-height: 1.62; max-width: 68ch; }

.hero-facts {
  display: grid;
  gap: 8px;
  margin: 14px 0 16px;
  list-style: none;
}

.hero-facts li {
  color: var(--text);
  border-left: 3px solid rgba(141, 108, 255, 0.78);
  padding-left: 10px;
  font-size: 0.93rem;
}

.availability-note {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(141, 108, 255, 0.28);
  background: rgba(141, 108, 255, 0.12);
  border-radius: 12px;
  color: var(--text);
  font-weight: 700;
}

.link-arrow::after,
.project-links a::after,
.contact-links a::after {
  content: "";
  display: inline-block;
  width: 0.82em;
  height: 0.82em;
  margin-left: 0.35em;
  vertical-align: -0.04em;
  background: currentColor;
  opacity: 0.78;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='black' d='M5.5 4.75A.75.75 0 0 1 6.25 4h8a.75.75 0 0 1 .75.75v8a.75.75 0 0 1-1.5 0V6.56l-8.22 8.22a.75.75 0 0 1-1.06-1.06l8.22-8.22H6.25a.75.75 0 0 1-.75-.75Z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='black' d='M5.5 4.75A.75.75 0 0 1 6.25 4h8a.75.75 0 0 1 .75.75v8a.75.75 0 0 1-1.5 0V6.56l-8.22 8.22a.75.75 0 0 1-1.06-1.06l8.22-8.22H6.25a.75.75 0 0 1-.75-.75Z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.btn { border-radius: 10px; border: 1px solid transparent; padding: 9px 13px; font-weight: 700; transition: border-color 0.16s ease, background 0.16s ease; }
.btn:hover, .btn:focus-visible { border-color: rgba(181, 158, 255, 0.58); }
.btn-primary { background: #8d6cff; color: #120b2a; }
.btn-secondary { border-color: var(--line); background: rgba(26, 23, 39, 0.72); color: var(--text); }


.hero-ticker {
  margin-top: 18px;
  border: 1px solid rgba(185, 174, 220, 0.16);
  background: rgba(11, 10, 18, 0.38);
  border-radius: 12px;
  overflow: hidden;
}


.ticker-track {
  width: max-content;
  display: flex;
  padding: 10px 0;
  animation: ticker-slide 28s linear infinite;
}

.ticker-set {
  display: flex;
  gap: 10px;
  padding-right: 10px;
}

.hero-ticker:hover .ticker-track,
.hero-ticker:focus-within .ticker-track {
  animation-play-state: paused;
}

.ticker-set span {
  border: 1px solid rgba(185, 174, 220, 0.18);
  background: rgba(141, 108, 255, 0.12);
  color: var(--text);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
}

@keyframes ticker-slide {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.hero-projects {
  align-self: stretch;
  min-height: 100%;
  display: grid;
  grid-template-rows: auto 1fr;
}

.hero-projects-head {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
}

.hero-projects h2 {
  font-size: 1.15rem;
}

.hero-project-list {
  display: grid;
  gap: 8px;
  align-content: stretch;
}

.hero-project {
  display: grid;
  gap: 3px;
  border: 1px solid rgba(185, 174, 220, 0.16);
  background: rgba(11, 10, 18, 0.36);
  border-radius: 10px;
  padding: 10px 11px;
}

.hero-project:hover,
.hero-project:focus-visible {
  border-color: rgba(180, 167, 229, 0.46);
}

.hero-project strong {
  color: var(--text);
  font-size: 0.94rem;
}

.hero-project span {
  color: var(--muted);
  font-size: 0.82rem;
}

.mini-title { font-family: "Space Grotesk", "Sora", sans-serif; font-size: 1.15rem; }
.mini-subline { color: var(--muted); font-size: 0.92rem; margin-top: 6px; }

.focus-tabs { margin-top: 14px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.focus-tab { border: 1px solid var(--line); border-radius: 10px; background: rgba(20, 13, 43, 0.72); color: var(--muted); padding: 8px; font-weight: 700; cursor: pointer; }
.focus-tab.is-active { color: var(--text); border-color: rgba(150, 122, 255, 0.65); box-shadow: inset 0 -2px 0 rgba(150, 122, 255, 0.92); }

.focus-panel { margin-top: 12px; padding: 14px; border-radius: 10px; border: 1px solid var(--line); background: rgba(14, 13, 24, 0.82); display: grid; gap: 10px; }
.focus-panel p, .focus-panel li, .section-subline, .about-card p, .contact-wrap p, .item-card p, .empty-state p { color: var(--muted); }
.about-card p {
  font-size: clamp(1.05rem, 1.55vw, 1.22rem);
  line-height: 1.68;
}
.focus-panel ul { list-style: disc; padding-left: 18px; display: grid; gap: 6px; }
.live-status { display: inline-flex; align-items: center; gap: 8px; color: var(--accent-2); font-size: 0.82rem; font-weight: 600; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); }

.section-head { display: grid; gap: 10px; margin-bottom: 20px; }
h2 { font-family: "Space Grotesk", "Sora", sans-serif; font-size: clamp(1.55rem, 3.2vw, 2.35rem); line-height: 1.15; }

.project-explorer {
  display: grid;
  gap: 16px;
  align-items: start;
}

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

.certificate-block {
  display: grid;
  gap: 14px;
  margin-top: 20px;
}

.certificate-head {
  display: grid;
  gap: 5px;
}

.certificate-head p {
  color: var(--muted);
}

.compact-certificates {
  display: grid;
  gap: 14px;
}

.profile-card { align-content: start; }
.profile-photo-wrap { width: min(280px, 100%); aspect-ratio: 1 / 1; overflow: hidden; border-radius: 16px; border: 1px solid var(--line); margin-bottom: 14px; }
.profile-photo { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }

.about-compact {
  display: grid;
  gap: 12px;
}

.about-compact .profile-photo-wrap {
  width: min(170px, 100%);
  margin-bottom: 0;
}

.about-facts {
  display: grid;
  gap: 8px;
}

.about-facts li {
  border: 1px solid rgba(185, 174, 220, 0.14);
  background: rgba(11, 10, 18, 0.34);
  border-radius: 10px;
  color: var(--muted);
  padding: 9px 10px;
  line-height: 1.45;
}

.stats-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stat-box { padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: rgba(14, 10, 30, 0.76); display: grid; gap: 5px; }
.stat-box strong { font-size: 1.25rem; color: var(--accent); }
.stat-box span { font-size: 0.77rem; color: var(--muted); }

.career-timeline {
  position: relative;
  display: grid;
  gap: 18px;
  padding-left: 22px;
}

.career-timeline::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: rgba(181, 158, 255, 0.44);
}

.career-item {
  position: relative;
  display: grid;
  gap: 10px;
}

.career-dot {
  position: absolute;
  left: -22px;
  top: 26px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #8d6cff;
  box-shadow: 0 0 0 6px rgba(141, 108, 255, 0.12);
}

.career-card {
  border: 1px solid var(--line);
  background: rgba(22, 19, 33, 0.88);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 20px;
  display: grid;
  gap: 12px;
}

.career-card-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
}

.career-card h3 {
  color: var(--text);
  font-size: clamp(1.15rem, 2vw, 1.5rem);
}

.career-type {
  color: var(--accent-2);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.career-badge {
  flex: 0 0 auto;
  border: 1px solid rgba(181, 158, 255, 0.24);
  background: rgba(20, 17, 31, 0.72);
  color: var(--accent-2);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

.career-card p {
  color: var(--muted);
  line-height: 1.72;
}

.tech-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  padding: 8px 0;
  justify-items: stretch;
  align-items: stretch;
}

.tech-group-card {
  border: 1px solid var(--line);
  background: rgba(22, 19, 33, 0.82);
  border-radius: var(--radius-md);
  padding: 16px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 12px;
  min-height: 168px;
  align-content: start;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.tech-group-card:hover,
.tech-group-card:focus-within {
  border-color: rgba(150, 122, 255, 0.48);
  background: rgba(28, 24, 42, 0.92);
  transform: translateY(-2px);
}

.tech-group-card h3 {
  font-size: 1rem;
  color: var(--text);
}

.tech-group-card ul {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  align-items: flex-start;
  gap: 8px;
}

.tech-group-card li {
  border: 1px solid rgba(185, 174, 220, 0.16);
  background: rgba(11, 10, 18, 0.48);
  color: var(--muted);
  border-radius: 999px;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  font-size: 0.82rem;
  line-height: 1;
}

.tech-group-card li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  margin-right: 7px;
  background: rgba(180, 167, 229, 0.75);
}

.tech-tile {
  position: relative;
  width: min(100%, 118px);
  min-height: 118px;
  border-radius: 12px;
  border: 1px solid rgba(130, 153, 255, 0.35);
  background-color: rgba(12, 16, 34, 0.94);
  background-image:
    url("data:image/svg+xml,%3Csvg width='64' height='64' viewBox='0 0 64 64' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%237497ff' fill-opacity='0.05'%3E%3Ccircle cx='14' cy='16' r='1'/%3E%3Ccircle cx='48' cy='30' r='0.8'/%3E%3Ccircle cx='28' cy='52' r='0.7'/%3E%3C/g%3E%3C/svg%3E");
  display: grid;
  place-items: center;
  padding: 14px;
  box-shadow: 0 16px 36px rgba(5, 2, 15, 0.46);
  overflow: visible;
}

.tech-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  border: 1px solid rgba(143, 166, 255, 0.32);
  background: rgba(10, 17, 39, 0.86);
  display: grid;
  place-items: center;
}

.tech-icon-image {
  width: 54px;
  height: 54px;
  object-fit: contain;
  display: block;
}

.tech-icon-fallback {
  font-size: 0.66rem;
  font-weight: 700;
  color: var(--muted);
}

.tech-tooltip {
  position: absolute;
  left: 50%;
  top: auto;
  bottom: -30px;
  transform: translateX(-50%) translateY(4px);
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;
  padding: 4px 8px;
  border-radius: 7px;
  border: 1px solid rgba(187, 169, 255, 0.45);
  background: rgba(12, 9, 28, 0.97);
  color: #efe8ff;
  font-size: 0.76rem;
  font-weight: 600;
  transition: opacity 0.14s ease, transform 0.14s ease;
  z-index: 10;
}

.tech-tile:hover .tech-tooltip,
.tech-tile:focus-within .tech-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.tech-tile.label-top .tech-tooltip {
  top: -30px;
  bottom: auto;
  transform: translateX(-50%) translateY(-4px);
}

.tech-tile.label-top:hover .tech-tooltip,
.tech-tile.label-top:focus-within .tech-tooltip {
  transform: translateX(-50%) translateY(0);
}

.portfolio-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
.tab { border: 1px solid var(--line); background: rgba(19, 13, 41, 0.78); color: var(--muted); border-radius: 10px; padding: 10px; font-weight: 700; cursor: pointer; }
.tab.is-active { color: var(--text); border-color: rgba(150, 122, 255, 0.65); box-shadow: inset 0 -2px 0 rgba(150, 122, 255, 0.92); }

.tab-panel { display: none; }
.tab-panel.is-active { display: block; }
.cards-grid { grid-template-columns: 1fr; }

.item-card, .empty-state { padding: 14px; }
.item-card {
  display: flex;
  flex-direction: column;
  gap: 9px;
  min-height: 100%;
}
.item-card h3 { color: var(--text); }
.item-card {
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.item-card:hover,
.item-card:focus-within {
  border-color: rgba(150, 122, 255, 0.44);
  background: rgba(31, 24, 51, 0.86);
  transform: translateY(-2px);
}
.item-card.is-selected {
  border-color: rgba(150, 122, 255, 0.62);
  background: rgba(31, 24, 51, 0.94);
}


.project-preview {
  position: relative;
  min-height: clamp(168px, 15vw, 210px);
  border-radius: 10px;
  border: 1px solid rgba(136, 155, 255, 0.28);
  background-color: rgba(13, 14, 27, 0.96);
  background-image:
    url("data:image/svg+xml,%3Csvg width='72' height='72' viewBox='0 0 72 72' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23b4a7e5' fill-opacity='0.06'%3E%3Ccircle cx='14' cy='19' r='0.8'/%3E%3Ccircle cx='52' cy='21' r='0.55'/%3E%3Ccircle cx='36' cy='54' r='0.7'/%3E%3C/g%3E%3Cpath d='M9 44h18M42 38h16' stroke='%23b4a7e5' stroke-opacity='0.08'/%3E%3C/svg%3E");
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 16px;
}
.project-preview.has-image {
  background:
    var(--preview-image) center / cover no-repeat;
}

.certificate-preview.has-image {
  min-height: clamp(154px, 13vw, 190px);
  padding: 22px;
  background:
    var(--preview-image) center / contain no-repeat,
    rgba(12, 11, 20, 0.72);
}

.certificate-card {
  gap: 8px;
}
.project-preview.has-image .project-preview-label,
.project-preview.has-image .project-preview-title {
  display: none;
}
.project-preview-label {
  color: #ddd5ff;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.project-preview-title {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  color: rgba(244, 240, 255, 0.96);
  font-family: "Space Grotesk", "Sora", sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.2;
}
.project-tags,
.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.card-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.card-actions .project-links {
  display: contents;
}

.project-tags span,
.project-links a {
  border: 1px solid rgba(185, 174, 220, 0.16);
  background: rgba(11, 10, 18, 0.48);
  color: var(--muted);
  border-radius: 999px;
  padding: 5px 8px;
  font-size: 0.76rem;
  font-weight: 600;
}





.project-links a {
  color: #ded5ff;
  border-color: rgba(141, 108, 255, 0.34);
}

.project-links a:hover,
.project-links a:focus-visible {
  border-color: rgba(181, 158, 255, 0.72);
}

.more-projects-summary-card .more-projects-preview {
  min-height: clamp(168px, 15vw, 210px);
}

.more-projects-card-list {
  display: grid;
  gap: 8px;
  margin-top: auto;
}

.more-project-name {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(185, 174, 220, 0.18);
  border-radius: 10px;
  background: rgba(16, 14, 26, 0.58);
  color: var(--text);
  font-weight: 800;
  padding: 9px 11px;
}

.more-project-name:hover,
.more-project-name:focus-visible {
  border-color: rgba(181, 158, 255, 0.62);
  background: rgba(31, 24, 51, 0.86);
}

.more-project-name.is-disabled {
  color: var(--muted);
  cursor: default;
  opacity: 0.76;
}

.item-card button, .empty-action { justify-self: start; border: 1px solid var(--line); background: rgba(16, 14, 26, 0.78); color: var(--text); border-radius: 10px; padding: 7px 11px; cursor: pointer; transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease; }
.item-card button:hover,
.item-card button:focus-visible,
.empty-action:hover,
.empty-action:focus-visible {
  border-color: rgba(181, 158, 255, 0.62);
  background: rgba(141, 108, 255, 0.18);
}





.empty-state { display: grid; gap: 10px; }

.contact-wrap { grid-template-columns: 1fr; }
.contact-links { display: grid; gap: 10px; }
.contact-links a { border: 1px solid var(--line); background: rgba(17, 12, 38, 0.78); border-radius: 12px; padding: 12px; color: #e0d8ff; }
.contact-links a:hover, .contact-links a:focus-visible { border-color: rgba(150, 122, 255, 0.65); }

.legal-wrap {
  display: grid;
  gap: 18px;
}

.legal-grid {
  display: grid;
  gap: 14px;
}

.legal-card {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 18px;
  display: grid;
  gap: 8px;
}

.legal-card h3 {
  color: var(--text);
}

.legal-card p {
  color: var(--muted);
  line-height: 1.68;
}

.detail-modal { border: none; padding: 0; background: transparent; }
.detail-modal::backdrop { background: rgba(1, 1, 8, 0.86); }
.modal-card {
  width: min(820px, 94vw);
  max-height: min(82vh, 760px);
  padding: 18px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
  overflow: hidden;
  background: rgba(24, 16, 52, 0.98);
  border: 1px solid rgba(169, 147, 255, 0.28);
  box-shadow: 0 28px 70px rgba(3, 2, 10, 0.62);
}
.modal-card.is-document {
  width: min(1180px, 96vw);
  max-height: 94vh;
}
.modal-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
}
.modal-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.modal-head h3,
#modal-title {
  color: var(--text);
}
.modal-kicker {
  color: var(--accent-2);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  font-weight: 700;
  margin-bottom: 6px;
}
.modal-body {
  min-height: 0;
  overflow-y: auto;
  padding-right: 6px;
  display: grid;
  gap: 16px;
  overscroll-behavior: contain;
}
.modal-body::-webkit-scrollbar { width: 10px; }
.modal-body::-webkit-scrollbar-thumb {
  background: rgba(141, 108, 255, 0.35);
  border-radius: 999px;
  border: 2px solid rgba(18, 11, 40, 0.95);
}
.modal-preview {
  position: relative;
  min-height: 190px;
  border-radius: 16px;
  border: 1px solid rgba(136, 155, 255, 0.28);
  background-color: rgba(13, 14, 27, 0.98);
  background-image:
    url("data:image/svg+xml,%3Csvg width='88' height='88' viewBox='0 0 88 88' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23b4a7e5' fill-opacity='0.055'%3E%3Ccircle cx='18' cy='20' r='0.9'/%3E%3Ccircle cx='62' cy='26' r='0.7'/%3E%3Ccircle cx='40' cy='66' r='0.8'/%3E%3C/g%3E%3Cpath d='M10 52h21M50 47h24' stroke='%23b4a7e5' stroke-opacity='0.09'/%3E%3C/svg%3E");
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 18px;
}
.modal-card.has-preview-image .modal-preview {
  background:
    var(--modal-preview-image) center / contain no-repeat,
    rgba(13, 14, 27, 0.98);
}
.modal-card.has-preview-image .modal-preview-label,
.modal-card.has-preview-image .modal-preview-title,
.modal-card.has-preview-image .modal-preview-subtitle {
  display: none;
}
.modal-card.is-document .modal-preview {
  min-height: min(72vh, 860px);
}
.modal-preview-label {
  color: #efe8ff;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.modal-preview-title {
  color: #fbf8ff;
  font-family: "Space Grotesk", "Sora", sans-serif;
  font-size: clamp(1.35rem, 2.6vw, 2.1rem);
  font-weight: 700;
  text-align: center;
  line-height: 1.08;
  max-width: 90%;
}
.modal-preview-subtitle {
  color: #c9bbef;
  font-size: 0.92rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.modal-close {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  background: rgba(28, 19, 56, 0.82);
  color: var(--text);
  border-radius: 12px;
  padding: 0;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  flex: 0 0 auto;
}
.modal-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid rgba(124, 193, 255, 0.28);
  background: rgba(15, 33, 60, 0.92);
  color: #dff0ff;
  font-weight: 700;
  white-space: nowrap;
}
.modal-download:hover,
.modal-download:focus-visible {
  border-color: rgba(124, 193, 255, 0.52);
  background: rgba(20, 43, 78, 0.98);
}

.github-grid {
  display: grid;
  gap: 16px;
  align-items: start;
}

.github-card {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 18px;
}

.github-activity-card,
.open-source-card {
  display: grid;
  gap: 14px;
}

.github-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.activity-strip {
  border: 1px solid rgba(141, 108, 255, 0.24);
  background: rgba(11, 10, 18, 0.42);
  border-radius: 12px;
  overflow: hidden;
}

.activity-strip img {
  display: block;
  width: 100%;
  height: auto;
  min-height: 0;
  object-fit: contain;
}

.open-source-list {
  display: grid;
  gap: 10px;
}

.open-source-pr {
  display: grid;
  gap: 10px;
  min-height: 174px;
  padding: 13px;
  border: 1px solid rgba(185, 174, 220, 0.18);
  border-radius: 12px;
  background:
    linear-gradient(90deg, rgba(141, 108, 255, 0.12), transparent 34%) top left / 100% 3px no-repeat,
    rgba(17, 15, 27, 0.76);
  transition: border-color 0.16s ease, transform 0.16s ease, background-color 0.16s ease;
}

.open-source-pr:hover,
.open-source-pr:focus-visible {
  border-color: rgba(150, 122, 255, 0.58);
  background-color: rgba(28, 23, 43, 0.9);
  transform: translateY(-2px);
}

.open-source-top,
.open-source-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.open-source-repo {
  color: #a9c3ff;
  font-family: "Space Grotesk", "Sora", sans-serif;
  font-weight: 700;
  min-width: 0;
  overflow-wrap: anywhere;
}

.open-source-number {
  color: var(--muted);
  font-size: 0.78rem;
  white-space: nowrap;
}

.open-source-pr h4 {
  color: var(--text);
  font-size: 1.02rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.open-source-pr p,
.open-source-card p {
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.open-source-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.open-source-tags span {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
}

.open-source-tags span + span::before {
  content: "\00b7";
  margin-right: 6px;
  color: rgba(181, 158, 255, 0.7);
}

.merged-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border-radius: 9px;
  color: #f3edff;
  background: rgba(141, 108, 255, 0.92);
  font-size: 0.76rem;
  font-weight: 800;
  white-space: nowrap;
}

.merge-icon {
  width: 15px;
  height: 15px;
  display: inline-block;
  flex: 0 0 auto;
  background-color: currentColor;
  -webkit-mask: url("assets/icons/git-merge-16.svg") center / contain no-repeat;
  mask: url("assets/icons/git-merge-16.svg") center / contain no-repeat;
}

.open-source-empty {
  border: 1px dashed rgba(185, 174, 220, 0.24);
  border-radius: 12px;
  padding: 12px;
}
.modal-close:hover,
.modal-close:focus-visible {
  border-color: rgba(150, 122, 255, 0.72);
  background: rgba(40, 28, 76, 0.94);
}
.modal-description {
  display: grid;
  gap: 14px;
  color: #e6ddff;
}
.modal-description p {
  line-height: 1.78;
  margin: 0;
}
#modal-meta { list-style: disc; padding-left: 18px; color: #ddd2ff; display: grid; gap: 6px; margin: 0; }

.site-footer { border-top: 1px solid var(--line); color: var(--muted); padding: 18px 0 24px; }
.site-footer a {
  color: var(--accent-2);
  font-weight: 700;
}
.reveal { opacity: 0; transform: translateY(8px); transition: opacity 0.32s ease, transform 0.32s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

@media (min-width: 700px) {
  .about-grid { grid-template-columns: 1.08fr 0.92fr; align-items: stretch; }
  .contact-wrap { grid-template-columns: 1.08fr 0.92fr; }
  .github-grid { grid-template-columns: 1fr; }
  .open-source-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cards-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .compact-certificates { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tech-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 880px; margin-inline: auto; }
  .legal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 960px) {
  .navbar { flex-wrap: nowrap; gap: 12px; padding: 0; }
  .nav-toggle { display: none; }
  .nav-list { display: flex; width: auto; flex-direction: row; margin-left: auto; border: none; background: transparent; padding: 0; gap: 1px; }
  .nav-list a { padding: 9px 10px; }
  .language-switch { width: auto; }
  .lang-btn { min-width: 44px; padding-inline: 7px; }
  .project-explorer { display: block; }
  .project-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cards-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .open-source-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tech-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: none; }
  .compact-certificates { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 1200px) {
  .nav-list a { padding-inline: 12px; }
}

@media (max-width: 420px) {
  .hero-projects,
  .hero-copy {
    padding: 16px;
  }

  .stats-grid { grid-template-columns: 1fr; }
  .tech-grid { grid-template-columns: 1fr; gap: 10px; }
  .tech-tile { width: min(100%, 98px); min-height: 98px; padding: 8px; }
  .tech-icon { width: 54px; height: 54px; }
  .tech-icon-image { width: 44px; height: 44px; }
  .career-card-head { grid-template-columns: 1fr; display: grid; }
  .career-badge { justify-self: start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker-track { animation: none; }
  .reveal,
  .item-card,
  .tech-group-card { transition: none; transform: none; }
}

