@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,700&family=Sora:wght@300;400;500;600&display=swap');

    :root {
      color-scheme: light;
      --bg: #ffead0;
      --ink: #18020c;
      --muted: #113c55;
      --accent: #dd0000;
      --accent-dark: #113c55;
      --accent-soft: #437F97;
      --card: #ffffff;
      --outline: rgba(17, 60, 85, 0.18);
      --shadow: 0 20px 45px rgba(17, 60, 85, 0.18);
      --rule: rgba(17, 60, 85, 0.18);
      --nav-bg: rgba(255, 234, 208, 0.9);
      --nav-text: #18020c;
      --nav-pill-bg: rgba(255, 255, 255, 0.9);
      --nav-pill-text: #18020c;
      --nav-pill-border: rgba(0, 0, 0, 0.15);
      --panel-bg: rgba(255, 255, 255, 0.9);
      --section-card-bg: rgba(255, 255, 255, 0.1);
    }

    body.dark {
      color-scheme: dark;
      --bg: #0f1113;
      --ink: #f5ead9;
      --muted: #c7b9a7;
      --accent: #DBB3B1;
      --accent-dark: #95d9c3;
      --accent-soft: #dd0000;
      --card: #14171a;
      --outline: rgba(255, 255, 255, 0.12);
      --shadow: 0 20px 45px rgba(0, 0, 0, 0.45);
      --rule: rgba(255, 255, 255, 0.12);
      --nav-bg: rgba(10, 10, 12, 0.8);
      --nav-text: #f5ead9;
      --nav-pill-bg: rgba(255, 255, 255, 0.12);
      --nav-pill-text: #f5ead9;
      --nav-pill-border: rgba(255, 255, 255, 0.2);
      --panel-bg: rgba(20, 23, 26, 0.92);
      --section-card-bg: #1C1F21;
    }

    * {
      box-sizing: border-box;
    }

    body {
      margin: 0;
      min-height: 100vh;
      font-family: "Sora", "Helvetica Neue", sans-serif;
      color: var(--ink);
      background: var(--bg);
    }

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

    .content-link {
      color: var(--accent);
      text-decoration: underline;
      text-decoration-thickness: 2px;
      text-underline-offset: 3px;
    }

    .page {
      position: relative;
      overflow: visible;
    }

    header {
      position: relative;
      z-index: 1;
      padding: 24px 24px 0;
    }

    .nav {
      position: sticky;
      top: 0;
      z-index: 10;
      background: var(--nav-bg);
      backdrop-filter: blur(20px);
      /* border-bottom: 1px solid rgba(255, 255, 255, 0.12); */
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 16px;
      max-width: 980px;
      margin: 0 auto;
      padding: 10px 0;
      border-radius: 0;
    }

    /* .logo { */
    /*   font-family: "Fraunces", "Times New Roman", serif; */
    /*   font-weight: 700; */
    /*   letter-spacing: 0.5px; */
    /*   display: inline-flex; */
    /*   align-items: center; */
    /*   gap: 0; */
    /*   line-height: 0; */
    /* } */

    /* .logo-icon { */
    /*   width: 80px; */
    /*   height: 80px; */
    /*   display: block; */
    /*   object-fit: contain; */
    /* } */

    .nav-links {
      display: flex;
      gap: 18px;
      font-weight: 500;
      color: var(--nav-text);
      align-items: center;
    }

    .nav-links a {
      padding: 8px 12px;
      border-radius: 999px;
      border: 1px solid transparent;
      transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
      color: var(--nav-text);
    }

    .nav-links a:focus-visible,
    .theme-toggle:focus-visible {
      outline: 2px solid rgba(17, 60, 85, 0.55);
      outline-offset: 3px;
    }

    .content-link:focus-visible,
    .contact a:focus-visible,
    .footer-top:focus-visible {
      outline: 2px solid rgba(17, 60, 85, 0.55);
      outline-offset: 2px;
      border-radius: 6px;
    }

    body.dark .nav-links a:focus-visible,
    body.dark .theme-toggle:focus-visible,
    body.dark .content-link:focus-visible,
    body.dark .contact a:focus-visible,
    body.dark .footer-top:focus-visible {
      outline-color: rgba(199, 185, 167, 0.7);
    }


    .nav-links a:hover,
    .nav-links a.active {
      background: var(--nav-pill-bg);
      color: var(--nav-pill-text);
      border-color: var(--nav-pill-border);
    }

    .theme-toggle {
      padding: 8px;
      border-radius: 999px;
      border: 1px solid transparent;
      background: transparent;
      color: var(--nav-text);
      cursor: pointer;
      font: inherit;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 38px;
      height: 38px;
    }

    .theme-toggle:hover {
      background: var(--nav-pill-bg);
      color: var(--nav-pill-text);
      border-color: var(--nav-pill-border);
    }

    .theme-icon {
      display: inline-flex;
      align-items: center;
      justify-content: center;
    }

    .theme-icon svg {
      width: 18px;
      height: 18px;
      display: block;
    }

    .theme-icon-moon {
      display: none;
    }

    body.dark .theme-icon-sun {
      display: none;
    }

    body.dark .theme-icon-moon {
      display: inline-flex;
    }


    body.home main {
      opacity: 0;
      transform: translateY(12px);
      transition: transform 0.6s ease, opacity 0.5s ease;
    }

    body.home.content-revealed main {
      opacity: 1;
      transform: translateY(0);
    }

    .life-bar {
      position: sticky;
      top: 56px;
      z-index: 8;
      margin: 6px 0 0;
      font-weight: 700;
      font-size: 1rem;
      color: var(--ink);
    }

    .life-bar-inner {
      max-width: 980px;
      margin: 0 auto;
      padding: 0 24px;
      display: flex;
      justify-content: center;
    }

    .life-bar-chip {
      display: inline-flex;
      gap: 10px;
      align-items: center;
      padding: 12px 18px;
      background: var(--panel-bg);
      border: 1px solid var(--outline);
      border-radius: 999px;
      cursor: pointer;
      font: inherit;
      color: inherit;
    }

    .hero-pill {
      background: transparent;
      border-color: transparent;
      font-size: clamp(1.3rem, 2.4vw, 2.4rem);
      letter-spacing: 0.6px;
      padding: 28px 40px;
      gap: 22px;
    }

    .hero-pill .life-pill {
      font-weight: 700;
      font-size: inherit;
    }

    .hero-pill .life-heart {
      transform: scale(4.25);
      margin-right: 18px;
    }

    .life-bar-chip:focus-visible {
      outline: 2px solid rgba(68, 157, 209, 0.6);
      outline-offset: 3px;
    }

    .life-modal {
      position: fixed;
      inset: 0;
      background: rgba(10, 10, 12, 0.6);
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 24px;
      z-index: 30;
    }

    .life-modal[hidden] {
      display: none;
    }

    .life-modal-card {
      background: var(--panel-bg);
      color: var(--ink);
      border-radius: 18px;
      max-width: 520px;
      width: 100%;
      padding: 24px;
      box-shadow: 0 24px 60px rgba(0, 0, 0, 0.2);
      position: relative;
      pointer-events: auto;
    }

    .life-modal-card h2 {
      margin: 0 0 12px;
      font-family: "Fraunces", "Times New Roman", serif;
      font-size: 1.6rem;
    }

    .life-modal-card p {
      margin: 0;
      color: var(--muted);
      line-height: 1.6;
    }

    .article h2 {
      font-family: "Fraunces", "Times New Roman", serif;
      font-size: 1.4rem;
      margin: 24px 0 10px;
      color: var(--ink);
    }

    .life-modal-close {
      position: absolute;
      top: 12px;
      right: 12px;
      width: 34px;
      height: 34px;
      border-radius: 50%;
      border: 1px solid var(--outline);
      background: rgba(255, 255, 255, 0.1);
      font-size: 1.2rem;
      line-height: 1;
      cursor: pointer;
    }

    .life-heart {
      position: relative;
      width: 18px;
      height: 16px;
      display: inline-block;
      margin-right: 2px;
      animation: pulse var(--pulse-speed, 1s) infinite;
    }

    .life-heart::before,
    .life-heart::after {
      position: absolute;
      content: "";
      left: 9px;
      top: 0;
      width: 9px;
      height: 14px;
      background: #dd0000;
      border-radius: 9px 9px 0 0;
      transform: rotate(-45deg);
      transform-origin: 0 100%;
      animation: pulsecolor var(--pulse-speed, 1s) infinite;
    }

    .life-heart::after {
      left: 0;
      transform: rotate(45deg);
      transform-origin: 100% 100%;
      animation: pulsecolor var(--pulse-speed, 1s) infinite;
    }

    .life-pill {
      display: inline;
      padding: 0;
      border-radius: 0;
      background: transparent;
      color: var(--ink);
      border: 0;
      text-transform: none;
      font-size: 0.9rem;
      letter-spacing: 0.6px;
    }

    body.home .life-bar {
      opacity: 0;
      pointer-events: none;
      transform: translateY(-6px);
      transition: opacity 0.2s ease, transform 0.2s ease;
    }

    body.home.pill-visible .life-bar {
      opacity: 1;
      pointer-events: auto;
      transform: none;
    }


    .hero {
      max-width: none;
      margin: 28px 0 0;
      padding: 0 0 36px;
    }

    .hero-image {
      width: 100%;
      border-radius: 0;
      display: block;
      max-height: clamp(220px, 45vh, 520px);
      object-fit: contain;
    }

    .hero-wordmark {
      font-family: "Fraunces", "Times New Roman", serif;
      font-size: clamp(2.4rem, 6vw, 4.6rem);
      color: #c83a2d;
      text-align: center;
      margin-top: 14px;
      letter-spacing: 0.5px;
    }

    .hero-wordmark[data-alt] {
      cursor: pointer;
    }

    .hero-wordmark:focus-visible {
      outline: 2px solid rgba(17, 60, 85, 0.55);
      outline-offset: 4px;
      border-radius: 8px;
    }

    .hero-scroll {
      font-family: "Sora", "Helvetica Neue", sans-serif;
      font-size: 0.72rem;
      text-align: center;
      color: var(--muted);
      margin-top: 8px;
      line-height: 1.4;
      letter-spacing: 0.35em;
      text-transform: uppercase;
      opacity: 0.7;
    }

    .hero-status {
      display: flex;
      justify-content: center;
      margin-top: 12px;
    }

    .bandcamp-frame {
      background: var(--bg);
      border-radius: 8px;
      overflow: hidden;
      max-width: 700px;
      min-width: 250px;
      width: 100%;
      margin: 16px auto 0;
    }

    .bandcamp-embed {
      display: block;
      width: 100%;
      height: 260px;
      border: 0;
      background: var(--bg);
    }

    .media-grid {
      display: grid;
      gap: 18px;
      grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
      margin-top: 16px;
    }

    .insta-feed {
      margin-top: 24px;
    }

    .lightwidget-widget {
      display: block;
      width: 100%;
      border: 0;
      overflow: hidden;
      min-height: 520px;
    }

    .embed-wrap {
      background: var(--bg);
      border-radius: 8px;
      overflow: hidden;
      border: 1px solid var(--outline);
    }

    .embed-wrap.video {
      aspect-ratio: 16 / 9;
    }

    .youtube-embed {
      width: 100%;
      height: 100%;
      border: 0;
      display: block;
    }

    .art-figure {
      margin: 0;
      display: grid;
      gap: 12px;
    }

    .art-image {
      width: 100%;
      border-radius: 12px;
      border: 1px solid var(--outline);
      background: var(--panel-bg);
      display: block;
    }

    .art-caption {
      color: var(--muted);
      font-size: 0.95rem;
      line-height: 1.5;
    }

    .gallery {
      display: grid;
      gap: 14px;
    }

    .gallery-main {
      border-radius: 12px;
      overflow: hidden;
      border: 1px solid var(--outline);
      background: var(--panel-bg);
    }

    .gallery-main img {
      width: 100%;
      max-height: 70vh;
      object-fit: contain;
      display: block;
      background: var(--panel-bg);
    }

    .gallery-caption {
      color: var(--muted);
      font-size: 0.95rem;
      line-height: 1.5;
    }

    .gallery-thumbs {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
      gap: 10px;
    }

    .gallery-thumb {
      border: 1px solid var(--outline);
      border-radius: 10px;
      padding: 0;
      background: var(--panel-bg);
      cursor: pointer;
    }

    .gallery-thumb img {
      width: 100%;
      height: 72px;
      object-fit: cover;
      border-radius: 10px;
      display: block;
    }

    .gallery-thumb.active {
      outline: 2px solid var(--accent);
      outline-offset: 2px;
    }

    .inline-gallery {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
      gap: 16px;
      margin: 16px 0;
    }

    .inline-image {
      width: 100%;
      border-radius: 12px;
      border: 1px solid var(--outline);
      background: var(--panel-bg);
      display: block;
    }

    .post-hero {
      width: 100%;
      height: clamp(180px, 35vh, 420px);
      border-radius: 12px;
      border: 1px dashed rgba(17, 60, 85, 0.25);
      background: rgba(255, 255, 255, 0.35);
      color: var(--muted);
      display: flex;
      align-items: center;
      justify-content: center;
      font-weight: 600;
      letter-spacing: 0.2px;
    }

    .bandcamp-frame,
    .embed-wrap,
    .art-image,
    .gallery-main,
    .gallery-thumb,
    .inline-image,
    .post-hero {
      transition: transform 0.2s ease, box-shadow 0.2s ease;
    }

    .bandcamp-frame:hover,
    .embed-wrap:hover,
    .art-image:hover,
    .gallery-main:hover,
    .gallery-thumb:hover,
    .inline-image:hover,
    .post-hero:hover {
      transform: translateY(-2px);
      box-shadow: 0 14px 28px rgba(17, 60, 85, 0.16);
    }

    .post-hero img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      border-radius: 12px;
      display: block;
    }

    main {
      max-width: 980px;
      margin: 0 auto;
      padding: 0 24px 72px;
      display: grid;
      gap: 28px;
    }

    .section {
      position: relative;
      z-index: 1;
      border-radius: 0;
      padding: 26px 0 30px;
      border-top: 1px solid var(--rule);
      animation: fadeUp 0.8s ease both;
      scroll-margin-top: 120px;
    }

    .section.no-rule {
      border-top: 0;
      padding-top: 0;
    }

    .home-blurb {
      margin-bottom: 36px;
      padding-bottom: 50px;
      border-bottom: 1px solid var(--rule);
    }

    .home-copy {
      font-family: "Fraunces", "Times New Roman", serif;
      font-size: clamp(1.6rem, 3.2vw, 2.6rem);
      text-align: center;
      line-height: 1.2;
      margin: 0;
      color: var(--ink);
    }

    .section:nth-of-type(even) {
      background: transparent;
      padding-left: 0;
      padding-right: 0;
      border-radius: 14px;
    }

    .section:nth-of-type(even)::before {
      content: "";
      position: absolute;
      inset: -12px;
      background: var(--section-card-bg);
      border-radius: 16px;
      z-index: -1;
    }

    .section:nth-of-type(even) > * {
      padding-left: 14px;
      padding-right: 14px;
    }

    .section:nth-of-type(even) p,
    .section:nth-of-type(even) .tile p,
    .section:nth-of-type(even) .now li {
      color: var(--ink);
    }

    .section h2,
    .page-title {
      font-family: "Fraunces", "Times New Roman", serif;
      font-size: clamp(1.9rem, 3vw, 2.6rem);
      margin: 0 0 12px;
    }

    .section p,
    .page-intro {
      color: var(--muted);
      margin: 0 0 22px;
    }

    .section h2::after,
    .page-title::after {
      content: "";
      display: block;
      width: 42px;
      height: 3px;
      background: var(--accent-soft);
      margin-top: 10px;
      border-radius: 999px;
    }

    .post-list {
      display: grid;
      gap: 20px;
    }

    .post-item {
      border-bottom: 1px solid rgba(17, 60, 85, 0.2);
      padding-bottom: 18px;
      display: grid;
      gap: 8px;
    }

    .build-log-details {
      margin-top: 6px;
    }

    .build-log-details summary {
      cursor: pointer;
      font-weight: 600;
      color: var(--accent-dark);
      list-style: none;
    }

    .build-log-details summary::-webkit-details-marker {
      display: none;
    }

    .build-log-details summary::before {
      content: "+";
      display: inline-block;
      margin-right: 8px;
      color: var(--accent);
      font-weight: 700;
    }

    .build-log-details[open] summary::before {
      content: "–";
    }

    .build-log-details pre {
      margin: 12px 0 0;
      padding: 14px 16px;
      background: var(--panel-bg);
      border: 1px solid var(--outline);
      border-radius: 10px;
      overflow-x: auto;
      font-size: 0.9rem;
      line-height: 1.5;
      color: var(--ink);
    }

    .post-meta {
      font-size: 0.85rem;
      color: var(--muted);
      letter-spacing: 0.2px;
      text-transform: uppercase;
    }

    .post-item h3 {
      margin: 0;
      font-size: 1.2rem;
    }

    .post-item p {
      margin: 0;
      color: var(--muted);
    }

    .post-link {
      color: var(--accent-dark);
      font-weight: 600;
    }

    .contact {
      display: grid;
      gap: 12px;
      font-weight: 500;
      list-style: none;
      margin: 0;
      padding: 0;
    }

    .contact a {
      color: var(--accent);
      text-decoration: underline;
    }

    .article {
      display: grid;
      gap: 18px;
    }

    .article h2 {
      margin: 18px 0 4px;
    }

    .back-link {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      font-weight: 600;
      color: var(--accent-dark);
      text-decoration: underline;
      text-underline-offset: 4px;
      text-decoration-thickness: 2px;
      width: fit-content;
    }

    .artifact-note {
      font-size: 0.85rem;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      opacity: 0;
      transform: translateY(6px);
      transition: opacity 0.6s ease, transform 0.6s ease;
      color: var(--muted);
    }

    .artifact-note.revealed {
      opacity: 0.7;
      transform: translateY(0);
    }

    footer {
      text-align: center;
      padding: 32px 24px 48px;
      color: var(--muted);
    }

    .footer-top {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      margin-bottom: 12px;
      font-weight: 600;
      color: var(--accent-dark);
      text-decoration: underline;
      text-underline-offset: 4px;
      text-decoration-thickness: 2px;
    }

    @keyframes fadeUp {
      from {
        opacity: 0;
        transform: translateY(16px);
      }

      to {
        opacity: 1;
        transform: translateY(0);
      }
    }

    @keyframes pulse {
      10% {
        transform: scale(1.1);
      }
    }

    @keyframes pulsecolor {
      10% {
        background: #aa0000;
      }
    }

    @media (max-width: 760px) {
      .nav {
        flex-direction: column;
      }

      .nav-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
      }

      .nav-links a,
      .theme-toggle {
        font-size: 0.82rem;
        padding: 6px 8px;
      }

      .hero {
        margin-top: 24px;
        padding-bottom: 28px;
      }

      .hero-wordmark {
        margin-top: 10px;
      }

      .hero-pill {
        font-size: 0.75rem;
        padding: 14px 18px;
        gap: 10px;
      }

      .hero-status {
        margin-top: 10px;
      }

      .hero-scroll {
        margin-top: 6px;
        letter-spacing: 0.25em;
      }

      .hero-pill .life-heart {
        transform: scale(2.1);
        margin-right: 8px;
      }

      .lightwidget-widget {
        min-height: 420px;
      }

      .life-bar-chip {
        font-size: 0.8rem;
      }

      .life-pill {
        font-size: inherit;
      }
    }

    @media (prefers-reduced-motion: reduce) {
      * {
        animation: none !important;
        transition: none !important;
      }
    }
