.tbat, .tbat-contact { margin-block: 1.4rem 2rem; --t-teal: #0e9f8e; --t-teal-d: #0b7f72; --t-navy: #14213d; --t-line: #e5e2da; --t-muted: #5b6472; }
.tbat-loading, .tbat-noscript { color: var(--t-muted); }
.tbat-card { background: #fff; border: 1px solid var(--t-line); border-radius: 18px; padding: 22px; box-shadow: 0 1px 2px rgba(20,33,61,.06), 0 8px 24px rgba(20,33,61,.07); }
.tbat-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.tbat-tab { font: inherit; font-weight: 800; font-size: .92rem; border: 1px solid var(--t-line); background: #f7f6f2; color: var(--t-navy); padding: .45rem .9rem; border-radius: 10px; cursor: pointer; }
.tbat-tab.is-active { background: var(--t-navy); color: #fff; border-color: var(--t-navy); }
.tbat-label { display: flex; flex-direction: column; gap: 4px; font-weight: 700; color: var(--t-navy); font-size: .95rem; }
.tbat-input { font: inherit; font-size: 1rem; padding: .5rem .7rem; border: 1px solid #d3cfc4; border-radius: 10px; background: #fff; max-width: 100%; }
.tbat-toolbar { display: flex; flex-wrap: wrap; gap: 14px; align-items: end; justify-content: space-between; margin-bottom: 12px; }
.tbat-sections { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 12px; }
.tbat-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; }
@media (max-width: 640px) { .tbat-sections { grid-template-columns: 1fr 1fr; } }

.tbat-result { display: grid; grid-template-columns: 150px 1fr; gap: 18px; align-items: center; background: #f3faf9; border: 1px solid #cdebe6; border-radius: 14px; padding: 16px; margin-top: 14px; }
.tbat-result__big { text-align: center; }
.tbat-result__big strong { display: block; font-size: 3.2rem; line-height: 1.1; color: var(--t-teal-d); font-weight: 900; }
.tbat-result__label { font-size: .82rem; color: var(--t-muted); font-weight: 700; }
.tbat-result__grid { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 0; }
.tbat-result__grid dt { color: var(--t-muted); font-size: .92rem; }
.tbat-result__grid dd { margin: 0; font-weight: 800; color: var(--t-navy); }
@media (max-width: 560px) { .tbat-result { grid-template-columns: 1fr; } }

.tbat-btn { font: inherit; font-weight: 800; font-size: .98rem; padding: .6rem 1.2rem; border-radius: 12px; border: 2px solid var(--t-teal); background: var(--t-teal); color: #fff; cursor: pointer; }
.tbat-btn:hover { background: var(--t-teal-d); border-color: var(--t-teal-d); }
.tbat-btn:disabled { opacity: .45; cursor: not-allowed; }
.tbat-btn--ghost { background: #fff; color: var(--t-teal-d); }
.tbat-btn--ghost:hover { background: #e3f6f3; color: var(--t-teal-d); }
.tbat-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-block: 14px; }
.tbat-actions--center { justify-content: center; }

.tbat-progress { display: flex; justify-content: space-between; font-size: .9rem; color: var(--t-muted); font-weight: 700; }
.tbat-bar { height: 6px; background: #eeece5; border-radius: 99px; margin: 6px 0 16px; overflow: hidden; }
.tbat-bar span { display: block; height: 100%; background: linear-gradient(90deg, #f2a541, var(--t-teal)); border-radius: 99px; transition: width .3s; }

.tbat-dialog { direction: ltr; text-align: left; font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif; font-size: 1.12rem; line-height: 2.2; margin: 0 0 6px; }
.tbat-dialog b { color: var(--t-teal-d); }
.tbat-slots { display: inline; }
.tbat-blank { display: inline-block; width: 82px; border-bottom: 3px solid var(--t-navy); margin: 0 4px; vertical-align: middle; height: 1.4em; }
.tbat-pool { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 4px; padding: 14px; background: #f7f6f2; border-radius: 12px; min-height: 56px; }
.tbat-chip { font: 600 1.02rem "Segoe UI", "Helvetica Neue", Arial, sans-serif; padding: .4rem .9rem; border-radius: 10px; border: 2px solid var(--t-navy); background: #fff; color: var(--t-navy); cursor: pointer; margin: 2px; }
.tbat-chip:hover { background: #eef2f9; }
.tbat-chip.is-used { opacity: .25; cursor: default; }
.tbat-chip.is-placed { background: #7ee0d3; border-color: #7ee0d3; }

.tbat-feedback { border-radius: 12px; margin-top: 10px; }
.tbat-feedback:empty { display: none; }
.tbat-feedback.is-ok { background: #e6f6ec; border: 1px solid #bfe5cd; padding: 12px 16px; }
.tbat-feedback.is-bad { background: #fdecec; border: 1px solid #f3c8c8; padding: 12px 16px; }
.tbat-feedback p { margin: 0 0 .4rem; }
.tbat-feedback__title { font-weight: 900; color: var(--t-navy); }
.tbat-answer { direction: ltr; text-align: left; font-family: "Segoe UI", Arial, sans-serif; font-weight: 700; }

.tbat-final { text-align: center; padding: 18px 8px; }
.tbat-final__score { font-size: 2.6rem; font-weight: 900; color: var(--t-teal-d); margin: 0; }
.tbat-small { font-size: .88rem; color: var(--t-muted); }
.tbat-note { color: var(--t-navy); font-weight: 700; margin: 10px 0 0; }
.tbat-tip { background: #fef3e2; border-inline-start: 4px solid #f2a541; padding: 8px 12px; border-radius: 8px; margin: 10px 0; }
.tbat-warn { color: #b02e2e; font-weight: 700; }

.tbat-passage { direction: ltr; text-align: left; font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif; font-size: 1.1rem; line-height: 2.4; background: #fbfaf7; border: 1px solid var(--t-line); border-radius: 12px; padding: 14px 18px; }
.tbat-gap { font: 600 1.05rem "Segoe UI", Arial, sans-serif; border: 0; border-bottom: 2px dashed var(--t-navy); background: #eef2f9; border-radius: 4px 4px 0 0; padding: 0 3px; margin: 0 1px; text-align: left; direction: ltr; }
.tbat-gap:focus { outline: 2px solid #f2a541; background: #fff; }
.tbat-gap.is-ok { background: #e6f6ec; border-bottom-color: #1b8a4f; }
.tbat-gap.is-bad { background: #fdecec; border-bottom-color: #c73e3e; }
.tbat-ltr-list { direction: ltr; text-align: left; font-family: "Segoe UI", Arial, sans-serif; padding-left: 1.4rem; padding-right: 0; }

.tbat-hidden { filter: blur(7px); user-select: none; }
.tbat-audio { width: 100%; margin: 8px 0; }

.tbat-prompt { direction: ltr; text-align: left; background: #f2f6fb; border-left: 5px solid #2b7bb9; border-radius: 10px; padding: 12px 18px; font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif; font-size: 1.02rem; line-height: 1.75; margin-bottom: 12px; }
.tbat-prompt p { margin: 0 0 .5rem; }
.tbat-prompt ul { margin: 0 0 .5rem; padding-left: 1.3rem; }
.tbat-textarea { width: 100%; font: 1.05rem/1.7 "Segoe UI", "Helvetica Neue", Arial, sans-serif; padding: 12px 14px; border: 1px solid #d3cfc4; border-radius: 12px; resize: vertical; direction: ltr; text-align: left; }
.tbat-textarea:disabled { background: #f7f6f2; }
.tbat-timer { font-weight: 900; color: var(--t-navy); font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
.tbat-timer--big { font-size: 1.8rem; }
.tbat-timer.is-low { color: #c73e3e; }
.tbat-wc { font: 700 .95rem "Segoe UI", Arial, sans-serif; direction: ltr; color: var(--t-muted); background: #f7f6f2; padding: .2rem .7rem; border-radius: 99px; }
.tbat-wc.is-ok { color: #1b8a4f; background: #e6f6ec; }
.tbat-checklist { list-style: none; padding: 0; margin: 6px 0; }
.tbat-checklist li { display: flex; gap: 8px; align-items: baseline; margin-bottom: 6px; }
.tbat-check { display: inline-flex; gap: 6px; align-items: center; font-size: .95rem; }

.tbat-flash { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 220px; margin: 10px 0; border: 2px solid var(--t-navy); border-radius: 20px; background: #fff; cursor: pointer; font: inherit; padding: 20px; transition: background .2s; }
.tbat-flash:hover { background: #fbfaf7; }
.tbat-flash.is-back { background: #f3faf9; border-color: var(--t-teal); }
.tbat-flash__word { font: 800 2.3rem "Segoe UI", "Helvetica Neue", Arial, sans-serif; color: var(--t-navy); }
.tbat-flash__hint { font-size: .88rem; color: var(--t-muted); }
.tbat-flash__ar { font-size: 1.9rem; font-weight: 900; color: var(--t-teal-d); }
.tbat-flash__theme { font-size: .85rem; color: var(--t-muted); background: #e3f6f3; padding: .1rem .7rem; border-radius: 99px; }
.tbat-flash__ex { font: italic 1rem "Segoe UI", Arial, sans-serif; color: var(--t-navy); max-width: 30em; text-align: center; }

.tbat-h { margin-top: 18px; }
.tbat-table-wrap { overflow-x: auto; border: 1px solid var(--t-line); border-radius: 12px; }
.tbat-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.tbat-table th, .tbat-table td { padding: .55rem .8rem; border-bottom: 1px solid var(--t-line); text-align: start; vertical-align: top; }
.tbat-table thead th { background: var(--t-navy); color: #fff; }
.tbat-table td:first-child { font-weight: 900; color: var(--t-teal-d); white-space: nowrap; }

/* Contact form */
.tbat-contact { max-width: 620px; }
.tbat-contact label { display: block; font-weight: 700; color: var(--t-navy); margin-bottom: 4px; }
.tbat-contact input, .tbat-contact select, .tbat-contact textarea { width: 100%; font: inherit; padding: .6rem .8rem; border: 1px solid #d3cfc4; border-radius: 10px; background: #fff; }
.tbat-hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tbat-alert { padding: 12px 16px; border-radius: 12px; font-weight: 700; }
.tbat-alert--ok { background: #e6f6ec; color: #1b6a3f; }
.tbat-alert--err { background: #fdecec; color: #8f2525; }

@media print {
	.tbat-card { box-shadow: none; border: 0; padding: 0; }
	.tbat-form, .tbat-actions, .tbat-toolbar { display: none !important; }
}
