
/* ==========================================================
   TERVILO TEXT TOOLS — WORD COUNTER BENCHMARK
   Scoped only to .text-word-counter-benchmark
   ========================================================== */

.text-word-counter-benchmark {
    padding: 30px;
    border: 1px solid #dbeafe;
    border-radius: 22px;
    background: linear-gradient(180deg, #fbfdff 0%, #ffffff 100%);
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
}

.text-word-counter-benchmark .twc-intro {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 22px;
}
.text-word-counter-benchmark .twc-eyebrow {
    margin: 0 0 7px;
    color: #2563eb;
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}
.text-word-counter-benchmark .twc-title {
    margin: 0;
    font-size: clamp(1.55rem, 3vw, 2.05rem);
    letter-spacing: -.025em;
}
.text-word-counter-benchmark .twc-description {
    margin: 8px 0 0;
    max-width: 680px;
    color: #64748b;
    line-height: 1.65;
}
.text-word-counter-benchmark .twc-local-note {
    flex: 0 0 auto;
    padding: 9px 13px;
    border-radius: 999px;
    background: #dcfce7;
    color: #15803d;
    font-size: .82rem;
    font-weight: 800;
    white-space: nowrap;
}

.text-word-counter-benchmark .twc-editor-card {
    padding: 20px;
    border: 1px solid #dbeafe;
    border-radius: 18px;
    background: #fff;
}
.text-word-counter-benchmark .twc-label {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: baseline;
    margin-bottom: 9px;
}
.text-word-counter-benchmark .twc-label strong { font-size: .98rem; }
.text-word-counter-benchmark .twc-label span { color: #64748b; font-size: .84rem; }

.text-word-counter-benchmark textarea[data-twc-input] {
    display: block;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    min-height: 220px;
    resize: vertical;
    padding: 13px 14px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
    color: #0f172a;
    font: inherit;
    line-height: 1.55;
    outline: none;
    transition: border-color .18s ease, box-shadow .18s ease;
}
.text-word-counter-benchmark textarea[data-twc-input]:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 4px rgba(37,99,235,.09);
}

.text-word-counter-benchmark .twc-live {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 9px;
    margin-top: 12px;
}
.text-word-counter-benchmark .twc-live-item {
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #f8fafc;
}
.text-word-counter-benchmark .twc-live-item strong {
    display: block;
    color: #0f172a;
    font-size: 1.05rem;
}
.text-word-counter-benchmark .twc-live-item span {
    display: block;
    margin-top: 2px;
    color: #64748b;
    font-size: .76rem;
}

.text-word-counter-benchmark .twc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}
.text-word-counter-benchmark .twc-button {
    min-height: 48px;
    padding: 0 20px;
    border-radius: 12px;
    border: 1px solid transparent;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}
.text-word-counter-benchmark .twc-button--primary {
    color: #fff;
    background: #2563eb;
    box-shadow: 0 8px 18px rgba(37,99,235,.17);
}
.text-word-counter-benchmark .twc-button--secondary {
    color: #0f172a;
    background: #fff;
    border-color: #cbd5e1;
}
.text-word-counter-benchmark .twc-button:hover { transform: translateY(-1px); }

