/* The free subtitle tools (/tools and /tools/...), in AutoSubtitles' tool page grammar: a 1152 px column, the
   tool as one card with an input and an output pane (stacked on a phone, side by side from 1024 px), then rows
   with the heading on the left, step cards, a centred editor card, an open FAQ and tool cards. Light and dark
   pages share it through the site's colour variables. */

.seo-body .tool,
.seo-body .seo-tool-article {
    --tool-card: var(--surface-card, var(--bg-surface));
    --tool-well: var(--bg-base);
    --tool-line: var(--bg-border);
    --tool-dim: var(--text-muted);
}
html[data-theme="dark"] .seo-body :is(.tool, .seo-tool-article) { --tool-well: #0a0a0a; --tool-chip: #fff; --tool-chip-text: #0a0a0a; }

/* Column: 20 px gutters on a phone, 32 px from 640 px, 48 px from 1024 px, and 1152 px of content. */
.seo-main > .subtitleai-container:has(.seo-tool-article) { max-width: 1248px; padding: 0 20px; }
.seo-body .seo-tool-article,
.seo-body .seo-breadcrumbs:has(+ .seo-tool-article) { max-width: none; }
.seo-body .seo-tool-article .seo-header { max-width: 48rem; }
.seo-body .seo-tool-article .seo-header h1 { font-size: 36px; line-height: 1.05; }
.seo-body .seo-tool-article h2 { margin: 0; font-size: 1.5rem; line-height: 1.25; }

.seo-body .tool {
    margin: 28px 0 64px;
    padding: 16px;
    border: 1px solid var(--tool-line);
    border-radius: 16px;
    background: var(--tool-card);
}

.seo-body .tool-grid { display: grid; gap: 24px; }
.seo-body .tool-pane { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.seo-body .tool-pane-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; }
.seo-body .tool .tool-heading { margin: 0; font-size: 1rem; line-height: 1.4; }

.seo-body .tool-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.seo-body .tool-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; }

.seo-body .tool-btn,
.seo-body .tool-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 8px;
    font: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    touch-action: manipulation;
    transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}
