/* Deux Engineering catalog. One set of tokens, light and dark (data-theme on <html>, set before first paint from the
   visitor's choice or the system). Warm neutrals, one coral accent used sparingly, system fonts, quiet borders. */
:root {
  --bg: #fbfaf8; --panel: #ffffff; --sunk: #f4f2ef; --chip: #f2f0ed;
  --ink: #1c1917; --ink2: #57534e; --ink3: #78716c; --line: #e7e4df; --line2: #d6d3cd;
  --accent: #e4572e; --accent-hover: #c8461f; --accent-ink: #ffffff; --accent-soft: #fdeee8; --ok: #2f855a;
  --logo-ink: #ffffff; --card-img: #f3f1ee;
  --shadow: 0 1px 2px rgba(28, 25, 23, .05); --shadow-hi: 0 12px 32px rgba(28, 25, 23, .10), 0 2px 6px rgba(28, 25, 23, .05);
  --r: 10px; --r-lg: 14px; --w: 1240px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji";
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0f0e0d; --panel: #171615; --sunk: #1c1b19; --chip: #22201e;
  --ink: #f5f4f2; --ink2: #b8b3ad; --ink3: #8f8a84; --line: #2a2826; --line2: #3a3734;
  --accent: #ff8a5c; --accent-hover: #ffa47f; --accent-ink: #1f0c04; --accent-soft: #2e1810; --ok: #68d391;
  --logo-ink: #171615; --card-img: #1a1917;
  --shadow: none; --shadow-hi: 0 16px 40px rgba(0, 0, 0, .55);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100dvh; display: flex; flex-direction: column; background: var(--bg); color: var(--ink); font: 15px/1.55 var(--font); overflow-x: clip; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -.015em; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: var(--accent-ink); padding: 6px 12px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
main:focus-visible { outline: none; }   /* focused after navigation for screen readers only */
.tm { display: none; }

/* ---------------------------------------------------------------- header */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
.top-in { max-width: var(--w); margin: 0 auto; padding: 0 24px; height: 62px; display: flex; gap: 22px; align-items: center; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--accent); flex: none; }
.logo svg { width: 28px; height: 28px; }
.logo span { color: var(--ink); font-size: 16.5px; letter-spacing: -.01em; white-space: nowrap; }
.logo b { font-weight: 750; }
.nav { display: flex; gap: 2px; align-items: center; }
.nav > a, .cats-menu summary { padding: 7px 11px; border-radius: 8px; font-weight: 550; font-size: 14.5px; color: var(--ink2); cursor: pointer; list-style: none; transition: color .15s, background .15s; }
.nav > a:hover, .cats-menu summary:hover, .cats-menu[open] summary { color: var(--ink); background: var(--chip); }
.cats-menu { position: relative; }
.cats-menu summary::-webkit-details-marker { display: none; }
.cats-menu summary::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-3px) rotate(45deg); opacity: .6; }
.menu { position: absolute; left: 0; top: calc(100% + 8px); background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-hi); padding: 6px; width: 520px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 2px; }
.menu a { display: flex; justify-content: space-between; gap: 12px; padding: 7px 10px; border-radius: 8px; font-size: 14px; color: var(--ink2); }
.menu a:hover { background: var(--chip); color: var(--ink); }
.menu a span { color: var(--ink3); font-variant-numeric: tabular-nums; font-size: 13px; }
.qbox { position: relative; flex: 1; max-width: 420px; margin-left: auto; display: flex; align-items: center; }
.qbox > svg { position: absolute; left: 12px; width: 16px; height: 16px; color: var(--ink3); pointer-events: none; }
.qbox input { width: 100%; height: 38px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); padding: 0 40px 0 36px; outline: none; font-size: 14.5px; transition: border-color .15s, box-shadow .15s; }
.qbox input::placeholder { color: var(--ink3); }
.qbox input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }
.qbox input::-webkit-search-cancel-button { display: none; }
.qbox kbd { position: absolute; right: 10px; font: 11.5px var(--mono); color: var(--ink3); border: 1px solid var(--line); border-radius: 5px; padding: 0 6px; background: var(--sunk); }
.sugg { position: absolute; top: 46px; left: 0; right: 0; margin: 0; padding: 6px; list-style: none; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-hi); max-height: 70vh; overflow: auto; }
.sugg li { display: flex; gap: 10px; align-items: center; padding: 6px 8px; border-radius: 8px; cursor: pointer; }
.sugg li[aria-selected="true"], .sugg li:hover { background: var(--chip); }
.sugg img { width: 38px; height: 38px; border-radius: 7px; background: var(--card-img); flex: none; }
.sugg .s-t { display: flex; flex-direction: column; min-width: 0; }
.sugg .s-t b { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sugg .s-t span { font-size: 12.5px; color: var(--ink3); }
.sugg .s-all { color: var(--accent); font-weight: 600; justify-content: center; }
.top-end { display: flex; align-items: center; gap: 8px; flex: none; }
.top-end .qbtn, .top-end .mnav { display: none; }
.mnav { position: relative; }
.mnav summary { list-style: none; }
.mnav summary::-webkit-details-marker { display: none; }
.mnav-panel { position: fixed; left: 12px; right: 12px; top: 62px; max-height: calc(100dvh - 80px); overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-hi); padding: 8px; display: grid; gap: 2px; }
.mnav-panel > a { padding: 10px 12px; border-radius: 8px; font-weight: 600; }
.mnav-panel > a:hover { background: var(--chip); }
.mnav-panel h4 { margin: 10px 12px 4px; font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); }
.mnav-panel #mnav-cats { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; }
.mnav-panel #mnav-cats a { display: flex; justify-content: space-between; gap: 8px; padding: 8px 12px; border-radius: 8px; font-size: 14px; color: var(--ink2); }
.mnav-panel #mnav-cats a span { color: var(--ink3); font-size: 12.5px; }
.icon-btn { width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--ink2); cursor: pointer; padding: 0; transition: color .15s, border-color .15s; }
.icon-btn:hover { color: var(--ink); border-color: var(--line2); }
.icon-btn svg { width: 17px; height: 17px; }
.acct { height: 38px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 9px; background: var(--ink); color: var(--panel); font-weight: 600; font-size: 14px; white-space: nowrap; transition: opacity .15s; }
.acct:hover { opacity: .86; }

