:root {
  color-scheme: dark;
  font-family: "Segoe UI", Inter, system-ui, sans-serif;
  font-synthesis: none;
  --bg: #0c1028;
  --sidebar: #0b0e22;
  --surface: #181e3e;
  --line: #ffffff20;
  --text: #f8f8ff;
  --muted: #c5c8df;
  --mint: #83e5d5;
  --yellow: #ffda8e;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
.icon { width: 22px; height: 22px; flex: none; }
.skip-link { position: absolute; z-index: 50; left: 12px; top: -80px; background: #fff; color: #10132c; padding: 12px 16px; border-radius: 10px; font-weight: 700; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 4px; }

.app-shell {
  display: grid;
  grid-template-columns: 206px minmax(0, 1fr);
  min-height: 100vh;
  background: radial-gradient(ellipse 55% 40% at 60% 0%, #252b67 0%, transparent 68%), linear-gradient(135deg, #0e1028 0%, #141432 55%, #0c1a31 100%);
}
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 32px 19px 28px;
  border-right: 1px solid #ffffff18;
  background: linear-gradient(180deg, #0b0e22 0%, #11112d 75%, #0d1c2b 100%);
}
.sidebar-header { margin: 0 1px 38px; }
.brand { display: block; width: 151px; margin-bottom: 16px; }
.brand img { display: block; width: 100%; height: auto; }
.language-switch { display: inline-flex; gap: 3px; padding: 3px; border: 1px solid #ffffff34; border-radius: 11px; background: #ffffff0b; }
.language-switch button { min-width: 44px; min-height: 44px; padding: 8px; border: 0; border-radius: 7px; background: transparent; color: #d0d4e9; font: inherit; font-size: 12px; font-weight: 800; letter-spacing: .05em; cursor: pointer; transition: background .18s ease, color .18s ease; }
.language-switch button:hover { color: #fff; background: #ffffff20; }
.language-switch button[aria-pressed="true"] { background: #a6f1de; color: #102c36; box-shadow: 0 2px 7px #0004; }
.side-nav { display: grid; gap: 10px; }
.nav-link { display: flex; align-items: center; gap: 13px; min-height: 56px; padding: 8px 11px; border: 1px solid transparent; border-radius: 15px; color: #c2c5dc; font-size: 16px; font-weight: 700; transition: background .2s ease, color .2s ease, transform .2s ease; }
.nav-link:hover { background: #ffffff12; color: #fff; transform: translateX(2px); }
.nav-link.active { background: linear-gradient(100deg, #5c4a9b88, #2d3b6780); border-color: #9a87d755; color: #fff; box-shadow: inset 3px 0 #ad98fa, 0 8px 25px #0000002a; }
.nav-icon { display: grid; place-items: center; width: 37px; height: 37px; border: 1px solid #ffffff24; border-radius: 11px; background: #ffffff0b; color: #91dedb; }
.active .nav-icon { background: #8be1d526; border-color: #8be1d580; color: #a4f1df; }
.sidebar-art { height: 138px; margin-top: auto; border: 1px solid #ffffff33; border-radius: 16px; background: linear-gradient(180deg, transparent 25%, #15163890 100%), url('/public/optimized/aventi-hero.webp') 69% center/cover; box-shadow: 0 12px 32px #00000040; }
.sidebar-tagline { margin: 16px 8px 0; color: #bfc5d9; line-height: 1.45; font-size: 13px; }

.page-wrap { min-width: 0; display: flex; flex-direction: column; }
.topbar { height: 82px; display: flex; justify-content: space-between; align-items: center; padding: 0 clamp(26px, 4.4vw, 74px); border-bottom: 1px solid #ffffff17; }
.topbar-label { color: #b7bee0; font-size: 11px; font-weight: 800; letter-spacing: .2em; }
.topbar-spark { width: 26px; height: 26px; }
main { width: 100%; max-width: 1500px; min-height: calc(100vh - 143px); margin: 0 auto; padding: 33px clamp(26px, 4.4vw, 74px) 76px; }
footer { display: flex; justify-content: space-between; gap: 18px; padding: 18px clamp(26px, 4.4vw, 74px); border-top: 1px solid #ffffff16; color: #a7afca; font-size: 11px; font-weight: 650; letter-spacing: .12em; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px 20px; letter-spacing: 0; font-size: 12px; }
.footer-links a:hover { color: #a6f1de; text-decoration: underline; text-underline-offset: 3px; }

.hero { position: relative; display: flex; align-items: center; overflow: hidden; min-height: 420px; isolation: isolate; border: 1px solid #9b8bd656; border-radius: 23px; background-color: #18153c; background-image: linear-gradient(90deg, #161336 0%, #1c1845ef 27%, #1c18458a 49%, transparent 70%), var(--hero-image); background-size: cover; background-position: center; box-shadow: 0 24px 50px #06071b72; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(135deg, #ffffff0b 0%, transparent 36%, #0ce5df17 100%); }
.hero-glow { position: absolute; left: -90px; bottom: -140px; width: 360px; height: 360px; border-radius: 50%; background: #5a4cff45; filter: blur(90px); pointer-events: none; animation: glow 7s ease-in-out infinite alternate; }
.hero-copy { position: relative; max-width: 510px; padding: 42px clamp(28px, 4vw, 60px); animation: rise .7s ease both; }
.hero-kicker, .section-kicker { display: block; color: #a6f0e4; font-size: 12px; font-weight: 850; letter-spacing: .18em; }
h1, h2, h3, p { margin-top: 0; }
.hero h1 { margin: 15px 0 16px; font-size: clamp(45px, 4.15vw, 68px); font-weight: 880; line-height: .99; letter-spacing: -.06em; }
.hero h1 span { color: var(--mint); }
.hero p { max-width: 340px; margin-bottom: 23px; color: #eeeffa; font-size: 17px; line-height: 1.5; }
.primary-button { display: inline-flex; align-items: center; justify-content: center; gap: 17px; min-height: 52px; padding: 12px 20px; border: 1px solid #c8fff1ad; border-radius: 13px; background: linear-gradient(135deg, #a6f1de, #6bd1dd); color: #0d2634; box-shadow: 0 10px 28px #2dcfca39; font-size: 15px; font-weight: 850; transition: transform .2s ease, box-shadow .2s ease, filter .2s ease; }
.primary-button .icon { width: 18px; height: 18px; }
.primary-button:hover { transform: translateY(-3px); box-shadow: 0 14px 33px #2dcfca57; filter: brightness(1.05); }

.games-section { margin-top: 48px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 21px; }
.section-head h2 { margin: 7px 0 0; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.1; letter-spacing: -.04em; }
.text-link { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; color: #acf1e4; font-size: 13px; font-weight: 750; }
.text-link:hover { text-decoration: underline; text-underline-offset: 5px; }
.text-link .icon { width: 17px; height: 17px; }
.games-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.game-card { min-width: 0; overflow: hidden; border: 1px solid #a9a1d142; border-radius: 20px; background: linear-gradient(160deg, #22294e, #171c3d); box-shadow: 0 15px 38px #06081750; animation: rise .6s ease both; animation-delay: calc(var(--order) * 90ms); transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease; }
.game-card:hover, .game-card:focus-within { transform: translateY(-5px); border-color: #9de9dc; box-shadow: 0 20px 40px #06081777; }
.game-cover { position: relative; display: block; aspect-ratio: 16/9; overflow: hidden; background: #222e5a; }
.game-cover img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.game-card:hover img, .game-card:focus-within img { transform: scale(1.045); }
.cover-shine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(110deg, transparent 20%, #ffffff1e 47%, transparent 70%); opacity: 0; transform: translateX(-80%); transition: transform .55s ease, opacity .4s ease; }
.game-card:hover .cover-shine { opacity: 1; transform: translateX(80%); }
.game-info { display: flex; align-items: end; justify-content: space-between; gap: 16px; min-height: 148px; padding: 18px 20px 20px; }
.game-copy { min-width: 0; }
.game-eyebrow { color: #9ce6dc; font-size: 11px; font-weight: 850; letter-spacing: .14em; }
.game-info h3 { margin: 7px 0 5px; font-size: clamp(20px, 1.8vw, 27px); line-height: 1.1; letter-spacing: -.035em; }
.game-info h3 a:hover { color: #a7efdf; }
.game-info p { max-width: 350px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.4; }
.play-button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; flex: none; min-height: 44px; padding: 8px 14px; border-radius: 12px; background: #ffe0a0; color: #292037; font-size: 14px; font-weight: 850; transition: background .2s ease, transform .2s ease; }
.play-button:hover { background: #fff0c8; transform: translateY(-2px); }
.play-button .icon { width: 15px; height: 15px; }
.availability { display: inline-flex; align-items: center; justify-content: center; flex: none; min-height: 43px; padding: 8px 13px; border: 1px solid #b9bed24a; border-radius: 12px; background: #ffffff0d; color: #e7e8f6; font-size: 12px; font-weight: 750; text-align: center; }
.detail-availability { min-height: 52px; padding-inline: 18px; font-size: 14px; }

.page-heading { max-width: 720px; padding: 38px 0 6px; }
.page-heading h1, .detail-body h1 { margin: 11px 0 12px; font-size: clamp(42px, 4.8vw, 70px); line-height: 1.05; letter-spacing: -.06em; }
.page-heading p, .detail-body p { color: var(--muted); font-size: 18px; line-height: 1.5; }
.page-heading + .games-section { margin-top: 25px; }
.back-link { display: inline-flex; align-items: center; gap: 9px; min-height: 44px; margin: 4px 0 23px; color: #a8eadf; font-size: 14px; font-weight: 750; }
.back-link .icon { width: 18px; height: 18px; }
.back-link:hover { text-decoration: underline; text-underline-offset: 5px; }
.game-detail { overflow: hidden; border: 1px solid #aaa7cf52; border-radius: 23px; background: linear-gradient(155deg, #222650, #151a36); box-shadow: 0 24px 45px #070a1d65; }
.detail-cover { aspect-ratio: 2.5/1; overflow: hidden; background: #18214a; }
.detail-cover img { width: 100%; height: 100%; display: block; object-fit: cover; }
.detail-body { display: flex; align-items: end; justify-content: space-between; gap: 30px; padding: 27px 31px 31px; }
.detail-body h1 { font-size: clamp(32px, 3.2vw, 52px); }
.detail-body p { margin: 0; font-size: 16px; }
.detail-body .primary-button { flex: none; }
.next-adventure { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 28px; padding: 20px 24px; border: 1px solid #ffffff25; border-radius: 16px; background: #ffffff0b; }
.next-adventure p { margin: 0; font-weight: 750; }
.next-adventure a { display: inline-flex; align-items: center; gap: 7px; color: #a6ede0; font-size: 14px; font-weight: 800; }
.next-adventure .icon { width: 18px; height: 18px; }

@keyframes rise { from { opacity: 0; transform: translateY(15px); } to { opacity: 1; transform: translateY(0); } }
@keyframes glow { from { opacity: .42; transform: scale(.95); } to { opacity: .72; transform: scale(1.08); } }

@media (max-width: 1120px) {
  .app-shell { grid-template-columns: 174px minmax(0, 1fr); }
  .sidebar { padding-inline: 13px; }
  .sidebar-header { margin-left: 0; }
  .brand { width: 138px; }
  .hero { min-height: 375px; background-position: 57% center; }
  .hero-copy { max-width: 430px; }
  .game-info { align-items: start; flex-direction: column; }
}
@media (max-width: 720px) {
  .app-shell { display: block; }
  .sidebar { position: relative; height: auto; min-height: 0; padding: 15px 18px 13px; border-right: 0; border-bottom: 1px solid #ffffff22; }
  .sidebar-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 14px; }
  .brand { width: 146px; margin: 0; }
  .language-switch { flex: none; }
  .side-nav { display: flex; gap: 9px; }
  .nav-link { min-height: 44px; padding: 5px 12px 5px 6px; font-size: 14px; }
  .nav-icon { width: 32px; height: 32px; }
  .nav-icon .icon { width: 18px; height: 18px; }
  .sidebar-art, .sidebar-tagline, .topbar { display: none; }
  main { min-height: calc(100vh - 180px); padding: 20px 18px 52px; }
  footer { padding: 18px; font-size: 10px; }
  .hero { min-height: 540px; align-items: start; background-image: linear-gradient(180deg, #18143e 0%, #18143e 41%, #18143e73 70%, transparent 100%), var(--hero-image); background-size: cover, auto 52%; background-position: center, right bottom; background-repeat: no-repeat; }
  .hero-copy { max-width: 100%; padding: 30px 26px; }
  .hero h1 { font-size: clamp(39px, 10vw, 50px); }
  .hero p { max-width: 285px; font-size: 16px; }
  .games-section { margin-top: 39px; }
  .section-head { align-items: start; flex-direction: column; gap: 4px; }
  .games-grid { grid-template-columns: 1fr; gap: 17px; }
  .game-info { min-height: 0; padding: 17px; }
  .game-info h3 { font-size: 23px; }
  .game-info p { font-size: 14px; }
  .play-button { min-height: 44px; }
  .page-heading { padding: 20px 0 0; }
  .page-heading h1 { font-size: 42px; }
  .page-heading p { font-size: 16px; }
  .detail-cover { aspect-ratio: 16/11; }
  .detail-body { align-items: start; flex-direction: column; padding: 23px; }
  .detail-body h1 { font-size: 37px; }
  .next-adventure { align-items: start; flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
