/* === Video Compressor Tool CSS === */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --dt-bg: #0a0a0c;
    --dt-bg-card: #16161a;
    --dt-primary: #6366f1;
    --dt-primary-hover: #4f46e5;
    --dt-success: #10b981;
    --dt-text: #f8fafc;
    --dt-text-muted: #94a3b8;
    --dt-border: rgba(255, 255, 255, 0.08);
    --dt-radius: 14px;
}

html,
body {
    background: var(--dt-bg);
    color: var(--dt-text);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* --- Header --- */
.site-header {
    background: rgba(10, 10, 12, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--dt-border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.site-header .dt-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.4rem;
    font-weight: 800;
    text-decoration: none;
    color: #fff;
    letter-spacing: -0.5px;
}

.logo span {
    color: var(--dt-primary);
}

.site-header nav {
    display: flex;
    gap: 1.5rem;
}

.site-header nav a {
    color: var(--dt-text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

.site-header nav a:hover {
    color: #fff;
}

/* --- Layout --- */
.dt-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.dt-main-content {
    background: var(--dt-bg);
    min-height: 100vh;
}

.dt-mb-16 {
    margin-bottom: 4rem;
}

/* --- Hero --- */
.dt-hero {
    padding: 72px 0 40px;
    text-align: center;
}

.dt-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(99, 102, 241, 0.12);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.2);
    margin-bottom: 1.25rem;
}

.dt-title-xl {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    color: #fff;
    margin-bottom: 1.25rem;
    line-height: 1.1;
}

.dt-gradient-text {
    background: linear-gradient(135deg, #818cf8, #6366f1 50%, #4f46e5);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.dt-subtitle-lg {
    font-size: 1rem;
    color: var(--dt-text-muted);
    max-width: 640px;
    margin: 0 auto;
    line-height: 1.7;
}

/* --- Tool Grid --- */
.dt-tool-section {
    padding: 0 0 80px;
}

.dt-tool-grid {
    display: grid;
    grid-template-columns: 420px 1fr;
    gap: 32px;
    align-items: start;
}

/* --- Glass Panel --- */
.dt-glass-panel {
    background: var(--dt-bg-card);
    border: 1px solid var(--dt-border);
    border-radius: var(--dt-radius);
    padding: 24px;
}

/* --- Controls Panel --- */
.dt-controls-panel {
    position: sticky;
    top: 88px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* --- Upload Area --- */
.dt-upload-area {
    border: 2px dashed rgba(99, 102, 241, 0.3);
    border-radius: 12px;
    padding: 32px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(99, 102, 241, 0.03);
    position: relative;
}

.dt-upload-area:hover,
.dt-upload-area.drag-over {
    border-color: var(--dt-primary);
    background: rgba(99, 102, 241, 0.07);
}

.dt-upload-area.drag-over {
    transform: scale(1.01);
}

.dt-upload-content {
    pointer-events: none;
}

.dt-upload-content svg {
    color: var(--dt-primary);
    margin-bottom: 12px;
    opacity: 0.8;
}

.dt-upload-text {
    font-size: 0.95rem;
    color: #e2e8f0;
    margin-bottom: 6px;
}

.dt-upload-text strong {
    color: var(--dt-primary);
}

.dt-upload-hint {
    font-size: 0.8rem;
    color: var(--dt-text-muted);
}

/* --- File Info --- */
.dt-file-info {
    background: rgba(16, 185, 129, 0.06);
    border: 1px solid rgba(16, 185, 129, 0.15);
    border-radius: 10px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dt-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.dt-info-label {
    font-size: 0.78rem;
    color: var(--dt-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}

.dt-info-value {
    font-size: 0.88rem;
    color: #e2e8f0;
    font-weight: 500;
    text-align: right;
    word-break: break-all;
}

.dt-info-highlight {
    color: var(--dt-success);
    font-weight: 700;
}

.dt-info-primary {
    color: var(--dt-primary);
    font-weight: 700;
}

/* --- Divider --- */
.dt-divider {
    height: 1px;
    background: var(--dt-border);
    margin: 0;
}

/* --- Label --- */
.dt-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--dt-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

/* --- Control Group --- */
.dt-control-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* --- Preset Buttons --- */
.dt-preset-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.dt-preset-btn {
    flex: 1;
    min-width: 52px;
    padding: 7px 10px;
    border-radius: 8px;
    border: 1px solid var(--dt-border);
    background: rgba(255, 255, 255, 0.03);
    color: var(--dt-text-muted);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    text-align: center;
}

.dt-preset-btn:hover {
    border-color: var(--dt-primary);
    color: #fff;
    background: rgba(99, 102, 241, 0.08);
}

.dt-preset-btn.active {
    border-color: var(--dt-primary);
    background: rgba(99, 102, 241, 0.15);
    color: #a5b4fc;
}

/* --- Custom Size --- */
.dt-custom-size {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dt-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--dt-border);
    border-radius: 8px;
    color: #fff;
    padding: 10px 14px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.2s;
    -moz-appearance: textfield;
}

.dt-input::-webkit-outer-spin-button,
.dt-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.dt-input:focus {
    outline: none;
    border-color: var(--dt-primary);
}

.dt-input-suffix {
    font-size: 0.9rem;
    color: var(--dt-text-muted);
    font-weight: 600;
    flex-shrink: 0;
}

/* --- Use Case Buttons --- */
.dt-usecase-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.dt-usecase-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid var(--dt-border);
    background: rgba(255, 255, 255, 0.02);
    color: var(--dt-text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
    font-family: inherit;
}

.dt-usecase-btn:hover {
    border-color: var(--dt-primary);
    color: #fff;
    background: rgba(99, 102, 241, 0.07);
}

.dt-usecase-btn svg {
    flex-shrink: 0;
    color: var(--dt-primary);
    opacity: 0.7;
}

/* --- Bitrate Info --- */
.dt-bitrate-info {
    background: rgba(99, 102, 241, 0.06);
    border: 1px solid rgba(99, 102, 241, 0.15);
    border-radius: 10px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* --- Compress Button --- */
.dt-compress-btn {
    width: 100%;
    padding: 14px 24px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.25s;
    font-family: inherit;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.dt-compress-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #818cf8, #6366f1);
    transform: translateY(-1px);
    box-shadow: 0 8px 28px rgba(99, 102, 241, 0.4);
}

.dt-compress-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* --- Privacy Badge --- */
.dt-privacy-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--dt-text-muted);
    text-align: center;
}

.dt-privacy-badge svg {
    color: var(--dt-success);
    flex-shrink: 0;
}

/* --- Preview Panel wrappers --- */
.dt-preview-wrapper {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* --- Progress Panel --- */
.dt-progress-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.dt-panel-title {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
}

.dt-progress-bar-container {
    width: 100%;
    height: 10px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 999px;
    overflow: hidden;
}

.dt-progress-bar {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #6366f1, #818cf8, #6366f1);
    background-size: 200% 100%;
    animation: progressShimmer 1.5s linear infinite;
    transition: width 0.4s ease;
}

@keyframes progressShimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

.dt-progress-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

#progress-percent {
    font-weight: 700;
    color: var(--dt-primary);
}

#progress-status {
    color: var(--dt-text-muted);
}

.dt-progress-log {
    font-size: 0.75rem;
    color: #475569;
    font-family: monospace;
    max-height: 80px;
    overflow-y: auto;
}

/* --- Result Panel --- */
.dt-result-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.dt-result-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.dt-result-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dt-success);
}

.dt-result-stats {
    display: flex;
    align-items: center;
    gap: 12px;
}

.dt-stat-card {
    flex: 1;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--dt-border);
    border-radius: 10px;
    padding: 14px 16px;
    text-align: center;
}

