/* Gwen Sands — site styles */

:root {
  --paper: #f4efe6;
  --paper-deep: #eae2d3;
  --ink: #191714;
  --muted: #62594d;
  --accent: #9ccc3c;
  --accent-deep: #4f8212;
  --line: rgba(25, 23, 20, 0.16);
  --serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: "Instrument Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --gutter: clamp(20px, 5vw, 72px);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: clamp(1.05rem, 0.98rem + 0.3vw, 1.2rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: var(--accent);
  color: var(--ink);
}

a {
  color: inherit;
}

p {
  margin: 0 0 1em;
  max-width: 62ch;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 50;
  letter-spacing: -0.025em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}

em,
.it {
  font-style: italic;
}

.wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding-inline: var(--gutter);
}

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  padding: 10px 16px;
  border-radius: 999px;
  transition: top 0.2s;
}

.skip:focus {
  top: 12px;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

.site-header.scrolled {
  border-bottom-color: var(--line);
}

.bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-block: 14px;
}

.brand {
  font-family: var(--serif);
  font-size: 1.45rem;
  font-variation-settings: "opsz" 40, "SOFT" 100;
  letter-spacing: -0.02em;
  text-decoration: none;
  white-space: nowrap;
}

.brand i {
  color: var(--accent-deep);
  font-style: normal;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px clamp(12px, 2.4vw, 32px);
  font-size: 0.98rem;
}

.nav a:not(.btn) {
  position: relative;
  text-decoration: none;
  padding: 6px 0;
}

.nav a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.nav a:not(.btn):hover::after,
.nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

/* ---------- Buttons and links ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  padding: 0.85em 1.5em;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.3s var(--ease);
}

.btn::after {
  content: "\2192";
  transition: transform 0.3s var(--ease);
}

.btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink);
  transform: translateY(-2px);
}

.btn:hover::after {
  transform: translateX(5px);
}

.btn.ghost {
  background: transparent;
  color: var(--ink);
}

.btn.ghost:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.btn.small {
  padding: 0.55em 1.1em;
  font-size: 0.92rem;
}

.btn.small::after {
  content: none;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 2rem;
}

.link {
  display: inline-block;
  font-weight: 600;
  text-decoration: none;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-repeat: no-repeat;
  background-size: 100% 2px;
  background-position: 0 100%;
  padding-bottom: 3px;
  transition: background-size 0.35s var(--ease);
}

.link::after {
  content: " \2192";
  display: inline-block;
  margin-left: 0.3em;
  transition: transform 0.3s var(--ease);
}

.link:hover {
  background-size: 100% 0.5em;
}

.link:hover::after {
  transform: translateX(4px);
}

.link.out::after {
  content: " \2197";
}

.link.plain::after {
  content: none;
}

/* ---------- Home hero ---------- */

.hero {
  position: relative;
  padding-block: clamp(48px, 9vw, 120px) clamp(56px, 8vw, 110px);
}

.blob {
  position: absolute;
  z-index: -1;
  top: 2%;
  right: -8%;
  width: min(58vw, 720px);
  aspect-ratio: 1;
  border-radius: 46% 54% 60% 40% / 48% 42% 58% 52%;
  background: radial-gradient(circle at 35% 35%, #dcf0a0 0%, var(--accent) 45%, #c3d93a 100%);
  opacity: 0.9;
  filter: blur(2px);
  transform: translate(var(--mx, 0), var(--my, 0));
  animation: morph 16s ease-in-out infinite alternate;
  transition: transform 0.8s var(--ease);
}

@keyframes morph {
  0% {
    border-radius: 46% 54% 60% 40% / 48% 42% 58% 52%;
    rotate: 0deg;
  }
  50% {
    border-radius: 60% 40% 44% 56% / 40% 58% 42% 60%;
  }
  100% {
    border-radius: 40% 60% 52% 48% / 58% 46% 54% 42%;
    rotate: 24deg;
  }
}

.hero h1 {
  font-size: clamp(4.4rem, 19vw, 17rem);
  line-height: 0.86;
  letter-spacing: -0.045em;
  font-variation-settings: "opsz" 144, "SOFT" 100;
}

.hero h1 .word {
  display: block;
  overflow: hidden;
  padding-bottom: 0.08em;
}

.hero h1 .word > span {
  display: block;
}

.hero h1 .word:nth-child(2) {
  font-style: italic;
  padding-left: 0.6em;
}

.js .hero h1 .word > span {
  transform: translateY(105%);
  animation: rise 1.1s var(--ease) 0.1s forwards;
}

.js .hero h1 .word:nth-child(2) > span {
  animation-delay: 0.25s;
}

@keyframes rise {
  to {
    transform: none;
  }
}

.hero h1,
.hero .lead,
.hero .intro,
.hero .actions {
  position: relative;
  z-index: 1;
}

.portrait {
  position: absolute;
  z-index: 0;
  top: clamp(24px, 4vw, 56px);
  right: var(--gutter);
  width: min(35vw, 480px);
  margin: 0;
}

.portrait img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 999px 999px 36px 36px;
}

