/* Travis Ladue — homepage
   All measurements come from the 1440px Figma frame and are expressed in
   --u (one design pixel). Below 1440 a design pixel is a real pixel and the
   layout flexes; above 1440 the whole page scales up proportionally. */

:root {
  --u: 1px;
  --bg: #000;
  --fg: #fff;
  --placeholder: #d9d9d9;
  --line: rgba(255, 255, 255, .295);   /* section and row lines (#4B4B4B on black) */
  --margin: calc(24 * var(--u));
  --col: 72.381%;            /* right text column: (1031.54 - 24) / 1392 */
  --ease: cubic-bezier(.22, .61, .21, 1);
}
@media (min-width: 1440px) {
  :root { --u: calc(100vw / 1440); }
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: calc(10 * var(--u));
  font-weight: 400;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-wrap: break-word;
}
h2, p, ul { margin: 0; padding: 0; font: inherit; }
ul { list-style: none; }
img { display: block; }

a { color: inherit; text-decoration: underline; text-decoration-thickness: from-font; text-underline-position: from-font; transition: opacity .3s var(--ease); }
a:hover { opacity: .55; }
a:focus-visible { outline: 1px solid var(--fg); outline-offset: 3px; }

/* ---------- shared structure ---------- */
.site-header, main > section, .site-footer { position: relative; padding: 0 var(--margin); }

.row { display: grid; grid-template-columns: var(--col) minmax(0, 1fr); }
.body { max-width: calc(280 * var(--u)); }

/* ---------- header ---------- */
.header-row { height: calc(62.5 * var(--u)); }
.mark { display: block; width: calc(20 * var(--u)); height: calc(19.93 * var(--u)); background: none; }
.mark img { width: 100%; height: 100%; }
/* the symbol turns once when pointed at, and turns back when the pointer leaves */
.mark img { transition: transform .9s cubic-bezier(.45, 0, .2, 1); }
.mark:hover { opacity: 1; }
.mark:hover img, .mark:focus-visible img { transform: rotate(360deg); }
@media (prefers-reduced-motion: reduce) { .mark img { transition: none; } .mark:hover img, .mark:focus-visible img { transform: none; } }
.site-header .mark { margin-top: calc(21.1 * var(--u)); }
.site-header .tagline { margin-top: calc(31.27 * var(--u)); }
.tagline { margin-left: calc(.36 * var(--u)); }

/* ---------- hero cascade ---------- */
main > .hero { padding: calc(82.5 * var(--u)) 0 calc(63 * var(--u)); overflow: hidden; }
/* On tall screens the hero grows so the About text starts low on the first
   screen (about 82% down) instead of floating in the middle. The Figma
   spacing above is the minimum; any extra height is shared out, roughly a
   third above the pictures and two thirds below. */
@media (min-width: 1100px) {
  main > .hero { display: flex; flex-direction: column; min-height: calc(82vh - 62.5 * var(--u)); }
  main > .hero::before { content: ""; flex: 0.35 0 0px; }
  main > .hero::after { content: ""; flex: 0.65 0 0px; }
  main > .hero > .cascade { flex: none; width: 100%; }
}
.cascade {
  position: relative;
  isolation: isolate;                  /* the pictures' stacking order stays inside the carousel */
  height: calc(622 * var(--u));        /* refined by site.js */
  cursor: grab;
  touch-action: pan-y;
  user-select: none; -webkit-user-select: none;
  outline: none;
}
.cascade.is-dragging { cursor: grabbing; }
.card {
  position: absolute; left: 50%; top: 0;   /* the centre picture sits at the top of the stage */
  width: var(--cw); height: var(--ch);
  margin: 0 0 0 calc(var(--cw) / -2);
  background: #111;                    /* never a light colour, so no pale edge can show */
  box-shadow: 0 calc(6 * var(--u)) calc(26 * var(--u)) rgba(0, 0, 0, .3);   /* very slight: only reads where one picture overlaps another */
  overflow: hidden;
  transform-origin: 50% 50%;
  backface-visibility: hidden;
}
.cascade.is-moving .card { will-change: transform; }   /* only while moving, so resting cards are redrawn sharp */
.card img {
  position: absolute; inset: -1px; width: calc(100% + 2px); height: calc(100% + 2px); max-width: none; object-fit: cover;
  opacity: 0; transition: opacity .5s ease; pointer-events: none;
}
.card img.is-loaded { opacity: 1; }
/* pictures on pure black keep a faint outline; its width is divided by the card's scale so it stays 1px */
.card.is-dark::after { content: ""; position: absolute; inset: 0; border: calc(1px / var(--s, 1)) solid rgba(255, 255, 255, .12); pointer-events: none; }
.cascade:focus-visible .card { outline: 1px solid var(--fg); outline-offset: -1px; }

