/* ============================================================
   Abdulaziz Awal — portfolio
   Brand: deep green #063020 + white, on near-black
   ============================================================ */

:root {
  --green: #063020;
  --green-mid: #0e5c3c;
  --green-bright: #2fd97f;
  --ink: #0a0f0d;
  --ink-2: #0e1613;
  --paper: #eef5f1;
  --muted: #8fa89c;
  --line: rgba(47, 217, 127, 0.14);
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1.65;
  overflow-x: hidden;
}

::selection { background: var(--green-bright); color: var(--ink); }

.mono { font-family: var(--font-mono); }

a { color: inherit; text-decoration: none; }

/* ---------- film grain ---------- */
.grain {
  position: fixed; inset: -50%;
  width: 200%; height: 200%;
  pointer-events: none; z-index: 60;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 8s steps(10) infinite;
}
@keyframes grain {
  0%,100% { transform: translate(0,0); } 10% { transform: translate(-5%,-8%); }
  20% { transform: translate(-13%,3%); } 30% { transform: translate(6%,-10%); }
  40% { transform: translate(-4%,12%); } 50% { transform: translate(-12%,7%); }
  60% { transform: translate(11%,0%); } 70% { transform: translate(0%,10%); }
  80% { transform: translate(3%,13%); } 90% { transform: translate(-9%,4%); }
}

/* ---------- custom cursor ---------- */
.cursor-dot, .cursor-ring {
  position: fixed; top: 0; left: 0;
  pointer-events: none; z-index: 100;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}
.cursor-dot { width: 6px; height: 6px; background: var(--green-bright); }
.cursor-ring {
  width: 34px; height: 34px;
  border: 1px solid rgba(47, 217, 127, 0.45);
  transition: width 0.25s var(--ease-out), height 0.25s var(--ease-out),
              border-color 0.25s;
}
.cursor-ring.is-hover { width: 56px; height: 56px; border-color: var(--green-bright); }
@media (hover: none), (max-width: 760px) {
  .cursor-dot, .cursor-ring { display: none; }
}

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 4.5vw;
  transition: background 0.35s, backdrop-filter 0.35s, padding 0.35s;
}
.nav.is-scrolled {
  background: rgba(10, 15, 13, 0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 12px 4.5vw;
  border-bottom: 1px solid var(--line);
}
.nav-brand { display: flex; align-items: center; gap: 10px; }
.nav-logo { width: 30px; height: 30px; border-radius: 8px; }
.nav-name { font-size: 14px; letter-spacing: 0.02em; color: var(--muted); }
.nav-links { display: flex; gap: 30px; }
.nav-links a {
  font-size: 14px; font-weight: 500; color: var(--muted);
  transition: color 0.25s;
  display: inline-flex; gap: 7px; align-items: baseline;
}
.nav-links a:hover { color: var(--paper); }
.nav-num { font-size: 10px; color: var(--green-bright); }
.nav-cta {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--paper);
  transition: border-color 0.25s, background 0.25s;
}
.nav-cta:hover { border-color: var(--green-bright); background: rgba(47,217,127,0.08); }
@media (max-width: 760px) { .nav-links { display: none; } }
/* ---------- nav socials ---------- */
.nav-right { display: flex; align-items: center; gap: 12px; }
.nav-socials { display: flex; align-items: center; gap: 2px; }
.nav-socials a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 999px;
  color: var(--muted);
  transition: color 0.25s, background 0.25s, transform 0.25s;
}
.nav-socials a:hover { color: var(--green-bright); background: rgba(47,217,127,0.08); transform: translateY(-2px); }

/* ---------- contact alt links ---------- */
.contact-alt { margin-top: 28px; color: var(--muted); font-size: 13px; }
.contact-alt a {
  color: var(--paper);
  border-bottom: 1px solid var(--line);
  transition: color 0.25s, border-color 0.25s;
}
.contact-alt a:hover { color: var(--green-bright); border-color: var(--green-bright); }

@media (max-width: 760px) {
  .nav-name { display: none; }
  .nav-right { gap: 6px; }
  .nav-socials a { width: 30px; height: 30px; }
  .nav-cta { padding: 8px 12px; }
}