.hero .lead {
  margin-top: clamp(24px, 4vw, 48px);
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3.2vw, 2.6rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  max-width: 22ch;
}

.hero .intro {
  margin-top: 1.2rem;
  max-width: 46ch;
}

.js .fade {
  opacity: 0;
  animation: fade-up 0.9s var(--ease) forwards;
  animation-delay: calc(0.55s + var(--i, 0) * 0.12s);
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.ring {
  position: absolute;
  right: var(--gutter);
  bottom: clamp(40px, 7vw, 96px);
  width: clamp(120px, 14vw, 180px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  transition: background 0.3s, color 0.3s, transform 0.4s var(--ease);
}

.ring svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: spin 18s linear infinite;
}

.ring text {
  fill: currentColor;
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.ring .arrow {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1;
  transition: transform 0.4s var(--ease);
}

.ring:hover {
  background: var(--accent);
  color: var(--ink);
  transform: scale(1.06);
}

.ring:hover .arrow {
  transform: translate(4px, -4px);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

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

.section {
  padding-block: clamp(56px, 8vw, 120px);
  border-top: 1px solid var(--line);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.7em;
  margin: 0 0 clamp(24px, 4vw, 48px);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-family: var(--sans);
  line-height: 1.3;
}

.eyebrow::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}

.h-lg {
  font-size: clamp(2.2rem, 5.4vw, 4.4rem);
}

.h-md {
  font-size: clamp(1.7rem, 3.2vw, 2.6rem);
  line-height: 1.08;
}

/* Figures */

.figures {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.4vw, 32px);
  list-style: none;
  margin: 0;
  padding: 0;
}

.figures li {
  padding: clamp(22px, 3vw, 40px);
  border-radius: 28px;
  background: var(--paper-deep);
  transition: transform 0.5s var(--ease), background 0.4s;
}

.figures li:hover {
  transform: translateY(-6px) rotate(-0.6deg);
  background: #e2d8c5;
}

.figures li:last-child {
  background: var(--ink);
  color: var(--paper);
}

.figures strong {
  display: block;
  font-family: var(--serif);
  font-weight: 400;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  font-size: clamp(2.6rem, 5.6vw, 5rem);
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 0.35em;
  white-space: nowrap;
}

.figures li:last-child strong {
  color: var(--accent);
}

.figures span {
  display: block;
  max-width: 30ch;
}

/* Role rows */

.roles {
  border-bottom: 1px solid var(--line);
}

.role {
  position: relative;
  display: grid;
  grid-template-columns: 5rem minmax(0, 1fr) minmax(0, 1.3fr);
  gap: 16px clamp(20px, 4vw, 64px);
  align-items: start;
  padding: clamp(28px, 4vw, 52px) 0;
  border-top: 1px solid var(--line);
}

.role .num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--muted);
  padding-top: 0.5em;
}

.role h2 {
  font-size: clamp(2.2rem, 5vw, 4.2rem);
  transition: transform 0.5s var(--ease), color 0.3s;
}

.role:hover h2 {
  transform: translateX(14px);
  font-style: italic;
}

.role p {
  margin-bottom: 1.1em;
}

/* Subscribe band */

.band {
  background: var(--accent);
  color: var(--ink);
  padding-block: clamp(56px, 8vw, 120px);
  overflow: hidden;
}

.band h2 {
  font-size: clamp(2.6rem, 8vw, 7rem);
  line-height: 0.95;
  font-variation-settings: "opsz" 144, "SOFT" 100;
}

.band p {
  margin-top: 1.4rem;
  font-size: 1.15em;
  max-width: 44ch;
}

.band .btn:hover {
  background: var(--paper);
  border-color: var(--paper);
}

.band .link {
  background-image: linear-gradient(var(--ink), var(--ink));
}

.band .aside {
  margin-top: 2rem;
  margin-bottom: 0;
}

.marquee {
  display: flex;
  width: max-content;
  margin-bottom: clamp(32px, 5vw, 64px);
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.2rem, 2.4vw, 1.9rem);
  white-space: nowrap;
  animation: slide 38s linear infinite;
}

