:root {
  color-scheme: light;
  --background: #f8f2eb;
  --surface: #fffdfa;
  --blush: #f5e8ef;
  --blue: #75a1ed;
  --orange: #ff542c;
  --ink: #333333;
  --muted: #817a75;
  --line: rgba(51, 51, 51, 0.16);
  --radius-card: 24px;
  --radius-button: 15px;
  --border: 2.5px solid var(--ink);
  --hard-shadow: 0 6px 0 var(--ink);
  --soft-shadow: 0 18px 50px rgba(91, 58, 38, 0.18);
  --font-rounded: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", system-ui, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--background);
  color: var(--ink);
  font-family: var(--font-body);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100dvh;
  background: var(--background);
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

button {
  color: inherit;
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 30;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--ink);
  color: var(--surface);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

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

.split-shell {
  display: grid;
  grid-template-columns: minmax(390px, 42%) minmax(0, 58%);
  min-height: 100dvh;
}

.intro-panel {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100dvh;
  padding: 28px clamp(28px, 4vw, 72px) 24px;
  border-right: 1px solid rgba(51, 51, 51, 0.12);
  background: var(--background);
}

.intro-panel .site-header {
  display: grid;
  gap: 14px;
}

.intro-panel .site-nav {
  gap: clamp(9px, 1.15vw, 18px);
}

.site-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px;
}

.wordmark {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand-mark {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  border-radius: 11px;
  object-fit: cover;
}

.brand-copy {
  display: inline-flex;
  flex-direction: column;
}

.wordmark .brand-copy > span {
  font-family: var(--font-rounded);
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.wordmark small {
  margin-top: 2px;
  color: var(--muted);
  font-family: var(--font-rounded);
  font-size: 0.61rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(12px, 1.5vw, 24px);
  min-height: 44px;
  white-space: nowrap;
}

.site-nav a {
  position: relative;
  padding: 7px 0;
  color: #5c5753;
  font-family: var(--font-rounded);
  font-size: 0.78rem;
  font-weight: 760;
  text-decoration: none;
}

.site-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

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

.hero-copy {
  align-self: center;
  max-width: 660px;
  padding: 46px 0 24px;
}

.hero-kicker {
  margin: 0 0 20px;
  color: var(--orange);
  font-family: var(--font-rounded);
  font-size: 0.88rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-copy h1 {
  max-width: 11ch;
  margin: 0;
  font-family: var(--font-rounded);
  font-size: clamp(3.2rem, 5.9vw, 6.9rem);
  font-weight: 900;
  letter-spacing: -0.065em;
  line-height: 0.92;
}

.hero-description {
  max-width: 32rem;
  margin: 28px 0 30px;
  color: #69635f;
  font-size: clamp(1rem, 1.4vw, 1.2rem);
  line-height: 1.55;
}

.app-store-button {
  display: inline-grid;
  min-width: 186px;
  padding: 10px 18px 11px;
  border: var(--border);
  border-radius: var(--radius-button);
  background: var(--ink);
  box-shadow: 0 5px 0 var(--orange);
  color: #fffdfa;
  text-decoration: none;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.app-store-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 0 var(--orange);
}

.app-store-button:active {
  transform: translateY(3px);
  box-shadow: 0 2px 0 var(--orange);
}

.app-store-overline {
  font-size: 0.68rem;
  line-height: 1;
}

.app-store-button strong {
  margin-top: 2px;
  font-family: var(--font-rounded);
  font-size: 1.35rem;
  line-height: 1.1;
}

.intro-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.73rem;
}

.intro-footer p {
  margin: 0;
}

.gallery-panel {
  position: relative;
  min-height: 100dvh;
  overflow: hidden;
  isolation: isolate;
  background: #ead8ca;
}

.gallery-wall {
  position: absolute;
  inset: 0 0 18%;
  background-color: #f3dcd0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.08), rgba(223, 184, 167, 0.06)),
    url("/assets/gallery-wall.jpg");
  background-size: 560px 560px;
}

.gallery-wall::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 72% 6%, rgba(255, 248, 229, 0.72), transparent 26%),
    linear-gradient(115deg, rgba(255, 255, 255, 0.16), transparent 35%, rgba(104, 56, 41, 0.07));
}

.gallery-floor {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 18%;
  border-top: 6px solid rgba(255, 255, 255, 0.78);
  background: url("/assets/gallery-floor.jpg") center 46% / cover;
  box-shadow: inset 0 12px 28px rgba(119, 74, 44, 0.14);
}

