/* The Quilting Bee Toolbox. Brand colors sampled from the Bee's Quilt Shop logo; the theme's own font. */
.bqt{
  --bqt-ink:#3D2314;
  --bqt-text:#4A3426;
  --bqt-muted:#6B4A34;
  --bqt-bg:#fff;
  --bqt-soft:#FFF8E1;
  --bqt-band:#FFF0B1;
  --bqt-amber:#FCB040;
  --bqt-link:#7A4A08;
  --bqt-line:#E3D5BE;
  --bqt-field:#8A7360;
  --bqt-radius:12px;
  max-width:880px;margin:0 auto;color:var(--bqt-text);font-size:1.0625rem;line-height:1.7;overflow-wrap:anywhere;
}
.bqs-toolbox-page .wp-block-post-content>.bqt{max-width:880px;margin-left:auto;margin-right:auto}
.bqs-toolbox-page main>.wp-block-group:empty{display:none}
.bqs-toolbox-page main{margin-top:0}
.bqs-toolbox-page main .wp-block-post-content{margin-top:0}
.bqt-row-units{margin-top:.1rem}
.bqt-row-units .bqt-seg{margin-bottom:.35rem}
.bqt *,.bqt *::before,.bqt *::after{box-sizing:border-box}
.bqt [hidden]{display:none!important}
.bqt a{color:var(--bqt-link);text-decoration:underline;text-underline-offset:2px}
.bqt a:hover{color:var(--bqt-ink)}
.bqt :focus-visible{outline:3px solid var(--bqt-ink);outline-offset:2px;border-radius:4px}
.bqt h2{color:var(--bqt-ink);font-size:clamp(1.35rem,3vw,1.7rem);line-height:1.3;margin:2.1em 0 .6em;font-weight:700}
.bqt h3{color:var(--bqt-ink);font-size:1.15rem;line-height:1.4;margin:1.5em 0 .4em;font-weight:700}
.bqt p{margin:0 0 1em}
.bqt-vh{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}

/* Breadcrumb, title, lead answer */
.bqt-crumbs{font-size:.9rem;margin:1.25rem 0 .75rem}
.bqt-crumbs ol{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:.25rem}
.bqt-crumbs li+li::before{content:"/";margin-right:.25rem;color:var(--bqt-muted)}
.bqt-crumbs span{color:var(--bqt-muted)}
.bqt .bqt-h1{color:var(--bqt-ink);font-size:clamp(1.75rem,4.2vw,2.4rem);line-height:1.15;margin:0 0 .6rem;font-weight:700;text-wrap:balance;text-align:left}
.bqt-snippet{background:var(--bqt-soft);border-left:4px solid var(--bqt-amber);border-radius:0 var(--bqt-radius) var(--bqt-radius) 0;padding:.8rem 1.1rem;margin:0 0 1rem;font-size:1rem;line-height:1.6}
.bqt-snippet p{margin:0}
.bqt-byline{font-size:.85rem;color:var(--bqt-muted);margin:0 0 1.25rem}
.bqt .bqt-h-small{font-size:1.1rem;margin:0 0 .6rem}

