/* Beta 86: a calmer selection panel, a leaner Constellate bar, and an About link. */

/* Selection panel: while a filmmaker, film or land is held, the list tools step back. */
body.selection-held #index .search-row,
body.selection-held #index #toggle-filters,
body.selection-held #index #toggle-recent,
body.selection-held #index #toggle-saved,
body.selection-held #index .dossier-topline{display:none!important}
body.selection-held #index .index-control-row{justify-content:flex-end;min-height:0;padding-top:0;padding-bottom:2px}
body.selection-held #index #selection-tools{margin-left:auto}
#index .profile-pager.is-single{display:none!important}
/* "Add to thread" becomes a quiet action instead of a full-width box */
#index .entry-detail .collect-current{display:inline-flex!important;width:auto!important;min-height:0!important;margin:2px 0 12px!important;padding:4px 0!important;background:none!important;border:0!important;border-bottom:1px solid rgba(233,217,173,.35)!important;border-radius:0!important;font:600 13px/1.3 'Atlas Sans',system-ui,sans-serif!important;letter-spacing:.02em;color:#e9d9ad!important;box-shadow:none!important}
#index .entry-detail .collect-current:hover,#index .entry-detail .collect-current:focus-visible{border-bottom-color:#e9d9ad!important}
:root[data-reading-theme="light"] #index .entry-detail .collect-current{color:#9c3b26!important;border-bottom-color:rgba(156,59,38,.35)!important}

/* Constellate bar: compact controls; Clear and Exit sit apart at the end */
#constellate-mode #constellate-undo,#constellate-mode #constellate-redo{min-width:30px;padding-left:6px;padding-right:6px;font-size:17px!important;line-height:1}
#constellate-mode #constellate-clear{margin-left:auto}
#constellate-mode #constellate-clear,#constellate-mode #constellate-exit{color:#f1c9a2}
#constellate-popup .weave-discard{display:block;margin:12px 0 2px;padding:4px 0;background:none;border:0;border-bottom:1px solid rgba(216,71,94,.45);color:#ec8f9c;font:600 13px/1.3 'Atlas Sans',system-ui,sans-serif;cursor:pointer}
#constellate-popup .weave-discard:hover,#constellate-popup .weave-discard:focus-visible{border-bottom-color:#ec8f9c}