main { flex: 1; width: 100%; max-width: var(--w); margin: 0 auto; padding: 28px 24px 72px; outline: none; }
.loading { height: 60vh; }
.foot { border-top: 1px solid var(--line); color: var(--ink3); font-size: 13.5px; }
.foot-in { max-width: var(--w); margin: 0 auto; padding: 28px 24px 36px; display: flex; align-items: center; gap: 12px 28px; flex-wrap: wrap; }
.foot-brand { color: var(--ink); font-size: 14.5px; }
.foot-brand b { font-weight: 750; }
.foot nav { display: flex; gap: 20px; }
.foot nav a:hover { color: var(--ink); }
.foot-note { margin-left: auto; }
.nojs { text-align: center; padding: 30px; }

/* ---------------------------------------------------------------- buttons, tags */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 9px; border: 1px solid var(--line2);
  background: var(--panel); color: var(--ink); font-weight: 600; font-size: 14.5px; cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, color .15s; }
.btn:hover { border-color: var(--ink3); }
.btn:active { transform: translateY(1px); }
.btn.pri { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.pri:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn small { font-weight: 500; color: inherit; opacity: .8; }
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 550; color: var(--ink2); background: var(--chip); border-radius: 6px; padding: 2px 8px; white-space: nowrap; }
.tag.ok { color: var(--ok); background: color-mix(in srgb, var(--ok) 11%, transparent); }
.tag.acc { color: var(--ink2); background: var(--chip); }
.linkbtn { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; cursor: pointer; }
.note { background: var(--panel); border: 1px dashed var(--line2); border-radius: var(--r); padding: 14px 16px; color: var(--ink2); margin-bottom: 14px; }

/* ---------------------------------------------------------------- sections */
.sec { margin-top: 56px; }
.sec-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.sec-h h2 { font-size: 21px; font-weight: 700; }
.sec-h a { color: var(--ink2); font-weight: 550; font-size: 14px; white-space: nowrap; }
.sec-h a:hover { color: var(--accent); }

