:root {
  --bg-0: #050505;
  --bg-1: #0b0b0b;
  --bg-2: #131010;
  --text: #f7f2f2;
  --muted: #b8a8a8;
  --line: rgba(255, 255, 255, 0.08);
  --red-main: #c20d16;
  --red-soft: #8d0d13;
  --red-glow: rgba(194, 13, 22, 0.4);
  --card: linear-gradient(165deg, rgba(255, 255, 255, 0.02), rgba(194, 13, 22, 0.08));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
  background-color: #050505;
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  font-family: 'Exo 2', 'Segoe UI', sans-serif;
  background-color: #050505;
  background:
    radial-gradient(circle at 8% 12%, rgba(194, 13, 22, 0.18), transparent 45%),
    radial-gradient(circle at 88% 88%, rgba(141, 13, 19, 0.18), transparent 40%),
    linear-gradient(140deg, var(--bg-0), var(--bg-1) 45%, var(--bg-2));
  color: var(--text);
  overflow-x: hidden;
  opacity: 1;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.12;
  background-image: radial-gradient(rgba(255, 255, 255, 0.25) 0.5px, transparent 0.5px);
  background-size: 3px 3px;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding-top: env(safe-area-inset-top, 0px);
  z-index: 1200;
}

main,
.site-footer {
  position: relative;
  z-index: 1;
}

.site-header {
  backdrop-filter: blur(10px);
  background: rgba(5, 5, 5, 0.82);
  border-bottom: none;
}

.header-inner {
  max-width: 1220px;
  margin: 0 auto;
  padding: 12px 20px;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 16px;
  align-items: center;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--text);
  text-decoration: none;
  min-width: 0;
}

.brand-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.brand-text-wrap {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.brand-title {
  font-family: 'Russo One', sans-serif;
  letter-spacing: 0.07em;
  font-size: 0.98rem;
  white-space: nowrap;
}

.brand-sub {
  color: var(--muted);
  font-size: 0.78rem;
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  justify-self: end;
}

.site-nav a,
.mobile-nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.03em;
  transition: color 0.25s ease;
}

.site-nav a:hover,
.mobile-nav a:hover {
  color: #ff5962;
}

.menu-toggle {
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 10px;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.menu-toggle:hover {
  background: rgba(255, 89, 98, 0.06);
}

.menu-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: transform 0.25s ease, opacity 0.25s ease;
  transform-origin: center;
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  overflow: hidden;
  max-height: 0;
  border-top: 0;
  background: rgba(5, 5, 5, 0.97);
  backdrop-filter: blur(16px);
  padding: 0 20px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: max-height 0.35s ease, padding 0.3s ease;
}

.mobile-nav.open {
  max-height: 320px;
  padding: 8px 20px 16px;
}

.mobile-nav a {
  padding: 13px 0;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border-bottom: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mobile-nav a:last-child {
  border-bottom: none;
}

.mobile-nav a::after {
  content: '';
  display: inline-block;
  width: 7px;
  height: 7px;
  border-right: 2px solid rgba(255, 89, 98, 0.6);
  border-top: 2px solid rgba(255, 89, 98, 0.6);
  transform: rotate(45deg);
  transition: border-color 0.2s ease;
}

.mobile-nav a:hover::after {
  border-color: #ff5962;
}

.hero,
.projects,
.about,
.join,
.oss,
.support,
.site-footer {
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(60px, 8vw, 100px) 20px;
}

.hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  max-width: 100%;
  padding: 0;
  overflow: hidden;
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
  z-index: 0;
}

.hero-center {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(100px, 14vw, 160px) 20px clamp(60px, 8vw, 100px);
  max-width: 760px;
  width: 100%;
  margin: 0 auto;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  width: 100%;
  justify-content: center;
}

.hero-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.hero-stat strong {
  font-family: 'Russo One', sans-serif;
  font-size: 1.5rem;
  color: var(--text);
  line-height: 1;
}

.hero-stat span {
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.hero-stat-sep {
  width: 1px;
  height: 32px;
  background: var(--line);
}

.hero-tag,
.kicker {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid rgba(255, 89, 98, 0.45);
  border-radius: 100px;
  color: #ff7c83;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 16px 0 16px;
  line-height: 1.03;
  font-family: 'Russo One', sans-serif;
  font-size: clamp(2.6rem, 7vw, 5.5rem);
  text-transform: uppercase;
}

.hero h1 span {
  color: #ff2a34;
  text-shadow: 0 0 30px rgba(255, 42, 52, 0.5);
}

.hero-text {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
  max-width: 52ch;
}

.hero-actions {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  text-decoration: none;
  font-family: 'Exo 2', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  position: relative;
  transition: opacity 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  color: #fff;
  background: #c20d16;
  box-shadow: 4px 4px 0 #7a0009;
}

.btn-primary:hover {
  opacity: 0.9;
  box-shadow: 2px 2px 0 #7a0009;
  transform: translate(2px, 2px);
}

.btn-primary:active {
  box-shadow: 0 0 0 #7a0009;
  transform: translate(4px, 4px);
}

.btn-ghost {
  color: var(--text);
  background: transparent;
  box-shadow: 4px 4px 0 rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255, 255, 255, 0.3);
}

.btn-ghost:hover {
  border-color: rgba(255,255,255,0.6);
  box-shadow: 2px 2px 0 rgba(255,255,255,0.15);
  transform: translate(2px, 2px);
}

.btn-ghost:active {
  box-shadow: 0 0 0 rgba(255,255,255,0.15);
  transform: translate(4px, 4px);
}


