/* Brailleschrift (/braille-translator/, /braille/ und deutsche Fassungen), seit 21.11.2026. Lädt nach site.css. */

/* Zelle als Punkte: 2 Spalten, 3 (bzw. 4) Reihen; Punkte 1 4 / 2 5 / 3 6 */
.bcell { display: inline-grid; grid-template-columns: repeat(2, var(--bd, 7px)); grid-auto-rows: var(--bd, 7px); gap: var(--bg, 3px); padding: 3px; vertical-align: middle; }
.bcell i { display: block; border-radius: 50%; background: transparent; box-shadow: inset 0 0 0 1px #D9D9E6; }
.bcell i.on { background: var(--ink); box-shadow: none; }

/* Braille-Zeichen im Fließtext und in Tabellen */
.bch { font-size: 1.55em; line-height: 0; vertical-align: -.08em; color: var(--ink); }
.bcode { font-family: var(--mono); font-size: 1.5em; line-height: 0; letter-spacing: .08em; background: #F3F3FA; border-radius: 4px; padding: 0 5px; color: var(--ink); }
.bbig { font-size: 2em; line-height: 1; color: var(--ink); vertical-align: -2px; }

/* ------------------------------------------------ Übersetzer */
.btool .tool__bar { align-items: flex-end; }
.btool select { min-width: 220px; }
.btool__keys { align-self: center; display: inline-flex; gap: 8px; align-items: center; font-size: 14.5px; font-weight: 500; color: var(--ink); cursor: pointer; margin-left: auto; }
.btool__help { margin: 0; padding: 10px 18px; background: var(--accent-soft); color: var(--accent-ink); font-size: 14.5px; border-bottom: 1px solid var(--line); }
.btool .pane textarea { min-height: 150px; word-break: normal; overflow-wrap: break-word; }
.btool textarea.btool__braille { font-family: inherit; font-size: 32px; line-height: 1.5; letter-spacing: .06em; }
.btool__note { margin: 0; padding: 10px 18px; background: var(--amber-soft); color: #5C3E00; font-size: 14.5px; border-top: 1px solid var(--line); }
.btool__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--line); background: #FAFAFD; }
.btool__count { margin-left: auto; font-size: 13px; color: var(--muted); }
.btool > .samples { padding: 12px 18px 14px; border-top: 1px solid var(--line); }
.btool__cells { border-top: 1px solid var(--line); padding: 16px 18px 20px; }
.btool__cells h2 { margin: 0 0 4px; font-family: var(--head); font-size: 17px; font-weight: 600; color: var(--ink); }
.btool__cells > p { margin: 0 0 12px; font-size: 14px; color: var(--muted); }

.bchips { display: flex; flex-wrap: wrap; gap: 6px; max-height: 360px; overflow: auto; }
.bchip { --bd: 9px; --bg: 4px; display: inline-flex; flex-direction: column; align-items: center; gap: 2px; min-width: 58px; padding: 7px 6px 6px; border: 1px solid var(--line-2); border-radius: 10px; background: #FFFFFF; }
.bchip b { font-size: 15px; font-weight: 600; color: var(--ink); line-height: 1.2; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bchip small { font-size: 11px; color: var(--muted); white-space: nowrap; }
.bchip__cells { display: inline-flex; gap: 4px; }
.bchip--sign { background: var(--accent-soft); border-color: #DCDBFF; }
.bchip--sign b { font-size: 12px; color: var(--accent-ink); }
.bchip--space { opacity: .55; }
.bchip--unknown { background: var(--amber-soft); }
.bchip-br { flex-basis: 100%; height: 0; }

/* Alphabete */
.btables { display: flex; flex-direction: column; gap: 12px; }
.btable { border: 1px solid var(--line-2); border-radius: 14px; background: #FFFFFF; }
.btable > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; cursor: pointer; list-style: none; }
.btable > summary::-webkit-details-marker { display: none; }
.btable > summary h3 { margin: 0; font-family: var(--head); font-size: 17px; font-weight: 600; color: var(--ink); }
.btable > summary::after { content: '+'; font-size: 22px; color: var(--accent); }
.btable[open] > summary::after { content: '–'; }
.btable__sample { margin-left: auto; font-size: 28px; line-height: 1; letter-spacing: .06em; color: var(--muted); }
.btable > p, .btable > h4, .btable > .bgrid { margin-left: 18px; margin-right: 18px; }
.btable > p { margin-top: 0; font-size: 15.5px; }
.btable > h4 { margin-top: 18px; margin-bottom: 8px; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.btable > .bgrid:last-child { margin-bottom: 20px; }
.bgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 6px; }
.bgrid--wide { grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); }
.bglyph { --bd: 10px; --bg: 4px; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 4px 6px; border: 1px solid var(--line); border-radius: 10px; background: #FCFCFF; }
.bglyph__cells { display: inline-flex; gap: 5px; }
.bglyph b { font-size: 15px; font-weight: 600; color: var(--ink); text-align: center; line-height: 1.25; }
.bgrid--wide .bglyph b { font-size: 12.5px; font-weight: 500; }

/* ------------------------------------------------ Einführung: anklickbare Zelle */
.bcellpad { display: flex; flex-wrap: wrap; gap: 28px 40px; align-items: center; padding: 24px; }
.bcellpad__cell { display: grid; grid-template-columns: repeat(2, 72px); grid-auto-rows: 72px; gap: 14px; padding: 18px; border-radius: 22px; background: #F6F6FB; border: 1px solid var(--line-2); }
.bdot { position: relative; border-radius: 50%; border: 2px dashed #C9C8E0; background: #FFFFFF; cursor: pointer; transition: transform .08s ease, background .12s ease; }
.bdot span { position: absolute; right: -6px; bottom: -6px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: #FFFFFF; border: 1px solid var(--line-2); font-size: 12px; font-weight: 700; color: var(--muted); }
.bdot[aria-pressed="true"] { background: var(--ink); border: 2px solid var(--ink); box-shadow: 0 6px 14px -6px rgba(28, 27, 58, .6); }
.bdot:hover { transform: scale(1.05); }
.bdot:focus-visible { outline: 3px solid #B9B6FF; outline-offset: 3px; }
.bcellpad__out { flex: 1 1 320px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.bcellpad__big { margin: 0; font-family: var(--head); font-size: 64px; font-weight: 700; line-height: 1; color: var(--ink); min-height: 64px; }
.bcellpad__means { margin: 0; font-size: 17px; }
.bcellpad__row { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: flex-end; }
.bcellpad__row input[type=text] { width: 80px; text-align: center; font-size: 18px; }

.bprose > p, .bprose > ul, .bprose > ol { margin: 0 0 14px; }
.bprose > *:last-child { margin-bottom: 0; }
.bfig { margin: 6px 0 18px; display: flex; align-items: center; gap: 18px; }
.bfig__cell { display: grid; grid-template-columns: repeat(2, 40px); grid-auto-rows: 40px; gap: 10px; padding: 12px; border-radius: 14px; background: #F6F6FB; }
.bfig__cell span { display: grid; place-items: center; border-radius: 50%; border: 2px dashed #C9C8E0; font-size: 14px; font-weight: 700; color: var(--muted); }
.bfig__cell span.on { background: var(--ink); border: 2px solid var(--ink); color: #FFFFFF; }
.bfig figcaption { font-size: 15px; color: var(--muted); }
.bdecades { display: flex; flex-direction: column; gap: 12px; margin: 4px 0 16px; }
.bdecade__label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.bdecade .bgrid { grid-template-columns: repeat(10, minmax(0, 1fr)); }
.bbits td { white-space: nowrap; }

@media (max-width: 720px) {
  .btool__keys { margin-left: 0; }
  .btool textarea.btool__braille { font-size: 22px; }
  .bcellpad { padding: 18px; }
  .bcellpad__cell { grid-template-columns: repeat(2, 60px); grid-auto-rows: 60px; }
  .bcellpad__big { font-size: 48px; min-height: 48px; }
  .bdecade .bgrid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

/* ------------------------------------------------ Druck (Übersetzer) */
#braille-print { display: none; }
@media print {
  @page { size: A4; margin: 12mm; }
  body.braille-printing { background: #FFFFFF; }
  body.braille-printing > *:not(#braille-print) { display: none !important; }
  body.braille-printing #braille-print { display: block; }
  .bprint { font-family: var(--body-font, Inter, sans-serif); color: #000000; }
  .bprint__head { margin: 0 0 2mm; font-size: 12pt; font-weight: 700; }
  .bprint__hint { margin: 0 0 6mm; font-size: 10pt; color: #333333; }
  .bsheet { display: block; }
  .bsheet circle { fill: #000000; }
  .bsheet circle.off { fill: #BBBBBB; }
  .bprint__text { margin: 8mm 0 0; font-size: 10pt; color: #333333; white-space: pre-wrap; }
}
