/* ── DESIGN TOKENS ── */
:root {
  --color-bg:    #ffffff;
  --color-navy:  #042956;   /* Aclonica text + dot icons ONLY */
  --color-text:  #000000;   /* all other text */
  --font-display: 'Aclonica', sans-serif;   /* MAIT wordmark only */
  --font-sans:    'Helvetica Neue', Helvetica, Arial, sans-serif; /* everything else */
  --nav-height:   56px;
  --ease-main:    cubic-bezier(0.44, 0, 0.56, 1);
  --ease-drop:    cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  overflow-x: clip;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ── NAVIGATION ── */
.nav {
  position: fixed;
  top: 16px; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  background: transparent;
  opacity: 0;
  animation: fadeSlideDown 0.6s var(--ease-drop) 0.1s forwards;
}

.nav-brand {
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--color-navy);
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--color-text);
  position: relative;
  display: inline-flex;
  align-items: center;        /* keep letters on same horizontal line */
}

/* underline: 2px below the text */
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  height: 2px;
  width: 100%;
  background: var(--color-navy);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.35s var(--ease-drop);
}
.nav-links a:hover { color: var(--color-navy); }
.nav-links a:hover::after { transform: scaleX(1); }

/* ── letter roll ── */
.nl-wrap {
  display: inline-block;
  overflow: hidden;
  line-height: 1.2;
  vertical-align: middle;     /* align with nav-brand baseline */
}

/* top letter (original) slides up on hover */
.nl-top {
  display: block;
  transition: transform 0.4s var(--ease-drop);
  transition-delay: var(--d, 0ms);
}

/* bottom letter (clone) starts below, rolls up on hover */
.nl-bot {
  display: block;
  transform: translateY(0);
  transition: transform 0.4s var(--ease-drop);
  transition-delay: var(--d, 0ms);
  color: var(--color-navy);
}

/* before hover: bot sits just below top */
.nl-bot { transform: translateY(100%); }

.nav-links a:hover .nl-top { transform: translateY(-100%); }
.nav-links a:hover .nl-bot  { transform: translateY(-100%); }

/* ── HERO ── */
.hero {
  position: relative;
  height: 100vh;
  padding-top: var(--nav-height);
  padding-bottom: 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
}

.hero-mait-wrapper {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

/* UX / UI Designer tag */
.hero-tag {
  align-self: flex-end;
  padding-right: 40px;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0;
  animation: fadeSlideUp 0.8s var(--ease-drop) 0.5s forwards;
}

.hero-tag__dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-navy); /* icon — stays navy */
  flex-shrink: 0;
}

.hero-tag__label {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--color-text);
}

/* MAIT wordmark — Aclonica + navy, the only exception */
.hero-mait {
  width: 100%;
  padding: 0 24px;
  line-height: 1;
  font-family: var(--font-display);
  font-size: 480px;
  color: var(--color-navy);
  white-space: nowrap;
  display: flex;
  overflow: hidden;
}

.mait-ma {
  display: inline-block;
  opacity: 0;
  transform: translateX(-60px);
  animation: slideInLeft 1.7s var(--ease-main) 0.2s forwards;
}

.mait-it {
  display: inline-block;
  opacity: 0;
  transform: translateX(60px);
  animation: slideInRight 1.7s var(--ease-main) 0.4s forwards;
}

/* Bottom bar */
.hero-bottom {
  width: 100%;
  padding: 0 24px;
  margin-top: -40px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  opacity: 0;
  animation: fadeSlideUp 0.8s var(--ease-drop) 1.0s forwards;
}

.hero-clock,
.hero-location {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}

