/* Window edition: the frame, the type, and the motion change together.
   Loops pause for lite mode, an idle page, and reduced motion.
   A sheet still plays its entrance unless motion is off. */

.tm-folio {
  --t-bg: #dcc9a4; --t-card-solid: #f7edd8; --t-ink: #241910; --t-muted: #4a3828;
  --t-line: #8c704c; --t-accent: #8e2e24; --t-accent-ink: #fff8f2; --t-accent2: #1f5c45;
  --t-theirs: #fff4b8; --t-mine: #d7efd4; --t-mine-ink: #142418;
  --t-danger: #8e2e24; --t-admin: #6e4a08; --t-scheme: light;
  --t-display: "Fraunces", Georgia, serif; --t-display-weight: 560; --t-h1: 30px; --t-h1-track: -.02em;
  --t-tech: "Inter", system-ui, sans-serif; --t-body: Georgia, "Times New Roman", serif;
  --t-tabfont: "Inter", system-ui, sans-serif;
  --t-radius: 0 14px 12px 12px; --t-btn-radius: 2px;
  --t-input: #fffaf0; --t-btn: #8e2e24; --t-btn-ink: #fff8f2;
  --t-wall: radial-gradient(#6b543028 1px, transparent 1.5px) 0 0 / 5px 5px, linear-gradient(165deg, #e6d7b8, #dcc9a4 46%, #c9b48a);
  --t-card-shadow: 4px 5px 0 #00000018;
  --ui-sample-bg: #c9b48a;
}
.tm-reticle {
  --t-bg: #070c14; --t-card-solid: #121a28; --t-ink: #e9f4ff; --t-muted: #b7c9dc;
  --t-line: #3d536c; --t-accent: #ffc14a; --t-accent-ink: #1c1404; --t-accent2: #7ad7ff;
  --t-theirs: #1a2838; --t-mine: #1a4d62; --t-mine-ink: #f3fbff;
  --t-danger: #ffb0a0; --t-admin: #ffd27a; --t-scheme: dark;
  --t-display: "Orbitron", system-ui, sans-serif; --t-display-weight: 600; --t-h1: 20px; --t-h1-track: .04em;
  --t-tech: "Chakra Petch", system-ui, sans-serif; --t-body: "Inter", system-ui, sans-serif;
  --t-tabfont: "Chakra Petch", system-ui, sans-serif;
  --t-radius: 0; --t-btn-radius: 0;
  --t-input: #0b121c; --t-btn: #ffc14a; --t-btn-ink: #1c1404;
  --t-wall: linear-gradient(rgba(122, 215, 255, .16) 1px, transparent 1px) 0 0 / 46px 46px, linear-gradient(90deg, rgba(122, 215, 255, .12) 1px, transparent 1px) 0 0 / 46px 46px, radial-gradient(ellipse at 50% 38%, #123044, #070c14 68%);
  --t-card-shadow: none;
  --win-cut: polygon(12px 0, calc(100% - 12px) 0, 100% 12px, 100% calc(100% - 12px), calc(100% - 12px) 100%, 12px 100%, 0 calc(100% - 12px), 0 12px);
  --ui-sample-bg: #070c14;
}
.tm-playbill {
  --t-bg: #14080d; --t-card-solid: #2a1218; --t-ink: #fff3e6; --t-muted: #f0cfc4;
  --t-line: #6a4038; --t-accent: #ffe08a; --t-accent-ink: #2a1804; --t-accent2: #ff5d78;
  --t-theirs: #3a1822; --t-mine: #ffe3a6; --t-mine-ink: #2a1608;
  --t-danger: #ffb0a0; --t-admin: #ffe08a; --t-scheme: dark;
  --t-display: "Bebas Neue", "Arial Narrow", sans-serif; --t-display-weight: 400; --t-h1: 40px; --t-h1-track: .03em;
  --t-tech: "Inter", system-ui, sans-serif; --t-body: "Inter", system-ui, sans-serif;
  --t-tabfont: "Inter", system-ui, sans-serif;
  --t-radius: 2px; --t-btn-radius: 3px;
  --t-input: #1a0c12; --t-btn: #ffe08a; --t-btn-ink: #2a1804;
  --t-wall: radial-gradient(ellipse 55% 42% at 50% 0%, rgba(255, 224, 138, .28), transparent 70%), repeating-linear-gradient(90deg, #1c0c12 0 22px, #12080c 22px 44px);
  --t-card-shadow: 0 16px 0 #00000040;
  --ui-sample-bg: #10060a;
}
.tm-sonar {
  --t-bg: #041318; --t-card-solid: #0d242c; --t-ink: #e8fff6; --t-muted: #b7ddd2;
  --t-line: #1d4a44; --t-accent: #7dffa8; --t-accent-ink: #042014; --t-accent2: #8fd4ff;
  --t-theirs: #12383a; --t-mine: #145246; --t-mine-ink: #e9fff6;
  --t-danger: #ffb0a0; --t-admin: #ffe0a0; --t-scheme: dark;
  --t-display: "Chakra Petch", system-ui, sans-serif; --t-display-weight: 700; --t-h1: 26px; --t-h1-track: .01em;
  --t-tech: "Chakra Petch", system-ui, sans-serif; --t-body: "Inter", system-ui, sans-serif;
  --t-tabfont: "Chakra Petch", system-ui, sans-serif;
  --t-radius: 22px; --t-btn-radius: 999px;
  --t-input: #071910; --t-btn: #7dffa8; --t-btn-ink: #042014;
  --t-wall: repeating-radial-gradient(circle at 50% 46%, transparent 0 54px, rgba(125, 255, 168, .2) 54px 56px), radial-gradient(circle at 50% 46%, #0c3a3a, #041318 62%);
  --t-card-shadow: inset 0 0 0 1px #7dffa855, 0 10px 28px #00000055;
  --ui-sample-bg: #041318;
}

:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) {
  --t-card: var(--t-card-solid); --t-tabs: var(--t-card-solid); --t-sheet: var(--t-card-solid);
  --t-header: var(--t-card-solid); --t-sec: var(--t-ink); --t-link: var(--t-accent);
  --t-blur: none; --t-title: none;
  --t-wall-wide: var(--t-wall); --t-veil: none; --t-veil-wide: none;
  --t-pattern: none;
}

html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) body { -webkit-font-smoothing: antialiased; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) :is(.card, .sheet, .toc, .appban, #toast, .sendbar, .mu-player) {
  -webkit-backdrop-filter: none; backdrop-filter: none;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) :is(header.top h1, .appban .ab-name, .appban .ab-tag) {
  color: var(--t-ink); background: none; filter: none; text-shadow: none;
  -webkit-background-clip: border-box; background-clip: border-box; -webkit-text-fill-color: currentColor;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban .ab-art { display: none; animation: none; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban { min-height: 0; overflow: hidden; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban .ab-text { min-width: 0; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban .ab-name {
  font-family: var(--t-display); font-weight: var(--t-display-weight); letter-spacing: var(--t-h1-track); line-height: 1;
  white-space: normal; overflow-wrap: anywhere;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban .ab-tag {
  font-family: var(--t-body); color: var(--t-muted); opacity: 1;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban .ab-ic {
  display: grid; place-items: center; background: var(--t-accent); box-shadow: none; border-radius: var(--t-btn-radius);
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .appban .ab-ic::after {
  content: ""; width: 46%; height: 46%; background: var(--t-btn-ink);
  -webkit-mask: var(--icm) center / contain no-repeat; mask: var(--icm) center / contain no-repeat;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) #app > header.top h1::before {
  background: var(--t-accent); box-shadow: none; border-radius: 2px;
  -webkit-mask: var(--icm) center / 72% no-repeat; mask: var(--icm) center / 72% no-repeat;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .section-title {
  font-family: var(--t-display); font-weight: var(--t-display-weight); letter-spacing: var(--t-h1-track);
  text-transform: none; color: var(--t-ink); font-size: 1.15rem;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) #tabs a .ic {
  width: 1.2rem; height: 1.2rem; background: currentColor; box-shadow: none; opacity: 1;
  transform: none; border-radius: 0; filter: none;
  -webkit-mask: var(--icm) center / contain no-repeat; mask: var(--icm) center / contain no-repeat;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) #tabs a.on .ic { transform: none; box-shadow: none; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) :is(.btn, .appban .ab-theme, .appban .ab-work, .toc-btn) {
  font-family: var(--t-tech); background: var(--t-btn); color: var(--t-btn-ink);
  border-radius: var(--t-btn-radius); box-shadow: none; filter: none;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) :is(.btn.ghost, .appban .ab-theme, .appban .ab-work) {
  background: transparent; color: var(--t-ink);
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .btn.danger {
  background: var(--t-danger); color: #2a0c08;
}
html.tm-folio .btn.danger { color: #fff8f2; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) :is(input[type=text], input[type=search], input[type=password], textarea, .select) {
  background: var(--t-input); color: var(--t-ink); border-radius: var(--t-btn-radius); box-shadow: none;
}
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) :is(input, textarea)::placeholder { color: var(--t-muted); opacity: 1; }
html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) #toast {
  background: var(--t-sheet); color: var(--t-ink); border: 1px solid var(--t-line);
  font-family: var(--t-tech); animation: win-toast .35s ease-out;
}

/* Living walls. Transform only, so the page does not show a gap. */
html:is(.tm-folio, .tm-reticle, .tm-playbill) body::before {
  inset: -12%;
  animation: win-pan 36s ease-in-out infinite alternate;
}
html.tm-sonar body::before {
  inset: auto; width: 200vmax; height: 200vmax; left: 50%; top: 50%; margin: -100vmax 0 0 -100vmax;
  animation: win-spin 70s linear infinite;
}
@keyframes win-pan { to { transform: translate3d(-3.5%, -2.5%, 0); } }
@keyframes win-spin { to { transform: rotate(360deg); } }
@keyframes win-sheen { from { transform: translateX(-130%); } to { transform: translateX(280%); } }
@keyframes win-scan { from { transform: translateY(-100%); } to { transform: translateY(100%); } }
@keyframes win-chase { to { background-position: 48px 0; } }
@keyframes win-paper { from { transform: translateY(36px) rotate(-1deg); } to { transform: none; } }
@keyframes win-iris { from { transform: scale(.94); } to { transform: none; } }
@keyframes win-curtain { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }
@keyframes win-led { 0%, 46% { opacity: 1; } 50%, 100% { opacity: .28; } }
@keyframes win-toast {
  from { transform: translateX(-50%) translateY(12px); }
  to { transform: translateX(-50%) translateY(0); }
}

/* ---------- File Folder: a tab, lined wells, notes, a page that drops ---------- */
html.tm-folio :is(.card, .sheet, .toc, .appban) {
  position: relative;
  background:
    linear-gradient(#e4cfa6, #e4cfa6) 0 26px / 100% 1px no-repeat,
    linear-gradient(#ecd7ad, #ecd7ad) 14px 0 / 118px 27px no-repeat,
    var(--t-card-solid);
  border: 1px solid #8c704c; border-radius: 0 14px 12px 12px;
  box-shadow: 4px 5px 0 #00000018; color: var(--t-ink);
  padding-top: 38px;
}
html.tm-folio .appban { padding-top: 0; }
html.tm-folio .appban .ab-body { padding-top: 34px; }
html.tm-folio .appban::after, .th-card.tm-folio .if-panel::after {
  content: ""; position: absolute; top: 0; left: 14px; width: 118px; height: 26px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .7), transparent);
  animation: win-sheen 5.8s ease-in-out infinite; pointer-events: none;
}
html.tm-folio .sheet { animation: win-paper .48s ease-out; }
html.tm-folio :is(.sheet h2, .toc .toc-h, .te-head h2) {
  font-family: var(--t-display); font-weight: 560; font-size: 1.65rem; letter-spacing: -.02em; color: var(--t-ink);
}
html.tm-folio article.card .post-body { max-width: 66ch; font: 1.08rem/1.6 Georgia, "Times New Roman", serif; }
html.tm-folio article.card .name { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 1.25rem; }
html.tm-folio :is(input[type=text], input[type=search], input[type=password], textarea, .select) {
  font-family: Georgia, "Times New Roman", serif; line-height: 28px; border: 0; border-bottom: 2px solid #8c704c;
  border-radius: 0; background-color: #fffaf0;
  background-image: repeating-linear-gradient(#fffaf0, #fffaf0 27px, #e4d2ae 28px);
  background-attachment: local; color: #241910;
}
html.tm-folio :is(.btn, .appban .ab-theme, .appban .ab-work) {
  border: 1px solid #5c2118; letter-spacing: .04em; text-transform: uppercase; font-size: .8rem;
  box-shadow: 2px 2px 0 #4a2018;
}
html.tm-folio :is(.btn.ghost, .appban .ab-theme, .appban .ab-work) {
  background: #f7edd8; color: #5c2118; border-style: dashed;
}
html.tm-folio :is(.btn, .appban .ab-theme, .appban .ab-work):active { transform: translate(2px, 2px); box-shadow: none; }
html.tm-folio :is(.msg, .comment .bubble) {
  background: #fff4b8; color: #241910; border: 1px solid #c4a15a; border-radius: 2px;
  box-shadow: 3px 4px 0 #00000018; transform: rotate(-.5deg);
}
html.tm-folio .msg.mine { background: #d7efd4; color: #142418; border-color: #7ea87a; transform: rotate(.5deg); }
html.tm-folio #tabs {
  background: #c9b48a; border-top: 0; box-shadow: none; gap: 4px;
  padding: 8px 6px max(6px, env(safe-area-inset-bottom));
}
html.tm-folio #tabs a {
  background: #ecd7ad; color: #4a3828; border: 1px solid #8c704c; border-bottom: 0; border-radius: 10px 10px 0 0;
}
html.tm-folio #tabs a.on { background: #f7edd8; color: #8e2e24; }
html.tm-folio #tabs a.on::after { display: none; }
html.tm-folio .appban .ab-ticker { background: #ecd7ad; color: #4a3828; border-top: 1px solid #8c704c; }

/* ---------- Reticle: chamfer, brackets, a scan on the open window ---------- */
html.tm-reticle :is(.card, .sheet, .toc, .appban, .mu-player) {
  position: relative; background: var(--t-card-solid); color: var(--t-ink);
  border: 1px solid #2c4664; border-radius: 0; box-shadow: none; clip-path: var(--win-cut);
}
html.tm-reticle :is(.card, .sheet, .toc, .appban)::before,
html.tm-reticle #toast::before {
  content: ""; position: absolute; inset: 6px; z-index: 2; pointer-events: none;
  background:
    linear-gradient(#7ad7ff, #7ad7ff) left top / 14px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) left top / 2px 14px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right top / 14px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right top / 2px 14px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) left bottom / 14px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) left bottom / 2px 14px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right bottom / 14px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right bottom / 2px 14px no-repeat;
}
html.tm-reticle :is(.appban, .sheet)::after, .th-card.tm-reticle .if-panel::after {
  content: ""; position: absolute; left: 8px; right: 8px; top: 0; height: 100%; z-index: 2;
  background: linear-gradient(#7ad7ff, #7ad7ff) 0 0 / 100% 2px no-repeat;
  animation: win-scan 4.6s linear infinite; pointer-events: none;
}
html.tm-reticle .sheet { animation: win-iris .4s ease-out; }
html.tm-reticle :is(.section-title, .sheet h2, .toc .toc-h, .appban .ab-name) {
  font-family: "Orbitron", system-ui, sans-serif; letter-spacing: .06em; color: #ffc14a;
}
html.tm-reticle .appban .ab-name { font-size: clamp(1.35rem, 3vw, 1.9rem); }
html.tm-reticle .section-title, html.tm-reticle .sheet h2 { font-size: 1rem; }
html.tm-reticle :is(input[type=text], input[type=search], input[type=password], textarea, .select) {
  font-family: "Chakra Petch", system-ui, sans-serif; color: #d7f4ff; background: #0b121c;
  border: 1px solid #3d536c; border-radius: 0;
  clip-path: polygon(8px 0, calc(100% - 8px) 0, 100% 8px, 100% calc(100% - 8px), calc(100% - 8px) 100%, 8px 100%, 0 calc(100% - 8px), 0 8px);
}
html.tm-reticle :is(.btn, .appban .ab-theme, .appban .ab-work) {
  clip-path: polygon(7px 0, calc(100% - 7px) 0, 100% 7px, 100% calc(100% - 7px), calc(100% - 7px) 100%, 7px 100%, 0 calc(100% - 7px), 0 7px);
  letter-spacing: .08em; text-transform: uppercase; font-size: .78rem; border: 0;
}
html.tm-reticle :is(.btn.ghost, .appban .ab-theme, .appban .ab-work) {
  background: transparent; color: #d7f4ff; box-shadow: inset 0 0 0 1px #7ad7ff;
}
html.tm-reticle :is(.btn, .appban .ab-theme):active { transform: translate(1px, 1px); }
html.tm-reticle :is(.msg, .comment .bubble) {
  border-radius: 0; border: 1px solid #3d536c; background: #1a2838; color: #e9f4ff;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
}
html.tm-reticle .msg.mine { background: #1a4d62; color: #f3fbff; border-color: #7ad7ff; }
html.tm-reticle #tabs {
  background: #0b121c; border-top: 1px solid #7ad7ff; box-shadow: none; gap: 0;
}
html.tm-reticle #tabs a { color: #b7c9dc; }
html.tm-reticle #tabs a.on { color: #ffc14a; background: #121a28; }
html.tm-reticle #tabs a.on::after {
  width: 6px; height: 6px; margin-left: -3px; border-radius: 0; bottom: 4px; background: #7ad7ff;
  animation: win-led 1.7s steps(2, end) infinite;
}
html.tm-reticle .appban .ab-tag { font-family: "Chakra Petch", system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; }
html.tm-reticle #toast { border-radius: 0; clip-path: var(--win-cut); }

/* ---------- Playbill: a poster frame, ticket stubs, bulbs that chase ---------- */
html.tm-playbill :is(.card, .sheet, .toc, .appban) {
  position: relative; background: var(--t-card-solid); color: var(--t-ink);
  border: 3px solid #ffe08a; border-radius: 2px;
  box-shadow: inset 0 0 0 6px #2a1218, inset 0 0 0 8px #6a4038;
}
html.tm-playbill :is(.appban, .sheet)::before,
html.tm-playbill #toast::before,
.th-card.tm-playbill .if-panel::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 8px; z-index: 3; pointer-events: none;
  background: repeating-linear-gradient(90deg, #ffe08a 0 7px, #3a240c 7px 13px, #fff6c8 13px 17px, #3a240c 17px 24px);
  background-size: 48px 100%; animation: win-chase 1.6s linear infinite;
}
html.tm-playbill .sheet { animation: win-curtain .5s ease-out; padding-top: 22px; }
html.tm-playbill .appban .ab-body { padding-top: 20px; }
html.tm-playbill .appban .ab-name { color: #ffe08a; font-size: clamp(1.8rem, 3.4vw, 2.7rem); }
html.tm-playbill :is(.section-title, .sheet h2, .toc .toc-h) {
  font-family: "Bebas Neue", "Arial Narrow", sans-serif; font-size: 2rem; letter-spacing: .04em; color: #ffe08a; font-weight: 400;
}
html.tm-playbill :is(input[type=text], input[type=search], input[type=password], textarea, .select) {
  background: transparent; border: 0; border-bottom: 2px solid #ffe08a; border-radius: 0; color: #fff3e6;
  font-family: "Inter", system-ui, sans-serif;
}
html.tm-playbill :is(.btn, .appban .ab-theme, .appban .ab-work) {
  border: 1px dashed #2a1804; letter-spacing: .12em; text-transform: uppercase; font-size: .75rem;
  box-shadow: 3px 3px 0 #000;
}
html.tm-playbill :is(.btn.ghost, .appban .ab-theme, .appban .ab-work) {
  background: transparent; color: #ffe08a; border: 1px dashed #ffe08a; box-shadow: none;
}
html.tm-playbill :is(.btn, .appban .ab-theme):active { transform: translate(3px, 3px); box-shadow: none; }
html.tm-playbill :is(.msg, .comment .bubble) {
  color: #fff3e6; border: 0; border-radius: 8px;
  background-color: #3a1822;
  background-image:
    radial-gradient(circle at 0 50%, transparent 7px, #3a1822 8px),
    radial-gradient(circle at 100% 50%, transparent 7px, #3a1822 8px);
  background-size: 51% 100%, 51% 100%; background-position: left, right; background-repeat: no-repeat;
}
html.tm-playbill .msg.mine {
  color: #2a1608; background-color: #ffe3a6;
  background-image:
    radial-gradient(circle at 0 50%, transparent 7px, #ffe3a6 8px),
    radial-gradient(circle at 100% 50%, transparent 7px, #ffe3a6 8px);
}
html.tm-playbill #tabs {
  background:
    repeating-linear-gradient(90deg, #ffe08a 0 6px, #3a240c 6px 12px, #fff6c8 12px 16px, #3a240c 16px 22px) top / 100% 7px no-repeat,
    #14080d;
  border-top: 0; box-shadow: none; padding-top: 10px;
}
html.tm-playbill #tabs a { color: #f0cfc4; letter-spacing: .06em; text-transform: uppercase; font-size: 11px; }
html.tm-playbill #tabs a.on { color: #ffe08a; }
html.tm-playbill #tabs a.on::after { background: #ffe08a; animation: win-led 1.4s steps(2, end) infinite; }
html.tm-playbill #toast { border: 2px solid #ffe08a; border-radius: 2px; color: #fff3e6; padding-top: 16px; }

/* ---------- Sonar: a bezel, a scope, lamps on the readouts ---------- */
html.tm-sonar :is(.card, .sheet, .toc, .appban) {
  position: relative; background: var(--t-card-solid); color: var(--t-ink);
  border: 6px solid #12383a; border-radius: 22px;
  box-shadow: inset 0 0 0 2px #7dffa866, 0 12px 28px #00000066;
}
html.tm-sonar .appban { border-radius: 26px; }
html.tm-sonar .appban .ab-ic {
  position: relative; border-radius: 50%; background: #062026;
  box-shadow: inset 0 0 0 3px #1d4a44, 0 0 0 1px #7dffa8; overflow: hidden;
}
html.tm-sonar .appban .ab-ic::before {
  content: ""; position: absolute; inset: 5px; border-radius: 50%;
  background:
    repeating-radial-gradient(circle, transparent 0 7px, rgba(125, 255, 168, .45) 7px 8px),
    conic-gradient(from 0deg, transparent 0 300deg, rgba(125, 255, 168, .95) 345deg, transparent 360deg);
  animation: win-spin 3.4s linear infinite;
}
html.tm-sonar .appban .ab-ic::after { display: none; }
html.tm-sonar .sheet { animation: win-iris .42s ease-out; border-radius: 28px; }
html.tm-sonar .appban .ab-name { color: #7dffa8; font-size: clamp(1.35rem, 2.6vw, 2rem); }
html.tm-sonar :is(.section-title, .sheet h2, .toc .toc-h) {
  font-family: "Chakra Petch", system-ui, sans-serif; color: #7dffa8; letter-spacing: .04em;
}
html.tm-sonar :is(input[type=text], input[type=search], input[type=password], .select) {
  border-radius: 999px; border: 2px solid #1d4a44; background: #071910; color: #c8ffe4;
  box-shadow: inset 0 2px 5px #0008; font-family: "Chakra Petch", system-ui, sans-serif; padding-inline: 16px;
}
html.tm-sonar textarea {
  border-radius: 16px; border: 2px solid #1d4a44; background: #071910; color: #c8ffe4;
  box-shadow: inset 0 2px 5px #0008; font-family: "Chakra Petch", system-ui, sans-serif;
}
html.tm-sonar :is(.btn, .appban .ab-theme, .appban .ab-work) {
  border: 0; box-shadow: inset 0 1px #ffffff66, 0 3px 0 #06341f; letter-spacing: .04em;
}
html.tm-sonar :is(.btn.ghost, .appban .ab-theme, .appban .ab-work) {
  background: #0d2c30; color: #c8ffe4; box-shadow: inset 0 0 0 1px #1d4a44;
}
html.tm-sonar :is(.btn, .appban .ab-theme):active { transform: translateY(3px); box-shadow: inset 0 2px 4px #0008; }
html.tm-sonar :is(.msg, .comment .bubble) {
  position: relative; border-radius: 999px; border: 1px solid #1d4a44; background: #12383a; color: #e8fff6;
  padding-left: 28px;
}
html.tm-sonar .msg.mine { background: #145246; color: #e9fff6; border-color: #7dffa8; }
html.tm-sonar :is(.msg, .comment .bubble)::before {
  content: ""; position: absolute; left: 12px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%;
  background: #7dffa8; animation: win-led 1.8s steps(2, end) infinite;
}
html.tm-sonar #tabs {
  background: #062026; border-top: 3px solid #1d4a44; box-shadow: none; gap: 3px;
  padding: 5px 5px max(5px, env(safe-area-inset-bottom));
}
html.tm-sonar #tabs a {
  margin: 3px 2px; border-radius: 999px; background: #0d2c30; color: #b7ddd2;
  box-shadow: inset 0 -2px #0006, inset 0 1px #ffffff22;
}
html.tm-sonar #tabs a.on { background: #7dffa8; color: #042014; }
html.tm-sonar #tabs a.on::after {
  width: 6px; height: 6px; margin-left: -3px; bottom: 5px; border-radius: 50%; background: #042014;
  animation: win-led 1.6s steps(2, end) infinite;
}
html.tm-sonar .appban .ab-ticker { background: #062026; color: #b7ddd2; border-top: 1px solid #1d4a44; }
html.tm-sonar #toast { border: 3px solid #12383a; border-radius: 999px; box-shadow: inset 0 0 0 1px #7dffa8; }

@media (min-width: 700px) {
  html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .sheet-bg { align-items: center; padding: 1.5rem; }
  html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .sheet {
    max-width: 36rem; max-height: min(86dvh, 760px); margin: 0;
  }
  html.tm-folio .sheet { border-radius: 0 16px 14px 14px; }
  html.tm-playbill .sheet { border-radius: 2px; }
  html.tm-sonar .sheet { border-radius: 28px; }
}
@media (max-width: 699px) {
  html.tm-reticle .sheet { clip-path: polygon(12px 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 0 100%, 0 12px); }
  html.tm-sonar .sheet { border-radius: 22px 22px 0 0; }
  html.tm-playbill .sheet { border-radius: 2px 2px 0 0; }
}

/* Gallery samples use the same frames. */
.th-motion .th-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); }
.th-motion .th-card { display: flex; flex-direction: column; background: var(--t-card-solid); border-radius: 12px; }
.th-motion .th-meta { padding: .8rem 1rem 1rem; }
.th-motion .th-meta b { font-family: var(--t-display); font-weight: var(--t-display-weight); font-size: 1.7rem; letter-spacing: var(--t-h1-track); }
.th-motion .th-meta p { font: .9375rem/1.45 var(--t-body); }
.th-motion .th-sw { display: none; }
.th-motion .if-demo { background: var(--t-wall); background-color: var(--t-bg); }
.th-card.tm-folio .if-panel {
  position: relative; overflow: hidden; padding-top: 34px;
  background:
    linear-gradient(#e4cfa6, #e4cfa6) 0 26px / 100% 1px no-repeat,
    linear-gradient(#ecd7ad, #ecd7ad) 10px 0 / 92px 27px no-repeat,
    #f7edd8;
  border: 1px solid #8c704c; border-radius: 0 12px 10px 10px; box-shadow: 4px 5px 0 #00000018;
}
.th-card.tm-reticle .if-panel {
  position: relative; overflow: hidden; background: #121a28; border: 1px solid #2c4664; border-radius: 0;
  clip-path: var(--win-cut);
}
.th-card.tm-reticle .if-panel::before {
  content: ""; position: absolute; inset: 6px; pointer-events: none;
  background:
    linear-gradient(#7ad7ff, #7ad7ff) left top / 12px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) left top / 2px 12px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right top / 12px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right top / 2px 12px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) left bottom / 12px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) left bottom / 2px 12px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right bottom / 12px 2px no-repeat,
    linear-gradient(#7ad7ff, #7ad7ff) right bottom / 2px 12px no-repeat;
}
.th-card.tm-playbill .if-panel {
  position: relative; overflow: hidden; background: #2a1218; border: 3px solid #ffe08a; border-radius: 2px;
  box-shadow: inset 0 0 0 5px #2a1218, inset 0 0 0 7px #6a4038; padding-top: 14px;
}
.th-card.tm-sonar .if-panel {
  position: relative; background: #0d242c; border: 6px solid #12383a; border-radius: 18px;
  box-shadow: inset 0 0 0 2px #7dffa866;
}
.th-card:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .if-caption {
  font-family: var(--t-display); font-weight: var(--t-display-weight); background: transparent; color: var(--t-ink);
}
.th-card.tm-reticle .if-caption, .th-card.tm-playbill .if-caption, .th-card.tm-sonar .if-caption { color: var(--t-accent); }
.th-card.tm-sonar .if-caption { display: flex; align-items: center; justify-content: space-between; }
.th-card.tm-sonar .if-caption::after {
  content: ""; width: 26px; height: 26px; border-radius: 50%; flex: none;
  background:
    repeating-radial-gradient(circle, transparent 0 5px, rgba(125, 255, 168, .5) 5px 6px),
    conic-gradient(from 0deg, transparent 0 300deg, rgba(125, 255, 168, .95) 345deg, transparent 360deg);
  animation: win-spin 3.4s linear infinite;
}
.th-card.tm-folio .if-field {
  background: #fffaf0; border: 0; border-bottom: 2px solid #8c704c; border-radius: 0; color: #241910;
  box-shadow: none; font-family: Georgia, serif;
}
.th-card.tm-reticle .if-field {
  background: #0b121c; color: #d7f4ff; border: 1px solid #3d536c; border-radius: 0; box-shadow: none;
  font-family: "Chakra Petch", system-ui, sans-serif;
}
.th-card.tm-playbill .if-field {
  background: transparent; color: #fff3e6; border: 0; border-bottom: 2px solid #ffe08a; border-radius: 0; box-shadow: none;
}
.th-card.tm-sonar .if-field {
  background: #071910; color: #c8ffe4; border: 2px solid #1d4a44; border-radius: 999px; box-shadow: inset 0 2px 4px #0008;
}
.th-card:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .if-key {
  background: var(--t-btn); color: var(--t-btn-ink); border: 0; box-shadow: none; font-family: var(--t-tech);
}
.th-card.tm-folio .if-key.ghost { background: #f7edd8; color: #5c2118; border: 1px dashed #5c2118; }
.th-card.tm-reticle .if-key { clip-path: polygon(6px 0, calc(100% - 6px) 0, 100% 6px, 100% calc(100% - 6px), calc(100% - 6px) 100%, 6px 100%, 0 calc(100% - 6px), 0 6px); }
.th-card.tm-reticle .if-key.ghost { background: transparent; color: #d7f4ff; box-shadow: inset 0 0 0 1px #7ad7ff; }
.th-card.tm-playbill .if-key { letter-spacing: .08em; text-transform: uppercase; }
.th-card.tm-playbill .if-key.ghost { background: transparent; color: #ffe08a; border: 1px dashed #ffe08a; }
.th-card.tm-sonar .if-key { border-radius: 999px; }
.th-card.tm-sonar .if-key.ghost { background: #0d2c30; color: #c8ffe4; }

@media (prefers-reduced-motion: reduce) {
  html:is(.tm-folio, .tm-reticle, .tm-playbill) body::before,
  html.tm-sonar body::before,
  html:is(.tm-folio, .tm-playbill) .appban::after,
  html.tm-playbill .appban::before,
  html.tm-playbill .sheet::before,
  html.tm-playbill #toast::before,
  html.tm-reticle .appban::after,
  html.tm-reticle .sheet::after,
  html.tm-sonar .appban .ab-ic::before,
  html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .sheet,
  html:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) #toast,
  html.tm-sonar .msg::before,
  html.tm-sonar .comment .bubble::before,
  html:is(.tm-reticle, .tm-playbill, .tm-sonar) #tabs a.on::after,
  .th-card.tm-folio .if-panel::after,
  .th-card.tm-reticle .if-panel::after,
  .th-card.tm-playbill .if-panel::before,
  .th-card.tm-sonar .if-caption::after { animation: none; }
}
html.lite:is(.tm-folio, .tm-reticle, .tm-playbill) body::before,
html.lite.tm-sonar body::before,
html.lite:is(.tm-folio, .tm-playbill) .appban::after,
html.lite.tm-playbill .appban::before,
html.lite.tm-playbill .sheet::before,
html.lite.tm-playbill #toast::before,
html.lite.tm-reticle .appban::after,
html.lite.tm-reticle .sheet::after,
html.lite.tm-sonar .appban .ab-ic::before,
html.lite:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) .sheet,
html.lite:is(.tm-folio, .tm-reticle, .tm-playbill, .tm-sonar) #toast,
html.lite.tm-sonar .msg::before,
html.lite.tm-sonar .comment .bubble::before,
html.lite:is(.tm-reticle, .tm-playbill, .tm-sonar) #tabs a.on::after,
html.lite .th-card.tm-folio .if-panel::after,
html.lite .th-card.tm-reticle .if-panel::after,
html.lite .th-card.tm-playbill .if-panel::before,
html.lite .th-card.tm-sonar .if-caption::after { animation: none; }
html.idle:is(.tm-folio, .tm-reticle, .tm-playbill) body::before,
html.idle.tm-sonar body::before,
html.idle:is(.tm-folio, .tm-playbill) .appban::after,
html.idle.tm-playbill .appban::before,
html.idle.tm-playbill .sheet::before,
html.idle.tm-reticle .appban::after,
html.idle.tm-reticle .sheet::after,
html.idle.tm-sonar .appban .ab-ic::before,
html.idle.tm-sonar .msg::before,
html.idle.tm-sonar .comment .bubble::before,
html.idle:is(.tm-reticle, .tm-playbill, .tm-sonar) #tabs a.on::after,
html.idle .th-card.tm-folio .if-panel::after,
html.idle .th-card.tm-reticle .if-panel::after,
html.idle .th-card.tm-playbill .if-panel::before,
html.idle .th-card.tm-sonar .if-caption::after { animation-play-state: paused; }