.gallery-room-title {
  position: absolute;
  top: 28px;
  left: 50%;
  z-index: 3;
  min-width: 230px;
  padding: 13px 24px;
  border: var(--border);
  border-radius: var(--radius-button);
  background: var(--surface);
  box-shadow: var(--hard-shadow);
  font-family: var(--font-rounded);
  font-size: clamp(1rem, 1.5vw, 1.35rem);
  font-weight: 900;
  text-align: center;
  transform: translateX(-50%);
}

.gallery-hint {
  position: absolute;
  right: 26px;
  bottom: 22px;
  z-index: 3;
  max-width: 245px;
  margin: 0;
  padding: 10px 14px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  background: rgba(255, 253, 250, 0.9);
  box-shadow: 0 4px 0 var(--ink);
  color: #5c5753;
  font-family: var(--font-rounded);
  font-size: 0.73rem;
  font-weight: 800;
  line-height: 1.35;
}

.artwork {
  position: absolute;
  z-index: 2;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: var(--soft-shadow);
  cursor: pointer;
  transition: transform 260ms cubic-bezier(0.16, 1, 0.3, 1), filter 260ms ease;
}

.artwork:hover {
  z-index: 4;
  filter: brightness(1.035);
  transform: translateY(-7px) scale(1.025);
}

.artwork:active {
  transform: translateY(-1px) scale(0.99);
}

.artwork img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.artwork--flowers {
  top: 19%;
  left: 8%;
  width: 19%;
  aspect-ratio: 0.83;
}

.artwork--letter {
  top: 15%;
  right: 7%;
  width: 16%;
  aspect-ratio: 0.84;
}

.artwork--bride {
  top: 45%;
  left: 35%;
  width: 36%;
  aspect-ratio: 1.38;
}

.artwork--night {
  top: 57%;
  left: 4%;
  width: 24%;
  aspect-ratio: 1.2;
}

.artwork--wheat {
  top: 48%;
  right: -4%;
  width: 24%;
  aspect-ratio: 1.26;
}

.frame {
  border: 7px solid #25282a;
  background: #d7b565;
}

.frame img {
  border: 4px solid #d9c888;
}

.frame--midnight {
  padding: 9px;
  border-color: #18283a;
  box-shadow:
    inset 0 0 0 3px #8193a9,
    inset 0 0 0 6px #d9d4bb,
    var(--soft-shadow);
}

.frame--cobalt {
  padding: 7px;
  border-color: #1b4f8e;
  box-shadow:
    inset 0 0 0 3px #8cb7df,
    inset 0 0 0 6px #292c2e,
    var(--soft-shadow);
}

.frame--gilded {
  padding: 8px;
  border-color: #6d441c;
  box-shadow:
    inset 0 0 0 4px #d59c35,
    inset 0 0 0 7px #34261c,
    var(--soft-shadow);
}

.frame--coral {
  padding: 6px;
  border-color: #e05742;
  box-shadow:
    inset 0 0 0 3px #2e2f31,
    inset 0 0 0 6px #f4a062,
    var(--soft-shadow);
}

.frame--lacquer {
  padding: 7px;
  border-color: #191716;
  box-shadow:
    inset 0 0 0 3px #eee7d6,
    inset 0 0 0 6px #8b3328,
    var(--soft-shadow);
}

.artwork-dialog {
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--background);
  color: var(--ink);
  overflow-y: auto;
}

.artwork-dialog::backdrop {
  background: rgba(26, 22, 20, 0.82);
}