/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 55% at 50% -10%, rgba(14, 92, 60, 0.55), transparent 65%),
    linear-gradient(180deg, var(--green) 0%, var(--ink) 62%);
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(47,217,127,0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(47,217,127,0.055) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 75% 65% at 50% 40%, black, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 40%, black, transparent 75%);
}
.hero-glow {
  position: absolute;
  width: 620px; height: 620px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(47,217,127,0.13), transparent 65%);
  filter: blur(10px);
  pointer-events: none;
  left: 50%; top: 42%;
  transform: translate(-50%, -50%);
}
.hero-inner {
  position: relative; z-index: 2;
  text-align: center;
  padding: 120px 5vw 130px;
  max-width: 1000px;
}
.hero-mark {
  width: 84px; height: 84px;
  border-radius: 22px;
  margin-bottom: 34px;
  box-shadow: 0 18px 60px rgba(0,0,0,0.45), 0 0 0 1px var(--line);
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); }
}
.hero-eyebrow {
  color: var(--green-bright);
  font-size: 14px;
  letter-spacing: 0.08em;
  margin-bottom: 18px;
}
.hero-title {
  font-size: clamp(52px, 11vw, 128px);
  line-height: 0.95;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 26px;
}
.hero-title .line { display: block; overflow: hidden; }
.hero-title .word {
  display: inline-block;
  transform: translateY(110%);
  animation: rise 1s var(--ease-out) forwards;
}
.hero-title .line:nth-child(2) .word { animation-delay: 0.12s; }
@keyframes rise { to { transform: translateY(0); } }
.hero-title .accent {
  color: transparent;
  -webkit-text-stroke: 2px var(--green-bright);
}
.hero-typed {
  font-size: clamp(15px, 2.4vw, 20px);
  color: var(--paper);
  min-height: 1.7em;
  margin-bottom: 22px;
}
.hero-typed .prompt { color: var(--green-bright); margin-right: 10px; }
.caret {
  display: inline-block;
  width: 9px; height: 1.15em;
  background: var(--green-bright);
  vertical-align: text-bottom;
  margin-left: 3px;
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.hero-sub {
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto 34px;
}
.hero-sub a {
  color: var(--green-bright);
  border-bottom: 1px solid rgba(47,217,127,0.35);
  transition: border-color 0.25s;
}
.hero-sub a:hover { border-color: var(--green-bright); }
.hero-actions {
  display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
  margin-bottom: 44px;
}
.hero-stack {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 10px 22px; justify-content: center;
  font-size: 12.5px; color: var(--muted);
}
.hero-stack li { display: flex; align-items: center; gap: 8px; }
.hero-stack li::before {
  content: ""; width: 5px; height: 5px;
  background: var(--green-bright); border-radius: 1px;
}
.scroll-hint {
  position: absolute; bottom: 22px; left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--muted);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  transition: color 0.25s;
}
.scroll-hint:hover { color: var(--green-bright); }
.scroll-line {
  width: 1px; height: 42px;
  background: linear-gradient(var(--green-bright), transparent);
  animation: drip 1.8s var(--ease-out) infinite;
  transform-origin: top;
}
@keyframes drip { 0% { transform: scaleY(0); } 55% { transform: scaleY(1); } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 30px;
  border-radius: 999px;
  font-weight: 600; font-size: 15px;
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s, background 0.25s, border-color 0.25s;
  will-change: transform;
}
.btn-primary {
  background: var(--green-bright);
  color: var(--ink);
  box-shadow: 0 8px 30px rgba(47, 217, 127, 0.25);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 14px 40px rgba(47,217,127,0.35); }
.btn-ghost {
  border: 1px solid var(--line);
  color: var(--paper);
  font-size: 13.5px;
}
.btn-ghost:hover { border-color: var(--green-bright); transform: translateY(-3px); }
.btn-lg { padding: 17px 36px; }



/* ---------- nav CV language menu ---------- */
.nav-cv { position: relative; display: inline-flex; }
.nav-cv-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 999px;
  background: none; border: none; padding: 0;
  color: var(--muted); cursor: pointer;
  transition: color 0.25s, background 0.25s, transform 0.25s;
}
.nav-cv-btn:hover { color: var(--green-bright); background: rgba(47,217,127,0.08); transform: translateY(-2px); }
.nav-cv-menu {
  position: absolute; top: 44px; right: 0;
  min-width: 190px;
  background: #0d1512;
  border: 1px solid var(--line); border-radius: 14px;
  padding: 6px;
  display: none;
  box-shadow: 0 18px 44px rgba(0,0,0,0.5);
  z-index: 70;
}
.nav-cv.open .nav-cv-menu { display: block; }
.nav-cv-menu a {
  display: flex; justify-content: space-between; align-items: baseline; gap: 14px;
  padding: 10px 12px; border-radius: 9px;
  color: var(--paper); font-size: 13.5px; font-weight: 500;
  transition: background 0.2s, color 0.2s;
}
.nav-cv-menu a span { color: var(--muted); font-size: 10.5px; white-space: nowrap; }
.nav-cv-menu a:hover { background: rgba(47,217,127,0.1); color: var(--green-bright); }
@media (max-width: 760px) { .nav-cv-btn { width: 30px; height: 30px; } }