/* ── KEYFRAMES ── */
@keyframes fadeSlideDown {
  from { opacity: 0; transform: translateY(-16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(-60px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes slideInRight {
  from { opacity: 0; transform: translateX(60px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* spacer sits after the sticky projects section in normal flow.
   Its height = how far you scroll through the animation before About appears. */
.projects-spacer {
  height: 280vh;
  background: #fff;
}

/* ── PROJECTS SECTION ── */
.projects {
  position: sticky;
  top: 0;
  z-index: 1;
  height: 100vh;
  background: #fff;
  overflow: hidden;
}

/* full-size scene fills the sticky viewport */
.projects-scene {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* ── "MAKE IT REAL" ── */
.projects-headline {
  position: absolute;
  z-index: 1;
  text-align: center;
  pointer-events: none;
  /* opacity + transform driven by scroll JS */
  opacity: 0;
  transform: translateY(16px);
  will-change: opacity, transform;
}

.projects-title {
  font-family: var(--font-sans);
  font-size: 48px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--color-text);
}

/* ── CARD STACK (all cards share same absolute position) ── */
.projects-stack {
  position: relative;
  z-index: 2;
  width: 290px;
  height: 305px;
}

.project-card {
  position: absolute;
  inset: 0;
  width: 290px;
  height: 305px;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  z-index: var(--zi);
  will-change: transform, opacity;
}

/* Only when fully spread — CSS takes over for smooth hover */
.project-card.is-fully-spread {
  transition: transform 0.45s var(--ease-drop);
}

.project-card.is-fully-spread:hover {
  transform: translateX(var(--final-sx)) translateY(-12px) rotate(0deg) scale(1.03) !important;
  z-index: 10;
}

.project-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.project-card__overlay {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 24px 16px 16px;
  background: linear-gradient(to top, rgba(0,0,0,0.65) 0%, transparent 100%);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.project-card__name {
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  color: #fff;
}

.project-card__num {
  font-family: var(--font-sans);
  font-size: 12px;
  color: rgba(255,255,255,0.55);
}

/* ── ABOUT SECTION (slides over projects via z-index, not sticky) ── */
.about {
  position: relative;
  z-index: 2;
  background: #ebebeb;
  border-radius: 24px 24px 0 0;
  box-shadow: 0 -12px 48px rgba(0, 0, 0, 0.10);
  padding: 56px 40px 80px;
  min-height: 100vh;
}

.about-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 48px;
}

.section-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--color-text);
}

.section-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-navy); /* icon — stays navy */
  flex-shrink: 0;
}

.btn-cv {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--color-text);
  border: 1.5px solid var(--color-text);
  border-radius: 100px;
  padding: 10px 24px;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.btn-cv:hover {
  background: var(--color-text);
  color: #fff;
}

.about-bio {
  max-width: 400px;
  margin-bottom: 64px;
}
.about-bio p {
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.7;
  color: var(--color-text);
}

.about-statement {
  margin-bottom: 80px;
}
.about-statement p {
  font-family: var(--font-sans);
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  color: var(--color-text);
  max-width: 900px;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.process-card {
  background: #fff;
  border-radius: 16px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 220px;
}

.process-num {
  font-family: var(--font-sans);
  font-size: 13px;
  color: #888;
}

.process-title {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text);
}

.process-desc {
  font-family: var(--font-sans);
  font-size: 13px;
  line-height: 1.6;
  color: #555;
  margin-top: auto;
}

/* ── FOOTER ── */
.footer {
  position: relative;
  z-index: 3;
  background: #fff;
  border-radius: 0;
  box-shadow: 0 -12px 48px rgba(0, 0, 0, 0.08);
  min-height: 100vh;
  padding: 56px 40px 48px;
  display: flex;
  flex-direction: column;
}

.footer-top {
  margin-top: auto;  /* pushes label + headline + links to the bottom */
  margin-bottom: 8px;
}

.footer-headline {
  font-family: var(--font-display);
  font-size: clamp(80px, 12vw, 180px);
  line-height: 1;
  color: var(--color-navy);
  letter-spacing: -0.01em;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-top: 1px solid #e0e0e0;
  padding-top: 24px;
}

.footer-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer-left a,
.footer-left span {
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--color-text);
}
.footer-left a:hover { opacity: 0.5; }

.footer-right {
  display: flex;
  gap: 32px;
}

.footer-right a {
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--color-text);
  transition: opacity 0.2s;
}
.footer-right a:hover { opacity: 0.4; }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .nav { padding: 0 20px; }
  .hero-mait { padding: 0 12px; font-size: 140px; }

  .projects { padding: 80px 20px 60px; }
  .projects-grid { gap: 10px; flex-wrap: wrap; }
  .project-card { max-width: 45%; }

  .about { padding: 40px 20px 60px; border-radius: 16px 16px 0 0; }
  .process-grid { grid-template-columns: 1fr 1fr; }

  .footer { padding: 40px 20px 40px; border-radius: 16px 16px 0 0; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 24px; }
  .footer-right { flex-wrap: wrap; gap: 20px; }
}