/* ---------- text blocks ---------- */
/* a thin line above each section, across the content width */
.block::before, .site-footer::before {
  content: ""; display: block;
  height: calc(1 * var(--u));
  background: var(--line);
  transform-origin: 0 50%;
}
.label { line-height: 1; }
/* section titles share a baseline with the first line of their text block */
.block .row { align-items: baseline; }
.about { min-height: calc(381.25 * var(--u)); display: flex; flex-direction: column; }
.about .row { flex: 1; padding-top: calc(11 * var(--u)); }
.about-body { padding-bottom: calc(26.46 * var(--u)); }
.about-text { line-height: 1.1; }
.about-text p + p { margin-top: 1.1em; }
.contact { line-height: 1.1; margin-top: calc(59.64 * var(--u)); }

/* feature lists: one 30px row per entry, each with a line beneath, running to the right margin */
.list { line-height: 1; max-width: none; margin-left: calc(3.46 * var(--u)); }
.list li {
  box-sizing: border-box;
  min-height: calc(30 * var(--u));
  padding: calc(10.75 * var(--u)) 0 calc(8.25 * var(--u));
  border-bottom: calc(1 * var(--u)) solid var(--line);
}
/* each list is followed by one empty row's worth of space (29 + the next section's 1px line = 30), however many entries it has */
.printed, .digital { padding-bottom: calc(29 * var(--u)); }

/* ---------- logos ---------- */
.logos { display: flow-root; }   /* keeps the grid's negative margin inside the section */
.logos-label { position: absolute; left: calc(23.18 * var(--u)); top: calc(15.55 * var(--u)); }
.logo-grid { position: relative; height: calc(2060 * var(--u)); margin-top: calc(-89.8 * var(--u)); }
/* the quote: bottom right, on the feature lists' left edge, above the footer line */
.quote {
  /* vertically centred between the bottom of the last logo row and the footer line */
  margin: calc(46.8 * var(--u)) 0 0 calc(72.381% + 3.46 * var(--u));
  padding-bottom: calc(50.5 * var(--u));
  line-height: 1.1;
}
.quote p { margin: 0; }
.logo {
  position: absolute;
  /* --f: 0..1 across the grid, pinned 35.7 / 48.5 design px from the edges */
  left: calc(35.7 * var(--u) + var(--f) * (100% - 84.2 * var(--u)));
  top: calc(var(--t) * var(--u));
  width: calc(var(--w) * var(--u));
  height: calc(var(--h) * var(--u));
  margin: calc(var(--h) * var(--u) / -2) 0 0 calc(var(--w) * var(--u) / -2);
  transform: scale(.88);              /* each mark at 88% (80% + 10%), centred on its original position */
  transition: opacity .5s var(--ease);
}
.logo img {
  position: absolute;
  left: calc(var(--x) * var(--u));
  top: calc(var(--y) * var(--u));
  width: calc(var(--iw) * var(--u));
  height: calc(var(--ih) * var(--u));
}
@media (hover: hover) {
  .logo-grid:hover .logo { opacity: .32; }
  .logo-grid:hover .logo:hover { opacity: 1; }
}

/* ---------- footer ---------- */
.site-footer { min-height: calc(75.75 * var(--u)); }
.footer-row { padding: calc(8.47 * var(--u)) 0 calc(21.1 * var(--u)); }
/* every piece of footer text sits on one shared baseline */
.footer-row { align-items: baseline; }
.footer-left { display: flex; align-items: baseline; }
.social { width: calc(101 * var(--u)); line-height: 1.5; flex: none; }
.places { width: calc(202 * var(--u)); line-height: 1.567; flex: none; font-variant-numeric: tabular-nums; white-space: nowrap; }
.legal { width: calc(195 * var(--u)); margin: 0 0 0 calc(.74 * var(--u)); }
.footer-right { display: flex; align-items: baseline; position: relative; }
/* "Travis Ladue. Design, etc." starts on exactly the same left edge as the quote above it (and the feature lists) */
.footer-right .tagline { flex: 0 1 calc(199.62 * var(--u)); min-width: max-content; margin-left: calc(3.46 * var(--u)); padding-right: calc(16 * var(--u)); white-space: nowrap; }
.footer-right .email { line-height: 1.5; padding-right: calc(16 * var(--u)); white-space: nowrap; }
.footer-right .mark { margin: calc(2.78 * var(--u)) calc(10.2 * var(--u)) 0 auto; flex: none; align-self: flex-start; }

