/* Lindsay Wright: site styles.
   Design tokens first. Change the look of the whole site here. */
:root {
  --color-bg: #e8e1ff;          /* lavender page background */
  --color-text: #000;           /* headings and body text */
  --color-text-soft: #333;      /* default text outside content areas */
  --color-primary: #3eb484;     /* green: links on hover, buttons, arrows, "Contact" heading */
  --color-link: #c36;           /* pink link colour */
  --color-link-hover: #336;
  --color-contact: #1a1792;     /* dark blue contact details */
  --color-divider: #d5d8dc;

  --font-heading: "Gilbert", sans-serif;     /* bold display font (name, "Contact") */
  --font-body: "Neue Kabel", sans-serif;     /* everything else */
  --font-system: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";

  --content-width: 1140px;      /* widest the content gets */
  --radius-button: 3px;
}

@font-face {
  font-family: "Gilbert";
  font-style: normal;
  font-weight: 700;
  src: url("/assets/fonts/gilbert-bold.woff") format("woff"), url("/assets/fonts/gilbert-bold.ttf") format("truetype");
}
@font-face {
  font-family: "Neue Kabel";
  font-style: normal;
  font-weight: 400;
  src: url("/assets/fonts/neue-kabel-medium.woff") format("woff"), url("/assets/fonts/neue-kabel-medium.ttf") format("truetype");
}

