/* ============ RESET / TOKENS ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #141214;
  --ink: #000000;
  --paper: #ffffff;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--paper);
  font-family: 'Switzer', sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
img { display: block; }

/* ============ NAV ============ */
.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  background: var(--bg);
  border-bottom: 1px solid var(--paper);
}
.nav__brand {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.5px;
}
.nav__links { display: flex; gap: 38px; }
.nav__link {
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
  line-height: 20px;
}
.nav__toggle { display: none; width: 24px; height: 24px; }
.nav__toggle svg { display: block; }

/* ============ MOBILE MENU OVERLAY ============ */
.menu {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: var(--bg);
  display: none;
  flex-direction: column;
}
.menu.is-open { display: flex; }
.menu__bar {
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  border-bottom: 1px solid var(--paper);
}
.menu__bar .nav__brand { font-size: 15px; letter-spacing: -0.4px; }
.menu__bar .nav__toggle { display: block; }
.menu__links {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  padding-bottom: 80px;
}
.menu__link {
  font-weight: 700;
  font-size: 39px;
  letter-spacing: -0.4px;
}
.menu__link--current { text-decoration: line-through; opacity: 0.7; }

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
  line-height: 20px;
}
.btn--outline {
  height: 50px;
  padding: 0 28px;
  background: var(--ink);
  outline: 1px solid var(--paper);
  outline-offset: -1px;
}
.btn--ghost {
  height: 54px;
  padding: 0 36px;
  background: var(--bg);
  outline: 1px solid var(--paper);
  outline-offset: -1px;
}
.btn--solid {
  height: 54px;
  padding: 0 28px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 400;
}

/* ============ HERO ============ */
.hero {
  padding: 120px 48px 0;
  min-height: 1020px;
  border-bottom: 1px solid var(--paper);
  display: flex;
  flex-direction: column;
}
.hero__title {
  font-weight: 700;
  font-size: 160px;
  line-height: 0.92;
  letter-spacing: -6px;
}
.hero__lede {
  max-width: 694px;
  margin-top: 48px;
  font-size: 20px;
  line-height: 32px;
  font-weight: 400;
}
.hero .btn { margin-top: 36px; align-self: flex-start; }

/* ============ WORK CATALOGUE ============ */
.work {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--paper);
}
.tile {
  position: relative;
  border-bottom: 1px solid var(--paper);
}
.tile:nth-child(odd) { border-right: 1px solid var(--paper); }
.tile:nth-child(3), .tile:nth-child(4) { border-bottom: none; }
.tile__img {
  width: 100%;
  height: 540px;
  background-size: cover;
  background-position: 50% 50%;
  background-repeat: no-repeat;
}
.tile__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px 28px;
}
.tile__name { font-weight: 700; font-size: 28px; line-height: 34px; }
.tile__price {
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
}
/* buy overlay on tile */
.tile__buy {
  position: absolute;
  inset: 0;
  bottom: auto;
  height: 540px;
  width: 100%;
  background: rgba(20,18,20,0.82);
  color: var(--paper);
  font-family: 'Azeret Mono', monospace;
  font-size: 11px;
  letter-spacing: 1px;
  opacity: 0;
  transition: opacity 0.18s ease;
}
.tile:hover .tile__buy { opacity: 1; }

/* ============ ABOUT ============ */
.about {
  display: grid;
  grid-template-columns: 720px 1fr;
  border-bottom: 1px solid var(--paper);
  min-height: 465px;
}
.about__title {
  padding: 80px 48px;
  font-weight: 700;
  font-size: 80px;
  line-height: 0.95;
  letter-spacing: -3px;
  border-right: 1px solid var(--paper);
}
.about__col { padding: 80px 48px; max-width: 620px; }
.about__body { font-size: 18px; line-height: 30px; }
.about__note {
  margin-top: 34px;
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
  line-height: 20px;
}

/* ============ CTA ============ */
.cta {
  background: var(--ink);
  padding: 140px 48px 120px;
  text-align: center;
}
.cta__price {
  font-weight: 700;
  font-size: 240px;
  line-height: 1;
  letter-spacing: -10px;
}
.cta__line {
  max-width: 463px;
  margin: 32px auto 0;
  font-size: 20px;
  line-height: 32px;
}
.cta .btn { margin-top: 48px; }

/* ============ FOOTER ============ */
.foot {
  height: 173px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 48px;
  border-top: 1px solid var(--paper);
}
.foot__brand { font-weight: 700; font-size: 18px; letter-spacing: -0.5px; }
.foot__meta { text-align: right; display: flex; flex-direction: column; gap: 8px; }
.foot__line {
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
}