/* ---------- loader ---------- */
.loader { display: none; }
.js .loader {
  position: fixed; inset: 0; z-index: 1000;   /* above everything, including the pictures' own stacking order */
  display: flex; align-items: center; justify-content: center;
  padding: 0 var(--margin);
  background: var(--bg);
  text-align: center;
  transition: opacity .65s ease, visibility 0s linear .65s;
}
.js .loader.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-text { line-height: 1.5; opacity: 0; }
.loader-text.is-ready { opacity: 1; }
.loader-word { display: inline-block; white-space: nowrap; }
.loader-char { opacity: 0; transition: opacity .35s ease; }
.is-typing .loader-char { opacity: 1; }
.is-loading, .is-loading body { overflow: hidden; }
/* nothing behind the loader is drawn at all until it has gone (pictures still download) */
.is-loading .site-header, .is-loading main, .is-loading .site-footer { visibility: hidden; }

/* ---------- motion ---------- */
.js .fade { opacity: 0; transform: translateY(calc(8 * var(--u))); transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: calc(var(--d, 0s) + var(--seq, 0s)); }
/* first screen, in order: pictures (0s), mark, name, "About", then the text */
.site-header.is-seq .mark    { --seq: 1.2s; }
.site-header.is-seq .tagline { --seq: 1.55s; }
.about.is-seq                { --seq-line: 1.75s; }
.printed.is-seq, .digital.is-seq { --seq-line: 2.3s; }
.about.is-seq .label         { --seq: 1.9s; }
.about.is-seq .ln            { --seq: 2.25s; }
/* feature lists that are already on screen at load follow straight on; scrolled to later, they appear at once */
.printed.is-seq .fade, .printed.is-seq .ln,
.digital.is-seq .fade, .digital.is-seq .ln { --seq: 2.3s; }   /* same start as their line; the rows then wait for it (see --wait) */
.js .is-in .fade { opacity: 1; transform: none; }
.js .block::before, .js .site-footer::before { transform: scaleX(0); transition: transform var(--line-time, 1.3s) var(--ease) var(--seq-line, 0s); }
/* feature lists: the rows hold back until the section's full-width line has finished drawing */
.printed, .digital { --line-time: 1s; }
.printed .ln, .digital .ln { --wait: 1s; }
.js .block.is-in::before, .js .site-footer.is-in::before { transform: none; }
/* text blocks: one line after another, each easing down into place */
.js .ln {
  display: inline-block;
  opacity: 0;
  transform: translateY(-.9em);
  transition: opacity .55s ease, transform .7s var(--ease);
  transition-delay: calc(.1s + var(--l, 0) * 55ms + var(--seq, 0s) + var(--wait, 0s));
}
.js li.ln { display: block; }
.js .is-in .ln { opacity: 1; transform: none; }
.js .is-in a.ln:hover { opacity: .55; transition-delay: 0s; }
.js .logo { opacity: 0; transform: translateY(calc(-14 * var(--u))) scale(.88); }
.js .logo.is-in { opacity: 1; transform: scale(.88); transition: opacity .8s var(--ease) var(--d, 0s), transform .9s var(--ease) var(--d, 0s); }
.js .logo.is-done { transition: opacity .5s var(--ease); }

@media (prefers-reduced-motion: reduce) {
  .js .fade, .js .logo, .js .ln, .js .block::before, .js .site-footer::before { transition: none !important; }
  .js .block::before, .js .site-footer::before { transform: none; }
  .js .ln { opacity: 1; transform: none; }
  .js .fade { opacity: 1; transform: none; }
  .js .logo { opacity: 1; }
}

