:root {
  --navy: #0b1d33;
  --navy-deep: #07111f;
  --blue: #2f86a6;
  --blue-soft: #dceef1;
  --blue-pale: #edf7f7;
  --coral: #d33f4a;
  --coral-light: #ed8073;
  --yellow: #e2a632;
  --ink: #101923;
  --muted: #6b7782;
  --line: rgba(11, 29, 51, 0.18);
  --cream: #f4efe3;
  --shadow: 0 18px 50px rgba(5, 16, 29, 0.24);
  --radius: 12px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background: var(--navy);
  font-family: "Trebuchet MS", Arial, sans-serif;
  line-height: 1.55;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background-position: center;
  background-size: cover;
  pointer-events: none;
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
}

.theme-home::before { background-image: url("assets/home-monokuma-sitting.png"); filter: blur(2px); transform: scale(1.02); }
.theme-home::after { background: linear-gradient(120deg, rgba(7, 17, 31, .95), rgba(11, 29, 51, .76) 56%, rgba(46, 24, 32, .82)); }
.theme-dr2 { background: #b9d9dc; }
.theme-dr2::before { background-image: url("assets/dr2-beach.png"); opacity: .28; }
.theme-dr2::after { background: linear-gradient(135deg, rgba(236, 249, 249, .9), rgba(174, 215, 218, .74)); }
.theme-gifts { background: #14283a; }
.theme-gifts::before { background-image: url("assets/dr2-island.jpg"); opacity: .12; }
.theme-gifts::after { background: linear-gradient(135deg, rgba(7, 17, 31, .94), rgba(20, 40, 58, .9)); }

a { color: inherit; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }

.site-container { width: min(1180px, calc(100% - 36px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 2px solid var(--coral-light);
  background: rgba(7, 17, 31, .96);
  color: #fff;
  backdrop-filter: blur(14px);
}

.nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 70px; }
.brand { font-size: 1rem; font-weight: 900; letter-spacing: .045em; text-decoration: none; white-space: nowrap; }
.brand span { color: var(--coral-light); }
.nav-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; min-width: 0; }
.social-links { display: flex; align-items: center; gap: 7px; padding-right: 11px; border-right: 1px solid rgba(255,255,255,.18); }
.social-links a { display: grid; width: 36px; height: 36px; place-items: center; border: 1px solid rgba(255,255,255,.18); border-radius: 50%; background: rgba(255,255,255,.06); transition: border-color .18s ease, background .18s ease, transform .18s ease; }
.social-links a:hover { border-color: var(--coral-light); background: rgba(211,63,74,.2); transform: translateY(-2px); }
.social-links img { display: block; width: 18px; height: 18px; }
.main-nav { display: flex; align-items: stretch; gap: 8px; }
.main-nav a { padding: 24px 12px 18px; color: rgba(255,255,255,.78); font-size: .83rem; font-weight: 800; letter-spacing: .04em; text-decoration: none; white-space: nowrap; }
.main-nav a:hover, .main-nav a.active { color: var(--coral-light); }
.main-nav a.active { box-shadow: inset 0 -3px var(--coral-light); }

.page-content { padding: 46px 0 80px; }
.panel { border: 1px solid rgba(255,255,255,.18); border-radius: var(--radius); box-shadow: var(--shadow); }
.panel-dark { background: rgba(7, 17, 31, .86); color: #fff; }
.panel-blue { background: rgba(21, 65, 91, .9); color: #fff; }
.panel-light { background: rgba(246, 250, 248, .94); color: var(--ink); border-color: rgba(11, 29, 51, .2); }

.home-hero, .atlas-hero { padding: clamp(28px, 6vw, 68px); }
.home-hero { min-height: 300px; display: flex; flex-direction: column; justify-content: center; border-left: 5px solid var(--coral); }
.atlas-hero { border-left: 5px solid var(--yellow); }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.08; letter-spacing: -.035em; }
h1 { max-width: 790px; margin-bottom: 20px; font-size: clamp(2.35rem, 6vw, 5rem); }
h1 span { color: var(--coral-light); }
h2 { margin-bottom: 14px; font-size: clamp(1.7rem, 3vw, 2.7rem); }
h3 { margin-bottom: 10px; font-size: 1.28rem; }
.hero-lead { max-width: 700px; margin-bottom: 0; color: rgba(255,255,255,.78); font-size: clamp(1rem, 2vw, 1.22rem); }
.panel-light .hero-lead, .dr2-hero .hero-lead { color: #4c606a; }
.eyebrow { margin-bottom: 10px; color: var(--coral-light); font-size: .74rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; }
.panel-light .eyebrow { color: #0f7693; }
.section-block { margin-top: 66px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 20px; color: #fff; }
.theme-dr2 .section-heading { color: var(--navy); }
.section-heading h2 { margin-bottom: 0; }
.section-mark { color: var(--yellow); font-weight: 900; letter-spacing: .12em; }

.intro-note { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 28px; align-items: center; margin-top: 28px; padding: 22px 30px 22px 18px; border-left: 5px solid var(--yellow); }
.nagito-frame { display: flex; flex-direction: column; align-items: center; align-self: stretch; justify-content: end; min-height: 300px; overflow: hidden; border-radius: 8px; background: linear-gradient(180deg, rgba(219, 245, 248, .16), rgba(6, 18, 30, .35)); }
.nagito-art { display: block; width: 520px; max-width: none; height: 286px; object-fit: contain; object-position: bottom center; }
.image-caption { width: 100%; padding: 5px 10px; color: rgba(255,255,255,.72); background: rgba(7, 17, 31, .5); font-size: .75rem; text-align: center; }
.image-caption-jikan { padding-block: 8px; color: #fff; font-family: "Barlow Condensed", "Arial Narrow", sans-serif; font-size: 1.25rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.intro-copy h2 { max-width: 650px; color: #fff; }
.writer-space { min-height: 96px; max-width: 700px; border: 1px dashed rgba(255,255,255,.4); border-radius: 8px; background: rgba(255,255,255,.06); }
.project-note-copy { max-width: 760px; color: rgba(255,255,255,.84); font-size: .95rem; }
.project-note-copy p { margin-bottom: 12px; }
.project-note-copy p:last-child { margin-bottom: 0; }
.gift-note-link { color: #ff8b83; font-weight: 900; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.gift-note-link:hover { color: #fff; }

.project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.project-card { overflow: hidden; border: 1px solid rgba(255,255,255,.24); border-radius: var(--radius); background: rgba(7,17,31,.86); color: #fff; box-shadow: var(--shadow); }
.project-card-active { border-color: var(--coral-light); }
.project-image { display: grid; place-items: center; min-height: 170px; padding: 18px; background: #eaf5f5; }
.project-image img { display: block; width: 100%; max-height: 142px; object-fit: contain; }
.project-image-dr1 { background: #f1edf1; }
.project-image-dr3 { background: #f6f7f8; }
.project-card-body { padding: 20px; }
.card-kicker { margin-bottom: 6px; color: var(--coral-light); font-size: .72rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.project-card h3 { margin-bottom: 14px; }
.status-pill { display: inline-block; padding: 4px 10px; border: 1px solid rgba(255,255,255,.42); border-radius: 999px; color: rgba(255,255,255,.8); font-size: .76rem; font-weight: 800; }
.text-link { color: var(--coral-light); font-weight: 900; text-decoration: none; }
.text-link:hover { text-decoration: underline; }

.birthday-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.birthday-card { padding: 20px; border-left: 4px solid var(--yellow); border-radius: 8px; background: rgba(7,17,31,.82); color: #fff; }
.birthday-card strong, .birthday-card span { display: block; }
.birthday-card strong { margin-bottom: 6px; }
.birthday-card span { color: rgba(255,255,255,.65); font-size: .84rem; }
.birthday-card small { display: block; margin-top: 10px; color: var(--yellow); font-size: .74rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.birthday-card-next { border-left-color: var(--coral); box-shadow: inset 0 0 0 1px rgba(211,63,74,.22); }
.birthday-feature { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 26px; align-items: center; margin-top: 18px; padding: 18px 24px 18px 18px; }
.pixel-runner-stage { display: grid; min-height: 145px; place-items: center; overflow: hidden; border: 1px solid rgba(255,255,255,.16); border-radius: 8px; background: rgba(0,0,0,.28); }
.pixel-runner { display: block; width: 116px; aspect-ratio: 1; clip-path: inset(6px); background-image: url("assets/dr2-pixel-sheet.png"); background-position: 0 var(--pixel-y, 0%); background-repeat: no-repeat; background-size: 1600% 1900%; image-rendering: pixelated; image-rendering: crisp-edges; animation: birthday-run 1.45s steps(15, end) infinite; }
.birthday-feature-copy h3 { margin-bottom: 8px; color: #fff; font-size: 1.8rem; }
.birthday-date { margin-bottom: 0; color: rgba(255,255,255,.84); }
.birthday-date strong { color: var(--yellow); }
@keyframes birthday-run { from { background-position-x: 0%; } to { background-position-x: 100%; } }
.favorite-feature { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 26px; align-items: center; padding: 18px 24px 18px 18px; }
.favorite-feature-copy h3 { margin-bottom: 8px; color: #fff; font-size: clamp(1.9rem, 4vw, 2.8rem); }
.favorite-vote-count { margin-bottom: 0; color: var(--yellow); font-weight: 900; }
.favorite-feature .button { margin-top: 18px; }
.favorite-runner-stage { background: radial-gradient(circle at center, rgba(226,166,50,.2), rgba(0,0,0,.3) 68%); }
.favorite-runner { animation: favorite-pixel-cycle 1.95s steps(15, end) infinite, favorite-pixel-hop .95s ease-in-out infinite alternate; transform-origin: center bottom; }
.favorite-monokuma { clip-path: inset(6px); background-color: #d8eeee; background-image: url("assets/monokuma-bustups.png"), linear-gradient(180deg, #d8eeee, #0b1d33 88%); background-position: 7.3% 1.1%, center; background-size: 820% 944%, 100% 100%; animation: favorite-monokuma-hop 1.05s ease-in-out infinite alternate; }
@keyframes favorite-pixel-cycle { from { background-position-x: 0%; } to { background-position-x: 100%; } }
@keyframes favorite-pixel-hop { from { transform: translateY(4px) scale(1); } to { transform: translateY(-7px) scale(1.04); } }
@keyframes favorite-monokuma-hop { from { transform: translateY(3px) rotate(-1deg); } to { transform: translateY(-6px) rotate(1deg); } }
.home-footer-note { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 66px; padding: 26px 30px; }
.home-footer-note p:not(.eyebrow) { margin-bottom: 0; color: #54616b; }
.note-badge { padding: 8px 12px; border: 1px solid var(--blue); border-radius: 999px; color: #0f7693; font-size: .76rem; font-weight: 900; white-space: nowrap; }

.comments-layout { display: grid; grid-template-columns: minmax(290px, .72fr) minmax(0, 1.28fr); gap: 18px; align-items: start; }
.comment-form { position: sticky; top: 92px; display: grid; gap: 9px; padding: 24px; }
.comment-form h3 { margin-bottom: 4px; }
.comment-form label { color: var(--navy); font-size: .78rem; font-weight: 900; letter-spacing: .04em; }
.comment-form input, .comment-form textarea, .reply-form input, .reply-form textarea { width: 100%; padding: 11px 12px; border: 1px solid rgba(11,29,51,.24); border-radius: 6px; outline: none; background: #fff; color: var(--ink); resize: vertical; }
.comment-form input:focus, .comment-form textarea:focus, .reply-form input:focus, .reply-form textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,134,166,.14); }
.comment-form-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 4px; }
.form-status { min-height: 1.2em; margin: 0; color: #5a6870; font-size: .76rem; }
.form-status.error { color: #a92f3a; }
.comment-honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.comment-list { display: grid; gap: 12px; }
.comments-loading, .comments-empty { margin: 0; padding: 24px; border: 1px dashed rgba(255,255,255,.28); border-radius: 9px; color: rgba(255,255,255,.75); text-align: center; }
.comment-card { padding: 18px 20px; border: 1px solid rgba(255,255,255,.17); border-radius: 9px; background: rgba(7,17,31,.88); color: #fff; box-shadow: 0 12px 28px rgba(3,10,18,.18); }
.comment-card.reply { margin-top: 10px; margin-left: 34px; border-left: 3px solid var(--blue); background: rgba(20,47,66,.94); }
.comment-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 8px; }
.comment-meta strong { color: var(--coral-light); }
.comment-meta time { color: rgba(255,255,255,.5); font-size: .7rem; }
.comment-message { margin: 0; color: rgba(255,255,255,.86); white-space: pre-wrap; overflow-wrap: anywhere; }
.comment-actions { margin-top: 10px; }
.reply-toggle { padding: 0; border: 0; background: none; color: #8dd5e2; font-weight: 900; cursor: pointer; }
.reply-toggle:hover { color: #fff; text-decoration: underline; }
.reply-form { display: grid; gap: 8px; margin-top: 12px; padding: 14px; border-radius: 7px; background: rgba(255,255,255,.08); }
.reply-form-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.reply-form .button { min-height: 38px; padding: 8px 13px; }

.dr2-hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr); gap: 30px; align-items: center; padding: clamp(26px, 5vw, 54px); }
.dr2-hero h1 { color: var(--navy); font-size: clamp(2.2rem, 5vw, 4.6rem); }
.dr2-hero h1 span { color: #0f7693; }
.dr2-hero-art { display: grid; gap: 14px; align-items: center; }
.dr2-logo-art { display: block; width: min(100%, 460px); margin: 0 auto; border-radius: 8px; mix-blend-mode: multiply; }
.dr2-cover-art { display: block; width: 100%; max-height: 220px; object-fit: cover; object-position: center; border: 1px solid rgba(11,29,51,.18); border-radius: 8px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 45px; padding: 11px 18px; border: 1px solid transparent; border-radius: 6px; font-size: .78rem; font-weight: 900; letter-spacing: .07em; text-decoration: none; text-transform: uppercase; cursor: pointer; transition: transform .18s ease, filter .18s ease; }
.button:hover { filter: brightness(1.08); transform: translateY(-2px); }
.button:disabled { filter: grayscale(.25); cursor: default; opacity: .62; transform: none; }
.button-coral { background: var(--coral); color: #fff; }
.button-navy { background: var(--navy); color: #fff; }
.micro-note { margin: 13px 0 0; color: rgba(255,255,255,.58); font-size: .78rem; }
.panel-light .micro-note, .dr2-hero .micro-note { color: #687a82; }
.view-counter { margin: 15px 0 0; color: #60737c; font-size: .78rem; font-weight: 800; letter-spacing: .04em; }
.view-counter strong { color: var(--coral); font-size: .96rem; }
.info-strip { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 16px; overflow: hidden; border: 1px solid rgba(11,29,51,.16); border-radius: 8px; background: rgba(244,239,227,.9); }
.info-strip div { padding: 16px 20px; border-right: 1px solid var(--line); }
.info-strip div:last-child { border-right: 0; }
.info-strip span, .info-strip strong { display: block; }
.info-strip span { color: #61717a; font-size: .71rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.info-strip strong { color: var(--navy); font-size: .92rem; }
.two-column-layout { display: grid; grid-template-columns: 1.25fr .75fr; gap: 18px; }
.setup-card { padding: 26px; }
.setup-card p:last-child { margin-bottom: 0; }
.step-list { display: grid; gap: 10px; margin: 18px 0; padding-left: 22px; }
.step-list li::marker { color: var(--coral); font-weight: 900; }
.setup-overview { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr); gap: 18px; }
.video-placeholder { display: grid; min-height: 300px; place-items: center; align-content: center; gap: 10px; border-color: rgba(255,255,255,.25); background: radial-gradient(circle at center, rgba(47,134,166,.22), rgba(7,17,31,.98) 68%); }
.video-play { display: grid; width: 70px; height: 70px; place-items: center; padding-left: 5px; border: 2px solid rgba(255,255,255,.78); border-radius: 50%; color: #fff; font-size: 1.6rem; }
.video-play-muted { padding-left: 0; border-color: rgba(255,255,255,.35); color: rgba(255,255,255,.58); }
.video-placeholder strong { color: rgba(255,255,255,.88); letter-spacing: .08em; text-transform: uppercase; }
.setup-warning { display: flex; flex-direction: column; justify-content: center; padding: 28px; }
.setup-warning code, .installation-step code { padding: 2px 5px; border-radius: 4px; background: rgba(11,29,51,.09); color: #9d2934; font-family: Consolas, monospace; font-size: .88em; }
.installation-guide { display: grid; gap: 14px; margin-top: 18px; }
.installation-step { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 22px; align-items: start; padding: 20px; }
.installation-step-body { min-width: 0; }
.installation-step p { margin-bottom: 8px; color: #52636c; }
.installation-step p:last-child { margin-bottom: 0; }
.installation-step a { color: #b62f3a; font-weight: 900; }
.step-visual { display: grid; min-height: 110px; place-items: center; border-radius: 7px; background: linear-gradient(145deg, var(--navy), #1b5d76); color: var(--coral-light); }
.step-visual span { font-size: 2.1rem; font-weight: 900; letter-spacing: .08em; }
.installation-media { display: grid; gap: 14px; margin-top: 18px; }
.installation-media-single { max-width: 780px; }
.installation-media-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.installation-shot { overflow: hidden; margin: 0; border: 1px solid rgba(11,29,51,.18); border-radius: 8px; background: #111820; box-shadow: 0 8px 20px rgba(7,17,31,.12); }
.installation-shot img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: contain; background: #111820; }
.installation-shot figcaption { min-height: 56px; padding: 11px 13px; background: #eef4f3; color: #42555e; font-size: .78rem; line-height: 1.45; }
.installation-shot figcaption code { font-size: .9em; }
.vote-panel { padding: 24px; }
.vote-section { scroll-margin-top: 90px; }
.section-intro { max-width: 700px; margin-bottom: 20px; color: rgba(255,255,255,.78); }
.vote-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); }
.vote-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 15px; margin-top: 20px; }
.vote-actions .micro-note { margin: 0; }
.feature-link-card { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 28px; }
.feature-link-card p { max-width: 700px; margin-bottom: 0; color: #596970; }

.asset-note { margin-top: 28px; padding: 14px 18px; border-left: 4px solid var(--yellow); border-radius: 6px; background: rgba(226,166,50,.14); color: #f8efda; font-size: .86rem; }
.search-box input { width: min(260px, 42vw); padding: 11px 14px; border: 1px solid rgba(255,255,255,.32); border-radius: 7px; outline: 0; background: rgba(7,17,31,.72); color: #fff; }
.search-box input::placeholder { color: rgba(255,255,255,.62); }
.character-grid { display: grid; gap: 10px; }
.gift-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); }
.character-button { display: grid; gap: 8px; min-width: 0; padding: 9px; border: 1px solid rgba(255,255,255,.22); border-radius: 8px; background: rgba(7,17,31,.84); color: #fff; text-align: left; cursor: pointer; transition: border-color .18s ease, transform .18s ease, background .18s ease; }
.character-button:hover, .character-button.selected { border-color: var(--coral-light); background: rgba(22,61,83,.96); transform: translateY(-2px); }
.character-button.selected { box-shadow: 0 0 0 2px rgba(237,128,115,.25); }
.avatar { display: grid; place-items: center; aspect-ratio: .68; overflow: hidden; border-radius: 6px; background: linear-gradient(145deg, #2f86a6, #0b1d33 72%); color: #fff; font-size: clamp(.8rem, 1.8vw, 1.2rem); font-weight: 900; letter-spacing: .05em; }
.image-avatar { background: linear-gradient(180deg, #d8eeee, #0b1d33 88%); }
.image-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.pixel-art { image-rendering: pixelated; image-rendering: crisp-edges; }
.sprite-avatar { display: block; aspect-ratio: .58; background-color: #008c8c; background-image: url("assets/dr2-class-trial-mugshots.png"); background-position: var(--sprite-x) var(--sprite-y); background-repeat: no-repeat; background-size: auto 400%; }
.sprite-sheet-avatar { display: block; aspect-ratio: var(--sprite-aspect, 1); clip-path: inset(4px); background-color: #000; background-image: var(--sprite-image); background-position: var(--sprite-x) var(--sprite-y); background-repeat: no-repeat; background-size: var(--sprite-size); }
[data-character-id="monokuma"] .sprite-sheet-avatar {
  background-color: #d8eeee;
  background-image: var(--sprite-image), linear-gradient(180deg, #d8eeee, #0b1d33 88%);
  background-position: var(--sprite-x) calc(var(--sprite-y) - .45%), center;
  background-size: var(--sprite-size), 100% 100%;
}
.character-name { min-height: 34px; font-size: .74rem; font-weight: 800; line-height: 1.15; }
.portrait-note { color: rgba(255,255,255,.48); font-size: .61rem; line-height: 1.1; }
.gift-detail { display: grid; grid-template-columns: 1fr; gap: 20px; padding: 28px; }
.gift-summary { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 18px; }
.detail-character, .present-preview { min-height: 330px; padding: 22px; border-radius: 8px; background: linear-gradient(145deg, #2f86a6, #0b1d33 72%); color: #fff; }
.detail-character { display: grid; grid-template-columns: minmax(190px, 230px) minmax(0, 1fr); gap: 24px; align-items: end; }
.detail-character .avatar { width: 100%; margin: 0; background: rgba(255,255,255,.12); font-size: 2.5rem; }
.detail-character-copy { align-self: end; padding-bottom: 8px; }
.detail-character h3 { margin-bottom: 7px; font-size: clamp(1.7rem, 3vw, 2.3rem); }
.detail-character p { max-width: 290px; margin-bottom: 0; color: rgba(255,255,255,.7); font-size: .86rem; }
.present-preview { --category-color: #22a8aa; --category-tint: #dff7f7; display: grid; grid-template-columns: minmax(170px, 230px) minmax(0, 1fr); gap: 22px; align-items: center; border-top: 4px solid var(--category-color); }
.present-sprite { width: 100%; aspect-ratio: 1.304; border: 3px solid var(--category-color); background-color: #000; background-image: var(--present-image); background-position: var(--present-x) var(--present-y); background-repeat: no-repeat; background-size: 800% 1800%; image-rendering: pixelated; box-shadow: 0 10px 22px rgba(0,0,0,.28); }
.present-preview-copy { min-width: 0; }
.present-preview-label { display: block; margin-bottom: 8px; color: var(--category-color); font-family: "Barlow Condensed", "Arial Narrow", sans-serif; font-size: .9rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.present-preview strong { display: block; color: #fff; font-size: 1.16rem; line-height: 1.35; }
.present-preview-hint { grid-column: 1 / -1; align-self: center; color: rgba(255,255,255,.75); font-size: .9rem; line-height: 1.5; text-align: center; }
.gift-categories { display: grid; grid-template-columns: 1fr; gap: 10px; align-content: start; }
.gift-category { --category-color: var(--blue); --category-tint: #e5f4f7; --category-ink: #18566b; display: grid; grid-template-columns: minmax(150px, 180px) minmax(0, 1fr); overflow: hidden; border: 1px solid var(--line); border-left: 5px solid var(--category-color); border-radius: 7px; background: #f7fbfa; }
.gift-loves { --category-color: #d94f96; --category-tint: #fde5f2; --category-ink: #8c245c; }
.gift-likes { --category-color: #d76f63; --category-tint: #fde8e4; --category-ink: #893b32; }
.gift-ok { --category-color: #7d9653; --category-tint: #eef3e3; --category-ink: #50632f; }
.gift-dislikes { --category-color: #806ca5; --category-tint: #eee9f7; --category-ink: #574272; }
.gift-hates { --category-color: #d34c55; --category-tint: #fde6e8; --category-ink: #8b2830; }
.gift-category h3 { display: flex; align-items: center; min-height: 100%; margin: 0; padding: 15px 17px; background: var(--category-tint); color: var(--category-ink); font-size: 1rem; }
.gift-category p { margin: 0; padding: 14px 16px; color: var(--category-ink); font-size: .84rem; }
.gift-category ul { display: flex; flex-wrap: wrap; gap: 7px 8px; align-content: start; margin: 0; padding: 13px 16px; list-style: none; color: var(--category-ink); font-size: .82rem; line-height: 1.4; }
.gift-item-button { display: inline-flex; padding: 5px 8px; border: 1px solid color-mix(in srgb, var(--category-color) 42%, transparent); border-radius: 4px; background: var(--category-tint); color: var(--category-ink); font: inherit; font-weight: 650; line-height: inherit; text-align: left; cursor: pointer; }
.gift-item-button:hover { border-color: var(--category-color); filter: brightness(.97); }
.gift-item-button:focus-visible { outline: 2px solid var(--coral); outline-offset: 2px; }
.gift-item-button.selected { border-color: var(--category-color); background: var(--category-color); color: #fff; font-weight: 800; }

.site-footer { border-top: 1px solid rgba(255,255,255,.16); background: rgba(7,17,31,.94); color: rgba(255,255,255,.66); }
.footer-wrap { display: flex; justify-content: space-between; gap: 28px; padding: 22px 0; font-size: .76rem; }
.footer-wrap span:first-child { color: var(--coral-light); font-weight: 900; letter-spacing: .08em; }
.footer-wrap span:last-child { max-width: 720px; text-align: right; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

@media (max-width: 930px) {
  .nav-wrap { align-items: flex-start; flex-direction: column; gap: 0; padding-top: 12px; }
  .nav-actions { justify-content: space-between; width: 100%; }
  .main-nav a { padding-inline: 7px; font-size: .72rem; }
  .project-grid, .birthday-grid { grid-template-columns: 1fr; }
  .dr2-hero, .two-column-layout, .setup-overview, .comments-layout { grid-template-columns: 1fr; }
  .comment-form { position: static; }
  .dr2-hero-art { grid-template-columns: 1fr 1fr; }
  .dr2-logo-art { grid-column: 1 / -1; }
  .vote-grid, .gift-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .gift-summary { grid-template-columns: 1fr; }
}

@media (max-width: 650px) {
  .site-container { width: min(100% - 24px, 520px); }
  .brand { font-size: .86rem; }
  .nav-actions { align-items: flex-start; flex-direction: column; padding-top: 8px; }
  .social-links { padding-right: 0; border-right: 0; }
  .main-nav { width: 100%; overflow-x: auto; }
  .main-nav a { padding: 12px 9px 14px; font-size: .68rem; }
  .page-content { padding-top: 24px; }
  .intro-note { grid-template-columns: 1fr; padding: 16px; }
  .nagito-frame { min-height: 270px; }
  .nagito-art { width: 480px; height: 256px; }
  .writer-space { min-height: 84px; }
  .section-block { margin-top: 46px; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .search-box, .search-box input { width: 100%; }
  .search-box input { background: rgba(7,17,31,.86); }
  .info-strip { grid-template-columns: 1fr; }
  .info-strip div { border-right: 0; border-bottom: 1px solid var(--line); }
  .info-strip div:last-child { border-bottom: 0; }
  .dr2-hero-art { grid-template-columns: 1fr; }
  .dr2-logo-art { grid-column: auto; }
  .feature-link-card, .home-footer-note, .footer-wrap { align-items: flex-start; flex-direction: column; }
  .footer-wrap span:last-child { text-align: left; }
  .vote-grid, .gift-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gift-detail { padding: 16px; }
  .detail-character, .present-preview { grid-template-columns: 1fr; min-height: 0; }
  .detail-character .avatar { max-width: 210px; }
  .detail-character-copy { padding-bottom: 0; }
  .present-sprite { max-width: 240px; }
  .present-preview-hint { min-height: 150px; }
  .gift-category { grid-template-columns: 1fr; }
  .gift-category h3 { min-height: auto; }
  .birthday-feature, .favorite-feature { grid-template-columns: 1fr; padding: 16px; }
  .pixel-runner-stage { min-height: 130px; }
  .installation-step { grid-template-columns: 1fr; }
  .step-visual { min-height: 74px; }
  .installation-media-pair { grid-template-columns: 1fr; }
  .comment-card.reply { margin-left: 14px; }
  .comment-meta { align-items: flex-start; flex-direction: column; gap: 2px; }
}