/* ---------------------------------------------------------------- home */
.hero2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding: clamp(12px, 3vw, 36px) 0 8px; }
.hero2-tx { display: grid; gap: 18px; justify-items: start; }
.kicker { font-size: 13px; font-weight: 600; color: var(--accent); }
.hero2 h1 { margin: 0; font-size: clamp(34px, 4.4vw, 54px); line-height: 1.04; letter-spacing: -.035em; font-weight: 750; }
.hero2 h1 em { font-style: normal; color: var(--accent); }
.hero2 p { margin: 0; color: var(--ink2); font-size: 17px; max-width: 470px; }
.hero2-cta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.hero2-cta .btn { height: 46px; padding: 0 22px; font-size: 15px; }
.hero2-trust { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 13.5px; color: var(--ink3); }
.hero2-trust li::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); margin-right: 8px; transform: translateY(-2px); }
.reel { margin: 0; display: grid; gap: 10px; }
.reel-play, .reel-v { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; padding: 0; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #0a0a0c; }
.reel-play { cursor: pointer; }
.reel-play img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.reel-play:hover img { transform: scale(1.02); }
.reel-btn { position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .94); color: #111; box-shadow: 0 6px 24px rgba(0, 0, 0, .3); transition: transform .2s; }
.reel-btn svg { width: 22px; height: 22px; margin-left: 3px; }
.reel-play:hover .reel-btn { transform: scale(1.06); }
.reel-play:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.reel figcaption { display: flex; justify-content: space-between; gap: 10px; padding: 0 2px; font-size: 13.5px; color: var(--ink3); }
.reel figcaption b { color: var(--ink); font-weight: 600; }
.reel figcaption { align-items: center; flex-wrap: wrap; }
.film-tabs { display: inline-flex; padding: 3px; gap: 2px; background: var(--chip); border-radius: 9px; }
.film-tabs button { border: 0; background: transparent; padding: 5px 12px; border-radius: 7px; font-size: 13px; font-weight: 600; color: var(--ink2); cursor: pointer; }
.film-tabs button:hover { color: var(--ink); }
.film-tabs button[aria-pressed="true"] { background: var(--panel); color: var(--ink); box-shadow: var(--shadow); }
.film-sub { margin-left: auto; }
.show-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.show-pitch { align-self: center; display: grid; gap: 12px; justify-items: start; max-width: 420px; padding: 8px 8px 30px; }
.show-pitch h3 { font-size: 24px; font-weight: 700; letter-spacing: -.02em; }
.show-pitch p { margin: 0; color: var(--ink2); font-size: 16px; }
.show-pitch .btn { margin-top: 4px; }
.cat-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(214px, 1fr)); gap: 10px; }
.cat-tile { display: flex; align-items: center; gap: 12px; padding: 10px 14px 10px 10px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); transition: border-color .15s, background .15s; }
.cat-tile:hover { border-color: var(--line2); background: var(--sunk); }
.cat-tile img { width: 44px; height: 44px; border-radius: 8px; background: var(--card-img); flex: none; }
.cat-tile b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-weight: 600; font-size: 14px; line-height: 1.3; }
.cat-tile > div { min-width: 0; }
.cat-tile span { font-size: 12.5px; color: var(--ink3); }
.pop { display: none; }