/* About in the main navigation */
header nav.primary .about-link{color:inherit;text-decoration:none;opacity:.86}
header nav.primary .about-link:hover,header nav.primary .about-link:focus-visible{opacity:1}
body.selection-held #index #section-label{display:none!important}
/* On a phone the featured weave is a slim line, so the map stays visible */
@media (max-width:680px){#featured-weave{padding:10px 12px 9px;width:calc(100% - 24px)}#featured-weave ul,#featured-weave .fw-eyebrow{display:none}#featured-weave h2{font-size:17px;margin:0 22px 6px 0}}
#map-films.is-dismissed{display:none!important}

/* Beta 88: no film boxes appear on their own when you zoom; the poster circles carry the films */
#zoom-films69{display:none!important}

/* Beta 88: one quiet row above a selection: Back on the left, Copy link and Save view on the right */
body.selection-held #index .index-command-bar{display:grid;grid-template-columns:1fr auto;align-items:center;column-gap:12px}
body.selection-held #index .index-command-bar>*{grid-column:1/-1}
body.selection-held #index .index-command-bar>nav.view-history{grid-column:1;grid-row:1;border-bottom:0;margin:0;padding-bottom:6px}
body.selection-held #index .index-command-bar>.index-control-row{grid-column:2;grid-row:1;border:0;margin:0;padding:0 0 6px}
body.selection-held #index #view-forward:disabled{visibility:hidden}

/* Beta 89: the paper palette from the About page; no camera in the brand */
header .brand-camera{display:none!important}
:root:not([data-reading-theme="night"]) .atlas-ledger{color:var(--reading-muted)}
:root:not([data-reading-theme="night"]) .atlas-ledger b{color:var(--reading-ink)}
:root:not([data-reading-theme="night"]) .atlas-ledger span+span{border-left-color:var(--reading-line)}
:root:not([data-reading-theme="night"]) #index .entry-detail .collect-current{color:var(--reading-accent)!important;border-bottom-color:var(--reading-line)!important}
:root:not([data-reading-theme="night"]) header nav.primary .about-link{color:var(--reading-ink)}
:root:not([data-reading-theme="night"]) .map-panel{background:var(--reading-wash)!important}
:root:not([data-reading-theme="night"]) .map-panel .atlas-utilities-map>*,:root:not([data-reading-theme="night"]) .map-panel>details>summary,:root:not([data-reading-theme="night"]) .map-panel>button#world,:root:not([data-reading-theme="night"]) #map-info>summary{color:var(--reading-ink)!important;text-shadow:none!important}
:root:not([data-reading-theme="night"]) #featured-weave{background:rgba(238,240,236,.94);border-color:var(--reading-line);color:var(--reading-ink);box-shadow:0 10px 30px rgba(28,36,52,.12)}
:root:not([data-reading-theme="night"]) #featured-weave h2{color:var(--reading-ink)}
:root:not([data-reading-theme="night"]) #featured-weave ul{color:var(--reading-ink)}
:root:not([data-reading-theme="night"]) #featured-weave .fw-eyebrow,:root:not([data-reading-theme="night"]) #featured-weave a{color:var(--reading-accent)}
:root:not([data-reading-theme="night"]) #featured-weave a{border-bottom-color:var(--reading-line)}
:root:not([data-reading-theme="night"]) #featured-weave .fw-close{color:var(--reading-muted)}

/* Beta 91: theme-weaving: cards become compact chips with a round film image; threads gain end knots and a slow breath */
#constellate-graph .constellate-card rect{rx:21px;ry:21px}
#constellate-graph .constellate-card:not(.selected){opacity:.86}
#constellate-graph .constellate-card .weave-card-art{opacity:1!important}
#constellate-graph .weave-chip-ring{fill:none;stroke-width:1.6}
#constellate-graph .weave-chip-title{font:600 12px/1 'Atlas Sans',system-ui,sans-serif;letter-spacing:.01em}
#constellate-graph .weave-land-caption{font:italic 11px/1 'Atlas Serif',Georgia,serif!important;letter-spacing:.01em}
#constellate-graph .weave-film-star{transform-box:fill-box}
#constellate-graph .weave-thread-line{stroke-width:1.9}
#constellate-graph .weave-thread-knot circle:first-child{fill:var(--reading-paper,#0e1729);fill-opacity:.9;stroke-width:1.6}
#constellate-graph .weave-thread-name{font-size:16px}
@media (prefers-reduced-motion:no-preference){#constellate-graph .weave-thread-glow{animation:weave-breath 5.5s ease-in-out infinite}}
@keyframes weave-breath{0%,100%{stroke-opacity:.18}50%{stroke-opacity:.42}}
/* paper theme: a lighter dusk over the map while weaving, and readable bar actions */
:root:not([data-reading-theme="night"]) .weave-night-veil{fill-opacity:.16}
:root:not([data-reading-theme="night"]) #constellate-mode #constellate-clear,:root:not([data-reading-theme="night"]) #constellate-mode #constellate-exit{color:#9a3b2c}
:root:not([data-reading-theme="night"]) #constellate-graph .weave-thread-halo{stroke:#eef0ec;stroke-opacity:.7}
:root:not([data-reading-theme="night"]) #constellate-graph .weave-thread-name{stroke:#eef0ec;stroke-opacity:.9}

/* Beta 92: the map tools float on the map as one small bar, and the map fills the space above */
.map-panel .map-actions{background:rgba(238,240,236,.9);border:1px solid var(--reading-line,#c9d0c6);border-radius:999px;padding:3px 6px;box-shadow:0 4px 18px rgba(28,36,52,.12);backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px)}
.map-panel .map-actions>details>summary,.map-panel .map-actions>button{padding:5px 10px;border-radius:999px}
.map-panel .map-actions>details>summary:hover,.map-panel .map-actions>button:hover{background:rgba(156,59,38,.08)}
:root[data-reading-theme="night"] .map-panel .map-actions{background:rgba(14,23,41,.82);border-color:rgba(233,217,173,.22);box-shadow:0 4px 18px rgba(0,0,0,.3)}

/* Beta 93: small streamlines */
@media (min-width:681px){header #atlas-browse{display:none!important}}
#view-forward:disabled{visibility:hidden}
.map-panel .zoom button:focus-visible{outline:2px solid var(--reading-accent,#9c3b26);outline-offset:-2px}
#weave-notice{top:112px!important;bottom:auto!important;left:50%!important;right:auto!important;transform:translateX(-50%);max-width:min(440px,calc(100% - 32px))}
#constellate-graph .constellate-edge-label{opacity:0;transition:opacity .15s ease}
#constellate-graph g:hover>.constellate-edge-label,#constellate-graph g:focus>.constellate-edge-label{opacity:1}
@media (max-width:680px){.atlas-ledger{display:flex!important;gap:10px!important;margin:4px 0 0!important;padding:0!important;font-size:9.5px!important}.atlas-ledger b{font-size:15px!important}.atlas-ledger span+span{padding-left:10px!important}.atlas-ledger .ledger-countries{display:flex!important}}
#constellate-new{white-space:nowrap}
body.is-theme-weaving .map-panel .map-actions{display:none}
/* A missing film image becomes a quiet line instead of a large empty box */
#index :has(> .artwork-fallback:not([hidden])){min-height:0!important;height:auto!important;aspect-ratio:auto!important;background:transparent!important;border:1px dashed var(--reading-line,#c9d0c6)!important;padding:10px 12px!important}
#index :has(> .artwork-fallback:not([hidden]))>img{display:none!important}
#index .artwork-fallback:not([hidden]){position:static!important;display:block!important;font-size:12px;color:var(--reading-muted)!important;text-align:left!important}

/* Beta 97: a calmer trail above a selection */
body.selection-held #index .trail-duplicate{display:none!important}
body.selection-held #index #selection-summary{background:none!important;border-left-color:transparent!important;box-shadow:none!important;padding-left:0!important}
body.selection-held #index #selection-summary #selection-locate,body.selection-held #index #selection-summary #clear-context{font-size:12.5px}
body.selection-held #index .index-header{border-top:0!important}
body.selection-held #index .entry-detail .collect-current{margin:0 0 6px!important}
body.selection-held #index #selection-summary{display:flex!important;align-items:center;gap:12px;flex-wrap:nowrap}
body.selection-held #index #selection-summary .selection-label{flex:1 1 auto;min-width:0}
body.selection-held #index #selection-path{display:block!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body.selection-held #index #selection-path>*{display:inline}
body.selection-held #index #selection-summary>button{flex:none;white-space:nowrap}
/* A filmmaker's nation sits right under their name */
#index .entry-detail.maker-dossier{display:flex;flex-direction:column}
#index .entry-detail.maker-dossier>.maker-identity{order:-2;margin-top:0}
#index .entry-detail.maker-dossier>.maker-identity>p:first-child{margin-top:4px}
#weave-play-progress{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
.weave-dots{display:inline-flex;gap:6px;align-items:center;margin:0 8px}
.weave-dots i{width:6px;height:6px;border-radius:50%;background:currentColor;opacity:.28}
.weave-dots i.past{opacity:.55}
.weave-dots i.on{opacity:1;transform:scale(1.5);box-shadow:0 0 6px currentColor}
#index .suggest-fix{display:inline-block;margin:18px 0 6px;font-size:13px;color:var(--reading-accent);border-bottom:1px solid var(--reading-line);text-decoration:none}
