        :root {
            --bg: #0b0f17;
            --bg-surface: #131a28;
            --bg-card: #182032;
            --bg-input: #0f1623;
            --border: #1e2a40;
            --border-accent: #2a3a55;
            --text-primary: #e8ecf2;
            --text-secondary: #a0b0c8;
            --text-muted: #6b7d95;
            --accent: #5b9cf5;
            --accent-glow: rgba(91, 156, 245, 0.25);
            --accent-soft: rgba(91, 156, 245, 0.1);
            --success: #34d399;
            --success-soft: rgba(52, 211, 153, 0.12);
            --warning: #f59e0b;
            --warning-soft: rgba(245, 158, 11, 0.12);
            --danger: #ef4444;
            --danger-soft: rgba(239, 68, 68, 0.12);
            --info: #a78bfa;
            --info-soft: rgba(167, 139, 250, 0.1);
            --radius-sm: 8px;
            --radius-md: 12px;
            --radius-lg: 16px;
            --radius-xl: 20px;
            --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
            --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
            --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
            --shadow-glow: 0 0 40px var(--accent-glow);
            --font-sans: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
            --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', 'SF Mono', monospace;
            --transition-fast: 120ms ease-out;
            --transition-smooth: 250ms cubic-bezier(0.4, 0, 0.2, 1);
            --transition-spring: 350ms cubic-bezier(0.34, 1.56, 0.64, 1);
        }

        .ccp-tool {
            all: initial;
        }

        *,
        *::before,
        *::after {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
        }

        html {
            scroll-behavior: smooth;
            -webkit-text-size-adjust: 100%;
            scrollbar-width: thin;
            scrollbar-color: var(--border) transparent;
        }

        ::-webkit-scrollbar {
            width: 6px;
            height: 6px;
        }
        ::-webkit-scrollbar-track {
            background: transparent;
        }
        ::-webkit-scrollbar-thumb {
            background: var(--border);
            border-radius: 20px;
        }
        ::-webkit-scrollbar-thumb:hover {
            background: var(--border-accent);
        }

        body.single-tool {
            font-family: var(--font-sans) !important;
            background: var(--bg) !important;
            color: var(--text-primary) !important;
            line-height: 1.6 !important;
            min-height: 100vh;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
        }

        /* ─── LAYOUT ─────────────────────────── */
        .page-wrap {
            max-width: 1240px;
            margin: 0 auto;
            padding: 20px 24px 60px;
        }

        /* ─── BREADCRUMB ────────────────────── */
        .breadcrumb {
            display: flex;
            flex-wrap: wrap;
            gap: 6px;
            align-items: center;
            font-size: 0.85rem;
            color: var(--text-muted);
            margin-bottom: 18px;
            padding: 0;
            list-style: none;
        }
        .breadcrumb li {
            display: inline-flex;
            align-items: center;
            gap: 6px;
        }
        .breadcrumb a {
            color: var(--text-secondary);
            text-decoration: none;
            transition: color var(--transition-fast);
        }
        .breadcrumb a:hover {
            color: var(--accent);
        }
        .breadcrumb .sep {
            color: var(--text-muted);
            user-select: none;
        }
        .breadcrumb .current {
            color: var(--text-primary);
            font-weight: 500;
        }

        /* ─── HERO ──────────────────────────── */
        .hero {
            text-align: center;
            margin-bottom: 32px;
        }
        .hero-badge {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            background: var(--accent-soft);
            border: 1px solid rgba(91, 156, 245, 0.2);
            color: var(--accent);
            font-size: 0.8rem;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.06em;
            padding: 6px 14px;
            border-radius: 50px;
            margin-bottom: 14px;
        }
        .hero-badge .dot {
            width: 7px;
            height: 7px;
            border-radius: 50%;
            background: var(--accent);
            animation: pulse-dot 1.8s infinite;
        }
        @keyframes pulse-dot {
            0%,
            100% {
                box-shadow: 0 0 0 0 var(--accent-glow);
            }
            50% {
                box-shadow: 0 0 0 10px transparent;
            }
        }
        .hero h1 {
            font-size: clamp(1.8rem, 3.5vw, 2.6rem);
            font-weight: 800;
            letter-spacing: -0.02em;
            margin-bottom: 8px;
            line-height: 1.2;
            background: linear-gradient(135deg, #e8ecf2 0%, #a0bcf5 50%, #c4b5fd 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }
        .hero p {
            color: var(--text-secondary);
            font-size: 1.05rem;
            max-width: 600px;
            margin: 0 auto;
            text-wrap: balance;
        }

        /* ─── TOOLBAR ───────────────────────── */
        .toolbar {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-bottom: 14px;
            justify-content: flex-end;
        }
        .btn {
            display: inline-flex;
            align-items: center;
            gap: 7px;
            font-family: var(--font-sans);
            font-size: 0.875rem;
            font-weight: 500;
            padding: 9px 16px;
            border-radius: var(--radius-sm);
            cursor: pointer;
            border: 1px solid var(--border);
            background: var(--bg-surface);
            color: var(--text-secondary);
            transition: all var(--transition-fast);
            white-space: nowrap;
            user-select: none;
            -webkit-tap-highlight-color: transparent;
        }
        .btn:hover {
            border-color: var(--border-accent);
            background: var(--bg-card);
            color: var(--text-primary);
        }
        .btn:focus-visible {
            outline: 2px solid var(--accent);
            outline-offset: 2px;
            border-color: var(--accent);
        }
        .btn:active {
            transform: scale(0.97);
        }
        .btn--primary {
            background: var(--accent);
            border-color: var(--accent);
            color: #fff;
            font-weight: 600;
        }
        .btn--primary:hover {
            background: #4a8de8;
            border-color: #4a8de8;
            box-shadow: var(--shadow-glow);
        }
        .btn--ghost {
            background: transparent;
            border-color: transparent;
        }
        .btn--ghost:hover {
            background: var(--bg-card);
            border-color: var(--border);
        }
        .btn svg {
            width: 15px;
            height: 15px;
            flex-shrink: 0;
        }

        /* ─── EDITOR AREA ──────────────────── */
        .editor-container {
            position: relative;
            background: var(--bg-input);
            border: 2px solid var(--border);
            border-radius: var(--radius-lg);
            transition: border-color var(--transition-smooth), box-shadow var(--transition-smooth);
            margin-bottom: 24px;
            overflow: hidden;
        }
        .editor-container:focus-within {
            border-color: var(--accent);
            box-shadow: 0 0 0 6px var(--accent-soft), var(--shadow-lg);
        }
        .editor-container.warning-state {
            border-color: var(--warning);
            box-shadow: 0 0 0 6px var(--warning-soft);
        }
        .editor-container.danger-state {
            border-color: var(--danger);
            box-shadow: 0 0 0 6px var(--danger-soft);
        }
        textarea {
            display: block;
            width: 100%;
            min-height: 260px;
            max-height: 70vh;
            background: transparent;
            border: none;
            outline: none;
            resize: vertical;
            padding: 20px 22px;
            font-family: var(--font-mono);
            font-size: 0.95rem;
            line-height: 1.7;
            color: var(--text-primary);
            caret-color: var(--accent);
        }
        textarea::placeholder {
            color: var(--text-muted);
            font-family: var(--font-sans);
            font-size: 0.9rem;
            opacity: 0.7;
        }
        .editor-footer {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            justify-content: space-between;
            padding: 10px 18px;
            border-top: 1px solid var(--border);
            background: var(--bg-surface);
            gap: 10px;
        }
        .char-count-inline {
            font-size: 0.8rem;
            color: var(--text-muted);
            font-family: var(--font-mono);
            display: flex;
            gap: 16px;
            flex-wrap: wrap;
        }
        .char-count-inline span {
            display: inline-flex;
            align-items: center;
            gap: 4px;
        }
        .char-count-inline strong {
            color: var(--text-primary);
            font-weight: 600;
        }

        /* ─── STATS GRID ───────────────────── */
        .stats-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
            gap: 14px;
            margin-bottom: 28px;
        }
        .stat-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: var(--radius-md);
            padding: 16px 18px;
            transition: all var(--transition-smooth);
            position: relative;
            overflow: hidden;
        }
        .stat-card:hover {
            border-color: var(--border-accent);
            transform: translateY(-2px);
            box-shadow: var(--shadow-md);
        }
        .stat-card__icon {
            font-size: 1.3rem;
            margin-bottom: 6px;
            display: block;
        }
        .stat-card__value {
            font-size: 1.7rem;
            font-weight: 700;
            letter-spacing: -0.01em;
            line-height: 1;
            margin-bottom: 3px;
            font-family: var(--font-mono);
        }
        .stat-card__label {
            font-size: 0.78rem;
            color: var(--text-muted);
            font-weight: 500;
            text-transform: uppercase;
            letter-spacing: 0.04em;
        }
        .stat-card--highlight {
            border-left: 3px solid var(--accent);
        }
        .stat-card--success {
            border-left: 3px solid var(--success);
        }
        .stat-card--warning {
            border-left: 3px solid var(--warning);
        }
        .stat-card--info {
            border-left: 3px solid var(--info);
        }

        /* ─── SECTION HEADERS ──────────────── */
        .section-title {
            font-size: 1.15rem;
            font-weight: 700;
            letter-spacing: -0.01em;
            margin-bottom: 14px;
            display: flex;
            align-items: center;
            gap: 10px;
            color: var(--text-primary);
        }
        .section-title .icon-circle {
            width: 34px;
            height: 34px;
            border-radius: 50%;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            background: var(--accent-soft);
            color: var(--accent);
            font-size: 1rem;
            flex-shrink: 0;
        }

        /* ─── SOCIAL MEDIA CARDS ──────────── */
        .social-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
            gap: 14px;
            margin-bottom: 28px;
        }
        .social-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: var(--radius-md);
            padding: 16px 18px;
            transition: all var(--transition-smooth);
            display: flex;
            flex-direction: column;
            gap: 10px;
        }
        .social-card:hover {
            border-color: var(--border-accent);
            box-shadow: var(--shadow-md);
        }
        .social-card__header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 8px;
        }
        .social-card__platform {
            font-weight: 700;
            font-size: 0.9rem;
            display: flex;
            align-items: center;
            gap: 7px;
        }
        .social-card__platform .plat-icon {
            width: 28px;
            height: 28px;
            border-radius: 50%;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            font-size: 0.85rem;
            flex-shrink: 0;
        }
        .plat-icon--twitter {
            background: #1da1f220;
            color: #1da1f2;
        }
        .plat-icon--meta {
            background: #4285f420;
            color: #4285f4;
        }
        .plat-icon--instagram {
            background: #e4405f20;
            color: #e4405f;
        }
        .plat-icon--facebook {
            background: #1877f220;
            color: #1877f2;
        }
        .plat-icon--linkedin {
            background: #0a66c220;
            color: #0a66c2;
        }
        .plat-icon--sms {
            background: #34d39920;
            color: #34d399;
        }
        .plat-icon--title {
            background: #a78bfa20;
            color: #a78bfa;
        }
        .social-card__limit {
            font-size: 0.75rem;
            color: var(--text-muted);
            font-family: var(--font-mono);
        }
        .progress-bar-wrap {
            width: 100%;
            height: 6px;
            background: var(--bg-input);
            border-radius: 10px;
            overflow: hidden;
        }
        .progress-bar-fill {
            height: 100%;
            border-radius: 10px;
            transition: width var(--transition-smooth), background var(--transition-smooth);
            background: var(--accent);
        }
        .progress-bar-fill.warning {
            background: var(--warning);
        }
        .progress-bar-fill.danger {
            background: var(--danger);
        }
        .progress-bar-fill.success {
            background: var(--success);
        }
        .social-card__remaining {
            font-size: 0.78rem;
            color: var(--text-secondary);
            font-weight: 500;
        }
        .social-card__remaining.over {
            color: var(--danger);
            font-weight: 600;
        }

        /* ─── INSIGHTS GRID ───────────────── */
        .insights-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
            gap: 10px;
            margin-bottom: 28px;
        }
        .insight-chip {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: var(--radius-sm);
            padding: 12px 14px;
            text-align: center;
            transition: all var(--transition-fast);
        }
        .insight-chip:hover {
            border-color: var(--border-accent);
        }
        .insight-chip__value {
            font-size: 1.4rem;
            font-weight: 700;
            font-family: var(--font-mono);
            line-height: 1;
        }
        .insight-chip__label {
            font-size: 0.7rem;
            color: var(--text-muted);
            text-transform: uppercase;
            letter-spacing: 0.04em;
            margin-top: 4px;
        }

        /* ─── QUALITY INDICATORS ──────────── */
        .quality-list {
            list-style: none;
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            margin-bottom: 28px;
        }
        .quality-tag {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            font-size: 0.78rem;
            font-weight: 500;
            padding: 6px 12px;
            border-radius: 50px;
            background: var(--bg-card);
            border: 1px solid var(--border);
            color: var(--text-secondary);
            transition: all var(--transition-fast);
        }
        .quality-tag.warn {
            background: var(--warning-soft);
            border-color: rgba(245, 158, 11, 0.3);
            color: var(--warning);
        }
        .quality-tag.danger {
            background: var(--danger-soft);
            border-color: rgba(239, 68, 68, 0.3);
            color: var(--danger);
        }
        .quality-tag.ok {
            background: var(--success-soft);
            border-color: rgba(52, 211, 153, 0.3);
            color: var(--success);
        }
        .quality-tag.info {
            background: var(--info-soft);
            border-color: rgba(167, 139, 250, 0.3);
            color: var(--info);
        }

        /* ─── REPEATED WORDS/CHARS ────────── */
        .repeated-section {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
            gap: 14px;
            margin-bottom: 28px;
        }
        .repeated-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: var(--radius-md);
            padding: 14px 16px;
        }
        .repeated-card h4 {
            font-size: 0.85rem;
            font-weight: 600;
            margin-bottom: 8px;
            color: var(--text-secondary);
            text-transform: uppercase;
            letter-spacing: 0.04em;
        }
        .repeated-list {
            list-style: none;
            display: flex;
            flex-wrap: wrap;
            gap: 6px;
        }
        .repeated-list li {
            font-size: 0.78rem;
            background: var(--bg-input);
            padding: 4px 10px;
            border-radius: 20px;
            font-family: var(--font-mono);
            color: var(--text-primary);
            border: 1px solid var(--border);
        }
        .repeated-list .count {
            color: var(--accent);
            font-weight: 600;
        }
        .empty-note {
            color: var(--text-muted);
            font-size: 0.78rem;
            font-style: italic;
        }

        /* ─── FAQ SECTION ──────────────────── */
        .faq-section {
            margin-top: 40px;
            padding-top: 30px;
            border-top: 1px solid var(--border);
        }
        .faq-section h2 {
            font-size: 1.4rem;
            font-weight: 700;
            margin-bottom: 20px;
            letter-spacing: -0.01em;
        }
        .faq-item {
            margin-bottom: 16px;
            border: 1px solid var(--border);
            border-radius: var(--radius-md);
            overflow: hidden;
            background: var(--bg-card);
            transition: border-color var(--transition-fast);
        }
        .faq-item:hover {
            border-color: var(--border-accent);
        }
        .faq-question {
            width: 100%;
            text-align: left;
            background: none;
            border: none;
            color: var(--text-primary);
            font-family: var(--font-sans);
            font-size: 0.95rem;
            font-weight: 600;
            padding: 16px 18px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            -webkit-tap-highlight-color: transparent;
            transition: background var(--transition-fast);
        }
        .faq-question:hover {
            background: var(--bg-surface);
        }
        .faq-question:focus-visible {
            outline: 2px solid var(--accent);
            outline-offset: -2px;
        }
        .faq-icon {
            flex-shrink: 0;
            transition: transform var(--transition-spring);
            font-size: 1.2rem;
            color: var(--text-muted);
        }
        .faq-item.open .faq-icon {
            transform: rotate(45deg);
            color: var(--accent);
        }
        .faq-answer {
            max-height: 0;
            overflow: hidden;
            transition: max-height var(--transition-smooth), padding var(--transition-smooth);
            padding: 0 18px;
            color: var(--text-secondary);
            font-size: 0.9rem;
            line-height: 1.7;
        }
        .faq-item.open .faq-answer {
            max-height: 300px;
            padding: 0 18px 16px;
        }

        /* ─── RESPONSIVE ──────────────────── */
        @media (max-width: 768px) {
            .page-wrap {
                padding: 12px 14px 40px;
            }
            textarea {
                min-height: 200px;
                font-size: 0.85rem;
                padding: 14px;
            }
            .stats-grid {
                grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
                gap: 8px;
            }
            .stat-card {
                padding: 12px 14px;
            }
            .stat-card__value {
                font-size: 1.35rem;
            }
            .social-grid {
                grid-template-columns: 1fr;
                gap: 10px;
            }
            .insights-grid {
                grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
                gap: 6px;
            }
            .toolbar {
                justify-content: stretch;
            }
            .toolbar .btn {
                flex: 1;
                justify-content: center;
                font-size: 0.8rem;
                padding: 8px 12px;
            }
            .editor-footer {
                flex-direction: column;
                align-items: flex-start;
            }
        }
        @media (max-width: 400px) {
            .stats-grid {
                grid-template-columns: 1fr 1fr;
            }
            .insights-grid {
                grid-template-columns: 1fr 1fr;
            }
            .hero h1 {
                font-size: 1.5rem;
            }
        }

        /* ─── FOCUS VISIBLE ──────────────── */
        :focus-visible {
            outline: 2px solid var(--accent);
            outline-offset: 2px;
        }
        textarea:focus-visible {
            outline: none;
        }

        /* ─── REDUCED MOTION ─────────────── */
        @media (prefers-reduced-motion: reduce) {
            *,
            *::before,
            *::after {
                animation-duration: 0.01ms !important;
                animation-iteration-count: 1 !important;
                transition-duration: 0.01ms !important;
            }
        }