/* A warm field station: large tap surface, side controls, and a clear palm-rest area. */
[data-view="dig"] #digScreen{display:block}
[data-view="dig"] #dinoWrap,[data-view="dig"] #sceneFront,[data-view="dig"] #artCredit{display:none}
[data-view="dig"] #veil{opacity:.95;fill:#e7d7ae}
#digScreen{padding:0 var(--padR) var(--palm) 8px;--dig-ink:#3d493d;--dig-green:#3f7565;color:var(--dig-ink)}
.dig-layout{height:100%;display:flex;flex-direction:column;gap:clamp(8px,1.6vh,18px)}
.dig-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;flex-shrink:0}
.dig-eyebrow{font:800 clamp(10px,1vw,13px)/1.3 var(--font-body);letter-spacing:.17em;margin:0 0 7px;color:#6e765a}
.dig-heading h1{font:500 clamp(20px,2.7vw,36px)/1.1 var(--font-display);margin:0;letter-spacing:-.025em}
.dig-collection{display:flex;gap:8px;align-items:center;padding:8px 15px 9px 8px;background:#fff9e9;border:1px solid #e2d3af;border-radius:20px;box-shadow:0 3px 0 #cabb95;white-space:nowrap}
.dig-collection svg{width:42px;height:42px}
.dig-collection strong{font:500 26px/1 var(--font-display);display:block}
.dig-collection small{font-size:10px;display:block;color:#727760;margin-top:4px}
.dig-workspace{display:grid;grid-template-columns:minmax(0,1fr) clamp(185px,22%,260px);gap:clamp(12px,2vw,26px);min-height:0;flex:1}
.dig-main{display:flex;flex-direction:column;min-height:0;min-width:0}
.dig-site-label{display:flex;justify-content:space-between;gap:10px;padding:8px 10px;color:#74684f;font-size:clamp(10px,1vw,13px);line-height:1.3}
.dig-site{font-weight:800;text-transform:uppercase;letter-spacing:.1em}
.dig-species{font-style:italic;text-align:right}
.dig-pit{position:relative;min-height:0;flex:1;border-radius:24px;cursor:pointer;touch-action:none;background:radial-gradient(ellipse at 50% 50%,#ad9673aa,transparent 72%);isolation:isolate}
.dig-pit:focus-visible,.dig-actions button:focus-visible{outline:4px solid #2d7367;outline-offset:4px}
.dig-canvas{display:block;width:100%;height:100%;overflow:visible;pointer-events:none}
.dig-fossil{filter:drop-shadow(0 3px 2px #2c261d55)}
.dig-fossil .fig{--bone:#ffedc5;--bone-edge:#94744b}
.dig-fossil .skeleton{opacity:1!important}
.dig-fossil *{animation:none!important}
.dig-patch .dig-rock,.dig-patch>path{transition:opacity .28s ease}
.dig-disclaimer{font:700 clamp(9px,.9vw,12px)/1.4 var(--font-body);color:#7c725d;text-align:center;margin:0;flex-shrink:0}
.dig-notebook{padding:clamp(12px,1.7vw,24px);background:linear-gradient(100deg,#f7f0db,#fffbed 25%,#faf4e4);border:1px solid #e6d9b9;border-radius:8px 22px 22px 8px;box-shadow:inset 6px 0 0 #e9dfc4,0 6px 0 #cabc9755,0 14px 25px #5f55300d;display:flex;flex-direction:column;align-items:stretch;min-height:0;position:relative}
.dig-notebook:before{content:"";position:absolute;right:20px;top:-7px;width:22px;height:38px;border:3px solid #8c9e8c;border-radius:9px;transform:rotate(6deg);box-shadow:inset 0 0 0 2px #fbf5e4}
.dig-steps{list-style:none;margin:8px 0;padding:0;display:flex;flex-direction:column;gap:12px}
.dig-steps li{display:flex;align-items:center;gap:10px;color:#7e806f}
.dig-steps b{display:grid;place-items:center;border:1px solid #d8d4be;border-radius:50%;width:30px;height:30px;font:500 17px var(--font-display);flex-shrink:0}
.dig-steps span{font:500 clamp(15px,1.4vw,20px)/1.2 var(--font-display)}
.dig-steps small{display:block;font:700 10px/1.4 var(--font-body);margin-top:2px;opacity:.8}
.dig-steps [data-state="active"]{color:#345e50}
.dig-steps [data-state="active"] b{background:#477b67;color:#fff6dc;border-color:#477b67;box-shadow:0 0 0 4px #dce6cf}
.dig-steps [data-state="done"] b{background:#dce6cf;border-color:#a8bea3;color:#345e50;font-size:0}
.dig-steps [data-state="done"] b:after{content:'✓';font-size:18px}
.dig-tool{margin:auto auto 0;width:clamp(52px,7vw,100px);min-height:0;flex-shrink:1}
.dig-tool svg{width:100%;height:100%;max-height:100px;filter:drop-shadow(1px 4px 1px #7b5c3020)}
.dig-instruction{font:500 clamp(17px,1.7vw,25px)/1.15 var(--font-display);margin:8px 0;color:#345e50}
.dig-hint{font:700 clamp(11px,1.05vw,14px)/1.45 var(--font-body);margin:0 0 14px;color:#77755f}
.dig-progress{height:9px;background:#e7dfc8;border-radius:8px;overflow:hidden;flex-shrink:0}
.dig-progress i{display:block;height:100%;background:linear-gradient(90deg,#67977b,#9db685);border-radius:8px;transition:width .25s}
.dig-count{font-size:10px;text-align:right;margin:5px 0 0;color:#77755f}
.dig-actions{display:flex;flex-direction:column;gap:9px;margin-top:14px;flex-shrink:0}
.dig-actions button{min-height:54px;border:0;border-radius:15px;padding:8px 12px;cursor:pointer;font:500 clamp(14px,1.3vw,18px)/1.15 var(--font-display);touch-action:none;color:#fff7e3;background:#487a65;box-shadow:0 4px 0 #2c5646;display:flex;align-items:center;justify-content:center;gap:7px}
.dig-actions button:active{transform:translateY(2px);box-shadow:0 2px 0 #2c5646}
.dig-actions svg{width:30px;height:30px;flex-shrink:0}
.dig-actions .dig-explore{background:#efe5c9;color:#4f624f;box-shadow:0 3px 0 #c7b991;font-size:clamp(12px,1.15vw,16px)}
.dig-reveal{position:absolute;left:50%;top:0;transform:translateX(-50%);background:#fff5d9;box-shadow:0 4px 0 #cfb275,0 8px 20px #372a2b20;border-radius:0 0 18px 18px;padding:4px 17px;display:flex;align-items:center;gap:8px;white-space:nowrap;font-size:10px;font-weight:800;letter-spacing:.12em;pointer-events:none}
.dig-reveal svg{width:32px;height:32px}
[data-phase="2"] .dig-tool{display:none}
[data-phase="2"] .dig-steps{margin-bottom:auto}
.dig-status{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.dig-grain{animation:dig-grain .7s ease-out forwards;transform-box:fill-box;transform-origin:center}
.dig-strike{animation:dig-strike .42s ease-out both;transform-origin:50px 25px}
.dig-sweep{animation:dig-sweep .42s ease-out both;transform-origin:50px 25px}
@keyframes dig-grain{0%{opacity:.95;transform:translate(0,0) scale(1)}100%{opacity:0;transform:translate(var(--dx),var(--dy)) scale(.2)}}
@keyframes dig-strike{0%{opacity:0;transform:rotate(-25deg) translateY(-18px)}30%{opacity:1;transform:rotate(12deg)}80%{opacity:1}100%{opacity:0;transform:translateY(-12px)}}
@keyframes dig-sweep{0%{opacity:0;transform:rotate(-25deg)}25%{opacity:1}75%{opacity:1;transform:translateX(40px) rotate(18deg)}100%{opacity:0;transform:translateX(55px) rotate(25deg)}}
@media(max-height:820px){.dig-layout{gap:8px}.dig-steps{gap:8px;margin:5px 0}.dig-steps small{display:none}.dig-tool{max-height:65px}.dig-notebook{padding:13px 16px}.dig-hint{margin-bottom:8px}.dig-actions{margin-top:10px;gap:8px}.dig-heading h1{font-size:clamp(19px,2.6vw,30px)}.dig-notebook>.dig-eyebrow{font-size:10px}.dig-instruction{margin:6px 0}.dig-steps b{width:26px;height:26px}}
@media(max-width:900px){.dig-heading{gap:10px}.dig-heading h1{max-width:330px}.dig-collection{padding:6px 10px 7px 6px}.dig-collection svg{width:30px;height:30px}.dig-workspace{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(160px,1fr) auto;gap:8px}.dig-notebook{display:grid;grid-template-columns:50px 1fr auto;column-gap:12px;row-gap:3px;border-radius:15px;padding:12px 15px;align-items:center}.dig-notebook:before,.dig-notebook>.dig-eyebrow,.dig-steps,.dig-hint{display:none}.dig-tool{grid-column:1;grid-row:1 / 4;width:50px;height:58px;margin:0}.dig-instruction{grid-column:2;grid-row:1;margin:0;font-size:19px}.dig-progress{grid-column:2;grid-row:2}.dig-count{grid-column:2;grid-row:3;margin:0;font-size:10px}.dig-actions{grid-column:3;grid-row:1 / 4;margin:0;gap:7px}.dig-actions button{min-height:48px;font-size:13px;padding:7px 10px}.dig-actions svg{display:none}[data-phase="2"] .dig-notebook{grid-template-columns:1fr auto}[data-phase="2"] .dig-instruction,[data-phase="2"] .dig-progress,[data-phase="2"] .dig-count{grid-column:1}[data-phase="2"] .dig-actions{grid-column:2}.dig-species{display:none}.dig-disclaimer{font-size:9px}}
@media(prefers-reduced-motion:reduce){#digScreen *,#digScreen *:before{animation:none!important;transition:none!important}}
.dig-collection{color:inherit;font-family:inherit;cursor:pointer;min-height:64px;touch-action:none}
.dig-collection:focus-visible,.dig-gallery button:focus-visible{outline:4px solid #2d7367;outline-offset:3px}
.dig-gallery{position:absolute;inset:0 var(--padR) var(--palm) 8px;border:1px solid #e2d3af;background:#fbf4e1;border-radius:24px;padding:clamp(12px,2vw,24px);display:flex;flex-direction:column;gap:12px;box-shadow:0 6px 0 #cabb95}
.dig-gallery header{display:flex;justify-content:space-between;align-items:center;gap:12px}
.dig-gallery h2{font:500 clamp(18px,2.4vw,30px)/1.1 var(--font-display);margin:0}
.dig-gallery button{font-family:var(--font-display);cursor:pointer;color:#345e50;touch-action:none}
.dig-close,.dig-gallery-nav button{min-height:48px;min-width:48px;border:1px solid #d5c9a4;border-radius:14px;background:#f1e6c6;font-size:16px;padding:8px 15px;box-shadow:0 3px 0 #ccbc91}
.dig-gallery-nav{display:flex;align-items:center;justify-content:center;gap:14px;flex-shrink:0}
.dig-gallery-nav button{font-size:24px;line-height:1}
.dig-gallery-nav button:disabled{opacity:.3;cursor:default}
.dig-gallery-page{font-size:12px;text-align:center}
.dig-gallery-grid{display:grid;grid-template-columns:1fr 1fr;grid-auto-rows:minmax(0,1fr);gap:14px;flex:1;min-height:0}
.dig-specimen{border:1px solid #ddcfaa;background:#ede0ba;border-radius:15px;padding:8px;display:flex;flex-direction:column;align-items:center;min-height:0;box-shadow:0 4px 0 #c6b78e}
.dig-specimen svg{width:100%;height:0;flex:1;min-height:0;background:#78614a;border-radius:9px}
.dig-specimen strong{font:500 clamp(13px,1.5vw,21px)/1.2 var(--font-display);padding-top:6px}
.dig-specimen small{font:700 9px/1.4 var(--font-body);opacity:.75}
.dig-empty{grid-column:1/-1;align-self:center;text-align:center;font:500 24px/1.5 var(--font-display);max-width:400px;justify-self:center;color:#718167}
@media(max-height:560px){.dig-heading .dig-eyebrow,.dig-notebook>.dig-eyebrow,.dig-steps,.dig-hint,.dig-notebook:before{display:none}.dig-heading h1{font-size:20px}.dig-heading{min-height:40px}.dig-collection{min-height:44px;padding:3px 10px}.dig-collection svg{width:28px;height:28px}.dig-collection strong{font-size:19px}.dig-collection small{font-size:9px;margin:0}.dig-workspace{grid-template-columns:minmax(0,1fr) 185px;grid-template-rows:minmax(0,1fr);gap:12px}.dig-notebook{display:flex;padding:8px 12px;gap:4px}.dig-tool{height:40px;max-height:40px;width:40px;margin:auto auto 0}.dig-instruction{font-size:16px;margin:0}.dig-count{font-size:9px}.dig-actions{margin:0;gap:6px;width:100%}.dig-actions button{min-height:44px;font-size:13px;padding:6px}.dig-actions svg{display:none}[data-phase="2"] .dig-progress,[data-phase="2"] .dig-count{display:none}[data-phase="2"] .dig-notebook{justify-content:space-between}.dig-site-label{padding:0 8px 3px;font-size:9px}.dig-disclaimer{font-size:8px}.dig-reveal{font-size:8px;padding:2px 8px}.dig-reveal svg{width:20px;height:20px}.dig-gallery{padding:10px;gap:6px}.dig-gallery header .dig-eyebrow{display:none}.dig-gallery-nav{position:absolute;top:10px;left:45%;transform:translateX(-50%);gap:7px}.dig-gallery-page{font-size:9px;max-width:80px}.dig-gallery h2{font-size:18px;max-width:130px}.dig-gallery-grid{grid-template-columns:repeat(4,1fr);gap:8px}.dig-specimen strong{font-size:12px}.dig-specimen small{display:none}.dig-gallery-nav button{padding:5px;min-width:44px;min-height:44px}}
/* Bones owns the two activities; the story button keeps its original behavior. */
#boneActivities,#poopActivities{position:absolute;top:0;left:8px;right:var(--padR);display:flex;gap:8px;pointer-events:auto;z-index:2}
.bone-activity{display:flex;align-items:center;gap:9px;min-height:50px;padding:5px 16px 5px 9px;border:1px solid #d0c29d;border-radius:16px;background:#fff9e9;color:#52624c;box-shadow:0 3px 0 #b6aa86;font:500 17px var(--font-display);touch-action:none;cursor:pointer}
.bone-activity svg{width:36px;height:36px;pointer-events:none}
.bone-activity[aria-pressed="true"]{background:#e5edcf;border-color:#578570;box-shadow:0 3px 0 #578570;color:#285a48}
.bone-activity:focus-visible{outline:4px solid #478477;outline-offset:3px}
#digScreen{top:64px}
/* Put the field notebook in a compact strip: the dirt gets the full width. */
#digScreen .dig-heading h1{font-size:clamp(20px,2.3vw,29px)}
#digScreen .dig-heading .dig-eyebrow{font-size:10px;margin-bottom:4px}
#digScreen .dig-collection{min-height:48px;padding:5px 12px}
#digScreen .dig-collection svg{width:30px;height:30px}
#digScreen .dig-collection strong{font-size:22px}
#digScreen .dig-workspace{display:flex;flex-direction:column;gap:10px}
#digScreen .dig-main{flex:1;min-height:0}
#digScreen .dig-notebook{order:-1;flex-shrink:0;display:grid;grid-template-columns:42px minmax(0,1fr) 130px;grid-template-rows:auto auto;gap:3px 12px;padding:10px 14px;border-radius:15px;box-shadow:0 3px 0 #cabc9755;align-items:center}
#digScreen .dig-notebook:before,#digScreen .dig-notebook>.dig-eyebrow,#digScreen .dig-steps{display:none}
#digScreen .dig-tool{display:block;grid-column:1;grid-row:1/3;width:42px;height:44px;margin:0;max-height:none}
#digScreen .dig-instruction{grid-column:2;grid-row:1;margin:0;font-size:clamp(16px,1.7vw,23px)}
#digScreen .dig-hint{grid-column:2;grid-row:2;display:block;margin:0;font-size:clamp(10px,1vw,13px)}
#digScreen .dig-progress{grid-column:3;grid-row:1;width:100%;display:block}
#digScreen .dig-count{grid-column:3;grid-row:2;display:block;margin:0}
#digScreen .dig-site-label{padding:2px 8px 7px}
#digScreen .dig-actions{grid-column:4;grid-row:1/3;display:flex;flex-direction:row;margin:0;gap:8px}
#digScreen .dig-actions button{min-height:48px;font-size:14px;padding:7px 12px}
#digScreen .dig-actions svg{display:none}
#digScreen[data-phase="2"] .dig-notebook{grid-template-columns:42px minmax(0,1fr) auto}
#digScreen[data-phase="2"] .dig-progress,#digScreen[data-phase="2"] .dig-count{display:none}
#digScreen[data-phase="2"] .dig-actions{grid-column:3}
#digScreen[data-phase="0"] .dig-progress{opacity:.35}
#digScreen .dig-reveal{top:8px}
@media(max-width:600px){.bone-activity{padding:4px 10px;min-height:46px;font-size:14px;gap:5px}.bone-activity svg{width:28px;height:28px}#digScreen{top:58px}#digScreen .dig-heading h1{font-size:19px}#digScreen .dig-heading .dig-eyebrow{display:none}#digScreen .dig-notebook{grid-template-columns:34px minmax(0,1fr);padding:9px;gap:3px 8px}#digScreen .dig-tool{width:34px;height:40px}#digScreen .dig-progress,#digScreen .dig-count{display:none}#digScreen .dig-hint{font-size:11px}#digScreen[data-phase="2"] .dig-notebook{grid-template-columns:minmax(0,1fr) auto}#digScreen[data-phase="2"] .dig-tool,#digScreen[data-phase="2"] .dig-hint{display:none}#digScreen[data-phase="2"] .dig-instruction{grid-column:1;grid-row:1/3}#digScreen[data-phase="2"] .dig-actions{grid-column:2;flex-direction:column}#digScreen .dig-actions button{min-height:44px;font-size:12px}#digScreen .dig-reveal{font-size:8px;padding:3px 8px}}
@media(max-height:560px){#boneActivities{gap:6px}.bone-activity{min-height:44px;padding:3px 10px;font-size:14px}.bone-activity svg{width:30px;height:30px}#digScreen{top:54px}#digScreen .dig-heading{display:none}#digScreen .dig-layout{gap:0}#digScreen .dig-workspace{flex-direction:row;gap:12px}#digScreen .dig-notebook{order:1;display:flex;flex-direction:column;justify-content:center;align-items:stretch;width:160px;padding:8px;box-sizing:border-box}#digScreen .dig-tool{display:none}#digScreen .dig-instruction{font-size:15px}#digScreen .dig-hint{font-size:10px}#digScreen .dig-progress,#digScreen .dig-count{display:none}#digScreen .dig-actions{flex-direction:column}#digScreen .dig-actions button{min-height:44px;padding:5px;font-size:12px}#digScreen .dig-disclaimer{display:none}#digScreen .dig-site-label{font-size:8px;padding:0 6px 4px}#digScreen .dig-reveal{display:none}}
@media(max-height:560px){#digScreen .dig-heading{display:flex;position:absolute;top:-54px;right:var(--padR);z-index:3}#digScreen .dig-heading>div{display:none}#digScreen .dig-collection{min-height:44px;padding:3px 10px}}