.artwork-dialog[open] {
  animation: dialog-enter 320ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes dialog-enter {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

.dialog-close {
  position: fixed;
  top: 22px;
  right: 24px;
  z-index: 10;
}

.dialog-wordmark {
  position: fixed;
  top: 22px;
  left: 24px;
  z-index: 10;
  color: #fffdfa;
}

.dialog-wordmark .brand-copy {
  text-shadow: 0 2px 8px rgba(31, 29, 27, 0.75);
}

.dialog-wordmark small {
  color: rgba(255, 253, 250, 0.78);
}

.physical-button {
  min-height: 48px;
  padding: 0 18px;
  border: var(--border);
  border-radius: var(--radius-button);
  background: var(--surface);
  box-shadow: var(--hard-shadow);
  font-family: var(--font-rounded);
  font-weight: 900;
  cursor: pointer;
}

.physical-button:active {
  transform: translateY(4px);
  box-shadow: 0 2px 0 var(--ink);
}

.artwork-detail {
  display: grid;
  grid-template-columns: minmax(0, 58%) minmax(360px, 42%);
  min-height: 100dvh;
}

.detail-image-wrap {
  position: sticky;
  top: 0;
  height: 100dvh;
  background: #1f1d1b;
}

.detail-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.detail-copy {
  padding: clamp(76px, 8vw, 130px) clamp(28px, 5vw, 76px) 80px;
}

.detail-artist {
  margin: 0 0 14px;
  color: var(--orange);
  font-family: var(--font-rounded);
  font-size: 0.9rem;
  font-weight: 900;
}

.detail-copy h2 {
  margin: 0 0 30px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.6rem, 4.2vw, 5.4rem);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 0.98;
}

.artwork-facts {
  display: grid;
  gap: 11px;
  margin: 0 0 44px;
}

.artwork-facts div {
  display: grid;
  grid-template-columns: 105px 1fr;
  gap: 16px;
}

.artwork-facts dt {
  color: #948d88;
}

.artwork-facts dd {
  margin: 0;
  font-weight: 650;
}

.artwork-source-link {
  color: #a92b16;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 0.1em;
}

.artwork-source-link:hover {
  color: #7e1f10;
}

.notice-card {
  margin: 0 0 44px;
  padding: 24px;
  border: var(--border);
  border-radius: var(--radius-card);
  background: var(--blush);
  box-shadow: var(--hard-shadow);
}

.notice-card h3,
.story-copy h3 {
  margin: 0 0 12px;
  font-family: var(--font-rounded);
  font-size: 1.35rem;
  font-weight: 900;
}

.notice-card p,
.story-copy p {
  margin: 0;
  font-size: 1.04rem;
  line-height: 1.65;
}

.story-copy {
  padding-top: 4px;
}

body:has(.artwork-dialog[open]) {
  overflow: hidden;
}

.document-page {
  min-height: 100dvh;
}

.document-shell {
  width: min(100% - 40px, 980px);
  margin: 0 auto;
  padding-bottom: 80px;
}

.document-shell .site-header {
  min-height: 76px;
  padding: 24px 0 16px;
  border-bottom: 1px solid var(--line);
}

.document-main {
  padding-top: clamp(54px, 9vw, 110px);
}

.document-heading {
  max-width: 730px;
  margin-bottom: 64px;
}

.document-heading h1 {
  margin: 0 0 18px;
  font-family: var(--font-rounded);
  font-size: clamp(3.2rem, 8vw, 6.8rem);
  font-weight: 900;
  letter-spacing: -0.065em;
  line-height: 0.92;
}

.document-heading p {
  max-width: 590px;
  margin: 0;
  color: #6f6965;
  font-size: 1.08rem;
  line-height: 1.6;
}

.document-content {
  max-width: 720px;
}

.document-content section {
  margin: 0 0 48px;
}

.document-content h2 {
  margin: 0 0 16px;
  font-family: var(--font-rounded);
  font-size: 1.55rem;
  font-weight: 900;
}

.document-content h3 {
  margin: 26px 0 10px;
  font-size: 1.04rem;
}

.document-content p,
.document-content li {
  color: #5f5a56;
  line-height: 1.7;
}

.document-content ul {
  padding-left: 1.25rem;
}

.document-content a {
  color: #b93016;
  font-weight: 700;
}

.legal-meta {
  display: inline-block;
  margin-top: 18px;
  padding: 8px 12px;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: 0 3px 0 var(--ink);
  color: var(--ink);
  font-family: var(--font-rounded);
  font-size: 0.72rem;
  font-weight: 850;
}

.faq-list {
  display: grid;
  gap: 16px;
}

.faq-list details {
  border: var(--border);
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow: 0 5px 0 var(--ink);
}

.faq-list summary {
  padding: 20px 56px 20px 22px;
  font-family: var(--font-rounded);
  font-weight: 900;
  cursor: pointer;
}

.faq-answer {
  padding: 0 22px 22px;
}

.faq-answer p {
  margin: 0;
  color: #5f5a56;
  line-height: 1.7;
}

.faq-answer a {
  color: #b93016;
  font-weight: 700;
}

.contact-card {
  max-width: 680px;
  padding: clamp(24px, 5vw, 46px);
  border: var(--border);
  border-radius: var(--radius-card);
  background: var(--blue);
  box-shadow: var(--hard-shadow);
}

.contact-card h2 {
  margin: 0 0 14px;
  font-family: var(--font-rounded);
  font-size: clamp(2rem, 5vw, 3.8rem);
  letter-spacing: -0.04em;
  line-height: 1;
}

.contact-card p {
  max-width: 520px;
  margin: 0 0 26px;
  font-size: 1.06rem;
  line-height: 1.6;
}

.contact-card .physical-button {
  display: inline-flex;
  align-items: center;
  color: var(--ink);
  text-decoration: none;
}

.support-links {
  max-width: 760px;
  margin-top: 68px;
}

.support-links-heading {
  max-width: 570px;
  margin-bottom: 24px;
}

.support-links-heading h2 {
  margin: 0 0 10px;
  font-family: var(--font-rounded);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 900;
  letter-spacing: -0.04em;
}

.support-links-heading p {
  margin: 0;
  color: #6f6965;
  line-height: 1.6;
}

.support-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.support-action {
  display: inline-flex;
  align-items: center;
  min-height: 52px;
  padding: 0 20px;
  border: var(--border);
  border-radius: var(--radius-button);
  box-shadow: 0 5px 0 var(--ink);
  font-family: var(--font-rounded);
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.support-action:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 0 var(--ink);
}

.support-action:active {
  transform: translateY(3px);
  box-shadow: 0 2px 0 var(--ink);
}

.support-action--bug {
  background: var(--orange);
  color: var(--surface);
}

.support-action--feature {
  background: var(--blue);
}

.support-action--updates {
  background: var(--blush);
}

.error-wordmark {
  margin-bottom: 72px;
}

.document-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 80px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.78rem;
}