/* ---------------------------------------------------------------- cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(208px, 1fr)); gap: 22px 18px; }
.card { display: flex; flex-direction: column; gap: 10px; }
.card .im { position: relative; aspect-ratio: 1; background: var(--card-img); border-radius: var(--r-lg); overflow: hidden; border: 1px solid transparent; transition: border-color .15s; }
.card:hover .im { border-color: var(--line2); }
.card .im img { width: 100%; height: 100%; object-fit: contain; padding: 8%; transition: transform .3s ease; }
.card:hover .im img { transform: scale(1.04); }
.card .pn { position: absolute; left: 10px; top: 9px; font: 500 11.5px var(--mono); color: var(--ink2); opacity: .8; }
.card .bd { display: flex; flex-direction: column; gap: 1px; padding: 0 2px; }
.card h3 { font-size: 14.5px; font-weight: 600; letter-spacing: -.005em; }
.card:hover h3 { color: var(--accent); }
.card .cat { font-size: 13px; color: var(--ink3); }
.card .meta { display: none; }
.grid.row { grid-template-columns: repeat(5, minmax(0, 1fr)); }

/* ---------------------------------------------------------------- search / category listing */
.layout { display: grid; grid-template-columns: 220px 1fr; gap: 40px; align-items: start; }
.filters { position: sticky; top: 90px; display: flex; flex-direction: column; gap: 26px; font-size: 14px; max-height: calc(100vh - 110px); overflow: auto; padding-right: 4px; }
.filters h4 { margin: 0 0 8px; font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); }
.fopt { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 5px 9px; margin: 0 -9px; border-radius: 7px; cursor: pointer; color: var(--ink2); }
.fopt:hover { background: var(--chip); color: var(--ink); }
.fopt.on { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.fopt span { font-size: 12.5px; color: var(--ink3); font-variant-numeric: tabular-nums; }
.fopt.on span { color: inherit; }
.fopt.zero:not(.on) { display: none; }
.filters > div:not(:has(.fopt:not(.zero))) { display: none; }
.res-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.res-h h1 { font-size: 26px; font-weight: 700; letter-spacing: -.02em; }
.res-h .count { color: var(--ink3); font-size: 14px; margin-top: 4px; }
.res-h select { height: 40px; border: 1px solid var(--line2); border-radius: 9px; background: var(--panel); padding: 0 10px; font-weight: 600; font-size: 14px; }
.active { display: flex; gap: 6px; flex-wrap: wrap; margin: -6px 0 18px; }
.active a { font-size: 13px; background: var(--accent-soft); color: var(--accent); border-radius: 999px; padding: 3px 11px; font-weight: 550; }
.active a::after { content: " ✕"; font-size: 10.5px; }
.more { display: flex; justify-content: center; margin-top: 32px; }
.ftoggle { display: none; }

/* ---------------------------------------------------------------- model page */
.crumbs { font-size: 13.5px; color: var(--ink3); margin-bottom: 18px; display: flex; gap: 8px; flex-wrap: wrap; }
.crumbs a:hover { color: var(--ink); }
.model { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(320px, 1fr); gap: 48px; align-items: start; }
.gallery { background: var(--card-img); border-radius: 18px; aspect-ratio: 1; overflow: hidden; position: sticky; top: 90px; }
.gallery img { width: 100%; height: 100%; object-fit: contain; padding: 5%; }
.info { display: flex; flex-direction: column; gap: 20px; }
.info .pn { font: 500 12.5px var(--mono); color: var(--ink3); }
.info h1 { font-size: clamp(28px, 3.2vw, 38px); letter-spacing: -.03em; font-weight: 750; margin-top: -10px; }
.info .lede { color: var(--ink2); font-size: 16.5px; margin: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags a { font-size: 13px; background: var(--chip); color: var(--ink2); border-radius: 999px; padding: 3px 11px; }
.tags a:hover { color: var(--ink); }
.cta { display: flex; gap: 10px; flex-wrap: wrap; }
.cta .btn { flex: 1 1 200px; height: 48px; font-size: 15px; }
.lic { margin: -8px 0 0; font-size: 13px; color: var(--ink3); }
.lic a, .doc a { color: var(--accent); }
.panel { border-top: 1px solid var(--line); padding: 18px 0 0; }
.panel h2 { font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); margin-bottom: 12px; }
.panel h2 .tag { text-transform: none; letter-spacing: 0; }
.panel p { margin: 0; color: var(--ink2); }
.specs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 24px; }
.specs div { display: flex; flex-direction: column; }
.specs span { font-size: 12.5px; color: var(--ink3); }
.specs b { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.files { display: flex; flex-direction: column; gap: 8px; }
.file { display: flex; align-items: flex-start; gap: 12px; padding: 10px 12px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); }
.file i { width: 12px; height: 12px; border-radius: 4px; flex: none; margin-top: 4px; }
.file a { align-self: center; }
.file div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.file b { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file span { font-size: 12.5px; color: var(--ink3); }
.file a { font-weight: 600; color: var(--accent); white-space: nowrap; font-size: 13.5px; }
.loads { display: flex; flex-direction: column; gap: 6px; }
.loads a { display: flex; justify-content: space-between; gap: 12px; padding: 9px 12px; border-radius: var(--r); border: 1px solid var(--line); background: var(--panel); font-size: 14px; }
.loads a:hover { border-color: var(--line2); background: var(--sunk); }
.loads a span { color: var(--ink3); font-size: 13px; text-align: right; }
.groups { display: flex; flex-wrap: wrap; gap: 6px; }
.about .clamp { display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.about .clamp.open { display: block; }
.about [data-more] { margin-top: 8px; font-size: 14px; font-weight: 600; }
.err { text-align: center; padding: 90px 20px; color: var(--ink2); }
.err h1 { font-size: 28px; margin-bottom: 8px; color: var(--ink); }
/* colour changer under the picture */
.paint { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 14px; font-size: 13px; color: var(--ink3); }
.paint > span { margin-right: 6px; }
.paint button, .paint-custom { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--bg); background: var(--c); cursor: pointer; box-shadow: 0 0 0 1px var(--line2); padding: 0; position: relative; transition: transform .12s; }
.paint button:hover { transform: scale(1.12); }
.paint button[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--ink); }
.paint-custom { display: grid; place-items: center; background: conic-gradient(red, yellow, lime, cyan, blue, magenta, red); overflow: hidden; }
.paint-custom input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.paint-custom span { color: #fff; font-weight: 700; text-shadow: 0 0 2px #000; pointer-events: none; }

/* ---------------------------------------------------------------- documents (license, privacy) */
.doc { max-width: 720px; margin: 8px auto 0; }
.doc h1 { margin: 0 0 8px; font-size: clamp(28px, 3.4vw, 38px); letter-spacing: -.03em; font-weight: 750; }
.doc h2 { margin: 32px 0 10px; font-size: 19px; }
.doc p, .doc li { color: var(--ink2); font-size: 16px; }
.doc ul { padding-left: 20px; margin: 0; display: grid; gap: 7px; }
.doc b { color: var(--ink); }
.doc-sub { font-size: 14px !important; color: var(--ink3) !important; }

/* ---------------------------------------------------------------- My saved settings */
.me { max-width: 820px; margin: 8px auto 0; }
.me .sec-h h1 { margin: 0; font-size: 28px; font-weight: 750; letter-spacing: -.025em; }
.me .sec-h .count { color: var(--ink3); font-weight: 500; font-size: 18px; }
.me-who { color: var(--ink3); font-size: 14px; }
.tpls { display: grid; gap: 8px; margin-top: 8px; }
.tpl { display: flex; align-items: center; gap: 14px; padding: 10px 12px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); }
.tpl img, .tpl > i { width: 56px; height: 56px; border-radius: 10px; background: var(--card-img); flex: none; object-fit: contain; }
.tpl-t { flex: 1; min-width: 0; display: grid; }
.tpl-t b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tpl-t span { color: var(--ink3); font-size: 13.5px; }
.tpl .btn { height: 36px; padding: 0 13px; font-size: 13.5px; }
.me-danger { margin-top: 32px; font-size: 13.5px; }
.me-danger .linkbtn { color: var(--ink3); }
.me-out { max-width: 560px; margin: 40px auto 0; text-align: center; display: grid; gap: 12px; justify-items: center; }
.me-out h1 { font-size: 30px; font-weight: 750; letter-spacing: -.025em; }
.me-out p { color: var(--ink2); margin: 0; }
.me-out .cta { justify-content: center; margin-top: 8px; width: 100%; }
.me-out .cta .btn { flex: 0 1 220px; }
.me-out .tpl.ghost { max-width: 420px; margin-top: 20px; text-align: left; }
.me-out .doc-sub { margin: 0; }
.me-empty { display: grid; gap: 14px; justify-items: start; margin-top: 8px; }
.me-empty p { margin: 0; color: var(--ink2); }
.tpl.ghost { width: 100%; opacity: .55; border-style: dashed; pointer-events: none; }
/* owner message queue */
.notes-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-bottom: 14px; }
.notes-list:empty { display: none; }
figure.note { margin: 0; padding: 14px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); }
.note blockquote { margin: 0 0 8px; font-size: 15px; line-height: 1.45; color: var(--ink); }
.note figcaption { font-size: 13px; color: var(--ink3); }
.note figcaption a { color: var(--accent); }
.nq { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; margin-bottom: 8px; }

