/* Paul Davies Studio, pauldaviesstudio.com
   Brand: Style Guide v1.2. Warm cream ground, warm navy ink, sunset stripe as
   the one motif. Plain HTML and CSS on purpose: no build step, no framework,
   nothing to keep updated. */

:root {
  --sun-1: #F5C93A;
  --sun-2: #EFAB30;
  --sun-3: #E07830;
  --sun-4: #CC5828;
  --sun-5: #A03820;
  --sun-6: #7D2518;

  --cream: #FAF3E4;
  --wall: #F7F0E3;
  --navy: #1E2D4D;
  --rust: #A03820;          /* 6.2:1 on cream, safe for text */
  --muted: #6A6152;         /* 5.4:1 on cream */
  --line: #E2D9C6;
  --white: #FFFFFF;

  --measure: 34rem;
  --page: 68rem;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--wall);
  color: var(--navy);
  font: 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .badge, .nav a, .btn, .eyebrow {
  font-family: "Avenir Next", "Futura", "Trebuchet MS", Helvetica, Arial, sans-serif;
}

h1, h2, h3 { line-height: 1.1; letter-spacing: 0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.1rem, 6vw, 3.5rem); text-transform: uppercase; font-weight: 800; }
h2 { font-size: clamp(1.5rem, 3.6vw, 2.1rem); text-transform: uppercase; font-weight: 800; }
h3 { font-size: 1.15rem; text-transform: uppercase; letter-spacing: 0.06em; }
p { margin: 0 0 1rem; max-width: var(--measure); }
a { color: var(--rust); }
a:focus-visible, .btn:focus-visible { outline: 3px solid var(--sun-4); outline-offset: 3px; }

.eyebrow {
  color: var(--rust);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.8rem;
  font-weight: 700;
  margin: 0 0 0.75rem;
}

.wrap { width: min(var(--page), 100% - 2.5rem); margin-inline: auto; }

/* header */
header { background: var(--cream); border-bottom: 1px solid var(--line); }
.bar { display: flex; flex-wrap: wrap; gap: 1rem 1.5rem; align-items: center; justify-content: space-between; padding: 1.1rem 0; }
.badge { font-weight: 800; text-transform: uppercase; letter-spacing: 0.12em; color: var(--navy); text-decoration: none; font-size: 1rem; }
.badge span { color: var(--rust); }
.nav { display: flex; flex-wrap: wrap; gap: 1.1rem; }
.nav a { color: var(--navy); text-decoration: none; text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.82rem; font-weight: 700; padding-block: 0.62rem; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--rust); box-shadow: inset 0 -3px 0 var(--sun-3); }

/* buttons */
/* quiet buttons: the drawings should be the loudest thing on the page */
.btn {
  display: inline-block; text-decoration: none; font-weight: 600;
  letter-spacing: 0.01em; font-size: 0.98rem;
  padding: 0.7rem 1.25rem; border-radius: 4px; border: 1px solid transparent;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
@media (prefers-reduced-motion: reduce) { .btn { transition: none; } }
.btn-primary { background: var(--navy); color: var(--cream); }
.btn-primary:hover { background: var(--rust); color: var(--cream); }
.btn-ghost { border-color: rgba(30, 45, 77, 0.55); color: var(--navy); }
.btn-ghost:hover { border-color: var(--navy); }
.btns { display: flex; flex-wrap: wrap; gap: 0.8rem; margin: 1.4rem 0 0; }

/* sections */
section { padding: 3.2rem 0; }
section + section { border-top: 1px solid var(--line); }
.hero { background: var(--cream); }
.lead { font-size: 1.15rem; color: var(--muted); }

/* work grid */
.grid { display: grid; gap: 1.6rem; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); margin: 0; padding: 0; list-style: none; }
.piece { margin: 0; }
.piece img {
  width: 100%; display: block; border: 1px solid var(--line);
  /* one frame shape for every piece, and contain rather than cover: a
     portrait must never be cropped to fit a layout */
  aspect-ratio: 3 / 4; height: auto; object-fit: contain;
  background: var(--white); padding: 0.6rem;
}
.piece figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 0.5rem; text-transform: uppercase; letter-spacing: 0.07em; }

/* prices */
table { border-collapse: collapse; width: 100%; max-width: 34rem; margin: 0 0 1.2rem; }
th, td { text-align: left; padding: 0.6rem 0.8rem 0.6rem 0; border-bottom: 1px solid var(--line); }
th { text-transform: uppercase; letter-spacing: 0.07em; font-size: 0.8rem; color: var(--muted); }
td:last-child, th:last-child { text-align: right; padding-right: 0; }

.note { color: var(--muted); font-size: 0.95rem; }
.cols { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); align-items: start; }
.card { background: var(--cream); border: 1px solid var(--line); padding: 1.5rem; }
.card p:last-child { margin-bottom: 0; }
ol.steps { padding-left: 1.1rem; max-width: var(--measure); }
ol.steps li { margin-bottom: 0.6rem; }

