/* 家族ガチャ の 色と、このゲームだけの 画面 */
:root {
  --bg: #fff6f0; --bg2: #3a1a2a; --panel: #ffffff; --ink: #3a2a2a; --dim: #8a7272; --btn: #f6e6e0;
  --pri1: #ff7a5a; --pri2: #e8384f; --accent: #d8406a; --bar: #4a2a3a; --logo-stroke: #a8204a;
  --title-bg: linear-gradient(180deg, #ffd0a0 0%, #ffb0c0 50%, #b0d8ff 100%);
  --banner-bg: radial-gradient(circle at 70% 40%, #fff0a0, #ff7a8a 50%, #7a2a5a);
}
#title::before { content: ""; position: absolute; inset: 0; background: url(img/bg/living.webp) center/cover; opacity: .7; }
.gold { color: #c88a00; font-weight: 800; }
.card.kid .cimg { inset: -14% -48% -40%; }
.card.pet .cimg { inset: -10% -14% -10%; background-position: 50% 50%; background-size: cover; }

/* ガチャの 入れもの：ポチ袋 */
.gobj.o-pochi { width: 130px; height: 190px; }
.gobj.o-pochi .body { border-radius: 8px; writing-mode: vertical-rl; font-size: 44px; letter-spacing: 0; color: rgba(120,0,0,.6); }
.gobj.o-pochi .body::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 32%; clip-path: polygon(0 0, 100% 0, 50% 100%); background: inherit; filter: brightness(1.2); }

/* おうち */
.house { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #e8c8a0; }
.stage { position: absolute; left: 0; right: 0; bottom: 0; aspect-ratio: 1; z-index: 1; }
.house .side, .house .housename, .house .saybox { z-index: 10; }
.stage .bgimg { position: absolute; inset: 0; width: 100%; height: 100%; }
.stage .fm { filter: drop-shadow(0 4px 3px rgba(0,0,0,.3)); cursor: pointer; transform-origin: 50% 90%; }
.fm.boing { animation: hop .5s; }
@keyframes hop { 40% { transform: translateY(-14px); } }
.saybox { position: absolute; left: 8px; right: 70px; top: 60px; background: #fff; border-radius: 14px; padding: 8px 12px; font-size: .82em; font-weight: 700; box-shadow: 0 3px 8px rgba(0,0,0,.2); z-index: 6; opacity: 0; transform: scale(.7); transition: .2s; pointer-events: none; }
.saybox.show { opacity: 1; transform: none; }
.housename { position: absolute; left: 8px; top: 8px; z-index: 5; background: #fdf3dc; border: 3px solid #6a4a2a; border-radius: 6px; padding: 2px 12px; display: flex; flex-direction: column; align-items: center; line-height: 1.1; cursor: pointer; box-shadow: 0 2px 4px rgba(0,0,0,.25); }
.housename small { font-size: var(--fs-xs); color: var(--dim); } .housename b { font-size: 1.15em; font-family: serif; }
.hhud { padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.fampow { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.fampow b { font-size: 1.5em; color: var(--pri2); }
.setb { background: linear-gradient(90deg, #ffcc33, #ff8a5a); color: #fff; font-weight: 800; padding: 2px 10px; border-radius: 99px; font-size: .8em; }
.setb.full { background: linear-gradient(90deg, #ff5f8f, #ffd23f, #4be38a, #4ab2ff, #b46bff); animation: pop 1.4s infinite; }
.bigbtn { border: 0; border-radius: 16px; padding: 10px 14px; color: #fff; display: grid; grid-template-columns: 1fr auto; text-align: left; box-shadow: 0 4px 0 rgba(0,0,0,.25); }
.bigbtn small { grid-column: 1 / 3; opacity: .9; font-size: .75em; }
.bigbtn b { font-size: 1.25em; } .bigbtn span { align-self: center; display: flex; align-items: center; gap: 2px; font-weight: 800; }
.bigbtn .ico { width: 18px; height: 18px; }
.bigbtn.go { background: linear-gradient(135deg, #ff9a5a, #e8384f); }
.bigbtn.go.special { background: linear-gradient(135deg, #ffcc33, #ff5f8f, #8a5ad8); animation: glow 1.6s infinite; }
.preview { display: flex; justify-content: space-around; background: var(--panel); border-radius: 12px; padding: 6px; }
.preview span { display: flex; flex-direction: column; align-items: center; font-size: 22px; }
.preview small { font-size: var(--fs-xs); color: var(--dim); }

/* 家族（編成） */
.teamhead { display: flex; justify-content: space-between; align-items: center; padding: 10px 10px 0; }
.slots6 { display: grid; grid-template-columns: repeat(6, 1fr); gap: 5px; padding: 8px; }
.slot { position: relative; }
.slot .rl { position: absolute; top: -6px; left: 50%; transform: translateX(-50%); z-index: 3; color: #fff; font-size: var(--fs-xs); font-weight: 900; padding: 0 6px; border-radius: 6px; }
.slot .empty { aspect-ratio: 3 / 4; border-radius: 10px; border: 2px dashed #c8a8a8; display: grid; place-items: center; font-size: 22px; color: #c8a8a8; cursor: pointer; }
.setinfo { text-align: center; font-size: .82em; margin: 0 8px; color: var(--accent); font-weight: 700; }
.lvrow { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; align-items: center; }
.lvrow .ico { width: 16px; height: 16px; vertical-align: middle; }

/* ある一日 */
#day { position: fixed; inset: 0; z-index: 60; max-width: 520px; margin: 0 auto; background: linear-gradient(180deg, #fff1e6, #ffd8d8); display: flex; flex-direction: column; padding: max(10px, env(safe-area-inset-top)) 10px max(10px, env(safe-area-inset-bottom)); }
.dtop { display: flex; justify-content: space-between; font-weight: 800; padding: 4px 4px 8px; }
.evcard { background: #fff; border-radius: 20px; padding: 14px; text-align: center; box-shadow: 0 6px 16px rgba(160,60,80,.2); animation: zoom .25s; }
.evicon { font-size: 54px; line-height: 1; } .evcard h2 { margin: 6px 0; } .evcard p { margin: 3px 0; }
.dhint { text-align: center; font-weight: 700; margin: 10px 0 6px; }
.dpick { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; align-content: start; }
.dm { position: relative; background: #fff; border-radius: 14px; padding: 4px 4px 6px; display: flex; flex-direction: column; align-items: center; cursor: pointer; box-shadow: 0 2px 6px rgba(0,0,0,.12); overflow: hidden; }
.dm img { height: 110px; width: 100%; object-fit: cover; object-position: 50% 10%; }
.dm b { font-size: .8em; }
.dm .pct { font-size: 1.1em; font-weight: 900; color: #c88a00; } .dm .pct.hi { color: #17a85a; } .dm .pct.lo { color: #e0334a; }
.dm em { position: absolute; top: 4px; right: 4px; font-style: normal; background: #ff5f8f; color: #fff; font-size: var(--fs-xs); font-weight: 900; padding: 1px 5px; border-radius: 6px; }
.dm.off { opacity: .4; filter: grayscale(1); cursor: default; }
.dres { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; animation: zoom .25s; }
.dres img { height: 46vh; filter: drop-shadow(0 6px 8px rgba(0,0,0,.3)); }
.dres.ok img { animation: hop .6s 2; } .dres.ng img { filter: grayscale(.5) drop-shadow(0 6px 8px rgba(0,0,0,.3)); transform: rotate(-6deg); }
.dresult { font-size: 42px; font-weight: 900; font-style: italic; }
.dres.ok .dresult { color: #ff5f8f; } .dres.ng .dresult { color: #6a7aa8; }
.dlog > div { display: flex; justify-content: space-between; padding: 4px 6px; border-bottom: 1px solid rgba(0,0,0,.07); font-size: .9em; }
.dlog .ok span { color: #17a85a; font-weight: 800; } .dlog .ng span { color: #e0334a; }