/* ---------------------------------------------------------------- owner dashboard (/admin) */
.adm .sec-h .chips { display: flex; gap: 6px; }
.adm .chips a { padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink2); font-size: 14px; background: var(--panel); }
.adm .chips a.on { background: var(--ink); border-color: var(--ink); color: var(--panel); }
.adm-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 6px 0 16px; }
.adm-tile { display: block; padding: 14px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); color: var(--ink); }
.adm-tile b { display: block; font-size: 26px; line-height: 1.1; font-weight: 700; font-variant-numeric: tabular-nums; }
.adm-tile span { font-size: 13px; color: var(--ink3); }
a.adm-tile:hover { border-color: var(--line2); }
.adm-chart-box { position: relative; }
.adm-chart { width: 100%; height: auto; display: block; margin: 6px 0; }
.adm-bar { fill: var(--accent); }
.adm-bar.on { fill: var(--accent-hover); }
.adm-hit { fill: transparent; cursor: default; }
.adm-grid { stroke: var(--line); stroke-dasharray: 3 4; }
.adm-base { stroke: var(--line); }
.adm-axis { font-size: 11px; fill: var(--ink3); font-variant-numeric: tabular-nums; }
.adm-tip { position: absolute; top: 44px; width: 180px; padding: 8px 10px; background: var(--ink); color: var(--panel); border-radius: 8px; font-size: 12.5px; pointer-events: none; box-shadow: var(--shadow-hi); }
.adm-tip b, .adm-tip span { display: block; }
.adm-days { width: 100%; border-collapse: collapse; font-size: 13px; font-variant-numeric: tabular-nums; margin-top: 8px; }
.adm-days th, .adm-days td { text-align: right; padding: 5px 8px; border-bottom: 1px solid var(--line); }
.adm-days th:first-child, .adm-days td:first-child { text-align: left; }
.adm-grid2 { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 12px; margin-top: 12px; }
.adm-rank table { width: 100%; border-collapse: collapse; font-size: 14px; }
.adm-rank td { padding: 6px 0; border-bottom: 1px solid var(--line); }
.adm-rank td:last-child { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink2); width: 70px; }
.adm-empty, .adm-note { color: var(--ink3); font-size: 13px; }
.adm .panel { border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; background: var(--panel); }