/* ---------- CV language switch ---------- */
.cv-dl {
  display: inline-flex; align-items: stretch;
  border: 1px solid var(--line); border-radius: 999px;
  overflow: hidden;
  transition: border-color 0.25s;
}
.cv-dl:hover { border-color: var(--green-bright); }
.cv-dl-label {
  display: inline-flex; align-items: center;
  padding: 0 10px 0 26px;
  color: var(--muted); font-size: 13px;
}
.cv-dl a {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 17px 22px;
  color: var(--paper); font-size: 13.5px; font-weight: 600;
  border-left: 1px solid var(--line);
  transition: background 0.25s, color 0.25s;
}
.cv-dl a:hover { background: rgba(47,217,127,0.12); color: var(--green-bright); }
@media (max-width: 480px) {
  .cv-dl a { padding: 14px 18px; }
  .cv-dl-label { padding: 0 8px 0 18px; }
}

/* ---------- marquee ---------- */
.marquee {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--ink-2);
  overflow: hidden;
  padding: 20px 0;
}
.marquee-track {
  display: flex; align-items: center; gap: 34px;
  width: max-content;
  animation: marquee 28s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span {
  font-family: var(--font-mono);
  font-size: 14px; letter-spacing: 0.06em;
  color: var(--muted);
  white-space: nowrap;
  text-transform: uppercase;
}
.marquee-track i { color: var(--green-bright); font-style: normal; font-size: 8px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- sections ---------- */
.section { padding: 110px 5vw; max-width: 1180px; margin: 0 auto; }
.section-title {
  font-size: clamp(34px, 5.5vw, 56px);
  font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 60px;
  display: flex; align-items: baseline; gap: 18px; flex-wrap: wrap;
}
.section-num {
  font-size: 14px; font-weight: 400;
  color: var(--green-bright);
  letter-spacing: 0.08em;
}

/* ---------- work ---------- */
.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 22px;
}
.work-card {
  position: relative;
  display: flex; flex-direction: column;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 30px;
  overflow: hidden;
  transition: transform 0.35s var(--ease-out), border-color 0.35s, box-shadow 0.35s;
}
.work-card::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(47,217,127,0.09), transparent 60%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}
.work-card:hover { transform: translateY(-6px); border-color: rgba(47,217,127,0.4); box-shadow: 0 24px 60px rgba(0,0,0,0.4); }
.work-card:hover::before { opacity: 1; }
.work-top {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 26px;
}
.work-tag {
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--green-bright);
  border: 1px solid rgba(47,217,127,0.35);
  padding: 5px 12px; border-radius: 999px;
}
.work-arrow {
  font-size: 22px; color: var(--green-bright);
  transition: transform 0.3s var(--ease-out);
}
.work-card:hover .work-arrow { transform: translate(4px, -4px); }
.work-card h3 { font-size: 21px; margin-bottom: 12px; letter-spacing: -0.01em; }
.work-card p { color: var(--muted); font-size: 15px; flex: 1; }
.work-tech {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 24px;
}
.work-tech li {
  font-size: 11.5px; color: var(--muted);
  background: rgba(47,217,127,0.07);
  padding: 5px 11px; border-radius: 6px;
}

