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

:root {
  --bg: #181b24;
  --surface: #1e2130;
  --border: #272c3d;
  --muted: #6b748f;
  --body: #a0aac0;
  --bright: #eef0f8;
  --green: #3ddc84;
  --gold: #c8a96e;
  --mono: "Martian Mono", monospace;
  --sans: "Sono", sans-serif;
  --max: 1200px;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--bg);
  color: var(--body);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.75;
  overflow-x: hidden;
  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.8' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.028'/%3E%3C/svg%3E");
}

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

header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(24, 27, 36, 0.9);
  backdrop-filter: blur(14px);
}

.header-inner {
  padding: 2rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-spread-link {
  font-family: var(--mono);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--body);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: color 0.15s;
  flex: 1;
}
.nav-spread-link:first-child {
  text-align: left;
}
.nav-spread-link:last-child {
  text-align: right;
}
.nav-spread-link:hover {
  color: var(--bright);
}

.nav-wordmark {
  font-family: var(--mono);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--bright);
  letter-spacing: -0.02em;
  text-align: center;
  flex: 1;
  transition: opacity 0.15s;
}
.nav-wordmark:hover {
  opacity: 0.7;
}

.hero {
  min-height: 100vh;
  min-height: 100dvh;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

.hero-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 7rem 3.5rem 3rem;
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-type-block {
  display: grid;
  grid-template-columns: 1fr max-content;
  grid-template-areas:
    "line1 line1"
    "line2 bio"
    "line3 line3"
    "line4 line4";
  align-items: center;
  column-gap: 2rem;
}

.hero-line-1 {
  grid-area: line1;
}
.hero-line-2 {
  grid-area: line2;
}
.hero-line-3 {
  grid-area: line3;
}
.hero-line-4 {
  grid-area: line4;
}

.hero-line {
  font-family: var(--mono);
  font-size: clamp(3rem, 8.5vw, 9.5rem);
  font-weight: 700;
  color: var(--bright);
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
  opacity: 0;
  animation: fadeUp 0.7s ease forwards;
}

.hero-line-1 {
  animation-delay: 0.05s;
}
.hero-line-2 {
  animation-delay: 0.15s;
}
.hero-line-3 {
  animation-delay: 0.25s;
}
.hero-line-4 {
  animation-delay: 0.35s;
}

.hero-line em {
  font-style: normal;
  color: var(--green);
}

.hero-bio {
  grid-area: bio;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-self: center;
  opacity: 0;
  animation: fadeUp 0.7s ease 0.2s forwards;
}

.hero-bio p {
  font-family: var(--sans);
  font-size: clamp(0.75rem, 1vw, 0.9rem);
  font-weight: 300;
  color: var(--muted);
  line-height: 1.7;
  letter-spacing: 0;
}

.hero-email {
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--green);
  letter-spacing: 0.04em;
  border-bottom: 1px solid rgba(61, 220, 132, 0.3);
  padding-bottom: 2px;
  width: fit-content;
  transition: border-color 0.15s;
}
.hero-email:hover {
  border-color: var(--green);
}

.hero-foot {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding-top: 3rem;
  border-top: 1px solid var(--border);
  margin-top: 3rem;
  opacity: 0;
  animation: fadeUp 0.7s ease 0.45s forwards;
}

.hero-wordmark {
  font-family: var(--mono);
  font-size: clamp(2.5rem, 6vw, 7rem);
  font-weight: 700;
  color: var(--bright);
  letter-spacing: -0.04em;
  line-height: 1;
  opacity: 0.12;
}

.hero-down {
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--muted);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.hero-down:hover {
  color: var(--bright);
}

.section-label {
  font-family: var(--mono);
  font-size: 0.58rem;
  color: var(--muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.section-note {
  font-family: var(--mono);
  font-size: 0.58rem;
  color: var(--muted);
  opacity: 0.5;
  letter-spacing: 0.06em;
}

.work {
  border-bottom: 1px solid var(--border);
}

.work-list {
  display: flex;
  flex-direction: column;
}

.project-card {
  background: var(--surface);
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 3.5rem;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.project-card:last-child {
  border-bottom: none;
}

.project-card-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.project-frame {
  width: 100%;
  max-width: 1200px;
  border-radius: 32px;
  overflow: hidden;
  position: relative;
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.15),
    0 8px 24px rgba(0, 0, 0, 0.3),
    0 24px 64px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.06);
  transform: translateY(0px);
  transition:
    transform 0.5s ease,
    box-shadow 0.5s ease;
}

.project-frame:hover {
  transform: translateY(-6px);
  box-shadow:
    0 4px 8px rgba(0, 0, 0, 0.2),
    0 16px 40px rgba(0, 0, 0, 0.4),
    0 40px 80px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.08);
}

.project-img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.6s ease;
}

.project-frame:hover .project-img {
  transform: scale(1.01);
}

.project-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: flex-end;
  padding: 2.5rem;
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.project-frame:hover .project-overlay {
  opacity: 1;
  pointer-events: auto;
}

.project-overlay-inner {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  transform: translateY(8px);
  transition: transform 0.35s ease;
}

.project-frame:hover .project-overlay-inner {
  transform: translateY(0);
}

.project-overlay-top {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-bottom: 0.3rem;
}