@media (max-width: 1180px) {
  .split-shell {
    grid-template-columns: minmax(340px, 46%) minmax(0, 54%);
  }

  .site-header {
    display: grid;
  }

  .site-nav {
    justify-content: flex-start;
  }

  .hero-copy h1 {
    font-size: clamp(3rem, 6vw, 5.2rem);
  }

  .artwork--flowers { width: 24%; left: 6%; }
  .artwork--letter { width: 20%; right: 5%; }
  .artwork--bride { width: 43%; left: 31%; }
  .artwork--night { width: 29%; }
  .artwork--wheat { width: 29%; }
}

@media (max-width: 780px) {
  .split-shell {
    display: block;
  }

  .intro-panel {
    min-height: 100dvh;
    padding: 20px 20px 18px;
    border-right: 0;
  }

  .site-header {
    display: grid;
    gap: 14px;
  }

  .site-nav {
    width: calc(100vw - 40px);
    justify-content: flex-start;
    gap: 20px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .site-nav::-webkit-scrollbar {
    display: none;
  }

  .site-nav a {
    font-size: 0.78rem;
  }

  .hero-copy {
    padding: 38px 0 28px;
  }

  .hero-kicker {
    margin-bottom: 14px;
  }

  .hero-copy h1 {
    max-width: 9ch;
    font-size: clamp(3.1rem, 14.5vw, 5.2rem);
  }

  .hero-description {
    margin: 22px 0 26px;
    font-size: 1rem;
  }

  .intro-footer {
    align-items: flex-end;
  }

  .intro-footer p:first-child {
    max-width: 230px;
  }

  .gallery-panel {
    min-height: 94dvh;
  }

  .gallery-wall {
    bottom: 17%;
    background-size: 480px 480px;
  }

  .gallery-floor {
    height: 17%;
  }

  .gallery-room-title {
    top: 22px;
    min-width: 220px;
  }

  .artwork--flowers { top: 20%; left: 6%; width: 25%; }
  .artwork--letter { top: 16%; right: 5%; width: 22%; }
  .artwork--bride { top: 45%; left: 31%; width: 46%; }
  .artwork--night { top: 59%; left: 3%; width: 29%; }
  .artwork--wheat { top: 57%; right: -5%; width: 31%; }

  .gallery-hint {
    right: 18px;
    bottom: 18px;
    max-width: 225px;
  }

  .artwork-detail {
    display: block;
  }

  .detail-image-wrap {
    position: relative;
    height: 62dvh;
  }

  .dialog-close {
    top: 14px;
    right: 14px;
  }

  .dialog-wordmark {
    top: 14px;
    left: 14px;
  }

  .detail-copy {
    padding: 44px 20px 72px;
  }

  .detail-copy h2 {
    font-size: clamp(2.75rem, 12vw, 4.4rem);
  }

  .document-shell {
    width: min(100% - 32px, 980px);
  }

  .document-shell .site-header {
    min-height: 0;
  }

  .document-main {
    padding-top: 52px;
  }

  .document-heading {
    margin-bottom: 46px;
  }

  .document-heading h1 {
    font-size: clamp(3.2rem, 16vw, 5.2rem);
  }

  .document-footer {
    display: grid;
  }
}

@media (max-width: 440px) {
  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .hero-copy h1 {
    font-size: 3.05rem;
  }

  .intro-footer p:last-child {
    display: none;
  }

  .gallery-panel {
    min-height: 84dvh;
  }

  .artwork--flowers { top: 22%; }
  .artwork--letter { top: 19%; }
  .artwork--bride { top: 47%; width: 51%; left: 27%; }
  .artwork--night { top: 62%; width: 31%; }
  .artwork--wheat { top: 61%; width: 33%; }

  .support-actions {
    display: grid;
  }

  .support-action {
    justify-content: center;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