/* ---------- experience timeline ---------- */
.timeline { position: relative; padding-left: 34px; }
.timeline::before {
  content: "";
  position: absolute; left: 6px; top: 8px; bottom: 8px;
  width: 1px;
  background: linear-gradient(var(--green-bright), var(--line));
}
.tl-item { position: relative; padding-bottom: 52px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot {
  position: absolute; left: -34px; top: 7px;
  width: 13px; height: 13px;
  border-radius: 50%;
  background: var(--ink);
  border: 2px solid var(--green-bright);
  box-shadow: 0 0 14px rgba(47,217,127,0.5);
}
.tl-when { font-size: 12.5px; color: var(--green-bright); letter-spacing: 0.06em; margin-bottom: 8px; }
.tl-item h3 { font-size: 20px; letter-spacing: -0.01em; }
.tl-where { color: var(--paper); font-weight: 500; font-size: 14.5px; margin-bottom: 10px; opacity: 0.85; }
.tl-item p:last-child { color: var(--muted); font-size: 15px; max-width: 640px; }

/* ---------- skills ---------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 22px;
}
.skill-group {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 26px;
  background: var(--ink-2);
  transition: border-color 0.3s, transform 0.3s var(--ease-out);
}
.skill-group:hover { border-color: rgba(47,217,127,0.4); transform: translateY(-4px); }
.skill-group h3 {
  font-size: 12px; font-weight: 500;
  color: var(--green-bright);
  letter-spacing: 0.14em; text-transform: uppercase;
  margin-bottom: 18px;
}
.skill-group h3::before { content: "$ "; color: var(--muted); }
.skill-group ul { list-style: none; }
.skill-group li {
  padding: 7px 0;
  font-size: 15px;
  border-bottom: 1px dashed rgba(143,168,156,0.15);
}
.skill-group li:last-child { border-bottom: 0; }

/* ---------- about ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 60px;
  align-items: center;
}
@media (max-width: 860px) {
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-photo { max-width: 300px; margin: 0 auto; }
}
.about-photo {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: 0 24px 70px rgba(0,0,0,0.5);
  transform: rotate(-2deg);
  transition: transform 0.4s var(--ease-out);
}
.about-photo:hover { transform: rotate(0deg) scale(1.02); }
.about-photo img { display: block; width: 100%; height: auto; }
.about-lede { font-size: 22px; font-weight: 500; letter-spacing: -0.01em; margin-bottom: 18px; }
.about-text p { color: var(--muted); margin-bottom: 16px; }
.about-facts {
  list-style: none;
  margin-top: 28px;
  border-top: 1px solid var(--line);
}
.about-facts li {
  display: flex; gap: 18px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}
.about-facts li span {
  color: var(--green-bright);
  min-width: 92px;
  font-size: 12px;
  letter-spacing: 0.08em; text-transform: uppercase;
  padding-top: 2px;
}

/* ---------- contact ---------- */
.contact { text-align: center; padding-bottom: 140px; }
.contact-eyebrow { color: var(--green-bright); font-size: 13px; letter-spacing: 0.1em; margin-bottom: 24px; }
.contact-title {
  font-size: clamp(40px, 7.5vw, 84px);
  font-weight: 700; letter-spacing: -0.03em; line-height: 1.05;
  margin-bottom: 48px;
}
.accent-outline {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--green-bright);
}
.contact-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ---------- footer ---------- */
.footer {
  border-top: 1px solid var(--line);
  padding: 40px 5vw;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.footer-logo { width: 34px; height: 34px; border-radius: 9px; opacity: 0.85; }
.footer p { font-size: 12px; color: var(--muted); letter-spacing: 0.04em; }

/* ---------- scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media print {
  .reveal { opacity: 1 !important; transform: none !important; }
  .marquee-track { animation: none !important; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .hero-title .word { transform: none; }
}

/* ============================================================
   Projects, Ausbildung and nav additions
   ============================================================ */

/* ---------- nav with six links ---------- */
@media (max-width: 1120px) {
  .nav-links { gap: 18px; }
  .nav-links a { font-size: 13px; }
  .nav-links a .nav-num { display: none; }
}
@media (max-width: 900px) { .nav-links { display: none; } }

/* ---------- hero availability pill ---------- */
.hero-avail {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 12px; letter-spacing: 0.01em;
  color: var(--paper);
  border: 1px solid rgba(47,217,127,0.3);
  background: rgba(47,217,127,0.06);
  border-radius: 999px;
  padding: 8px 16px;
  margin-bottom: 30px;
}
.hero-avail-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--green-bright);
  box-shadow: 0 0 0 0 rgba(47,217,127,0.6);
  animation: pulse 2.4s var(--ease-out) infinite;
  flex: none;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(47,217,127,0.55); }
  70% { box-shadow: 0 0 0 9px rgba(47,217,127,0); }
  100% { box-shadow: 0 0 0 0 rgba(47,217,127,0); }
}
@media (max-width: 560px) {
  .hero-avail { font-size: 11px; padding: 7px 13px; line-height: 1.4; text-align: left; }
}