.section-head {
  margin-bottom: 24px;
}

.section-head h2,
.about h2,
.support h2 {
  margin: 12px 0 0;
  font-family: 'Russo One', sans-serif;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-size: clamp(1.4rem, 3vw, 2.1rem);
}

.project-grid {
  display: grid;
  gap: 16px;
}

.project-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.project-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--card);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
  position: relative;
  display: block;
  text-decoration: none;
  color: inherit;
}

.card-status {
  position: absolute;
  top: 12px;
  right: 12px;
}

.card-arrow {
  position: absolute;
  bottom: 12px;
  left: 14px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: none;
  color: #ff5962;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  transition: color 0.2s ease;
  z-index: 1;
}

.project-card:hover .card-arrow {
  color: #ff9aa0;
}

.project-card {
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 89, 98, 0.75);
}

.project-cover {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #080808;
}

.soon-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0e0e0e, #1a0a0a);
  color: rgba(194, 13, 22, 0.55);
}

.project-body {
  padding: 14px 14px 44px;
}

.project-body h3 {
  margin: 0 0 8px;
  font-size: 1.08rem;
}

.project-body p,
.about p,
.support p,
.site-footer p {
  margin: 0;
  color: var(--muted);
  line-height: 1.62;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 5px 12px 5px 9px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  box-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.status::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status.done {
  background: rgba(10, 4, 4, 0.75);
  border: 1px solid rgba(13, 194, 52, 0.55);
  color: #95ffa3;
}

.status.done::before {
  background: #59ff90;
  box-shadow: 0 0 5px #0dc234;
}

.status.progress {
  background: rgba(10, 8, 0, 0.75);
  border: 1px solid rgba(255, 185, 50, 0.5);
  color: #ffd56a;
}

.status.progress::before {
  background: #ffd56a;
  box-shadow: 0 0 6px rgba(255, 185, 50, 0.7);
  animation: status-pulse 1.8s ease-in-out infinite;
}

.status.wait {
  background: rgba(10, 10, 10, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #b8a8a8;
}

.status.wait::before {
  background: #666;
}

.status.not-vn {
  background: rgba(10, 4, 4, 0.75);
  border: 1px solid rgba(194, 13, 13, 0.7);
  color: #ff5959;
  position: relative;
}

.status.not-vn::before {
  content: '✕';
  font-size: 0.65rem;
  opacity: 0.8;
  width: auto;
  height: auto;
  background: none;
  box-shadow: none;
  border-radius: 0;
}

.status.not-vn {
  position: relative;
  align-self: flex-start;
}

.status.not-vn .tooltip {
  position: absolute;
  bottom: auto;
  left: 0;           /* ← було right, тепер left */
  right: auto;
  background: rgba(10, 4, 4, 0.95);
  border: 1px solid rgba(194, 13, 13, 0.5);
  color: #ffb3b3;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: none;
  white-space: nowrap;
  padding: 6px 10px;
  border-radius: 6px;
  pointer-events: none;
  opacity: 0;
  top: calc(100% + 8px);
  transform: translateY(-4px);
  transition: opacity .15s ease, transform .15s ease;
  z-index: 10;
}

.status.not-vn:hover .tooltip {
  opacity: 1;
  transform: translateY(0);
}

.card-status-group {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  gap: 6px;
  z-index: 2;
  align-items: center;
}

@keyframes status-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.65); }
}

/* ── Open Source / GitHub widget ─────────────────────────────── */
.gh-widget-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.gh-widget {
  display: block;
  text-decoration: none;
  background: #0d1117;
  border: 1px solid #30363d;
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.gh-widget:hover {
  border-color: #58a6ff;
  box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.1);
}

.gh-widget-cover {
  width: 100%;
  display: block;
  aspect-ratio: 1200 / 600;
  object-fit: cover;
  border-bottom: 1px solid #30363d;
}

.gh-widget-body {
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.gh-widget-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.gh-widget-icon {
  color: #8b949e;
  flex-shrink: 0;
}

.gh-widget-repo {
  font-size: 0.9rem;
  color: #8b949e;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.gh-widget-repo strong {
  color: #58a6ff;
  font-weight: 600;
}

.gh-widget-desc {
  font-size: 0.82rem;
  color: #8b949e;
  line-height: 1.6;
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.gh-widget-desc code {
  font-family: 'SFMono-Regular', Consolas, monospace;
  font-size: 0.85em;
  background: rgba(110, 118, 129, 0.15);
  border-radius: 4px;
  padding: 1px 5px;
  color: #e6edf3;
}

.gh-widget-footer {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.gh-widget-lang {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  color: #8b949e;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.gh-lang-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #3572A5;
  flex-shrink: 0;
}

.gh-widget-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  color: #8b949e;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.gh-widget-badge {
  font-size: 0.72rem;
  font-weight: 600;
  color: #8b949e;
  background: rgba(110, 118, 129, 0.1);
  border: 1px solid #30363d;
  border-radius: 999px;
  padding: 2px 8px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ── About / Support grid ─────────────────────────────────────── */

.about-grid,
.support {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 20px;
  align-items: center;
}

.about-badge {
  border-radius: 16px;
  border: 1px solid var(--line);
  overflow: hidden;
}

.about-badge img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.team-list {
  list-style: none;
  margin: 32px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 12px;
}

.team-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(255,255,255,0.02), rgba(194,13,22,0.06));
  transition: border-color 0.2s ease;
}

.team-item:hover {
  border-color: rgba(255, 89, 98, 0.5);
}

.team-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.team-role {
  font-size: 0.82rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.join {
  padding-top: 20px;
}

.join-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: center;
  padding: 36px 40px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(255,255,255,0.02), rgba(194,13,22,0.07));
}