.marquee span {
  padding-right: 1.2em;
}

@keyframes slide {
  to {
    transform: translateX(-50%);
  }
}

/* ---------- Inner pages ---------- */

.page-head {
  position: relative;
  padding-block: clamp(48px, 8vw, 110px) clamp(40px, 6vw, 80px);
}

.page-head h1 {
  font-size: clamp(2.6rem, 7.4vw, 6.4rem);
  line-height: 0.96;
  letter-spacing: -0.035em;
  max-width: 16ch;
}

.page-head h1 em {
  color: var(--accent-deep);
}

.page-head .intro {
  margin-top: clamp(20px, 3vw, 36px);
  font-size: 1.2em;
  max-width: 50ch;
}

.dot {
  position: absolute;
  z-index: -1;
  top: clamp(24px, 5vw, 70px);
  right: var(--gutter);
  width: clamp(90px, 16vw, 240px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--accent);
  animation: float 9s ease-in-out infinite alternate;
}

.dot.half {
  border-radius: 999px 999px 0 0;
  aspect-ratio: 2 / 1;
}

.dot.square {
  border-radius: 22%;
}

@keyframes float {
  from {
    transform: translateY(0) rotate(0deg);
  }
  to {
    transform: translateY(22px) rotate(10deg);
  }
}

/* Track record entries */

.entries {
  border-bottom: 1px solid var(--line);
}

.entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  gap: 14px clamp(24px, 5vw, 80px);
  padding: clamp(28px, 4vw, 52px) 0;
  border-top: 1px solid var(--line);
}

.entry h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.9rem);
  line-height: 1.05;
}

.tag {
  display: inline-block;
  margin-top: 0.9em;
  padding: 0.3em 0.9em;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.entry p:last-child {
  margin-bottom: 0;
}

/* Skills */

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.chips li {
  padding: 0.55em 1.1em;
  border-radius: 999px;
  background: var(--paper-deep);
  font-size: 1rem;
  transition: background 0.3s, transform 0.3s var(--ease);
}

.chips li:hover {
  background: var(--accent);
  transform: translateY(-3px) rotate(-1.5deg);
}

/* Services */

.service {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 20px clamp(24px, 5vw, 80px);
  align-items: start;
  padding: clamp(32px, 5vw, 64px) 0;
  border-top: 1px solid var(--line);
}

.service h2 {
  font-size: clamp(1.9rem, 4vw, 3.4rem);
  margin-bottom: 0.5em;
}

.service .what {
  font-size: 1.15em;
}

.record {
  padding: clamp(20px, 2.6vw, 30px);
  border-radius: 24px;
  background: var(--paper-deep);
  font-size: 0.98em;
}

.record b {
  display: block;
  margin-bottom: 0.5em;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.record p {
  margin: 0;
}

/* Steps */

.dark {
  background: var(--ink);
  color: var(--paper);
  border-top: 0;
}

.dark .eyebrow {
  color: var(--paper);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(20px, 3vw, 48px);
  list-style: none;
  margin: clamp(28px, 4vw, 56px) 0 0;
  padding: 0;
  counter-reset: step;
}

.steps li {
  counter-increment: step;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(244, 239, 230, 0.3);
}

.steps li::before {
  content: counter(step);
  display: block;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(3.4rem, 7vw, 6rem);
  line-height: 1;
  color: var(--accent);
  margin-bottom: 0.2em;
}

.steps h3 {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  margin-bottom: 0.5em;
}

.steps p {
  margin: 0;
  opacity: 0.86;
}

.dark .btn {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink);
}

.dark .btn:hover {
  background: var(--paper);
  border-color: var(--paper);
}

.dark .link {
  color: var(--paper);
}

.dark .aside {
  margin-top: 1.6rem;
  margin-bottom: 0;
}

/* Now page */

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 20px clamp(24px, 5vw, 80px);
  align-items: start;
}

.feature .big {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.8vw, 2.3rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  max-width: 26ch;
}

.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(16px, 2.4vw, 32px);
  list-style: none;
  margin: clamp(24px, 4vw, 48px) 0 0;
  padding: 0;
}

.cards li {
  padding: clamp(24px, 3.4vw, 44px);
  border-radius: 28px;
  background: var(--paper-deep);
  transition: transform 0.5s var(--ease);
}

.cards li:nth-child(2) {
  background: var(--ink);
  color: var(--paper);
}

.cards li:hover {
  transform: translateY(-6px) rotate(0.6deg);
}

.cards h3 {
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  margin-bottom: 0.5em;
}