.text-word-counter-benchmark .twc-status {
    min-height: 24px;
    margin-top: 12px;
    color: #64748b;
    font-size: .9rem;
}
.text-word-counter-benchmark .twc-status.is-success { color: #15803d; font-weight: 750; }
.text-word-counter-benchmark .twc-status.is-error { color: #b91c1c; font-weight: 700; }

.text-word-counter-benchmark .twc-result {
    margin-top: 20px;
    overflow: hidden;
    border: 1px solid #dbeafe;
    border-radius: 20px;
    background: #fff;
}
.text-word-counter-benchmark .twc-result-head {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
    padding: 22px 24px;
    background: linear-gradient(135deg, #f8fbff, #ffffff);
    border-bottom: 1px solid #dbeafe;
}
.text-word-counter-benchmark .twc-result-eyebrow {
    margin: 0 0 6px;
    color: #2563eb;
    font-size: .78rem;
    font-weight: 850;
    letter-spacing: .12em;
}
.text-word-counter-benchmark .twc-result-title {
    margin: 0;
    font-size: 1.55rem;
}
.text-word-counter-benchmark .twc-result-subtitle {
    margin: 6px 0 0;
    color: #64748b;
}
.text-word-counter-benchmark .twc-complete {
    padding: 9px 13px;
    border-radius: 999px;
    background: #dcfce7;
    color: #15803d;
    font-size: .82rem;
    font-weight: 800;
    white-space: nowrap;
}

.text-word-counter-benchmark .twc-result-body { padding: 20px 24px 24px; }
.text-word-counter-benchmark .twc-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 12px;
}
.text-word-counter-benchmark .twc-metric {
    min-height: 112px;
    padding: 17px;
    border: 1px solid #dbeafe;
    border-radius: 16px;
    background: #f8fbff;
}
.text-word-counter-benchmark .twc-metric:nth-child(2) { background: #f0fdf4; border-color: #bbf7d0; }
.text-word-counter-benchmark .twc-metric:nth-child(3) { background: #fff7ed; border-color: #fed7aa; }
.text-word-counter-benchmark .twc-metric:nth-child(4) { background: #faf5ff; border-color: #e9d5ff; }
.text-word-counter-benchmark .twc-metric strong {
    display: block;
    color: #2563eb;
    font-size: 1.65rem;
    line-height: 1.15;
}
.text-word-counter-benchmark .twc-metric:nth-child(2) strong { color: #15803d; }
.text-word-counter-benchmark .twc-metric:nth-child(3) strong { color: #c2410c; }
.text-word-counter-benchmark .twc-metric:nth-child(4) strong { color: #7c3aed; }
.text-word-counter-benchmark .twc-metric span {
    display: block;
    margin-top: 7px;
    color: #64748b;
    font-size: .84rem;
}

.text-word-counter-benchmark .twc-panels {
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    gap: 14px;
    margin-top: 14px;
}
.text-word-counter-benchmark .twc-panel {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
}
.text-word-counter-benchmark .twc-panel-head {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 16px 18px;
    border-bottom: 1px solid #e2e8f0;
    background: #fff;
}
.text-word-counter-benchmark .twc-panel-head strong { font-size: 1rem; }
.text-word-counter-benchmark .twc-panel-head span { color: #94a3b8; font-size: .82rem; }
.text-word-counter-benchmark .twc-rows { padding: 0 18px; }
.text-word-counter-benchmark .twc-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid #eef2f7;
}
.text-word-counter-benchmark .twc-row:last-child { border-bottom: 0; }
.text-word-counter-benchmark .twc-row span { color: #64748b; }
.text-word-counter-benchmark .twc-row strong { color: #0f172a; }

.text-word-counter-benchmark .twc-explain {
    margin-top: 14px;
    border: 1px solid #dbeafe;
    border-radius: 16px;
    overflow: hidden;
}
.text-word-counter-benchmark .twc-explain-head {
    padding: 15px 18px;
    border-bottom: 1px solid #dbeafe;
    background: #f8fbff;
}
.text-word-counter-benchmark .twc-explain-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
}
.text-word-counter-benchmark .twc-explain-item {
    padding: 17px 18px;
}
.text-word-counter-benchmark .twc-explain-item + .twc-explain-item {
    border-left: 1px solid #e2e8f0;
}
.text-word-counter-benchmark .twc-explain-item strong {
    display: block;
    margin-bottom: 7px;
}
.text-word-counter-benchmark .twc-explain-item p {
    margin: 0;
    color: #64748b;
    line-height: 1.6;
    font-size: .9rem;
}

.text-word-counter-benchmark .twc-hidden {
    display: none !important;
}

@media (max-width: 850px) {
    .text-word-counter-benchmark .twc-metrics { grid-template-columns: repeat(2,1fr); }
    .text-word-counter-benchmark .twc-panels { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .text-word-counter-benchmark { padding: 18px; }
    .text-word-counter-benchmark .twc-intro { display: block; }
    .text-word-counter-benchmark .twc-local-note { display: inline-block; margin-top: 12px; }
    .text-word-counter-benchmark .twc-editor-card { padding: 14px; }
    .text-word-counter-benchmark .twc-live { grid-template-columns: repeat(2,1fr); }
    .text-word-counter-benchmark .twc-actions { display: grid; grid-template-columns: 1fr; }
    .text-word-counter-benchmark .twc-button { width: 100%; }
    .text-word-counter-benchmark .twc-result-head { display: block; padding: 18px; }
    .text-word-counter-benchmark .twc-complete { display: inline-block; margin-top: 12px; }
    .text-word-counter-benchmark .twc-result-body { padding: 14px; }
    .text-word-counter-benchmark .twc-metrics { grid-template-columns: 1fr 1fr; gap: 8px; }
    .text-word-counter-benchmark .twc-metric { min-height: 100px; padding: 13px; }
    .text-word-counter-benchmark .twc-explain-grid { grid-template-columns: 1fr; }
    .text-word-counter-benchmark .twc-explain-item + .twc-explain-item {
        border-left: 0;
        border-top: 1px solid #e2e8f0;
    }
}