.join-copy h2 {
  margin: 8px 0 12px;
}

.join-copy p {
  margin: 0 0 20px;
  color: var(--muted);
  line-height: 1.62;
  max-width: 560px;
}

.join-icon {
  color: rgba(255, 89, 98, 0.45);
  flex-shrink: 0;
  margin-right: 70px;
}

.support {
  padding-top: 30px;
}

.support-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.support-copy .btn {
  margin-top: 12px;
}

.support-media {
  border-radius: 16px;
  overflow: hidden;
}

.support-image {
  width: min(100%, 360px);
  display: block;
  margin: 0 auto;
}

.support-image-link {
  display: block;
}

.nav-tg-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--line);
  color: var(--muted);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.nav-tg-link:hover {
  color: #54a3e4;
  border-color: rgba(84, 163, 228, 0.5);
  background: rgba(84, 163, 228, 0.08);
}

.nav-j4s-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border: 1px solid rgba(255, 89, 98, 0.35);
  border-radius: 6px;
  color: #ff7c83 !important;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  transition: background 0.2s ease, border-color 0.2s ease !important;
}

.nav-j4s-link:hover {
  background: rgba(255, 89, 98, 0.1) !important;
  border-color: rgba(255, 89, 98, 0.6) !important;
  color: #ff9ca1 !important;
}

.site-footer {
  padding-top: 40px;
  padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px));
  text-align: center;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.footer-inner p {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.footer-socials {
  display: flex;
  gap: 10px;
}

.footer-social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--line);
  color: var(--muted);
  text-decoration: none;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.footer-social-link:hover {
  border-color: rgba(255, 89, 98, 0.5);
  color: #ff9ca1;
  background: rgba(255, 89, 98, 0.06);
}

.footer-copy {
  font-size: 0.78rem !important;
  opacity: 0.5;
}

.footer-j4s {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--muted);
}

.footer-j4s-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.footer-j4s-link:hover {
  border-color: rgba(255, 89, 98, 0.5);
  color: #ff9ca1;
  background: rgba(255, 89, 98, 0.06);
}

.section-reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.28s ease, transform 0.28s ease;
}

.section-reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Song of Saya page ───────────────────────────────────────── */

.saya-section {
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(48px, 7vw, 80px) 20px;
}

/* Hero */
.saya-hero {
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(100px, 14vw, 140px) 20px clamp(48px, 7vw, 80px);
}

.saya-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.saya-hero-copy h1 {
  margin: 14px 0 16px;
  font-family: 'Russo One', sans-serif;
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  line-height: 1.05;
  text-transform: uppercase;
}

.saya-hero-copy h1 span {
  color: #ff2a34;
  text-shadow: 0 0 30px rgba(255, 42, 52, 0.5);
}

.saya-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 20px 0 24px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.saya-meta-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.saya-meta-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.saya-meta-value {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
}

.saya-hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.saya-capsule {
  width: 100%;
  max-width: 480px;
  border-radius: 12px;
  display: block;
  position: relative;
  z-index: 1;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.saya-glow {
  position: absolute;
  inset: -20%;
  background: radial-gradient(ellipse at center, rgba(194,13,22,0.22) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.saya-story {
  padding-top: 12px;
  width: 100%;
}

.saya-story-wrap {
  width: 100%;
  max-width: 100%;
  margin: 0;
}

.saya-story-wrap .kicker {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid rgba(255, 89, 98, 0.45);
  border-radius: 100px;
  color: #ff7c83;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.saya-story-wrap h2 {
  margin: 12px 0 18px;
  font-family: 'Russo One', sans-serif;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  line-height: 1.1;
  color: #fff;
}

.saya-story-wrap p {
  margin: 0;
  color: #e8dfe0;
  line-height: 1.8;
  font-size: clamp(1rem, 1.25vw, 1.22rem);
  max-width: 100%;
}

.saya-story-wrap .saya-dl-notice {
  margin: 28px 0 18px;
}

.saya-story-wrap p + p {
  margin-top: 18px;
}

.saya-story-wrap strong {
  color: #fff;
  font-weight: 800;
}

/* Progress dashboard from saya_menu_dashboard.html */
.saya-dashboard-shell {
  width: min(100%, 1250px);
  margin: 0 auto;
}

.saya-dashboard-window {
  width: 100%;
  aspect-ratio: 16 / 9.3;
  border: 1px solid rgba(168, 190, 255, 0.54);
  border-radius: 16px;
  box-shadow: 0 22px 58px rgba(62, 78, 142, 0.22);
  position: relative;
  overflow: hidden;
  background: #edf3f8;
}


.saya-dashboard-bg,
.saya-dashboard-overlay,
.saya-dashboard-wash {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.saya-dashboard-bg {
  background: url('img/title_back01.png') center center / cover no-repeat;
  opacity: 0.98;
  filter: saturate(108%) contrast(103%);
}

.saya-dashboard-overlay {
  background: url('img/title02.png') center center / 112% auto no-repeat;
  opacity: 0.34;
}

.saya-dashboard-wash {
  background: linear-gradient(rgba(244, 248, 255, 0.52), rgba(244, 248, 255, 0.52));
}

.saya-dashboard-page {
  position: relative;
  z-index: 2;
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 14px 20px;
}

.saya-dashboard-hero {
  text-align: center;
  margin-bottom: 8px;
  position: relative;
}

.saya-dashboard-kanji {
  font-family: 'Noto Serif JP', serif;
  position: absolute;
  left: 50%;
  top: -26px;
  transform: translateX(-50%);
  font-size: clamp(86px, 8.8vw, 108px);
  line-height: 0.9;
  color: rgba(96, 116, 182, 0.16);
  margin-bottom: 0;
  white-space: nowrap;
  z-index: 0;
  pointer-events: none;
}

.saya-dashboard-title {
  font-size: clamp(44px, 5.2vw, 56px);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #1f2c5c;
  line-height: 0.98;
  text-shadow: 0 2px 14px rgba(73, 92, 171, 0.16);
  position: relative;
  z-index: 1;
}

.saya-dashboard-meta {
  margin-top: 6px;
  font-size: 16px;
  letter-spacing: 0.14em;
  color: #44538c;
  position: relative;
  z-index: 1;
}

.saya-dashboard-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.saya-dashboard-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #2aaf63;
  box-shadow: 0 0 14px rgba(42, 175, 99, 0.58);
  display: inline-block;
}

.saya-dashboard-main-card {
  margin: 0 auto 8px;
  width: 100%;
  max-width: 1100px;
  background: linear-gradient(160deg, rgba(249, 252, 255, 0.54), rgba(232, 240, 255, 0.36));
  border: 1px solid rgba(170, 196, 255, 0.52);
  box-shadow:
    0 10px 24px rgba(48, 64, 126, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.64),
    inset 0 -1px 0 rgba(145, 170, 235, 0.24);
  padding: 14px 16px;
  position: relative;
  overflow: hidden;
}

.saya-dashboard-main-card::after {
  content: '';
  position: absolute;
  inset: 1px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.04));
  pointer-events: none;
}

.saya-dashboard-main-card > * {
  position: relative;
  z-index: 1;
}

.saya-dashboard-main-inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: center;
}