.dt-stat-success {
    border-color: rgba(16, 185, 129, 0.25);
    background: rgba(16, 185, 129, 0.05);
}

.dt-stat-label {
    display: block;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--dt-text-muted);
    margin-bottom: 4px;
}

.dt-stat-value {
    font-size: 1.3rem;
    font-weight: 800;
    color: #fff;
}

.dt-stat-success .dt-stat-value {
    color: var(--dt-success);
}

.dt-stat-arrow {
    color: var(--dt-text-muted);
    flex-shrink: 0;
}

.dt-result-meta {
    font-size: 0.85rem;
    color: var(--dt-text-muted);
    text-align: center;
}

.dt-download-btn {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.25s;
    font-family: inherit;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.25);
}

.dt-download-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 28px rgba(16, 185, 129, 0.35);
}

.dt-btn-secondary {
    width: 100%;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid var(--dt-border);
    background: transparent;
    color: var(--dt-text-muted);
    font-size: 0.88rem;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.dt-btn-secondary:hover {
    border-color: var(--dt-primary);
    color: #fff;
}

/* --- How It Works --- */
.dt-howto-panel {}

.dt-steps {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 4px;
}

.dt-step {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.dt-step-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: #a5b4fc;
    font-size: 0.78rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
}

.dt-step strong {
    display: block;
    font-size: 0.9rem;
    color: #e2e8f0;
    margin-bottom: 3px;
}

.dt-step p {
    font-size: 0.82rem;
    color: var(--dt-text-muted);
    line-height: 1.6;
}

.dt-step code {
    background: rgba(99, 102, 241, 0.12);
    color: #a5b4fc;
    padding: 1px 6px;
    border-radius: 4px;
    font-size: 0.78rem;
}

/* --- SEO Content --- */
.dt-seo-content {
    padding: 48px 0 16px;
}

.dt-seo-content h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 12px;
    margin-top: 32px;
}

.dt-seo-content h2:first-child {
    margin-top: 0;
}

.dt-seo-content p {
    font-size: 0.9rem;
    color: var(--dt-text-muted);
    line-height: 1.8;
    margin-bottom: 12px;
}

.dt-seo-content code {
    background: rgba(99, 102, 241, 0.12);
    color: #a5b4fc;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.dt-formula-block {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-left: 3px solid var(--dt-primary);
    border-radius: 8px;
    padding: 14px 18px;
    margin: 16px 0;
    font-family: monospace;
}

.dt-formula-block code {
    background: none;
    color: #86efac;
    padding: 0;
    font-size: 0.92rem;
}

