:root{--ink:#183a46;--aqua:#2fb7bd;--deep:#087783;--gold:#e5aa37;--paper:#f7fbf8;--white:#fff;--shadow:0 18px 45px rgba(8,69,75,.18)}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:"Yu Gothic",Meiryo,sans-serif;color:var(--ink);background:radial-gradient(circle at 15% 10%,#d8f4ef,transparent 38%),linear-gradient(145deg,#f7fbf8,#e5f3ed)}
body{display:grid;place-items:center;padding:16px}.game{width:min(100%,880px);min-height:min(780px,calc(100vh - 32px));background:rgba(255,255,255,.88);border:1px solid rgba(47,183,189,.25);border-radius:28px;box-shadow:var(--shadow);overflow:hidden;position:relative}
.start,.found,.complete{min-height:min(780px,calc(100vh - 32px));display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:40px 24px;background:linear-gradient(rgba(255,255,255,.72),rgba(255,255,255,.96)),repeating-linear-gradient(135deg,transparent 0 18px,rgba(47,183,189,.055) 18px 20px)}
[hidden]{display:none!important}.eyebrow{font-size:12px;font-weight:800;letter-spacing:.16em;color:var(--deep)}h1,h2,p{margin-top:0}h1{font-size:clamp(34px,7vw,68px);line-height:1.15;margin:12px 0 22px}h1 em{font-style:normal;color:var(--deep)}.start>p:not(.eyebrow){font-size:18px;line-height:1.9}.start__mark{font-size:84px;color:var(--gold);filter:drop-shadow(0 9px 12px rgba(181,121,10,.25));animation:float 2.4s ease-in-out infinite}
button,a{font:inherit}.primary{display:inline-flex;align-items:center;justify-content:center;min-width:230px;border:0;border-radius:999px;padding:16px 28px;background:linear-gradient(135deg,var(--aqua),var(--deep));color:#fff;font-weight:800;text-decoration:none;box-shadow:0 10px 22px rgba(8,119,131,.26);cursor:pointer}.primary:hover{transform:translateY(-2px)}
.play{padding:18px}.topbar{display:flex;align-items:center;gap:18px;margin-bottom:12px}.topbar>div:first-child{font-size:28px;font-weight:900}.topbar small{font-size:14px}.gem-tray{margin-left:auto;display:flex;gap:6px}.gem-dot{width:19px;height:19px;transform:rotate(45deg);border:2px solid #8db2b1;border-radius:4px;background:#fff}.gem-dot.collected{border-color:var(--gem);background:var(--gem);box-shadow:0 0 12px color-mix(in srgb,var(--gem) 60%,transparent)}
.room-title p{margin:0;color:var(--deep);font-size:12px;font-weight:800;letter-spacing:.12em}.room-title h2{margin:3px 0 12px;font-size:clamp(23px,4vw,36px)}.photo-stage{position:relative;overflow:hidden;border-radius:20px;background:#d9e3df;aspect-ratio:4/3;box-shadow:inset 0 0 0 1px rgba(0,0,0,.08)}.photo-stage img{width:100%;height:100%;display:block;object-fit:cover}.jewel{position:absolute;left:var(--x);top:var(--y);width:25px;height:25px;transform:translate(-50%,-50%) rotate(45deg);border:0;border-radius:5px;background:linear-gradient(135deg,#fff 0 8%,var(--gem) 20% 68%,#fff8 70%,var(--gem) 82%);box-shadow:0 0 0 1px #fff8,0 4px 8px #0005;cursor:pointer;transition:.2s}.jewel:hover{scale:1.08}.jewel::after{content:"";position:absolute;inset:5px;border:1px solid #fff9;border-radius:2px}.hint-ring{position:absolute;left:var(--x);top:var(--y);width:132px;height:132px;border:5px solid #fff;border-radius:50%;transform:translate(-50%,-50%);box-shadow:0 0 0 5px #e5aa37;opacity:0;pointer-events:none}.hint-ring.show{animation:pulse 1s infinite;opacity:1}.controls{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:15px 4px 2px}.controls p{margin:0;font-size:14px}.secondary,.text-button{border:0;background:none;color:var(--deep);font-weight:800;text-decoration:underline;cursor:pointer;white-space:nowrap}
.found__gem{font-size:110px;color:var(--gem);filter:drop-shadow(0 12px 18px #0003);animation:pop .5s ease-out}.found h2{font-size:clamp(34px,7vw,60px);margin:8px 0}.found>p:not(.eyebrow){font-size:20px;line-height:1.8;max-width:560px}.complete__crown{font-size:36px;line-height:1.1;color:var(--gold);letter-spacing:.2em}.complete h2{font-size:clamp(34px,7vw,60px);margin:12px}.complete p{line-height:1.8}.complete__lead{font-size:21px;font-weight:800}.complete .text-button{margin-top:24px}
@keyframes float{50%{transform:translateY(-10px)}}@keyframes pulse{50%{scale:1.18;opacity:.55}}@keyframes pop{0%{transform:scale(.2) rotate(-30deg)}70%{transform:scale(1.16) rotate(5deg)}}
@media(max-width:600px){body{padding:0}.game{min-height:100vh;border-radius:0}.start,.found,.complete{min-height:100vh}.play{padding:12px}.photo-stage{aspect-ratio:3/4}.controls{align-items:flex-start}.controls p{max-width:60%}.gem-dot{width:14px;height:14px}.jewel{width:29px;height:29px}.hint-ring{width:120px;height:120px}}

/* 宝石の見た目は小さく、クリック範囲は操作しやすい大きさを維持 */
.jewel{width:40px;height:40px;background:transparent;box-shadow:none;border-radius:50%}
.jewel::before{content:"";position:absolute;left:50%;top:50%;width:7px;height:7px;transform:translate(-50%,-50%);border-radius:2px;background:linear-gradient(135deg,#fff 0 8%,var(--gem) 20% 68%,#fff8 70%,var(--gem) 82%);box-shadow:0 0 0 1px #fff9,0 2px 4px #0006}
.jewel::after{content:none}
.hint-ring{width:220px;height:220px;border-width:5px;box-shadow:0 0 0 6px #e5aa37}
@media(max-width:600px){.jewel{width:44px;height:44px}.hint-ring{width:190px;height:190px}}
.irukachan-guide{display:block;width:clamp(78px,15vw,128px);height:auto;object-fit:contain;filter:drop-shadow(0 8px 12px rgba(11,53,63,.2))}.irukachan-guide--start,.irukachan-guide--found,.irukachan-guide--complete{margin:0 auto 8px}.irukachan-guide--play{position:absolute;z-index:5;right:10px;bottom:72px;width:clamp(66px,12vw,105px);pointer-events:none}.found .irukachan-guide{animation:irukachan-celebrate .55s ease-out both}@keyframes irukachan-celebrate{0%{transform:translateY(16px) scale(.85);opacity:0}65%{transform:translateY(-5px) scale(1.05);opacity:1}100%{transform:translateY(0) scale(1);opacity:1}}