.saya-dashboard-main-pct {
  font-size: clamp(64px, 6.8vw, 86px);
  line-height: 1;
  font-weight: 700;
  color: #2e9f74;
  letter-spacing: -0.04em;
  display: block;
  font-family: 'Space Mono', monospace;
}

.saya-dashboard-main-label {
  font-size: 20px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #1f2c5c;
  margin-bottom: 8px;
  font-family: 'Space Mono', monospace;
  font-weight: 700;
}

.saya-dashboard-bar-wrap,
.saya-dashboard-metric-bar,
.saya-dashboard-subpoint-bar {
  width: 100%;
  height: 12px;
  background: rgba(186, 206, 246, 0.3);
  border: 1px solid rgba(165, 188, 245, 0.56);
  box-shadow: inset 0 1px 3px rgba(92, 114, 182, 0.24);
  overflow: hidden;
}

.saya-dashboard-bar-fill,
.saya-dashboard-metric-bar span,
.saya-dashboard-subpoint-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #9ee8c9 0%, #59c79d 52%, #2f9f77 100%);
}

.saya-dashboard-metric-bar--done span,
.saya-dashboard-metric-bar--warn span,
.saya-dashboard-subpoint-bar--warn span {
  background: linear-gradient(90deg, #b7dcf3 0%, #7fb7df 52%, #5a89c8 100%);
}

.saya-dashboard-metric-bar--warn span,
.saya-dashboard-subpoint-bar--warn span {
  background: linear-gradient(90deg, #c8e7bf 0%, #9fcf93 52%, #78a96e 100%);
}

.saya-dashboard-main-meta {
  margin-top: 6px;
  font-size: 16px;
  color: #44538c;
}

.saya-dashboard-metrics {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 0 0 auto;
}

.saya-dashboard-metric-row {
  background: linear-gradient(160deg, rgba(249, 252, 255, 0.5), rgba(232, 240, 255, 0.32));
  border: 1px solid rgba(170, 196, 255, 0.52);
  box-shadow:
    0 8px 18px rgba(48, 64, 126, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  padding: 10px 14px;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto auto;
  gap: 6px 18px;
  position: relative;
}

.saya-dashboard-metric-row::after {
  content: '';
  position: absolute;
  inset: 1px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.03));
  pointer-events: none;
}

.saya-dashboard-metric-row > * {
  position: relative;
  z-index: 1;
}

.saya-dashboard-metric-row::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: rgba(47, 159, 119, 0.82);
}

.saya-dashboard-metric-row--done::before { background: rgba(90, 137, 200, 0.82); }
.saya-dashboard-metric-row--warn::before { background: rgba(120, 169, 110, 0.82); }

.saya-dashboard-metric-name {
  font-size: 22px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #1f2c5c;
  font-weight: 700;
  font-family: 'Space Mono', monospace;
}

.saya-dashboard-metric-nums {
  font-size: 19px;
  color: #44538c;
  font-style: italic;
  font-family: 'Space Mono', monospace;
}

.saya-dashboard-metric-pct {
  grid-column: 2;
  grid-row: 1 / 3;
  align-self: center;
  font-size: 58px;
  line-height: 0.9;
  font-weight: 700;
  color: #2e9f74;
  font-family: 'Space Mono', monospace;
}

