@font-face {
  font-family: "DM Sans";
  src: url("assets/dm-sans.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
}
@font-face {
  font-family: "Young Serif";
  src: url("assets/young-serif.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "DM Serif Text";
  src: url("assets/dm-serif-text-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
}

:root {
  --espresso: #241410;
  --walnut: #45221b;
  --oxblood: #431922;
  --ink: #342019;
  --cream: #fff0cf;
  --paper: #f7ecd6;
  --gold: #ffbe46;
  --copper: #993b22;
  --body: "DM Sans", system-ui, sans-serif;
  --display: "Young Serif", Georgia, serif;
  --italic: "DM Serif Text", Georgia, serif;
  --gutter: clamp(1.25rem, 5.6vw, 6rem);
  --sunset: linear-gradient(to bottom, #ffce69 0 24%, #f99a3c 24% 48%, #dd5529 48% 72%, #9f2928 72% 100%);
  color: var(--ink);
  background: var(--espresso);
  font-family: var(--body);
  line-height: 1.55;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body, p, h1, h2, h3, figure { margin: 0; }
img { display: block; max-width: 100%; }
button, input, textarea { font: inherit; }
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #3e8fbc; outline-offset: 4px; }
::selection { background: #ef8c35; color: #291012; }
[hidden] { display: none !important; }
.wrap, .portal-wrap { width: min(100% - 2 * var(--gutter), 82rem); margin-inline: auto; }
.skip-link { position: fixed; z-index: 5; top: .5rem; left: .5rem; padding: .65rem 1rem; color: var(--ink); background: var(--cream); transform: translateY(-160%); }
.skip-link:focus { transform: none; }

.site-header, .portal-head {
  position: relative;
  color: var(--cream);
  background: linear-gradient(180deg, #2a1915, #20120f);
  border-bottom: 1px solid #77533b;
}
.header-inner, .site-header nav, .brand, .actions, .game-actions, .button, .footer-inner, .submit-line, .portal-tools {
  display: flex;
  align-items: center;
}
.header-inner { min-height: 5.35rem; justify-content: space-between; gap: 2rem; }
.brand { flex: none; width: fit-content; color: var(--cream); text-decoration: none; }
.brand img, .portal-logo img { width: clamp(10rem, 15.5vw, 14.4rem); height: auto; }
.site-header nav { gap: clamp(1.1rem, 2.75vw, 2.8rem); }
.site-header nav a { color: #f2e2c9; font-size: .9375rem; line-height: 1.25; font-weight: 600; text-decoration: none; }
.site-header nav a:hover { color: #ffd28b; }
.nav-link, .nav-contact { padding-block: .72rem; }
.site-header nav :is(.nav-client, [href*="clients"]) {
  border: 1px solid #bd8c56;
  border-radius: 2rem;
  padding: .62rem 1.08rem;
  color: #ffe5ad;
  white-space: nowrap;
}
.site-header nav :is(.nav-client, [href*="clients"]):hover { background: #4b2b21; }

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--cream);
  background: #29110d;
}
.hero-art, .hero::before { position: absolute; inset: 0; }
.hero-art { z-index: -2; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 52%; }
.hero::before {
  content: "";
  z-index: -1;
  background: linear-gradient(90deg, #230e0aeb 0%, #260e0bbd 30%, #270d086b 50%, #2b0e0400 70%);
}
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: .58rem; background: var(--sunset); }
.hero-inner { display: flex; align-items: center; min-height: clamp(34rem, 42vw, 44rem); padding-block: clamp(4rem, 6vw, 6rem); }
.hero-copy { width: min(59%, 48rem); }
.eyebrow, .portal-kicker {
  display: flex;
  align-items: center;
  gap: .72rem;
  color: var(--copper);
  font-size: .8125rem;
  font-weight: 700;
  letter-spacing: .145em;
  line-height: 1.35;
  text-transform: uppercase;
}
.eyebrow .rule {
  flex: none;
  width: 2.05rem;
  height: .52rem;
  border-radius: .1rem 1rem 1rem .1rem;
  background: var(--sunset);
}
.hero .eyebrow, .capabilities .eyebrow { color: #ffcc81; }
h1, h2, .project-copy h3 { font-family: var(--display); font-weight: 400; }
.hero h1 {
  margin: 1.2rem 0 1.45rem;
  font-size: clamp(3rem, 5.15vw, 5.8rem);
  line-height: 1.05;
  letter-spacing: -.062em;
  text-shadow: 0 2px 14px #200b0866;
}
.hero h1 em { font-family: var(--italic); font-weight: 400; color: #ffbf58; letter-spacing: -.055em; }
.hero-intro { max-width: 29rem; color: #f6e5ce; font-size: clamp(1.07rem, 1.45vw, 1.26rem); line-height: 1.57; }
.actions { flex-wrap: wrap; gap: 1.6rem; margin-top: 1.9rem; }
.button {
  width: fit-content;
  justify-content: center;
  gap: .65rem;
  min-height: 3rem;
  padding: .75rem 1.4rem;
  border: 1px solid transparent;
  border-radius: .58rem;
  font: 700 .98rem/1.3 var(--body);
  text-decoration: none;
  transition: transform .17s ease, box-shadow .17s ease, filter .17s ease;
}
.button-lime, .button-primary {
  color: #381a0d;
  background: linear-gradient(180deg, #ffcf68 0%, #ffb544 57%, #f8a038 100%);
  border-color: #efaa48;
  box-shadow: inset 0 1px 0 #fff0b8, 0 2px 0 #a65322, 0 4px 12px #250c0b35;
}
.button-light {
  color: #fff1d4;
  background: linear-gradient(180deg, #793829, #622a24);
  border-color: #6e3527;
  box-shadow: inset 0 1px 0 #a96946, 0 2px 0 #431f18;
}
.button:hover { transform: translateY(-1px); filter: brightness(1.055); }
.button:active { transform: translateY(1px); }
.button:disabled { opacity: .67; cursor: wait; transform: none; }
.text-link { color: #fff0d1; font-size: .97rem; font-weight: 600; text-decoration-color: #dbab72; text-underline-offset: .31em; }
.text-link:hover { color: #ffcd7a; }

.spotlight {
  color: var(--ink);
  background: radial-gradient(ellipse at 88% 20%, #fff5df 0%, transparent 72%), #f4e4c7;
  padding-block: clamp(3.6rem, 6.4vw, 6.4rem);
}
.feature-grid { display: grid; grid-template-columns: 1.15fr 1fr; align-items: center; gap: clamp(2.7rem, 6.6vw, 7.1rem); }
.game-cover {
  position: relative;
  display: block;
  overflow: hidden;
  padding: .4rem;
  border: 1px solid #6e4230;
  border-radius: 1rem;
  background: linear-gradient(150deg, #fce3a7, #906443 28%, #44281c 55%, #e4b87f 85%, #85543b);
  box-shadow: inset 0 0 0 1px #f4e1b1a1, 0 .55rem 1.6rem #54261228;
}
.game-cover img { width: 100%; height: auto; border-radius: .58rem; aspect-ratio: 2.04; object-fit: cover; }
.game-cover:focus-visible { outline-offset: 5px; }
.cover-play {
  position: absolute;
  right: 1.15rem;
  bottom: 1.15rem;
  display: grid;
  place-items: center;
  width: 2.85rem;
  height: 2.85rem;
  border: 1px solid #fde3ad;
  border-radius: 50%;
  color: #30190f;
  background: #ffd88ce8;
  box-shadow: 0 2px 6px #220e087d;
  transition: background .16s ease;
}
.game-cover:hover .cover-play { background: #fff0c8; }
.play-icon { display: inline-block; width: 0; height: 0; border-top: .33em solid transparent; border-bottom: .33em solid transparent; border-left: .55em solid currentColor; }
.cover-play .play-icon { margin-left: .15rem; font-size: 1.1rem; }
h2 { font-size: clamp(2.6rem, 4.1vw, 4.55rem); line-height: 1.08; letter-spacing: -.062em; }
.feature-copy h2 { margin: .86rem 0 .26rem; }
.credit { color: #854029; font-size: .96rem; font-weight: 600; margin-bottom: 1rem; }
.feature-copy > p:not(.eyebrow, .credit), .section-intro > p:not(.eyebrow) { font-size: 1.08rem; line-height: 1.65; }
.feature-copy > p:not(.eyebrow, .credit) { max-width: 34rem; color: #534038; }
.game-actions { flex-wrap: wrap; gap: 1.05rem; margin-top: 1.6rem; }
.demo-note { font-size: .88rem; color: #674a3a; }

.split-layout { display: grid; grid-template-columns: .83fr 1.17fr; gap: clamp(3rem, 9vw, 9.5rem); }
.capabilities, .contact { padding-block: clamp(4rem, 7vw, 7.1rem); }
.capabilities {
  color: var(--cream);
  background: radial-gradient(ellipse at 0% 85%, #6a2b28 0%, transparent 65%), linear-gradient(110deg, #442320, #34181e 70%, #32151a);
  border-block: 1px solid #774a37;
}
.section-intro h2 { margin: .9rem 0 1.05rem; }
.section-intro > p:not(.eyebrow) { max-width: 24.5rem; color: #523b2f; }
.capabilities .section-intro > p:not(.eyebrow) { color: #e9d8c0; }
.services { border-top: 1px solid #976750; }
.service { display: grid; grid-template-columns: 2.75rem 1fr; gap: clamp(.9rem, 1.8vw, 1.5rem); padding-block: 1.45rem; border-bottom: 1px solid #7b5146; }
.service svg {
  width: 2.65rem;
  height: 2.65rem;
  padding: .37rem;
  color: #ffca80;
  background: #512a2b;
  border: 1px solid #926149;
  border-radius: .56rem;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}
h3 { font-size: clamp(1.3rem, 1.85vw, 1.65rem); line-height: 1.26; letter-spacing: -.037em; }
.service p { margin-top: .45rem; max-width: 37rem; color: #e5d0bb; font-size: 1rem; line-height: 1.62; }

.contact {
  color: #3a2016;
  background: radial-gradient(ellipse at 100% 0%, #ffdc95 0%, transparent 67%), linear-gradient(100deg, #edb866, #f3c479);
}
.contact .eyebrow { color: #743321; }
.contact .eyebrow .rule { background: linear-gradient(to bottom, #b44a26 0 32%, #95331f 32% 65%, #602728 65%); }
.contact .section-intro > p:not(.eyebrow) { color: #5a3a24; }
.form-fields { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 1.22rem 1rem; }
.form-fields label, .portal-form label { display: block; font-weight: 700; font-size: .96rem; }
.form-fields .wide { grid-column: 1 / -1; }
input, textarea {
  display: block;
  width: 100%;
  padding: .74rem .88rem;
  margin-top: .38rem;
  border: 1px solid #a97949;
  border-radius: .4rem;
  background: #fff3d8;
  color: var(--ink);
  box-shadow: inset 0 1px 3px #855d3d15;
  font-size: 1rem;
}
textarea { resize: vertical; min-height: 6.8rem; }
input:focus-visible, textarea:focus-visible { outline: 2px solid #723721; outline-offset: 2px; }
.bot-field { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.submit-line { gap: 1.1rem; margin-top: 1.35rem; }
.submit-line button { flex: none; background: linear-gradient(#743a2a, #58251e); color: #fff0cd; border-color: #713d29; box-shadow: inset 0 1px 0 #a16c4e, 0 2px 0 #4a251a; }
.form-status, .contact-alternative { font-size: .94rem; }
.contact-alternative { margin-top: .65rem; }
.site-footer { background: var(--espresso); color: #e4d2b9; border-top: 1px solid #7b543e; }
.footer-inner { min-height: 5.1rem; gap: .6rem 1.75rem; flex-wrap: wrap; padding-block: 1rem; font-size: .89rem; }
.footer-inner a { margin-left: auto; color: #ffe3a9; text-underline-offset: .26em; }

.demo-page, body.portal-demo { display: grid; grid-template-rows: auto minmax(0, 1fr); height: 100vh; height: 100dvh; background: #170c0a; }
.demo-bar { display: flex; align-items: center; gap: 1.1rem; padding: .33rem clamp(.7rem, 2.8vw, 2.6rem); min-height: 2.85rem; color: var(--cream); background: #281713; border-bottom: 1px solid #986b48; font-size: .9rem; }
.studio-return { display: inline-flex; align-items: center; gap: .57rem; color: #ffcd81; font-weight: 700; text-decoration: none; }
.studio-return img { width: 1.55rem; height: 1.55rem; object-fit: contain; }
.demo-title { border-left: 1px solid #785343; padding-left: 1rem; font-weight: 700; }
.demo-format { margin-left: auto; color: #e8d2b8; }
.expand-game { text-underline-offset: .23em; }
.demo-stage, .demo-stage iframe, .portal-demo iframe { width: 100%; height: 100%; min-height: 0; }
.demo-stage iframe, .portal-demo iframe { display: block; border: 0; }

.portal-page { min-height: 100vh; min-height: 100dvh; background: var(--paper); color: var(--ink); }
.portal-page > .portal-wrap { width: 100%; }
.portal-head, .portal-main { padding-inline: max(var(--gutter), calc((100% - 82rem) / 2)); }
.portal-head { display: flex; align-items: center; justify-content: space-between; gap: 1.25rem; min-height: 5.35rem; padding-block: .65rem; border-bottom: 2px solid #b77442; }
.portal-logo { display: inline-block; flex: none; }
.portal-tools { flex-wrap: wrap; justify-content: flex-end; gap: .5rem 1.15rem; font-size: .94rem; }
.portal-head a:not(.portal-logo) { color: var(--cream); text-underline-offset: .28em; }
.portal-logout { color: #ffdda2; background: transparent; border: 1px solid #b78958; border-radius: 2rem; padding: .45rem .92rem; font-size: .9rem; font-weight: 600; }
.portal-main { padding-block: clamp(3rem, 6vw, 5.75rem); }
.portal-main h1 { font-size: clamp(2.7rem, 4.7vw, 4.9rem); line-height: 1.09; letter-spacing: -.055em; margin: .65rem 0 .75rem; }
.portal-main h2 { font-size: clamp(1.75rem, 3vw, 2.65rem); }
.portal-main > p:not(.portal-kicker) { max-width: 42rem; color: #6c4e40; }
.portal-page.portal-login {
  background: linear-gradient(90deg, #2c110feb, #2c100f9c 48%, #2c100f30), url("assets/studio-hero.webp") center / cover, var(--espresso);
}
.portal-panel {
  width: min(100%, 32rem);
  padding: clamp(1.45rem, 3.3vw, 2.9rem);
  color: var(--ink);
  background: #fff1d7;
  border: 1px solid #d4a871;
  border-radius: .95rem;
  box-shadow: 0 1.25rem 3.7rem #1e090b40;
}
.portal-panel h1, .portal-panel h2 { font-size: clamp(2.3rem, 3.6vw, 3.65rem); line-height: 1.05; letter-spacing: -.055em; margin: .65rem 0 .9rem; }
.portal-panel p:not(.portal-kicker, .portal-error) { color: #614637; }
.portal-form { display: grid; gap: 1rem; margin-top: 1.3rem; }
.portal-form .button { margin-top: .15rem; }
.portal-form input { background: #fffbef; }
.portal-error { width: min(100%, 32rem); padding: .75rem .9rem; margin-bottom: 1rem; border-left: 3px solid #a24429; background: #f6d9bd; color: #702519; }
.portal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 22.5rem), 1fr)); gap: 1.35rem; margin-top: 2rem; }
.project-card { display: flex; flex-direction: column; overflow: hidden; background: #fff7e7; color: var(--ink); border: 1px solid #cbae84; border-radius: .85rem; box-shadow: 0 .3rem 1.15rem #663f2514; }
.project-cover, .project-cover img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.project-copy { padding: 1.4rem; }
.project-copy h2, .project-copy h3 { margin: 0; font-size: clamp(1.55rem, 2.2vw, 2.05rem); line-height: 1.15; letter-spacing: -.045em; }
.project-copy p { color: #694d3e; margin-top: .48rem; }
.project-copy .button { margin-top: 1.12rem; }

@media (max-width: 1050px) {
  .header-inner { gap: 1.25rem; }
  .hero-inner { min-height: 32.5rem; }
  .hero-copy { width: 62%; }
  .hero-intro { max-width: 25rem; }
  .feature-grid { gap: 2.5rem; grid-template-columns: 1.05fr 1fr; }
  .split-layout { gap: 3.5rem; grid-template-columns: .84fr 1.16fr; }
}
@media (max-width: 780px) {
  .header-inner { min-height: 4.6rem; }
  .site-header nav { gap: 1.05rem; }
  .site-header nav a { font-size: .875rem; }
  .site-header nav :is(.nav-client, [href*="clients"]) { padding: .52rem .8rem; }
  .split-layout { gap: 2.25rem; }
  .feature-grid { gap: 1.85rem; }
}
@media (max-width: 720px) {
  .hero { display: flex; flex-direction: column; }
  .hero::before { background: radial-gradient(ellipse at 87% 0%, #54221977, transparent 82%), linear-gradient(#2b130f, #29100d); }
  .hero-inner { order: -1; align-items: start; min-height: 0; padding-block: 2.6rem .5rem; }
  .hero-copy { width: min(100%, 37rem); }
  .hero h1 { font-size: clamp(2.65rem, 8.7vw, 4.25rem); margin: .85rem 0 1rem; }
  .hero-intro { max-width: 31rem; }
  .actions { margin-top: 1.35rem; }
  .hero-art { position: relative; inset: auto; z-index: 0; width: 100%; height: clamp(11rem, 48vw, 18rem); }
  .hero-art img { object-position: 50% 49%; }
  .hero-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(#2b120f, transparent 26%); }
  .spotlight { padding-block: 3.25rem; }
  .feature-grid, .split-layout { grid-template-columns: 1fr; gap: 2rem; }
  .feature-copy { order: -1; }
  .feature-copy h2 { margin-top: .6rem; }
  .section-intro h2 { margin: .65rem 0 .8rem; }
  .section-intro > p:not(.eyebrow) { max-width: 32rem; }
  .capabilities, .contact { padding-block: 3.6rem; }
  .game-cover { padding: .28rem; border-radius: .72rem; }
  .game-cover img { border-radius: .46rem; }
  .portal-head { min-height: 4.5rem; }
}
@media (max-width: 630px) {
  .header-inner { flex-wrap: wrap; justify-content: flex-start; gap: .12rem clamp(.75rem, 4vw, 1.45rem); padding-block: .75rem .3rem; }
  .site-header nav { display: contents; }
  .header-inner .brand { order: 0; }
  .site-header nav :is(.nav-client, [href*="clients"]) { order: 1; margin-left: auto; }
  .header-inner::after { content: ""; order: 1; flex-basis: 100%; height: 0; }
  .site-header nav a:not([href*="clients"], .nav-client) { order: 2; padding: .42rem 0; }
  .portal-page.portal-login { background: linear-gradient(#3c211cdb, #2b1611b8), url("assets/studio-hero-mobile.webp") center / cover, var(--espresso); }
}
@media (max-width: 490px) {
  .form-fields { grid-template-columns: 1fr; }
  .submit-line { flex-direction: column; align-items: flex-start; gap: .6rem; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: .22rem; padding-block: 1.25rem; }
  .footer-inner a { margin: .35rem 0 0; }
  .demo-bar { gap: .55rem; justify-content: space-between; flex-wrap: wrap; font-size: .8rem; }
  .demo-title { display: none; }
  .demo-format { margin-left: 0; }
  .portal-head { gap: .72rem; flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
