/* 7times77 — pitch black, complete minimalism */
@font-face {
  font-family: Inter;
  src: url("/fonts/inter-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #000000;
  --fg: #ffffff;
  --muted: #8f8f8f;      /* passes 4.5:1 on black */
  --line: #262626;
  --hover: #bdbdbd;
  --font-sans: Inter, system-ui, -apple-system, sans-serif;
  --gutter: clamp(1.5rem, 4vw, 3rem);
  --measure: 760px;
  color-scheme: dark;
}

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

html { scroll-behavior: smooth; scroll-padding-top: env(safe-area-inset-top, 0px); }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--fg); text-decoration: none; }
a:hover { color: var(--hover); }
a:focus-visible { outline: 2px solid var(--fg); outline-offset: 4px; }

.skip {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  padding: 0.5rem 0.75rem;
  background: var(--fg);
  color: var(--bg);
  z-index: 10;
}
.skip:focus { top: 1rem; color: var(--bg); }

.page {
  min-height: 100vh;
  min-height: 100dvh;
  padding: var(--gutter);
  padding-top: max(var(--gutter), env(safe-area-inset-top, 0px));
  padding-bottom: max(var(--gutter), env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: clamp(4rem, 10vw, 7rem);
}

/* Header */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.brand, .nav-link {
  min-height: 44px;
  display: flex;
  align-items: center;
}
.brand { gap: 14px; }
.mark { display: block; width: 44px; height: auto; }
.wordmark { font-size: 1.125rem; font-weight: 600; letter-spacing: -0.02em; }
.nav-link { font-size: 0.9375rem; font-weight: 500; }

/* Main */
.main {
  width: 100%;
  max-width: var(--measure);
  display: flex;
  flex-direction: column;
  gap: clamp(4rem, 10vw, 7rem);
}

.headline {
  margin: 0;
  font-size: clamp(2.25rem, 6vw, 4rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.05;
  text-wrap: balance;
}

.lede {
  margin: 1.5rem 0 0;
  max-width: 34em;
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  color: var(--muted);
  text-wrap: pretty;
}

.section-title {
  margin: 0 0 1.25rem;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--muted);
}

/* Work list: rows sit muted; each lights up in its own brand color */
.work { position: relative; }
.work-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }

.work-row {
  display: grid;
  grid-template-columns: 1fr auto 16px;
  grid-template-areas: "name meta arrow";
  align-items: center;
  gap: 0.25rem 1.5rem;
  min-height: 44px;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  transition: color 0.3s ease;
}
.work-row:hover,
.work-row:focus-visible,
.work-row:active { color: var(--brand, var(--fg)); }

.work-name { grid-area: name; font-size: 1.25rem; font-weight: 500; }
.work-meta { grid-area: meta; font-size: 0.875rem; color: var(--muted); }
.arrow { grid-area: arrow; fill: none; stroke: currentColor; stroke-width: 1.5; }
.work-shot { display: none; }

/* Phones: name and arrow on one line, details under it, same for every row */
@media (max-width: 600px) {
  .work-row {
    grid-template-columns: 1fr 16px;
    grid-template-areas: "name arrow" "meta meta";
  }
}

/* Touch screens can't hover, so each row shows its brand color as a dot */
@media (hover: none) {
  .work-name::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    margin: 0 0.75rem 0.15em 0;
    border-radius: 50%;
    background: var(--brand);
  }
}

/* Wide screens with a mouse: a preview of the site floats beside the list */
@media (hover: hover) and (pointer: fine) and (min-width: 1280px) {
  .work-shot {
    display: block;
    position: absolute;
    top: 2.75rem;
    left: calc(100% + 3.5rem);
    width: 360px;
    height: auto;
    border: 1px solid var(--line);
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
  }
  .work-row:hover .work-shot,
  .work-row:focus-visible .work-shot { opacity: 1; transform: none; }
}

.section-note { margin: 1rem 0 0; font-size: 0.875rem; color: var(--muted); }

/* Client quotes */
.quote { margin: 0; padding-left: 1.25rem; border-left: 2px solid var(--brand, var(--line)); }
.quote blockquote { margin: 0; }
.quote p {
  margin: 0;
  max-width: 36em;
  font-size: clamp(1.125rem, 2vw, 1.375rem);
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: -0.01em;
  text-wrap: pretty;
}
.quote figcaption { margin-top: 1rem; font-size: 0.9375rem; color: var(--muted); }
.quote figcaption a { color: var(--muted); border-bottom: 1px solid var(--line); }
.quote figcaption a:hover { color: var(--brand, var(--fg)); border-color: currentColor; }

/* Apps: same rows, with the app icon in front */
.section-intro { margin: -0.5rem 0 1.5rem; max-width: 34em; color: var(--muted); }
.app-row {
  grid-template-columns: 40px 1fr auto 16px;
  grid-template-areas: "icon name meta arrow";
  column-gap: 1rem;
}
.app-icon {
  grid-area: icon;
  display: block;
  width: 40px;
  height: 40px;
  border-radius: 22%;
  opacity: 0.75;
  transition: opacity 0.3s ease;
}
.app-row:hover .app-icon,
.app-row:focus-visible .app-icon { opacity: 1; }
.more-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 0.5rem;
  font-size: 0.9375rem;
  color: var(--muted);
}
.more-link::after { content: " →"; white-space: pre; }
.more-link:hover { color: var(--fg); }

@media (max-width: 600px) {
  .app-row {
    grid-template-columns: 40px 1fr 16px;
    grid-template-areas: "icon name arrow" "icon meta arrow";
  }
}

/* Touch screens: the icon already carries the color */
@media (hover: none) {
  .app-row .work-name::before { content: none; }
  .app-icon { opacity: 1; }
}

/* How it works */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  counter-reset: step;
}
.steps li { counter-increment: step; border-top: 1px solid var(--line); padding-top: 1.25rem; }
.steps h3 { margin: 0 0 0.5rem; font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em; }
.steps h3::before { content: counter(step) "  "; white-space: pre; color: var(--muted); font-weight: 500; }
.steps p { margin: 0; font-size: 0.9375rem; color: var(--muted); }

@media (max-width: 700px) {
  .steps { grid-template-columns: 1fr; gap: 1.5rem; }
}

/* Contact */
.contact-email {
  display: inline-block;
  font-size: clamp(1.75rem, 5.5vw, 3.25rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.1;
  overflow-wrap: anywhere;
  border-bottom: 2px solid var(--line);
  padding-bottom: 0.15em;
  transition: border-color 0.3s ease, color 0.3s ease;
}
.contact-email:hover { color: var(--fg); border-color: var(--fg); }
.contact-alt { margin: 1rem 0 0; font-size: 1.0625rem; color: var(--muted); }
.contact-alt a {
  display: inline-block;
  padding: 0.6rem 0 0.1rem; /* ~44px tap target */
  color: var(--fg);
  border-bottom: 1px solid var(--line);
}
.contact-alt a:hover { border-color: var(--fg); }
.contact-note { margin: 1.25rem 0 0; max-width: 34em; color: var(--muted); }

/* Footer */
.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.875rem;
  color: var(--muted);
}

/* 404 */
.not-found .headline { margin-bottom: 1.5rem; }
.not-found a { border-bottom: 1px solid var(--line); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .work-row, .work-shot, .contact-email { transition: none; }
}