.saya-dashboard-metric-pct--blue { color: #5a89c8; }
.saya-dashboard-metric-pct--red { color: #86a97b; }

.saya-dashboard-metric-bar {
  grid-column: 1 / 3;
  height: 10px;
  background: rgba(186, 206, 246, 0.28);
  border: 1px solid rgba(165, 188, 245, 0.48);
  box-shadow: inset 0 1px 2px rgba(90, 110, 175, 0.2);
  overflow: hidden;
}

.saya-dashboard-metric-subpoints {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
  padding: 2px 0 0 8px;
  border-left: 2px solid rgba(90, 137, 200, 0.34);
}

.saya-dashboard-subpoint-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.saya-dashboard-subpoint-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

.saya-dashboard-subpoint-name {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #1f2c5c;
  text-transform: uppercase;
  font-family: 'Space Mono', monospace;
}

.saya-dashboard-subpoint-nums {
  font-size: 14px;
  color: #44538c;
  letter-spacing: 0.04em;
  white-space: nowrap;
  font-family: 'Space Mono', monospace;
}

.saya-dashboard-subpoint-bar {
  height: 6px;
  background: rgba(186, 206, 246, 0.28);
  border: 1px solid rgba(165, 188, 245, 0.48);
  box-shadow: inset 0 1px 2px rgba(90, 110, 175, 0.2);
  overflow: hidden;
}

.saya-dashboard-footer {
  width: 100%;
  max-width: 1100px;
  margin: 6px auto 0;
  display: flex;
  justify-content: space-between;
  font-size: 16px;
  letter-spacing: 0.1em;
  color: #44538c;
}

.saya-dashboard-footer-handle {
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

@media (max-width: 980px) {
  .saya-dashboard-title { font-size: 42px; }
  .saya-dashboard-kanji { font-size: 86px; top: -16px; }
  .saya-dashboard-main-pct { font-size: 78px; }
  .saya-dashboard-metric-name { font-size: 18px; }
  .saya-dashboard-metric-nums { font-size: 15px; }
  .saya-dashboard-metric-pct { font-size: 46px; }
  .saya-dashboard-subpoint-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }
  .saya-dashboard-subpoint-name,
  .saya-dashboard-subpoint-nums { font-size: 12px; }
  .saya-dashboard-footer { font-size: 12px; }
}

/* Screenshots */
.saya-screenshots-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.saya-shot {
  position: relative;
  display: block;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  line-height: 0;
  transition: border-color 0.2s ease, transform 0.2s ease;
  background: none;
  padding: 0;
  cursor: pointer;
  text-align: left;
  width: 100%;
}

.saya-shot:hover {
  border-color: rgba(255, 89, 98, 0.6);
  transform: translateY(-4px);
}

.saya-shot img {
  width: 100%;
  height: auto;
  display: block;
  background: #080808;
}

.saya-shot-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.saya-shot:hover .saya-shot-overlay {
  opacity: 1;
}

.saya-screenshots-note {
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
  margin: 12px 0 0;
}

/* ── Lightbox ──────────────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: lb-fade-in 0.2s ease;
}
.lightbox[hidden] { display: none; }

@keyframes lb-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.lb-img-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: calc(100vw - 120px);
  max-height: calc(100vh - 80px);
}

.lb-img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 80px);
  width: auto;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.7);
  animation: lb-zoom-in 0.2s ease;
}

@keyframes lb-zoom-in {
  from { transform: scale(0.96); opacity: 0.6; }
  to   { transform: scale(1);    opacity: 1; }
}

.lb-close {
  position: fixed;
  top: 16px;
  right: 20px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s;
  z-index: 9001;
}
.lb-close:hover { background: rgba(255,255,255,0.18); }

.lb-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s;
  z-index: 9001;
}
.lb-nav:hover { background: rgba(255,255,255,0.2); }
.lb-prev { left: 16px; }
.lb-next { right: 16px; }
.lb-nav[disabled] { opacity: 0.25; pointer-events: none; }

.lb-counter {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.8rem;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.08em;
  pointer-events: none;
  z-index: 9001;
}

/* Downloads */
.saya-dl-notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(255, 185, 50, 0.06);
  border: 1px solid rgba(255, 185, 50, 0.28);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.84rem;
  color: #d4a84e;
  line-height: 1.55;
  margin-bottom: 32px;
}

.saya-dl-notice svg {
  flex-shrink: 0;
  margin-top: 1px;
  color: #ffd56a;
}

.saya-dl-notice--danger {
  background: rgba(194, 13, 22, 0.1);
  border-color: rgba(255, 89, 98, 0.38);
  color: #ffd0d3;
  margin-top: -18px;
}

.saya-dl-notice--danger svg {
  color: #ff7c83;
}

.saya-dl-count {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--muted);
  margin: 6px 0 0;
}

.saya-dl-count strong {
  color: var(--text);
  font-weight: 600;
}

/* Release Countdown Gate */
.saya-release-gate {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 28px;
  padding: 44px 32px 36px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--card);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
  margin-top: 20px;
  overflow: hidden;
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 1;
  transform: translateY(0);
}

.saya-release-gate::before {
  content: '';
  position: absolute;
  top: -80px;
  left: 50%;
  transform: translateX(-50%);
  width: 320px;
  height: 200px;
  background: radial-gradient(ellipse at center, rgba(194, 13, 22, 0.18) 0%, transparent 70%);
  pointer-events: none;
}

.saya-release-gate__kanji {
  position: absolute;
  top: -15px;
  right: 4%;
  font-family: 'Russo One', sans-serif;
  font-size: 110px;
  color: rgba(255, 255, 255, 0.02);
  line-height: 1;
  pointer-events: none;
  user-select: none;
  letter-spacing: -0.04em;
}

.saya-release-gate.fade-out {
  opacity: 0;
  transform: translateY(-12px);
  pointer-events: none;
}

.saya-release-gate[hidden] {
  display: none !important;
}

