/* TARLIS: the same rooms, with a quieter entrance and a few less certain edges. */
@font-face {
  font-family: 'Italianno';
  src: url('assets/fonts/italianno.woff') format('woff');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

:root { --signature: 'Italianno', 'Cormorant Garamond', Georgia, serif; }
html.map-open { overflow: hidden; }
.site-header { justify-content: space-between; gap: 24px; }
.signature { min-height: 48px; gap: 15px; color: var(--brass); }
.tarlis-sigil { flex: 0 0 auto; width: 44px; height: 44px; }
.site-header .signature .tarlis-wordmark {
  display: block;
  font: 400 1.4rem/1.1 Georgia, 'Times New Roman', serif;
  letter-spacing: .22em;
  color: var(--paper);
}
.menu-button { min-height: 48px; padding-inline: 24px 0; }
.menu-button[aria-expanded='true'] .menu-lines { border-color: var(--paper); }

.hero-content { max-width: 990px; padding-top: clamp(155px, 19svh, 205px); }
.hero h1.architect-title {
  font: 400 clamp(8rem, 13.8vw, 12.8rem)/.86 var(--signature);
  letter-spacing: 0;
  margin: 20px 0 34px;
  text-wrap: nowrap;
  text-shadow: 0 3px 28px #07110c90;
}
.architect-der { display: block; font-size: .63em; line-height: .9; }
.architect-name { display: block; margin-left: .06em; color: #e2d2b4; }
.hero-thought { margin-bottom: 24px; }
.hero .quiet-link { display: inline-flex; align-items: center; gap: 25px; min-height: 44px; margin-top: 0; font-size: .9375rem; }
.hero .quiet-link span { color: var(--brass); font-size: 1.25rem; }
.hero-bottom { justify-content: space-between; }
.hero-bottom .world-sign { font-size: .75rem; letter-spacing: .18em; }
.hero-bottom .scroll-link { min-height: 44px; font-size: .875rem; }
.hero-scene { background-image: url('assets/archive-tarlis-refined.webp'); transform: scale(1.014); }
.ambient-light {
  inset: -2%;
  background: radial-gradient(ellipse at 79% 46%, #eab57932, transparent 29%);
  mix-blend-mode: screen;
  animation: wandering-light 18s ease-in-out infinite alternate;
}
@keyframes wandering-light {
  from { opacity: .16; transform: translate3d(-.6%, .4%, 0); }
  to { opacity: .5; transform: translate3d(.6%, -.4%, 0); }
}

/* The portrait remains an original-photo space, set within the existing room. */
.personal-teaser { padding-top: 104px; padding-bottom: 104px; }
.teaser-album, .portrait-page {
  background: linear-gradient(115deg, #202b23ee, #233025e8), url('assets/archive.webp') 68% 48% / cover;
  border-top: 1px solid #bdad7836;
  border-right: 1px solid #bdad7836;
  box-shadow: inset 7px 0 8px #060c0770, 18px 18px 0 -8px #a28a5620, 0 20px 45px #060c0729;
}
.teaser-album { transform: perspective(1100px) rotateY(3deg) rotate(-2deg); }
.photo-space { position: relative; }
.photo-space::after {
  content: '';
  position: absolute;
  inset: 9px;
  border: 1px solid #d1bc8a24;
  pointer-events: none;
}
.photo-space:has(img) { padding: 0; }
.photo-space img { width: 100%; height: 100%; object-fit: cover; }
.photo-space small, .album-tag { font-size: .75rem; }
.teaser-copy .eyebrow { max-width: 100%; }
.worlds-section { border-top: 1px solid #b99c6b24; }
.world-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); }
.world-card { justify-content: flex-end; }
.world-card:focus-visible { outline-offset: 4px; border-color: var(--brass); }
.world-info h3 { overflow-wrap: anywhere; }
.card-bottom { font-size: .875rem; }

/* Existing archive details appear through the surface, without another scene. */
.archive-teaser {
  background: linear-gradient(90deg, #1b2721 12%, #1b2721f5 48%, #17251edb), url('assets/archive.webp') 80% 55% / cover;
}
.sample-paper { transform-origin: 25% 75%; }
.paper-catalog, .paper-bottom, .art-label { font-size: .75rem; }
.reserved-line { gap: 12px; }
.footer-mark { font-family: Georgia, 'Times New Roman', serif; font-size: 1.35rem; letter-spacing: .22em; }
.footer-mark span { font: 400 1.125rem/1.4 var(--serif); letter-spacing: .02em; color: var(--paper); }
.site-footer > a:last-child, .back-link { min-height: 44px; display: inline-flex; align-items: center; }

/* The room plan is an offset threshold, with the same sigil in its margin. */
.room-map {
  isolation: isolate;
  background: linear-gradient(125deg, #18251efc, #15241ded), url('assets/archive.webp') 76% 50% / cover;
  border-color: #b79b6980;
  box-shadow: 0 30px 150px #000a, inset 0 0 0 10px #08171050;
}
.room-map::before {
  content: '';
  position: absolute;
  z-index: -1;
  width: 260px;
  height: 260px;
  right: -75px;
  top: -58px;
  opacity: .05;
  background: url('assets/tarlis-sigil.svg') center / contain no-repeat;
  pointer-events: none;
}
.room-map nav { border-left: 1px solid #c4a3742e; }
.room-map nav a {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px 20px;
  padding: 18px 14px 18px 22px;
  font-size: 1.875rem;
  line-height: 1.16;
  border-top-color: #b99c6b30;
  transition: background .3s ease, color .3s ease;
}
.room-map nav a:nth-child(2), .room-map nav a:nth-child(4) { margin-left: 12px; }
.room-map nav a:nth-child(3) { margin-left: 24px; }
.room-map nav a small { font: .8125rem/1.45 var(--sans); }
.room-map nav a:hover, .room-map nav a:focus-visible, .room-map nav a[aria-current] { background: #d8bb7e09; color: #e4c798; }
.close-menu { min-width: 44px; min-height: 44px; }
.map-top { align-items: flex-start; }
.map-top .eyebrow { padding-top: 14px; }
.map-title { line-height: 1.1; }

@media (max-width: 1100px) {
  .site-header .signature .tarlis-wordmark { display: block; font-size: 1.35rem; }
  .hero-content { max-width: 820px; }
}
@media (max-width: 700px) {
  .site-header { gap: 12px; }
  .signature { gap: 11px; }
  .tarlis-sigil { width: 36px; height: 36px; }
  .site-header .signature .tarlis-wordmark { font-size: 1.2rem; letter-spacing: .19em; }
  .menu-button { padding: 10px 0 10px 12px; font-size: .875rem; }
  .hero { min-height: 660px; height: 94svh; max-height: 880px; }
  .hero-content { padding: clamp(132px, 20svh, 190px) 7% 110px; max-width: none; }
  .hero h1.architect-title { font-size: clamp(5.6rem, 25.6vw, 10.5rem); margin: 22px 0 31px; line-height: .94; }
  .architect-der { font-size: .69em; }
  .architect-name { margin-left: .025em; }
  .hero-thought { font-size: 1rem; margin-bottom: 21px; }
  .hero .quiet-link { font-size: .875rem; gap: 22px; }
  .hero-bottom { height: 75px; flex-wrap: nowrap; gap: 12px; }
  .hero-bottom .world-sign { font-size: .75rem; letter-spacing: .12em; }
  .hero-bottom .scroll-link { font-size: 0; min-width: 44px; justify-content: flex-end; }
  .hero-bottom .scroll-link span { font-size: 1.25rem; }
  .personal-teaser { padding-top: 72px; padding-bottom: 74px; gap: 46px; }
  .teaser-album { margin-inline: 5px; }
  .world-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; overflow: visible; margin: 0; padding: 0; scroll-snap-type: none; }
  .world-card { height: 400px; min-width: 0; width: 100%; }
  .world-info { padding: 24px; }
  .world-info h3 { font-size: clamp(2rem, 9vw, 2.7rem); }
  .world-info .eyebrow, .paper-catalog, .album-tag, .art-label { font-size: .75rem; }
  .world-info .eyebrow { letter-spacing: .075em; }
  .card-bottom { font-size: .875rem; }
  .margin-note { margin-top: 25px; }
  .room-map { width: calc(100% - 24px); max-height: calc(100svh - 24px); padding: 20px; }
  .room-map nav a { grid-template-columns: minmax(0, 1fr); padding: 14px 12px; gap: 5px; font-size: clamp(1.45rem, 6.1vw, 1.9rem); }
  .room-map nav a small { grid-column: 1; font-size: .75rem; margin: 0; }
  .room-map nav a:nth-child(2), .room-map nav a:nth-child(4) { margin-left: 7px; }
  .room-map nav a:nth-child(3) { margin-left: 14px; }
  .map-top .eyebrow { font-size: .75rem; letter-spacing: .075em; padding-top: 12px; }
  .map-title { font-size: clamp(1.9rem, 7.5vw, 2.4rem); margin: 25px 0; }
  .map-note { font-size: 1.125rem; line-height: 1.4; }
  .close-menu { padding: 5px; }
  .close-menu span { margin: 0; }
  .outline-button { max-width: 100%; gap: 18px; }
  .sky-teaser { grid-template-columns: minmax(0, 1fr) 68px; }
  .sky-teaser h2 { font-size: clamp(1.8rem, 8.5vw, 2.5rem); }
}
@media (max-width: 360px) {
  .signature { gap: 8px; }
  .site-header .signature .tarlis-wordmark { font-size: 1.08rem; letter-spacing: .17em; }
  .menu-button { gap: 9px; }
  .hero .eyebrow { letter-spacing: .09em; }
  .world-info { padding: 21px; }
  .sample-paper { margin-right: 8px; padding: 25px 22px 20px; }
  .sample-text { font-size: 3.1rem; }
  .paper-bottom { flex-wrap: wrap; gap: 8px; }
  .portrait-page { padding: 15px; }
  .portrait-mount .photo-space { padding: 20px 10px; }
}
@media (hover: none) {
  .world-card:hover { transform: none; }
  .world-card:hover .world-image { transform: none; }
  .sample-paper:hover { transform: rotate(5deg); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* A separate composition for narrow windows; desktop rules remain untouched. */
@media (max-width: 700px) {
  .site-header { height: 72px; padding-inline: max(18px, 5.5vw); }
  .site-header .signature .tarlis-wordmark { font-size: 1.2rem; }
  .menu-button { flex: 0 0 auto; }
  .menu-lines { flex: 0 0 20px; }
  .room-map::before { right: 0; width: min(260px, 100%); }

  .hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto auto auto auto;
    height: auto;
    min-height: 0;
    max-height: none;
    padding-top: clamp(104px, 14svh, 124px);
    background: #101a15;
  }
  .hero-content { display: contents; }
  .hero .eyebrow {
    grid-area: 1 / 1;
    position: relative;
    z-index: 1;
    margin: 0 7% 18px;
    font-size: .75rem;
    letter-spacing: .1em;
  }
  .hero h1.architect-title {
    grid-area: 2 / 1;
    position: relative;
    z-index: 1;
    font-size: clamp(5rem, 22.5vw, 6.6rem);
    line-height: .88;
    margin: 0 7% 22px;
  }
  .architect-der { font-size: .66em; line-height: .96; }
  .architect-name { margin-left: .035em; }
  .hero-thought {
    grid-area: 3 / 1;
    position: relative;
    z-index: 1;
    font-size: 1rem;
    line-height: 1.5;
    margin: 0 7% 6px;
  }
  .hero-scene {
    grid-area: 4 / 1;
    position: relative;
    inset: auto;
    height: clamp(260px, 82vw, 420px);
    transform: none;
    background-color: #101a15;
    background-size: auto 100%;
    background-position: right center;
    background-repeat: no-repeat;
  }
  .hero-shade {
    grid-area: 4 / 1;
    position: relative;
    inset: auto;
    pointer-events: none;
    background: linear-gradient(180deg, #101a15 0%, #101a1530 12%, transparent 28%, transparent 68%, #101a15d9 94%, #101a15 100%);
  }
  .ambient-light {
    grid-area: 4 / 1;
    position: relative;
    inset: 0;
    background: radial-gradient(ellipse at 59% 46%, #eab57925, transparent 46%);
    pointer-events: none;
  }
  .hero .quiet-link {
    grid-area: 4 / 1;
    position: relative;
    z-index: 1;
    align-self: end;
    justify-self: start;
    margin: 0 7% 10px;
    min-height: 44px;
    color: #d8dbce;
    font-size: .875rem;
  }
  .hero-bottom {
    grid-area: 5 / 1;
    position: relative;
    inset: auto;
    height: 68px;
    margin-inline: 7%;
    background: transparent;
  }
  .hero-bottom .world-sign { letter-spacing: .1em; }

  .personal-teaser { padding-top: 62px; padding-bottom: 64px; gap: 40px; }
  .personal-teaser h2, .worlds-section h2, .archive-teaser h2 {
    font-size: clamp(2.35rem, 10.6vw, 2.8rem);
    line-height: 1.07;
  }
  .worlds-section { padding-top: 64px; padding-bottom: 64px; }
  .world-card { height: clamp(360px, 98vw, 410px); }
  .game-card .world-image {
    background-size: auto 78%;
    background-position: right top;
    background-repeat: no-repeat;
  }
  .archive-teaser-inner { gap: 42px; }
  .sample-paper { transform: rotate(3deg); }
  .sample-paper:hover { transform: rotate(3deg); }
  .sky-teaser { padding-top: 60px; padding-bottom: 60px; }
}

@media (max-width: 360px) {
  .site-header .signature .tarlis-wordmark { font-size: 1.1rem; }
  .signature { gap: 8px; }
  .menu-button { padding-left: 8px; gap: 9px; }
  .hero h1.architect-title { margin-bottom: 20px; }
  .hero .eyebrow { letter-spacing: .08em; }
}
