/* ==========================================================
   DESIGN PLAYGROUND
   Bold lettering, interactive geometry, and accessible themes.
   ========================================================== */

:root {
  --paper: #f8f8f4;
  --ink: #151719;
  --muted: #60646b;
  --line: #d4d6d2;
  --surface: #eeefea;
  --accent: #d7331d;
  --accent-soft: #ffdfd5;
  --purple: var(--accent);
  --lime: var(--accent);
}

html.theme-dark {
  color-scheme: dark;
  --paper: #111418;
  --ink: #f5f5ef;
  --muted: #b5bcc4;
  --line: #3c424b;
  --surface: #1d232b;
  --accent-soft: #2a2423;
}

body {
  background: var(--paper);
}

button {
  color: inherit;
}

button:focus-visible,
a:focus-visible {
  outline-color: var(--accent);
}

.header {
  padding: 20px 5%;
  border-bottom: 1px solid var(--ink);
}

.brand-icon {
  background: none;
  color: var(--ink);
  width: auto;
  height: auto;
  font-size: 25px;
  letter-spacing: -1.9px;
  gap: 3px;
}

.brand-dot {
  display: inline-block;
  background: var(--accent);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  align-self: end;
  margin-bottom: 7px;
}

.brand {
  gap: 22px;
}

.brand>span:last-child {
  font-size: 13px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.brand small {
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
}

.header nav {
  font-size: 16px;
  gap: 30px;
}

.header nav a:hover {
  color: var(--accent);
}

.theme-toggle {
  display: flex;
  align-items: center;
  gap: 9px;
  background: none;
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 7px 14px;
  min-height: 42px;
  font-size: 16px;
}

.theme-toggle:hover {
  border-color: var(--ink);
}

.theme-symbol {
  font-size: 20px;
  line-height: 1;
}

.playground-hero {
  max-width: 1440px;
  margin: auto;
  padding: 22px 5% 0;
}

.hero-topline {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font: 13px/1.6 monospace;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.playground-intro {
  display: grid;
  grid-template-columns: 1.12fr 1fr;
  gap: 70px;
  padding: 35px 0 40px;
  border-top: 1px solid var(--ink);
  align-items: center;
}

.intro-copy .eyebrow {
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 9px;
  letter-spacing: 1.3px;
  text-transform: uppercase;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  display: inline-block;
  flex-shrink: 0;
}

.intro-copy h1 {
  font-size: clamp(33px, 3.3vw, 48px);
  letter-spacing: -1.9px;
  line-height: 1.14;
  margin: 19px 0;
  font-weight: 600;
}

.intro-copy h1>span {
  color: var(--accent);
}

.intro-copy>p {
  font-size: 16px;
  color: var(--muted);
  line-height: 1.8;
  max-width: 390px;
}

.primary-button {
  background: var(--ink);
  color: var(--paper);
  padding: 13px 20px;
  border-radius: 30px;
  font-size: 16px;
  font-weight: 500;
  margin-top: 23px;
  gap: 35px;
}

.primary-button:hover {
  background: var(--accent);
  color: #fff;
}

.experiment-panel {
  border: 1px solid var(--ink);
  border-radius: 3px;
  overflow: hidden;
}

.experiment-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 15px;
  border-bottom: 1px solid var(--line);
  font: 13px monospace;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.experiment-label>span:last-child {
  font: 17px Arial, sans-serif;
  text-transform: uppercase;
}

.shape-stage {
  height: 235px;
  position: relative;
  overflow: hidden;
  background-color: var(--surface);
  background-image: linear-gradient(var(--line) 1px,transparent 1px),linear-gradient(90deg,var(--line) 1px,transparent 1px);
  background-size: 23px 23px;
  --pointer-x: 0;
  --pointer-y: 0;
}

.play-shape {
  position: absolute;
  will-change: transform;
  transition: transform 350ms ease-out;
}

.shape-circle {
  width: 117px;
  height: 117px;
  left: 12%;
  top: 30px;
  background: var(--accent);
  border-radius: 50%;
  transform: translate(calc(var(--pointer-x) * 15px),calc(var(--pointer-y) * 15px));
}

.shape-checker {
  width: 96px;
  height: 96px;
  left: 30%;
  top: 101px;
  background: repeating-conic-gradient(#17191d 0% 25%,#fff 0% 50%) 50% / 24px 24px;
  border: 1px solid #17191d;
  transform: translate(calc(var(--pointer-x) * -12px),calc(var(--pointer-y) * -12px)) rotate(-12deg);
}

.shape-spark {
  width: 119px;
  height: 119px;
  right: 10%;
  top: 26px;
  fill: var(--ink);
  transform: translate(calc(var(--pointer-x) * -16px),calc(var(--pointer-y) * 12px)) rotate(calc(var(--pointer-x) * 14deg));
}

.shape-arch {
  width: 95px;
  height: 95px;
  right: 19%;
  top: 112px;
  background: var(--accent);
  border-radius: 50% 50% 0 0;
  transform: translate(calc(var(--pointer-x) * 10px),calc(var(--pointer-y) * -10px)) rotate(14deg);
}

.stage-caption {
  position: absolute;
  bottom: 9px;
  left: 14px;
  font: 13px monospace;
  letter-spacing: 1px;
  color: var(--muted);
  text-transform: uppercase;
}

.playground-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  border-top: 1px solid var(--line);
}

.color-description {
  display: flex;
  align-items: center;
  gap: 7px;
  font: 16px monospace;
}

.accent-toggle {
  background: var(--ink);
  color: var(--paper);
  border: 0;
  font-size: 16px;
  padding: 9px 13px;
  border-radius: 2px;
  min-height: 36px;
}

.accent-toggle:hover {
  background: var(--accent);
  color: #fff;
}

.accent-toggle span {
  font-size: 16px;
  margin-left: 7px;
}

.playground-note {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
  font: 16px monospace;
  letter-spacing: 1px;
  color: var(--muted);
}

.playground-note>span:last-child {
  font-family: 'DM Sans',Arial,sans-serif;
  letter-spacing: 0;
  font-size: 16px;
}

.overview-strip {
  display: none;
}

.projects-section {
  padding-top: 60px;
}

h2 em {
  color: var(--accent);
}

.filters button {
  border-radius: 30px;
  font-weight: 500;
}

.filters button[aria-pressed=true] {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

.filters button span {
  color: inherit;
  opacity: .7;
}

.project-grid {
  gap: 46px 32px;
}

.thumbnail {
  border-radius: 3px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.thumbnail--1,
.thumbnail--4,
.thumbnail--6 {
  background: var(--accent);
}

.thumbnail--2,
.thumbnail--5,
.thumbnail--8 {
  background: var(--surface);
}

.thumbnail--3,
.thumbnail--7 {
  background: #20242a;
}

.mini-browser {
  color: #151719;
  background: #fff;
}

.mini-head em {
  color: var(--accent);
}

.mini-shape {
  background: var(--accent);
  box-shadow: 10px 10px 0 #dddeda;
}

.mini-pill {
  background: var(--accent);
  color: #fff;
}

.design-1 .mini-shape,
.design-4 .mini-shape {
  background: #151719;
  box-shadow: 10px 10px 0 var(--accent);
}

.design-2 .mini-shape,
.design-6 .mini-shape {
  background: var(--accent);
  box-shadow: 10px 10px 0 #bdbfbb;
}

.design-3 .mini-shape,
.design-7 .mini-shape {
  background: var(--accent);
  box-shadow: 10px 10px 0 #dedfdb;
}

.design-5 {
  color: #fff;
}

.design-5 .mini-head em {
  color: #ffbcae;
}

.card-meta>span:last-child {
  color: var(--accent);
  text-transform: uppercase;
}

.card-meta {
  color: var(--muted);
  text-transform: uppercase;
}

.project-card h3 {
  font-size: 22px;
  font-weight: 600;
}

.project-card>p {
  color: var(--muted);
}

.art-arrow {
  background: #fff;
  color: #151719;
  border-radius: 50%;
}

.text-link:hover {
  color: var(--accent);
}

.topic-tags span {
  background: var(--surface);
  border-color: var(--line);
  border-radius: 30px;
}

.about-copy p,
.about-copy small {
  color: var(--muted);
}

footer {
  background: #151719;
  color: #f8f8f4;
  border-top: 1px solid var(--line);
}

.footer-brand {
  font-size: 37px;
  line-height: 1.15;
  font-weight: 600;
}

.footer-brand span {
  color: #ff846f;
}

.detail-header h1>span {
  color: var(--accent);
}

.status-badge {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--line);
}

.pending-link {
  background: var(--surface);
  border-color: var(--line);
}

.pending-link span {
  color: var(--ink);
}

.pending-link small,
.project-aside>p {
  color: var(--muted);
}

.reflection {
  background: var(--surface);
  border-color: var(--accent);
}

.reflection .reflection-label,
.reflection h2 span {
  color: var(--accent);
  text-transform: uppercase;
}

.detail-section p,
.detail-section .draft-note {
  color: var(--muted);
}

.circle-button {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
  border-radius: 50%;
}

.circle-button:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

@media (max-width: 1000px) {
  .brand>span:last-child {
    display: none;
    text-transform: uppercase;
  }

  .playground-intro {
    gap: 30px;
  }

  .intro-copy h1 {
    font-size: 35px;
  }

  .shape-stage {
    height: 220px;
  }

  .shape-circle {
    width: 95px;
    height: 95px;
    left: 7%;
  }

  .shape-checker {
    width: 80px;
    height: 80px;
    left: 25%;
  }

  .shape-spark {
    width: 95px;
    height: 95px;
    right: 7%;
  }

  .shape-arch {
    width: 80px;
    height: 80px;
    right: 14%;
    top: 110px;
  }
}

@media (max-width: 700px) {
  .header {
    padding-top: 14px;
    padding-bottom: 14px;
    gap: 10px;
  }

  .brand-icon {
    font-size: 22px;
  }

  .brand-dot {
    width: 6px;
    height: 6px;
    margin-bottom: 6px;
  }

  .header nav {
    font-size: 16px;
    gap: 14px;
  }

  .theme-toggle {
    padding: 7px 10px;
    font-size: 16px;
    gap: 5px;
  }

  .theme-symbol {
    font-size: 17px;
  }

  .hero-topline {
    font-size: 13px;
    letter-spacing: .7px;
    text-transform: uppercase;
  }

  .hero-topline>span:last-child {
    display: none;
    text-transform: uppercase;
  }

  .playground-intro {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 28px 0;
  }

  .intro-copy h1 {
    font-size: 37px;
    letter-spacing: -1.8px;
  }

  .intro-copy .eyebrow {
    font-size: 13px;
    text-transform: uppercase;
  }

  .intro-copy>p {
    font-size: 16px;
  }

  .experiment-panel {
    width: 100%;
  }

  .shape-stage {
    height: 225px;
  }

  .shape-circle {
    width: 110px;
    height: 110px;
    left: 12%;
  }

  .shape-checker {
    width: 90px;
    height: 90px;
    left: 30%;
  }

  .shape-spark {
    width: 110px;
    height: 110px;
    right: 10%;
  }

  .shape-arch {
    width: 90px;
    height: 90px;
    right: 18%;
  }

  .playground-note {
    font-size: 16px;
  }

  .playground-note>span:last-child {
    display: none;
  }

  .projects-section {
    padding-top: 40px;
  }

  .section-heading h2 {
    font-size: 31px;
  }

  .footer-brand {
    font-size: 31px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .play-shape {
    transition: none;
    transform: none;
    will-change: auto;
  }
}

/* Screenshot illustrations keep their own light surface in either theme. */

:root {
  --project-accent: #d7331d;
  --on-accent: #fff;
}

html.theme-dark {
  --on-accent: #111418;
}

.mini-head em {
  color: var(--project-accent);
}

.mini-pill {
  background: var(--project-accent);
  color: #fff;
}

.primary-button:hover,
.accent-toggle:hover,
.circle-button:hover {
  color: var(--on-accent);
}

html.theme-dark .design-5 .mini-head em {
  color: #ffbcae;
}

/* TYPOGRAPHIC HEADER — a geometric period adds a small playful detail. */
.playground-intro {
  border-top: 0;
  padding-top: 46px;
  padding-bottom: 43px;
  gap: 60px;
}

.intro-copy .playground-title {
  font-size: clamp(53px, 6.1vw, 86px);
  font-weight: 600;
  letter-spacing: -.065em;
  line-height: 1.04;
  margin-top: 22px;
  margin-bottom: 24px;
}

.playground-title .headline-line {
  display: block;
  color: var(--ink);
}

.playground-title .headline-accent {
  color: var(--accent);
}

.headline-period {
  display: inline-block;
  width: .17em;
  height: .17em;
  margin-left: .075em;
  margin-bottom: .025em;
  border-radius: 1px;
  background: var(--accent);
  transform: rotate(-12deg);
  transition: transform 220ms ease;
}

.playground-title:hover .headline-period {
  transform: translateY(-.04em) rotate(78deg);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 1000px) {
  .playground-intro {
    gap: 30px;
  }

  .intro-copy .playground-title {
    font-size: 64px;
  }
}

@media (max-width: 700px) {
  .playground-intro {
    padding-top: 30px;
    padding-bottom: 28px;
    gap: 30px;
  }

  .intro-copy .playground-title {
    font-size: clamp(58px, 12vw, 76px);
    letter-spacing: -.06em;
    margin-top: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .headline-period,
  .playground-title:hover .headline-period {
    transition: none;
    transform: none;
  }
}

/* READABILITY AND CONTRAST — apply to both themes and every accent palette. */
body {
  font-size: 16px;
  line-height: 1.65;
}

.card-meta b,
.filters button span {
  color: inherit;
  opacity: 1;
}

.card-meta {
  flex-wrap: wrap;
  align-items: start;
  gap: 10px;
  line-height: 1.65;
  letter-spacing: .7px;
}

.card-meta > span:first-child {
  max-width: calc(100% - 40px);
}

.eyebrow,
.hero-topline,
.experiment-label,
.stage-caption,
.thumbnail-caption,
.reflection-label {
  font-size: 13px;
  text-transform: uppercase;
}

.stage-caption {
  color: var(--ink);
  background: var(--surface);
  padding: 3px 5px;
}

.theme-toggle,
.filters button {
  border-color: var(--muted);
  min-height: 44px;
}

.accent-toggle {
  min-height: 44px;
}

.playground-controls {
  flex-wrap: wrap;
}

.experiment-label {
  line-height: 1.5;
  gap: 12px;
}

.playground-note {
  flex-wrap: wrap;
  line-height: 1.65;
}

.header {
  flex-wrap: wrap;
}

.header nav {
  flex-wrap: wrap;
}

.brand small {
  line-height: 1.5;
}

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

.primary-button:focus-visible,
.circle-button:focus-visible,
.accent-toggle:focus-visible {
  outline-color: var(--accent);
}

@media (max-width: 700px) {
  .header nav {
    order: 3;
    width: 100%;
    justify-content: space-between;
    padding-top: 8px;
  }

  .theme-toggle {
    margin-left: auto;
  }

  .hero-topline {
    flex-wrap: wrap;
    gap: 8px 20px;
  }

  .hero-topline > span:nth-child(2) {
    display: none;
  }

  .intro-copy .eyebrow {
    font-size: 13px;
    letter-spacing: .8px;
  }

  .brand-icon {
    font-size: 25px;
  }
}

/* The reflection label sits on a tinted panel, so use the full-contrast ink. */
.reflection .reflection-label {
  color: var(--ink);
}
