/* Nockles portfolio — design tokens extracted from the live uxfol.io-hosted site, 2026-07-29 */

:root {
  --color-bg: #ffffff;
  --color-text: #112505;
  --color-text-strong: #000000;
  --color-text-muted: #787878;
  --color-border: #e2e2e2;
  --color-hero-overlay: rgba(255, 255, 255, 0.73);

  --color-project-amazon-inbound: #f6efef;
  --color-project-supply-chain: #f5f8ff;
  --color-project-dust-mite: #fffef0;
  --color-project-streamlining: #ebffed;
  --color-project-inventory: #fcf0ff;
  --color-project-lens37: #f1eeff;

  --font-family: "Albert Sans", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --content-max-width: 1160px;
  --section-padding: 60px;
  --section-padding-sm: 40px;

  --radius: 4px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

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

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  font-weight: 500;
  color: var(--color-text-strong);
}

h1 { font-size: 42px; line-height: 1.15; font-weight: 500; }
h2 { font-size: 28px; line-height: 1.25; }
h3 { font-size: 22px; line-height: 1.3; }
h4 { font-size: 18px; line-height: 1.3; font-weight: 600; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

ul { margin: 0; padding-left: 20px; }
li { margin-bottom: 0.6em; }
li:last-child { margin-bottom: 0; }
li p { margin: 0; }

.wrap {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 0 40px;
}

/* ---------- Navigation ---------- */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid transparent;
}

.site-nav .wrap {
  display: flex;
  align-items: center;
  gap: 40px;
  padding-top: 22px;
  padding-bottom: 22px;
}

.site-nav a {
  font-size: 16px;
  color: var(--color-text);
  opacity: 0.85;
}

.site-nav a:hover { opacity: 1; }

/* ---------- Hero (homepage) ---------- */

.hero {
  position: relative;
  padding: 80px 0 60px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: -1;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-hero-overlay);
}

/* Panorama zone: the scrolling 360 image sits behind the intro and the
   top of the project cards, fading to the page background */
.hero-zone { position: relative; isolation: isolate; overflow-x: clip; }
.hero-zone > .hero-pano {
  inset: 0 0 auto 0;
  height: 580px;
  overflow: hidden;
}

