﻿/* ============================================ */
    /* ACCESSIBLE COLOR SYSTEM - WP COMPATIBLE      */
    /* ============================================ */

    :root {
        --docs-ok-color: #10b981;
        --docs-warn-color: #f59e0b;
        --docs-error-color: #ef4444;
        --docs-info-color: #3b82f6;
        --docs-plasma: #00d9ff;
        --docs-accent: #8b5cf6;
    }

    [data-theme="light"] .docs-content {
        --docs-ok-color: #059669;
        --docs-warn-color: #d97706;
        --docs-error-color: #dc2626;
        --docs-info-color: #2563eb;
        --docs-plasma: #1e40af;
        --docs-accent: #6d28d9;
    }

    /* ============================================ */
    /* NAVIGATION TABS                              */
    /* ============================================ */

    .docs-nav {
        display: flex;
        border-bottom: 2px solid var(--border, rgba(255, 255, 255, 0.1));
        margin-bottom: 0;
        flex-wrap: wrap;
        justify-content: center;
        gap: 5px;
        padding: 10px 0;
    }

    .docs-tab {
        padding: 12px 18px;
        cursor: pointer;
        color: rgba(255, 255, 255, 0.7);
        font-weight: 600;
        font-size: 13px;
        transition: all 0.2s ease;
        border-bottom: 3px solid transparent;
        white-space: nowrap;
        margin-bottom: -2px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        background: transparent;
    }

    .docs-tab:hover {
        color: rgba(255, 255, 255, 0.95);
        background: rgba(255, 255, 255, 0.05);
    }

    .docs-tab.active {
        color: var(--docs-plasma, #00d9ff);
        border-color: var(--docs-plasma, #00d9ff);
        background: rgba(0, 217, 255, 0.1);
    }

    [data-theme="light"] .docs-tab {
        color: rgba(0, 0, 0, 0.7);
    }

    [data-theme="light"] .docs-tab:hover {
        color: rgba(0, 0, 0, 0.95);
        background: rgba(0, 0, 0, 0.05);
    }

    [data-theme="light"] .docs-tab.active {
        color: #1e40af;
        border-color: #1e40af;
        background: rgba(30, 64, 175, 0.08);
    }

    /* ============================================ */
    /* CONTENT SECTIONS                             */
    /* ============================================ */

    .docs-content {
        width: 100%;
    }

    .docs-section {
        display: none;
        animation: fadeIn 0.3s;
        padding-top: 20px;
        width: 100%;
    }

    .docs-section.active {
        display: block;
    }

    @keyframes fadeIn {
        from {
            opacity: 0;
            transform: translateY(5px);
        }

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

    .docs-content h2 {
        font-size: 1.8rem;
        color: var(--docs-plasma, #00d9ff);
        border-left: 5px solid var(--docs-plasma, #00d9ff);
        padding-left: 20px;
        margin-top: 35px;
        margin-bottom: 20px;
        letter-spacing: -0.5px;
        font-weight: 700;
    }

    .docs-content h3 {
        font-size: 1.4rem;
        color: rgba(255, 255, 255, 0.95);
        margin-top: 30px;
        margin-bottom: 15px;
        font-weight: 600;
    }

    .docs-content h4 {
        font-size: 1.1rem;
        color: rgba(255, 255, 255, 0.9);
        margin-top: 20px;
        margin-bottom: 12px;
        font-weight: 600;
    }

    .docs-content p {
        line-height: 1.8;
        color: rgba(255, 255, 255, 0.8);
        margin-bottom: 16px;
        font-size: 1rem;
    }

    .docs-content ul {
        padding-left: 25px;
        margin-bottom: 18px;
    }

    .docs-content li {
        margin-bottom: 10px;
        line-height: 1.8;
        color: rgba(255, 255, 255, 0.8);
    }

    .docs-content strong {
        color: rgba(255, 255, 255, 0.95);
        font-weight: 600;
    }

    .docs-content em {
        color: var(--docs-plasma, #00d9ff);
        font-style: normal;
        font-weight: 500;
    }

    .docs-content code {
        background: rgba(0, 0, 0, 0.4);
        padding: 3px 8px;
        border-radius: 4px;
        font-family: 'Monaco', 'Consolas', 'Courier New', monospace;
        font-size: 0.9em;
        color: #7dd3fc;
        border: 1px solid rgba(0, 217, 255, 0.3);
    }

    .docs-content pre {
        background: rgba(0, 0, 0, 0.35);
        padding: 18px;
        border-radius: 10px;
        overflow-x: auto;
        margin: 20px 0;
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .docs-content ol {
        padding-left: 25px;
        margin-bottom: 18px;
    }

    .docs-content ol li {
        margin-bottom: 10px;
    }

    [data-theme="light"] .docs-content h3 {
        color: rgba(0, 0, 0, 0.9);
    }

    [data-theme="light"] .docs-content h4 {
        color: rgba(0, 0, 0, 0.85);
    }

    [data-theme="light"] .docs-content p,
    [data-theme="light"] .docs-content li {
        color: rgba(0, 0, 0, 0.75);
    }

    [data-theme="light"] .docs-content strong {
        color: rgba(0, 0, 0, 0.9);
    }

    [data-theme="light"] .docs-content code {
        background: rgba(0, 0, 0, 0.06);
        color: #0369a1;
        border-color: rgba(0, 0, 0, 0.1);
    }

    [data-theme="light"] .docs-content pre {
        background: rgba(0, 0, 0, 0.04);
        border-color: rgba(0, 0, 0, 0.08);
    }

    /* ============================================ */
    /* PARAM GRID - INTERACTIVE CARDS               */
    /* ============================================ */

    .param-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 18px;
        margin: 20px 0;
    }

    .param {
        background: rgba(0, 0, 0, 0.3);
        padding: 20px;
        border-radius: 12px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        transition: all 0.2s ease;
    }

    .param:hover {
        border-color: var(--docs-plasma, #00d9ff);
        background: rgba(0, 217, 255, 0.08);
        transform: translateY(-2px);
    }

    .param strong {
        color: var(--docs-plasma, #00d9ff);
        display: block;
        margin-bottom: 12px;
        font-size: 1rem;
        font-weight: 700;
    }

    .param span {
        color: rgba(255, 255, 255, 0.75);
        font-size: 0.9rem;
        line-height: 1.7;
        display: block;
        margin-bottom: 6px;
    }

    [data-theme="light"] .param {
        background: rgba(0, 0, 0, 0.03);
        border-color: rgba(0, 0, 0, 0.1);
    }

    [data-theme="light"] .param:hover {
        background: rgba(30, 64, 175, 0.06);
        border-color: #1e40af;
    }

    [data-theme="light"] .param strong {
        color: #1e40af;
    }

    [data-theme="light"] .param span {
        color: rgba(0, 0, 0, 0.7);
    }

    /* ============================================ */
    /* FEATURE LISTS - ARROW BULLETS                */
    /* ============================================ */

    .feature-list {
        list-style: none;
        padding: 0;
    }

    .feature-list li {
        padding-left: 28px;
        position: relative;
        margin-bottom: 12px;
    }

    .feature-list li::before {
        content: "\25B8";
        position: absolute;
        left: 0;
        color: var(--docs-plasma, #00d9ff);
        font-weight: bold;
        font-size: 1.1rem;
    }

    [data-theme="light"] .feature-list li::before {
        color: #1e40af;
    }

    /* ============================================ */
    /* ALERT BOXES                                  */
    /* ============================================ */

    .warning-box,
    .info-box,
    .new-box,
    .success-box,
    .tip-box {
        background: rgba(0, 0, 0, 0.25);
        padding: 20px;
        margin: 24px 0;
        border-radius: 12px;
        border-left: 5px solid;
        line-height: 1.7;
    }

    .warning-box {
        border-left-color: var(--docs-warn-color, #f59e0b);
        background: rgba(245, 158, 11, 0.1);
    }

    .warning-box strong {
        color: #fbbf24;
        font-weight: 700;
    }

    .info-box {
        border-left-color: var(--docs-info-color, #3b82f6);
        background: rgba(59, 130, 246, 0.1);
    }

    .info-box strong {
        color: #60a5fa;
        font-weight: 700;
    }

    .new-box {
        border-left-color: var(--docs-ok-color, #10b981);
        background: rgba(16, 185, 129, 0.1);
    }

    .new-box strong {
        color: #34d399;
        font-weight: 700;
    }

    .success-box {
        border-left-color: var(--docs-ok-color, #10b981);
        background: rgba(16, 185, 129, 0.1);
    }

    .success-box strong {
        color: #34d399;
        font-weight: 700;
    }

    .tip-box {
        border-left-color: var(--docs-plasma, #00d9ff);
        background: rgba(0, 217, 255, 0.1);
    }

    .tip-box strong {
        color: #22d3ee;
        font-weight: 700;
    }

    [data-theme="light"] .warning-box,
    [data-theme="light"] .info-box,
    [data-theme="light"] .new-box,
    [data-theme="light"] .success-box,
    [data-theme="light"] .tip-box {
        background: rgba(255, 255, 255, 0.8);
    }

    [data-theme="light"] .warning-box strong {
        color: #d97706;
    }

    [data-theme="light"] .info-box strong {
        color: #2563eb;
    }

    [data-theme="light"] .new-box strong {
        color: #059669;
    }

    [data-theme="light"] .success-box strong {
        color: #059669;
    }

    [data-theme="light"] .tip-box strong {
        color: #1e40af;
    }

    /* ============================================ */
    /* VERSION BADGE                                */
    /* ============================================ */

    .v-badge {
        display: inline-block;
        background: rgba(57, 255, 20, 0.15);
        color: #39ff14;
        font-size: 0.7rem;
        font-weight: 700;
        padding: 2px 7px;
        border-radius: 4px;
        margin-left: 8px;
        vertical-align: middle;
        letter-spacing: 0.5px;
    }

    [data-theme="light"] .v-badge {
        background: rgba(0, 128, 0, 0.12);
        color: #008000;
    }

    /* ============================================ */
    /* COLOR SWATCHES                               */
    /* ============================================ */

    .color-swatch {
        display: inline-block;
        width: 14px;
        height: 14px;
        border-radius: 50%;
        margin-right: 8px;
        vertical-align: middle;
        border: 1px solid rgba(255, 255, 255, 0.2);
    }

    /* Element Swatches */
    .swatch-carbon {
        background: hsla(190, 100%, 50%, 1) !important;
    }

    .swatch-oxygen {
        background: hsla(280, 100%, 60%, 1) !important;
    }

    .swatch-hydrogen {
        background: hsla(200, 10%, 80%, 1) !important;
    }

    .swatch-nitrogen {
        background: hsla(140, 100%, 30%, 1) !important;
    }

    .swatch-sulfur {
        background: hsla(55, 100%, 50%, 1) !important;
    }

    .swatch-phosphorus {
        background: hsla(10, 100%, 60%, 1) !important;
    }

    .swatch-chlorine {
        background: hsla(120, 100%, 70%, 1) !important;
    }

    .swatch-bromine {
        background: hsla(25, 60%, 30%, 1) !important;
    }

    .swatch-probe {
        background: hsla(220, 100%, 50%, 1) !important;
    }

    /* Darker Swatches */
    .swatch-carbon-dark {
        background: hsla(190, 100%, 30%, 1) !important;
    }

    .swatch-oxygen-dark {
        background: hsla(280, 100%, 40%, 1) !important;
    }

    .swatch-hydrogen-dark {
        background: hsla(200, 10%, 30%, 1) !important;
    }

    .swatch-nitrogen-dark {
        background: hsla(140, 100%, 25%, 1) !important;
    }

    .swatch-sulfur-dark {
        background: hsla(55, 100%, 40%, 1) !important;
    }

    .swatch-phosphorus-dark {
        background: hsla(10, 100%, 45%, 1) !important;
    }

    .swatch-chlorine-dark {
        background: hsla(120, 100%, 30%, 1) !important;
    }

    .swatch-bromine-dark {
        background: hsla(25, 50%, 22%, 1) !important;
    }

    .swatch-probe-dark {
        background: hsla(220, 100%, 40%, 1) !important;
    }

    /* Reaction Swatches */
    .swatch-peroxide {
        background: hsla(0, 100%, 60%, 1) !important;
    }

    .swatch-nucleophilic {
        background: hsla(180, 100%, 70%, 1) !important;
    }

    .swatch-thermal {
        background: hsla(40, 100%, 60%, 1) !important;
    }

    .swatch-charge {
        background: hsla(120, 100%, 60%, 1) !important;
    }

    .swatch-acidbase {
        background: hsla(40, 100%, 65%, 1) !important;
    }

    .swatch-water {
        background: hsla(300, 100%, 65%, 1) !important;
    }

    .swatch-hydronium {
        background: hsla(200, 100%, 70%, 1) !important;
    }

    /* ============================================ */
    /* REACTION EQUATION STYLING                    */
    /* ============================================ */

    .reaction {
        text-align: center;
        font-family: 'Monaco', 'Consolas', monospace;
        font-size: 1rem;
        color: rgba(255, 255, 255, 0.95);
        padding: 14px 0 8px;
        letter-spacing: 1px;
    }

    .reaction .arrow {
        color: var(--docs-plasma, #00d9ff);
        margin: 0 10px;
    }

    .reaction .label {
        display: block;
        font-family: sans-serif;
        font-size: 0.75rem;
        color: rgba(255, 255, 255, 0.6);
        margin-top: 4px;
        letter-spacing: 0;
    }

    [data-theme="light"] .reaction {
        color: rgba(0, 0, 0, 0.85);
    }

    [data-theme="light"] .reaction .label {
        color: rgba(0, 0, 0, 0.55);
    }

    /* ============================================ */
    /* COMPARISON TABLE                             */
    /* ============================================ */

    .comparison-table {
        width: 100%;
        border-collapse: collapse;
        margin: 24px 0;
        background: rgba(0, 0, 0, 0.25);
        border-radius: 12px;
        overflow: hidden;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .comparison-table th {
        background: rgba(0, 217, 255, 0.15);
        padding: 14px;
        text-align: left;
        color: rgba(255, 255, 255, 0.95);
        font-weight: 700;
        border-bottom: 2px solid rgba(0, 217, 255, 0.3);
        font-size: 0.95rem;
    }

    .comparison-table td {
        padding: 14px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        color: rgba(255, 255, 255, 0.8);
        font-size: 0.9rem;
    }

    .comparison-table tr:last-child td {
        border-bottom: none;
    }

    .comparison-table tr:hover {
        background: rgba(255, 255, 255, 0.03);
    }

    [data-theme="light"] .comparison-table {
        background: rgba(0, 0, 0, 0.02);
        border-color: rgba(0, 0, 0, 0.1);
    }

    [data-theme="light"] .comparison-table th {
        background: rgba(0, 217, 255, 0.12);
        color: rgba(0, 0, 0, 0.9);
        border-bottom-color: rgba(0, 0, 0, 0.1);
    }

    [data-theme="light"] .comparison-table td {
        color: rgba(0, 0, 0, 0.75);
        border-bottom-color: rgba(0, 0, 0, 0.06);
    }

    [data-theme="light"] .comparison-table tr:hover {
        background: rgba(0, 0, 0, 0.03);
    }

    /* ============================================ */
    /* METRICS GRID                                 */
    /* ============================================ */

    .metrics-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 16px;
        margin: 24px 0;
    }

    .metric-card {
        background: rgba(0, 0, 0, 0.3);
        padding: 20px;
        border-radius: 12px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        text-align: center;
        transition: all 0.2s ease;
    }

    .metric-card:hover {
        border-color: var(--docs-plasma, #00d9ff);
        transform: translateY(-2px);
    }

    .metric-value {
        font-size: 2.2rem;
        font-weight: 800;
        color: var(--docs-plasma, #00d9ff);
        display: block;
        margin-bottom: 8px;
        line-height: 1;
    }

    .metric-label {
        font-size: 0.85rem;
        color: rgba(255, 255, 255, 0.7);
        text-transform: uppercase;
        letter-spacing: 1px;
        font-weight: 600;
    }

    [data-theme="light"] .metric-card {
        background: rgba(0, 0, 0, 0.03);
        border-color: rgba(0, 0, 0, 0.1);
    }

    [data-theme="light"] .metric-value {
        color: #1e40af;
    }

    [data-theme="light"] .metric-card:hover {
        border-color: #1e40af;
    }

    [data-theme="light"] .metric-label {
        color: rgba(0, 0, 0, 0.6);
    }

    /* ============================================ */
    /* EXAMPLE BOXES                                */
    /* ============================================ */

    .example-box {
        background: rgba(0, 0, 0, 0.35);
        padding: 18px;
        border-radius: 12px;
        margin: 20px 0;
        border-left: 4px solid var(--docs-plasma, #00d9ff);
    }

    .example-box .label {
        color: var(--docs-plasma, #00d9ff);
        font-weight: 700;
        font-size: 0.85rem;
        text-transform: uppercase;
        margin-bottom: 10px;
        display: block;
        letter-spacing: 0.5px;
    }

    .example-box .content {
        color: rgba(255, 255, 255, 0.85);
        line-height: 1.8;
        font-size: 0.95rem;
    }

    [data-theme="light"] .example-box {
        background: rgba(0, 0, 0, 0.04);
    }

    [data-theme="light"] .example-box .content {
        color: rgba(0, 0, 0, 0.8);
    }

    /* ============================================ */
    /* ARCHITECTURE BADGES                          */
    /* ============================================ */

    .arch-badge {
        display: inline-block;
        padding: 6px 14px;
        border-radius: 20px;
        font-weight: 700;
        font-size: 0.85rem;
        margin: 0 5px;
        border: 2px solid;
    }

    .arch-core {
        background: rgba(0, 217, 255, 0.2);
        color: var(--docs-plasma);
        border-color: var(--docs-plasma);
    }

    .arch-api {
        background: rgba(139, 92, 246, 0.2);
        color: #a78bfa;
        border-color: #8b5cf6;
    }

    .arch-sec {
        background: rgba(16, 185, 129, 0.2);
        color: #34d399;
        border-color: #10b981;
    }

    .arch-storage {
        background: rgba(249, 115, 22, 0.2);
        color: #fb923c;
        border-color: #f97316;
    }

    .arch-bridge {
        background: rgba(251, 191, 36, 0.2);
        color: #fbbf24;
        border-color: #eab308;
    }

    /* ============================================ */
    /* GLOBAL OVERFLOW PROTECTION                   */
    /* ============================================ */

    .docs-content {
        width: 100%;
        min-width: 0;
        overflow-x: hidden;
        overflow-wrap: anywhere;
        box-sizing: border-box;
    }

    .docs-content *,
    .docs-content *::before,
    .docs-content *::after {
        box-sizing: border-box;
        min-width: 0;
    }

    .docs-section {
        width: 100%;
        min-width: 0;
    }

    .comparison-table {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* ============================================ */
    /* RESPONSIVE: 768px                            */
    /* ============================================ */

    @media (max-width: 768px) {
        .docs-tab {
            font-size: 11px;
            padding: 10px 12px;
        }

        .docs-content h2 {
            font-size: 1.5rem;
            padding-left: 14px;
        }

        .docs-content h3 {
            font-size: 1.2rem;
        }

        /* Force all grids to single column */
        .param-grid {
            grid-template-columns: 1fr !important;
            width: 100%;
        }

        .metrics-grid {
            grid-template-columns: repeat(2, 1fr) !important;
            width: 100%;
        }

        .param,
        .metric-card {
            width: 100%;
            min-width: 0;
        }

        /* Alert boxes */
        .warning-box,
        .info-box,
        .new-box,
        .success-box,
        .tip-box {
            padding: 14px;
            margin-left: 0;
            margin-right: 0;
            word-break: break-word;
            overflow-wrap: anywhere;
        }

        .example-box {
            padding: 14px;
            overflow-wrap: anywhere;
        }

        .example-box .content {
            overflow-x: auto;
            -webkit-overflow-scrolling: touch;
        }

        .arch-badge {
            padding: 4px 8px;
            font-size: 0.7rem;
            margin: 2px 3px;
        }

        .param strong {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            gap: 6px;
        }

        .metric-value {
            font-size: 1.6rem;
        }

        .metric-label {
            font-size: 0.75rem;
            letter-spacing: 0.5px;
        }

        .comparison-table th,
        .comparison-table td {
            padding: 10px;
            font-size: 0.8rem;
        }

        .reaction {
            font-size: 0.82rem;
            letter-spacing: 0;
        }

        .v-badge {
            font-size: 0.6rem;
            padding: 1px 5px;
        }

        .docs-content pre {
            font-size: 0.78rem;
            padding: 12px;
            word-break: break-all;
            white-space: pre-wrap;
        }

        .docs-content code {
            font-size: 0.8em;
            word-break: break-all;
        }

        .comparison-table {
            display: block;
            overflow-x: auto;
            -webkit-overflow-scrolling: touch;
        }
    }

    /* ============================================ */
    /* RESPONSIVE: 400px                            */
    /* ============================================ */

    @media (max-width: 400px) {
        .docs-tab {
            font-size: 10px;
            padding: 8px 8px;
            letter-spacing: 0;
        }

        .docs-nav {
            gap: 2px;
            padding: 6px 0;
        }

        .docs-content h2 {
            font-size: 1.3rem;
            padding-left: 10px;
        }

        .docs-content h3 {
            font-size: 1rem;
        }

        .metrics-grid {
            grid-template-columns: 1fr 1fr !important;
            gap: 10px;
        }

        .metric-value {
            font-size: 1.4rem;
        }

        .metric-card {
            padding: 12px;
        }

        .param {
            padding: 14px;
        }

        .param strong {
            font-size: 0.88rem;
        }

        .param span {
            font-size: 0.82rem;
        }

        .reaction {
            font-size: 0.72rem;
        }
    }