.cards p {
  margin: 0;
}

.photo {
  position: sticky;
  top: 96px;
  margin: 0;
}

.photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 36px 36px 999px 999px;
}

.beliefs h2 {
  margin-bottom: 0.5em;
}

.principles {
  list-style: none;
  margin: clamp(24px, 3vw, 40px) 0 0;
  padding: 0;
  counter-reset: principle;
}

.principles li {
  counter-increment: principle;
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr);
  gap: 0 12px;
  padding: clamp(20px, 2.6vw, 32px) 0;
  border-top: 1px solid var(--line);
}

.principles li::before {
  content: "0" counter(principle);
  font-family: var(--serif);
  font-style: italic;
  color: var(--accent-deep);
  font-size: 1.3rem;
  padding-top: 0.25em;
}

.principles h3 {
  font-size: clamp(1.6rem, 2.8vw, 2.3rem);
  margin-bottom: 0.4em;
}

.principles p {
  grid-column: 2;
  margin: 0;
}

.beliefs .close {
  margin: clamp(20px, 2.6vw, 32px) 0 0;
  padding-top: clamp(20px, 2.6vw, 32px);
  border-top: 1px solid var(--line);
}

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

.site-footer {
  background: var(--ink);
  color: var(--paper);
  padding-block: clamp(48px, 7vw, 96px) 36px;
}

.dark + .site-footer {
  border-top: 1px solid rgba(244, 239, 230, 0.2);
}

.site-footer .name {
  font-family: var(--serif);
  font-variation-settings: "opsz" 144, "SOFT" 100;
  font-size: clamp(3.4rem, 13vw, 11rem);
  line-height: 0.9;
  letter-spacing: -0.04em;
  margin: 0 0 clamp(28px, 4vw, 56px);
  max-width: none;
}

.site-footer .name em {
  color: var(--accent);
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px clamp(20px, 4vw, 56px);
  list-style: none;
  margin: 0;
  padding: 24px 0 0;
  border-top: 1px solid rgba(244, 239, 230, 0.25);
}

.foot-links a {
  text-decoration: none;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-repeat: no-repeat;
  background-size: 0 2px;
  background-position: 0 100%;
  padding-bottom: 3px;
  transition: background-size 0.35s var(--ease);
  overflow-wrap: anywhere;
}

.foot-links a:hover {
  background-size: 100% 2px;
}

/* ---------- Scroll reveal ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: calc(var(--i, 0) * 0.1s);
}

.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* ---------- Small screens ---------- */

@media (max-width: 820px) {
  .figures,
  .steps,
  .cards {
    grid-template-columns: 1fr;
  }

  .role,
  .entry,
  .service,
  .feature {
    grid-template-columns: 1fr;
  }

  .role .num {
    padding-top: 0;
  }

  .role:hover h2 {
    transform: none;
  }

  .portrait {
    position: relative;
    top: auto;
    right: auto;
    width: min(100%, 380px);
    margin-top: 36px;
  }

  .photo {
    position: static;
    max-width: 420px;
  }

  .ring {
    position: relative;
    right: auto;
    bottom: auto;
    margin-top: 36px;
  }

  .blob {
    width: 86vw;
    right: -34%;
    top: 0;
    opacity: 0.75;
  }

  .dot {
    opacity: 0.85;
    top: 16px;
    width: 84px;
  }
}

@media (max-width: 520px) {
  .nav {
    width: 100%;
    justify-content: space-between;
    font-size: 0.92rem;
  }

  .actions .btn {
    width: 100%;
    justify-content: center;
  }
}

/* ---------- Reduced motion ---------- */

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .js .reveal,
  .js .fade,
  .js .hero h1 .word > span {
    opacity: 1;
    transform: none;
  }
}

/* ---------- Page-head photos (Track Record, Consulting) ---------- */

.page-head.has-photo {
  display: grid;
  grid-template-columns: minmax(0, 1fr) min(30vw, 380px);
  gap: clamp(24px, 5vw, 72px);
  align-items: center;
}

.head-photo {
  position: relative;
  margin: 0;
}

.head-photo::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -8%;
  right: -8%;
  width: 62%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--accent);
  animation: float 9s ease-in-out infinite alternate;
}

.head-photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: 50% 14%;
  border-radius: 50%;
}

.head-photo.square::before,
.head-photo.square img {
  border-radius: 22%;
}

@media (max-width: 820px) {
  .page-head.has-photo {
    grid-template-columns: 1fr;
  }

  .head-photo {
    width: min(70%, 280px);
    margin-top: 28px;
  }
}