/* ---------- section lede ---------- */
.section-lede {
  color: var(--muted);
  font-size: 16px;
  max-width: 600px;
  margin: -36px 0 44px;
}
@media (max-width: 760px) { .section-lede { margin-top: -26px; margin-bottom: 32px; } }

/* ---------- projects ---------- */
.proj-feature {
  display: block;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  margin-bottom: 22px;
  transition: border-color 0.35s, box-shadow 0.35s;
}
.proj-feature:hover { border-color: rgba(47,217,127,0.35); box-shadow: 0 26px 70px rgba(0,0,0,0.45); }
.proj-feature-copy { padding: 34px; display: flex; flex-direction: column; }
.proj-top {
  display: flex; justify-content: space-between; align-items: center;
  gap: 12px; margin-bottom: 20px;
}
.proj-year { font-size: 11.5px; color: var(--muted); letter-spacing: 0.12em; }
.proj-feature h3 { font-size: clamp(26px, 3vw, 34px); letter-spacing: -0.02em; margin-bottom: 12px; }
.proj-feature-copy > p { color: var(--muted); font-size: 15px; max-width: 74ch; }
.proj-points { list-style: none; margin: 20px 0 0; display: grid; gap: 10px; max-width: 74ch; }
.proj-points li {
  position: relative; padding-left: 20px;
  font-size: 14.5px; color: var(--muted); line-height: 1.5;
}
.proj-points li::before {
  content: ""; position: absolute; left: 0; top: 0.6em;
  width: 6px; height: 6px; background: var(--green-bright); border-radius: 1px;
}
.proj-shot {
  display: block;
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--line);
  aspect-ratio: 2.2;
  background:
    radial-gradient(120% 90% at 80% 10%, rgba(47,217,127,0.12), transparent 60%),
    var(--ink);
}
.proj-shot img {
  display: block; width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
  transition: transform 0.7s var(--ease-out);
}
.proj-shot:hover img { transform: scale(1.035); }
.proj-links {
  display: flex; align-items: center; gap: 20px;
  margin-top: auto; padding-top: 26px; flex-wrap: wrap;
}
.proj-repo {
  font-size: 12.5px; color: var(--muted);
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
  transition: color 0.25s, border-color 0.25s;
}
.proj-repo:hover { color: var(--green-bright); border-color: var(--green-bright); }
.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 22px;
}
.proj-card {
  display: flex; flex-direction: column;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  transition: transform 0.35s var(--ease-out), border-color 0.35s;
}
.proj-card:hover { transform: translateY(-5px); border-color: rgba(47,217,127,0.4); }
.proj-card h3 { font-size: 20px; letter-spacing: -0.01em; margin-bottom: 10px; }
.proj-card p { color: var(--muted); font-size: 15px; flex: 1; }
.proj-card .proj-links { padding-top: 22px; }
@media (max-width: 860px) {
  .proj-feature-copy { padding: 26px; }
  .proj-shot { aspect-ratio: 1.7; }
}

