/* Visitor-only UI. Kept separate from the Mini renderer and model styles. */
.neighborhood-panel input[type="search"]{
  width:100%;min-height:39px;margin:0 0 5px;padding:7px 10px;
  background:#fff;border:1px solid #b7d4c0;border-radius:10px;
  color:var(--ink);font:600 13px system-ui,-apple-system,"Segoe UI",sans-serif;
}
.neighborhood-panel input[type="search"]:focus-visible{
  outline:2px solid var(--mint-strong);outline-offset:1px;
}
.neighborhood-match-count{
  display:block;min-height:17px;font-size:11px;color:var(--muted);
  margin:1px 2px 6px;
}
.story-camera{
  display:flex;align-items:center;justify-content:center;
  width:43px;height:43px;flex:none;border:1px solid var(--stroke);
  border-radius:13px;background:#fffefbf2;color:var(--mint-dark);
  box-shadow:var(--shadow);
}
.story-camera:hover{background:#dff2e6;border-color:#9acdb2}
.story-camera svg{
  width:24px;height:24px;fill:none;stroke:currentColor;
  stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;
}
.story-modal[hidden],#storyResultView[hidden],#storyConfirmView[hidden],
#storyShare[hidden]{display:none!important}
.story-modal{
  position:fixed;inset:0;z-index:5000;
  display:flex;align-items:center;justify-content:center;
  padding:14px;background:rgba(16,33,27,.68);
  overscroll-behavior:contain;
}
.story-dialog{
  width:min(440px,100%);max-height:calc(100dvh - 28px);
  overflow:auto;padding:18px;background:#f6f8f4;color:#214338;
  border:1px solid #b7d4c0;border-radius:20px;
  box-shadow:0 20px 65px rgba(0,0,0,.28);
}
.story-heading{
  display:flex;align-items:center;justify-content:space-between;
  gap:14px;color:#235a44;font-size:17px;
}
#storyClose{
  flex:none;width:36px;height:36px;line-height:1;
  border:1px solid #cdddD3;border-radius:10px;
  background:#fff;color:#2b634d;font-size:26px;
}
#storyConfirmView p{
  color:#496a57;font-size:13px;line-height:1.65;margin:18px 0 16px;
}
.story-actions{display:flex;gap:9px;margin-top:12px}
.story-actions button{
  flex:1;min-height:43px;border-radius:11px;
  padding:8px 10px;font-weight:750;font-size:13px;
}
.story-primary{
  color:#fff;background:#246d4e;border:1px solid #246d4e;
}
.story-primary:hover{background:#18583c}
.story-secondary{
  color:#265e49;background:#fff;border:1px solid #b7d4c0;
}
.story-secondary:hover{background:#e5f3e8}
.story-actions button:disabled{opacity:.52;cursor:wait}
.story-status{
  min-height:17px;margin:10px 2px 0;
  font-size:12px;color:#536d5b;line-height:1.5;
}
.story-status:empty{display:none}
#storyPreview{
  display:block;width:auto;max-width:100%;height:auto;
  max-height:min(55dvh,520px);aspect-ratio:9/16;
  margin:14px auto 0;object-fit:contain;
  background:#deede1;border:1px solid #cdddD3;border-radius:8px;
}
@media(max-width:720px){
  .story-camera{width:39px;height:39px;border-radius:11px}
  .story-camera svg{width:22px;height:22px}
  .story-dialog{padding:14px;border-radius:17px}
  .story-heading{font-size:15px}
  #storyPreview{max-height:53dvh}
}
@media(prefers-reduced-motion:reduce){
  .story-camera,.story-actions button{transition:none}
}

/* Normal Mini page share menu, the 3B stage is not modified. */
.mini-share-wrap{position:relative;flex:none}
.mini-share-menu[hidden]{display:none!important}
.mini-share-menu{
  position:absolute;bottom:calc(100% + 9px);left:0;
  box-sizing:border-box;width:min(255px,calc(100vw - 30px));
  display:flex;flex-direction:column;gap:8px;
  background:#fbfdf8;border:1px solid #bad3c4;border-radius:15px;
  padding:13px;box-shadow:0 12px 30px rgba(14,52,35,.22);
  z-index:10;color:#28543f;
}
.mini-share-menu strong{font-size:14px}
.mini-share-menu>button{
  display:block;width:100%;min-height:40px;
  border:1px solid #c8ddcf;border-radius:10px;padding:8px 10px;
  text-align:left;background:#fff;color:#285d45;
  font-size:12px;font-weight:750;cursor:pointer;
}
.mini-share-menu>button:hover{background:#e2f2e7}
.mini-share-menu label{font-size:11px;font-weight:700}
.mini-share-menu input{
  box-sizing:border-box;width:100%;min-height:37px;
  padding:7px 8px;font-size:11px;border-radius:8px;
  border:1px solid #b7d4c0;color:#344e40;background:#fff;
}
.mini-share-menu [role="status"]{font-size:11px;color:#416e53;min-height:16px}
#miniShareToggle[aria-expanded="true"]{background:#dff2e6}

/* One visual action with both share and photo symbols. */
#miniShareToggle svg{width:27px;height:27px;overflow:visible}
#miniShareToggle .camera-mark{stroke-width:1.6}
#miniShareToggle .share-mark{stroke-width:1.75}

/* Latest decision: two permanent, separate actions rather than one menu. */
.mini-action-stack{display:flex;flex-direction:column;align-items:center;gap:7px}
.story-heading{justify-content:flex-end;min-height:22px}
.story-progress{text-align:center;padding:27px 12px 31px;font-size:14px;font-weight:700;color:#27694c}
#storyProgressView[hidden]{display:none!important}
#miniShareToggle svg,#storyCapture svg{width:23px;height:23px}

/* A compact readback indicator; show full dialog only after PNG is ready. */
.story-modal[data-phase="preparing"]{background:transparent;pointer-events:none}
.story-modal[data-phase="preparing"] .story-dialog{width:min(260px,85vw);padding:0;background:transparent;border:0;box-shadow:none;overflow:visible}
.story-modal[data-phase="preparing"] .story-heading{display:none}
.story-modal[data-phase="preparing"] .story-progress{padding:12px 16px;color:#205c43;border-radius:12px;background:#fffffff0;box-shadow:0 8px 26px #163f2a25;font-size:12px}
.story-progress-line{display:block;width:100%;height:4px;background:#d4eada;border-radius:4px;margin-top:9px;overflow:hidden;position:relative}
.story-progress-line::before{content:"";position:absolute;height:100%;width:35%;left:0;background:#318c66;border-radius:4px;animation:miniCaptureLoading 1.2s ease-in-out infinite alternate}
@keyframes miniCaptureLoading{from{left:0}to{left:65%}}
@media(prefers-reduced-motion:reduce){.story-progress-line::before{animation:none;width:100%}}