/* footer */
footer { background: var(--navy); color: var(--cream); padding: 2.5rem 0 3rem; }
footer a { color: var(--sun-1); }
footer p { color: #D9D2C4; }
/* .note is a muted brown for cream grounds; on the navy footer it must lift */
footer .note { color: #C9C1B1; }


/* short stripe rule under a heading, in place of a plain line */
.hero { position: relative; }

/* the badge */
.badge { display: inline-flex; align-items: center; gap: 0.7rem; }
.badge img { width: 46px; height: 46px; display: block; }
.hero-badge { width: 96px; height: 96px; display: block; margin: 0 0 1.2rem; }
@media (min-width: 900px) { .hero-badge { position: absolute; right: 0; top: 2.6rem; width: 132px; height: 132px; margin: 0; } }
.foot-badge { width: 84px; height: 84px; display: block; margin: 0 0 1.2rem; }

footer { position: relative; padding-top: 2.5rem; }


/* ---- 70s/80s athletic: the stripe as kit, not as trim ------------------- */

/* three bold diagonal bars, the track jacket shoulder */
/* every section heading wears the stripes */
/* the hero carries the diagonal bars behind the badge */
@media (min-width: 900px) {
  .hero { overflow: hidden; }
  /* upright bars down the right of the hero, no angles */
  .hero::after {
    content: ""; position: absolute; right: 0; top: 0; bottom: 0;
    width: 150px; opacity: 0.14;
    background: repeating-linear-gradient(90deg,
      var(--sun-1) 0 14px, transparent 14px 44px,
      var(--sun-3) 44px 58px, transparent 58px 88px,
      var(--sun-5) 88px 102px, transparent 102px 132px);
    pointer-events: none;
  }
  .hero .wrap { position: relative; z-index: 1; }
}

/* heavier, wider lettering: varsity rather than minimal */
h1 { letter-spacing: 0.02em; }
h2 { letter-spacing: 0.05em; }
.badge-text { letter-spacing: 0.14em; }

/* the footer as a kit label: stripes top and bottom */
footer { padding-bottom: 3.4rem; }


/* ---- the spine: six stripe columns down the left of every page ---------- */
:root { --spine: 20px; }
@media (min-width: 700px)  { :root { --spine: 36px; } }
@media (min-width: 1100px) { :root { --spine: 54px; } }

body { padding-inline: var(--spine); }
body::before, body::after {
  content: "";
  position: fixed; top: 0; bottom: 0; width: var(--spine); z-index: 40;
  background: linear-gradient(to right,
    var(--sun-1) 0 16.66%, var(--sun-2) 16.66% 33.33%, var(--sun-3) 33.33% 50%,
    var(--sun-4) 50% 66.66%, var(--sun-5) 66.66% 83.33%, var(--sun-6) 83.33% 100%);
}
/* left runs yellow to burgundy inwards; right mirrors it, so the page sits
   inside the stripes rather than beside them */
body::before { left: 0; }
body::after { right: 0; transform: scaleX(-1); }

/* a single quiet rule, not a band of colour */
.rule { width: 120px; height: 3px; background: var(--rust); margin: 0 0 1.4rem; opacity: 0.85; }


/* keyboard users land here first */
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--navy); color: var(--cream); padding: 0.7rem 1rem;
}
.skip-link:focus { left: 0; }

/* the drawing in the hero, so a phone sees work straight away */
.hero-piece { margin: 1.8rem 0 0; max-width: 320px; }
.hero-piece img { width: 100%; height: auto; display: block; border: 1px solid var(--line); background: var(--white); padding: 0.5rem; }
.hero-piece figcaption { font-size: 0.82rem; color: var(--muted); margin-top: 0.5rem; text-transform: uppercase; letter-spacing: 0.07em; }
/* Only the hero that actually holds a drawing becomes two columns. Applied to
   every hero, it squeezed the headline of every other page into the 320px
   column: right on a phone, broken on a laptop. */
@media (min-width: 900px) {
  .hero .wrap.has-piece { display: grid; grid-template-columns: 1fr 320px; gap: 2.5rem; align-items: start; }
  .hero .wrap.has-piece > :not(.hero-piece) { grid-column: 1; }
  .hero .wrap.has-piece .hero-piece { margin: 0; grid-column: 2; grid-row: 1 / span 8; position: relative; z-index: 2; }
}
table caption { text-align: left; padding-bottom: 0.6rem; }

/* on a phone the drawing comes before the buttons, so a visitor sent by a
   drawing sees one without scrolling */
@media (max-width: 899px) {
  .hero .wrap { display: flex; flex-direction: column; }
  .hero-piece { order: 5; margin-top: 1.2rem; max-width: 260px; }
  .hero .btns { order: 6; }
  .hero { padding-top: 1.8rem; padding-bottom: 2.2rem; }
  .hero h1 { font-size: 1.95rem; }
  .hero .lead { font-size: 1.03rem; margin-bottom: 0.6rem; }
  .nav { gap: 0.72rem; }
  .nav a { font-size: 0.76rem; letter-spacing: 0.05em; }
}