/* ---------- Ausbildung ---------- */
.de-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 46px;
  align-items: start;
}
.de-copy .de-lede {
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--paper);
  margin-bottom: 20px;
  line-height: 1.35;
}
.de-copy p { color: var(--muted); font-size: 15.5px; margin-bottom: 14px; max-width: 62ch; }
.de-en { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 16px; }
.de-en summary {
  cursor: pointer; color: var(--green-bright);
  font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase;
  list-style: none;
}
.de-en summary::-webkit-details-marker { display: none; }
.de-en summary::before { content: "+ "; }
.de-en[open] summary::before { content: "– "; }
.de-en p { margin-top: 14px; }
.de-facts {
  list-style: none;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 8px 24px;
}
.de-facts li {
  display: flex; gap: 16px; align-items: baseline;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.de-facts li:last-child { border-bottom: 0; }
.de-facts span {
  font-family: var(--font-mono);
  color: var(--green-bright);
  font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase;
  min-width: 84px; flex: none;
}
.de-facts strong { font-weight: 500; color: var(--paper); line-height: 1.45; }
@media (max-width: 900px) {
  .de-grid { grid-template-columns: 1fr; gap: 30px; }
  .de-facts { padding: 4px 20px; }
  .de-facts li { flex-direction: column; gap: 4px; }
  .de-facts span { min-width: 0; }
}

/* ============================================================
   Language switcher + Arabic RTL
   ============================================================ */

.nav-lang { position: relative; display: inline-flex; }
.nav-lang-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 34px; min-width: 46px; padding: 0 11px;
  background: none; border: 1px solid var(--line); border-radius: 999px;
  color: var(--paper); font-size: 11.5px; letter-spacing: 0.06em; cursor: pointer;
  transition: border-color 0.25s, color 0.25s, background 0.25s;
}
.nav-lang-btn::after {
  content: ""; width: 0; height: 0;
  border-left: 3.5px solid transparent; border-right: 3.5px solid transparent;
  border-top: 4px solid currentColor; opacity: 0.6;
}
.nav-lang-btn:hover { border-color: var(--green-bright); color: var(--green-bright); }
.nav-lang-menu {
  position: absolute; top: 44px; right: 0;
  min-width: 152px;
  background: #0d1512;
  border: 1px solid var(--line); border-radius: 14px;
  padding: 6px;
  display: none;
  box-shadow: 0 18px 44px rgba(0,0,0,0.5);
  z-index: 70;
}
.nav-lang.open .nav-lang-menu { display: block; }
.nav-lang-menu button {
  display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 12px; border: 0; border-radius: 9px; background: none;
  color: var(--paper); font: inherit; font-size: 13.5px; font-weight: 500;
  text-align: start; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.nav-lang-menu button:hover { background: rgba(47,217,127,0.1); color: var(--green-bright); }
.nav-lang-menu button[aria-current="true"] { color: var(--green-bright); }
.nav-lang-menu button[aria-current="true"]::after { content: "\2713"; font-size: 11px; }
@media (max-width: 760px) {
  .nav-lang-btn { height: 30px; min-width: 40px; padding: 0 9px; font-size: 11px; }
  .nav-lang-menu { top: 38px; }
}

/* ---------- Arabic ---------- */
html[dir="rtl"] body { font-family: "IBM Plex Sans Arabic", system-ui, sans-serif; }
html[dir="rtl"] .mono,
html[dir="rtl"] .hero-eyebrow,
html[dir="rtl"] .section-num,
html[dir="rtl"] .nav-num {
  font-family: "IBM Plex Sans Arabic", ui-monospace, monospace;
  letter-spacing: 0;
}
html[dir="rtl"] .hero-title { letter-spacing: 0; }
html[dir="rtl"] .section-title { letter-spacing: 0; line-height: 1.25; }
html[dir="rtl"] .contact-title { line-height: 1.4; }
html[dir="rtl"] .nav-lang-menu, html[dir="rtl"] .nav-cv-menu { right: auto; left: 0; }
html[dir="rtl"] .timeline { padding-left: 0; padding-right: 34px; }
html[dir="rtl"] .timeline::before { left: auto; right: 6px; }
html[dir="rtl"] .tl-dot { left: auto; right: -34px; }
html[dir="rtl"] .proj-points li { padding-left: 0; padding-right: 20px; }
html[dir="rtl"] .proj-points li::before { left: auto; right: 0; }
html[dir="rtl"] .cv-dl-label { padding: 0 26px 0 10px; }
html[dir="rtl"] .cv-dl a { border-left: 0; border-right: 1px solid var(--line); }
html[dir="rtl"] .marquee-track { direction: ltr; }
html[dir="rtl"] .work-arrow { transform: scaleX(-1); }
html[dir="rtl"] .work-card:hover .work-arrow { transform: scaleX(-1) translate(4px, -4px); }
html[dir="rtl"] .proj-repo span { display: inline-block; transform: scaleX(-1); }
html[dir="rtl"] .hero-typed .prompt { margin-right: 0; margin-left: 10px; }
html[dir="rtl"] .about-lede, html[dir="rtl"] .de-copy .de-lede { line-height: 1.6; }
html[dir="rtl"] .skill-group h3::before { content: ""; }
html[dir="rtl"] .skill-group h3::after { content: " $"; color: var(--muted); }
html[dir="rtl"] .contact-alt, html[dir="rtl"] .footer p { letter-spacing: 0; }

html[dir="rtl"] .hero-sub a, html[dir="rtl"] .proj-repo { white-space: nowrap; }

/* ============================================================
   Projects carousel
   ============================================================ */
.proj-carousel { margin-top: 4px; }
.proj-rail {
  display: flex; align-items: flex-start; gap: 22px;
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: none; scroll-behavior: auto;
  scroll-padding-inline: 5vw;
  scrollbar-width: none; -ms-overflow-style: none;
  padding: 4px 5vw 8px; margin: 0 -5vw;
  cursor: grab;
}
.proj-rail::-webkit-scrollbar { display: none; }
.proj-rail.is-dragging { cursor: grabbing; scroll-snap-type: none; scroll-behavior: auto; }
.proj-rail:focus-visible { outline: 2px solid rgba(47,217,127,0.5); outline-offset: 6px; border-radius: 20px; }
.proj-slide {
  flex: 0 0 min(560px, calc((100% - 22px) / 2)); min-height: 440px;
  display: flex; flex-direction: column;
  background: linear-gradient(180deg, rgba(18,32,25,0.92), rgba(10,18,14,0.92));
  border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
  transition: border-color 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
.proj-slide:hover { border-color: rgba(47,217,127,0.32); box-shadow: 0 24px 60px rgba(0,0,0,0.4); }
.proj-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #08130e; border-bottom: 1px solid var(--line); }
.proj-media img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform 0.55s var(--ease-out); }
.proj-media:hover img { transform: scale(1.03); }
.proj-body { padding: 26px 28px 28px; display: flex; flex-direction: column; flex: 1; }
.proj-slide h3 { font-size: clamp(22px, 2.4vw, 28px); letter-spacing: -0.02em; margin-bottom: 10px; }
.proj-slide p { color: var(--muted); font-size: 15px; }
.proj-slide .proj-points { margin-top: 16px; }
.proj-slide .work-tech { margin-top: 16px; }
.proj-slide .proj-links { margin-top: auto; padding-top: 24px; }
.proj-carousel.is-static .proj-ctrl { display: none; }
.proj-ctrl { display: flex; align-items: center; gap: 14px; margin-top: 22px; }
.proj-arrow {
  width: 42px; height: 42px; display: grid; place-items: center; padding: 0;
  border-radius: 50%; border: 1px solid var(--line); background: transparent;
  color: var(--text); cursor: pointer;
  transition: border-color 0.25s, color 0.25s, background 0.25s;
}
.proj-arrow:hover:not(:disabled) { border-color: rgba(47,217,127,0.5); color: var(--green-bright); background: rgba(47,217,127,0.07); }
.proj-arrow:disabled { opacity: 0.3; cursor: default; }
.proj-count { font-size: 12.5px; letter-spacing: 0.12em; color: var(--muted); display: flex; gap: 7px; }
.proj-count-sep { opacity: 0.5; }
html[dir="rtl"] .proj-arrow svg { transform: scaleX(-1); }
@media (max-width: 720px) {
  .proj-slide { flex-basis: 84vw; min-height: 360px; }
  .proj-body { padding: 22px; }
  .proj-rail { gap: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .proj-rail { scroll-behavior: auto; }
}

/* ============================================================
   Projects: 3D cylinder carousel
   ============================================================ */
.cyl { --cw: 460px; --ch: 259px; margin-top: 8px; }
.cyl-stage { direction: ltr; perspective: 1700px; height: calc(var(--ch) + 56px); display: flex; align-items: center; justify-content: center; overflow: hidden; cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.cyl-stage.is-dragging { cursor: grabbing; }
.cyl-ring { position: relative; width: var(--cw); height: var(--ch); transform-style: preserve-3d; will-change: transform; }
.cyl-face { position: absolute; inset: 0; display: block; width: var(--cw); height: var(--ch); border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: #08130e; box-shadow: 0 24px 60px rgba(0,0,0,0.45); backface-visibility: hidden; -webkit-backface-visibility: hidden; transition: filter .3s; }
.cyl-face img { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; pointer-events: none; -webkit-user-drag: none; }
.cyl-face .pface-name { position: absolute; left: 14px; bottom: 12px; padding: 5px 11px; font-size: 12px; letter-spacing: 0.08em; color: var(--green-bright); background: rgba(6,16,11,0.78); border: 1px solid rgba(47,217,127,0.35); border-radius: 999px; backdrop-filter: blur(6px); }
.cyl:not(.is-ready) .cyl-ring { display: flex; flex-wrap: wrap; gap: 16px; width: auto; height: auto; }
.cyl:not(.is-ready) .cyl-face { position: relative; width: 100%; max-width: var(--cw); height: auto; aspect-ratio: 16 / 9; }
.cyl-ctrl { justify-content: center; }
.pdetail { margin-top: 26px; }
.pdetail .proj-slide { display: none; flex: none; min-height: 0; max-width: 860px; margin: 0 auto; }
.pdetail .proj-slide.is-on { display: flex; animation: pdIn .5s var(--ease-out); }
@keyframes pdIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.pdetail .proj-body { padding: 28px 30px 30px; }
.cyl:not(.is-ready) + .pdetail .proj-slide { display: flex; margin-bottom: 18px; }
@media (max-width: 720px) { .cyl { --cw: 290px; --ch: 163px; } .pdetail .proj-body { padding: 22px; } }
@media (prefers-reduced-motion: reduce) { .pdetail .proj-slide.is-on { animation: none; } }

/* ============================================================
   Agentic build intro: named agent cursors build the first screen
   ============================================================ */
html.agent-on { overflow: hidden; }
.ag-pre { visibility: hidden !important; }
html.agent-on .hero .reveal { opacity: 1; transform: none; transition: none; }
html.agent-on .hero-title .line, html.agent-done .hero-title .line { overflow: visible; }
html.agent-on .hero-title .word, html.agent-done .hero-title .word { animation: none; transform: none; }
html.agent-on .nav { transition: none; }
.agent-ui { position: fixed; inset: 0; z-index: 9999; pointer-events: none; transition: opacity .5s ease; }
.agent-ui.is-out { opacity: 0; }
.ag-cur { position: fixed; left: 0; top: 0; z-index: 3; will-change: transform; filter: drop-shadow(0 4px 10px rgba(0,0,0,.5)); }
.ag-cur span { position: absolute; left: 14px; top: 20px; white-space: nowrap; padding: 3px 9px; border-radius: 999px; background: var(--c); color: #06100b; font: 600 11px/1.3 "JetBrains Mono", monospace; letter-spacing: .02em; }
.ag-box { position: fixed; z-index: 2; border: 1.5px solid var(--c); background: color-mix(in srgb, var(--c) 7%, transparent); box-sizing: border-box; }
.ag-box i { position: absolute; width: 8px; height: 8px; background: #06100b; border: 1.5px solid var(--c); box-sizing: border-box; margin: -4px 0 0 -4px; }
.ag-box .n { left: 50%; top: 0; } .ag-box .ne { left: 100%; top: 0; } .ag-box .e { left: 100%; top: 50%; } .ag-box .se { left: 100%; top: 100%; }
.ag-box .s { left: 50%; top: 100%; } .ag-box .sw { left: 0; top: 100%; } .ag-box .w { left: 0; top: 50%; } .ag-box .nw { left: 0; top: 0; }
.ag-size { position: absolute; left: 50%; top: calc(100% + 10px); transform: translateX(-50%); white-space: nowrap; padding: 2px 8px; border-radius: 5px; background: var(--c); color: #06100b; font-size: 10.5px; font-weight: 600; }
.ag-marq { position: fixed; z-index: 1; border: 1.5px dashed var(--c); background: color-mix(in srgb, var(--c) 6%, transparent); box-sizing: border-box; }
.ag-hud { position: fixed; left: 16px; bottom: 16px; width: min(340px, calc(100vw - 32px)); font-size: 11.5px; color: #9bb8a8; direction: ltr; text-align: left; }
.ag-log { display: flex; flex-direction: column; gap: 3px; margin-bottom: 8px; text-shadow: 0 1px 6px #000; }
.ag-log b { font-weight: 600; }
.ag-row { display: flex; align-items: center; gap: 9px; padding: 8px 10px 8px 12px; border: 1px solid rgba(47,217,127,.3); border-radius: 999px; background: rgba(6,16,11,.85); backdrop-filter: blur(8px); pointer-events: auto; }
.ag-row span:nth-child(2) { flex: 1; }
.ag-dot { width: 7px; height: 7px; border-radius: 50%; background: #2fd97f; box-shadow: 0 0 10px #2fd97f; animation: agp 1s ease-in-out infinite; }
@keyframes agp { 50% { opacity: .35; } }
.ag-row button { background: none; border: 1px solid var(--line); color: var(--muted); border-radius: 999px; font: inherit; padding: 3px 10px; cursor: pointer; }
.ag-row button:hover { color: var(--green-bright); border-color: var(--green-bright); }
