:root {
  --bg: #0b0c10;
  --panel: rgba(255, 255, 255, 0.05);
  --text: #eef0f6;
  --muted: rgba(238, 240, 246, 0.7);
  --border: rgba(255, 255, 255, 0.12);
  --radius: 16px;
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  --max: 1120px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  background:
    radial-gradient(900px 520px at 20% 0%, rgba(78, 119, 255, 0.16), transparent 60%),
    radial-gradient(900px 520px at 80% 10%, rgba(255, 78, 156, 0.12), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial, sans-serif;
  line-height: 1.55;
}

a { color: inherit; text-decoration: none; }
a:hover { opacity: 0.9; }

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 24px;
}

:is(.header, .topbar) {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(10px);
  background: rgba(11, 12, 16, 0.62);
  border-bottom: 1px solid var(--border);
}

:is(.header-inner, .topbar-inner) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

:is(.logo, .brand) { font-weight: 800; letter-spacing: 0.2px; }

.nav {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px; 
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.10);
  box-shadow: var(--shadow);
  font-size: 14px;
  white-space: nowrap;
}
.btn.small { padding: 8px 12px; font-size: 13px; }
.btn.ghost { background: transparent; box-shadow: none; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.hero { padding: 44px 0 18px; }
.hero h1 { font-size: clamp(30px, 4vw, 46px); margin: 0 0 6px; }
.hero p { margin: 0 0 16px; color: var(--muted); max-width: 860px; }

.sub { color: var(--muted); font-size: 18px; max-width: 750px; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 16px 0 10px; }
.proof { color: var(--muted); font-size: 14px; display: flex; gap: 10px; flex-wrap: wrap; }

.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
}
.chip {
  padding: 6px 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}

.section { padding: 36px 0; }              
.section-title h2 { margin: 0; }
.section-title p { margin: 6px 0 0; color: var(--muted); }

.grid {
  margin-top: 18px;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(12, 1fr);
}

.card {
  grid-column: span 12;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
}

.muted { color: var(--muted); }
.stack { color: var(--muted); font-size: 14px; margin: 10px 0; }

.links { display: flex; gap: 14px; flex-wrap: wrap; }
.links a { border-bottom: 1px solid rgba(255,255,255,0.25); padding-bottom: 2px; }

.projects-cta { margin-top: 18px; }
.contact-links { display: flex; gap: 14px; flex-wrap: wrap; }

@media (min-width: 840px) {
  .card { grid-column: span 4; }
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel .section { padding: 18px; }    

.layout {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  gap: 16px;
  padding: 18px 0 26px;
  align-items: start;
}
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 14px 10px;
  border-bottom: 1px solid var(--border);
}
.panel-header .title {
  font-weight: 700;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.panel-header .hint { color: var(--muted); font-size: 13px; }

.game-shell { padding: 14px; }

.game-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #231F20;
  border-radius: 12px;
  overflow: hidden;

  display: flex;
  align-items: center;
  justify-content: center;
}

#unity-canvas {
  width: 100%;
  height: 100%;
  display: block;
  background: #231F20;
}

.loading {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.38);
  color: var(--text);
  padding: 16px;
  text-align: center;
}
.loading .box {
  max-width: 520px;
  background: rgba(11, 12, 16, 0.72);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px;
}
.bar {
  height: 10px;
  width: 100%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
  margin-top: 10px;
}
.bar > div {
  height: 100%;
  width: 0%;
  background: rgba(255, 255, 255, 0.55);
  border-radius: 999px;
  transition: width 120ms linear;
}

.mobile-overlay {
  display: none;
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  padding: 16px;
  text-align: center;
  align-items: center;
  justify-content: center;
}
.mobile-overlay .box {
  max-width: 520px;
  background: rgba(11, 12, 16, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 14px;
}
.mobile-overlay p {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
}
@media (max-width: 768px) {
  #unity-canvas { pointer-events: none; }
  .mobile-overlay { display: flex; }
}

body.is-fs { padding: 0; }
body.is-fs h1,
body.is-fs p,
body.is-fs h2 { display: none; }

body.is-fs :is(.topbar, .header) { display: none; }
body.is-fs .container { max-width: none; padding: 0; }
body.is-fs .layout { padding: 0; gap: 0; }
body.is-fs .panel { border-radius: 0; border: none; box-shadow: none; }
body.is-fs .panel-header { display: none; }
body.is-fs #details { display: none; }

body.is-fs .game-shell { padding: 0; }
body.is-fs .game-frame {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  aspect-ratio: auto;
  border-radius: 0;
}
body.is-fs #unity-canvas {
  width: auto;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
}

.fs-btn {
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.45);
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  user-select: none;
  backdrop-filter: blur(6px);
}
.fs-btn:hover { background: rgba(0, 0, 0, 0.6); }
.fs-btn:active { transform: translateY(1px); }

.footer {
  color: var(--muted);
  padding: 26px 0 50px;
  font-size: 13px;
}

#details.details { padding: 24px; }
#details.details .spec {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 10px;
}
#details.details .spec-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 12px;
  align-items: start;
}
#details.details .spec-label {
  color: var(--muted);
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
#details.details .spec-value {
  color: var(--text);
  font-size: 14px;
}
#details.details .link-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-start;
  margin-top: 10px;
}

.bullets { margin: 10px 0 0 18px; padding-left: 18px; }
.bullets li { margin: 6px 0; }

.code {
  background: rgba(0,0,0,0.35);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  overflow: auto;
  font-size: 13px;
  line-height: 1.45;
}

.media {
  width: 100%;
  display: block;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(0,0,0,0.25);
}

.quick-facts-title {
  margin: 14px 0 8px;               
}

ul.quick-facts {
  margin: 0;                     
  padding-left: 18px;            
  display: grid;
  gap: 6px;
}

ul.quick-facts li { margin: 0; }

.hero h2 {
  margin: 0 0 12px;                      
  font-size: clamp(18px, 2.2vw, 26px);  
  font-weight: 650;
  color: var(--muted);
  letter-spacing: 0.2px;
}

