/* site.css — layout and components for index.html. Values come from tokens.css / brand.css. */

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

html {
  /* No scroll-behavior: smooth here: it fights ScrollTrigger's pinning and snapping */
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--color-action);
  outline-offset: 2px;
}

.wrap {
  max-width: var(--container-max);
  margin: 0 auto;
  padding-inline: var(--container-pad);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Header: Work + Start a project, scrolls away ---------- */

/* Sits over the hero so the first screen is the film itself */
.site-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-header);
}

.site-header__inner {
  /* Full width: the links sit on the right edge, level with the hero's left label */
  max-width: none;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-4);
  min-height: 64px;
}

.header-links {
  display: flex;
  gap: var(--space-3);
  /* Last link's text lines up with the container edge */
  margin-right: calc(-1 * var(--space-2));
}

.header-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 var(--space-2);
  border-radius: var(--radius-sm);
  color: var(--color-logo-ink);
  font-size: var(--text-sm);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color var(--duration-fast) var(--ease-out);
}

.header-link:hover {
  color: var(--color-text-muted);
}

/* ---------- Sections ---------- */

.section {
  padding-block: var(--space-section);
}

.section + .section {
  border-top: 1px solid var(--color-line);
}

/* The book fills the screen while pinned, so its own padding is enough below */
.section--book {
  padding-bottom: 0;
}

.section__title {
  margin: 0 0 var(--space-6);
  font-size: var(--text-2xl);
  font-weight: var(--weight-medium);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
}

/* Title with no lead, straight before the content (Work, Cases, Contact): same gap as a lead → content */
.section__title--content {
  margin-bottom: var(--space-content);
}

.section__lead {
  margin: 0;
  max-width: var(--measure);
  color: var(--color-text-muted);
}

/* Shown until a section's content is built in its own step */
.pending {
  margin: 0;
  padding: var(--space-7) var(--space-5);
  border: 1px dashed var(--color-line);
  border-radius: var(--radius-md);
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  text-align: center;
}

/* Hero styles live in hero.css */

/* ---------- Process ---------- */

.process__lead {
  margin-bottom: var(--space-content);
}

.process {
  display: grid;
  gap: var(--space-6);
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 768px) {
  .process {
    grid-template-columns: repeat(3, 1fr);
  }
}

.process h3 {
  margin: 0 0 var(--space-2);
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
}

.process p {
  margin: 0;
  color: var(--color-text-muted);
  font-size: var(--text-sm);
}

/* ---------- Contact ---------- */

.contact__email {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: var(--text-2xl);
  letter-spacing: var(--tracking-tight);
  text-underline-offset: 6px;
  border-radius: var(--radius-sm);
  transition: color var(--duration-fast) var(--ease-out);
}

.contact__email:hover {
  color: var(--color-text-muted);
}

/* ---------- Footer ---------- */

.site-footer {
  padding-block: var(--space-7);
  border-top: 1px solid var(--color-line);
  color: var(--color-text-muted);
  font-size: var(--text-xs);
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-2) var(--space-5);
}

.site-footer p {
  margin: 0;
}
