:root {
  color-scheme: dark;
  --ink: #f2ede2;
  --muted: #acb9b8;
  --gold: #edc58c;
  --bg: #101c22;
  --line: rgba(229, 234, 219, 0.13);
  font-family: Inter, system-ui, sans-serif;
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background:
    radial-gradient(
      ellipse at 68% 44%,
      var(--scene-glow, rgba(58, 91, 105, 0.22)),
      transparent 65%
    ),
    var(--bg);
  color: var(--ink);
  overflow: hidden;
  height: 100svh;
  min-height: 400px;
}
button,
a,
select {
  -webkit-tap-highlight-color: transparent;
}
a {
  color: inherit;
  text-decoration: none;
}
button,
select {
  font: inherit;
}
button {
  color: inherit;
  cursor: pointer;
}
button:focus-visible,
a:focus-visible,
select:focus-visible,
canvas:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 5px;
}
button:disabled {
  opacity: 0.4;
  cursor: default;
}
[hidden] {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background: radial-gradient(
    ellipse at 62% 43%,
    transparent 35%,
    rgba(5, 14, 18, 0.25) 100%
  );
}
.site-header {
  height: 100px;
  position: fixed;
  inset: 0 0 auto;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4.4vw;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: "DM Serif Display", Georgia, serif;
  font-size: 24px;
  letter-spacing: -0.6px;
}
.brand-period {
  color: var(--gold);
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 40px;
  border: 1px solid rgba(237, 197, 140, 0.45);
  border-radius: 14px 14px 5px 5px;
  color: var(--gold);
  background: rgba(237, 197, 140, 0.06);
}
.brand-mark svg {
  width: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.2;
}
.site-header nav {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 12px;
}
.site-header nav a {
  color: var(--muted);
  transition: color 0.2s;
}
.site-header nav a:hover {
  color: var(--ink);
}
.site-header nav a span {
  margin-left: 8px;
  color: var(--gold);
}
.site-header nav .journal-link {
  padding: 12px 18px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(10, 22, 26, 0.22);
}
.introduction {
  position: fixed;
  left: 4.4vw;
  top: 31%;
  z-index: 3;
  width: 350px;
  pointer-events: none;
}
.introduction a {
  pointer-events: auto;
}
.eyebrow {
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 26px;
  color: var(--gold);
}
.status-light {
  flex: none;
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 12px rgba(245, 191, 102, 0.65);
}
h1 {
  font-family: "DM Serif Display", Georgia, serif;
  font-weight: 400;
  font-size: clamp(38px, 3.15vw, 57px);
  line-height: 1.12;
  letter-spacing: -1.8px;
  margin: 0 0 23px;
}
h1 em {
  color: var(--gold);
  font-weight: 400;
}
.intro-description {
  font-size: 12px;
  line-height: 1.9;
  color: var(--muted);
  margin: 0 0 24px;
}
.intro-link {
  font-size: 11px;
  border-bottom: 1px solid rgba(237, 197, 140, 0.3);
  display: inline-flex;
  gap: 30px;
  padding-bottom: 9px;
}
.intro-link span {
  color: var(--gold);
  transition: transform 0.2s;
}
.intro-link:hover span {
  transform: translate(2px, -2px);
}
.intro-footnote {
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  color: #829391;
  margin-top: 64px;
}
.intro-footnote span {
  color: var(--gold);
  margin-right: 8px;
}
.scene-stage {
  position: fixed;
  top: 74px;
  bottom: 86px;
  left: 25%;
  right: 0;
  z-index: 0;
}
#scene3d {
  width: 100%;
  height: 100%;
  display: block;
  cursor: grab;
  touch-action: none;
  opacity: 0;
  transition: opacity 1.2s;
}
.scene-ready #scene3d {
  opacity: 1;
}
#scene3d:active {
  cursor: grabbing;
}
.scene-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: "JetBrains Mono", monospace;
  font-size: 10px;
  color: var(--gold);
}
.loading-ring {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 1px solid var(--line);
  border-top-color: var(--gold);
  animation: spin 1.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.scene-caption {
  position: absolute;
  right: 6%;
  top: 12px;
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  letter-spacing: 0.3px;
  color: #8c9e9d;
  opacity: 0.75;
}
.scene-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  max-width: 400px;
  margin: auto;
  padding: 24px;
}
.fallback-house {
  font-size: 90px;
  color: var(--gold);
}
.scene-fallback p {
  font-family: "DM Serif Display", serif;
  font-size: 26px;
  margin: 12px 0;
}
.scene-fallback > span:not(.fallback-house) {
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
}
.scene-fallback button {
  border: 1px solid var(--line);
  background: transparent;
  border-radius: 6px;
  padding: 12px 18px;
  margin-top: 20px;
}
.explore-controls {
  position: fixed;
  bottom: 86px;
  left: 62.5%;
  transform: translateX(-50%);
  z-index: 5;
  white-space: nowrap;
}
.scene-hint {
  text-align: center;
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  color: #98a7a4;
  letter-spacing: 0.15px;
  margin: 0 0 14px;
}
.scene-hint span {
  margin: 0 8px;
  color: var(--gold);
}
.control-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px;
  background: rgba(15, 29, 32, 0.84);
  border: 1px solid rgba(212, 227, 210, 0.17);
  border-radius: 10px;
  box-shadow: 0 8px 35px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(18px);
}
.view-controls {
  display: flex;
  gap: 2px;
}
.view-controls button {
  border: 0;
  border-radius: 5px;
  background: transparent;
  font-size: 10px;
  padding: 10px 15px;
  color: var(--muted);
  min-height: 36px;
}
.view-controls button.active {
  background: rgba(237, 197, 140, 0.12);
  color: var(--gold);
}
.view-controls button:hover {
  color: var(--ink);
}
.control-divider {
  height: 18px;
  width: 1px;
  background: var(--line);
  margin: 0 4px;
}
.lighting-control {
  display: flex;
  align-items: center;
  gap: 5px;
  padding-left: 5px;
  color: var(--gold);
}
.lighting-control svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.3;
}
.lighting-control select {
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 10px;
  cursor: pointer;
  width: 100px;
  height: 36px;
  padding: 0 4px;
}
.lighting-control option {
  background: #15272d;
  color: var(--ink);
}
.icon-button {
  width: 34px;
  height: 36px;
  display: grid;
  place-items: center;
  background: transparent;
  border: 0;
  border-radius: 5px;
  color: var(--muted);
}
.icon-button:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--ink);
}
.icon-button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.play-icon,
.sound-on {
  display: none;
}
#motionToggle[aria-pressed="true"] .pause-icon,
#soundToggle[aria-pressed="true"] .sound-off {
  display: none;
}
#motionToggle[aria-pressed="true"] .play-icon,
#soundToggle[aria-pressed="true"] .sound-on {
  display: block;
}
.agent-widget {
  position: fixed;
  right: 4.4vw;
  bottom: 90px;
  width: 64px;
  height: 64px;
  z-index: 8;
  transition:
    width 0.3s,
    height 0.3s;
  border: 1px solid rgba(237, 197, 140, 0.4);
  border-radius: 50%;
  background: #15272d;
  box-shadow: 0 0 35px rgba(237, 197, 140, 0.06);
}
.agent-face {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
  pointer-events: none;
}
.agent-face iframe {
  border: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.agent-widget button {
  position: absolute;
  inset: 0;
  background: transparent;
  border: 0;
  border-radius: inherit;
}
.agent-label {
  position: absolute;
  bottom: -22px;
  left: 50%;
  transform: translateX(-50%);
  font-family: "JetBrains Mono", monospace;
  font-size: 8px;
  white-space: nowrap;
  color: var(--muted);
}
.agent-expand {
  position: absolute;
  right: -3px;
  bottom: -3px;
  background: #263c40;
  border: 1px solid var(--line);
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  font-size: 12px;
  color: var(--gold);
}
.agent-widget.expanded {
  width: 250px;
  height: 250px;
  border-radius: 20px;
}
.agent-widget.expanded .agent-face,
.agent-widget.expanded iframe {
  pointer-events: auto;
}
.agent-widget.expanded button {
  inset: auto -9px -9px auto;
  width: 36px;
  height: 36px;
}
.agent-widget.expanded .agent-expand {
  inset: 0;
  width: 36px;
  height: 36px;
}
.agent-widget.expanded .agent-label {
  display: none;
}
.site-footer {
  position: fixed;
  bottom: 0;
  left: 4.4vw;
  right: 4.4vw;
  height: 61px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  z-index: 4;
  font-size: 9px;
  color: #99aaa7;
}
.porch-status {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--gold);
}
.time-display {
  display: flex;
  gap: 14px;
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
}
.footer-separator {
  color: #5f7677;
}
.site-footer a {
  font-size: 9px;
}
.site-footer a span {
  color: var(--gold);
  margin-left: 12px;
}
.no-script {
  position: fixed;
  left: 40%;
  top: 50%;
  font-size: 14px;
  z-index: 20;
}
@media (min-width: 1700px) {
  .introduction {
    width: 440px;
  }
  .intro-description {
    font-size: 14px;
  }
  .eyebrow {
    font-size: 10px;
  }
  .scene-stage {
    left: 26%;
    right: 3%;
  }
  .scene-caption {
    right: 3%;
  }
  .explore-controls {
    left: 61.5%;
  }
}
@media (max-width: 1100px) {
  .site-header {
    padding: 0 30px;
  }
  .introduction {
    left: 30px;
    width: 265px;
  }
  h1 {
    font-size: 39px;
  }
  .eyebrow {
    font-size: 8px;
    letter-spacing: 1px;
  }
  .scene-stage {
    left: 23%;
  }
  .intro-footnote {
    margin-top: 42px;
  }
  .scene-caption {
    display: none;
  }
  .agent-widget {
    right: 24px;
    width: 52px;
    height: 52px;
  }
  .site-footer {
    left: 30px;
    right: 30px;
  }
  .site-header nav {
    gap: 22px;
  }
  .explore-controls {
    left: 60%;
  }
}
@media (max-width: 760px) {
  body {
    min-height: 360px;
  }
  .site-header {
    height: 78px;
    padding: 0 22px;
    gap: 12px;
  }
  .brand {
    font-size: 21px;
    gap: 9px;
  }
  .brand-mark {
    width: 29px;
    height: 33px;
  }
  .brand-mark svg {
    width: 19px;
  }
  .site-header nav {
    gap: 18px;
    font-size: 10px;
  }
  .community-link {
    display: none;
  }
  .site-header nav .journal-link {
    padding: 9px 12px;
  }
  .introduction {
    top: 99px;
    left: 22px;
    right: 22px;
    width: auto;
    text-align: center;
    pointer-events: none;
  }
  .eyebrow {
    justify-content: center;
    font-size: 8px;
    letter-spacing: 1.25px;
    margin-bottom: 13px;
  }
  h1 {
    font-size: 31px;
    letter-spacing: -0.8px;
    line-height: 1.16;
    margin-bottom: 10px;
  }
  h1 br:nth-of-type(2) {
    display: none;
  }
  h1 em {
    margin-left: 4px;
  }
  .intro-description {
    font-size: 10px;
    line-height: 1.6;
    margin: 0;
  }
  .intro-description br {
    display: none;
  }
  .intro-link,
  .intro-footnote {
    display: none;
  }
  .scene-stage {
    left: 0;
    right: 0;
    top: 221px;
    bottom: 146px;
  }
  .explore-controls {
    bottom: 83px;
    left: 50%;
  }
  .scene-hint {
    font-size: 8px;
    margin-bottom: 10px;
  }
  .control-bar {
    gap: 2px;
    padding: 5px;
    border-radius: 9px;
  }
  .control-divider {
    margin: 0 3px;
  }
  .view-controls button {
    padding: 10px 12px;
  }
  .lighting-control select {
    width: 91px;
  }
  .icon-button {
    width: 31px;
    min-height: 36px;
  }
  .agent-widget {
    right: 18px;
    bottom: 148px;
    width: 43px;
    height: 43px;
  }
  .agent-label {
    display: none;
  }
  .agent-expand {
    width: 18px;
    height: 18px;
    font-size: 10px;
  }
  .agent-widget.expanded {
    width: 220px;
    height: 220px;
  }
  .site-footer {
    left: 22px;
    right: 22px;
    height: 59px;
    gap: 5px;
    flex-wrap: wrap;
    align-content: center;
    row-gap: 6px;
  }
  .porch-status {
    font-size: 8px;
    width: 100%;
    justify-content: center;
  }
  .time-display {
    font-size: 8px;
    gap: 8px;
    flex: 1;
    justify-content: center;
  }
  .site-footer > a {
    display: none;
  }
  .scene-fallback {
    padding: 0 40px;
  }
  .scene-fallback .fallback-house {
    font-size: 60px;
  }
  .scene-fallback p {
    font-size: 20px;
  }
  .scene-fallback > span:not(.fallback-house) {
    font-size: 10px;
  }
  .scene-fallback button {
    padding: 8px 12px;
    margin-top: 12px;
  }
  .scene-loading {
    font-size: 9px;
  }
  .no-script {
    left: 20px;
    right: 20px;
    top: 48%;
    text-align: center;
  }
}
@media (max-width: 380px) {
  .site-header {
    padding: 0 16px;
  }
  .site-header nav {
    gap: 11px;
  }
  .site-header nav .journal-link {
    padding: 9px;
  }
  .brand {
    font-size: 19px;
  }
  .control-bar {
    gap: 0;
  }
  .view-controls button {
    padding: 10px;
  }
  .control-divider {
    margin: 0 2px;
  }
  .lighting-control select {
    width: 87px;
  }
  .introduction {
    left: 12px;
    right: 12px;
  }
  h1 {
    font-size: 29px;
  }
}
@media (max-width: 760px) and (max-height: 700px) {
  .introduction {
    top: 83px;
  }
  .eyebrow {
    margin-bottom: 8px;
  }
  h1 {
    font-size: 26px;
    margin-bottom: 7px;
  }
  .intro-description {
    display: none;
  }
  .scene-stage {
    top: 164px;
    bottom: 132px;
  }
  .explore-controls {
    bottom: 73px;
  }
  .site-footer {
    height: 51px;
  }
  .agent-widget {
    bottom: 133px;
  }
  .scene-hint {
    margin-bottom: 7px;
  }
}
@media (max-height: 540px) and (min-width: 761px) {
  .site-header {
    height: 70px;
  }
  .introduction {
    top: 25%;
    width: 260px;
  }
  h1 {
    font-size: 34px;
  }
  .eyebrow {
    margin-bottom: 14px;
  }
  .intro-description {
    margin-bottom: 12px;
  }
  .intro-footnote {
    display: none;
  }
  .scene-stage {
    top: 58px;
    bottom: 64px;
  }
  .explore-controls {
    bottom: 61px;
  }
  .site-footer {
    height: 44px;
  }
  .agent-widget {
    bottom: 70px;
  }
  .scene-hint {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* Feather the atmosphere into the page, leaving the model itself unmasked. */
#scene3d {
  mask-image:
    linear-gradient(to right, transparent, #000 13%, #000 88%, transparent),
    linear-gradient(to bottom, transparent, #000 14%, #000 87%, transparent);
  mask-composite: intersect;
}
@media (max-width: 760px) {
  #scene3d {
    mask-image: linear-gradient(
      to bottom,
      transparent,
      #000 14%,
      #000 86%,
      transparent
    );
  }
}

body[data-mood="golden"] {
  --scene-glow: rgba(121, 111, 67, 0.21);
}
body[data-mood="day"],
body[data-mood="morning"] {
  --scene-glow: rgba(117, 158, 147, 0.23);
}
body[data-mood="dawn"] {
  --scene-glow: rgba(140, 115, 116, 0.19);
}