/* Tool card */
.bqt-tool{background:var(--bqt-bg);border:1px solid var(--bqt-line);border-radius:var(--bqt-radius);padding:1.1rem 1.25rem 1.25rem;margin:1rem 0 .75rem;box-shadow:0 1px 3px rgba(61,35,20,.08)}
.bqt-form{margin:0}
.bqt-row{display:flex;flex-wrap:wrap;gap:0 .9rem;align-items:flex-start}
.bqt-row-top{margin-bottom:.15rem}
.bqt-field{display:flex;flex-direction:column;gap:.25rem;flex:1 1 180px;min-width:0;margin:0 0 .7rem}
.bqt-field-wide{flex-basis:100%}
.bqt-field label,.bqt-seg legend{font-weight:600;color:var(--bqt-ink);font-size:.93rem;line-height:1.35}
.bqt select,.bqt input[type="text"]{font:inherit;color:var(--bqt-ink);background:#fff;border:1px solid var(--bqt-field);border-radius:8px;min-height:46px;padding:.45rem .7rem;width:100%}
.bqt-input{display:flex;align-items:stretch;border:1px solid var(--bqt-field);border-radius:8px;background:#fff;min-height:46px}
.bqt-input:focus-within{outline:3px solid var(--bqt-ink);outline-offset:2px}
.bqt .bqt-input input[type="text"]{border:0;border-radius:8px;min-width:0;flex:1 1 auto;outline:0;background:transparent}
.bqt-affix{display:flex;align-items:center;padding:0 .65rem;color:var(--bqt-muted);font-size:.9rem;white-space:nowrap;background:var(--bqt-soft);border-radius:0 7px 7px 0}
.bqt-affix:first-child{border-radius:7px 0 0 7px}
.bqt .bqt-input:has(input[aria-invalid="true"]){border-color:#b91c1c;box-shadow:0 0 0 1px #b91c1c}
.bqt select[aria-invalid="true"]{border-color:#b91c1c}
.bqt-hint{font-size:.82rem;color:var(--bqt-muted);line-height:1.4}
.bqt-group-f{border-top:1px solid var(--bqt-line);padding-top:.7rem;margin-top:.2rem}
.bqt .bqt-group-t{font-weight:700;color:var(--bqt-ink);margin:1rem 0 .35rem;font-size:.97rem}
.bqt-seg{border:0;padding:0;margin:0 0 .7rem;min-width:0;flex:1 1 220px}
.bqt-seg legend{padding:0;margin:0 0 .25rem}
.bqt-seg-opts{display:flex;flex-wrap:wrap}
.bqt-seg input{position:absolute;opacity:0;width:1px;height:1px}
.bqt-seg label{flex:1 1 auto;display:inline-flex;align-items:center;justify-content:center;text-align:center;min-height:46px;padding:.4rem .75rem;border:1px solid var(--bqt-field);margin-left:-1px;background:#fff;color:var(--bqt-ink);font-weight:600;font-size:.93rem;line-height:1.25;cursor:pointer}
.bqt-seg label:first-of-type{border-radius:8px 0 0 8px;margin-left:0}
.bqt-seg label:last-of-type{border-radius:0 8px 8px 0}
.bqt-seg input:checked+label{background:var(--bqt-ink);border-color:var(--bqt-ink);color:#fff}
.bqt-seg input:focus-visible+label{outline:3px solid var(--bqt-ink);outline-offset:2px}
.bqt-check{display:flex;flex-wrap:wrap;align-items:center;gap:.25rem .55rem;margin:0 0 .7rem;min-height:44px;flex:1 1 220px}
.bqt-check input{width:22px;height:22px;margin:0;accent-color:var(--bqt-ink)}
.bqt-check label{font-weight:600;color:var(--bqt-ink);cursor:pointer;font-size:.93rem}
.bqt-check .bqt-hint{flex-basis:100%}
.bqt-error{background:#fef2f2;border:1px solid #fca5a5;color:#991b1b;border-radius:8px;padding:.55rem .8rem;margin:0 0 .7rem;font-size:.95rem}

/* Result */
.bqt-result{margin:.35rem 0 0}
.bqt-card{background:var(--bqt-soft);border-radius:var(--bqt-radius);padding:.9rem 1.1rem}
.bqt .bqt-card-k{font-weight:700;color:var(--bqt-ink);margin:0 0 .15rem;font-size:1rem}
.bqt .bqt-big{font-size:clamp(1.7rem,5.5vw,2.3rem);font-weight:800;line-height:1.15;color:var(--bqt-ink);margin:0 0 .2rem;font-variant-numeric:tabular-nums}
.bqt .bqt-sub{font-size:.92rem;color:var(--bqt-muted);margin:0 0 .6rem}
.bqt-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:.5rem;margin:.6rem 0 0}
.bqt-stat{background:#fff;border:1px solid var(--bqt-line);border-radius:8px;padding:.5rem .65rem}
.bqt-stat dt{font-size:.8rem;font-weight:700;color:var(--bqt-ink);line-height:1.3}
.bqt-stat dd{margin:.15rem 0 0;font-weight:700;font-size:1.03rem;line-height:1.3;color:var(--bqt-ink);font-variant-numeric:tabular-nums}
.bqt-stat dd small{display:block;font-weight:400;font-size:.8rem;color:var(--bqt-muted);line-height:1.35;margin-top:.1rem}
.bqt-mini{width:100%;border-collapse:collapse;font-size:.9rem;font-variant-numeric:tabular-nums;margin:.3rem 0 .75rem;background:#fff}
.bqt-mini th,.bqt-mini td{border-bottom:1px solid var(--bqt-line);padding:.4rem .55rem;text-align:right}
.bqt-mini th:first-child,.bqt-mini td:first-child{text-align:left}
.bqt-mini thead th{font-size:.8rem;color:var(--bqt-ink);background:var(--bqt-soft)}
.bqt-mini tr.is-base td,.bqt-mini tr.is-base th{background:var(--bqt-band);font-weight:700}
.bqt-mini-wrap{overflow-x:auto;position:relative}
.bqt .bqt-flag{font-size:.87rem;color:var(--bqt-muted);margin:.6rem 0 0;line-height:1.5}
.bqt .bqt-flag.bqt-flag-strong{font-size:.95rem;color:#7c2d12;background:#fff7ed;border:1px solid #fdba74;border-radius:8px;padding:.6rem .8rem;margin-top:.75rem}
.bqt-diagram{margin:.9rem 0 0;text-align:center}
.bqt-diagram svg{display:inline-block;width:100%;height:auto;max-width:440px;max-height:420px}
.bqt-diagram figcaption{font-size:.87rem;color:var(--bqt-muted);margin-top:.4rem;line-height:1.45}

/* Printable sheets, shown at a preview scale on screen and true size in print */
.bqt-sheet-wrap{margin:.9rem auto 0;max-width:460px;border:1px solid var(--bqt-line);border-radius:6px;overflow:hidden;background:#fff}
.bqt-sheet-svg{display:block;width:100%;height:auto}
.bqt-sheet-actions{display:flex;flex-wrap:wrap;gap:.6rem;margin:.75rem 0 0}

/* Actions */
.bqt-actions,.bqt-copyrow{display:flex;flex-wrap:wrap;align-items:center;gap:.6rem;margin-top:.85rem}
.bqt .bqt-btn{display:inline-flex;align-items:center;justify-content:center;min-height:46px;padding:.55rem 1.1rem;border-radius:8px;border:2px solid var(--bqt-amber);background:var(--bqt-amber);color:var(--bqt-ink);font:inherit;font-weight:700;font-size:.98rem;line-height:1.2;cursor:pointer;text-decoration:none}
.bqt .bqt-btn:hover{background:#FFDE51;border-color:#FFDE51;color:var(--bqt-ink)}
.bqt .bqt-btn-ghost{background:#fff;border-color:var(--bqt-field);color:var(--bqt-ink)}
.bqt .bqt-btn-ghost:hover{background:var(--bqt-soft);border-color:var(--bqt-ink);color:var(--bqt-ink)}
.bqt-status{font-size:.9rem;color:var(--bqt-ink);min-height:1.5em}
.bqt-note{font-size:.95rem;background:var(--bqt-band);padding:.6rem .85rem;border-radius:8px}

.bqt-intro{margin-top:1.75rem}

/* At a glance */
.bqt-summary{background:var(--bqt-soft);border-radius:var(--bqt-radius);padding:1rem 1.25rem;margin:1.5rem 0}
.bqt-summary dl{margin:0;display:grid;gap:.6rem}
.bqt-summary dt{font-weight:700;color:var(--bqt-ink);font-size:.95rem}
.bqt-summary dd{margin:0;font-size:.95rem}

/* Reference chart */
.bqt-ref h2{margin-top:1.75rem}
.bqt-table-wrap{overflow-x:auto;position:relative;border:1px solid var(--bqt-line);border-radius:var(--bqt-radius);background:#fff}
.bqt-table{width:100%;border-collapse:collapse;font-size:.92rem;font-variant-numeric:tabular-nums;margin:0}
.bqt-table th,.bqt-table td{border-bottom:1px solid var(--bqt-line);padding:.5rem .65rem;text-align:left;vertical-align:middle}
.bqt-table thead th{background:var(--bqt-ink);color:#fff;font-weight:700;font-size:.82rem;line-height:1.3;border-color:var(--bqt-ink)}
.bqt-table tbody th{font-weight:700;color:var(--bqt-ink)}
.bqt-table tbody tr:nth-child(even){background:#FFFCF3}
.bqt-fillbtn{font:inherit;font-size:.85rem;font-weight:700;color:var(--bqt-ink);background:#fff;border:1px solid var(--bqt-field);border-radius:6px;padding:.3rem .6rem;min-height:36px;cursor:pointer;white-space:nowrap}
.bqt-fillbtn:hover{background:var(--bqt-band)}

/* CTA */
.bqt-cta{background:var(--bqt-ink);color:#FFF0B1;border-radius:var(--bqt-radius);padding:1.4rem 1.5rem .75rem;margin:2.5rem 0}
.bqt .bqt-cta h2{color:#fff;margin-top:0}
.bqt .bqt-cta a:not(.bqt-btn){color:#FFDE51}
.bqt .bqt-cta a:not(.bqt-btn):hover{color:#fff}

/* FAQ, sources, share */
.bqt-faq h3{margin-top:1.4em}
.bqt-sources{font-size:.95rem}
.bqt-checked{color:var(--bqt-muted)}
.bqt-share{border-top:1px solid var(--bqt-line);margin-top:2rem}
.bqt-code{display:block;width:100%;font:.85rem/1.5 ui-monospace,SFMono-Regular,Consolas,monospace;color:var(--bqt-ink);background:var(--bqt-soft);border:1px solid var(--bqt-line);border-radius:8px;padding:.75rem;resize:vertical}
.bqt .bqt-cite{background:var(--bqt-soft);border-radius:8px;padding:.75rem;font-size:.95rem;margin:0}
.bqt .bqt-disclaimer{border-top:1px solid var(--bqt-line);padding-top:1.25rem;margin-top:2rem;font-size:.9rem;color:var(--bqt-muted)}

/* Cards */
.bqt ul.bqt-cards-list{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:.85rem}
.bqt ul.bqt-cards-list li{margin:0}
.bqt .bqt-cards-list a{display:flex;flex-direction:column;gap:.3rem;height:100%;border:1px solid var(--bqt-line);border-radius:var(--bqt-radius);padding:1rem;background:#fff;text-decoration:none;color:var(--bqt-text)}
.bqt .bqt-cards-list a:hover{border-color:var(--bqt-amber);box-shadow:0 2px 8px rgba(61,35,20,.14)}
.bqt .bqt-card-t{color:var(--bqt-ink);font-size:1.05rem;line-height:1.35;margin:0;font-weight:700;text-decoration:underline;text-underline-offset:2px;text-decoration-color:var(--bqt-amber)}
.bqt-cards-list span{font-size:.92rem;line-height:1.5}
.bqt-related{margin-top:2rem}
.bqt-guide{margin-top:1rem}
.bqt-group h2{margin-top:1.6rem}
.bqt-group p{margin-bottom:.75rem}

/* Embed */
.bqt-embed-body{margin:0;background:#fff;font-family:Montserrat,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif}
.bqt-embed{padding:12px 16px}
.bqt-embed .bqt-tool{margin:0}
.bqt .bqt-embed-title{font-weight:800;font-size:1.25rem;color:var(--bqt-ink);margin:0 0 .5rem}
.bqt .bqt-embed-credit{font-size:.9rem;margin:.75rem 0 0}

/* Desktop: form and answer side by side, so the result is visible while you type. */
@media (min-width:860px){
  .bqt-tool-page .bqt-tool,.bqt-embed .bqt-tool{display:grid;grid-template-columns:minmax(0,5fr) minmax(0,6fr);column-gap:1.5rem;align-items:start}
  .bqt-tool>.bqt-form{grid-column:1;grid-row:1}
  .bqt-tool>.bqt-result{grid-column:2;grid-row:1 / span 2;margin:0}
  .bqt-tool>.bqt-actions{grid-column:1;grid-row:2;margin-top:.35rem}
  .bqt-tool>noscript{grid-column:1 / -1}
  .bqt-tool .bqt-field{flex-basis:150px}
  .bqt-tool .bqt-field-wide{flex-basis:100%}
  .bqt-tool .bqt-seg,.bqt-tool .bqt-check{flex-basis:100%}
  .bqt-diagram svg{max-height:300px}
}

@media (max-width:600px){
  .bqt{font-size:1rem}
  .bqt-tool{padding:.9rem}
  .bqt-cta{padding:1.2rem 1.1rem .5rem}
  /* Number boxes sit in pairs, so the answer is close to the fields. */
  .bqt .bqt-field{flex:1 1 calc(50% - .45rem);margin-bottom:.55rem}
  .bqt .bqt-field:has(select){flex-basis:100%}
  .bqt .bqt-field-wide{flex-basis:100%}
  .bqt-seg{flex-basis:100%}
  .bqt-hint{font-size:.78rem}
  /* The tool comes straight after the title on a phone; the short answer follows it. */
  .bqt-tool-page{display:flex;flex-direction:column}
  .bqt-tool-page>*{order:3;min-width:0}
  .bqt-tool-page>.bqt-crumbs,.bqt-tool-page>.bqt-h1{order:0}
  .bqt-tool-page>.bqt-tool{order:1}
  .bqt-tool-page>.bqt-snippet{order:2;margin-top:.5rem}
  .bqt-crumbs{margin-top:.75rem}
}
@media (prefers-reduced-motion:reduce){.bqt *{transition:none!important;scroll-behavior:auto!important}}
