/* =========================================================
   aliba games のページ（一覧 /games/ と各タイトル /games/<名前>/ で共通）
   地: 第一画面とタイトルの箱の面＝やわらかいオレンジ（--g-bg）、一覧＝淡いクリーム（--games-soft）
   オレンジの面の上の文字は濃い字（白は小さい字で4.5:1に届かないため）
   ========================================================= */
:root{
  --sec-y:120px; --head-gap:48px; --card-pad:24px; --wrap:1200px;
  --g-bg:#f58a3c; --g-ink:#b4490c;
}
@media (max-width:599px){ :root{ --sec-y:80px; --head-gap:32px; } }
*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; -webkit-text-size-adjust:100%; }
body{ margin:0; font-family:var(--f-base); color:var(--ink); background:var(--paper); font-size:16px; line-height:1.85; overflow-x:clip; }
img{ max-width:100%; height:auto; display:block; }
a{ color:inherit; }
h1,h2,h3,h4,p,ul,ol,dl,dd,figure{ margin:0; }
ul,ol{ padding:0; list-style:none; }
:focus-visible{ outline:3px solid var(--corp); outline-offset:3px; }
.g-hero :focus-visible, .g-panel :focus-visible{ outline-color:var(--ink); }
h1,h2,h3,p,li,.vt,.gc-name,.gc-catch{ word-break:auto-phrase; }
h2,h3{ text-wrap:balance; }
.sr-only{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
.vid, .acct-big, .sns-chip, .gcard{ position:relative; }
.nw{ white-space:nowrap; }
.wrap{ width:100%; max-width:calc(var(--wrap) + var(--gutter) * 2); margin:0 auto; padding:0 var(--gutter); }

.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:10px;
  min-height:52px; padding:0 26px; border-radius:var(--radius);
  font-weight:700; font-size:16px; text-decoration:none; line-height:1.3; border:2px solid transparent;
  transition:background-color .2s, color .2s;
}
.btn .arw{ width:18px; height:18px; flex:none; }
.btn--corp{ background:var(--corp); color:#fff; }
.btn--corp:hover{ background:var(--corp-dark); }
.btn--games{ background:var(--g-ink); color:#fff; }
.btn--games:hover{ background:#8f3a0a; }
.btn--games-line{ background:transparent; color:var(--g-ink); border-color:var(--g-ink); }
.btn--games-line:hover{ background:var(--g-ink); color:#fff; }

.px{ position:absolute; display:block; pointer-events:none; }
.px svg{ display:block; width:100%; height:100%; fill:currentColor; }

.sec{ padding:var(--sec-y) 0; }
.sec-head{ margin-bottom:var(--head-gap); max-width:900px; }
.kicker{ font-size:15px; font-weight:700; letter-spacing:.18em; color:var(--g-ink); margin-bottom:14px; line-height:1.4; }
.sec h2{ font-size:40px; line-height:1.4; font-weight:900; letter-spacing:.03em; }
.sec-head p.lead{ margin-top:20px; font-size:17px; }
@media (max-width:1023px){ .sec h2{ font-size:32px; } }
@media (max-width:599px){ .sec h2{ font-size:26px; } .sec-head p.lead{ font-size:16px; } }

/* ---------- 第一画面（一覧） ---------- */
.g-hero{ background:var(--g-bg); color:var(--ink); padding:80px 0 88px; overflow:hidden; }
.g-hero .wrap{ display:grid; grid-template-columns:minmax(0,1.1fr) minmax(0,1fr); gap:48px; align-items:center; }
.g-title{ display:flex; flex-direction:column; align-items:flex-start; gap:14px; margin-bottom:28px; }
.g-title img{ width:min(440px, 100%); height:auto; }
.g-title span{ font-size:17px; font-weight:700; color:var(--ink); background:var(--paper); padding:5px 10px; border-radius:4px; line-height:1.3; letter-spacing:.08em; }
.g-catch{ font-family:var(--f-play); font-weight:800; color:var(--ink); font-size:44px; line-height:1.45; letter-spacing:.04em; }
.g-catch span{ display:inline-block; }
.g-lead{ margin-top:20px; font-size:17px; max-width:34em; }
.sns-chips{ display:flex; flex-wrap:wrap; gap:10px; margin-top:32px; }
.g-to-titles{ margin-top:32px; }
.sns-chip{
  display:inline-flex; align-items:center; gap:10px; min-height:48px; padding:0 18px 0 8px;
  background:var(--paper); color:var(--ink); border-radius:var(--radius); text-decoration:none; font-weight:700; font-size:16px;
}
.sns-chip .sns-ic{ width:32px; height:32px; border-radius:4px; }
.sns-chip .sns-ic svg{ width:20px; height:20px; }
.sns-chip:hover{ box-shadow:inset 0 0 0 2px var(--ink); }

.g-stage{ position:relative; height:440px; container-type:size; }
.g-stage::after{
  content:""; position:absolute; left:50%; bottom:2px; width:min(260px,56%); height:24px;
  transform:translateX(-50%); background:rgba(122,40,0,.28); border-radius:50%; filter:blur(4px);
}
.g-stage .chara{ position:absolute; left:50%; bottom:10px; z-index:3; transform:translateX(-50%); width:min(280px, 62cqw, 74cqh); height:auto; }
.g-stage .px{ z-index:1; }
.g-stage .d-cloud1{ left:0; top:6%; width:min(170px,32cqw); aspect-ratio:120/56; color:rgba(255,255,255,.92); }
.g-stage .d-cloud2{ right:0; top:56%; width:min(130px,26cqw); aspect-ratio:120/56; color:rgba(255,255,255,.8); }
.g-stage .d-star1{ left:6%; top:52%; width:min(50px,10cqw); aspect-ratio:1; color:#ffe39a; }
.g-stage .d-star2{ right:10%; top:6%; width:min(42px,9cqw); aspect-ratio:1; color:#fff3e6; }
.g-stage .d-heart{ right:4%; top:30%; width:min(48px,10cqw); aspect-ratio:7/6; color:#fff3e6; }
.g-stage .d-plus1{ left:34%; top:4%; width:min(24px,5cqw); aspect-ratio:1; color:#fff3e6; }
.g-stage .d-plus2{ left:2%; top:84%; width:min(26px,5cqw); aspect-ratio:1; color:#ffe39a; }
.g-stage .d-plus3{ right:22%; top:82%; width:min(20px,4cqw); aspect-ratio:1; color:#fff3e6; }
.g-stage .d-sq1{ left:22%; top:32%; width:10px; height:10px; background:#ffc9a0; }
.g-stage .d-sq2{ right:30%; top:20%; width:8px; height:8px; background:#fff3e6; }
.g-stage .d-sq3{ left:60%; top:0; width:8px; height:8px; background:#ffe39a; }
@media (max-width:1023px){
  .g-hero{ padding:56px 0 64px; }
  .g-hero .wrap{ grid-template-columns:1fr; gap:24px; }
  .g-stage{ height:320px; order:-1; }
  .g-catch{ font-size:38px; }
}
@media (max-width:599px){
  .g-hero{ padding:32px 0 56px; }
  .g-stage{ height:250px; }
  .g-title img{ width:min(300px, 100%); }
  .g-title span{ font-size:16px; }
  .g-catch{ font-size:28px; }
  .g-lead{ font-size:16px; }
  .sns-chips{ display:grid; grid-template-columns:1fr; }
}

/* ---------- タイトル一覧（何十本になっても読める格子） ---------- */
.titles{ background:var(--games-soft); }
.titles .sec-head{ display:flex; flex-wrap:wrap; align-items:flex-end; justify-content:space-between; gap:12px 24px; max-width:none; margin-bottom:24px; }
.titles .count{ font-size:16px; font-weight:700; color:var(--sub); }
.filters{ display:flex; flex-wrap:wrap; gap:8px; margin-bottom:28px; }
.filters button{
  min-height:44px; padding:0 16px; border-radius:var(--radius); border:2px solid var(--ink); background:var(--paper);
  font:inherit; font-size:15px; font-weight:700; color:var(--ink); cursor:pointer;
}
.filters button small{ font-size:14px; font-weight:500; margin-left:6px; color:var(--sub); }
.filters button[aria-pressed="true"]{ background:var(--ink); color:#fff; }
.filters button[aria-pressed="true"] small{ color:#d5dde8; }
.filters .sort{ margin-left:auto; align-self:center; font-size:15px; color:var(--sub); font-weight:500; }
.gl{ display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; }
.gcard{
  display:grid; grid-template-columns:88px minmax(0,1fr); gap:14px; align-items:start;
  padding:14px; background:var(--paper); border-radius:var(--radius); border:1px solid #f0dcc6;
  text-decoration:none; color:var(--ink); transition:box-shadow .2s, transform .2s;
}
.gcard:hover{ box-shadow:0 8px 20px rgba(120,60,10,.14); transform:translateY(-2px); }
.gcard[hidden]{ display:none; }
.gcard > span{ min-width:0; }
.gcard img{ width:88px; height:88px; border-radius:20px; box-shadow:0 0 0 1px rgba(29,36,51,.1); }
.gc-name{ display:block; font-size:16px; font-weight:900; line-height:1.4; }
.gc-sub{ display:block; font-size:14px; color:var(--sub); line-height:1.4; }
.gc-catch{ display:block; font-size:14px; line-height:1.5; margin-top:4px; word-break:auto-phrase; }
.gc-tags{ display:flex; flex-wrap:wrap; gap:4px; margin-top:8px; }
.gc-tags span{ font-size:14px; font-weight:700; line-height:1; padding:5px 6px; border-radius:4px; border:1.5px solid currentColor; }
.gc-tags .g{ color:var(--g-ink); }
.gc-tags .d{ color:var(--sub); }
@media (max-width:1023px){ .gl{ grid-template-columns:repeat(3,minmax(0,1fr)); } .gcard{ grid-template-columns:72px minmax(0,1fr); } .gcard img{ width:72px; height:72px; border-radius:16px; } }
@media (max-width:599px){
  .gl{ grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
  .gcard{ grid-template-columns:minmax(0,1fr); gap:8px; padding:12px; }
  .gcard img{ width:64px; height:64px; border-radius:14px; }
  .gc-sub{ display:none; }
  .filters .sort{ margin-left:0; width:100%; }
}

/* ---------- 各タイトルのページ: 箱パネル ---------- */
.crumb{ background:var(--games-soft); border-bottom:1px solid #f0dcc6; }
.crumb ol{ display:flex; flex-wrap:wrap; align-items:center; gap:4px 10px; min-height:52px; font-size:15px; }
.crumb li + li::before{ content:"›"; margin-right:10px; color:var(--sub); }
.crumb a{ color:var(--g-ink); font-weight:700; display:inline-flex; align-items:center; min-height:44px; }
.g-panel{ background:var(--g-bg); padding:72px 0 96px; }
.gbox{
  display:grid; grid-template-columns:64px minmax(0,420px) minmax(0,1fr);
  border-radius:var(--radius); overflow:hidden; box-shadow:12px 12px 0 rgba(29,36,51,.22); background:var(--paper);
}
.gbox--okazu{ background:var(--games-soft); }
.gbox-spine{ display:flex; flex-direction:column; align-items:center; justify-content:space-between; padding:22px 0; color:#fff; background:var(--spine,#1a1a1a); }
.gbox-spine .v{ writing-mode:vertical-rl; font-size:20px; font-weight:700; letter-spacing:.24em; line-height:1; }
.gbox-spine .v-sub{ writing-mode:vertical-rl; font-size:14px; letter-spacing:.2em; font-weight:500; line-height:1; }
.gbox-info{ padding:40px 36px 40px 40px; display:flex; flex-direction:column; }
.gbox-title{ display:flex; align-items:center; gap:16px; margin-bottom:20px; }
.gbox-title img{ width:80px; height:80px; border-radius:18px; box-shadow:0 0 0 1px rgba(29,36,51,.12); flex:none; }
.gbox h1{ font-size:26px; font-weight:900; line-height:1.4; letter-spacing:.02em; }
.gbox h1 small{ display:block; font-size:15px; font-weight:500; color:var(--sub); letter-spacing:.06em; margin-top:2px; }
.gbox .catch{ font-size:21px; font-weight:700; line-height:1.55; margin-bottom:12px; }
.gbox--okazu .catch{ color:#7a4b24; }
.gbox .desc{ font-size:16px; }
.gbox h2{ font-size:16px; font-weight:700; margin:20px 0 6px; padding-left:12px; border-left:4px solid var(--spine); line-height:1.4; }
.gbox--okazu h2{ border-left-color:var(--games); }
.gbox .pts li{ position:relative; padding-left:16px; font-size:16px; line-height:1.7; }
.gbox .pts li + li{ margin-top:4px; }
.gbox .pts li::before{ content:""; position:absolute; left:2px; top:.72em; width:6px; height:6px; background:currentColor; }
.facts{ display:flex; flex-wrap:wrap; gap:8px; margin:24px 0 28px; }
.facts li{ font-size:14px; font-weight:700; line-height:1; padding:9px 11px; border:1.5px solid currentColor; border-radius:4px; color:var(--ink); }
.stores{ display:flex; flex-wrap:wrap; gap:12px; margin-top:auto; align-self:flex-start; }
.store{ display:inline-flex; min-height:44px; border-radius:8px; }
.store img{ height:52px; width:auto; }
/* 画面写真: 帯の幅にちょうど収まる枚数だけ並べ（見切れなし）、送りボタンは写真の直下。右の余白はカード左と同じ40px */
.gbox-shots{ position:relative; padding:40px 40px 40px 4px; min-width:0; display:flex; flex-direction:column; justify-content:center; }
.shots-track{
  display:flex; gap:20px; overflow-x:auto; scroll-snap-type:x mandatory;
  padding:10px 0 20px; scrollbar-width:none; overscroll-behavior-x:contain;
}
.shots-track::-webkit-scrollbar{ display:none; }
.phone{ background:#121212; border-radius:24px; padding:6px; }
.phone img{ width:100%; aspect-ratio:460/999; object-fit:cover; border-radius:18px; }
.shots-track .phone{ flex:0 0 calc((100% - 40px) / 3); scroll-snap-align:start; box-shadow:0 6px 14px rgba(29,36,51,.16); }
.shots-ctrl{ display:flex; gap:10px; justify-content:flex-end; align-items:center; margin-top:6px; }
.shots-ctrl .cnt{ font-size:15px; font-weight:700; color:var(--sub); margin-right:6px; }
.shots-ctrl button{
  width:48px; height:48px; border-radius:var(--radius); border:2px solid var(--ink); background:transparent;
  color:var(--ink); cursor:pointer; display:flex; align-items:center; justify-content:center;
}
.shots-ctrl button svg{ width:20px; height:20px; }
.shots-ctrl button:hover:not(:disabled){ background:var(--ink); color:#fff; }
.shots-ctrl button:disabled{ opacity:.35; cursor:default; }
@media (max-width:1023px){
  .g-panel{ padding:48px 0 72px; }
  .gbox{ grid-template-columns:56px minmax(0,1fr); }
  .gbox-info{ padding:36px 32px 8px; }
  .gbox-shots{ grid-column:2; padding:16px 32px 32px; }
  .gbox-spine{ grid-row:1 / span 2; }
  .stores{ margin-top:0; }
}
@media (max-width:599px){
  .g-panel{ padding:32px 0 56px; }
  .gbox{ grid-template-columns:minmax(0,1fr); box-shadow:8px 8px 0 rgba(29,36,51,.22); }
  .gbox-spine{ grid-row:auto; padding:0; height:12px; }
  .gbox-spine .v, .gbox-spine .v-sub{ display:none; }
  .gbox-info{ padding:24px 20px 4px; }
  .gbox-shots{ grid-column:1; padding:8px 20px 24px; }
  .gbox-title img{ width:64px; height:64px; }
  .gbox h1{ font-size:22px; }
  .gbox .catch{ font-size:19px; }
  .shots-track{ gap:14px; }
  .shots-track .phone{ flex-basis:calc((100% - 14px) / 2); border-radius:20px; padding:5px; }
  .shots-track .phone img{ border-radius:15px; }
}
.more-titles .foot{ margin-top:32px; }
@media (max-width:599px){ .more-titles .foot .btn{ width:100%; } }

/* ---------- 動画とSNS ---------- */
.videos{ background:var(--paper); }
.vid-list{ display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:24px; }
.vid{ text-decoration:none; color:var(--ink); display:flex; flex-direction:column; gap:14px; }
.vid .phone{ position:relative; border-radius:22px; box-shadow:0 10px 22px rgba(60,20,0,.18); transition:transform .25s; }
.vid .phone img{ aspect-ratio:9/16; border-radius:16px; }
.vid:hover .phone{ transform:translateY(-6px); }
.vid .play{
  position:absolute; left:50%; top:50%; width:52px; height:52px; transform:translate(-50%,-50%);
  background:rgba(29,36,51,.72); border-radius:50%; display:flex; align-items:center; justify-content:center;
}
.vid .play svg{ width:22px; height:22px; color:#fff; margin-left:3px; }
.vid .vt{ font-size:16px; font-weight:700; line-height:1.55; }
.vid .vs{ display:block; font-size:14px; font-weight:500; color:var(--sub); margin-bottom:2px; }
.vid:hover .vt{ text-decoration:underline; }
.acct-head{ margin-top:96px; font-size:28px; font-weight:900; line-height:1.45; }
@media (max-width:1023px){
  .vid-list{ display:flex; overflow-x:auto; scroll-snap-type:x mandatory; gap:20px; margin:0 calc(var(--gutter) * -1); padding:6px var(--gutter) 20px; scroll-padding-left:var(--gutter); }
  .vid{ flex:0 0 200px; scroll-snap-align:start; }
  .acct-head{ margin-top:72px; }
}
@media (max-width:599px){
  .vid{ flex-basis:160px; }
  .vid .phone{ border-radius:18px; padding:5px; }
  .vid .phone img{ border-radius:13px; }
  .vid .vt{ font-size:15px; }
  .acct-head{ font-size:23px; margin-top:56px; }
}

/* ---------- aliba games について／お問い合わせ ---------- */
.about{ background:var(--mist); }
.about .grid{ display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:56px; align-items:start; }
.about p{ font-size:17px; }
.about p + p{ margin-top:16px; }
.about .lnk{
  display:inline-flex; align-items:center; gap:8px; min-height:44px; margin-top:24px;
  font-weight:700; color:var(--corp); text-decoration:none; border-bottom:2px solid var(--corp);
}
.about .lnk svg{ width:16px; height:16px; }
.about .lnk:hover{ color:var(--ink); border-color:var(--ink); }
.contact-box{ background:var(--paper); border-radius:var(--radius); padding:40px; border-left:6px solid var(--corp); }
.contact-box h2{ font-size:26px !important; font-weight:900; line-height:1.45; margin-bottom:14px; }
.contact-box p{ margin-bottom:28px; font-size:16px !important; }
.contact-box .sub-link{ display:inline-flex; align-items:center; min-height:44px; margin-top:16px; font-size:16px; color:var(--corp); text-decoration:underline; }
.contact-box .row{ display:flex; flex-direction:column; align-items:flex-start; }
@media (max-width:1023px){ .about .grid{ grid-template-columns:1fr; gap:48px; } }
@media (max-width:599px){
  .about p{ font-size:16px; }
  .contact-box{ padding:28px 22px; }
  .contact-box h2{ font-size:22px !important; }
  .contact-box .btn{ width:100%; }
}
@media (prefers-reduced-motion:reduce){
  html{ scroll-behavior:auto; }
  .vid .phone, .acct-big, .gcard{ transition:none !important; }
}