/* ---------- Base ---------- */
*, ::before, ::after { box-sizing: border-box; }
html { line-height: 1.15; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background-color: var(--color-bg);
  color: var(--color-text-soft);
  font-family: var(--font-system);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
h1, h2, p { margin: 0; }
p { margin-block-end: .9rem; }
a { color: var(--color-link); text-decoration: none; background-color: transparent; }
a:hover, a:active { color: var(--color-link-hover); }
img { border-style: none; height: auto; max-width: 100%; vertical-align: middle; }
ul { list-style: none; margin: 0; padding: 0; }
a:focus-visible { box-shadow: 0 0 0 4px #fff; outline: 2px solid #000; outline-offset: 2px; }

.screen-reader-text {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; word-wrap: normal;
}
.skip-link:focus {
  clip: auto; width: auto; height: auto; margin: 0; padding: 15px 23px 14px;
  top: 5px; left: 5px; z-index: 100000; display: block;
  background: #f1f1f1; color: #21759b; font-size: 14px; font-weight: 600;
  line-height: normal; box-shadow: 0 0 2px 2px rgba(0, 0, 0, .6);
}

/* A full-width band with its content centred at most --content-width wide. */
.band { display: flex; flex-direction: column; padding: 0 10px; }
.band__inner {
  display: flex; flex-direction: column; gap: 20px;
  width: 100%; max-width: min(100%, var(--content-width));
  margin: 0 auto; padding: 10px 0;
}
.group { display: flex; flex-direction: column; gap: 20px; padding: 10px; }
@media (max-width: 1024px) { :root { --content-width: 1024px; } }
@media (max-width: 767px) { :root { --content-width: 767px; } }

/* ---------- Header ---------- */
.site-header { padding: 0 15px; }
.site-header__inner {
  display: flex; flex-direction: column; align-items: center; gap: 20px;
  max-width: min(100%, var(--content-width)); margin: 0 auto;
  padding: 40px 0 30px;
}
.site-title {
  margin: 0; font-family: var(--font-heading); font-size: 50px; font-weight: 700; line-height: 1;
  color: var(--color-text); text-align: center;
}
.site-title a { color: inherit; }

.menu ul { display: flex; flex-wrap: wrap; justify-content: center; line-height: normal; }
.menu li { display: flex; position: relative; }
.menu a {
  position: relative; display: flex; align-items: center; flex-grow: 1;
  padding: 13px 20px; white-space: nowrap;
  font-family: var(--font-body); font-size: 25px; line-height: 20px;
  color: var(--color-text); transition: .4s;
}
.menu li:not(:last-child) > a { margin-inline-end: 2.5px; }
.menu li:not(:first-child) > a { margin-inline-start: 2.5px; }
/* green underline that fades in on hover */
.menu a::after {
  content: ""; position: absolute; left: 0; bottom: 0; z-index: 2;
  width: 100%; height: 3px; background-color: var(--color-primary);
  opacity: 0; transition: .3s cubic-bezier(.58, .3, .005, 1);
}
.menu a:hover, .menu a:focus, .menu a.is-active { color: var(--color-primary); }
.menu a:hover::after, .menu a:focus::after, .menu a.is-active::after { opacity: 1; }

/* ---------- Project page text ---------- */
.intro { font-family: var(--font-body); font-size: 22px; line-height: 1.5; color: var(--color-text); margin: 0 15%; }
@media (max-width: 1024px) { .intro { margin: 0; } }

/* ---------- Gallery (laid out by /assets/site.js) ---------- */
.gallery { position: relative; }
.gallery__item { display: block; position: relative; overflow: hidden; color: var(--color-link); }
.gallery__item img { display: block; width: 100%; transform-origin: center top; }
.gallery__item::after {
  content: ""; position: absolute; inset: 0;
  transition: background-color .8s;
}
.gallery__item:hover::after, .gallery__item:focus::after { background-color: rgba(0, 0, 0, .5); }
/* Before the script runs (or without it), show photos in simple columns. */
html:not(.js) .gallery { columns: 3; column-gap: 20px; }
html:not(.js) .gallery__item { break-inside: avoid; margin-bottom: 20px; }
/* Photos fade and grow in as they load, like the old site. */
.js .gallery__item img { transition: opacity .8s, transform .8s; }
.js .gallery__item img:not(.is-loaded) { opacity: 0; transform: scale(.5); }
.js .gallery__item { position: absolute; }

/* ---------- Previous / Next links ---------- */
.post-nav { display: flex; overflow: hidden; }
.post-nav__link { width: calc(50% - .5px); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.post-nav__link a { display: flex; align-items: center; gap: 2px; max-width: 100%; }
.post-nav__link--next { text-align: end; }
.post-nav__link--next a { justify-content: flex-end; }
.post-nav__arrow { display: flex; font-size: 30px; color: var(--color-primary); fill: var(--color-primary); }
.post-nav__arrow svg { width: 1em; height: 1em; }
.post-nav__text { display: flex; flex-direction: column; overflow: hidden; }
.post-nav__link--next .post-nav__text { text-align: end; }
.post-nav__label, .post-nav__title { overflow: hidden; text-overflow: ellipsis; font-family: var(--font-body); }
.post-nav__label { font-size: 35px; text-transform: uppercase; color: var(--color-primary); }
.post-nav__title { font-size: 26px; color: var(--color-text); }
.post-nav__separator-wrapper { text-align: center; }
.post-nav__separator { width: 1px; height: 100%; margin: 0 auto; background-color: var(--color-divider); }
@media (max-width: 767px) {
  .post-nav__label { font-size: 25px; }
  .post-nav__title { font-size: 16px; }
}

/* ---------- Home: project tiles ---------- */
.tiles { padding: 0 15px; }
.tiles__grid {
  display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(4, 1fr); gap: 30px;
  max-width: min(100%, var(--content-width)); margin: 0 auto; height: 100%;
}
@media (max-width: 767px) { .tiles__grid { grid-template-columns: 1fr; } }
.tile { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.tile__image { display: inline-block; text-align: center; }
.tile__image img { display: inline-block; width: 100%; height: 200px; object-fit: cover; transition-duration: .4s; }
.tile__image--top img { object-position: top center; }
.tile:hover .tile__image img { opacity: .7; }
.tile__title {
  font-family: var(--font-body); font-size: 26px; font-weight: 400; line-height: 1;
  text-align: center; color: var(--color-text);
}
.tile__title a { color: inherit; transition-duration: .3s; }
.tile__title a:hover, .tile__title a:focus { color: var(--color-primary); }

/* ---------- Home: contact ---------- */
.contact { padding: 40px 15px; }
.contact__inner {
  display: flex; flex-direction: column; gap: 20px;
  max-width: min(100%, var(--content-width)); margin: 0 auto;
}
.contact__heading { font-family: var(--font-heading); font-size: 36px; font-weight: 700; line-height: 1; color: var(--color-primary); }
.contact__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.contact__about { display: flex; flex-direction: row; gap: 20px; }
.contact__photo { flex: 0 0 auto; width: 31.449%; text-align: center; }
.contact__photo a { display: inline-block; }
.contact__photo img { display: inline-block; width: 200px; border-radius: 50%; }
.contact__text { flex: 0 0 auto; width: 65.009%; font-family: var(--font-body); font-size: 20px; color: var(--color-text); }
.contact__list { display: flex; flex-direction: column; text-align: right; }
.contact__list li { display: flex; align-items: center; justify-content: flex-end; }
.contact__list li:not(:last-child) { padding-block-end: 5px; }
.contact__list li:not(:first-child) { margin-block-start: 5px; }
.contact__list a { display: flex; align-items: center; justify-content: flex-end; width: 100%; font-family: var(--font-body); font-size: 20px; }
.contact__icon { display: flex; }
.contact__icon svg { width: 14px; height: 14px; margin: 0 3.5px 0 0; fill: var(--color-primary); transition: fill .3s; }
.contact__label { align-self: center; padding-inline-start: 5px; color: var(--color-contact); transition: color .3s; }
@media (max-width: 1024px) {
  .contact__grid { grid-template-columns: 1fr; }
  .contact__list { text-align: left; }
  .contact__list li, .contact__list a { justify-content: flex-start; }
}
@media (max-width: 767px) {
  .contact__about { flex-direction: column; justify-content: center; align-items: center; }
  .contact__photo { width: 50%; }
  .contact__text { width: 100%; }
}

/* ---------- Footer ---------- */
.site-footer { padding: 30px 15px 50px; }
.site-footer__inner {
  display: grid; grid-template-columns: repeat(3, 1fr); align-items: end; justify-items: center; gap: 20px;
  max-width: min(100%, var(--content-width)); min-height: 100px; margin: 0 auto;
}
.site-footer__copyright { width: 100%; align-self: end; text-align: left; font-family: var(--font-body); line-height: 14px; color: var(--color-text); }
.button {
  display: inline-block; padding: 12px 24px; border-radius: var(--radius-button);
  background-color: var(--color-primary); color: #fff;
  font-family: var(--font-body); font-size: 15px; line-height: 1; text-align: center;
  transition: all .3s;
}
.button:hover, .button:focus { color: #fff; }
.site-footer__flower { text-align: right; }
.site-footer__flower img { display: inline-block; width: 100vw; height: 100px; object-fit: contain; object-position: center right; }
@media (max-width: 1024px) {
  .site-footer__copyright { width: auto; }
  .site-footer__flower { text-align: center; }
  .site-footer__flower img { width: 100%; }
}
@media (max-width: 767px) {
  .site-footer__inner { grid-template-columns: 1fr; }
  .site-footer__top { order: 99999; }
}

/* ---------- Embeds ---------- */
.figma-embed iframe { border: 1px solid rgba(0, 0, 0, .1); max-width: 100%; }

/* ---------- Photo viewer (lightbox, opened by /assets/site.js) ---------- */
.lightbox {
  --ui: hsla(0, 0%, 93%, .9);
  position: fixed; inset: 0; z-index: 9999;
  background-color: rgba(0, 0, 0, .8);
  user-select: none; -webkit-user-select: none;
}
.lightbox__content { position: absolute; inset: 0; overflow: hidden; animation: lightbox-in .3s both; }
@keyframes lightbox-in { from { opacity: 0; transform: scale3d(.3, .3, .3); } 50% { opacity: 1; } }
:where(.lightbox) button { appearance: none; background: none; border: 0; padding: 0; margin: 0; color: var(--ui); cursor: pointer; font: inherit; }
:where(.lightbox) svg { display: block; fill: var(--ui); transition: fill .3s; }
.lightbox button:hover svg, .lightbox button:focus-visible svg { fill: #fff; }
.lightbox__close { position: absolute; top: 0; right: .75em; z-index: 11; display: flex; margin-top: 13px; padding: .25em; font-size: 20px; line-height: 1; }
.lightbox__close svg { width: 1em; height: 1em; }
.lightbox__header {
  position: absolute; top: 0; left: 0; z-index: 10; width: 100%;
  display: flex; flex-direction: row-reverse; align-items: center;
  padding: 15px 2.6em 15px 1em; font-size: 20px; line-height: 1.5; color: var(--ui); transition: .3s;
}
.lightbox__tool { margin: 0 .35em; padding: .25em; }
.lightbox__tool svg { width: 1em; height: 1em; }
.lightbox__counter { margin-inline-end: auto; font-size: .75em; color: #fff; font-family: var(--font-system); }
.lightbox__track { display: flex; gap: 100px; height: 100%; transition: transform .3s ease; }
.lightbox__slide { flex: 0 0 100%; display: flex; align-items: center; justify-content: center; height: 100%; padding: 70px; }
.lightbox__frame { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.lightbox__image {
  max-width: 100%; max-height: 100%; border-radius: 2px;
  box-shadow: 0 0 30px rgba(0, 0, 0, .3), 0 0 8px -5px rgba(0, 0, 0, .3);
  transition: transform .3s; touch-action: none;
}
.lightbox__arrow {
  position: absolute; top: 0; z-index: 1; display: flex; align-items: center; justify-content: center;
  width: 15%; height: 100%; font-size: 25px; transition: all .3s;
}
.lightbox__arrow svg { width: 1em; height: 1em; }
.lightbox__arrow--prev { left: 0; }
.lightbox__arrow--next { right: 0; }
.lightbox.is-zoomed .lightbox__header { background-color: rgba(0, 0, 0, .5); }
.lightbox.is-zoomed .lightbox__arrow { opacity: 0; pointer-events: none; }
.lightbox.is-zoomed .lightbox__image { cursor: move; }
.lightbox__footer { position: fixed; bottom: 0; left: 0; z-index: 5; width: 100%; padding: 15px 20px; text-align: center; color: var(--ui); font-family: var(--font-system); }
.lightbox__title { margin: 0; font-size: 16px; font-weight: 700; line-height: 1.5; }
/* share menu */
.lightbox__share-menu { position: absolute; width: 0; height: 0; overflow: hidden; background-color: transparent; transition: background-color .4s; }
.lightbox__share-links {
  position: absolute; top: 3em; right: 2.8em; min-width: 200px; padding: 14px 20px;
  background-color: #fff; border-radius: 3px; box-shadow: 0 4px 15px rgba(0, 0, 0, .3);
  opacity: 0; transform: scale(0); transform-origin: 90% 10%; transition: all .25s .1s;
}
.lightbox__share-links::before {
  content: ""; position: absolute; top: 1px; right: .5em; display: block;
  border: .45em solid transparent; border-bottom-color: #fff; transform: translateY(-100%) scaleX(.7);
}
.lightbox__share-links a {
  display: flex; align-items: center; color: #0c0d0e; font-family: var(--font-system); font-size: 12px; line-height: 2.5;
  opacity: 0; transition: opacity .5s .1s;
}
.lightbox__share-links a:hover { color: #000; }
.lightbox__share-links svg { width: 1.25em; height: 1.25em; margin-inline-end: .75em; }
.lightbox__share-links .lightbox__facebook { fill: #3b5998; }
.lightbox__share-links .lightbox__twitter { fill: #1da1f2; }
.lightbox__share-links .lightbox__pinterest { fill: #bd081c; }
.lightbox__share-links .lightbox__download { fill: #9da5ae; }
.lightbox.is-sharing .lightbox__share-menu { top: 0; left: 0; width: 100vw; height: 100vh; background-color: rgba(0, 0, 0, .5); cursor: default; }
.lightbox.is-sharing .lightbox__share-links { transform: scale(1); }
.lightbox.is-sharing .lightbox__share-links, .lightbox.is-sharing .lightbox__share-links a { opacity: 1; }
@media (max-width: 767px) {
  .lightbox__slide { padding: 70px 0; }
  .lightbox__arrow { width: 20%; }
  .lightbox__arrow--prev { justify-content: flex-start; }
  .lightbox__arrow--next { justify-content: flex-end; }
}
