.tf {
  --tf-ink: #2e2925;
  --tf-muted: #645b54;
  --tf-line: #e5dfd9;
  --tf-accent: #a94313;
  --tf-pale: #fff3e6;
  width: min(100%, 720px);
  margin: 0 auto;
  padding: 28px 20px 54px;
  box-sizing: border-box;
  color: var(--tf-ink);
  text-align: left;
}
.tf *, .tf *::before, .tf *::after { box-sizing: border-box; }
.tf [hidden] { display: none !important; }
.tf button, .tf select, .tf textarea, .tf input { font: inherit; }
.tf button, .tf a, .tf input, .tf textarea, .tf select { -webkit-tap-highlight-color: transparent; }
.tf button { cursor: pointer; }
.tf button:disabled { cursor: wait; opacity: .72; }
.tf :is(button,a,input,select,textarea):focus-visible, .tf-choice input:focus-visible + span { outline: 3px solid #97501b; outline-offset: 3px; }
.tf-back, .tf-link {
  align-items: center; justify-content: center; gap: 6px; display: inline-flex; color: var(--tf-accent);
  background: transparent; border: 0; font-weight: 650; text-decoration: none; padding: 0; min-height: 44px;
}
.tf-back { font-size: .9375rem; color: var(--tf-muted); justify-content:flex-start; }
.tf a:hover, .tf-link:hover { text-decoration: underline; }
.tf-heading { margin: 12px 0 28px; }
.tf h1, .tf h2, .tf p { margin: 0; }
.tf h1 { color: var(--tf-ink); font-size: clamp(1.85rem,3.8vw,2.375rem); font-weight: 780; line-height: 1.28; letter-spacing: -.04em; }
.tf-heading p, .tf-panel-heading p { color: var(--tf-muted); font-size: 1rem; line-height: 1.7; margin-top: 7px; }
.tf-stepbar { display: flex; gap: 14px; align-items: center; margin: 0 0 20px; }
.tf-stepbar > div { display: flex; align-items: center; gap: 8px; color: #665e56; }
.tf-stepbar > div > span { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 50%; color: #5c554e; background: #efebe6; font-size: .875rem; font-weight: 700; }
.tf-stepbar b { font-size: .9375rem; font-weight: 600; }
.tf-stepbar .is-current, .tf-stepbar .is-done { color: var(--tf-accent); }
.tf-stepbar .is-current span, .tf-stepbar .is-done span { color: white; background: var(--tf-accent); }
.tf-stepbar i { width: clamp(28px,7vw,58px); height: 1px; background: #d9d2ca; }
.tf-panel { padding: clamp(20px,4vw,34px); border: 1px solid var(--tf-line); border-radius: 10px; background: #fff; }
.tf h2 { font-size: 1.375rem; font-weight: 720; line-height: 1.38; letter-spacing: -.025em; }
.tf h2:focus { outline: none; }
.tf-panel-heading { margin-bottom: 23px; }
.tf-tabs { display: flex; border: 1px solid var(--tf-line); background: #f7f5f2; border-radius: 8px; padding: 4px; margin-bottom: 20px; }
.tf-tabs button { flex: 1; display:flex; align-items:center; justify-content:center; gap: 7px; min-height: 44px; border: 0; border-radius: 8px; background: transparent; color: var(--tf-muted); line-height: 1.4; }
.tf-tabs button.on { background: var(--tf-accent); color: #fff; font-weight: 700; }
.tf-hold-zone {
  --hold-ink: #255448;
  --hold-fill: #296354;
  --hold-wash: #f2f7f3;
  --hold-line: #ccdcd0;
  padding: 14px 16px 12px;
  border: 1px solid var(--hold-line);
  border-radius: 11px;
  background: var(--hold-wash);
}
.tf-hold-status {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 2.9em; margin-bottom: 6px;
  color: var(--hold-ink); font-size: 1rem; line-height: 1.4;
}
.tf-hold-time { flex: none; font-variant-numeric: tabular-nums; font-weight: 650; }
.tf button.tf-hold {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: 68px; padding: 11px 8px;
  border: 0; border-radius: 9px; background: var(--hold-fill); color: white;
  font-size: 1.2rem; font-weight: 700; line-height: 1.45;
  touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
}
.tf-hold > * { pointer-events: none; }
.tf .tf-hold-hint { margin-top: 8px; text-align: center; color: var(--tf-muted); font-size: .92rem; line-height: 1.55; }
.tf-hold-zone[data-state="preparing"], .tf-hold-zone[data-state="finishing"] {
  --hold-ink: #67523a; --hold-wash: #faf6ef; --hold-line: #ded1bd; --hold-fill: #635645;
}
.tf-hold-zone[data-state="recording"] {
  --hold-fill: #194f40; --hold-wash: #e2f1e7; --hold-line: #86aa98;
}
.tf-hold-zone[data-state="recording"] [data-hold-status]::before {
  content: ""; display: inline-block; width: 9px; height: 9px; margin-right: 7px;
  border-radius: 50%; background: #b93b31; vertical-align: .09em;
  animation: tf-record-pulse 1.3s ease-in-out infinite;
}
@keyframes tf-record-pulse { 50% { opacity: .48; } }
@media(prefers-reduced-motion:reduce) {
  .tf-hold-zone[data-state="recording"] [data-hold-status]::before { animation: none; }
}
.tf-hold-zone[data-state="cancel"] {
  --hold-ink: #82291d; --hold-fill: #a43928; --hold-wash: #fff0e9; --hold-line: #d79b8a;
}
.tf-hold-zone[data-state="limit"] {
  --hold-ink: #664216; --hold-fill: #815020; --hold-wash: #fff3db; --hold-line: #d9bf8c;
}
.tf-extra { border-bottom: 1px solid var(--tf-line); padding-bottom: 8px; margin: 3px 0 17px; }
.tf-extra > summary { cursor: pointer; padding: 10px 0; min-height: 44px; color: var(--tf-muted); font-size: 1rem; line-height: 1.5; }
.tf-extra > summary:focus-visible { outline: 3px solid #97501b; outline-offset: 2px; }
.tf-extra[open] { padding-bottom: 16px; }
.tf-extra[open] > summary { color: var(--tf-accent); }
.tf-extra .tf-field { margin-top: 12px; }
.tf-transcript, .tf-count { color: var(--tf-muted); font-size: .875rem; line-height: 1.65; }
.tf-clip { padding: 19px; background: var(--tf-pale); border: 1px solid #efd9bc; border-radius: 8px; }
.tf-clip-label, .tf-summary > span { display:flex; align-items:center; gap:7px; color:var(--tf-accent); font-weight:650; }
.tf-play-row { display:flex; align-items:center; gap:14px; margin:15px 0 2px; }
.tf-listen { display:flex; align-items:center; gap:8px; min-height:46px; border:0; padding:8px 13px; background:var(--tf-accent); border-radius:7px; color:#fff; }
.tf-listen span { font-variant-numeric:tabular-nums; font-size:.9375rem; }
.tf p.tf-transcript { margin-top: 11px; }
.tf-sr { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.tf-text textarea, .tf-field :is(input:not([type="radio"]), select) { width:100%; background: #fff; color: var(--tf-ink); font-size: 1rem; border:1px solid #9d9287; border-radius:10px; min-height:48px; padding:10px 12px; }
.tf-text textarea { resize:vertical; min-height:146px; }
.tf :is(input,textarea)::placeholder { color: #736b63; opacity:1; }
.tf-count { display:flex; justify-content:space-between; gap:8px; margin-top:5px; }
.tf-summary { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:0 12px; background:#f7f4ef; border-radius:10px; padding:3px 12px; margin:0 0 20px; }
.tf-summary > span, .tf .tf-link { font-size:.9375rem; }
.tf-field { padding:0; border:0; min-width:0; margin:20px 0 0; }
.tf-field > label, .tf-field > legend { display: block; padding:0; margin:0 0 8px; font-size:1.04rem; font-weight:680; color:var(--tf-ink); }
.tf-field > label small { font-size:.8125rem; font-weight:400; color:var(--tf-muted); margin-left:8px; }
.tf-select { position:relative; }
.tf-select::after { content:""; position:absolute; right:16px; top:19px; width:8px; height:8px; transform:rotate(45deg); border-right:2px solid #746a60; border-bottom:2px solid #746a60; pointer-events:none; }
.tf-field select { appearance:none; padding-right:36px; }
.tf-options { display:grid; gap:8px; }
.tf-dates { grid-template-columns:repeat(3,minmax(0,1fr)); }
.tf-slots { grid-template-columns:repeat(2,minmax(0,1fr)); }
.tf-choice { cursor:pointer; position:relative; min-width:0; }
.tf-choice input { position:absolute; margin:0; width:1px; height:1px; opacity:0; }
.tf-choice > span { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:3px; font-size:1rem; line-height:1.5; min-height:48px; height:100%; padding:8px 4px; border:1px solid #a79c90; border-radius:9px; color:var(--tf-ink); background:#fff; }
.tf-choice small { font-size:.8125rem; color:var(--tf-muted); }
.tf-choice input:checked + span { border:1px solid var(--tf-accent); box-shadow: inset 0 0 0 1px var(--tf-accent); background:var(--tf-pale); color:var(--tf-accent); }
.tf-choice:active > span { background:#fff0dc; }
.tf-actions { margin-top:20px; }
.tf-primary { display:block; width:100%; min-height:52px; border-radius:8px; border:0; color:white; background:var(--tf-accent); font-size:1.06rem; font-weight:700; padding:12px 15px; }
.tf-primary:hover,.tf-listen:hover { background: #88340e; }
.tf p.tf-feedback { margin-top:14px; padding:11px 14px; border-left:3px solid #b55a35; color:#894126; background:#fff1e9; font-size:1rem; line-height:1.55; }
.tf p.tf-footnote { display:flex; justify-content:center; align-items:center; gap:6px; margin:13px 0 0; font-size:.875rem; color:var(--tf-muted); }
@media(max-width:620px) {
  .tf { padding:8px 16px 24px; }
  .tf-heading { margin:7px 0 20px; }
  .tf-stepbar { margin-bottom:16px; gap:10px; }
  .tf-panel { padding:19px 16px; border-radius:10px; }
  .tf-panel-heading { margin-bottom:17px; }
  .tf-tabs { margin-bottom:14px; }
  .tf-hold-zone { padding: 11px 12px 10px; }
}
@media(max-width:355px) {
  .tf { padding-inline:12px; }
  .tf-panel { padding-inline:12px; }
  .tf-slots { grid-template-columns:1fr; }
}