.seo-body .tool-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.seo-body .tool-btn:focus-visible,
.seo-body .tool-chip:focus-visible,
.seo-body .tool-text:focus-visible,
.seo-body :is(.tool-field, .tool-fps) :is(input, select):focus-visible,
.seo-body .tool-card:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
.seo-body .tool-btn:disabled { cursor: not-allowed; opacity: 0.4; }
.seo-body .tool-btn-primary { background: var(--accent); color: #fff; }
.seo-body .tool-btn-primary:not(:disabled):hover { background: var(--accent-hover); }
.seo-body .tool-btn-quiet { background: transparent; color: var(--tool-dim); }
.seo-body .tool-btn-quiet:not(:disabled):hover { color: var(--text-primary); }
html[data-theme="dark"] .seo-body .tool-btn-quiet:not(:disabled):hover { color: #fff; }

/* Format and option chips: one rounded group with a thin ring; the chosen chip is white on a dark page. */
.seo-body .tool-chips { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 4px; border-radius: 10px; background: var(--tool-well); box-shadow: inset 0 0 0 1px var(--tool-line); }
.seo-body .tool-chip { min-width: 44px; padding: 0 12px; background: transparent; color: var(--tool-dim); }
.seo-body .tool-chip[aria-pressed="true"] { background: var(--tool-chip, var(--accent)); color: var(--tool-chip-text, #fff); }
.seo-body .tool-chip[aria-pressed="false"]:hover { color: var(--text-primary); }
html[data-theme="dark"] .seo-body .tool-chip[aria-pressed="false"]:hover { color: #fff; }

.seo-body .tool-drop { border-radius: 12px; }
.seo-body .tool-drop[data-over="true"] { outline: 2px dashed var(--accent); outline-offset: 4px; }

.seo-body .tool-text {
    box-sizing: border-box;
    width: 100%;
    height: 18rem;
    padding: 16px;
    resize: vertical;
    border: 1px solid var(--tool-line);
    border-radius: 12px;
    background: var(--tool-well);
    color: inherit;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 16px;
    line-height: 1.6;
    unicode-bidi: plaintext;
}
.seo-body .tool-text::placeholder { color: var(--tool-dim); opacity: 0.8; }

.seo-body .tool-note,
.seo-body .tool-status { display: flex; align-items: center; gap: 8px; min-height: 1.5em; margin: 0; font-size: 0.875rem; color: var(--tool-dim); }
.seo-body .tool .tool-note { color: var(--tool-dim); }
.seo-body .tool-note svg { flex: none; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; }
.seo-body .tool-status[data-state="error"] { color: var(--error); }
html[data-theme="dark"] .seo-body .tool-status[data-state="error"] { color: #fca5a5; }

.seo-body .tool-styles { margin: 0; padding: 12px; border: 1px solid var(--tool-line); border-radius: 12px; }
.seo-body .tool-styles legend { padding: 0 4px; font-size: 0.875rem; font-weight: 600; }
.seo-body .tool-style-list { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.seo-body .tool-style { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 0.875rem; cursor: pointer; }
.seo-body .tool-style input { width: 20px; height: 20px; accent-color: var(--accent); }

/* Options: one compact strip, set off from the panes by a line. */
.seo-body .tool-options { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px 24px; margin: 0 0 20px; padding: 0 0 20px; border-bottom: 1px solid var(--tool-line); }
.seo-body .tool-grid + .tool-options { margin: 20px 0 0; padding: 20px 0 0; border-top: 1px solid var(--tool-line); border-bottom: 0; }
.seo-body .tool-option,
.seo-body .tool-field { display: flex; flex-direction: column; gap: 6px; }
.seo-body .tool-option-label,
.seo-body .tool-field > span,
.seo-body .tool-fps legend { padding: 0; font-size: 0.8125rem; font-weight: 600; color: var(--tool-dim); }
.seo-body :is(.tool-field, .tool-fps) :is(input, select) {
    box-sizing: border-box;
    width: 7rem;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid var(--tool-line);
    border-radius: 8px;
    background: var(--tool-well);
    color: inherit;
    font: inherit;
    font-size: 16px;
}
.seo-body .tool-fps { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; border: 0; }
.seo-body .tool-fps select { width: auto; }
.seo-body .tool-fps-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--tool-dim); font-size: 0.875rem; }

/* Below the tool: rows with the heading on the left from 1024 px. */
.seo-body .tool-row,
.seo-body .tool-steps-section,
.seo-body .tool-compare,
.seo-body .tool-more { margin: 0 0 64px; }
.seo-body .tool-row { display: grid; gap: 16px; }
.seo-body .tool-row-body > :first-child { margin-top: 0; }
.seo-body .tool-row-body p { margin: 0; line-height: 1.7; }
.seo-body .tool-list { margin: 0; padding-left: 1.25rem; line-height: 1.7; }
.seo-body .tool-list li + li { margin-top: 8px; }

.seo-body .tool-steps { display: grid; gap: 20px; margin: 20px 0 0; padding: 0; list-style: none; }
.seo-body .tool-step { margin: 0; padding: 24px; border: 1px solid var(--tool-line); border-radius: 16px; background: var(--tool-card); }
/* The step's icon on the left and "Step N" on the right, then room before the step's name. */
.seo-body .tool-step-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 32px; }
.seo-body .tool-step-icon { width: 20px; height: 20px; fill: none; stroke: var(--tool-dim); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.seo-body .tool-step-label { color: var(--tool-dim); font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.75rem; font-variant-numeric: tabular-nums; }
.seo-body .tool-step h3 { margin: 0 0 6px; font-size: 1.0625rem; }
.seo-body .tool-step p { margin: 0; color: var(--tool-dim); line-height: 1.6; }

/* The free plan's numbers under the hero: two by two on a phone, one row from 1024px. */
.seo-body .tool-facts { margin: 0 0 64px; }
.seo-body .tool-facts dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0; border: 1px solid var(--tool-line); border-radius: 16px; background: var(--tool-card); overflow: hidden; }
.seo-body .tool-facts dl > div { padding: 20px; border-color: var(--tool-line); border-style: solid; border-width: 0; }
.seo-body .tool-facts dl > div:nth-child(odd) { border-inline-end-width: 1px; }
.seo-body .tool-facts dl > div:nth-child(n + 3) { border-top-width: 1px; }
.seo-body .tool-facts dt { color: var(--tool-dim); font-size: 0.875rem; }
.seo-body .tool-facts dd { margin: 6px 0 0; font-weight: 600; }

.seo-body .tool-compare .seo-compare,
.seo-body .tool-compare table { width: 100%; margin-top: 20px; }
/* Comparison tables, as AutoSubtitles draws them: small uppercase column names, left-aligned row labels, ruled rows,
   group labels, a tinted Vid Hub column (the first value column) and marks for a plain Yes or No. The table keeps a
   readable width and scrolls inside its frame when the screen is narrower, with the row labels held at the left. */
.seo-body .tool-compare .seo-compare-wrap { overflow-x: auto; overscroll-behavior-x: contain; }
.seo-body .tool-compare .seo-compare-wrap:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
/* Separate borders move with the sticky label column; collapsed ones stay behind when the frame scrolls. */
.seo-body .tool-compare .seo-compare { border-collapse: separate; border-spacing: 0; font-size: 0.9375rem; line-height: 1.5; }
.seo-body .tool-compare .seo-compare :is(th, td) { padding: 12px 14px; border-top: 1px solid var(--tool-line); text-align: start; vertical-align: top; }
.seo-body .tool-compare .seo-compare thead th { border-top: 0; color: var(--tool-dim); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.seo-body .tool-compare .seo-compare tbody th[scope="row"] { min-width: 132px; font-weight: 600; }
.seo-body .tool-compare .seo-compare td { color: var(--tool-dim); }
.seo-body .tool-compare .seo-compare-ours :is(td:nth-child(2), thead th:nth-child(2)) { background: color-mix(in srgb, var(--accent) 10%, transparent); color: var(--text-primary); }
.seo-body .tool-compare .seo-compare :is(th[scope="row"], thead th:first-child) { position: sticky; left: 0; z-index: 1; background: var(--tool-well); }
/* "Which tool do I use?": the page's own row reads as "you are here" (copy plan part 4). */
.seo-body .tool-compare .seo-compare tr:has(> th[aria-current="page"]) > * { background: color-mix(in srgb, var(--accent) 10%, var(--tool-well)); color: var(--text-primary); }
.seo-body .tool-compare .seo-compare th[aria-current="page"] { box-shadow: inset 4px 0 0 var(--accent); font-weight: 700; }
/* A group label spans the table, so its words, not the cell, hold to the left while the frame scrolls. */
.seo-body .tool-compare .seo-compare-group th > span { position: sticky; left: 14px; }
.seo-body .seo-compare-group th { padding-top: 24px; color: var(--tool-dim); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.seo-body .tool-compare .seo-compare .plan-mark { width: 22px; height: 22px; }
.seo-body .tool-compare .seo-compare:has(thead th:nth-child(6)) { min-width: 1040px; font-size: 0.875rem; }
.seo-body .tool-compare .seo-compare:has(thead th:nth-child(6)) td { min-width: 92px; }
@media (max-width: 760px) {
    .seo-body .tool-compare .seo-compare { font-size: 0.875rem; }
    .seo-body .tool-compare .seo-compare :is(th, td) { padding: 10px 10px; }
    .seo-body .tool-compare .seo-compare tbody th[scope="row"] { min-width: 104px; }
    .seo-body .tool-compare .seo-compare:has(thead th:nth-child(6)) { min-width: 900px; }
}

/* Alternatives guides: the tools on the page as pills under the heading, then one card per tool. */
.seo-body .alt-jump ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 48px; padding: 0; list-style: none; }
.seo-body .alt-jump a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border: 1px solid var(--tool-line); border-radius: 999px; color: inherit; text-decoration: none; touch-action: manipulation; }
.seo-body .alt-section { margin: 0 0 64px; }
.seo-body .alt-method { margin: 8px 0 0; color: var(--tool-dim); }
.seo-body .alt-list { display: grid; gap: 16px; margin: 24px 0 0; padding: 0; list-style: none; }
.seo-body .alt-entry { padding: 24px; border: 1px solid var(--tool-line); border-radius: 16px; background: var(--tool-card); scroll-margin-top: 96px; }
.seo-body .alt-entry h3 { margin: 0; font-size: 1.25rem; }
.seo-body .alt-entry p { margin: 0; line-height: 1.6; }
.seo-body .alt-entry .alt-descriptor { margin: 4px 0 12px; color: var(--tool-dim); }
.seo-body .alt-points { display: grid; gap: 6px; margin: 14px 0; padding: 0; list-style: none; }
.seo-body .alt-points li { display: flex; gap: 8px; margin: 0; line-height: 1.5; }
.seo-body .alt-points li::before { content: "\2713"; color: #15803d; font-weight: 700; }
html[data-theme="dark"] .seo-body .alt-points li::before { color: #4ade80; }
.seo-body .alt-price span { margin-right: 6px; color: var(--tool-dim); font-size: 0.75rem; letter-spacing: 0.04em; text-transform: uppercase; }
/* Price at the left, the link as a bordered button at the right, as AutoSubtitles lays out a card's foot. */
.seo-body .alt-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; }
.seo-body .alt-entry a.alt-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--tool-line); border-radius: 999px; color: var(--text-primary); font-weight: 600; text-decoration: none; touch-action: manipulation; }
.seo-body .alt-entry a.alt-link:hover { border-color: var(--accent); }
html[data-theme="dark"] .seo-body .alt-entry a.alt-link { color: #fff; }

.seo-body .tool-cta {
    margin: 0 0 64px;
    padding: 40px 20px;
    border: 1px solid var(--tool-line);
    border-radius: 16px;
    background: radial-gradient(120% 140% at 50% 0%, rgba(97, 95, 255, 0.18), transparent 60%), var(--tool-card);
    text-align: center;
}
.seo-body .tool-cta p { max-width: 36rem; margin: 12px auto 24px; line-height: 1.7; }
.seo-body .tool-cta .tool-cta-note { margin: 12px auto 0; color: var(--tool-dim); font-size: 0.875rem; }

.seo-body .tool-faq-item { padding: 0 0 20px; margin: 0 0 20px; border-bottom: 1px solid var(--tool-line); }
.seo-body .tool-faq-item:last-child { margin-bottom: 0; border-bottom: 0; }
.seo-body .tool-faq-item h3 { margin: 0 0 8px; font-size: 1.0625rem; }
.seo-body .tool-faq-item p { margin: 0; color: var(--tool-dim); line-height: 1.7; }

/* Tool cards (the hub, More free tools): a file icon, the name and its line, and an arrow. */
.seo-body .tool-cards { display: grid; gap: 12px; margin: 20px 0 0; padding: 0; list-style: none; }
.seo-body .tool-hub .tool-cards { margin: 0 0 64px; }
.seo-body a.tool-card {
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 44px;
    padding: 16px 20px;
    border: 1px solid var(--tool-line);
    border-radius: 12px;
    background: var(--tool-card);
    color: inherit;
    text-decoration: none;
    transition: border-color 150ms ease;
}
.seo-body a.tool-card:hover { border-color: var(--accent); color: inherit; }
.seo-body .tool-card > svg { flex: none; width: 20px; height: 20px; fill: none; stroke: var(--tool-dim); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.seo-body .tool-card > svg:first-child { box-sizing: content-box; padding: 8px; border-radius: 8px; background: var(--tool-well); }
.seo-body .tool-card-text { display: flex; flex: 1; flex-direction: column; gap: 4px; min-width: 0; }
.seo-body .tool-card-name { font-weight: 600; }
html[data-theme="dark"] .seo-body .tool-card-name { color: #fff; }
.seo-body .tool-card-note { color: var(--tool-dim); font-size: 0.875rem; line-height: 1.5; }

.seo-body .tool-related { margin: 0 0 32px; }
.seo-body .tool-related h2 { font-size: 1rem; }
.seo-body .tool-related ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; padding: 0; list-style: none; }
.seo-body .tool-related a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--tool-line); border-radius: 999px; color: inherit; font-size: 0.875rem; text-decoration: none; }
.seo-body .tool-related a:hover { border-color: var(--accent); }

@media (min-width: 640px) {
    .seo-main > .subtitleai-container:has(.seo-tool-article) { padding: 0 32px; }
    .seo-body .seo-tool-article .seo-header h1 { font-size: 48px; }
    .seo-body .tool { padding: 24px; }
    .seo-body .tool-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .seo-body .tool-cta { padding: 48px 32px; }
    .seo-body .tool-facts dl > div { padding: 24px; }
    .seo-body .tool-facts dd { font-size: 1.125rem; }
}

@media (min-width: 768px) {
    .seo-body .tool-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    /* An odd last card takes the whole row instead of standing alone in the left column. */
    .seo-body .tool-cards > li:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

@media (min-width: 1024px) {
    .seo-main > .subtitleai-container:has(.seo-tool-article) { padding: 0 48px; }
    .seo-body .seo-tool-article .seo-header h1 { font-size: 56px; }
    .seo-body .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .seo-body .tool-text { height: 24rem; }
    .seo-body .tool-row { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 48px; }
    .seo-body .tool-facts dl { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .seo-body .tool-facts dl > div:nth-child(n) { border-width: 0; border-inline-start-width: 1px; }
    .seo-body .tool-facts dl > div:first-child { border-width: 0; }
    .seo-body .tool-facts,
    .seo-body .tool-row,
    .seo-body .tool-steps-section,
    .seo-body .tool-compare,
    .seo-body .tool-more,
    .seo-body .tool-cta { margin-bottom: 96px; }
}

@media (min-width: 1280px) {
    .seo-body .tool-steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* Smaller text only with a mouse: a tablet would zoom into a box under 16 px. */
@media (min-width: 1024px) and (pointer: fine) {
    .seo-body .tool-text { font-size: 13px; }
}

/* The larger tools: the subtitle editor, the MKV extractor and add text to a GIF. Phone first: the editor's video
   and controls sit above the subtitle list; from 1024 px they stay beside it. */
.seo-body .tool [hidden] { display: none; }
.seo-body :is([data-tool="editor"], [data-tool="gif"]) .tool-field :is(input, select) { width: 100%; }

.seo-body .tool-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 32px 16px;
    border: 1px dashed var(--tool-line);
    border-radius: 12px;
    background: var(--tool-well);
    text-align: center;
}
.seo-body .tool-dropzone[data-over="true"] { border-color: var(--accent); }
.seo-body .tool-dropzone > svg { width: 28px; height: 28px; fill: none; stroke: var(--tool-dim); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.seo-body .tool-dropzone p { margin: 0; color: var(--tool-dim); font-size: 0.875rem; }
.seo-body .tool-dropzone .tool-actions { justify-content: center; margin-top: 8px; }

.seo-body .tool-progress { width: 100%; height: 8px; accent-color: var(--accent); }
.seo-body .mkv-track-list { display: flex; flex-direction: column; }
.seo-body .mkv-track input:disabled + * { opacity: 0.5; }

.seo-body .editor-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 0 0 16px; }
.seo-body .editor-count { flex: 1 1 100%; margin: 0; font-weight: 600; }
.seo-body .editor-check { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 0.875rem; cursor: pointer; }
.seo-body .editor-check input { width: 20px; height: 20px; accent-color: var(--accent); }

.seo-body .editor-layout { display: grid; gap: 20px; }
.seo-body .editor-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

.seo-body .editor-video { position: relative; overflow: hidden; border-radius: 12px; background: #000; aspect-ratio: 16 / 9; }
.seo-body .editor-video video { display: none; width: 100%; height: 100%; object-fit: contain; }
.seo-body .tool[data-tool="editor"][data-video="true"] .editor-video video { display: block; }
.seo-body .tool[data-tool="editor"][data-video="true"] .editor-video-empty { display: none; }
.seo-body .editor-video-empty {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px;
    text-align: center;
    color: #a3a3a3;
    font-size: 0.875rem;
}
.seo-body .editor-video-empty p { margin: 0; color: #a3a3a3; }
.seo-body .editor-overlay {
    position: absolute;
    right: 8%;
    bottom: 18%;
    left: 8%;
    margin: 0;
    color: #fff;
    font-weight: 700;
    text-align: center;
    text-shadow: 0 1px 3px #000, 0 0 2px #000;
    white-space: pre-line;
    unicode-bidi: plaintext;
    pointer-events: none;
}

.seo-body .editor-panel { border: 1px solid var(--tool-line); border-radius: 12px; padding: 0 12px; }
.seo-body .editor-panel summary { display: flex; align-items: center; min-height: 44px; font-weight: 600; cursor: pointer; }
.seo-body .editor-panel[open] { padding-bottom: 12px; }
.seo-body .editor-panel[open] > :not(summary) { margin-top: 8px; }
.seo-body .editor-save { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }

.seo-body .editor-list { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; list-style: none; }
.seo-body .editor-row { padding: 12px; border: 1px solid var(--tool-line); border-radius: 12px; background: var(--tool-well); }
.seo-body .editor-row[data-problem="true"] { border-color: #f59e0b; }
.seo-body .editor-row:focus-within { border-color: var(--accent); }
.seo-body .editor-row[data-selected="true"] { box-shadow: inset 3px 0 0 var(--accent); }
.seo-body .editor-undo {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px;
    border: 1px dashed var(--tool-line);
    border-radius: 12px;
    color: var(--tool-dim);
    font-size: 0.875rem;
}
.seo-body .editor-row-head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; }
.seo-body .editor-row-number { align-self: center; min-width: 2ch; color: var(--tool-dim); font-variant-numeric: tabular-nums; }
.seo-body .editor-time { display: flex; flex-direction: column; gap: 2px; font-size: 0.75rem; color: var(--tool-dim); }
.seo-body .editor-time input,
.seo-body .editor-row-text {
    box-sizing: border-box;
    border: 1px solid var(--tool-line);
    border-radius: 8px;
    background: var(--tool-card);
    color: inherit;
    font-size: 16px;
}
.seo-body .editor-time input { width: 9.5rem; min-height: 44px; padding: 0 8px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.seo-body .editor-time input[aria-invalid="true"] { border-color: #f87171; }
.seo-body .editor-row-actions { display: flex; gap: 4px; margin-left: auto; }
.seo-body .editor-row-actions .tool-btn { padding: 0 10px; }
.seo-body .editor-row-text { display: block; width: 100%; margin-top: 8px; padding: 8px 10px; resize: vertical; line-height: 1.5; unicode-bidi: plaintext; }
.seo-body .editor-row-warning { margin: 6px 0 0; font-size: 0.8125rem; color: #b45309; }
html[data-theme="dark"] .seo-body .editor-row-warning { color: #fbbf24; }
.seo-body .editor-row-warning[hidden],
.seo-body .editor-row[hidden] { display: none; }

@media (min-width: 640px) {
    .seo-body .editor-count { flex: 1 1 auto; }
}

@media (min-width: 1024px) {
    .seo-body .editor-layout { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; }
    /* Sticky, but never taller than the window: on a short laptop screen the column scrolls on its own, so
       Download stays reachable beside a long list. */
    .seo-body .editor-side { position: sticky; top: 88px; max-height: calc(100vh - 104px); max-height: calc(100dvh - 104px); overflow-y: auto; }
}

@media (min-width: 1024px) and (pointer: fine) {
    .seo-body .editor-time input,
    .seo-body .editor-row-text { font-size: 14px; }
}

/* Add text to a GIF: the drop box, then the preview, above the controls on a phone, beside them from 1024 px.
   The controls show from the start and work once a GIF is open. */
.seo-body .gif-layout { display: grid; gap: 20px; }
.seo-body .gif-left { min-width: 0; }
.seo-body .gif-stage { display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 0; }
.seo-body .gif-preview {
    display: block;
    width: 100%;
    max-width: 640px;
    height: auto;
    border-radius: 12px;
    background: repeating-conic-gradient(#d4d4d4 0 25%, #fff 0 50%) 0 0 / 16px 16px;
}
.seo-body .gif-controls { display: flex; flex-direction: column; gap: 16px; min-width: 0; margin: 0; padding: 0; border: 0; }
.seo-body .gif-controls:disabled { opacity: 0.6; }
.seo-body .gif-download { align-self: flex-start; }

@media (min-width: 1024px) {
    .seo-body .gif-layout { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; }
}

@media (prefers-reduced-motion: reduce) {
    .seo-body .tool-btn,
    .seo-body .tool-chip,
    .seo-body .tool-card { transition: none; }
}

/* Feature pages and their hub (/features): a large upload button under the heading and once more at the end, cards in
   one column on a phone, two from 640 px and three from 1024 px, and the free against paid table. The hub's three
   groups stack on a phone and stand side by side from 1024 px. */
.seo-body .tool-hero-cta,
.seo-body .tool-cta-band { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 0 0 64px; }
.seo-body .tool-cta-band { flex-direction: column; justify-content: center; text-align: center; }
.seo-body a.tool-upload {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 56px;
    padding: 0 28px;
    border-radius: 12px;
    font-size: 1.125rem;
    touch-action: manipulation;
}
.seo-body .tool-upload svg { flex: none; width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.seo-body :is(.tool-hero-cta, .tool-cta-band) .tool-cta-note { margin: 0; color: var(--tool-dim); font-size: 0.875rem; }

.seo-body .feature-section { margin: 0 0 64px; }
.seo-body .feature-grid { display: grid; gap: 12px; margin: 20px 0 0; padding: 0; list-style: none; }
.seo-body .feature-card { margin: 0; padding: 24px; border: 1px solid var(--tool-line); border-radius: 16px; background: var(--tool-card); }
.seo-body .feature-card h3 { margin: 0 0 8px; font-size: 1.0625rem; }
html[data-theme="dark"] .seo-body .feature-card h3 { color: #fff; }
.seo-body .feature-card p { margin: 0; color: var(--tool-dim); line-height: 1.6; }
/* A picture of the editor fills the top of its card, in a 2:1 box held before it loads. */
.seo-body .feature-card.has-pic { overflow: hidden; padding-top: 0; }
.seo-body .feature-pic { margin: 0 -24px 20px; aspect-ratio: 2 / 1; border-bottom: 1px solid var(--tool-line); background: #0a0a0a; }
.seo-body .feature-pic img { display: block; width: 100%; height: 100%; object-fit: cover; }
.seo-body .feature-credit { margin: 12px 0 0; color: var(--tool-dim); font-size: 0.8125rem; }

.seo-body .feature-head { margin: 0 0 32px; }
.seo-body .feature-head p { max-width: 48rem; margin: 12px 0 0; color: var(--tool-dim); line-height: 1.7; }
.seo-body .feature-columns { display: grid; gap: 32px; margin: 0 0 64px; }
.seo-body .feature-group-label { margin: 0 0 12px; color: var(--tool-dim); font-size: 0.875rem; font-weight: 500; }
.seo-body .feature-group .tool-cards { margin: 0; }
html[data-theme="dark"] .seo-body :is(.feature-group-label, .help-topics h2) { color: var(--tool-dim); }

.seo-body .plan-table-wrap { margin-top: 20px; overflow-x: auto; }
.seo-body .plan-table { width: 100%; margin-top: 0; border-collapse: collapse; font-size: 0.9375rem; }
/* The article's list spacing would open gaps between the topic links, the pills and the hub's cards. */
.seo-body :is(.help-topics, .tool-related, .feature-group) li { margin: 0; }
.seo-body .plan-table :is(th, td) { padding: 14px 12px; border-bottom: 1px solid var(--tool-line); text-align: left; vertical-align: middle; line-height: 1.5; }
.seo-body .plan-table thead th { border-top: 1px solid var(--tool-line); color: var(--tool-dim); font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
.seo-body .plan-table tbody th { font-weight: 500; }
.seo-body .plan-table .plan-paid { background: rgba(97, 95, 255, 0.07); }
.seo-body .plan-table thead .plan-paid { color: var(--accent); }
html[data-theme="dark"] .seo-body .plan-table thead .plan-paid { color: #a5b4fc; }
.seo-body .plan-mark { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; }
.seo-body .plan-mark svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.seo-body .plan-yes { background: rgba(34, 197, 94, 0.16); color: #15803d; }
html[data-theme="dark"] .seo-body .plan-yes { color: #4ade80; }
.seo-body .plan-no { background: var(--tool-line); color: var(--tool-dim); }

/* Help pages (/help/...): the topic list first on a phone, then the heading and the text. From 1024 px the list is a
   sticky column on the left, and the heading and the text share the right column, as at AutoSubtitles. */
.seo-body .seo-tool-article:has(> .help-layout) { display: grid; grid-template-columns: minmax(0, 1fr); column-gap: 64px; margin-bottom: 64px; }
.seo-body .seo-tool-article > .help-layout { display: contents; }
.seo-body .seo-tool-article:has(> .help-layout) > .seo-header { grid-row: 2; }
.seo-body .help-topics { grid-row: 1; margin: 0 0 32px; padding: 0 0 16px; border-bottom: 1px solid var(--tool-line); }
.seo-body .help-topics h2 { margin: 0 0 8px; padding: 0 12px; color: var(--tool-dim); font-size: 0.875rem; font-weight: 600; }
.seo-body .help-topics ul { display: flex; flex-direction: column; gap: 2px; margin: 0; padding: 0; list-style: none; }
.seo-body .help-topics a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0 12px;
    border-radius: 8px;
    color: var(--tool-dim);
    text-decoration: none;
    touch-action: manipulation;
    transition: background-color 150ms ease, color 150ms ease;
}
.seo-body .help-topics a:hover,
.seo-body .help-topics a[aria-current="page"] { background: var(--tool-card); color: var(--text-primary); }
.seo-body .help-topics a[aria-current="page"] { box-shadow: inset 0 0 0 1px var(--tool-line); font-weight: 600; }
html[data-theme="dark"] .seo-body .help-topics a:is(:hover, [aria-current="page"]) { color: #fff; }
.seo-body .help-topics a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.seo-body .help-content { grid-row: 3; min-width: 0; max-width: 48rem; }
.seo-body .help-content section + section { margin-top: 40px; }
.seo-body .help-content h2 { margin: 0 0 12px; }
.seo-body .help-content p,
.seo-body .help-content ul { margin: 0 0 12px; line-height: 1.7; }
.seo-body .help-content ul { padding-left: 1.25rem; }
.seo-body .help-content li + li { margin-top: 6px; }
.seo-body .help-content .tool-faq-item p { margin: 0; }

/* A phone centres the feature page's opening and gives the upload button the full width. */
@media (max-width: 639px) {
    .seo-body .seo-tool-article:has(.tool-hero-cta) .seo-header { text-align: center; }
    .seo-body .tool-hero-cta { flex-direction: column; text-align: center; }
    .seo-body .tool-hero-cta a.tool-upload { width: 100%; }
}

@media (min-width: 640px) {
    .seo-body .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .seo-body .plan-table :is(th, td) { padding: 16px 20px; }
    .seo-body .plan-table .plan-label { width: 44%; }
}

@media (min-width: 1024px) {
    .seo-body .feature-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    /* Four cards make two rows of two, not three and one alone. */
    .seo-body .feature-grid:has(> li:nth-child(4):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .seo-body .feature-columns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .seo-body .feature-group .tool-cards { grid-template-columns: minmax(0, 1fr); }
    .seo-body .tool-hero-cta,
    .seo-body .tool-cta-band,
    .seo-body .feature-section,
    .seo-body .feature-columns { margin-bottom: 96px; }
    .seo-body .seo-tool-article:has(> .help-layout) { grid-template-columns: 15rem minmax(0, 1fr); margin-bottom: 96px; }
    .seo-body .help-topics { grid-column: 1; grid-row: 1 / span 2; align-self: start; position: sticky; top: 96px; margin: 0; padding: 0; border: 0; }
    .seo-body .seo-tool-article:has(> .help-layout) > .seo-header { grid-column: 2; grid-row: 1; }
    .seo-body .help-content { grid-column: 2; grid-row: 2; }
}
