@import url("https://fonts.googleapis.com/css2?family=Zen+Maru+Gothic:wght@400;500;700&family=M+PLUS+Rounded+1c:wght@400;500;700&family=Yomogi&display=swap"); :root { --bg: #f7f5ec; --panel: rgba(255,251,245,0.88); --ink: #2a241d; --muted: #756a5e; --line: rgba(84, 68, 48, 0.18); --accent: #9ce84b; --accent-2: #f5a8b7; --danger: #b64545; --shadow: 0 18px 50px rgba(64, 48, 32, 0.14); --radius: 18px; --bubble-font: "Yomogi", "Zen Maru Gothic", "M PLUS Rounded 1c", ui-rounded, sans-serif; } * { box-sizing: border-box; } body { margin: 0; font-family: "Zen Maru Gothic", "M PLUS Rounded 1c", ui-rounded, "Hiragino Maru Gothic ProN", "Yu Gothic", "Meiryo", system-ui, sans-serif; background: radial-gradient(circle at 12% 0%, rgba(168, 228, 113, 0.28), transparent 33%), radial-gradient(circle at 88% 8%, rgba(255, 222, 147, 0.24), transparent 28%), radial-gradient(circle at 82% 90%, rgba(126, 181, 120, 0.16), transparent 34%), linear-gradient(180deg, #dff0ff 0%, #edf8ff 12%, #f9f6eb 46%, var(--bg) 100%); color: var(--ink); min-height: 100vh; overflow-x: hidden; position: relative; } button { font: inherit; color: inherit; } #app { width: min(1480px, 100vw); margin: 0 auto; padding: 18px; position: relative; } .topbar { display: flex; justify-content: space-between; gap: 18px; align-items: center; margin-bottom: 16px; } h1 { margin: 0 0 3px; font-size: clamp(24px, 3.4vw, 42px); letter-spacing: 0.03em; } .subtitle { margin: 0; color: var(--muted); font-size: 14px; } .top-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; } .btn, .tool { border: 1px solid var(--line); background: rgba(255,255,255,0.76); border-radius: 999px; padding: 9px 13px; cursor: pointer; box-shadow: 0 4px 14px rgba(80,60,40,0.06); transition: transform 130ms ease, background 130ms ease, border-color 130ms ease; user-select: none; } .btn:hover, .tool:hover { transform: translateY(-1px); background: #fff; } .btn:active, .tool:active { transform: translateY(1px); } .btn.primary { background: linear-gradient(180deg, #a9ef5d, #8bdc3f); border-color: rgba(89, 128, 47, 0.28); } .btn.danger { color: #7a2828; } .layout { display: grid; grid-template-columns: minmax(520px, 1fr) 380px; gap: 16px; align-items: stretch; } .stage-wrap { position: relative; background: linear-gradient(180deg, rgba(255,255,255,0.46), rgba(246, 240, 228, 0.56)); border: 1px solid rgba(84, 68, 48, 0.12); border-radius: calc(var(--radius) + 8px); overflow: hidden; box-shadow: 0 16px 42px rgba(42, 45, 80, 0.12), inset 0 0 0 1px rgba(255,255,255,0.24); min-height: var(--field-min-height, 620px); } #gameCanvas { width: 100%; height: var(--field-height, calc(100vh - 140px)); min-height: var(--field-min-height, 620px); display: block; cursor: crosshair; } .field-dialog { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 18px; background: rgba(34, 29, 22, 0.38); backdrop-filter: blur(3px); } .field-dialog.hidden { display: none; } .field-dialog-panel { width: min(440px, 100%); border-radius: 16px; padding: 16px; background: rgba(255, 252, 245, 0.96); border: 1px solid rgba(84,68,48,0.16); box-shadow: 0 18px 46px rgba(40, 32, 24, 0.22); } .field-dialog-panel h2 { margin: 0 0 12px; font-size: 17px; } .field-choice-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; } .field-choice { min-height: 74px; border: 1px solid rgba(84,68,48,0.16); border-radius: 12px; background: linear-gradient(180deg, rgba(255,255,255,0.86), rgba(241,235,221,0.72)); cursor: pointer; color: var(--ink); } .field-choice:hover { border-color: rgba(112,178,66,0.45); } .field-choice strong, .field-choice span { display: block; } .field-choice strong { font-size: 15px; } .field-choice span { margin-top: 4px; color: var(--muted); font-size: 12px; } .field-dialog-actions { margin-top: 12px; display: flex; justify-content: flex-end; } .toast { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); background: rgba(42,36,29,0.86); color: white; padding: 10px 16px; border-radius: 999px; font-size: 14px; pointer-events: none; opacity: 1; transition: opacity 200ms ease, transform 200ms ease; } .toast.hidden { opacity: 0; transform: translateX(-50%) translateY(8px); } .panel { display: flex; flex-direction: column; gap: 12px; height: calc(100vh - 120px); max-height: calc(100vh - 120px); overflow-y: auto; overflow-x: hidden; padding-right: 3px; } .card { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: 0 10px 30px rgba(64, 48, 32, 0.08); backdrop-filter: blur(10px); position: relative; } .card h2 { margin: 0 0 12px; font-size: 17px; letter-spacing: 0.03em; } .tool-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; } .tool { border-radius: 14px; display: flex; align-items: center; gap: 7px; justify-content: flex-start; padding: 8px 8px 8px 42px; min-height: 46px; position: relative; overflow: hidden; background-repeat: no-repeat; background-position: 7px center, center; background-size: 30px 30px, cover; } .tool::before { content: ""; position: absolute; left: 7px; top: 50%; width: 30px; height: 30px; transform: translateY(-50%); background: var(--tool-icon) center / contain no-repeat; opacity: 0.92; filter: drop-shadow(0 2px 3px rgba(52,40,26,0.12)); } .tool::after { content: ""; position: absolute; inset: 0; background: var(--tool-icon) right -8px center / 54px 54px no-repeat; opacity: 0.10; pointer-events: none; } .tool span { min-width: 16px; text-align: center; color: rgba(72,58,43,0.64); font-size: 10px; } .tool[data-tool="observe"] { --tool-icon: url("../assets/ui/tool_observe.png"); } .tool[data-tool="zunchi"] { --tool-icon: url("../assets/ui/tool_zunchi.png"); } .tool[data-tool="sweet"] { --tool-icon: url("../assets/ui/tool_sweet.png"); } .tool[data-tool="water"] { --tool-icon: url("../assets/ui/tool_water.png"); } .tool[data-tool="grass"] { --tool-icon: url("../assets/ui/tool_grass.png"); } .tool[data-tool="stone"] { --tool-icon: url("../assets/ui/tool_stone.png"); } .tool[data-tool="firecracker"] { --tool-icon: url("../assets/ui/tool_firecracker.png"); } .tool[data-tool="fence_v"] { --tool-icon: url("../assets/ui/tool_fence_v.png"); } .tool[data-tool="fence_h"] { --tool-icon: url("../assets/ui/tool_fence_h.png"); } .tool[data-tool="bed"] { --tool-icon: url("../assets/ui/tool_bed.png"); } .tool[data-tool="poke"] { --tool-icon: url("../assets/ui/tool_poke.png"); } .tool[data-tool="delete"] { --tool-icon: url("../assets/ui/tool_delete.png"); } .tool[data-tool="new"] { --tool-icon: url("../assets/ui/tool_new.png"); } .tool.selected { background: linear-gradient(180deg, #ffffff, #efffde); border-color: rgba(103, 178, 44, 0.52); box-shadow: inset 0 0 0 1px rgba(156,232,75,0.38), 0 8px 20px rgba(117, 166, 64, 0.13); } .hint { color: var(--muted); font-size: 12px; line-height: 1.55; margin: 10px 0 0; } .tool-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; } .tool-head h2 { margin-bottom: 0; } .btn.mini { padding: 6px 10px; font-size: 12px; } .tool-body { margin-top: 12px; } .tool-palette { display: flex; flex-direction: column; gap: 9px; } .tool-category { border: 1px solid rgba(84,68,48,0.10); border-radius: 14px; background: rgba(255,255,255,0.34); overflow: hidden; } .tool-category-toggle { width: 100%; border: 0; border-bottom: 1px solid rgba(84,68,48,0.08); background: rgba(255,252,244,0.66); padding: 8px 10px; text-align: left; cursor: pointer; font-weight: 700; font-size: 12px; } .tool-category-toggle::before { content: "▾"; display: inline-block; width: 16px; color: var(--muted); } .tool-category.collapsed .tool-category-toggle::before { content: "▸"; } .tool-category-body { padding: 8px; } .tool-category.collapsed .tool-category-body { display: none; } .tool-size-badge { position: absolute; right: 7px; bottom: 6px; min-width: 20px; padding: 2px 5px; border-radius: 999px; background: rgba(42,36,29,0.68); color: #fff; font-size: 10px; line-height: 1; text-align: center; box-shadow: 0 1px 4px rgba(42,36,29,0.16); pointer-events: none; } .chart-tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; margin: 3px 0 8px; } .chart-tabs button { border: 1px solid var(--line); background: rgba(255,255,255,0.62); border-radius: 999px; padding: 5px 4px; font-size: 11px; cursor: pointer; } .chart-tabs button.active { background: #efffde; border-color: rgba(103,178,44,0.46); font-weight: 700; } .log-accident { border-left-color: rgba(226, 136, 54, 0.76); } .stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; } .stat { background: linear-gradient(180deg, rgba(255,255,255,0.58), rgba(246, 240, 228, 0.72)); border: 1px solid var(--line); border-radius: 13px; padding: 9px 8px; text-align: center; } .stat span { display: block; font-size: 11px; color: var(--muted); } .stat strong { font-size: 18px; } .meter-row { display: grid; grid-template-columns: 72px 1fr; align-items: center; gap: 8px; font-size: 12px; margin: 6px 0; } meter { width: 100%; height: 12px; accent-color: var(--accent); } .selected-info { font-size: 13px; line-height: 1.55; } .selected-info.empty { color: var(--muted); } .badge { display: inline-block; font-size: 11px; line-height: 1; border-radius: 999px; padding: 5px 8px; background: #f1f8e9; border: 1px solid rgba(103, 178, 44, 0.28); margin: 0 4px 4px 0; } .info-row { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px dashed rgba(84,68,48,0.16); padding: 5px 0; } .info-row span:first-child { color: var(--muted); } .log-card { min-height: 260px; flex: 0 0 auto; display: flex; flex-direction: column; } .log { max-height: 360px; min-height: 170px; flex: 1 1 auto; overflow: auto; display: flex; flex-direction: column; gap: 7px; font-size: 12px; } .log-entry { padding: 8px 9px; border-radius: 12px; background: rgba(255,252,246,0.82); border: 1px solid rgba(84,68,48,0.12); border-left: 4px solid rgba(118, 101, 74, 0.24); } .log-tag { display: inline-block; min-width: 34px; margin-right: 6px; padding: 2px 5px; border-radius: 999px; font-size: 9px; line-height: 1.1; text-align: center; background: rgba(84,68,48,0.08); color: rgba(72,58,43,0.72); text-transform: uppercase; } .log-entry .time { color: var(--muted); margin-right: 6px; } .log-birth { border-left-color: rgba(115, 185, 75, 0.66); } .log-death { border-left-color: rgba(91, 83, 75, 0.60); } .log-fight { border-left-color: rgba(214, 94, 70, 0.68); } .log-food { border-left-color: rgba(118, 185, 77, 0.68); } .log-grass { border-left-color: rgba(72, 148, 67, 0.68); } .log-weather { border-left-color: rgba(92, 142, 210, 0.62); } .log-relation { border-left-color: rgba(204, 126, 176, 0.62); } .log-observe { border-left-color: rgba(175, 146, 86, 0.62); } @media (max-width: 980px) { #app { padding: 10px; } .topbar { align-items: flex-start; flex-direction: column; } .layout { grid-template-columns: 1fr; } .panel { max-height: none; overflow: visible; } #gameCanvas { height: var(--field-mobile-height, 66vh); min-height: var(--field-mobile-min-height, 460px); } .stage-wrap { min-height: var(--field-mobile-min-height, 460px); } .field-choice-grid { grid-template-columns: 1fr; } } .tree-note { color: var(--muted); font-size: 12px; line-height: 1.45; margin: 0 0 10px; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,0.54); border: 1px solid rgba(84,68,48,0.10); } .lineage-tree { overflow: auto; padding: 8px 10px 18px; contain: content; } .lineage-main-card { margin-top: 16px; min-height: 0; } .lineage-main-card h2 { margin-bottom: 6px; } .lineage-main-content { max-height: 560px; min-height: 320px; overflow: auto; overscroll-behavior: auto; padding: 8px 4px 16px; background: rgba(255,250,244,0.48); border-radius: 14px; border: 1px solid rgba(84,68,48,0.10); } .lineage-main-content .lineage-tree { min-width: 360px; overflow: visible; padding-right: 2px; } body::before { content: ""; position: fixed; inset: 0; pointer-events: none; background: radial-gradient(circle at 8% 20%, rgba(255,255,255,0.62), transparent 16%), radial-gradient(circle at 92% 18%, rgba(255,255,255,0.45), transparent 18%), linear-gradient(180deg, transparent 0%, rgba(114, 152, 78, 0.05) 100%); } .stage-wrap::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(circle at 18% 14%, rgba(255,255,255,0.12), transparent 18%), radial-gradient(circle at 84% 10%, rgba(255,255,255,0.09), transparent 16%), linear-gradient(180deg, rgba(255,255,255,0.07), transparent 24%); z-index: 1; } #gameCanvas { position: relative; z-index: 0; } .card::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; box-shadow: inset 0 1px 0 rgba(255,255,255,0.55); } /* Compact family board: parent ┳ parent / child, without unrelated founders. */ .family-board { padding: 0; overflow: visible; } .family-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(246px, 1fr)); gap: 10px 12px; align-items: start; padding: 2px 2px 10px; } .family-cluster { position: relative; min-height: 106px; padding: 7px 7px 8px; border-radius: 14px; background: rgba(255,253,248,0.56); border: 1px solid rgba(84,68,48,0.09); contain: layout paint; } .family-parents { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; align-items: center; } .family-child-slot { display: flex; justify-content: center; margin-top: 14px; } .family-node { display: grid; grid-template-columns: 22px minmax(0, 1fr); align-items: center; gap: 5px; min-width: 0; min-height: 34px; padding: 4px 6px; border-radius: 10px; background: linear-gradient(180deg, rgba(255,253,248,0.96), rgba(248,241,229,0.90)); border: 1px solid rgba(84,68,48,0.14); box-shadow: 0 3px 8px rgba(64,48,32,0.045); } .family-child-slot .family-node { width: min(150px, 68%); } .family-connector { position: relative; height: 12px; margin: 0 42px; } .family-connector::before { content: ""; position: absolute; left: 0; right: 0; top: 7px; height: 2px; background: rgba(107, 88, 61, 0.55); } .family-connector span { position: absolute; left: calc(50% - 1px); top: 7px; width: 2px; height: 16px; background: rgba(107, 88, 61, 0.55); } .family-node.child { border-color: rgba(103, 178, 44, 0.38); box-shadow: inset 0 0 0 1px rgba(156,232,75,0.17), 0 3px 8px rgba(64,48,32,0.045); } .family-node[data-family-tarinai-id] { cursor: pointer; transition: transform .12s ease, border-color .12s ease, box-shadow .12s ease; } .family-node[data-family-tarinai-id]:hover { transform: translateY(-1px); border-color: rgba(112,178,66,0.42); box-shadow: 0 5px 12px rgba(64,48,32,0.08); } .family-node.dead { opacity: 0.68; filter: grayscale(0.35); } .family-node.missing { opacity: 0.48; border-style: dashed; } .family-node img { width: 22px; height: 22px; object-fit: contain; } .family-copy { min-width: 0; line-height: 1.12; } .family-copy strong, .family-copy span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .family-copy .death-reason { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.12; margin-top: 1px; color: rgba(126, 80, 64, 0.92); } .family-copy strong { font-size: 11px; } .family-copy span { color: var(--muted); font-size: 8.5px; margin-top: 1px; } @media (max-width: 760px) { .family-grid { grid-template-columns: 1fr; } .family-cluster { min-height: 102px; } } .colony-card { overflow: visible; min-height: 0; flex: 0 0 auto; } .colony-stats { grid-template-columns: repeat(2, 1fr); margin-bottom: 8px; } .colony-chart { display: block; width: 100%; height: 188px; min-height: 188px; border: 1px solid rgba(84, 68, 48, 0.14); border-radius: 14px; background: linear-gradient(180deg, rgba(255,255,255,0.70), rgba(246,240,228,0.54)); overflow: hidden; } .colony-card h2 { line-height: 1.45; margin-bottom: 10px; } .colony-chart svg { display: block; width: 100%; height: 100%; } .colony-chart-legend { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; margin: 4px 0 8px; font-size: 11px; color: var(--muted); line-height: 1.25; } .colony-chart-legend span { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; } .colony-chart-legend i { width: 8px; height: 8px; border-radius: 999px; display: inline-block; box-shadow: 0 0 0 1px rgba(70, 52, 36, 0.10); } .relation-row strong { display: inline-flex; align-items: center; justify-content: flex-end; gap: 6px; } .relation-face { width: 24px; height: 24px; object-fit: contain; border-radius: 999px; background: rgba(255,255,255,0.66); border: 1px solid rgba(84,68,48,0.12); vertical-align: middle; flex: 0 0 auto; } .lineage-family { padding: 10px; margin: 0 0 12px; border-radius: 15px; background: rgba(255,253,248,0.62); border: 1px solid rgba(84,68,48,0.12); } .lineage-family h3 { margin: 0 0 8px; font-size: 13px; color: rgba(64,52,38,0.86); } .lineage-generation { display: grid; grid-template-columns: 62px 1fr; gap: 8px; align-items: start; padding: 8px 0; border-top: 1px dashed rgba(84,68,48,0.13); } .lineage-generation:first-of-type { border-top: 0; } .lineage-generation-label { position: sticky; left: 0; font-size: 11px; color: var(--muted); padding-top: 8px; } .lineage-generation-nodes { display: flex; flex-wrap: wrap; gap: 8px; align-items: stretch; } .family-node.lineage-node { width: 132px; min-height: 54px; align-items: flex-start; } .lineage-children { display: block; margin-top: 3px; font-size: 9px; color: rgba(117,106,94,0.84); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .lineage-empty-family { color: var(--muted); font-size: 12px; padding: 10px; } .lineage-tree-panel { position: relative; overflow: visible; min-width: 360px; margin-top: 6px; } .lineage-links { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; } .lineage-links path { fill: none; stroke: rgba(107, 88, 61, 0.58); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; } .lineage-links .partner-link { stroke-width: 2.4; stroke: rgba(98, 80, 56, 0.66); } .lineage-links .child-link { stroke-width: 1.9; stroke: rgba(107, 88, 61, 0.54); } .tree-node { position: absolute; width: 132px; min-height: 54px; align-items: flex-start; z-index: 2; } .tree-generation-label { position: absolute; left: 0; width: 54px; font-size: 10px; color: var(--muted); z-index: 1; } .lineage-family { overflow-x: auto; } .lineage-family-readable { overflow: visible; } .lineage-readable-grid { display: grid; grid-template-columns: minmax(300px, 1.05fr) minmax(280px, 0.95fr); gap: 12px; align-items: start; } .lineage-member-column, .lineage-reproduction-column { min-width: 0; } .lineage-generation-block { padding: 8px 0; border-top: 1px dashed rgba(84,68,48,0.12); } .lineage-generation-block:first-child { border-top: 0; padding-top: 0; } .lineage-generation-block > b, .lineage-column-title { display: block; margin: 0 0 7px; color: rgba(84,68,48,0.72); font-size: 11px; } .lineage-person-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 7px; } .family-node.lineage-person { width: auto; min-height: 46px; } .lineage-pair-list { display: grid; gap: 8px; } .lineage-pair-card { padding: 8px; border-radius: 12px; border: 1px solid rgba(84,68,48,0.12); background: rgba(255,253,248,0.70); } .lineage-pair-parents, .lineage-pair-children { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; } .lineage-pair-parents { padding-bottom: 5px; } .lineage-pair-children { padding-top: 5px; border-top: 1px solid rgba(84,68,48,0.08); } .lineage-plus { color: rgba(84,68,48,0.44); font-weight: 700; line-height: 28px; } .lineage-birth-arrow { color: rgba(107, 88, 61, 0.62); font-size: 14px; line-height: 1; padding: 1px 0 3px 13px; } .lineage-mini { display: inline-grid; grid-template-columns: 20px minmax(0, 1fr); grid-template-rows: auto auto; gap: 0 4px; align-items: center; max-width: 132px; min-width: 88px; padding: 4px 6px; border-radius: 9px; border: 1px solid rgba(84,68,48,0.12); background: rgba(255,255,255,0.64); } .lineage-mini.child { border-color: rgba(103,178,44,0.28); background: rgba(246,255,235,0.62); } .lineage-mini.dead { opacity: 0.64; filter: grayscale(0.25); } .lineage-mini img { grid-row: 1 / span 2; width: 20px; height: 20px; object-fit: contain; } .lineage-mini b, .lineage-mini small { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .lineage-mini b { font-size: 10px; line-height: 1.1; } .lineage-mini small { color: var(--muted); font-size: 8px; line-height: 1.1; } @media (max-width: 760px) { .lineage-readable-grid { grid-template-columns: 1fr; } }