/* ==========================================================================
   Design tokens
   ========================================================================== */
:root {
  --bg: #0a0a0b;
  --text: #f2f2f0;
  --muted: #9a9a94;
  --accent-art: #ff7a4d;
  --accent-tech: #4dc3ff;
  --font: system-ui, -apple-system, "Segoe UI", sans-serif;
  --space: 8px;
  --max-width: 1100px;
  --radius: 12px;
  --nav-height: 64px;
}

/* ==========================================================================
   Reset / base
   ========================================================================== */
* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.5;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 2px;
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 calc(var(--space) * 3);
}

/* ==========================================================================
   Top nav (shared markup across all pages)
   ========================================================================== */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  height: var(--nav-height);
  background: rgba(10, 10, 11, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.site-nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.site-nav .wordmark {
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
  font-size: 1.1rem;
}

.site-nav .nav-links {
  display: flex;
  gap: calc(var(--space) * 3);
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav .nav-links a {
  color: var(--muted);
  text-decoration: none;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}

.site-nav .nav-links a:hover {
  color: var(--text);
}

.site-nav .nav-links a.current {
  color: var(--text);
  border-bottom-color: var(--accent-art);
}

/* Per-page override: tech.html uses the cool accent for the nav underline */
body.tech .site-nav .nav-links a.current {
  border-bottom-color: var(--accent-tech);
}

/* ==========================================================================
   Hero (full-bleed, overlaid name)
   ========================================================================== */
.hero {
  position: relative;
  min-height: calc(100svh - var(--nav-height));
  background-image: url("assets/hero.jpg");
  background-size: cover;
  background-position: center 38%; /* keep the face in frame on wide viewports */
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 55%, var(--bg) 100%);
  pointer-events: none;
}

.hero-name {
  position: absolute;
  top: 55%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  text-align: center;
  z-index: 1;
}

.hero-name h1 {
  margin: 0;
  font-size: clamp(3.5rem, 14vw, 10rem);
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #fff;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.55);
}

.hero-name .tagline {
  display: block;
  margin-top: calc(var(--space) * 2);
  font-size: 0.9rem;
  font-variant: small-caps;
  letter-spacing: 0.25em;
  color: var(--muted);
}

/* ==========================================================================
   Duality CTAs
   ========================================================================== */
.duality {
  position: relative;
  z-index: 2;
  display: flex;
  gap: calc(var(--space) * 4);
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 calc(var(--space) * 3) calc(var(--space) * 6);
}

.duality-link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: calc(var(--space) * 1.5);
  padding: calc(var(--space) * 3);
  text-decoration: none;
  font-weight: 700;
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  letter-spacing: -0.02em;
  transition: transform 0.2s ease;
}

.duality-link .arrow {
  display: inline-block;
  transition: transform 0.2s ease;
}

.duality-link:hover,
.duality-link:focus-visible {
  transform: scale(1.04);
}

.duality-link.art {
  color: var(--accent-art);
}

.duality-link.art:hover .arrow,
.duality-link.art:focus-visible .arrow {
  transform: translateX(-6px);
}

.duality-link.tech {
  color: var(--accent-tech);
}

.duality-link.tech:hover .arrow,
.duality-link.tech:focus-visible .arrow {
  transform: translateX(6px);
}

/* ==========================================================================
   Page title treatment (for art.html / tech.html)
   ========================================================================== */
.page-title {
  padding: calc(var(--space) * 6) calc(var(--space) * 3) calc(var(--space) * 4);
  max-width: var(--max-width);
  margin: 0 auto;
}

.page-title h1 {
  font-weight: 700;
  letter-spacing: -0.02em;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  display: inline-block;
  margin: 0 0 calc(var(--space) * 1.5);
  padding-bottom: var(--space);
  border-bottom: 3px solid var(--accent-art);
}

.page-title.tech h1 {
  border-bottom-color: var(--accent-tech);
}

.page-title p {
  color: var(--muted);
  margin: 0;
}

.page-title .eyebrow {
  display: block;
  text-transform: uppercase;
  color: var(--muted);
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  margin-bottom: calc(var(--space) * 2);
}

/* ==========================================================================
   Gallery (art.html)
   ========================================================================== */
.gallery {
  columns: 1;
  column-gap: 12px;
  padding-top: calc(var(--space) * 2);
  padding-bottom: calc(var(--space) * 10);
}

.gallery a {
  display: block;
  break-inside: avoid;
  margin: 0 0 12px;
}

.gallery img {
  width: 100%;
  display: block;
  border-radius: var(--radius);
  transition: transform 0.2s ease;
}

.gallery a:hover img,
.gallery a:focus-visible img {
  transform: translateY(-4px);
}

@media (min-width: 700px) {
  .gallery {
    columns: 2;
  }
}

@media (min-width: 1024px) {
  .gallery {
    columns: 3;
  }
}

/* ==========================================================================
   Projects & Skills (tech.html)
   ========================================================================== */
.projects,
.skills {
  padding-top: calc(var(--space) * 3);
  padding-bottom: calc(var(--space) * 5);
}

.projects h2,
.skills h2 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 calc(var(--space) * 3);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
}

.project-card {
  background: #141416;
  border-radius: var(--radius);
  padding: calc(var(--space) * 3);
  transition: transform 0.2s ease;
}

.project-card:hover,
.project-card:focus-within {
  transform: translateY(-4px);
}

.project-card h3 {
  margin: 0 0 var(--space);
  font-size: 1.1rem;
  font-weight: 700;
}

.project-card p {
  color: var(--muted);
  margin: 0 0 calc(var(--space) * 2);
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space);
  margin-bottom: calc(var(--space) * 2);
}

.tech-tags span {
  font-size: 0.75rem;
  color: var(--muted);
  border: 1px solid var(--muted);
  border-radius: 999px;
  padding: 2px 10px;
}

.project-link {
  color: var(--accent-tech);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
}

.project-link:hover,
.project-link:focus-visible {
  text-decoration: underline;
}

.skill-pills {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--space) * 1.5);
}

.skill-pill {
  font-size: 0.85rem;
  color: var(--muted);
  border: 1px solid var(--muted);
  border-radius: 999px;
  padding: calc(var(--space) * 0.75) calc(var(--space) * 2);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 700px) {
  .duality {
    flex-direction: column;
    gap: calc(var(--space) * 2);
  }
}