#sayaDownloadContent {
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 1;
  transform: translateY(0);
}

#sayaDownloadContent.fade-in-init {
  opacity: 0;
  transform: translateY(12px);
}

#sayaDownloadContent[hidden] {
  display: none !important;
}

.saya-release-gate__header {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 1;
}

.saya-release-gate__title {
  font-family: 'Russo One', 'Exo 2', sans-serif;
  font-size: clamp(1.4rem, 3.8vw, 2.1rem);
  color: var(--text);
  margin: 0;
  letter-spacing: 0.01em;
}

.saya-release-gate__subtitle {
  color: var(--muted);
  font-size: 0.98rem;
  margin: 0;
}

.saya-release-gate__countdown {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  z-index: 1;
  width: 100%;
  max-width: 580px;
}

.saya-release-gate__card {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px 14px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: border-color 0.25s ease, background-color 0.25s ease, transform 0.25s ease;
}

.saya-release-gate__card:hover {
  border-color: rgba(255, 89, 98, 0.35);
  background: rgba(255, 89, 98, 0.04);
  transform: translateY(-2px);
}

.saya-release-gate__number {
  font-family: 'Russo One', 'Exo 2', sans-serif;
  font-size: clamp(2rem, 5.5vw, 3.2rem);
  line-height: 1;
  color: var(--text);
  letter-spacing: 0.02em;
}

.saya-release-gate__label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.saya-release-gate__divider {
  font-family: 'Russo One', sans-serif;
  font-size: 2rem;
  color: var(--red-main);
  opacity: 0.5;
  margin-top: -22px;
  user-select: none;
}

.saya-release-gate__footer {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  font-size: 0.88rem;
  color: var(--muted);
  z-index: 1;
}

.saya-release-gate__footer svg {
  color: var(--red-main);
  flex-shrink: 0;
}

.saya-release-gate__footer a {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.saya-release-gate__footer a:hover {
  color: var(--red-main);
}

@media (max-width: 580px) {
  .saya-release-gate {
    padding: 30px 18px 24px;
    gap: 20px;
  }

  .saya-release-gate__kanji {
    font-size: 70px;
    top: -5px;
  }

  .saya-release-gate__countdown {
    gap: 8px;
  }

  .saya-release-gate__divider {
    display: none;
  }

  .saya-release-gate__card {
    padding: 14px 8px;
  }

  .saya-release-gate__number {
    font-size: 1.7rem;
  }

  .saya-release-gate__footer {
    font-size: 0.82rem;
    padding: 8px 14px;
  }
}

.saya-release-gate__footer a {
  color: #ff8b91;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.saya-release-gate__footer a:hover {
  color: #ffffff;
}

@media (max-width: 580px) {
  .saya-release-gate {
    padding: 24px 16px;
    gap: 18px;
  }

  .saya-release-gate__countdown {
    gap: 6px;
  }

  .saya-release-gate__divider {
    display: none;
  }

  .saya-release-gate__card {
    padding: 12px 6px;
  }

  .saya-release-gate__number {
    font-size: 1.6rem;
  }
}

.saya-dl-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-areas:
    'lbk lbk'
    'zip exe'
    'dlc dlc';
  gap: 16px;
  padding-top: 16px;
}

.saya-dl-option {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 24px 20px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
}

.saya-dl-option--lbk { grid-area: lbk; }

.saya-dl-option--zip { grid-area: zip; }

.saya-dl-option--exe { grid-area: dlc; }

.saya-dl-option--dlc { grid-area: exe; }

.saya-dl-option--recommended {
  border-color: rgba(255, 89, 98, 0.4);
  background: linear-gradient(135deg, rgba(194,13,22,0.07), rgba(255,255,255,0.02));
}

.saya-dl-option-badge {
  position: absolute;
  top: -11px;
  left: 20px;
  background: var(--red-main);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
}

.saya-dl-option-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  flex-shrink: 0;
  color: var(--muted);
}

.saya-dl-option-icon--danger {
  color: #ff8b91;
  background: rgba(194, 13, 22, 0.14);
  border-color: rgba(255, 89, 98, 0.35);
}

.saya-dl-option-icon--zip {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.02);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.saya-dl-icon-lbk {
  color: #ff5962;
  background: rgba(255, 89, 98, 0.07);
  border-color: rgba(255, 89, 98, 0.2);
}

.saya-dl-option-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.saya-dl-name {
  font-size: 1.34rem;
  line-height: 1.2;
}

.saya-dl-desc {
  color: var(--muted);
  line-height: 1.5;
  font-size: 0.96rem;
}

.saya-dl-steps {
  margin: 4px 0 0;
  padding-left: 18px;
  color: #d9cccc;
  font-size: 0.9rem;
  line-height: 1.6;
}

.saya-dl-steps li + li {
  margin-top: 2px;
}

.saya-dl-danger {
  margin: 2px 0 0;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(194, 13, 22, 0.13);
  border: 1px solid rgba(255, 89, 98, 0.35);
  color: #ffc2c7;
  font-size: 0.86rem;
  line-height: 1.45;
}

