:root {
  --navy: #141B24;
  --navy-glass: rgba(20, 27, 36, 0.9);
  --card: #1C2531;
  --card-deep: #0F141B;
  --line: #2A3442;
  --line-strong: #3A4656;
  --text: #F5F3EE;
  --text-soft: #D5DAE0;
  --text-muted: #B8C0CA;
  --text-faint: #8A94A0;
  --amber: #E0A040;
  --radius: 14px;
  --radius-sm: 10px;
  --gutter: 48px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--navy);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
ul { list-style: none; }
.i { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; display: block; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--amber); color: var(--navy); padding: 8px 14px; border-radius: 6px; z-index: 10; font-weight: 600; }
.skip:focus { left: 12px; }

.bar { display: inline-block; width: 52px; height: 4px; background: var(--amber); border-radius: 2px; vertical-align: middle; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: max(100vh, 780px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 48px 40px;
  background:
    linear-gradient(rgba(14, 19, 26, 0.18), rgba(14, 19, 26, 0.18)),
    url("assets/ccny.jpg") center 30% / cover no-repeat;
}
.nav {
  position: absolute; top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: center;
  padding: 28px var(--gutter);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.6);
}
.brand { font-size: 19px; font-weight: 600; }
.nav-links { display: flex; gap: 40px; font-size: 16px; color: #E3E7EC; }
.nav-links a:hover, .brand:hover { color: var(--amber); }

.banner {
  background: var(--navy-glass);
  border-radius: var(--radius);
  padding: 40px 48px 42px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 48px;
  scroll-margin-top: 24px;
}

.who { display: flex; align-items: center; gap: 28px; margin-bottom: 26px; }
.avatar {
  width: 104px; height: 104px; border-radius: 50%; flex: none; overflow: hidden;
  background: #2A3442; display: flex; align-items: center; justify-content: center;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar .initials { display: none; font-size: 32px; font-weight: 600; color: var(--amber); letter-spacing: 1px; }
.avatar.no-photo .initials { display: block; }
.name { font-size: 54px; line-height: 1.05; font-weight: 600; letter-spacing: -0.5px; margin-bottom: 14px; }
.bio-lead { font-size: 22px; line-height: 1.5; color: var(--text-soft); margin-bottom: 10px; }
.bio { font-size: 20px; line-height: 1.55; color: var(--text-muted); margin-bottom: 30px; }

.actions { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; }
.btn {
  background: var(--amber); color: var(--navy); font-size: 17px; font-weight: 600;
  padding: 14px 32px; border-radius: 8px; transition: filter 0.15s ease;
}
.btn:hover { filter: brightness(1.08); }
.socials { display: flex; gap: 24px; font-size: 26px; color: var(--text); }
.socials a:hover { color: var(--amber); }

/* ---------- Projects carousel ---------- */
.projects { border-left: 1px solid var(--line); padding-left: 44px; display: flex; flex-direction: column; min-width: 0; scroll-margin-top: 24px; }
.projects-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.section-title { display: flex; align-items: center; gap: 18px; font-size: 38px; font-weight: 600; margin-bottom: 30px; }
.section-title.small { font-size: 24px; gap: 14px; margin-bottom: 0; }
.section-title.small .bar { width: 32px; }
.arrows { display: flex; gap: 12px; }
.arrow {
  width: 42px; height: 42px; border-radius: 50%; background: transparent; cursor: pointer;
  border: 1.5px solid var(--line-strong); color: var(--text-muted);
  display: flex; align-items: center; justify-content: center; font-size: 18px;
  transition: border-color 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}
.arrow:not(:disabled):hover { border-color: var(--amber); color: var(--amber); }
.arrow:disabled { opacity: 0.35; cursor: default; }
.projects.single .arrows, .projects.single .dots { visibility: hidden; }

.track {
  display: flex; gap: 16px; flex: 1;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  scrollbar-width: none; border-radius: var(--radius-sm);
}
.track::-webkit-scrollbar { display: none; }
.card {
  flex: 0 0 100%; scroll-snap-align: start;
  background: var(--card); border-radius: var(--radius-sm); overflow: hidden;
  display: grid; grid-template-columns: 46% minmax(0, 1fr);
}
.shot { background: var(--card-deep); min-height: 200px; position: relative; }
.shot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.shot-ph {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  color: var(--amber); font-size: 44px;
}
.shot-ph span { font-size: 13px; color: #6B7684; }
.card-body { padding: 22px 24px; display: flex; flex-direction: column; justify-content: center; }
.card-title { font-size: 22px; font-weight: 600; margin-bottom: 6px; }
.card-desc { font-size: 15px; line-height: 1.55; color: var(--text-muted); margin-bottom: 10px; }
.card-tech { font-size: 13px; color: var(--text-faint); margin-bottom: 14px; }
.card-links { display: flex; gap: 18px; flex-wrap: wrap; }
.card-links a { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 500; color: var(--text-soft); }
.card-links a:first-child { color: var(--amber); }
.card-links a:hover { text-decoration: underline; text-underline-offset: 3px; }
.card-links .i { font-size: 16px; }

.dots { display: flex; gap: 8px; margin-top: 16px; min-height: 8px; }
.dots span { width: 8px; height: 8px; border-radius: 4px; background: var(--line-strong); transition: width 0.2s ease, background 0.2s ease; }
.dots span.on { width: 22px; background: var(--amber); }

/* ---------- Sections below ---------- */
.section { padding: 64px 48px 8px; scroll-margin-top: 16px; }
.section:last-of-type { padding-bottom: 72px; }
.entry { background: var(--card); border-radius: var(--radius); padding: 30px 34px; }
.entry.has-logo { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 26px; align-items: start; }
.logo {
  width: 72px; height: 72px; border-radius: 14px; overflow: hidden; flex: none;
  background: #FFFFFF; display: flex; align-items: center; justify-content: center; padding: 8px;
}
.logo img { width: 100%; height: 100%; object-fit: contain; }
.logo.full { padding: 0; background: #272727; }
.logo.full img { object-fit: cover; flex: none; width: 108%; height: 108%; max-width: none; }
.logo.bare { padding: 0; background: transparent; }
.logo .logo-initials { display: none; color: var(--amber); font-weight: 600; font-size: 22px; }
.logo .logo-initials.long { font-size: 16px; }
.logo.no-logo { background: var(--navy); border: 1px solid var(--line-strong); padding: 0; }
.logo.no-logo .logo-initials { display: block; }
.entry-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 16px; }
.entry h3 { font-size: 23px; font-weight: 600; }
.org { color: var(--amber); font-size: 17px; font-weight: 500; }
.dot-sep { color: var(--text-faint); margin: 0 6px; }
.when { color: var(--text-faint); font-size: 16px; white-space: nowrap; padding-top: 4px; }
.points { margin-bottom: 20px; }
.points li { position: relative; padding-left: 22px; color: var(--text-muted); margin-bottom: 8px; }
.points li::before { content: ""; position: absolute; left: 2px; top: 0.56em; width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid var(--amber); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { background: var(--navy); border: 1px solid var(--line); color: var(--text-soft); font-size: 14px; padding: 5px 12px; border-radius: 6px; }
.tags.big li { font-size: 16px; padding: 8px 16px; background: var(--card); }

.footer {
  border-top: 1px solid var(--line); padding: 28px var(--gutter);
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  color: var(--text-faint); font-size: 15px;
}
.footer .socials { font-size: 20px; color: var(--text-muted); }

/* ---------- Medium screens ---------- */
@media (max-width: 1100px) {
  :root { --gutter: 24px; }
  .hero { padding: 0 24px 24px; }
  .section { padding-left: 24px; padding-right: 24px; }
  .banner { grid-template-columns: 1fr; gap: 32px; padding: 32px 32px 34px; }
  .projects { border-left: none; padding-left: 0; border-top: 1px solid var(--line); padding-top: 28px; }
  .name { font-size: 46px; }
}

/* ---------- Phones ---------- */
@media (max-width: 640px) {
  :root { --gutter: 20px; }
  body { font-size: 16px; }
  .hero {
    min-height: 0; padding: 38vh 12px 12px;
    background:
      linear-gradient(to bottom, rgba(20, 27, 36, 0) 0, rgba(20, 27, 36, 0.15) 30vh, var(--navy) 60vh) 0 0 / 100% 100% no-repeat,
      url("assets/ccny.jpg") center top / auto 62vh no-repeat,
      var(--navy);
  }
  .nav { padding: 18px 20px; }
  .nav-links { gap: 18px; font-size: 14px; }
  .brand { font-size: 16px; }
  .banner { padding: 24px 20px 26px; border-radius: 12px; }
  .who { gap: 16px; margin-bottom: 18px; }
  .avatar { width: 72px; height: 72px; }
  .avatar .initials { font-size: 24px; }
  .name { font-size: 34px; margin-bottom: 10px; }
  .bar { width: 40px; }
  .bio-lead { font-size: 18px; }
  .bio { font-size: 16px; margin-bottom: 22px; }
  .actions { gap: 22px; }
  .btn { font-size: 16px; padding: 12px 26px; }
  .socials { font-size: 24px; gap: 22px; }
  .card { grid-template-columns: 1fr; }
  .shot { min-height: 0; aspect-ratio: 16 / 9; }
  .section { padding: 48px 12px 8px; }
  .section:last-of-type { padding-bottom: 56px; }
  .section-title { font-size: 30px; margin-bottom: 22px; }
  .entry { padding: 22px 20px; }
  .entry.has-logo { display: block; }
  .logo { width: 52px; height: 52px; border-radius: 12px; padding: 6px; margin-bottom: 14px; }
  .logo .logo-initials { font-size: 18px; }
  .logo .logo-initials.long { font-size: 13px; }
  .entry-head { flex-direction: column; gap: 4px; }
  .when { padding-top: 0; }
  .footer { flex-direction: column; align-items: flex-start; padding: 24px 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html, .track { scroll-behavior: auto; }
  .dots span, .arrow, .btn { transition: none; }
}