.dt-limits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.dt-limit-card {
    background: var(--dt-bg-card);
    border: 1px solid var(--dt-border);
    border-radius: 10px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dt-limit-card strong {
    font-size: 0.82rem;
    color: #e2e8f0;
}

.dt-limit-card span {
    font-size: 0.88rem;
    color: var(--dt-primary);
    font-weight: 700;
}

/* --- FAQ styles (same as all tools) --- */
.faq-section {
    max-width: 720px;
    margin: 0 auto;
    padding: 48px 20px 56px;
}

.faq-heading {
    font-size: 1.6rem;
    font-weight: 800;
    text-align: center;
    color: #fff;
    margin-bottom: 2rem;
    letter-spacing: -0.3px;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.faq-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transition: background 0.25s ease;
}

.faq-item:first-child {
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.faq-item:hover {
    background: rgba(255, 255, 255, 0.02);
}

details.faq-item summary {
    padding: 20px 8px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #cbd5e1;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    transition: color 0.2s ease;
    -webkit-user-select: none;
    user-select: none;
    line-height: 1.5;
}

details.faq-item summary::-webkit-details-marker {
    display: none;
}

details.faq-item summary::after {
    content: '';
    width: 10px;
    height: 10px;
    border-right: 2px solid #6366f1;
    border-bottom: 2px solid #6366f1;
    transform: rotate(45deg);
    flex-shrink: 0;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-right: 4px;
}

details[open].faq-item summary::after {
    transform: rotate(-135deg);
}

details.faq-item summary:hover {
    color: #fff;
}

details[open].faq-item summary {
    color: #a5b4fc;
}

details.faq-item p {
    padding: 0 8px 20px 8px;
    font-size: 0.88rem;
    line-height: 1.8;
    color: #64748b;
    animation: faqFadeIn 0.35s ease-out;
}

@keyframes faqFadeIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Related Tools --- */
.related-section {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 20px 48px;
}

.related-heading {
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 1rem;
    text-align: center;
}

.related-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.related-card {
    padding: 10px 18px;
    border-radius: 10px;
    border: 1px solid var(--dt-border);
    background: var(--dt-bg-card);
    color: var(--dt-text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
}

.related-card:hover {
    border-color: var(--dt-primary);
    color: #fff;
    background: rgba(99, 102, 241, 0.06);
}

/* --- Footer --- */
.site-footer {
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--dt-border);
    background: var(--dt-bg);
    font-size: 0.85rem;
    color: var(--dt-text-muted);
    line-height: 2;
}

.site-footer a {
    color: var(--dt-text-muted);
    text-decoration: none;
}

.site-footer a:hover {
    color: #fff;
}

/* --- Mobile Responsive --- */
@media (max-width: 1024px) {
    .dt-tool-grid {
        grid-template-columns: 1fr;
    }

    .dt-controls-panel {
        position: static;
    }
}

@media (max-width: 768px) {
    .dt-hero {
        padding: 40px 0 24px;
    }

    .dt-title-xl {
        font-size: clamp(1.6rem, 6vw, 2.2rem);
    }

    .dt-subtitle-lg {
        font-size: 0.9rem;
    }

    .dt-container {
        padding: 0 14px;
    }

    .dt-glass-panel {
        padding: 16px;
    }

    .dt-preset-row {
        gap: 4px;
    }

    .dt-preset-btn {
        padding: 6px 8px;
        font-size: 0.78rem;
    }

    .dt-input {
        font-size: 16px;
    }

    .dt-result-stats {
        flex-direction: column;
    }

    .dt-stat-arrow {
        transform: rotate(90deg);
    }

    .dt-limits-grid {
        grid-template-columns: 1fr 1fr;
    }

    .faq-section {
        padding: 32px 16px 40px;
    }

    .faq-heading {
        font-size: 1.3rem;
    }
}

/* ============================================================
   === MOBILE-FIRST RESPONSIVE OVERRIDES ===
   Auto-injected by fix-mobile.cjs — global across all tools
   ============================================================ */

/* --- Universal Touch Targets --- */
@media (max-width: 768px) {
    button, .dt-btn-primary, .dt-btn-ghost, .dt-btn-success,
    .tx-btn, .fmt-btn, .hdr-btn, .tab-btn, .r-tab, .mode-btn,
    input[type="button"], input[type="submit"] {
        min-height: 44px;
        min-width: 44px;
    }
}

/* --- Container padding --- */
@media (max-width: 768px) {
    .dt-container, .container, [class*="container"] {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* --- Site Header: collapse nav on mobile --- */
@media (max-width: 768px) {
    .site-header .dt-container {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    nav {
        display: none;
    }

    .logo {
        font-size: 1.25rem !important;
    }
}

/* --- Hero Section --- */
@media (max-width: 768px) {
    .dt-hero, section.hero, .hero-section {
        padding: 36px 0 20px !important;
        text-align: center;
    }

    .dt-title-xl, .hero-title, h1 {
        font-size: clamp(1.6rem, 6vw, 2.4rem) !important;
        letter-spacing: -0.5px !important;
        line-height: 1.2 !important;
    }

    .dt-subtitle-lg, .hero-subtitle {
        font-size: 0.95rem !important;
        line-height: 1.65 !important;
    }
}

/* --- All 2-col / 3-col / 4-col grids → single column --- */
@media (max-width: 768px) {
    .input-grid,
    .two-col, .two-column,
    .info-grid, .tool-layout,
    .buttons-col,
    .gap-layout,
    .score-card,
    .ctrl-row {
        grid-template-columns: 1fr !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }

    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"] {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.85rem !important;
    }

    .verb-bank,
    .killer-grid,
    .stat-row,
    .score-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.65rem !important;
    }
}

@media (max-width: 480px) {
    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"],
    .verb-bank,
    .killer-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Textareas → full width, shorter min-height on mobile --- */
@media (max-width: 768px) {
    .dt-textarea, textarea {
        min-height: 180px !important;
        font-size: 0.92rem !important;
        padding: 1rem !important;
        border-radius: 12px !important;
    }
}

/* --- Action bars / analyze bars --- */
@media (max-width: 768px) {
    .analyze-bar, .action-row, .ctrl-actions,
    .action-bar, .tool-actions, .btn-bar {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.65rem !important;
    }

    .analyze-bar button, .action-row button,
    .action-row .dt-btn-primary, .action-row .dt-btn-ghost,
    .action-row .dt-btn-success {
        width: 100% !important;
        justify-content: center !important;
    }
}

/* --- Format/tab selectors --- */
@media (max-width: 640px) {
    .format-selector, .result-tabs, .tab-group, .mode-tabs {
        flex-wrap: wrap !important;
        gap: 0.4rem !important;
    }

    .r-tab, .tab-btn, .mode-btn {
        font-size: 0.78rem !important;
        padding: 0.55rem 0.75rem !important;
    }
}

/* --- Score card (ATS) --- */
@media (max-width: 768px) {
    .score-card {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 1.25rem !important;
        padding: 1.5rem !important;
    }

    .score-ring-wrap {
        width: 120px !important;
        height: 120px !important;
    }

    .score-ring {
        width: 120px !important;
        height: 120px !important;
    }

    .score-num {
        font-size: 1.6rem !important;
    }

    .score-meta h2 {
        font-size: 1.25rem !important;
    }

    .score-stats {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

/* --- Tables → horizontal scroll --- */
@media (max-width: 768px) {
    .table-wrap, .dt-table-wrap {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 500px;
    }
}

/* --- Cards grid → 2 col then 1 col --- */
@media (max-width: 768px) {
    .file-grid, .card-grid, .item-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
        gap: 0.75rem !important;
    }
}

/* --- Form inputs, selects --- */
@media (max-width: 768px) {
    input[type="text"], input[type="number"],
    input[type="email"], input[type="url"],
    input[type="search"], select {
        font-size: 16px !important; /* prevents iOS zoom */
        padding: 0.7rem 1rem !important;
        border-radius: 10px !important;
    }

    .dt-select, .form-select, .dt-input {
        font-size: 16px !important;
    }
}

/* --- Sliders --- */
@media (max-width: 768px) {
    .dt-slider, input[type="range"] {
        width: 100% !important;
    }
}

/* --- Glass panels --- */
@media (max-width: 768px) {
    .dt-glass-panel, .glass-card, .card-panel {
        padding: 1.5rem !important;
        border-radius: 16px !important;
    }
}

/* --- Tool section padding --- */
@media (max-width: 768px) {
    .tool-section, section.tool-section {
        padding-bottom: 32px !important;
    }

    .features-section {
        padding: 1.5rem 0 1rem !important;
    }
}

/* --- Privacy badge / format badges --- */
@media (max-width: 480px) {
    .privacy-badge {
        font-size: 0.74rem !important;
        padding: 5px 12px !important;
    }

    .format-badges {
        gap: 0.35rem !important;
    }

    .fmt-in, .fmt-out {
        padding: 4px 10px !important;
        font-size: 0.75rem !important;
    }
}

/* --- Keyword tags wrap properly --- */
@media (max-width: 768px) {
    .kw-tags, .verb-suggestions, .format-badges {
        flex-wrap: wrap !important;
    }
}

/* --- Case converter sticky → not sticky on mobile --- */
@media (max-width: 1100px) {
    .input-col {
        position: static !important;
    }
}

/* --- Global control row on image converter --- */
@media (max-width: 768px) {
    .global-controls {
        padding: 1rem !important;
    }

    .format-selector {
        flex-wrap: wrap !important;
    }
}

/* --- Meeting planner / complex tool layouts --- */
@media (max-width: 768px) {
    .planner-layout, .tool-grid, .split-layout, .two-pane {
        flex-direction: column !important;
        gap: 1rem !important;
    }
}

/* --- Drop zone on mobile --- */
@media (max-width: 768px) {
    .drop-zone {
        padding: 36px 20px !important;
    }

    .drop-zone h3 {
        font-size: 1.1rem !important;
    }
}

/* --- Stats strip wraps neatly --- */
@media (max-width: 640px) {
    .stats-strip {
        gap: 0.5rem !important;
        padding: 0.65rem 1rem !important;
        flex-wrap: wrap !important;
    }

    .stat span {
        font-size: 0.95rem !important;
    }

    .copy-row {
        margin-left: 0 !important;
        width: 100% !important;
        justify-content: flex-end !important;
    }
}

/* --- Footer --- */
@media (max-width: 768px) {
    .site-footer {
        padding: 32px 0 !important;
        font-size: 0.82rem !important;
    }
}

/* --- Prevent horizontal overflow --- */
body {
    overflow-x: hidden;
}

@media (max-width: 768px) {
    * {
        max-width: 100%;
    }

    img, canvas, video, iframe {
        max-width: 100% !important;
        height: auto !important;
    }
}

/* ============================================
   Global Scrollbar Override — Modern & Dark
   ============================================ */

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(99, 102, 241, 0.4) rgba(255, 255, 255, 0.03);
}

/* Chromium / Safari */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.35);
    border-radius: 10px;
    transition: background 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(99, 102, 241, 0.65);
}

::-webkit-scrollbar-corner {
    background: transparent;
}


/* ============================================================
   === MOBILE-FIRST RESPONSIVE OVERRIDES ===
   Auto-injected by fix-mobile.cjs — global across all tools
   ============================================================ */

/* --- Universal Touch Targets --- */
@media (max-width: 768px) {
    button, .dt-btn-primary, .dt-btn-ghost, .dt-btn-success,
    .tx-btn, .fmt-btn, .hdr-btn, .tab-btn, .r-tab, .mode-btn,
    input[type="button"], input[type="submit"] {
        min-height: 44px;
        min-width: 44px;
    }
}

/* --- Container padding --- */
@media (max-width: 768px) {
    .dt-container, .container, [class*="container"] {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* --- Site Header: collapse nav on mobile --- */
@media (max-width: 768px) {
    .site-header .dt-container {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    nav {
        display: none;
    }

    .logo {
        font-size: 1.25rem !important;
    }
}

/* --- Hero Section --- */
@media (max-width: 768px) {
    .dt-hero, section.hero, .hero-section {
        padding: 36px 0 20px !important;
        text-align: center;
    }

    .dt-title-xl, .hero-title, h1 {
        font-size: clamp(1.6rem, 6vw, 2.4rem) !important;
        letter-spacing: -0.5px !important;
        line-height: 1.2 !important;
    }

    .dt-subtitle-lg, .hero-subtitle {
        font-size: 0.95rem !important;
        line-height: 1.65 !important;
    }
}

/* --- All 2-col / 3-col / 4-col grids → single column --- */
@media (max-width: 768px) {
    .input-grid,
    .two-col, .two-column,
    .info-grid, .tool-layout,
    .buttons-col,
    .gap-layout,
    .score-card,
    .ctrl-row {
        grid-template-columns: 1fr !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }

    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"] {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.85rem !important;
    }

    .verb-bank,
    .killer-grid,
    .stat-row,
    .score-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.65rem !important;
    }
}

@media (max-width: 480px) {
    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"],
    .verb-bank,
    .killer-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Textareas → full width, shorter min-height on mobile --- */
@media (max-width: 768px) {
    .dt-textarea, textarea {
        min-height: 180px !important;
        font-size: 0.92rem !important;
        padding: 1rem !important;
        border-radius: 12px !important;
    }
}

/* --- Action bars / analyze bars --- */
@media (max-width: 768px) {
    .analyze-bar, .action-row, .ctrl-actions,
    .action-bar, .tool-actions, .btn-bar {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.65rem !important;
    }

    .analyze-bar button, .action-row button,
    .action-row .dt-btn-primary, .action-row .dt-btn-ghost,
    .action-row .dt-btn-success {
        width: 100% !important;
        justify-content: center !important;
    }
}

/* --- Format/tab selectors --- */
@media (max-width: 640px) {
    .format-selector, .result-tabs, .tab-group, .mode-tabs {
        flex-wrap: wrap !important;
        gap: 0.4rem !important;
    }

    .r-tab, .tab-btn, .mode-btn {
        font-size: 0.78rem !important;
        padding: 0.55rem 0.75rem !important;
    }
}

/* --- Score card (ATS) --- */
@media (max-width: 768px) {
    .score-card {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 1.25rem !important;
        padding: 1.5rem !important;
    }

    .score-ring-wrap {
        width: 120px !important;
        height: 120px !important;
    }

    .score-ring {
        width: 120px !important;
        height: 120px !important;
    }

    .score-num {
        font-size: 1.6rem !important;
    }

    .score-meta h2 {
        font-size: 1.25rem !important;
    }

    .score-stats {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

/* --- Tables → horizontal scroll --- */
@media (max-width: 768px) {
    .table-wrap, .dt-table-wrap {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 500px;
    }
}

/* --- Cards grid → 2 col then 1 col --- */
@media (max-width: 768px) {
    .file-grid, .card-grid, .item-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
        gap: 0.75rem !important;
    }
}

/* --- Form inputs, selects --- */
@media (max-width: 768px) {
    input[type="text"], input[type="number"],
    input[type="email"], input[type="url"],
    input[type="search"], select {
        font-size: 16px !important; /* prevents iOS zoom */
        padding: 0.7rem 1rem !important;
        border-radius: 10px !important;
    }

    .dt-select, .form-select, .dt-input {
        font-size: 16px !important;
    }
}

/* --- Sliders --- */
@media (max-width: 768px) {
    .dt-slider, input[type="range"] {
        width: 100% !important;
    }
}

/* --- Glass panels --- */
@media (max-width: 768px) {
    .dt-glass-panel, .glass-card, .card-panel {
        padding: 1.5rem !important;
        border-radius: 16px !important;
    }
}

/* --- Tool section padding --- */
@media (max-width: 768px) {
    .tool-section, section.tool-section {
        padding-bottom: 32px !important;
    }

    .features-section {
        padding: 1.5rem 0 1rem !important;
    }
}

/* --- Privacy badge / format badges --- */
@media (max-width: 480px) {
    .privacy-badge {
        font-size: 0.74rem !important;
        padding: 5px 12px !important;
    }

    .format-badges {
        gap: 0.35rem !important;
    }

    .fmt-in, .fmt-out {
        padding: 4px 10px !important;
        font-size: 0.75rem !important;
    }
}

/* --- Keyword tags wrap properly --- */
@media (max-width: 768px) {
    .kw-tags, .verb-suggestions, .format-badges {
        flex-wrap: wrap !important;
    }
}

/* --- Case converter sticky → not sticky on mobile --- */
@media (max-width: 1100px) {
    .input-col {
        position: static !important;
    }
}

/* --- Global control row on image converter --- */
@media (max-width: 768px) {
    .global-controls {
        padding: 1rem !important;
    }

    .format-selector {
        flex-wrap: wrap !important;
    }
}

/* --- Meeting planner / complex tool layouts --- */
@media (max-width: 768px) {
    .planner-layout, .tool-grid, .split-layout, .two-pane {
        flex-direction: column !important;
        gap: 1rem !important;
    }
}

/* --- Drop zone on mobile --- */
@media (max-width: 768px) {
    .drop-zone {
        padding: 36px 20px !important;
    }

    .drop-zone h3 {
        font-size: 1.1rem !important;
    }
}

/* --- Stats strip wraps neatly --- */
@media (max-width: 640px) {
    .stats-strip {
        gap: 0.5rem !important;
        padding: 0.65rem 1rem !important;
        flex-wrap: wrap !important;
    }

    .stat span {
        font-size: 0.95rem !important;
    }

    .copy-row {
        margin-left: 0 !important;
        width: 100% !important;
        justify-content: flex-end !important;
    }
}

/* --- Footer --- */
@media (max-width: 768px) {
    .site-footer {
        padding: 32px 0 !important;
        font-size: 0.82rem !important;
    }
}

/* --- Prevent horizontal overflow --- */
body {
    overflow-x: hidden;
}

@media (max-width: 768px) {
    * {
        max-width: 100%;
    }

    img, canvas, video, iframe {
        max-width: 100% !important;
        height: auto !important;
    }
}


/* ============================================================
   === MOBILE-FIRST RESPONSIVE OVERRIDES ===
   Auto-injected by fix-mobile.cjs — global across all tools
   ============================================================ */

/* --- Universal Touch Targets --- */
@media (max-width: 768px) {
    button, .dt-btn-primary, .dt-btn-ghost, .dt-btn-success,
    .tx-btn, .fmt-btn, .hdr-btn, .tab-btn, .r-tab, .mode-btn,
    input[type="button"], input[type="submit"] {
        min-height: 44px;
        min-width: 44px;
    }
}

/* --- Container padding --- */
@media (max-width: 768px) {
    .dt-container, .container, [class*="container"] {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* --- Site Header: collapse nav on mobile --- */
@media (max-width: 768px) {
    .site-header .dt-container {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    nav {
        display: none;
    }

    .logo {
        font-size: 1.25rem !important;
    }
}

/* --- Hero Section --- */
@media (max-width: 768px) {
    .dt-hero, section.hero, .hero-section {
        padding: 36px 0 20px !important;
        text-align: center;
    }

    .dt-title-xl, .hero-title, h1 {
        font-size: clamp(1.6rem, 6vw, 2.4rem) !important;
        letter-spacing: -0.5px !important;
        line-height: 1.2 !important;
    }

    .dt-subtitle-lg, .hero-subtitle {
        font-size: 0.95rem !important;
        line-height: 1.65 !important;
    }
}

/* --- All 2-col / 3-col / 4-col grids → single column --- */
@media (max-width: 768px) {
    .input-grid,
    .two-col, .two-column,
    .info-grid, .tool-layout,
    .buttons-col,
    .gap-layout,
    .score-card,
    .ctrl-row {
        grid-template-columns: 1fr !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }

    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"] {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.85rem !important;
    }

    .verb-bank,
    .killer-grid,
    .stat-row,
    .score-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.65rem !important;
    }
}

@media (max-width: 480px) {
    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"],
    .verb-bank,
    .killer-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Textareas → full width, shorter min-height on mobile --- */
@media (max-width: 768px) {
    .dt-textarea, textarea {
        min-height: 180px !important;
        font-size: 0.92rem !important;
        padding: 1rem !important;
        border-radius: 12px !important;
    }
}

/* --- Action bars / analyze bars --- */
@media (max-width: 768px) {
    .analyze-bar, .action-row, .ctrl-actions,
    .action-bar, .tool-actions, .btn-bar {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.65rem !important;
    }

    .analyze-bar button, .action-row button,
    .action-row .dt-btn-primary, .action-row .dt-btn-ghost,
    .action-row .dt-btn-success {
        width: 100% !important;
        justify-content: center !important;
    }
}

/* --- Format/tab selectors --- */
@media (max-width: 640px) {
    .format-selector, .result-tabs, .tab-group, .mode-tabs {
        flex-wrap: wrap !important;
        gap: 0.4rem !important;
    }

    .r-tab, .tab-btn, .mode-btn {
        font-size: 0.78rem !important;
        padding: 0.55rem 0.75rem !important;
    }
}

/* --- Score card (ATS) --- */
@media (max-width: 768px) {
    .score-card {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 1.25rem !important;
        padding: 1.5rem !important;
    }

    .score-ring-wrap {
        width: 120px !important;
        height: 120px !important;
    }

    .score-ring {
        width: 120px !important;
        height: 120px !important;
    }

    .score-num {
        font-size: 1.6rem !important;
    }

    .score-meta h2 {
        font-size: 1.25rem !important;
    }

    .score-stats {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

/* --- Tables → horizontal scroll --- */
@media (max-width: 768px) {
    .table-wrap, .dt-table-wrap {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 500px;
    }
}

/* --- Cards grid → 2 col then 1 col --- */
@media (max-width: 768px) {
    .file-grid, .card-grid, .item-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
        gap: 0.75rem !important;
    }
}

/* --- Form inputs, selects --- */
@media (max-width: 768px) {
    input[type="text"], input[type="number"],
    input[type="email"], input[type="url"],
    input[type="search"], select {
        font-size: 16px !important; /* prevents iOS zoom */
        padding: 0.7rem 1rem !important;
        border-radius: 10px !important;
    }

    .dt-select, .form-select, .dt-input {
        font-size: 16px !important;
    }
}

/* --- Sliders --- */
@media (max-width: 768px) {
    .dt-slider, input[type="range"] {
        width: 100% !important;
    }
}

/* --- Glass panels --- */
@media (max-width: 768px) {
    .dt-glass-panel, .glass-card, .card-panel {
        padding: 1.5rem !important;
        border-radius: 16px !important;
    }
}

/* --- Tool section padding --- */
@media (max-width: 768px) {
    .tool-section, section.tool-section {
        padding-bottom: 32px !important;
    }

    .features-section {
        padding: 1.5rem 0 1rem !important;
    }
}

/* --- Privacy badge / format badges --- */
@media (max-width: 480px) {
    .privacy-badge {
        font-size: 0.74rem !important;
        padding: 5px 12px !important;
    }

    .format-badges {
        gap: 0.35rem !important;
    }

    .fmt-in, .fmt-out {
        padding: 4px 10px !important;
        font-size: 0.75rem !important;
    }
}

/* --- Keyword tags wrap properly --- */
@media (max-width: 768px) {
    .kw-tags, .verb-suggestions, .format-badges {
        flex-wrap: wrap !important;
    }
}

/* --- Case converter sticky → not sticky on mobile --- */
@media (max-width: 1100px) {
    .input-col {
        position: static !important;
    }
}

/* --- Global control row on image converter --- */
@media (max-width: 768px) {
    .global-controls {
        padding: 1rem !important;
    }

    .format-selector {
        flex-wrap: wrap !important;
    }
}

/* --- Meeting planner / complex tool layouts --- */
@media (max-width: 768px) {
    .planner-layout, .tool-grid, .split-layout, .two-pane {
        flex-direction: column !important;
        gap: 1rem !important;
    }
}

/* --- Drop zone on mobile --- */
@media (max-width: 768px) {
    .drop-zone {
        padding: 36px 20px !important;
    }

    .drop-zone h3 {
        font-size: 1.1rem !important;
    }
}

/* --- Stats strip wraps neatly --- */
@media (max-width: 640px) {
    .stats-strip {
        gap: 0.5rem !important;
        padding: 0.65rem 1rem !important;
        flex-wrap: wrap !important;
    }

    .stat span {
        font-size: 0.95rem !important;
    }

    .copy-row {
        margin-left: 0 !important;
        width: 100% !important;
        justify-content: flex-end !important;
    }
}

/* --- Footer --- */
@media (max-width: 768px) {
    .site-footer {
        padding: 32px 0 !important;
        font-size: 0.82rem !important;
    }
}

/* --- Prevent horizontal overflow --- */
body {
    overflow-x: hidden;
}

@media (max-width: 768px) {
    * {
        max-width: 100%;
    }

    img, canvas, video, iframe {
        max-width: 100% !important;
        height: auto !important;
    }
}


/* ============================================================
   === MOBILE-FIRST RESPONSIVE OVERRIDES ===
   Auto-injected by fix-mobile.cjs — global across all tools
   ============================================================ */

/* --- Universal Touch Targets --- */
@media (max-width: 768px) {
    button, .dt-btn-primary, .dt-btn-ghost, .dt-btn-success,
    .tx-btn, .fmt-btn, .hdr-btn, .tab-btn, .r-tab, .mode-btn,
    input[type="button"], input[type="submit"] {
        min-height: 44px;
        min-width: 44px;
    }
}

/* --- Container padding --- */
@media (max-width: 768px) {
    .dt-container, .container, [class*="container"] {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* --- Site Header: collapse nav on mobile --- */
@media (max-width: 768px) {
    .site-header .dt-container {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    nav {
        display: none;
    }

    .logo {
        font-size: 1.25rem !important;
    }
}

/* --- Hero Section --- */
@media (max-width: 768px) {
    .dt-hero, section.hero, .hero-section {
        padding: 36px 0 20px !important;
        text-align: center;
    }

    .dt-title-xl, .hero-title, h1 {
        font-size: clamp(1.6rem, 6vw, 2.4rem) !important;
        letter-spacing: -0.5px !important;
        line-height: 1.2 !important;
    }

    .dt-subtitle-lg, .hero-subtitle {
        font-size: 0.95rem !important;
        line-height: 1.65 !important;
    }
}

/* --- All 2-col / 3-col / 4-col grids → single column --- */
@media (max-width: 768px) {
    .input-grid,
    .two-col, .two-column,
    .info-grid, .tool-layout,
    .buttons-col,
    .gap-layout,
    .score-card,
    .ctrl-row {
        grid-template-columns: 1fr !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }

    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"] {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.85rem !important;
    }

    .verb-bank,
    .killer-grid,
    .stat-row,
    .score-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.65rem !important;
    }
}

@media (max-width: 480px) {
    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"],
    .verb-bank,
    .killer-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Textareas → full width, shorter min-height on mobile --- */
@media (max-width: 768px) {
    .dt-textarea, textarea {
        min-height: 180px !important;
        font-size: 0.92rem !important;
        padding: 1rem !important;
        border-radius: 12px !important;
    }
}

/* --- Action bars / analyze bars --- */
@media (max-width: 768px) {
    .analyze-bar, .action-row, .ctrl-actions,
    .action-bar, .tool-actions, .btn-bar {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.65rem !important;
    }

    .analyze-bar button, .action-row button,
    .action-row .dt-btn-primary, .action-row .dt-btn-ghost,
    .action-row .dt-btn-success {
        width: 100% !important;
        justify-content: center !important;
    }
}

/* --- Format/tab selectors --- */
@media (max-width: 640px) {
    .format-selector, .result-tabs, .tab-group, .mode-tabs {
        flex-wrap: wrap !important;
        gap: 0.4rem !important;
    }

    .r-tab, .tab-btn, .mode-btn {
        font-size: 0.78rem !important;
        padding: 0.55rem 0.75rem !important;
    }
}

/* --- Score card (ATS) --- */
@media (max-width: 768px) {
    .score-card {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 1.25rem !important;
        padding: 1.5rem !important;
    }

    .score-ring-wrap {
        width: 120px !important;
        height: 120px !important;
    }

    .score-ring {
        width: 120px !important;
        height: 120px !important;
    }

    .score-num {
        font-size: 1.6rem !important;
    }

    .score-meta h2 {
        font-size: 1.25rem !important;
    }

    .score-stats {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

/* --- Tables → horizontal scroll --- */
@media (max-width: 768px) {
    .table-wrap, .dt-table-wrap {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 500px;
    }
}

/* --- Cards grid → 2 col then 1 col --- */
@media (max-width: 768px) {
    .file-grid, .card-grid, .item-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
        gap: 0.75rem !important;
    }
}

/* --- Form inputs, selects --- */
@media (max-width: 768px) {
    input[type="text"], input[type="number"],
    input[type="email"], input[type="url"],
    input[type="search"], select {
        font-size: 16px !important; /* prevents iOS zoom */
        padding: 0.7rem 1rem !important;
        border-radius: 10px !important;
    }

    .dt-select, .form-select, .dt-input {
        font-size: 16px !important;
    }
}

/* --- Sliders --- */
@media (max-width: 768px) {
    .dt-slider, input[type="range"] {
        width: 100% !important;
    }
}

/* --- Glass panels --- */
@media (max-width: 768px) {
    .dt-glass-panel, .glass-card, .card-panel {
        padding: 1.5rem !important;
        border-radius: 16px !important;
    }
}

/* --- Tool section padding --- */
@media (max-width: 768px) {
    .tool-section, section.tool-section {
        padding-bottom: 32px !important;
    }

    .features-section {
        padding: 1.5rem 0 1rem !important;
    }
}

/* --- Privacy badge / format badges --- */
@media (max-width: 480px) {
    .privacy-badge {
        font-size: 0.74rem !important;
        padding: 5px 12px !important;
    }

    .format-badges {
        gap: 0.35rem !important;
    }

    .fmt-in, .fmt-out {
        padding: 4px 10px !important;
        font-size: 0.75rem !important;
    }
}

/* --- Keyword tags wrap properly --- */
@media (max-width: 768px) {
    .kw-tags, .verb-suggestions, .format-badges {
        flex-wrap: wrap !important;
    }
}

/* --- Case converter sticky → not sticky on mobile --- */
@media (max-width: 1100px) {
    .input-col {
        position: static !important;
    }
}

/* --- Global control row on image converter --- */
@media (max-width: 768px) {
    .global-controls {
        padding: 1rem !important;
    }

    .format-selector {
        flex-wrap: wrap !important;
    }
}

/* --- Meeting planner / complex tool layouts --- */
@media (max-width: 768px) {
    .planner-layout, .tool-grid, .split-layout, .two-pane {
        flex-direction: column !important;
        gap: 1rem !important;
    }
}

/* --- Drop zone on mobile --- */
@media (max-width: 768px) {
    .drop-zone {
        padding: 36px 20px !important;
    }

    .drop-zone h3 {
        font-size: 1.1rem !important;
    }
}

/* --- Stats strip wraps neatly --- */
@media (max-width: 640px) {
    .stats-strip {
        gap: 0.5rem !important;
        padding: 0.65rem 1rem !important;
        flex-wrap: wrap !important;
    }

    .stat span {
        font-size: 0.95rem !important;
    }

    .copy-row {
        margin-left: 0 !important;
        width: 100% !important;
        justify-content: flex-end !important;
    }
}

/* --- Footer --- */
@media (max-width: 768px) {
    .site-footer {
        padding: 32px 0 !important;
        font-size: 0.82rem !important;
    }
}

/* --- Prevent horizontal overflow --- */
body {
    overflow-x: hidden;
}

@media (max-width: 768px) {
    * {
        max-width: 100%;
    }

    img, canvas, video, iframe {
        max-width: 100% !important;
        height: auto !important;
    }
}


/* ============================================================
   === MOBILE-FIRST RESPONSIVE OVERRIDES ===
   Auto-injected by fix-mobile.cjs — global across all tools
   ============================================================ */

/* --- Universal Touch Targets --- */
@media (max-width: 768px) {
    button, .dt-btn-primary, .dt-btn-ghost, .dt-btn-success,
    .tx-btn, .fmt-btn, .hdr-btn, .tab-btn, .r-tab, .mode-btn,
    input[type="button"], input[type="submit"] {
        min-height: 44px;
        min-width: 44px;
    }
}

/* --- Container padding --- */
@media (max-width: 768px) {
    .dt-container, .container, [class*="container"] {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* --- Site Header: collapse nav on mobile --- */
@media (max-width: 768px) {
    .site-header .dt-container {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    nav {
        display: none;
    }

    .logo {
        font-size: 1.25rem !important;
    }
}

/* --- Hero Section --- */
@media (max-width: 768px) {
    .dt-hero, section.hero, .hero-section {
        padding: 36px 0 20px !important;
        text-align: center;
    }

    .dt-title-xl, .hero-title, h1 {
        font-size: clamp(1.6rem, 6vw, 2.4rem) !important;
        letter-spacing: -0.5px !important;
        line-height: 1.2 !important;
    }

    .dt-subtitle-lg, .hero-subtitle {
        font-size: 0.95rem !important;
        line-height: 1.65 !important;
    }
}

/* --- All 2-col / 3-col / 4-col grids → single column --- */
@media (max-width: 768px) {
    .input-grid,
    .two-col, .two-column,
    .info-grid, .tool-layout,
    .buttons-col,
    .gap-layout,
    .score-card,
    .ctrl-row {
        grid-template-columns: 1fr !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }

    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"] {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.85rem !important;
    }

    .verb-bank,
    .killer-grid,
    .stat-row,
    .score-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.65rem !important;
    }
}

@media (max-width: 480px) {
    .features-grid,
    .features-grid-4,
    .grid-4, .grid-3,
    [class*="grid-col"],
    .verb-bank,
    .killer-grid {
        grid-template-columns: 1fr !important;
    }
}

/* --- Textareas → full width, shorter min-height on mobile --- */
@media (max-width: 768px) {
    .dt-textarea, textarea {
        min-height: 180px !important;
        font-size: 0.92rem !important;
        padding: 1rem !important;
        border-radius: 12px !important;
    }
}

/* --- Action bars / analyze bars --- */
@media (max-width: 768px) {
    .analyze-bar, .action-row, .ctrl-actions,
    .action-bar, .tool-actions, .btn-bar {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.65rem !important;
    }

    .analyze-bar button, .action-row button,
    .action-row .dt-btn-primary, .action-row .dt-btn-ghost,
    .action-row .dt-btn-success {
        width: 100% !important;
        justify-content: center !important;
    }
}

/* --- Format/tab selectors --- */
@media (max-width: 640px) {
    .format-selector, .result-tabs, .tab-group, .mode-tabs {
        flex-wrap: wrap !important;
        gap: 0.4rem !important;
    }

    .r-tab, .tab-btn, .mode-btn {
        font-size: 0.78rem !important;
        padding: 0.55rem 0.75rem !important;
    }
}

/* --- Score card (ATS) --- */
@media (max-width: 768px) {
    .score-card {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 1.25rem !important;
        padding: 1.5rem !important;
    }

    .score-ring-wrap {
        width: 120px !important;
        height: 120px !important;
    }

    .score-ring {
        width: 120px !important;
        height: 120px !important;
    }

    .score-num {
        font-size: 1.6rem !important;
    }

    .score-meta h2 {
        font-size: 1.25rem !important;
    }

    .score-stats {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

/* --- Tables → horizontal scroll --- */
@media (max-width: 768px) {
    .table-wrap, .dt-table-wrap {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    table {
        min-width: 500px;
    }
}

/* --- Cards grid → 2 col then 1 col --- */
@media (max-width: 768px) {
    .file-grid, .card-grid, .item-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
        gap: 0.75rem !important;
    }
}

/* --- Form inputs, selects --- */
@media (max-width: 768px) {
    input[type="text"], input[type="number"],
    input[type="email"], input[type="url"],
    input[type="search"], select {
        font-size: 16px !important; /* prevents iOS zoom */
        padding: 0.7rem 1rem !important;
        border-radius: 10px !important;
    }

    .dt-select, .form-select, .dt-input {
        font-size: 16px !important;
    }
}

/* --- Sliders --- */
@media (max-width: 768px) {
    .dt-slider, input[type="range"] {
        width: 100% !important;
    }
}

/* --- Glass panels --- */
@media (max-width: 768px) {
    .dt-glass-panel, .glass-card, .card-panel {
        padding: 1.5rem !important;
        border-radius: 16px !important;
    }
}

/* --- Tool section padding --- */
@media (max-width: 768px) {
    .tool-section, section.tool-section {
        padding-bottom: 32px !important;
    }

    .features-section {
        padding: 1.5rem 0 1rem !important;
    }
}

/* --- Privacy badge / format badges --- */
@media (max-width: 480px) {
    .privacy-badge {
        font-size: 0.74rem !important;
        padding: 5px 12px !important;
    }

    .format-badges {
        gap: 0.35rem !important;
    }

    .fmt-in, .fmt-out {
        padding: 4px 10px !important;
        font-size: 0.75rem !important;
    }
}

/* --- Keyword tags wrap properly --- */
@media (max-width: 768px) {
    .kw-tags, .verb-suggestions, .format-badges {
        flex-wrap: wrap !important;
    }
}

/* --- Case converter sticky → not sticky on mobile --- */
@media (max-width: 1100px) {
    .input-col {
        position: static !important;
    }
}

/* --- Global control row on image converter --- */
@media (max-width: 768px) {
    .global-controls {
        padding: 1rem !important;
    }

    .format-selector {
        flex-wrap: wrap !important;
    }
}

/* --- Meeting planner / complex tool layouts --- */
@media (max-width: 768px) {
    .planner-layout, .tool-grid, .split-layout, .two-pane {
        flex-direction: column !important;
        gap: 1rem !important;
    }
}

/* --- Drop zone on mobile --- */
@media (max-width: 768px) {
    .drop-zone {
        padding: 36px 20px !important;
    }

    .drop-zone h3 {
        font-size: 1.1rem !important;
    }
}

/* --- Stats strip wraps neatly --- */
@media (max-width: 640px) {
    .stats-strip {
        gap: 0.5rem !important;
        padding: 0.65rem 1rem !important;
        flex-wrap: wrap !important;
    }

    .stat span {
        font-size: 0.95rem !important;
    }

    .copy-row {
        margin-left: 0 !important;
        width: 100% !important;
        justify-content: flex-end !important;
    }
}

/* --- Footer --- */
@media (max-width: 768px) {
    .site-footer {
        padding: 32px 0 !important;
        font-size: 0.82rem !important;
    }
}

/* --- Prevent horizontal overflow --- */
body {
    overflow-x: hidden;
}

@media (max-width: 768px) {
    * {
        max-width: 100%;
    }

    img, canvas, video, iframe {
        max-width: 100% !important;
        height: auto !important;
    }
}