/* ---------------------------------------------------------------- ads: labelled, height reserved (no layout jump) */
.ad { margin: 48px auto 0; max-width: 970px; min-height: 120px; display: grid; gap: 4px; }
.ad.in-grid { grid-column: 1 / -1; margin: 4px 0; max-width: none; }
.ad-l { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink3); }
@media (min-width: 761px) { .ad { min-height: 250px; } }
.consent { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 50; max-width: 720px; margin: 0 auto; display: flex; gap: 14px; align-items: center;
  justify-content: space-between; flex-wrap: wrap; padding: 14px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-hi); }
.consent p { margin: 0; font-size: 14px; color: var(--ink2); flex: 1 1 300px; }
.consent div { display: flex; gap: 8px; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1080px) { .menu { width: 420px; } .qbox { max-width: 300px; } }
@media (max-width: 960px) {
  .model { grid-template-columns: 1fr; gap: 28px; }
  .gallery { position: static; }
  .layout { grid-template-columns: 1fr; gap: 16px; }
  .filters { position: static; display: none; max-height: none; }
  .filters.open { display: flex; }
  .ftoggle { display: inline-flex; height: 40px; font-size: 14px; }
  .hero2 { grid-template-columns: 1fr; }
  .grid.row { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(170px, 42%); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; }
  .grid.row > * { scroll-snap-align: start; content-visibility: visible; }   /* "auto" leaves cards in a sideways row unpainted */
}
@media (max-width: 760px) {
  .top-in { flex-wrap: wrap; height: 56px; gap: 8px; padding: 0 16px; }
  .top.qopen .top-in { height: auto; padding-bottom: 10px; }
  .nav { display: none; }
  .top-end { margin-left: auto; gap: 6px; }
  .top-end .qbtn, .top-end .mnav { display: grid; }
  .acct { display: none; }
  .qbox { display: none; order: 3; flex-basis: 100%; max-width: none; margin: 0; }
  .top.qopen .qbox { display: flex; }
  .qbox kbd { display: none; }
  .mnav-panel { top: 60px; }
  main { padding: 20px 16px 56px; }
  .sec { margin-top: 40px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
  .grid.row { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); overflow: visible; }
  .grid.row > :nth-child(n+5) { display: none; }
  .cat-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .cat-tile { padding: 8px 10px 8px 8px; gap: 10px; }
  .cat-tile img { width: 36px; height: 36px; }
  .cat-tile b { font-size: 14px; }
  .show-row { grid-template-columns: minmax(0, 1fr); }
  .loads a { flex-direction: column; gap: 2px; }
  .file { flex-wrap: wrap; }
  .file a { flex-basis: 100%; padding-left: 24px; align-self: flex-start; }
  .loads a span { text-align: left; }
  .foot-in { padding: 24px 16px 32px; }
  .foot-note { margin-left: 0; }
  .hero2 h1 { font-size: 38px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