.hero-zone > .hero-pano::after {
  background: linear-gradient(to bottom,
    rgba(255,255,255,0.55) 0%,
    rgba(255,255,255,0.6) 80%,
    var(--color-bg) 100%);
}
.hero-zone .hero { overflow: visible; padding: 120px 0 90px; }
.hero-zone .divider { padding-top: 0; }
.hero-zone .divider .wrap { border-top: 0; padding-top: 0; }
.hero-zone .hl {
  background: rgba(255,255,255,0.9);
  /* half a pixel extra each side so neighbouring lines overlap instead of showing a hairline seam */
  padding: calc(0.14em + 0.5px) 10px;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
/* line height = highlight height, so the highlighted lines touch */
.hero-zone .hero p { line-height: 1.5; }
.hero-zone .hero h1 { font-size: 40px; line-height: 1.5; margin-bottom: 0; }
.hero-zone .hero .wrap { max-width: var(--content-max-width); }
.hero-zone .hero h1 .hl { padding-top: calc(0.15em + 0.5px); padding-bottom: calc(0.15em + 0.5px); }
.project-grid .project-card {
  padding: 0;
  gap: 0;
  border-radius: 12px;
  /* translucent dark edge over the card's own colour = a slightly darker shade of it */
  border: 5px solid rgba(0,0,0,0.09);
  box-shadow: 0 14px 40px rgba(0,0,0,0.14);
}
.project-grid .project-card img {
  border-radius: 0;
  box-shadow: none;
  height: 240px;
}
.project-grid .project-card > div { padding: 22px 26px 26px; }

/* Panorama slideshow (assets/js/pano.js moves the tracks and cross-fades the layers) */
.hero-pano .pano-track {
  display: flex;
  height: 100%;
  width: max-content;
  will-change: transform;
}
.hero-pano img { height: 100%; width: auto; max-width: none; display: block; }
.hero-pano img.mirrored { transform: scaleX(-1); }
.hero-pano .pano-layer {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 2500ms ease;
}
.hero-pano .pano-layer.on { opacity: 1; }

.pano-picker {
  position: absolute;
  top: 20px;
  right: 24px;
  z-index: 2;
  display: flex;
  gap: 14px;
}
.pano-picker button {
  position: relative;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: rgba(255,255,255,0.75);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transition: background 200ms ease, transform 200ms ease;
}
.pano-picker button:hover { background: #fff; transform: scale(1.08); }
.pano-picker svg {
  position: absolute;
  inset: -5px;
  width: calc(100% + 10px);
  height: calc(100% + 10px);
  transform: rotate(-90deg);
  overflow: visible;
  filter: drop-shadow(0 0 1.5px rgba(0,0,0,0.45));
  pointer-events: none;
}
/* countdown ring (white) on the panorama showing while rotating; pinned = solid black ring */
.pano-picker .ring { fill: none; stroke: #fff; stroke-width: 3; opacity: 0; }
.pano-picker button.is-showing .ring { opacity: 1; }
.pano-picker button[aria-pressed="true"] { background: #fff; }
.pano-picker button[aria-pressed="true"] .ring { opacity: 1; stroke: #111; }
.pano-picker button:focus-visible { outline: 2px solid #111; outline-offset: 2px; }
.pano-caption {
  position: absolute;
  z-index: 2;
  white-space: nowrap;
  pointer-events: none;
  font-size: 12.5px;
  padding: 3px 8px;
  background: rgba(255,255,255,0.9);
  color: var(--color-text-strong);
}

.hero .wrap { max-width: 900px; }

.hero h1 { font-size: 56px; margin-bottom: 20px; }
.hero p { font-size: 18px; max-width: 640px; }

/* ---------- Section header hero (case studies) ---------- */

.case-hero {
  padding: var(--section-padding) 0;
}

.case-hero .wrap {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 2fr;
  gap: 48px;
  align-items: center;
}

.case-hero img {
  border-radius: var(--radius);
  width: 100%;
  height: 420px;
  object-fit: cover;
  object-position: top;
}

.case-hero h1 { font-size: 40px; margin-bottom: 16px; }
.case-hero .case-hero-text p { font-size: 18px; color: var(--color-text); }

@media (max-width: 760px) {
  .case-hero .wrap { grid-template-columns: 1fr; }
}

/* ---------- Divider / section heading ---------- */

.divider {
  padding-top: var(--section-padding);
}

.divider .wrap {
  border-top: 1px solid var(--color-border);
  padding-top: 24px;
}

.divider h2 { font-size: 26px; margin: 0; }

/* ---------- Project grid ---------- */

.project-grid {
  padding: 30px 0 var(--section-padding);
}

.project-grid .grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.project-card {
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  background: #f2f2f2;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 20px;
  transition: transform 180ms ease;
}

.project-card:hover { transform: translateY(-2px); }

.project-card img {
  border-radius: var(--radius);
  box-shadow: 0 12px 30px rgba(0,0,0,0.18);
  width: 100%;
  height: 200px;
  object-fit: cover;
  object-position: top center;
}

.project-card .project-title {
  font-size: 19px;
  font-weight: 500;
  color: var(--color-text-strong);
  margin-bottom: 6px;
}

.project-card .project-subtitle {
  font-size: 15px;
  color: var(--color-text-muted);
  line-height: 1.4;
}

@media (max-width: 760px) {
  .project-grid .grid { grid-template-columns: 1fr; }
}

/* ---------- Columns ---------- */

.columns { padding: var(--section-padding) 0; }

.columns .grid {
  display: grid;
  gap: 40px;
}

.columns .grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.columns .grid.cols-3 { grid-template-columns: repeat(3, 1fr); }

.columns h4 { font-size: 15px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--color-text-muted); font-weight: 600; margin-bottom: 14px; }
.columns h2 { font-size: 22px; margin-bottom: 12px; }
.columns p { font-size: 16px; }
.columns li { font-size: 16px; }

@media (max-width: 760px) {
  .columns .grid.cols-2, .columns .grid.cols-3 { grid-template-columns: 1fr; }
}

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

.process { padding: var(--section-padding) 0 20px; }

.process-steps {
  display: flex;
  justify-content: space-between;
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  position: relative;
}

.process-steps::before {
  content: "";
  position: absolute;
  top: 15px;
  left: 30px;
  right: 30px;
  height: 1px;
  background: var(--color-border);
  z-index: 0;
}

.process-steps li {
  flex: 1;
  text-align: center;
  font-size: 13px;
  color: var(--color-text-muted);
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 0 8px;
}

.process-steps .step-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  background: var(--color-bg);
  margin: 0 auto 10px;
  font-size: 13px;
  color: var(--color-text);
}

/* ---------- Text and media ---------- */

.text-media {
  padding: var(--section-padding) 0;
}

.text-media .wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}

.text-media.media-right .media-col { order: 2; }
.text-media.media-right .text-col { order: 1; }

.text-media figure { margin: 0; }
.text-media img { border-radius: var(--radius); width: 100%; }
.text-media figcaption {
  font-size: 13px;
  color: var(--color-text-muted);
  margin-top: 10px;
  font-style: italic;
}

.text-media h3 { font-size: 24px; margin-bottom: 16px; }
.text-media p { font-size: 16px; }
.text-media ul { margin: 0 0 1em; padding-left: 20px; }
.text-media li { font-size: 16px; }

@media (max-width: 760px) {
  .text-media .wrap { grid-template-columns: 1fr; }
  .text-media.media-right .media-col,
  .text-media.media-right .text-col { order: initial; }
}

/* ---------- Media block ---------- */

.media-block { padding: 20px 0 var(--section-padding); text-align: center; }
.media-block img { margin: 0 auto; border-radius: var(--radius); max-width: 100%; }
.media-block figcaption {
  font-size: 13px;
  color: var(--color-text-muted);
  margin-top: 12px;
  font-style: italic;
}

/* ---------- Text block ---------- */

.text-block { padding: var(--section-padding) 0; text-align: center; }
.text-block .wrap { max-width: 720px; }
.text-block p { font-size: 17px; }

/* ---------- Gallery (design process collage) ---------- */

.gallery {
  padding: 40px 0;
  overflow: hidden;
}

.gallery-track {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.gallery-track img {
  width: 160px;
  height: 210px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
  transform: rotate(var(--r, 0deg));
}

.gallery-track img:nth-child(odd) { --r: -3deg; }
.gallery-track img:nth-child(even) { --r: 2deg; }

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

.contact { padding: var(--section-padding) 0; }

.contact .wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.contact-plain .wrap { grid-template-columns: 1fr; }
/* same rhythm as the other section headings: line, 24px, heading */
.contact-plain { padding-top: 0; }
.contact-plain h2 { font-size: 26px; margin: 0 0 12px; }
.contact-plain p { max-width: 640px; }
.contact img { border-radius: var(--radius); width: 100%; object-fit: cover; }

.contact h2 { font-size: 24px; }
.contact p { font-size: 15px; color: var(--color-text-muted); }

.contact form { display: flex; flex-direction: column; gap: 16px; margin-top: 20px; }

.contact label {
  display: block;
  font-size: 13px;
  color: var(--color-text-muted);
  margin-bottom: 6px;
}

.contact input,
.contact textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-family: var(--font-family);
  font-size: 15px;
  color: var(--color-text);
  background: var(--color-bg);
}

.contact textarea { min-height: 110px; resize: vertical; }

.btn {
  display: inline-block;
  padding: 12px 26px;
  background: var(--color-text-strong);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  align-self: flex-start;
}

.btn:hover { opacity: 0.85; }

@media (max-width: 760px) {
  .contact .wrap { grid-template-columns: 1fr; }
}

/* ---------- Results / key wins & learnings shared with .columns ---------- */

/* ---------- Related case studies ---------- */

.related { padding: var(--section-padding) 0; }
.related h2 { text-align: center; font-size: 26px; margin-bottom: 32px; }

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

.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 30px 0;
  margin-top: 40px;
}

.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.site-footer nav { display: flex; gap: 28px; }
.site-footer a { font-size: 14px; color: var(--color-text); opacity: 0.75; }
.site-footer a:hover { opacity: 1; }

/* ---------- Password gate ---------- */

.password-gate {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
}

.password-gate .wrap { max-width: 360px; }
.password-gate .wrap { max-width: 520px; }
.password-gate input[type=password] { font: inherit; font-size: 16px; padding: 12px 14px; border: 1px solid #ccc; border-radius: 8px; text-align: center; }
.password-gate .btn { align-self: center; }
.password-gate h2 { font-size: 22px; margin-bottom: 12px; }
.password-gate .gate-intro { font-size: 16px; color: var(--color-text-muted); line-height: 1.5; margin-bottom: 24px; }
.password-gate .gate-intro a { color: var(--color-text-strong); text-decoration: underline; }
.password-gate form { display: flex; flex-direction: column; gap: 14px; }
.password-gate .error { color: #b23; font-size: 14px; display: none; }
.password-gate.show-error .error { display: block; }
.password-gate.unlocked { display: none; }
.gated-content { display: none; }
.gated-content.unlocked { display: block; }

/* ---------- Design process timeline ---------- */

.timeline { padding: 10px 0 0; }
.tl-era:last-child { padding-bottom: 0; }
.timeline-intro { font-size: 18px; max-width: 720px; margin: 0 0 40px; }
.tl { list-style: none; margin: 0; padding: 0; position: relative; }
.tl-era {
  display: grid;
  grid-template-columns: 180px 1fr;
  column-gap: 40px;
  align-items: baseline; /* date sits on the title's baseline, place on the paragraph's first line */
  padding-bottom: 44px;
}
.tl-date { font-weight: 600; font-size: 16px; text-align: right; }
.tl-place { font-size: 14px; color: var(--color-text-muted); text-align: right; }
.tl-era h3 { font-size: 22px; margin: 0 0 8px; }
.tl-body p { font-size: 16px; max-width: 680px; margin: 0 0 10px; }
.tl-strip { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; max-height: 96px; overflow: hidden; }
.tl-strip img { height: 96px; width: auto; border-radius: 6px; box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
.tl-links { font-size: 14px; color: var(--color-text-muted); margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tl-links a { color: var(--color-text-strong); background: #f3f3f3; border-radius: 999px; padding: 4px 12px; }
.tl-links a:hover { background: #e6e6e6; }
.tl-steps { margin: 12px 0 0; padding-left: 22px; max-width: 680px; }
.tl-steps li { font-size: 16px; margin-bottom: 8px; }

@media (max-width: 760px) {
  .tl-era { grid-template-columns: 1fr; }
  .tl-date, .tl-place { text-align: left; }
}

/* ---------- Case study back link (top; the footer repeats it) ---------- */
.back-link { padding: 18px 0; font-size: 15px; }
.back-link a { color: var(--color-text-strong); }
.back-link a:hover, .site-footer a:hover { text-decoration: underline; }