/* ---------- tablet: logo marks reflow into an even grid ---------- */
@media (max-width: 1099px) {
  /* The right-hand footer group needs 272px. Where the page's right column is
     narrower than that, the group and the quote above it move left together,
     so their left edges always match. */
  .footer-row { grid-template-columns: minmax(0, 1fr) max(272px, 100% - var(--col) - 3.46px); column-gap: 0; }
  .footer-right .tagline { flex-basis: auto; margin-left: 0; padding-right: 32px; }
  .quote { margin-left: min(var(--col) + 3.46px, 100% - 272px); }
  .footer-right .email { padding-right: 32px; }
  .legal { width: auto; }
  .logos-label { position: static; padding: calc(15.55 * var(--u)) 0 0; margin-left: -.82px; }
  .logo-grid { margin-top: 0; }
  .quote { margin-top: 0; }
  .logo-grid {
    height: auto;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    padding: 56px 0 72px;
  }
  .logo-grid > .logo {
    position: relative; left: auto; top: auto; margin: 0;
    place-self: center;
    margin-block: calc((120px - var(--h) * var(--u)) / 2);
  }
}

/* ---------- phone ---------- */
@media (max-width: 699px) {
  :root { --margin: 16px; }
  body { font-size: 12px; }
  .site-header .header-row { grid-template-columns: auto 1fr; height: 64px; }
  .site-header .tagline { justify-self: end; }
  main > .hero { padding: 40px 0 56px; }

  .row { grid-template-columns: 1fr; }
  .body { max-width: 34em; }
  .about, .printed, .digital { min-height: 0; padding-bottom: 48px; }
  .about .row, .printed .row, .digital .row { padding-top: 16px; row-gap: 18px; }
  .list { margin-left: 0; }
  .quote { margin-left: calc(22% + 12px); padding-bottom: 40px; }   /* the footer's middle column, so it starts where "Travis Ladue. Design, etc." does */
  .about-body { padding-bottom: 0; }
  .contact { margin-top: 28px; }
  .label { opacity: .6; }

  .logo-grid { --u: .78px; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 28px 0 48px; }
  .logo-grid > .logo { margin-block: calc((88px - var(--h) * var(--u)) / 2); }

  /* phone footer: three columns, two rows
       mark      | Travis Ladue. Design, etc. | (c) 2026 Travis Ladue.
       socials   | time and weather           | Get in touch            */
  .site-footer { font-size: 11px; }
  .footer-row {
    grid-template-columns: 22% minmax(0, 1fr) max-content;
    grid-template-areas: "mark tagline legal" "social places email";
    column-gap: 12px; row-gap: 22px;
    padding: 28px 0 40px;
    align-items: baseline;
  }
  .footer-left, .footer-right { display: contents; }
  .site-footer .mark    { grid-area: mark; margin: 0; align-self: center; }
  .site-footer .tagline { grid-area: tagline; align-self: center; margin: 0; padding: 0; min-width: 0; white-space: normal; }
  .site-footer .legal   { grid-area: legal; align-self: center; width: auto; margin: 0; }
  .site-footer .social  { grid-area: social; width: auto; }
  .site-footer .places  { grid-area: places; width: auto; white-space: normal; line-height: 1.5; }
  .site-footer .email   { grid-area: email; padding: 0; }
}

/* ==========================================================================
   Second version (index-2.html, <html class="v2">): no carousel. The logo
   marks sit directly under the header, with no title and no rule above
   them; About, the feature lists, the quote and the footer follow.
   (Figma frame 5:2.)
   ========================================================================== */
.v2 .logos { padding-bottom: calc(83.3 * var(--u)); }
.v2 .logo-grid { margin-top: calc(-70.2 * var(--u)); }
.v2 .outro .quote { margin-top: calc(19 * var(--u)); padding-bottom: calc(64.2 * var(--u)); }
/* About is shorter in this version: "Get in touch" sits just above the next rule */
.v2 .about { min-height: calc(230.73 * var(--u)); }
.v2 .about-body { padding-bottom: calc(14.1 * var(--u)); }
.v2 .contact { margin-top: calc(83.18 * var(--u)); }
/* first screen: the mark and the name come straight in, then the logos row by row */
.v2 .site-header.is-seq .mark    { --seq: 0s; }
.v2 .site-header.is-seq .tagline { --seq: .25s; }
@media (max-width: 1099px) {
  .v2 .logos { padding-bottom: 0; }
  .v2 .logo-grid { margin-top: 0; }
  .v2 .outro .quote { margin-top: 0; }
}
@media (max-width: 699px) {
  .v2 .about { min-height: 0; }
  .v2 .about-body { padding-bottom: 0; }
  .v2 .contact { margin-top: 28px; }
}
