/* ==========================================================================
   Collections — design system
   Warm paper, Acadian blue, a touch of star gold.
   ========================================================================== */

:root {
  /* Arcio brand palette (see brand guidelines) */
  --navy: #0f2f4d;          /* Arcio Navy — primary, headings, CTAs */
  --navy-2: #0a2238;
  --teal: #3e7377;          /* Archive Teal — supporting UI accent */
  --teal-soft: #e3eeee;
  --terracotta: #c96a42;    /* Terracotta Arch — signature accent, sparingly */
  --terracotta-soft: #f7e7df;
  --stone: #dccfbe;         /* Stone — dividers, metadata backgrounds */
  --ivory: #f6f2eb;         /* Ivory — primary light background */
  --charcoal: #1f252d;      /* Charcoal Ink — body text */

  /* Light site on Stone; Ivory and white panels sit on top */
  --paper: var(--stone);
  --paper-2: #d1c3b0;
  --paper-3: #c8b8a3;
  --panel: var(--ivory);
  --surface: #ffffff;
  --ink: var(--charcoal);
  --ink-2: #353d48;
  --muted: #545c67;         /* ≥4.5:1 on Stone */
  --faint: #6f7680;
  --line: #cdbfab;
  --line-2: #bcab94;

  /* Legacy names mapped onto the brand palette */
  --blue: var(--teal);
  --blue-2: #2f5a5e;
  --blue-soft: var(--teal-soft);
  --gold: var(--terracotta);
  --gold-soft: var(--terracotta-soft);
  --red: #a8392b;
  --red-soft: #f6e3df;
  --green: #2f6f58;
  --green-soft: #e2efe8;

  --serif: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;
  --r-btn: 10px;
  --shadow-sm: 0 1px 2px rgba(15, 47, 77, .05), 0 1px 1px rgba(15, 47, 77, .03);
  --shadow: 0 1px 2px rgba(15, 47, 77, .04), 0 8px 24px -6px rgba(15, 47, 77, .10);
  --shadow-lg: 0 2px 4px rgba(15, 47, 77, .04), 0 24px 64px -12px rgba(15, 47, 77, .20);
  --ease: cubic-bezier(.2, .7, .2, 1);

  --header-h: 72px;
  --wrap: 1280px;
  --gutter: clamp(16px, 4vw, 40px);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 15px/1.55 var(--sans);
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--gold-soft); }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.serif { font-family: var(--serif); font-optical-sizing: auto; }
.eyebrow {
  font-size: 11.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.acc { font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.muted { color: var(--muted); }

/* ---------- Buttons & inputs ------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 42px; padding: 0 18px; border-radius: var(--r-btn);
  font-weight: 550; font-size: 14px; white-space: nowrap;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  transition: background .15s, border-color .15s, transform .15s var(--ease), box-shadow .15s;
}
.btn:hover { border-color: var(--ink-2); }
.btn:active { transform: translateY(1px); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-primary { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-primary:hover { background: var(--navy-2); border-color: var(--navy-2); }
.btn-blue { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-blue:hover { background: var(--blue-2); border-color: var(--blue-2); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-ghost:hover { background: var(--paper-2); border-color: transparent; }
.btn-danger { color: var(--red); }
.btn-danger:hover { border-color: var(--red); background: var(--red-soft); }
.btn-sm { height: 34px; padding: 0 13px; font-size: 13px; border-radius: var(--r-sm); }
.btn-icon { width: 42px; padding: 0; }
.btn-sm.btn-icon { width: 34px; }
.btn[disabled] { opacity: .5; pointer-events: none; }

.input, .select, .textarea {
  width: 100%; height: 44px; padding: 0 14px; border-radius: 12px;
  background: var(--surface); border: 1px solid var(--line-2);
  transition: border-color .15s, box-shadow .15s;
}
.textarea { height: auto; min-height: 110px; padding: 12px 14px; resize: vertical; line-height: 1.55; }
.select { appearance: none; padding-right: 36px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5l5 5 5-5' stroke='%236f7886' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.input:hover, .select:hover, .textarea:hover { border-color: var(--faint); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px var(--blue-soft); }
.field { display: grid; gap: 6px; }
.field > label, .label { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.hint { font-size: 12.5px; color: var(--muted); }

.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px;
  border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface);
  font-size: 13px; font-weight: 500; color: var(--ink-2); white-space: nowrap;
  transition: all .15s var(--ease);
}
.chip:hover { border-color: var(--ink-2); color: var(--ink); }
.chip.is-on { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip .n { color: var(--faint); font-variant-numeric: tabular-nums; font-size: 12px; }
.chip.is-on .n { color: rgba(255,255,255,.6); }
.chip svg { width: 14px; height: 14px; }

.badge {
  display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 9px; border-radius: 999px;
  font-size: 11.5px; font-weight: 600; background: var(--paper-2); color: var(--ink-2);
}
.badge.green { background: var(--green-soft); color: var(--green); }
.badge.gold { background: var(--gold-soft); color: #8a6208; }
.badge.red { background: var(--red-soft); color: var(--red); }
.badge.blue { background: var(--blue-soft); color: var(--blue); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.switch { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14px; font-weight: 500; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch i { width: 38px; height: 22px; border-radius: 99px; background: var(--line-2); position: relative; transition: background .2s; flex: none; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .2s var(--ease); }
.switch input:checked + i { background: var(--blue); }
.switch input:checked + i::after { transform: translateX(16px); }
.switch input:focus-visible + i { outline: 2px solid var(--blue); outline-offset: 2px; }

/* ---------- Header ----------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(16px); -webkit-backdrop-filter: saturate(1.4) blur(16px);
  border-bottom: 1px solid transparent; transition: border-color .2s, background .2s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header > .wrap { height: 100%; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; }
.site-header > .wrap > .brand { justify-self: start; }
.site-header > .wrap > .nav { justify-self: center; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-mark { flex: none; border-radius: 22%; }
.wordmark { display: block; flex: none; }
.brand-divider { width: 1px; height: 26px; background: var(--stone); flex: none; }
.admin-brand { gap: 10px; padding: 6px 8px 2px !important; }
.foot-brand { display: flex; align-items: center; gap: 18px; }
.foot-brand .tagline { font-family: var(--serif); font-style: italic; font-size: 16px; color: var(--navy); }
.lang-card .top img { display: block; margin: 0 auto; }
.lang-card .org-line { text-align: center; font-size: 12.5px; color: var(--muted); padding: 16px 20px 0; }
.auth-logo { padding: 4px 0 18px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.brand-name { font-family: var(--serif); font-size: 20px; font-weight: 640; letter-spacing: -.01em; line-height: 1.1; white-space: nowrap; }
.brand-sub { display: block; font-family: var(--sans); font-size: 11.5px; font-weight: 500; color: var(--muted); line-height: 1.3; max-width: 190px; }
.nav { display: flex; gap: 4px; }
.nav a { padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--ink-2); transition: background .15s, color .15s; }
.nav a:hover { background: var(--paper-2); color: var(--ink); }
.nav a.is-active { color: var(--ink); background: var(--paper-2); }
.header-actions { justify-self: end; display: flex; align-items: center; gap: 8px; }

.lang-toggle { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--ivory); border: 1px solid var(--line); }
.lang-toggle button { height: 28px; min-width: 38px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 650; letter-spacing: .04em; color: var(--muted); transition: all .2s var(--ease); }
.lang-toggle button.is-on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }

/* Header search panel (drops down like Wynstock's) */
/* the drop panel's container is a normal block, not the header grid */
.search-drop .wrap { display: block; height: auto; }
.search-drop .search-chips { mask-image: linear-gradient(90deg, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, #000 92%, transparent); }
.search-drop {
  position: absolute; left: 0; right: 0; top: 100%;
  background: color-mix(in srgb, var(--paper) 96%, transparent);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line); box-shadow: 0 30px 50px -30px rgba(22,32,46,.25);
  padding: 20px 0 22px; transform-origin: top; animation: drop .22s var(--ease);
}
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } }

/* ---------- Search bar ------------------------------------------------- */
.searchbar {
  position: relative; display: flex; align-items: center; gap: 8px; padding: 7px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow);
  transition: box-shadow .2s, border-color .2s;
}
.searchbar:focus-within { border-color: var(--line-2); box-shadow: var(--shadow-lg); }
.seg { display: flex; padding: 3px; border-radius: var(--r-sm); background: var(--ivory); flex: none; }
.seg button { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 6px; font-size: 13px; font-weight: 550; color: var(--muted); transition: all .15s; }
.seg button svg { width: 15px; height: 15px; }
.seg button:hover { color: var(--ink); }
.seg button.is-on { background: var(--navy); color: #fff; }
.seg-top { display: inline-flex; margin-bottom: 10px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.searchbar.is-big { padding: 8px 8px 8px 10px; }
.searchbar.is-big input { height: 48px; font-size: 16.5px; }
.searchbar.is-big .go { height: 48px; padding: 0 24px; }
.searchbar input {
  flex: 1; min-width: 0; height: 42px; border: 0; background: transparent; padding: 0 10px; font-size: 15.5px;
}
.searchbar input:focus { outline: none; }
.searchbar input::placeholder { color: var(--faint); }
.searchbar input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
.suggest .ph-acc, .suggest .ph-name, .suggest .ph::before { display: none; }
.suggest .ph svg { width: 60%; }
:lang(fr) q { quotes: "« " " »"; }
.searchbar .kbd { font-size: 11px; font-weight: 600; color: var(--faint); border: 1px solid var(--line-2); border-radius: 6px; padding: 2px 7px; }
.searchbar .clear { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--faint); }
.searchbar .clear:hover { background: var(--paper); color: var(--ink); }
.searchbar .go { height: 42px; border-radius: var(--r-sm); padding: 0 20px; }
.search-chips { display: flex; gap: 8px; margin-top: 14px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.search-chips::-webkit-scrollbar { display: none; }

.suggest {
  position: absolute; left: 0; right: 0; top: calc(100% + 8px); z-index: 30;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-lg);
  padding: 8px; max-height: min(70vh, 560px); overflow: auto; animation: drop .16s var(--ease);
}
.suggest-group { padding: 6px 0; }
.suggest-group + .suggest-group { border-top: 1px solid var(--line); }
.suggest-group .eyebrow { padding: 6px 12px 4px; font-size: 10.5px; }
.suggest-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px 12px; border-radius: 12px; text-align: left; }
.suggest-item.is-active, .suggest-item:hover { background: var(--ivory); }
.suggest-item .thumb { width: 44px; height: 44px; border-radius: 10px; overflow: hidden; flex: none; }
.suggest-item .t { font-weight: 550; line-height: 1.25; }
.suggest-item .s { font-size: 12.5px; color: var(--muted); }
.suggest-item .ico { width: 44px; height: 44px; border-radius: 10px; background: var(--ivory); display: grid; place-items: center; color: var(--muted); flex: none; }
.suggest-item .ico svg { width: 18px; height: 18px; }
.suggest-item mark { background: var(--gold-soft); color: inherit; border-radius: 3px; padding: 0 1px; }
.suggest-empty { padding: 18px 14px; color: var(--muted); font-size: 14px; }

