/* Resource Prospector: the field log and answer control beside the survey camp's cross-section, inside the practice shell's stage. */
.rp { position: absolute; inset: 0; display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 12px; padding: 8px 12px; }
.rp-panel-l { display: flex; flex-direction: column; gap: 10px; min-height: 0; overflow-y: auto; padding: 2px; }

/* the field log */
.rp-log { padding: 8px 12px 10px; border-radius: var(--tlg-radius-lg, 14px); border: 2px dashed #9db6c2; background: #f2f8fb; color: #12303c; }
.rp-log-k { margin: 0 0 4px; font-size: 16px; font-weight: 800; text-transform: uppercase; letter-spacing: var(--tlg-tracking-caps, .08em); color: #245c70; }
.rp-log-clue { margin: 0; font-size: 19px; font-weight: 700; line-height: 1.35; font-style: italic; }
.rp-log-res { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 22px; font-weight: 800; line-height: 1.2; }
.rp-log-res .rp-icon { width: 44px; height: 44px; flex: none; }
.rp-log-note { margin: 6px 0 0; font-size: 16px; line-height: 1.35; }
.rp-chips { display: flex; flex-direction: column; gap: 6px; }
.rp-chip { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 19px; font-weight: 800; border: 2px solid; width: fit-content; }
.rp-chip--in { background: #e3f0fb; border-color: #3d8fd1; color: #123a5c; }
.rp-chip--out { background: #fdeee4; border-color: #c9682c; color: #5a2a0c; }
html[data-theme="dark"] .rp-log { background: #13293a; color: #e2f0f7; border-color: #3f6f86; }
html[data-theme="dark"] .rp-log-k { color: #8fd0e8; }
html[data-theme="dark"] .rp-chip--in { background: #12304a; color: #d3e9fb; }
html[data-theme="dark"] .rp-chip--out { background: #3a2212; color: #fbe0cc; }

/* the answer control */
.rp-field { border: 0; margin: 0; padding: 0; min-width: 0; }
.rp-field legend { padding: 0; margin: 0 0 6px; font-size: 16px; font-weight: 800; color: var(--tlg-text, #172c38); }
.rp-choices { display: grid; gap: 8px; }
.rp-choices--four { grid-template-columns: 1fr 1fr; }
.rp-choices--two, .rp-choices--site { grid-template-columns: 1fr; }
.rp-choice { display: flex; align-items: center; gap: 10px; min-height: 64px; padding: 8px 10px; text-align: left; font: inherit; cursor: pointer; touch-action: manipulation;
  border-radius: 12px; border: 2px solid var(--tlg-border, #a5b6c1); background: var(--tlg-surface, #fff); color: var(--tlg-text, #172c38); box-shadow: 0 2px 0 rgba(0, 0, 0, .08); }
.rp-choices--four .rp-choice { flex-direction: column; justify-content: center; gap: 4px; min-height: 96px; text-align: center; }
.rp-choice:hover:not(:disabled) { border-color: #245c70; }
.rp-choice[aria-pressed="true"] { border-color: #245c70; border-width: 3px; background: #e4f1f6; box-shadow: inset 0 0 0 2px #245c70; }
html[data-theme="dark"] .rp-choice[aria-pressed="true"] { background: #1b3a48; border-color: #8fd0e8; box-shadow: inset 0 0 0 2px #8fd0e8; }
.rp-choice[aria-pressed="true"] .rp-choice-l::after { content: ' ●'; color: #245c70; }
html[data-theme="dark"] .rp-choice[aria-pressed="true"] .rp-choice-l::after { color: #8fd0e8; }
.rp-choice-ic { flex: none; display: grid; place-items: center; }
.rp-icon { width: 46px; height: 46px; display: block; }
.rp-letter { width: 40px; height: 40px; border-radius: 8px; background: #f2b43c; color: #2b1d00; font-size: 22px; font-weight: 900; border: 2px solid #8a5c08; }
.rp-choice-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.rp-choice-l { font-size: 18px; font-weight: 800; line-height: 1.2; }
.rp-choice-s { font-size: 16px; line-height: 1.3; color: var(--tlg-text-muted, #4b5d68); }
.rp-choice.is-key { border-color: #2e8b57; border-style: solid; }
.rp-choice.is-key .rp-choice-l::before { content: '✓ '; color: #1d6b40; }
.rp-choice.is-miss { border-color: #b42318; border-style: dashed; }
.rp-choice.is-miss .rp-choice-l::before { content: '✗ '; color: #b42318; }
html[data-theme="dark"] .rp-choice.is-key .rp-choice-l::before { color: #8fe0ad; }
html[data-theme="dark"] .rp-choice.is-miss .rp-choice-l::before { color: #ffb4a8; }
.rp button:disabled, .rp input:disabled { cursor: default; }
.rp-choice:disabled { opacity: 1; }

.rp-entry { display: flex; align-items: center; gap: 8px; }
.rp-num { width: 150px; height: 54px; font: inherit; font-size: 28px; font-weight: 800; text-align: right; padding: 0 12px; border-radius: 10px;
  border: 2px solid var(--tlg-border, #a5b6c1); background: var(--tlg-surface, #fff); color: var(--tlg-text, #172c38); font-variant-numeric: tabular-nums;
  -moz-appearance: textfield; appearance: textfield; }
.rp-num::-webkit-outer-spin-button, .rp-num::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.rp-num:focus { border-color: #245c70; }
.rp-sign { width: 54px; height: 54px; font: inherit; font-size: 28px; font-weight: 900; border-radius: 10px; cursor: pointer; touch-action: manipulation;
  border: 2px solid var(--tlg-border, #a5b6c1); background: var(--tlg-surface, #fff); color: var(--tlg-text, #172c38); }
.rp-unit { font-size: 20px; font-weight: 800; }
.rp-entry-note { margin: 6px 0 0; font-size: 16px; color: var(--tlg-text-muted, #4b5d68); }

.rp :focus-visible { outline: 3px solid #b16a08; outline-offset: 2px; }
.rp-msg { margin: 0; min-height: 1.2em; font-size: 16px; font-weight: 700; color: var(--tlg-danger, #b42318); }
html[data-theme="dark"] .rp-msg { color: #ffb4a8; }
.rp-about { font-size: 16px; line-height: 1.4; }
.rp-about summary { cursor: pointer; font-weight: 700; }
.rp-about p { margin: 4px 0 0; }

/* the camp and cross-section */
.rp-view { position: relative; min-width: 0; min-height: 0; display: flex; align-items: flex-start; justify-content: center; }
.rp-scene { position: relative; width: 100%; aspect-ratio: 720 / 620; border-radius: var(--tlg-radius-lg, 14px); overflow: hidden; border: var(--tlg-border-width, 1px) solid var(--tlg-border, #a5b6c1); user-select: none; -webkit-user-select: none; background: #8fc4e8; }
.rp-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.rp-sky { fill: url(#rp-g-sky); }
html[data-theme="dark"] .rp-sky { fill: url(#rp-g-sky-d); }
html[data-theme="dark"] .rp-sun { opacity: .35; }
.rp-cloud ellipse { fill: #ffffff; opacity: .9; }
html[data-theme="dark"] .rp-cloud ellipse { fill: #9fb1c8; opacity: .55; }
.rp-rain { stroke: #3d7fb8; stroke-width: 2.5; stroke-linecap: round; }
.rp-edge { fill: none; stroke: rgba(40, 30, 20, .55); stroke-width: 2; }
.rp-fern path { fill: none; stroke: #8f8678; stroke-width: 2; stroke-linecap: round; }
.rp-shell { fill: none; stroke: #b8b2a8; stroke-width: 2; }
.rp-root { fill: none; stroke: #6e5a44; stroke-width: 2; }
.rp-contact { stroke: #1f6fb5; stroke-width: 2; stroke-dasharray: 6 5; }
.rp-migrate { fill: none; stroke: #d4601c; stroke-width: 3; stroke-dasharray: 7 5; }
.rp-hot { fill: none; stroke: #d4601c; stroke-width: 3.5; stroke-dasharray: 8 5; }
.rp-crack { fill: none; stroke: #4a4743; stroke-width: 3; }
.rp-crack.is-wet { stroke: #3d8fd1; stroke-width: 4; }
.rp-wt { stroke: #1f6fb5; stroke-width: 3; stroke-dasharray: 10 6; fill: none; }
.rp-wt-old { stroke: #ffffff; stroke-width: 2; stroke-dasharray: 4 6; opacity: .8; }
.rp-wt-mark { fill: #1f6fb5; }
.rp-infil, .rp-recharge { fill: none; stroke: #1f6fb5; stroke-width: 3; stroke-dasharray: 6 5; }
.rp-intrusion { stroke: #8f4f3c; stroke-width: 2; }
.rp-vein-out { fill: none; stroke: #1d4f43; stroke-width: 10; stroke-linecap: round; stroke-linejoin: round; }
.rp-vein { fill: none; stroke: #39b08f; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.rp-fleck { fill: #e2b22a; stroke: #6d5208; stroke-width: 1; }
.rp-casing { fill: #9aa6b0; stroke: #4a5560; stroke-width: 2; }
.rp-screen { fill: #4a5560; }
.rp-chev { fill: none; stroke: #ffffff; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.rp-dwt { stroke: #c0392b; stroke-width: 4; fill: none; }
.rp-divide { stroke: #ffffff; stroke-width: 3; stroke-dasharray: 8 6; opacity: .9; }
.rp-flag { fill: #f2b43c; stroke: #8a5c08; stroke-width: 2; }
.rp-flag.is-pick { fill: #245c70; stroke: #0f2f3a; }
.rp-flag.is-ok { fill: #2e8b57; stroke: #145232; }
.rp-flag.is-bad { fill: #b42318; stroke: #6b120b; }
.rp-t-flag { font-size: 20px; font-weight: 900; fill: #2b1d00; }
.rp-flag.is-pick + .rp-t-flag, .rp-flag.is-ok + .rp-t-flag, .rp-flag.is-bad + .rp-t-flag { fill: #ffffff; }
.rp-keybox { fill: none; stroke: #2e8b57; stroke-width: 5; }
.rp-leader { fill: none; stroke: #3a2e20; stroke-width: 2; }
.rp-leader-dot { fill: #fff6d8; stroke: #3a2e20; stroke-width: 2; }
.rp-tagbox, .rp-panel { fill: url(#rp-g-paper); stroke: #5c4a30; stroke-width: 2; }
.rp-riglabel { fill: url(#rp-g-paper); stroke: #245c70; stroke-width: 2.5; }
.rp-riglabel.is-ok { stroke: #2e8b57; stroke-width: 4; }
.rp-riglabel.is-bad { stroke: #b42318; stroke-width: 4; }
.rp-bore { stroke: #30343a; stroke-width: 5; stroke-dasharray: 3 3; }
.rp-bit { fill: #c98a14; stroke: #30343a; stroke-width: 2; }
.rp-hole { fill: rgba(20, 16, 12, .75); stroke: #fff6d8; stroke-width: 2; stroke-dasharray: 6 4; }
.rp-step-dot { fill: #245c70; }
.rp-story-arrow { stroke: #33302b; stroke-width: 3; }
.rp-bar-h { fill: #245c70; } .rp-bar-f { fill: #3a352f; } .rp-bar-w { fill: #3d8fd1; }
.rp-break { stroke: #fff6d8; stroke-width: 5; }

.rp-t { font-family: var(--tlg-font-body, system-ui, sans-serif); fill: #1d2b2f; }
.rp-t-sign { font-size: 18px; font-weight: 800; fill: #ffffff; }
.rp-t-tag { font-size: 18px; font-weight: 700; fill: #2b2418; }
.rp-t-rig { font-size: 18px; font-weight: 800; fill: #12303c; }
.rp-t-panelk { font-size: 18px; font-weight: 800; fill: #245c70; }
.rp-t-core { font-size: 20px; font-weight: 900; fill: #2b2418; }
.rp-t-core.is-ok { fill: #1d6b40; } .rp-t-core.is-bad { fill: #1d2b2f; }
.rp-t-story { font-size: 18px; font-weight: 700; fill: #2b2418; }
.rp-t-story.is-result { font-weight: 900; fill: #245c70; }
.rp-t-stepn { font-size: 18px; font-weight: 900; fill: #ffffff; }
.rp-t-bar { font-size: 18px; font-weight: 700; fill: #2b2418; }
.rp-t-barin { font-size: 18px; font-weight: 800; fill: #ffffff; }
.rp-t-hole { font-size: 18px; font-weight: 800; fill: #fff6d8; }
.rp-t-led { font-size: 18px; font-weight: 700; fill: #2b2418; }
.rp-t-led.is-num { font-family: ui-monospace, Menlo, Consolas, monospace; font-weight: 800; }
.rp-t-led.is-ans { fill: #245c70; font-weight: 900; }
.rp-t-note { font-size: 17px; font-weight: 700; fill: #fff6d8; paint-order: stroke; stroke: #2b2418; stroke-width: 3px; }

/* reveal badge (over the sky) */
.rp-badge { position: absolute; left: 2%; right: 2%; top: 1.5%; padding: 7px 12px; border-radius: 10px; font-size: 17px; font-weight: 700; line-height: 1.3; pointer-events: none;
  background: rgba(255, 255, 255, .97); color: #10202c; border: 3px solid #2e8b57; box-shadow: 0 3px 8px rgba(0, 0, 0, .2); animation: rp-pop .25s ease-out; }
.rp-badge.is-bad { border-color: #b42318; }
.rp-badge.is-count { border-color: #2f6fb5; }
@keyframes rp-pop { from { transform: scale(.94); opacity: 0; } to { transform: none; opacity: 1; } }

/* briefing + start */
.rp-example-svg { display: block; width: 100%; height: auto; max-height: 460px; }
.rp-start-svg { display: block; width: 100%; height: 100%; }

@media (prefers-reduced-motion: reduce) { .rp-badge { animation: none; } }
@media (max-width: 1100px) { .rp { grid-template-columns: 310px minmax(0, 1fr); } }
@media (max-width: 900px) {
  .rp { position: static; grid-template-columns: 1fr; }
  .rp-panel-l { overflow: visible; }
  .rp-view { display: block; order: -1; }
  .rp-scene { width: 100% !important; }
}