/* ============ BUY MODAL ============ */
.modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.78);
  padding: 24px;
}
.modal.is-open { display: flex; }
.modal__panel {
  position: relative;
  width: 100%;
  max-width: 460px;
  background: var(--bg);
  outline: 1px solid var(--paper);
  outline-offset: -1px;
  padding: 56px 40px 44px;
}
.modal__close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 24px;
  height: 24px;
}
.modal__view--hidden { display: none; }
.modal__price {
  font-weight: 700;
  font-size: 72px;
  line-height: 1;
  letter-spacing: -3px;
}
.modal__title { font-weight: 700; font-size: 30px; line-height: 1.1; margin-top: 14px; }
.modal__sub { font-size: 15px; line-height: 24px; margin-top: 12px; opacity: 0.85; }
.modal__label {
  display: block;
  margin-top: 28px;
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
}
.modal__input {
  width: 100%;
  margin-top: 10px;
  height: 50px;
  padding: 0 16px;
  background: var(--ink);
  outline: 1px solid var(--paper);
  outline-offset: -1px;
  border: none;
  color: var(--paper);
  font-family: 'Azeret Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.5px;
}
.modal__input::placeholder { color: rgba(255,255,255,0.4); }
.modal__input.is-invalid { outline-color: #ff5e5e; }
.modal__error {
  min-height: 16px;
  margin-top: 8px;
  font-family: 'Azeret Mono', monospace;
  font-size: 10px;
  letter-spacing: 1px;
  color: #ff5e5e;
}
.modal__submit { width: 100%; margin-top: 8px; }

/* ============ TABLET (<= 1024px) ============ */
@media (max-width: 1024px) {
  .nav { padding: 0 32px; }
  .hero { padding: 88px 32px 0; min-height: 786px; }
  .hero__title { font-size: 104px; letter-spacing: -4px; }
  .hero__lede { max-width: 542px; font-size: 18px; line-height: 30px; }

  .work { grid-template-columns: 1fr; }
  .tile:nth-child(odd) { border-right: none; }
  .tile:nth-child(3) { border-bottom: 1px solid var(--paper); }
  .tile__img { height: 540px; }
  .tile__buy { height: 540px; }
  .tile__bar { padding: 20px 32px 26px; }

  .about { grid-template-columns: 1fr; }
  .about__title {
    padding: 72px 32px 0;
    font-size: 72px;
    border-right: none;
  }
  .about__col { padding: 40px 32px 72px; max-width: none; }
  .about__note { width: 100%; }

  .cta { padding: 120px 32px 100px; }
  .cta__price { font-size: 168px; letter-spacing: -8px; }
  .cta__line { max-width: 422px; }

  .foot { padding: 44px 32px; }
}

/* ============ MOBILE (<= 640px) ============ */
@media (max-width: 640px) {
  .nav { height: 60px; padding: 0 20px; }
  .nav__brand { font-size: 15px; letter-spacing: -0.4px; }
  .nav__links { display: none; }
  .nav__toggle { display: block; }

  .hero { padding: 44px 20px 0; min-height: 536px; }
  .hero__title { font-size: 58px; line-height: 0.93; letter-spacing: -2px; }
  .hero__lede { margin-top: 36px; font-size: 16px; line-height: 26px; }
  .hero .btn { width: 100%; margin-top: 36px; height: 55px; }

  .tile__img { height: 340px; }
  .tile__buy { height: 340px; }
  .tile__bar { padding: 18px 20px 24px; }
  .tile__name { font-size: 22px; line-height: 26px; }
  /* touch: buy overlay always tappable via long bar tap fallback */
  .tile__buy { opacity: 0; }

  .about__title { padding: 48px 20px 0; font-size: 48px; letter-spacing: -2px; }
  .about__col { padding: 36px 20px 56px; }
  .about__body { font-size: 16px; line-height: 26px; }

  .cta { padding: 72px 20px 64px; }
  .cta__price { font-size: 120px; letter-spacing: -6px; }
  .cta__line { font-size: 18px; line-height: 28px; }
  .cta .btn { width: 100%; height: 59px; margin-top: 40px; }

  .foot {
    height: auto;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
    padding: 33px 20px 40px;
  }
  .foot__brand { font-size: 15px; letter-spacing: -0.4px; }
  .foot__meta { text-align: left; align-items: flex-start; }

  .modal__panel { padding: 48px 24px 36px; }
  .modal__price { font-size: 60px; }
}