.saya-dl-btn--danger {
  background: linear-gradient(135deg, #b50b13, #cb101a);
}

.saya-age-modal {
  position: fixed;
  inset: 0;
  z-index: 3200;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(5, 5, 5, 0.74);
  backdrop-filter: blur(8px);
}

.saya-age-modal[hidden] {
  display: none;
}

.saya-age-modal-card {
  width: min(560px, 100%);
  border: 1px solid rgba(255, 89, 98, 0.34);
  border-radius: 16px;
  padding: 20px;
  background: linear-gradient(155deg, rgba(24, 16, 17, 0.96), rgba(11, 11, 11, 0.98));
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}

.saya-age-modal-card h3 {
  margin: 0 0 10px;
  font-size: 1.25rem;
}

.saya-age-modal-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.saya-age-modal-disclaimer {
  margin-top: 12px !important;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 89, 98, 0.3);
  background: rgba(194, 13, 22, 0.11);
  color: #ffd2d5 !important;
  font-size: 0.92rem;
}

.saya-age-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.saya-age-modal-actions .btn {
  min-width: 174px;
  justify-content: center;
}

@media (max-width: 640px) {
  .saya-age-modal-card {
    padding: 16px;
  }

  .saya-age-modal-actions {
    flex-direction: column;
  }

  .saya-age-modal-actions .btn {
    width: 100%;
  }
}

.saya-dl-btn {
  margin-top: auto;
  align-self: flex-start;
}

@media (max-width: 640px) {
  .saya-dl-options {
    grid-template-columns: 1fr;
    grid-template-areas:
      'lbk'
      'zip'
      'exe'
      'dlc';
  }

  .saya-dl-name {
    font-size: 1.16rem;
  }
}

/* FAQ */
.saya-faq {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.saya-faq-item {
  border-bottom: 1px solid var(--line);
}

.saya-faq-item:first-child {
  border-top: 1px solid var(--line);
}

.saya-faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 4px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  list-style: none;
  user-select: none;
  transition: color 0.2s ease;
}

.saya-faq-q::-webkit-details-marker { display: none; }

.saya-faq-q::after {
  content: '';
  width: 10px;
  height: 10px;
  border-right: 2px solid rgba(255,89,98,0.7);
  border-bottom: 2px solid rgba(255,89,98,0.7);
  transform: rotate(45deg);
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.saya-faq-item[open] > .saya-faq-q::after {
  transform: rotate(-135deg);
}

.saya-faq-item[open] > .saya-faq-q {
  color: #ff7c83;
}

.saya-faq-a {
  padding: 0 4px 18px;
}

.saya-faq-a p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
  font-size: 0.93rem;
}

.saya-faq-a a {
  color: #ff7c83;
  text-decoration: none;
  border-bottom: 1px solid rgba(255,89,98,0.35);
  transition: border-color 0.2s ease;
}

.saya-faq-a a:hover {
  border-color: #ff5962;
}

.project-cover-wrap {
  position: relative;
  overflow: hidden;
}

.collab-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(10, 5, 5, 0.93);
  color: #fff;
  padding: 14px 14px 12px;
  transform: translateY(100%);
  opacity: 0;
  transition: transform .32s cubic-bezier(.22, 1, .36, 1), opacity .28s ease;
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.project-card:hover .collab-overlay {
  transform: translateY(0);
  opacity: 1;
}

.collab-overlay .co-tag {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #b8860b;
  margin-bottom: 2px;
}

.collab-overlay .co-title {
  font-size: 13.5px;
  font-weight: 600;
  color: #fff;
  line-height: 1.3;
}

.collab-overlay .co-desc {
  font-size: 11.5px;
  color: rgba(255, 255, 255, .62);
  line-height: 1.5;
}

.collab-overlay .co-partners {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  font-size: 11px;
  color: rgba(255, 255, 255, .5);
}

.collab-overlay .co-partners strong {
  color: rgba(255, 255, 255, .85);
  font-weight: 500;
}

.collab-link {
  position: absolute;
  bottom: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: rgba(255, 255, 255, .4);
  text-decoration: none;
  transition: color .2s ease;
  white-space: nowrap;
  z-index: 1;
}

.collab-link:hover {
  color: rgba(255, 255, 255, .85);
}

.collab-link strong {
  font-weight: 600;
  color: inherit;
}

.collab-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: rgba(255, 255, 255, .45);
  text-decoration: none;
  transition: color .2s ease;
  white-space: nowrap;
}

.collab-link:hover {
  color: rgba(255, 255, 255, .85);
}

.collab-link strong {
  font-weight: 600;
  color: inherit;
}

/* ─────────────────────────────────────────────────────────────── */

