:root {
  color-scheme: light;
  font-family: Inter, "Segoe UI", Roboto, sans-serif;
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #0f172a;
  --muted: #475569;
  --border: #e2e8f0;
  --accent: #1d4ed8;
  --accent-soft: #eff6ff;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: radial-gradient(circle at top right, #e0f2fe, transparent 35%),
    radial-gradient(circle at top left, #dcfce7, transparent 30%), var(--bg);
  color: var(--text);
}

body {
  line-height: 1.6;
}

body[data-theme="sunset"] {
  --bg: #fff7ed;
  --surface: #fffbf5;
  --text: #431407;
  --muted: #9a3412;
  --border: #fed7aa;
  --accent: #ea580c;
  --accent-soft: #ffedd5;
}

.wrap {
  width: min(100% - 2rem, 980px);
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(8px);
  background: rgb(248 250 252 / 86%);
  border-bottom: 1px solid var(--border);
  z-index: 9;
}

body[data-theme="sunset"] .site-header {
  background: rgb(255 247 237 / 90%);
}

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem 0;
}

.brand {
  font-weight: 700;
  text-decoration: none;
  color: var(--text);
}

.nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.95rem;
}

.hero {
  padding: 5rem 0 2.5rem;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
  margin-bottom: 0.8rem;
  font-size: 0.78rem;
}

h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.2;
  margin: 0;
}

.lead {
  color: var(--muted);
  max-width: 64ch;
  margin-top: 1rem;
}

.hero-actions {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-top: 1.6rem;
}

.button {
  display: inline-block;
  padding: 0.75rem 1.1rem;
  border-radius: 0.65rem;
  text-decoration: none;
  font-weight: 600;
  border: 1px solid transparent;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
}

.button:hover,
.button:focus-visible {
  filter: brightness(0.92);
}

.button-ghost {
  background: var(--accent-soft);
  color: color-mix(in srgb, var(--accent), #1e3a8a 45%);
  border-color: color-mix(in srgb, var(--accent), white 70%);
}

.section {
  padding: 2rem 0;
}

h2 {
  margin: 0 0 0.8rem;
  font-size: 1.55rem;
}

.grid {
  display: grid;
  gap: 1rem;
}

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

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

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.85rem;
  padding: 1rem;
  box-shadow: 0 6px 22px rgb(15 23 42 / 5%);
}

.card h3 {
  margin-top: 0;
  margin-bottom: 0.35rem;
}

.card p,
.card li {
  color: #334155;
}

.card ul {
  margin: 0.3rem 0 0;
  padding-left: 1.2rem;
}

.card a {
  font-weight: 600;
  color: #1e3a8a;
}

.compact {
  padding: 0.9rem;
}


.visual-grid {
  gap: 1.1rem;
}

.media-card {
  overflow: hidden;
  padding: 0;
}

.media-cover {
  width: 100%;
  height: clamp(180px, 22vw, 260px);
  object-fit: cover;
  display: block;
  border-bottom: 1px solid var(--border);
}

.media-content {
  padding: 0.95rem;
}

.section-note {
  color: var(--muted);
  margin-top: 0;
  margin-bottom: 0.9rem;
}

.post-meta {
  margin: 0;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.sketchbook-post h3,
.media-content h3 {
  margin-top: 0.35rem;
}

#goodreads-current {
  margin-top: 0.4rem;
}

#goodreads-status {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.goodreads-book {
  margin: 0.55rem 0 0;
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
}

#goodreads-cover {
  width: 64px;
  height: 96px;
  object-fit: cover;
  border-radius: 0.35rem;
  border: 1px solid var(--border);
  background: #f1f5f9;
  flex-shrink: 0;
}

.goodreads-book figcaption p {
  margin: 0;
}

#goodreads-title {
  font-weight: 600;
  line-height: 1.3;
}

#goodreads-rating {
  color: var(--muted);
  margin-top: 0.2rem;
}

.pillar-card {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  color: #fff;
}

.pillar-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.02);
}

.pillar-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgb(15 23 42 / 28%), rgb(15 23 42 / 70%));
}

.pillar-card > * {
  position: relative;
  z-index: 1;
}

.pillar-card h3,
.pillar-card p,
.pillar-card a {
  color: #fff;
}

.pillar-card a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.pillar-photo::before {
  background-image: url("assets/pillar-photography.svg");
}

.pillar-writing::before {
  background-image: url("assets/pillar-writing.svg");
}

.pillar-experiments::before {
  background-image: url("assets/pillar-experiments.svg");
}

.pillar-resources::before {
  background-image: url("assets/pillar-visual-art.svg");
}

.playful-zone {
  background: linear-gradient(135deg, rgb(59 130 246 / 8%), rgb(236 72 153 / 8%));
  border: 1px dashed color-mix(in srgb, var(--accent), white 75%);
  border-radius: 1rem;
  padding: 1.4rem;
}

.play-controls {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.prompt-box {
  margin-top: 0.9rem;
  border-left: 4px solid var(--accent);
}

#prompt-text {
  margin: 0;
  font-weight: 500;
}

.pill-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.pill-list li {
  background: #f1f5f9;
  border: 1px solid #dbe7f3;
  border-radius: 999px;
  padding: 0.4rem 0.8rem;
  font-size: 0.92rem;
}

blockquote {
  border-left: 4px solid #93c5fd;
  margin: 0.5rem 0 1rem;
  padding: 0.6rem 1rem;
  background: #eff6ff;
  border-radius: 0.4rem;
  color: #1e3a8a;
}

.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  padding: 1.5rem 0 2.5rem;
  color: var(--muted);
  font-size: 0.95rem;
}


.writing-page,
.visual-art-page {
  padding: 5rem 0 2.5rem;
}

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

  .cols-2 {
    grid-template-columns: 1fr;
  }

  .header-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 560px) {
  .media-cover {
    height: 180px;
  }

  .writing-post {
    overflow: hidden;
    padding: clamp(0.75rem, 2vw, 1.25rem);
  }

  .post-cover {
    width: 100%;
    max-width: 100%;
    height: clamp(180px, 28vw, 280px);
    object-fit: cover;
    display: block;
    border-radius: 0.7rem;
  }

  .post-content {
    padding: clamp(0.85rem, 2vw, 1.25rem) 0 0;
  }

  .writing-post h1 {
    margin-top: 0;
  }

  .expandable-text {
    margin-top: 1rem;
    border-top: 1px solid var(--border);
    padding-top: 1rem;
  }

  .expandable-text summary {
    cursor: pointer;
    font-weight: 600;
    color: #1e3a8a;
    width: fit-content;
  }

  .expandable-text[open] summary {
    margin-bottom: 0.8rem;
  }

  .expandable-text p {
    margin: 0.7rem 0;
    color: #334155;
  }
}