.project-num {
  font-family: var(--mono);
  font-size: 0.55rem;
  color: var(--card-accent);
  letter-spacing: 0.14em;
  opacity: 0.6;
}

.project-type {
  font-family: var(--mono);
  font-size: 0.55rem;
  color: var(--card-text);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.35;
}

.project-overlay-inner h3 {
  font-family: var(--mono);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--card-text);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.project-overlay-inner p {
  font-size: 0.88rem;
  line-height: 1.65;
  color: var(--card-text);
  opacity: 0.55;
  max-width: 480px;
}

.project-cta {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--card-accent);
  letter-spacing: 0.04em;
  margin-top: 0.5rem;
  border-bottom: 1px solid var(--card-accent);
  padding-bottom: 2px;
  width: fit-content;
}

.about {
  border-bottom: 1px solid var(--border);
}

.about-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 6rem 3.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8rem;
  align-items: start;
}

.about-left,
.about-right {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}

.about-left .section-label,
.about-right .section-label {
  margin-bottom: 0.4rem;
}

.about-left p,
.about-right p {
  font-size: 0.97rem;
  line-height: 1.82;
}

.nudge {
  font-size: 0.88rem !important;
  color: var(--muted);
  font-style: italic;
}

.clock-row {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-top: 0.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.clock-label {
  font-family: var(--mono);
  font-size: 0.52rem;
  color: var(--muted);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

#counter {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--green);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.how-list {
  list-style: none;
  display: flex;
  flex-direction: column;
}

.how-list li {
  display: grid;
  grid-template-columns: 2.2rem 1fr;
  gap: 1rem;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.93rem;
  line-height: 1.72;
}
.how-list li:first-child {
  border-top: 1px solid var(--border);
}

.n {
  font-family: var(--mono);
  font-size: 0.55rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  padding-top: 0.2rem;
}

.how-list strong {
  display: block;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--bright);
  margin-bottom: 0.25rem;
}

.contact {
  border-bottom: 1px solid var(--border);
}

.contact-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 7rem 3.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
}

.contact-inner h2 {
  font-family: var(--mono);
  font-size: clamp(2.5rem, 5vw, 5.5rem);
  font-weight: 300;
  color: var(--bright);
  line-height: 1.05;
  letter-spacing: -0.03em;
  text-transform: none;
  margin-bottom: 0;
}

.contact-inner h2 em {
  font-style: normal;
  color: var(--green);
}

.contact-right {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-right p {
  font-size: 0.97rem;
  line-height: 1.8;
}

.mailto {
  display: inline-block;
  font-family: var(--mono);
  font-size: 1rem;
  color: var(--bright);
  border-bottom: 1px solid var(--green);
  padding-bottom: 3px;
  transition: color 0.15s;
  letter-spacing: -0.01em;
}
.mailto:hover {
  color: var(--green);
}

footer {
  border-top: 1px solid var(--border);
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.8rem 3.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--mono);
  font-size: 0.6rem;
  color: var(--muted);
  letter-spacing: 0.06em;
}

footer nav {
  display: flex;
  gap: 2rem;
}
footer a {
  color: var(--muted);
  transition: color 0.15s;
}
footer a:hover {
  color: var(--body);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}
.d1 {
  transition-delay: 0.12s;
}
.d2 {
  transition-delay: 0.24s;
}

@media (max-width: 900px) {
  .about-inner {
    grid-template-columns: 1fr;
    gap: 4rem;
  }
  .contact-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .project-info {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  .project-info-right {
    flex-direction: row;
    align-items: center;
    gap: 1.5rem;
  }
}

@media (max-width: 768px) {
  .hero-type-block {
    display: flex;
    flex-direction: column;
  }

  .hero-line {
    font-size: clamp(2.8rem, 13vw, 9.5rem);
  }

  .hero-bio {
    align-self: flex-start;
    margin-top: 1.4rem;
    padding-top: 1.4rem;
    border-top: 1px solid var(--border);
    width: 100%;
  }

  .project-card {
    padding: 1.5rem;
    min-height: auto;
  }
}

@media (max-width: 640px) {
  .header-inner {
    padding: 1rem 1.5rem;
  }
  .nav-links {
    display: none;
  }
  .hero-inner {
    padding: 5rem 1.2rem 2rem;
  }
  .hero-line {
    font-size: clamp(2.8rem, 13vw, 9.5rem);
  }
  .hero-foot {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
  }
  .hero-wordmark {
    font-size: clamp(2rem, 12vw, 9.5rem);
  }
  .project-card {
    padding: 0;
    min-height: auto;
    background: #000;
  }
  .project-frame {
    border-radius: 0;
    box-shadow: none;
  }
  /* Info bar below image */
  .project-overlay {
    position: static;
    background: var(--surface);
    backdrop-filter: none;
    opacity: 1;
    padding: 1.2rem 1.2rem 1.4rem;
    pointer-events: auto;
  }
  .project-overlay-inner {
    transform: none;
  }
  .project-frame:hover .project-overlay-inner {
    transform: none;
  }
  .project-overlay-inner h3 {
    font-size: 1rem;
  }
  .project-overlay-inner p {
    font-size: 0.8rem;
  }
  .about-inner {
    padding: 4rem 1.5rem;
  }
  .contact-inner {
    padding: 4rem 1.5rem;
  }
  .footer-inner {
    padding: 1.5rem;
  }
}