@media (max-width: 980px) {
  .header-inner {
    grid-template-columns: 1fr auto;
    padding: 10px 16px;
  }

  .site-nav {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .project-grid,
  .about-grid,
  .support,
  .gh-widget-grid {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: clamp(2.2rem, 10vw, 3.4rem);
  }

  .hero-center {
    padding-top: 110px;
  }

  .hero-text {
    font-size: 0.95rem;
    max-width: 36ch;
  }

  .saya-hero .hero-text {
    width: 100%;
    max-width: none;
  }

  .hero-actions {
    flex-direction: column;
    width: 100%;
  }

  .hero-actions .btn-screenshots {
    display: none;
  }

  .hero-actions .btn-primary {
    width: 100%;
    padding: 15px 20px;
    font-size: 1rem;
  }

  .hero-stats {
    gap: 0;
  }

  .hero-stat {
    flex: 1;
    padding: 0 8px;
    border-right: 1px solid var(--line);
  }

  .hero-stat:last-child {
    border-right: none;
  }

  .hero-stat-sep {
    display: none;
  }

  .hero-stat strong {
    font-size: 1.3rem;
  }

  .hero-stat span {
    font-size: 0.7rem;
  }

  .join-inner {
    grid-template-columns: 1fr;
    padding: 24px 20px;
  }

  .join-icon {
    display: none;
  }

  .saya-hero-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .saya-hero-visual {
    order: -1;
  }

  .saya-capsule {
    max-width: 360px;
    margin: 0 auto;
  }

  .saya-screenshots-grid {
    grid-template-columns: 1fr 1fr;
  }

  .saya-progress-main {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .saya-progress-item {
    grid-template-columns: 1fr auto;
  }

  .saya-progress-numbers {
    grid-column: 1 / 2;
    white-space: normal;
  }

  .saya-progress-value {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
    align-self: start;
  }

  .saya-progress-item-track {
    grid-column: 1 / 3;
  }

}

@media (max-width: 560px) {
  .brand-title {
    font-size: 0.88rem;
  }

  .brand-sub {
    font-size: 0.72rem;
  }

  .projects,
  .about,
  .join,
  .oss,
  .support,
  .site-footer,
  .saya-section,
  .saya-hero {
    padding-left: 14px;
    padding-right: 14px;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-stats {
    gap: 0;
  }

  .hero-stat-sep {
    display: none;
  }

  .hero-stat {
    min-width: unset;
  }

  .join-inner {
    padding: 20px 16px;
  }

  .project-body {
    padding: 12px 12px 40px;
  }

  .saya-screenshots-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .saya-progress-main {
    padding: 16px;
  }

  .saya-progress-item {
    padding: 14px;
  }

  .saya-progress-value {
    font-size: 1.45rem;
    min-width: 44px;
  }

}

@media (max-width: 640px) {
  .saya-section,
  .saya-hero,
  .saya-hero-grid,
  .saya-hero-copy,
  .saya-dashboard-shell,
  .saya-dashboard-window,
  .saya-dashboard-page,
  .saya-dashboard-main-inner,
  .saya-dashboard-metric-row,
  .saya-dashboard-subpoint-head,
  .saya-dl-options,
  .saya-dl-option,
  .saya-release-gate,
  .saya-release-gate__countdown,
  .saya-release-gate__footer {
    min-width: 0;
  }

  .saya-hero {
    padding-top: 100px;
  }

  .saya-hero-copy h1 {
    font-size: clamp(1.8rem, 9vw, 2.35rem);
  }

  .saya-hero .hero-text {
    width: 100%;
    max-width: none;
  }

  .saya-meta-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 12px;
  }

  .saya-meta-item:last-child {
    grid-column: span 2;
    flex-direction: row;
    align-items: center;
    gap: 8px;
  }

  .saya-meta-item:last-child .status {
    width: fit-content;
    white-space: nowrap;
  }

  .saya-hero .hero-actions,
  .saya-hero .hero-actions .btn {
    width: 100%;
  }

  .saya-dashboard-window {
    aspect-ratio: auto;
  }

  .saya-dashboard-page {
    height: auto;
    padding: 42px 12px 16px;
  }

  .saya-dashboard-kanji {
    top: -20px;
    font-size: clamp(48px, 19vw, 70px);
  }

  .saya-dashboard-title {
    font-size: clamp(1.35rem, 7vw, 1.8rem);
  }

  .saya-dashboard-meta,
  .saya-dashboard-main-meta {
    font-size: 0.78rem;
  }

  .saya-dashboard-main-card,
  .saya-dashboard-metric-row {
    padding: 12px;
  }

  .saya-dashboard-main-inner {
    gap: 10px;
  }

  .saya-dashboard-main-pct {
    font-size: clamp(2.5rem, 14vw, 3.5rem);
  }

  .saya-dashboard-main-label {
    font-size: 0.76rem;
    margin-bottom: 6px;
  }

  .saya-dashboard-metric-row {
    gap: 6px 10px;
  }

  .saya-dashboard-metric-name {
    font-size: 0.8rem;
    letter-spacing: 0.04em;
  }

  .saya-dashboard-metric-nums {
    font-size: 0.72rem;
  }

  .saya-dashboard-metric-pct {
    font-size: clamp(2rem, 11vw, 2.7rem);
    min-width: 0;
  }

  .saya-dashboard-subpoint-nums {
    white-space: normal;
  }

  .saya-dashboard-footer {
    flex-direction: column;
    align-items: center;
    gap: 3px;
    font-size: 0.68rem;
    text-align: center;
  }

  .saya-dl-option {
    padding: 22px 16px 16px;
  }

  .saya-dl-btn {
    align-self: stretch;
    white-space: normal;
  }

  .lb-img-wrap {
    width: calc(100vw - 16px);
    max-width: 100%;
    max-height: calc(100dvh - 112px);
    padding: 0;
  }

  .lb-img {
    max-width: 100%;
    max-height: calc(100dvh - 112px);
    object-fit: contain;
  }

  .lb-nav {
    width: 40px;
    height: 40px;
  }

  .lb-prev { left: max(8px, env(safe-area-inset-left)); }
  .lb-next { right: max(8px, env(safe-area-inset-right)); }

  .lb-close {
    top: max(12px, env(safe-area-inset-top));
    right: max(12px, env(safe-area-inset-right));
  }
}

@media (max-width: 380px) {
  .header-inner {
    padding-right: 12px;
    padding-left: 12px;
    gap: 8px;
  }

  .brand-logo {
    width: 40px;
    height: 40px;
  }

  .brand {
    gap: 10px;
  }

  .brand-sub {
    display: none;
  }

  .hero-center {
    padding-right: 14px;
    padding-left: 14px;
  }

  .hero-stat {
    padding: 0 4px;
  }

  .hero-stat span {
    font-size: 0.64rem;
  }
}