/* ---------- Home ------------------------------------------------------- */
.hero { position: relative; padding: clamp(40px, 7vw, 96px) 0 clamp(40px, 6vw, 80px); overflow: clip; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 120%; z-index: -1;
  background:
    radial-gradient(40% 50% at 85% 20%, rgba(201,106,66,.10), transparent 70%),
    radial-gradient(45% 55% at 10% 10%, rgba(62,115,119,.10), transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .8fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero-grid.is-solo { grid-template-columns: minmax(0, 1fr); max-width: 980px; }
.hero h1 {
  font-family: var(--serif); font-weight: 580; font-size: clamp(46px, 7vw, 94px); line-height: .95; color: var(--navy);
  letter-spacing: -.02em; margin: 18px 0 22px;
}
.hero h1 em { font-style: italic; color: var(--terracotta); font-weight: 500; }
.hero p.lede { font-size: clamp(16px, 1.4vw, 19px); color: var(--ink-2); max-width: 680px; margin: 0 0 30px; }
.hero .popular { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 18px; font-size: 13px; color: var(--muted); }
.hero .popular a { color: var(--ink-2); border-bottom: 1px solid var(--line-2); }
.hero .popular a:hover { color: var(--blue); border-color: var(--blue); }

.collage { position: relative; height: clamp(380px, 42vw, 540px); }
.collage .card-float {
  position: absolute; width: 56%; border-radius: 20px; overflow: hidden; background: var(--surface);
  box-shadow: var(--shadow-lg); transition: transform .5s var(--ease);
}
.collage .card-float { width: 46%; }
.collage .card-float:nth-child(1) { left: 0; top: 4%; transform: rotate(-5deg); z-index: 2; }
.collage .card-float:nth-child(2) { right: 0; top: 0; transform: rotate(4deg); }
.collage .card-float:nth-child(3) { left: 28%; bottom: 0; transform: rotate(-1deg); z-index: 3; width: 48%; }
.collage:hover .card-float:nth-child(1) { transform: rotate(-7deg) translate(-8px, -4px); }
.collage:hover .card-float:nth-child(2) { transform: rotate(6deg) translate(8px, -6px); }
.collage:hover .card-float:nth-child(3) { transform: rotate(0deg) translateY(6px); }
.card-float .art { aspect-ratio: 4 / 3.4; }
.card-float .cap { padding: 12px 16px 14px; }
.card-float .cap b { font-family: var(--serif); font-weight: 600; font-size: 20px; display: block; line-height: 1.2; }
.card-float .cap span { font-size: 12px; color: var(--muted); }

.stats { display: flex; gap: clamp(20px, 4vw, 56px); margin-top: 38px; flex-wrap: wrap; }
.stat b { display: block; font-family: var(--serif); font-size: 40px; font-weight: 580; color: var(--navy); letter-spacing: -.02em; line-height: 1; }
.stat span { font-size: 12.5px; color: var(--muted); }

.section { padding: clamp(40px, 6vw, 80px) 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.section-head h2 { font-family: var(--serif); color: var(--navy); font-weight: 530; font-size: clamp(28px, 3.4vw, 42px); letter-spacing: -.025em; line-height: 1.05; margin: 8px 0 0; }
.section-head .more { font-size: 14px; font-weight: 550; color: var(--blue); display: inline-flex; gap: 6px; align-items: center; white-space: nowrap; }
.section-head .more svg { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.section-head .more:hover svg { transform: translateX(3px); }

.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.cat-tile {
  position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: 176px; padding: 20px;
  border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.cat-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--line-2); }
.cat-tile .ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; }
.cat-tile .ic svg { width: 26px; height: 26px; }
.cat-tile h3 { font-family: var(--serif); color: var(--navy); font-weight: 600; font-size: 22px; line-height: 1.2; letter-spacing: -.01em; margin: 18px 0 4px; }
.cat-tile .n { font-size: 13px; color: var(--muted); }
.cat-tile .bgimg { position: absolute; right: 16px; top: 16px; width: 64px; height: 76px; border-radius: 999px 999px 6px 6px; overflow: hidden; background: var(--ivory); border: 1px solid var(--line); }
.cat-tile .bgimg img { width: 100%; height: 100%; object-fit: cover; }

.rail { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(220px, 1fr); gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: thin; }
.rail > * { scroll-snap-align: start; }

.band {
  border-radius: var(--r-lg); background: var(--ivory); color: var(--ink); border: 1px solid var(--line); padding: clamp(28px, 5vw, 56px);
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: center; position: relative; overflow: hidden;
}
.band::after { content: ""; position: absolute; right: 6%; bottom: 0; width: 180px; height: 230px; border-radius: 999px 999px 0 0; border: 2px solid rgba(201,106,66,.55); border-bottom: 0; }
.band h2 { font-family: var(--serif); color: var(--navy); font-weight: 500; font-size: clamp(26px, 3vw, 38px); letter-spacing: -.02em; line-height: 1.1; margin: 10px 0 12px; }
.band p { color: var(--ink-2); margin: 0; }
.band .eyebrow { color: var(--terracotta); }

/* ---------- Object cards ----------------------------------------------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 26px 20px; }
.grid.is-list { grid-template-columns: 1fr; gap: 10px; }
.card { display: block; position: relative; }
.card .art {
  position: relative; aspect-ratio: 4 / 4.6; border-radius: var(--r); overflow: hidden;
  background: var(--paper-2); transition: transform .35s var(--ease), box-shadow .35s;
}
.card:hover .art { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.art img.photo { width: 100%; height: 100%; object-fit: contain; padding: 10%; mix-blend-mode: multiply; transition: transform .6s var(--ease); }
.art.cover img.photo { object-fit: cover; padding: 0; mix-blend-mode: normal; }
.card:hover .art img.photo { transform: scale(1.04); }
.card .meta { padding: 14px 4px 0; }
.card .title { font-family: var(--serif); font-size: 21px; font-weight: 580; line-height: 1.22; letter-spacing: -.01em; }
.card .alt { font-size: 13px; color: var(--muted); margin-top: 2px; }
.card .sub { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--faint); margin-top: 8px; }
.card .sub .sep { width: 3px; height: 3px; border-radius: 50%; background: currentColor; }
.card .flags { position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; z-index: 2; }
.card .flags .badge { background: rgba(255,255,255,.9); backdrop-filter: blur(6px); box-shadow: var(--shadow-sm); }
.card .flags .badge svg { width: 12px; height: 12px; }

.grid.is-list .card { display: grid; grid-template-columns: 88px 1fr auto; gap: 18px; align-items: center; padding: 10px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); }
.grid.is-list .card .art { aspect-ratio: 1; border-radius: 12px; }
.grid.is-list .card:hover .art { transform: none; box-shadow: none; }
.grid.is-list .card .meta { padding: 0; }
.grid.is-list .card .flags { position: static; }
.grid.is-list .card .art .ph-acc, .grid.is-list .card .art .ph-name { display: none; }

/* Placeholder art for objects without photographs */
.ph { position: absolute; inset: 0; display: grid; place-items: center; overflow: hidden; }
.ph::before {
  /* doorway arch — the brand's signature motif, kept quiet */
  content: ""; position: absolute; left: 50%; bottom: 0; transform: translateX(-50%);
  width: 52%; height: 72%; border-radius: 999px 999px 0 0;
  background: rgba(255,255,255,.34); border: 1px solid rgba(255,255,255,.55); border-bottom: 0;
}
.ph svg { width: 34%; max-width: 92px; height: auto; color: var(--ink); opacity: .34; position: relative; }
.ph-acc { position: absolute; left: 14px; bottom: 12px; font-size: 11px; font-weight: 600; letter-spacing: .06em; color: rgba(22,32,46,.42); font-variant-numeric: tabular-nums; }
.ph-name { position: absolute; left: 14px; right: 14px; top: 12px; font-family: var(--serif); font-style: italic; font-size: 16px; color: rgba(22,32,46,.45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.tint-built { background: #e8e2d8; }
.tint-furnishings { background: #eee3d1; }
.tint-personal { background: #f1e1de; }
.tint-materials { background: #dfe6ec; }
.tint-science { background: #dcebe5; }
.tint-commtools { background: #e7e1ee; }
.tint-distribution { background: #dbe5ef; }
.tint-communication { background: #e5e9d9; }
.tint-recreational { background: #f3e7cc; }
.tint-unclassified, .tint- { background: #efe9e0; }
.ic.tint-built { color: #7a6a52; } .ic.tint-furnishings { color: #8a6a3a; } .ic.tint-personal { color: #9c4f45; }
.ic.tint-materials { color: #3d5f7c; } .ic.tint-science { color: #2f6e58; } .ic.tint-commtools { color: #5f4b85; }
.ic.tint-distribution { color: #2c5c8c; } .ic.tint-communication { color: #5a6b34; } .ic.tint-recreational { color: #97700f; }
.ic.tint-unclassified { color: #6f6a62; }

/* ---------- Search page ------------------------------------------------ */
.page-head { padding: clamp(28px, 4vw, 52px) 0 24px; }
.crumbs { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); }
.crumbs a:hover { color: var(--ink); }
.crumbs svg { width: 12px; height: 12px; opacity: .6; }
.page-head h1 { font-family: var(--serif); color: var(--navy); font-weight: 510; font-size: clamp(34px, 4.6vw, 58px); letter-spacing: -.015em; line-height: 1.02; margin: 14px 0 6px; }
.page-head h1 q { quotes: "“" "”"; color: var(--terracotta); font-style: italic; }
:lang(fr) .page-head h1 q { quotes: "« " " »"; }
.page-head p { color: var(--muted); margin: 0; }

.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 22px 0 22px; }
.toolbar .count { font-size: 14px; color: var(--muted); margin-right: auto; }
.toolbar .count b { color: var(--ink); font-weight: 600; }
.toolbar .select { height: 38px; width: auto; border-radius: 999px; font-size: 13.5px; }
.view-toggle { display: inline-flex; border: 1px solid var(--line-2); border-radius: 999px; padding: 3px; background: var(--surface); }
.view-toggle button { width: 32px; height: 30px; border-radius: 999px; display: grid; place-items: center; color: var(--muted); }
.view-toggle button.is-on { background: var(--paper-2); color: var(--ink); }
.view-toggle svg { width: 16px; height: 16px; }
.active-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: -8px 0 20px; }
.active-filters .chip { height: 30px; background: var(--blue-soft); border-color: transparent; color: var(--blue); }
.active-filters .chip:hover { border-color: var(--blue); }

.layout-search { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 36px; align-items: start; }
.layout-search.no-filters { grid-template-columns: minmax(0, 1fr); }
.filters { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 26px; max-height: calc(100vh - var(--header-h) - 40px); overflow: auto; padding-right: 6px; }
.filter h4 { margin: 0 0 10px; }
.filter .opts { display: grid; gap: 2px; }
.opt { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 10px; font-size: 13.5px; color: var(--ink-2); text-align: left; width: 100%; }
.opt:hover { background: var(--paper-2); }
.opt .box { width: 16px; height: 16px; border-radius: 5px; border: 1.5px solid var(--line-2); flex: none; display: grid; place-items: center; transition: all .15s; }
.opt.is-on .box { background: var(--navy); border-color: var(--navy); }
.opt.is-on .box::after { content: ""; width: 8px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.opt.is-on { color: var(--ink); font-weight: 550; }
.opt .n { margin-left: auto; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.opt[disabled] { opacity: .45; pointer-events: none; }

.empty { text-align: center; padding: 70px 20px; }
.empty .ill { width: 88px; height: 88px; border-radius: var(--r-lg); background: var(--ivory); display: grid; place-items: center; margin: 0 auto 18px; color: var(--muted); }
.empty .ill svg { width: 38px; height: 38px; }
.empty h3 { font-family: var(--serif); color: var(--navy); font-weight: 530; font-size: 26px; margin: 0 0 6px; }
.empty p { color: var(--muted); margin: 0 auto 18px; max-width: 420px; }

.load-more { display: flex; justify-content: center; padding: 40px 0 10px; }

.skeleton { background: linear-gradient(90deg, var(--paper-2) 0%, var(--paper-3) 50%, var(--paper-2) 100%); background-size: 200% 100%; animation: shimmer 1.3s infinite linear; border-radius: 8px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.sk-card .art { aspect-ratio: 4 / 4.6; border-radius: var(--r); }
.sk-card .l1 { height: 16px; width: 70%; margin-top: 14px; }
.sk-card .l2 { height: 12px; width: 45%; margin-top: 8px; }

/* Filter drawer on small screens */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(22,32,46,.35); z-index: 80; animation: fade .2s; }
.drawer { position: fixed; top: 0; bottom: 0; left: 0; width: min(360px, 92vw); background: var(--paper); z-index: 81; padding: 22px; overflow: auto; box-shadow: var(--shadow-lg); animation: slidein .25s var(--ease); }
.drawer .filters { position: static; max-height: none; }
@keyframes slidein { from { transform: translateX(-100%); } }
@keyframes fade { from { opacity: 0; } }

/* ---------- Object page ------------------------------------------------ */
.obj { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 72px); align-items: start; padding-bottom: 40px; }
.gallery { position: sticky; top: calc(var(--header-h) + 20px); }
.stage { position: relative; aspect-ratio: 1 / 1; border-radius: var(--r-lg); overflow: hidden; background: var(--paper-2); cursor: zoom-in; }
.stage img.photo { width: 100%; height: 100%; object-fit: contain; padding: 6%; mix-blend-mode: multiply; }
.stage .ph svg { width: 26%; max-width: 150px; }
.stage .nav-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,.9); box-shadow: var(--shadow); display: grid; place-items: center; opacity: 0; transition: opacity .2s; }
.stage:hover .nav-btn { opacity: 1; }
.stage .nav-btn.prev { left: 14px; } .stage .nav-btn.next { right: 14px; }
.stage .nav-btn svg { width: 18px; height: 18px; }
.stage .zoom-hint { position: absolute; right: 14px; bottom: 14px; }
.thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; padding-bottom: 4px; }
.thumbs button { width: 74px; height: 74px; border-radius: 12px; overflow: hidden; background: var(--paper-2); flex: none; border: 2px solid transparent; transition: border-color .15s; }
.thumbs button.is-on { border-color: var(--navy); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }
.no-photo-note { margin-top: 12px; font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.no-photo-note svg { width: 16px; height: 16px; }

.obj h1 { font-family: var(--serif); color: var(--navy); font-weight: 510; font-size: clamp(36px, 4.4vw, 60px); letter-spacing: -.015em; line-height: 1.02; margin: 14px 0 6px; }
.obj .alt-name { font-size: 21px; color: var(--muted); font-family: var(--serif); font-style: italic; }
.facts { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 26px; }
.facts .chip { cursor: default; }
.facts a.chip { cursor: pointer; }
.prose { font-size: 16.5px; line-height: 1.7; color: var(--ink-2); }
.prose p { margin: 0 0 1em; }
.story { margin-top: 26px; padding: 22px 24px; border-radius: var(--r); background: var(--gold-soft); border: 1px solid #f1e0b5; }
.story .eyebrow { color: #8a6208; }
.story p { font-family: var(--serif); font-size: 20px; line-height: 1.6; margin: 8px 0 0; color: #3b3222; }
.lang-note { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted); margin: 0 0 12px; }
.lang-note svg { width: 14px; height: 14px; }

.details { margin-top: 34px; border-top: 1px solid var(--line); }
.details h3 { margin: 22px 0 6px; }
.dl { display: grid; grid-template-columns: minmax(130px, 34%) 1fr; }
.dl dt, .dl dd { padding: 12px 0; border-bottom: 1px solid var(--line); margin: 0; font-size: 14.5px; }
.dl dt { color: var(--muted); padding-right: 16px; }
.dl dd { color: var(--ink); }
.dl dd .orig { display: block; font-size: 12.5px; color: var(--faint); margin-top: 2px; }

.docs { display: grid; gap: 10px; margin-top: 10px; }
.doc { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); transition: border-color .15s, box-shadow .15s; }
.doc:hover { border-color: var(--line-2); box-shadow: var(--shadow-sm); }
.doc .ft { width: 42px; height: 48px; border-radius: 8px; display: grid; place-items: center; font-size: 10px; font-weight: 750; letter-spacing: .04em; color: #fff; flex: none; background: var(--ink-2); position: relative; }
.doc .ft.pdf { background: #c2412d; } .doc .ft.doc, .doc .ft.docx { background: #2b5797; } .doc .ft.xls, .doc .ft.xlsx, .doc .ft.csv { background: #217346; }
.doc .ft.jpg, .doc .ft.jpeg, .doc .ft.png, .doc .ft.tif, .doc .ft.tiff, .doc .ft.webp { background: #7b5ea7; }
.doc .t { font-weight: 550; line-height: 1.3; }
.doc .s { font-size: 12.5px; color: var(--muted); }
.doc .go { margin-left: auto; color: var(--muted); }
.doc .go svg { width: 18px; height: 18px; }

.obj-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 26px; }
.credit { margin-top: 26px; font-size: 16px; color: var(--muted); font-style: italic; font-family: var(--serif); }

/* Lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(14,20,29,.94); display: grid; grid-template-rows: auto 1fr auto; animation: fade .2s; color: #fff; }
.lightbox header { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; }
.lightbox .lb-stage { position: relative; overflow: hidden; display: grid; place-items: center; touch-action: none; }
.lightbox .lb-stage img { max-width: 94vw; max-height: 100%; object-fit: contain; transition: transform .2s var(--ease); cursor: zoom-in; user-select: none; -webkit-user-drag: none; }
.lightbox .lb-stage img.zoomed { cursor: grab; transition: none; }
.lightbox footer { padding: 14px 18px 20px; text-align: center; font-size: 14px; color: rgba(255,255,255,.75); }
.lightbox .btn { background: rgba(255,255,255,.1); border-color: transparent; color: #fff; }
.lightbox .btn:hover { background: rgba(255,255,255,.2); }
.lightbox .lb-nav { position: absolute; top: 50%; transform: translateY(-50%); }
.lightbox .lb-nav.prev { left: 18px; } .lightbox .lb-nav.next { right: 18px; }

/* ---------- Footer ----------------------------------------------------- */
.site-footer { margin-top: 60px; border-top: 1px solid var(--line); padding: 44px 0 56px; font-size: 13.5px; color: var(--muted); }
.site-footer .wrap { display: flex; gap: 24px; justify-content: space-between; flex-wrap: wrap; align-items: center; }
.site-footer a:hover { color: var(--ink); }
.site-footer .links { display: flex; gap: 18px; flex-wrap: wrap; }

/* ---------- Language chooser ------------------------------------------- */
.lang-gate { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 20px; background: rgba(220,207,190,.55); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); animation: fade .3s; }
.lang-card { width: min(640px, 100%); border-radius: var(--r-lg); overflow: hidden; background: var(--surface); box-shadow: var(--shadow-lg); animation: pop .35s var(--ease); }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.lang-card .top { background: var(--ivory); padding: 40px 28px 30px; border-bottom: 1px solid var(--line); }
.lang-card .top .brand-name { font-size: 24px; }
.lang-card .top .brand-sub { color: rgba(255,255,255,.6); max-width: none; }
.lang-card .body { padding: 26px 28px 30px; }
.lang-card .body .eyebrow { text-align: center; margin-bottom: 20px; }
.lang-options { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.lang-opt { padding: 26px 18px 22px; border-radius: var(--r); border: 1px solid var(--line-2); text-align: center; transition: all .2s var(--ease); background: var(--surface); }
.lang-opt:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow); }
.lang-opt .mono { width: 58px; height: 58px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font-family: var(--serif); font-size: 24px; font-style: italic; background: var(--blue-soft); color: var(--blue); }
.lang-opt:nth-child(2) .mono { background: var(--gold-soft); color: #8a6208; }
.lang-opt b { display: block; font-size: 15px; letter-spacing: .08em; text-transform: uppercase; }
.lang-opt span { font-size: 12.5px; color: var(--muted); }

/* ---------- Toasts, dialogs -------------------------------------------- */
.toasts { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 300; display: grid; gap: 8px; justify-items: center; pointer-events: none; }
.toast { background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 14px; font-weight: 500; box-shadow: var(--shadow-lg); animation: pop .25s var(--ease); display: flex; align-items: center; gap: 10px; pointer-events: auto; }
.toast.error { background: var(--red); }
.toast svg { width: 16px; height: 16px; }
.dialog-backdrop { position: fixed; inset: 0; z-index: 150; background: rgba(22,32,46,.4); display: grid; place-items: center; padding: 20px; animation: fade .2s; }
.dialog { width: min(460px, 100%); background: var(--surface); border-radius: var(--r-lg); padding: 26px; box-shadow: var(--shadow-lg); animation: pop .25s var(--ease); }
.dialog h3 { font-family: var(--serif); color: var(--navy); font-weight: 560; font-size: 24px; margin: 0 0 8px; }
.dialog p { color: var(--ink-2); margin: 0 0 22px; }
.dialog .row { display: flex; justify-content: flex-end; gap: 8px; }

.spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.page-loading { display: grid; place-items: center; min-height: 50vh; color: var(--muted); }

/* ---------- Auth ------------------------------------------------------- */
.auth { min-height: calc(100vh - var(--header-h)); display: grid; place-items: center; padding: 40px 20px; }
.auth-card { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 32px; }
.auth-card h1 { font-family: var(--serif); color: var(--navy); font-weight: 530; font-size: 30px; letter-spacing: -.02em; margin: 10px 0 6px; }
.auth-card form { display: grid; gap: 16px; margin-top: 22px; }
.auth-card .lang-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.auth-card .lang-pick button { height: 44px; border-radius: 12px; border: 1px solid var(--line-2); font-weight: 550; font-size: 14px; }
.auth-card .lang-pick button.is-on { border-color: var(--navy); background: var(--navy); color: #fff; }
.form-error { background: var(--red-soft); color: var(--red); padding: 10px 14px; border-radius: 12px; font-size: 13.5px; font-weight: 500; }

/* ---------- Admin ------------------------------------------------------ */
.admin { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; }
.admin-side { position: sticky; top: 0; height: 100vh; padding: 20px 14px; border-right: 1px solid var(--line); background: var(--ivory); display: flex; flex-direction: column; gap: 22px; }
.admin-side .brand { padding: 4px 8px; }
.admin-nav { display: grid; gap: 2px; }
.admin-nav a { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 10px; font-size: 14px; font-weight: 500; color: var(--ink-2); }
.admin-nav a svg { width: 18px; height: 18px; color: var(--muted); }
.admin-nav a:hover { background: var(--paper-2); }
.admin-nav a.is-active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); border: 1px solid var(--line); padding: 8px 11px; }
.admin-nav a.is-active svg { color: var(--blue); }
.admin-nav .sec { font-size: 10.5px; font-weight: 650; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); padding: 14px 12px 6px; }
.admin-side .foot { margin-top: auto; display: grid; gap: 10px; }
.admin-side .foot .lang-toggle { justify-self: start; }
.me { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 700; flex: none; }
.me .who { min-width: 0; line-height: 1.25; }
.me .who b { display: block; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me .who span { font-size: 11.5px; color: var(--muted); }
.admin-main { min-width: 0; padding: 26px clamp(18px, 3vw, 40px) 80px; }
.admin-top { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; flex-wrap: wrap; }
.admin-top h1 { font-family: var(--serif); color: var(--navy); font-weight: 530; font-size: 32px; letter-spacing: -.02em; margin: 0; margin-right: auto; line-height: 1.1; }
.admin-mobile-bar { display: none; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 22px; }
.panel + .panel { margin-top: 18px; }
.panel h2 { font-size: 15px; font-weight: 650; margin: 0 0 4px; }
.panel .hint { margin: 0 0 16px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px 20px; display: block; transition: border-color .15s, box-shadow .15s; }
a.kpi:hover { border-color: var(--line-2); box-shadow: var(--shadow-sm); }
.kpi span { display: block; font-size: 12.5px; color: var(--muted); font-weight: 500; }
.kpi span::first-letter { text-transform: uppercase; }
.kpi b { display: block; font-family: var(--serif); font-size: 36px; font-weight: 530; letter-spacing: -.02em; margin-top: 4px; line-height: 1.1; }
.kpi .bar { height: 5px; border-radius: 9px; background: var(--paper-2); margin-top: 12px; overflow: hidden; }
.kpi .bar i { display: block; height: 100%; background: var(--navy); border-radius: 9px; }

.table-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th { text-align: left; font-size: 11.5px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--ivory); position: sticky; top: 0; white-space: nowrap; }
table.t td { padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr { transition: background .1s; }
table.t tbody tr:hover { background: #fcfbf8; }
table.t tr.is-sel { background: var(--blue-soft); }
table.t .thumb { width: 46px; height: 46px; border-radius: 10px; overflow: hidden; position: relative; background: var(--paper-2); }
table.t .thumb img { width: 100%; height: 100%; object-fit: cover; }
table.t .thumb .ph svg { width: 55%; }
table.t .thumb .ph-acc, table.t .thumb .ph-name { display: none; }
table.t .nm { font-weight: 550; }
table.t .nm small { display: block; font-weight: 400; color: var(--muted); font-size: 12.5px; }
.cb { width: 18px; height: 18px; accent-color: var(--ink); }
.bulkbar { position: sticky; bottom: 18px; margin-top: 16px; display: flex; align-items: center; gap: 10px; padding: 10px 12px 10px 18px; border-radius: var(--r); background: var(--navy); color: #fff; box-shadow: var(--shadow-lg); width: fit-content; margin-inline: auto; animation: pop .2s var(--ease); z-index: 20; }
.bulkbar .btn { background: rgba(255,255,255,.1); border-color: transparent; color: #fff; }
.bulkbar .btn:hover { background: rgba(255,255,255,.2); }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13.5px; color: var(--muted); }

/* Editor */
.editor { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 22px; align-items: start; }
.editor .side { position: sticky; top: 20px; display: grid; gap: 18px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.tabs { justify-self: start; width: fit-content; display: inline-flex; padding: 3px; border-radius: var(--r-sm); background: var(--ivory); border: 1px solid var(--line); margin-bottom: 8px; }
.tabs button { height: 28px; padding: 0 12px; border-radius: 7px; font-size: 12.5px; font-weight: 600; color: var(--muted); }
.tabs button.is-on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.savebar { position: sticky; bottom: 16px; z-index: 20; margin-top: 18px; display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 20px; border-radius: var(--r); background: var(--navy); color: #fff; box-shadow: var(--shadow-lg); }
.savebar .msg svg { width: 16px; height: 16px; flex: none; }
.savebar .msg { white-space: nowrap; margin-right: auto; font-size: 13.5px; color: rgba(255,255,255,.8); display: flex; align-items: center; gap: 8px; }
.savebar .btn { border-color: transparent; }
.savebar .btn-ghost { color: #fff; }
.savebar .btn-ghost:hover { background: rgba(255,255,255,.12); }
.savebar .btn-primary { background: #fff; color: var(--ink); }

.dropzone { display: block; border: 1.5px dashed var(--line-2); border-radius: var(--r); padding: 18px; text-align: center; color: var(--muted); font-size: 13.5px; transition: all .15s; cursor: pointer; background: var(--ivory); }
.dropzone:hover, .dropzone.is-over { border-color: var(--blue); background: var(--blue-soft); color: var(--blue); }
.dropzone svg { width: 24px; height: 24px; margin: 0 auto 6px; display: block; }
.dropzone b { color: var(--ink); }
.media-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.media-tile { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--paper-2); cursor: grab; border: 2px solid transparent; }
.media-tile.is-cover { border-color: var(--gold); }
.media-tile img { width: 100%; height: 100%; object-fit: cover; }
.media-tile .acts { position: absolute; inset: auto 4px 4px 4px; display: flex; justify-content: space-between; opacity: 0; transition: opacity .15s; }
.media-tile:hover .acts, .media-tile:focus-within .acts { opacity: 1; }
.media-tile .acts button { width: 28px; height: 28px; border-radius: 8px; background: rgba(255,255,255,.94); display: grid; place-items: center; box-shadow: var(--shadow-sm); }
.media-tile .acts svg { width: 14px; height: 14px; }
.media-tile .star { position: absolute; top: 6px; left: 6px; width: 22px; height: 22px; border-radius: 50%; background: var(--gold); color: #fff; display: grid; place-items: center; }
.media-tile .star svg { width: 12px; height: 12px; }
.media-tile.is-private::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(45deg, rgba(22,32,46,.18) 0 6px, transparent 6px 12px); pointer-events: none; }
.media-tile.dragging { opacity: .4; }
.media-tile.uploading { display: grid; place-items: center; cursor: default; }
.media-tile .prog { position: absolute; left: 8px; right: 8px; bottom: 8px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.6); overflow: hidden; }
.media-tile .prog i { display: block; height: 100%; background: var(--blue); width: 0; transition: width .2s; }
.doc-list { display: grid; gap: 8px; margin-bottom: 12px; }
.doc-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; }
.doc-row .ft { width: 34px; height: 40px; border-radius: 6px; font-size: 9px; }
.doc-row .info { min-width: 0; flex: 1; }
.doc-row .info input { border: 0; padding: 0; height: auto; font-weight: 550; width: 100%; background: transparent; }
.doc-row .info input:focus { outline: none; box-shadow: none; color: var(--blue); }
.doc-row .info small { color: var(--muted); font-size: 12px; }
.pub-card .switch + .switch { margin-top: 14px; }
.pub-card .status { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }

.import-result { display: grid; gap: 14px; }
.vocab-row input { height: 36px; border-radius: 10px; }
.search-mini { position: relative; flex: 1; min-width: 220px; max-width: 420px; }
.search-mini input { padding-left: 40px; border-radius: 999px; height: 40px; }
.search-mini svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--muted); }
.seg-filter { display: inline-flex; gap: 4px; flex-wrap: wrap; }

/* ---------- Responsive ------------------------------------------------- */
@media (max-width: 1080px) {
  .editor { grid-template-columns: 1fr; }
  .editor .side { position: static; }
}
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .collage { height: 360px; max-width: 520px; margin: 0 auto; width: 100%; }
  .layout-search { grid-template-columns: 1fr; }
  .layout-search > .filters { display: none; }
  .obj { grid-template-columns: 1fr; }
  .gallery { position: static; }
  .band { grid-template-columns: 1fr; }
  .nav { display: none; }
  .site-header > .wrap { grid-template-columns: 1fr auto; }
  .admin { grid-template-columns: 1fr; }
  .admin-side { position: fixed; z-index: 90; left: 0; width: 270px; transform: translateX(-100%); transition: transform .25s var(--ease); box-shadow: var(--shadow-lg); }
  .admin-side.is-open { transform: none; }
  .admin-mobile-bar { display: flex; align-items: center; gap: 10px; margin: -8px 0 16px; }
}
@media (min-width: 961px) { .only-mobile { display: none !important; } }
@media (max-width: 640px) {
  :root { --header-h: 60px; }
  .brand-sub { display: none; }
  .brand-divider { display: none; }
  .site-header .wrap { gap: 12px; }
  .searchbar { flex-wrap: wrap; padding: 6px; }
  .searchbar .seg { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; }
  .searchbar .seg button { flex: 1; justify-content: center; }
  .searchbar .kbd { display: none; }
  .searchbar .go { padding: 0 14px; }
  .searchbar .go span { display: none; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 12px; }
  .card .title { font-size: 16px; }
  .collage { height: 290px; }
  .lang-options { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .dl { grid-template-columns: 1fr; }
  .dl dt { padding-bottom: 0; border-bottom: 0; font-size: 12.5px; }
  .dl dd { padding-top: 4px; }
  .toolbar .select { flex: 1; }
  .hide-sm { display: none !important; }
  .grid.is-list .card { grid-template-columns: 64px 1fr; }
  .grid.is-list .card .flags { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

@media print {
  .site-header, .site-footer, .obj-actions, .thumbs, .stage .nav-btn, .related { display: none !important; }
  body { background: #fff; }
  .obj { grid-template-columns: 1fr 1fr; }
}

/* Cormorant defaults to old-style figures; stats read better with lining numerals */
.kpi b, .stat b, .page-head h1, .obj h1 { font-variant-numeric: lining-nums; }

/* ==========================================================================
   Inline icons in text (e.g. the "staff only" lock) stay text-sized
   ========================================================================== */
.hint svg, .eyebrow svg, h2 > svg, h3 > svg { width: 14px; height: 14px; vertical-align: -2px; flex: none; }

/* ==========================================================================
   Museum-branded sites (a profile in app/sites/). Colours come from the
   profile as CSS variables; these rules add the layout touches.
   ========================================================================== */
.has-brand body { background: var(--paper); }
.has-brand .site-header { background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; border-bottom-color: var(--line); }
.has-brand .site-header.is-scrolled { box-shadow: 0 6px 20px -14px rgba(31, 39, 51, .35); }

.brand-text { display: grid; line-height: 1.15; min-width: 0; }
.brand-title { font-family: var(--serif); font-size: 21px; font-weight: 600; color: var(--navy); letter-spacing: -.005em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-powered { font-size: 10.5px; color: var(--faint); letter-spacing: .02em; margin-top: 1px; }
.brand-powered b { font-weight: 600; color: var(--muted); }
.brand-text.lg .brand-title { font-size: 28px; white-space: normal; }
.brand-text.lg .brand-powered { font-size: 12px; }
.lang-card .top .brand-text { text-align: center; justify-items: center; }
.auth-logo .brand-text { justify-items: start; }
.foot-brand .brand-title { font-size: 18px; }

/* Photo hero, in the style of the museum's own website */
.hero-photo { position: relative; min-height: min(56vh, 480px); display: flex; align-items: flex-end; color: #fff;
  background: #22486e var(--hero-lg) center 45% / cover no-repeat; }
.hero-photo::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 22, 38, .35) 0%, rgba(10, 22, 38, 0) 30%, rgba(10, 22, 38, .15) 55%, rgba(10, 22, 38, .72) 100%); }
.hero-photo-inner { position: relative; width: 100%; padding-top: 96px; padding-bottom: 56px; }
.hero-photo h1 { font-family: var(--sans); font-weight: 500; font-size: clamp(28px, 3.3vw, 44px); line-height: 1.14; letter-spacing: -.02em; margin: 0 0 12px; max-width: 900px; color: #fff; text-shadow: 0 2px 20px rgba(0,0,0,.25); }
.hero-photo p { font-size: clamp(14px, 1.05vw, 15.5px); line-height: 1.6; max-width: 600px; margin: 0; color: rgba(255,255,255,.94); text-shadow: 0 1px 12px rgba(0,0,0,.3); }
.hero-under { padding: clamp(36px, 5vw, 56px) 0; text-align: center; }
.hero-under .hero-search { max-width: 820px; margin: 0 auto; }
.hero-under .hero-search > :not(.seg-top) { text-align: left; }
.hero-under .seg-top { background: #fff; }
.hero-under .popular { display: flex; align-items: center; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 16px; font-size: 13px; color: var(--muted); }
.hero-under .popular a { color: var(--ink-2); border-bottom: 1px solid var(--line-2); }
.hero-under .popular a:hover { color: var(--navy); border-color: var(--navy); }
.hero-under .stats { margin-top: 30px; justify-content: center; }
@media (max-width: 720px) {
  .hero-photo { background-image: var(--hero-sm); min-height: 380px; }
  .hero-photo-inner { padding-bottom: 36px; }
  .brand-title { font-size: 16px; max-width: 58vw; }
}

/* "Image coming soon" placeholders */
.ph.ph-soon { background: #e9ebef; container-type: size; }
.ph.ph-soon::before { display: none; }
.ph-soon span { font-size: 12.5px; font-weight: 500; letter-spacing: .02em; color: #6b7280; text-align: center; padding: 0 10px; }
@container (max-width: 90px) { .ph-soon span { display: none; } }
.stage .ph-soon span { font-size: 15px; }
.art:has(.ph-soon), .stage:has(.ph-soon), .thumb:has(.ph-soon) { background: #e9ebef; }

/* Pastel category tints for branded sites: blue, red and yellow in turn */
.has-brand .ic.tint-built, .has-brand .ic.tint-materials, .has-brand .ic.tint-distribution, .has-brand .ic.tint-unclassified { background: var(--tint-blue); color: var(--navy); }
.has-brand .ic.tint-furnishings, .has-brand .ic.tint-commtools, .has-brand .ic.tint-recreational { background: var(--tint-yellow); color: #8a7300; }
.has-brand .ic.tint-personal, .has-brand .ic.tint-science, .has-brand .ic.tint-communication { background: var(--tint-red); color: var(--terracotta); }
.has-brand .band { background: var(--tint-blue); }
.has-brand .band .eyebrow { color: var(--terracotta); }
.has-brand .band::after { border-color: rgba(38, 86, 143, .3); }
.has-brand .story { background: var(--tint-yellow); border-color: #f1e6a6; }

/* Art collections: artist line on cards and the record page, category tints */
.card .alt.artist { font-style: normal; color: var(--ink-2); }
.artist-name { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 6px 0 4px; font-size: 18px; }
.artist-name a { color: var(--ink); font-weight: 600; border-bottom: 1px solid var(--line-2); }
.artist-name a:hover { border-color: currentColor; }
.artist-name span { color: var(--muted); font-size: 14.5px; }
.has-brand .ic.tint-figurative, .has-brand .ic.tint-photography { background: var(--tint-blue); color: var(--ink); }
.has-brand .ic.tint-street-art { background: var(--tint-red); color: var(--teal); }
.has-brand .ic.tint-abstract { background: var(--tint-yellow); color: var(--teal); }
