
    * { box-sizing: border-box; }
    body {
        margin: 0;
        padding: 0;
        background: #f0f2f5;
        font-family: 'Inter', 'Roboto', sans-serif;
        min-height: 100vh;
    }

    .header-bar {
        background: #ffffff;
        border-bottom: 1px solid #e0e4e8;
        box-shadow: 0 1px 8px rgba(0,0,0,0.06);
        position: sticky;
        top: 0;
        z-index: 100;
    }
    .header-inner {
        display: flex !important;
        align-items: center;
        padding: 0 24px;
        height: 64px;
        max-width: 100%;
        justify-content: flex-start;
        gap: 16px;
    }
    .header-logo-area {
        display: flex;
        align-items: center;
        margin-right: auto;
        flex-shrink: 0;
    }
    .header-logo-link {
        display: flex;
        align-items: center;
    }
    .header-logo {
        height: 44px;
        transition: opacity 0.2s;
    }
    .header-logo:hover {
        opacity: 0.85;
    }

    .header-nav {
        display: flex;
        align-items: center;
        gap: 8px;
        margin-left: auto;
    }
    .header-nav-btn {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 7px 14px;
        font-size: 13px;
        font-weight: 500;
        color: #4a5568;
        background: #f7f8fa;
        border: 1px solid #e2e6ea;
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.15s ease;
        font-family: 'Inter', sans-serif;
        white-space: nowrap;
    }
    .header-nav-btn:hover {
        background: #edf0f4;
        color: #1a202c;
        border-color: #cbd2da;
    }
    .header-nav-btn.active {
        background: #3b82f6;
        color: #fff;
        border-color: #3b82f6;
    }
    .header-nav-btn i {
        font-size: 14px;
    }
    .header-sound-btn.sound-on {
        background: #ecfdf5;
        border-color: #6ee7b7;
        color: #059669;
    }
    .header-sound-btn.sound-on:hover {
        background: #d1fae5;
    }

    .text-size-control {
        cursor: default;
    }
    .text-size-slider {
        -webkit-appearance: none;
        appearance: none;
        width: 80px;
        height: 4px;
        background: #cbd5e1;
        border-radius: 4px;
        outline: none;
        cursor: pointer;
    }
    .text-size-slider::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        width: 14px;
        height: 14px;
        border-radius: 50%;
        background: #3b82f6;
        cursor: pointer;
        border: 2px solid #fff;
        box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    }
    .text-size-slider::-moz-range-thumb {
        width: 14px;
        height: 14px;
        border-radius: 50%;
        background: #3b82f6;
        cursor: pointer;
        border: 2px solid #fff;
        box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    }

    body.dark-mode {
        background: #1a1a2e;
    }
    body.dark-mode .header-bar {
        background: #16213e;
        border-bottom-color: #2a2a4a;
    }
    body.dark-mode .header-nav-btn {
        background: #1a1a2e;
        color: #cbd5e1;
        border-color: #2a2a4a;
    }
    body.dark-mode .header-nav-btn:hover {
        background: #2a2a4a;
        color: #e2e8f0;
        border-color: #3a3a5a;
    }
    body.dark-mode .header-sep {
        background: #2a2a4a;
    }
    body.dark-mode .header-timer-text {
        color: #e2e8f0;
    }
    body.dark-mode .header-timer-text #timer {
        color: #f8fafc;
    }
    body.dark-mode .header-user {
        background: #ffffff;
        border-color: #3b82f6;
        color: #cbd5e1;
    }
    body.dark-mode .typing-card {
        background: #16213e;
        border-color: #2a2a4a;
        box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    }
    body.dark-mode .typing-card-header {
        background: #3b82f6;
        border-bottom-color: #2a2a4a;
    }
    body.dark-mode .typing-card-title {
        color: #e2e8f0;
    }
    body.dark-mode .passage-text,
    body.dark-mode #textParagraph,
    body.dark-mode #RRBPassage {
        background: #0f0f23;
        color: #e2e8f0;
        border-color: #2a2a4a;
    }
    body.dark-mode #typingArea,
    body.dark-mode #userInput {
        background: #0f0f23;
        color: #e2e8f0;
        border-color: #2a2a4a;
    }
    body.dark-mode #typingArea:focus,
    body.dark-mode #userInput:focus {
        border-color: #6366f1;
        box-shadow: 0 0 0 3px rgba(99,102,241,0.15);
    }
    body.dark-mode .form-control {
        background: #0f0f23;
        color: #e2e8f0;
        border-color: #2a2a4a;
    }
    body.dark-mode .text-size-slider {
        background: #4a5568;
    }
    body.dark-mode #darkModeToggle {
        background: #2d3748;
        color: #fbbf24;
        border-color: #4a5568;
    }

    .header-sep {
        width: 1px;
        height: 28px;
        background: #e2e6ea;
        margin: 0 12px;
    }

    .header-timer {
        display: flex;
        align-items: center;
        padding: 8px 18px;
        border-radius: 10px;
    }
    .header-timer-text {
        font-size: 20px;
        font-weight: 700;
        color: #1e293b;
        font-family: 'Inter', sans-serif;
        white-space: nowrap;
    }
    .header-timer-text #timer {
        font-size: 24px;
        font-weight: 800;
        font-family: 'Roboto', monospace;
        letter-spacing: 1px;
    }
    .header-timer.timer-danger {
        background: linear-gradient(135deg, #fee2e2, #fca5a5);
        border-color: #ef4444;
    }
    .header-timer.timer-danger .header-timer-text {
        color: #991b1b;
    }
    .header-timer.timer-danger #timer {
        color: #dc2626;
    }
    body.dark-mode .header-timer.timer-danger {
        background: linear-gradient(135deg, #7f1d1d, #991b1b);
        border-color: #dc2626;
    }
    body.dark-mode .header-timer.timer-danger .header-timer-text {
        color: #fecaca;
    }
    body.dark-mode .header-timer.timer-danger #timer {
        color: #fef2f2;
    }

    .header-user {
        display: flex;
        align-items: center;
        gap: 10px;
        margin-left: auto;
        padding: 4px 12px 4px 4px;
        border-radius: 40px;
        background: #f7f8fa;
        border: 1px solid #e2e6ea;
        cursor: default;
    }
    .header-user-avatar {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        border: 2px solid #e2e6ea;
        object-fit: cover;
    }
    .header-user-name {
        font-size: 13px;
        font-weight: 600;
        color: #1a202c;
    }
    .header-fs-icon {
        color: #64748b;
        font-size: 16px;
        cursor: pointer;
        margin-left: 8px;
        transition: color 0.2s;
    }
    .header-fs-icon:hover {
        color: #1a202c;
    }

    .page-body {
        padding: 20px 24px;
        max-width: 100%;
    }

    .typing-card {
        background: #ffffff;
        border-radius: 14px;
        box-shadow: 0 2px 12px rgba(0,0,0,0.06);
        border: 1px solid #e5e7eb;
        overflow: hidden;
    }
    .typing-card-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 12px 20px;
        background: #3b82f6;
        border-bottom: 1px solid #e5e7eb;
        gap: 10px;
    }
    .typing-card-title {
        font-size: 17px;
        font-weight: 600;
        color: #ffffff;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    .typing-card-title i {
        color: #ffffff;
        font-size: 18px;
    }
    .typing-card-badge {
        font-size: 15px;
        font-weight: 600;
        color: #3b82f6;
        background: #eff6ff;
        border: 1px solid #bfdbfe;
        padding: 3px 10px;
        border-radius: 7px;
    }

    .typing-card-body {
        padding: 20px;
    }

    #RRBPassage {
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        font-size: 16px;
        line-height: 1.7;
        color: #334155;
        padding: 16px;
        resize: none;
        width: 100%;
        font-family: 'Roboto', serif;
    }
    #RRBPassage:focus {
        outline: none;
        border-color: #93c5fd;
        box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
    }

    #userInput {
        background: #ffffff;
        border: 2px solid #e2e8f0;
        border-radius: 10px;
        font-size: 17px;
        line-height: 1.7;
        color: #1e293b;
        padding: 16px;
        resize: vertical;
        width: 100%;
        margin-top: 12px;
        font-family: 'Roboto', sans-serif;
        transition: border-color 0.2s;
    }
    #userInput:focus {
        outline: none;
        border-color: #3b82f6;
        box-shadow: 0 0 0 3px rgba(59,130,246,0.12);
    }
    #userInput::placeholder {
        color: #94a3b8;
        font-style: italic;
    }

    .submit-area {
        display: flex;
        justify-content: flex-end;
        padding: 16px 20px;
        background: #f8fafc;
        border-top: 1px solid #e5e7eb;
    }
    .cancel-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 10px 28px;
        font-size: 14px;
        font-weight: 600;
        color: #fff;
        background: linear-gradient(135deg, #ef4444, #dc2626);
        border: none;
        border-radius: 10px;
        cursor: pointer;
        transition: all 0.2s;
        font-family: 'Inter', sans-serif;
        box-shadow: 0 2px 8px rgba(220, 38, 38, 0.3);
    }
    .cancel-btn:hover {
        background: linear-gradient(135deg, #dc2626, #b91c1c);
        box-shadow: 0 4px 14px rgba(220, 38, 38, 0.4);
        transform: translateY(-1px);
    }
    .cancel-btn:active {
        transform: translateY(0);
    }
    .submit-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 10px 28px;
        font-size: 14px;
        font-weight: 600;
        color: #fff;
        background: linear-gradient(135deg, #3b82f6, #2563eb);
        border: none;
        border-radius: 10px;
        cursor: pointer;
        transition: all 0.2s;
        font-family: 'Inter', sans-serif;
        box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
    }
    .submit-btn:hover {
        background: linear-gradient(135deg, #2563eb, #1d4ed8);
        box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
        transform: translateY(-1px);
    }
    .submit-btn:active {
        transform: translateY(0);
    }

    .fullscreen-float {
        position: fixed;
        top: 80px;
        right: 20px;
        z-index: 50;
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #fff;
        border: 1px solid #e2e6ea;
        border-radius: 8px;
        cursor: pointer;
        box-shadow: 0 2px 8px rgba(0,0,0,0.08);
        color: #475569;
        transition: all 0.15s;
    }
    .fullscreen-float:hover {
        background: #f1f5f9;
        color: #1e293b;
    }

    .label {
        display: inline-block;
        padding: 5px 12px;
        margin: 4px;
        border-radius: 6px;
        color: #000;
        font-family: 'Inter', sans-serif;
        font-size: 12px;
        font-weight: 500;
    }
    .omission { background-color: #00FFFF; border-radius: 4px; padding: 1px 3px; }
    .extra { background-color: #FFC1CC; border-radius: 4px; padding: 1px 3px; }
    .spelling { background-color: #FF9999; border-radius: 4px; padding: 1px 3px; }
    .spacing { background-color: #FFA500; border-radius: 4px; padding: 1px 3px; }
    .capitalization { background-color: #FFFF99; border-radius: 4px; padding: 1px 3px; }
    .punctuation { background-color: #DDA0DD; border-radius: 4px; padding: 1px 3px; }
    .para-card-body span[style*="background-color"],
    .para-card-body span.omission,
    .para-card-body span.extra,
    .para-card-body span.spelling,
    .para-card-body span.spacing,
    .para-card-body span.capitalization,
    .para-card-body span.punctuation {
        border-radius: 4px !important;
        padding: 1px 4px !important;
    }

    .result-table {
        background: #fff;
        border-radius: 16px;
        padding: 28px;
        border: 1px solid #e5e7eb;
        box-shadow: 0 4px 24px rgba(0,0,0,0.07);
        margin-top: 20px;
    }
    .result-table > h4 {
        font-size: 20px;
        font-weight: 800;
        color: #1e293b;
        margin-bottom: 20px;
        display: flex;
        align-items: center;
        gap: 10px;
    }
    .result-table > h4::before {
        content: "\F296";
        font-family: "bootstrap-icons";
        color: #3b82f6;
        font-size: 22px;
    }

    .result-pass-fail {
        text-align: center;
        padding: 16px;
        border-radius: 12px;
        margin-bottom: 24px;
    }
    .result-pass-fail.pass {
        background: linear-gradient(135deg, #ecfdf5, #d1fae5);
        border: 1px solid #6ee7b7;
    }
    .result-pass-fail.fail {
        background: linear-gradient(135deg, #fef2f2, #fee2e2);
        border: 1px solid #fca5a5;
    }

    .result-stats-row {
        display: flex;
        flex-wrap: wrap;
        gap: 12px;
        margin-bottom: 24px;
    }
    .result-stat-card {
        flex: 1;
        min-width: 120px;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        padding: 14px 16px;
        text-align: center;
        transition: transform 0.15s ease, box-shadow 0.15s ease;
    }
    .result-stat-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    }
    .result-stat-card .stat-value {
        font-size: 24px;
        font-weight: 800;
        color: #1e293b;
        line-height: 1.2;
    }
    .result-stat-card .stat-label {
        font-size: 11px;
        font-weight: 600;
        color: #64748b;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        margin-top: 4px;
    }
    .result-stat-card.stat-speed .stat-value { color: #16a34a; }
    .result-stat-card.stat-gross .stat-value { color: #3b82f6; }
    .result-stat-card.stat-mistakes .stat-value { color: #dc2626; }
    .result-stat-card.stat-accuracy .stat-value { color: #8b5cf6; }
    .result-stat-card.stat-acc-green .stat-value { color: #16a34a; }
    .result-stat-card.stat-time .stat-value { color: #d97706; }

    .results-container {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 14px;
        max-width: 100%;
        margin: auto;
    }
    .results-section {
        background: #fff;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        padding: 0;
        overflow: hidden;
    }
    .results-section-header {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 10px 14px;
        border-bottom: 1px solid #e2e8f0;
    }
    .results-section-header .section-icon {
        width: 30px;
        height: 30px;
        border-radius: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 14px;
        color: #fff;
        flex-shrink: 0;
    }
    .results-section-header .section-icon.blue { background: #3b82f6; }
    .results-section-header .section-icon.purple { background: #8b5cf6; }
    .results-section-header .section-icon.amber { background: #f59e0b; }
    .results-section-header h2 {
        margin: 0;
        font-size: 13px;
        font-weight: 700;
        color: #334155;
        letter-spacing: 0.3px;
    }
    .compact-list {
        list-style: none;
        margin: 0;
        padding: 0;
    }
    .compact-list li {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 8px 14px;
        font-size: 13px;
        border-bottom: 1px solid #f1f5f9;
    }
    .compact-list li:last-child {
        border-bottom: none;
    }
    .compact-list li:hover {
        background: #f8fafc;
    }
    .compact-list .cl-label {
        color: #475569;
        font-weight: 500;
    }
    .compact-list .cl-value {
        font-weight: 700;
        color: #1e293b;
        min-width: 50px;
        text-align: right;
    }
    .compact-list .cl-value.green { color: #16a34a; }
    .compact-list .cl-value.red { color: #dc2626; }

    @media (max-width: 1024px) {
        .results-container { grid-template-columns: 1fr 1fr; }
    }
    @media (max-width: 640px) {
        .results-container { grid-template-columns: 1fr; }
    }

    .result-legend {
        margin-top: 24px;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        padding: 16px 18px;
    }
    .result-legend-title {
        font-size: 13px;
        font-weight: 700;
        color: #334155;
        margin-bottom: 12px;
        display: flex;
        align-items: center;
        gap: 6px;
    }
    .result-legend-title i {
        color: #3b82f6;
    }
    .result-legend-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }
    .legend-item {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 8px 12px;
        background: #fff;
        border: 1px solid #e5e7eb;
        border-radius: 8px;
        font-size: 12px;
        transition: box-shadow 0.15s ease;
    }
    .legend-item:hover {
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    }
    .legend-dot {
        width: 23px;
        height: 23px;
        border-radius: 5px;
        border-color: #000000;
        flex-shrink: 0;
        border: 0.5px solid #000000;
        }
    .legend-dot.spelling { background-color: #FF9999; }
    .legend-dot.omission { background-color: #00FFFF; }
    .legend-dot.extra { background-color: #FFC1CC; }
    .legend-dot.capitalization { background-color: #FFFF99; }
    .legend-dot.punctuation { background-color: #DDA0DD; }
    .legend-dot.spacing { background-color: #FFA500; }
    .legend-text {
        color: #334155;
        font-weight: 500;
        line-height: 1.3;
    }
    .legend-text .legend-type {
        font-weight: 700;
        color: #1e293b;
    }
    .legend-badge {
        font-size: 10px;
        font-weight: 700;
        padding: 2px 6px;
        border-radius: 4px;
        margin-left: auto;
        white-space: nowrap;
        flex-shrink: 0;
    }
    .legend-badge.full {
        background: #fee2e2;
        color: #dc2626;
    }
    .legend-badge.half {
        background: #fef3c7;
        color: #d97706;
    }
    @media (max-width: 640px) {
        .result-legend-grid { grid-template-columns: 1fr; }
    }

    body.dark-mode .result-legend {
        background: #1a1a2e;
        border-color: #2a2a4a;
    }
    body.dark-mode .result-legend-title {
        color: #e2e8f0;
    }
    body.dark-mode .legend-item {
        background: #16213e;
        border-color: #2a2a4a;
    }
    body.dark-mode .legend-text {
        color: #cbd5e1;
    }
    body.dark-mode .legend-text .legend-type {
        color: #e2e8f0;
    }

    .result-paragraphs {
        margin-top: 24px;
        display: flex;
        flex-direction: column;
        gap: 16px;
    }
    .para-card {
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        overflow: hidden;
        background: #fff;
    }
    .para-card-header {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 16px;
        border-bottom: 1px solid #e2e8f0;
    }
    .para-card-header .para-icon {
        width: 32px;
        height: 32px;
        border-radius: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 15px;
        color: #fff;
        flex-shrink: 0;
    }
    .para-card-header .para-icon.typed {
        background: linear-gradient(135deg, #3b82f6, #2563eb);
    }
    .para-card-header .para-icon.original {
        background: linear-gradient(135deg, #10b981, #059669);
    }
    .para-card-header h4 {
        margin: 0;
        font-size: 14px;
        font-weight: 700;
        color: #334155;
    }
    .para-card-header .para-tag {
        margin-left: auto;
        font-size: 10px;
        font-weight: 600;
        padding: 3px 8px;
        border-radius: 6px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    .para-tag.errors {
        background: #fef2f2;
        color: #dc2626;
        border: 1px solid #fecaca;
    }
    .para-tag.omissions {
        background: #ecfdf5;
        color: #059669;
        border: 1px solid #a7f3d0;
    }
    .para-card-body {
        padding: 16px 18px;
        font-size: 15px;
        line-height: 1.8;
        color: #334155;
    }
    .para-card-body::-webkit-scrollbar {
        width: 6px;
    }
    .para-card-body::-webkit-scrollbar-thumb {
        background: #cbd5e1;
        border-radius: 3px;
    }

    .error-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 13px;
        font-family: 'Inter', sans-serif;
    }
    .error-table thead th {
        background: #f1f5f9;
        padding: 10px 14px;
        text-align: left;
        font-weight: 700;
        color: #334155;
        font-size: 12px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        border-bottom: 2px solid #e2e8f0;
    }
    .error-table tbody td {
        padding: 9px 14px;
        border-bottom: 1px solid #f1f5f9;
        color: #334155;
    }
    .error-table tbody tr:hover {
        background: #f8fafc;
    }
    .error-table .error-type-badge {
        display: inline-block;
        padding: 3px 10px;
        border-radius: 6px;
        font-size: 11px;
        font-weight: 600;
    }
    .error-type-badge.spelling { background: #FF9999; color: #7f1d1d; }
    .error-type-badge.omission { background: #00FFFF; color: #064e3b; }
    .error-type-badge.extra { background: #FFC1CC; color: #881337; }
    .error-type-badge.capitalization { background: #FFFF99; color: #713f12; }
    .error-type-badge.punctuation { background: #DDA0DD; color: #581c87; }
    .error-type-badge.spacing { background: #FFA500; color: #7c2d12; }
    .mistake-badge {
        display: inline-block;
        padding: 3px 10px;
        border-radius: 6px;
        font-size: 11px;
        font-weight: 700;
    }
    .mistake-badge.full {
        background: #fee2e2;
        color: #dc2626;
    }
    .mistake-badge.half {
        background: #fef3c7;
        color: #d97706;
    }
    body.dark-mode .error-table thead th {
        background: #1a1a2e;
        color: #e2e8f0;
        border-bottom-color: #2a2a4a;
    }
    body.dark-mode .error-table tbody td {
        color: #cbd5e1;
        border-bottom-color: #2a2a4a;
    }
    body.dark-mode .error-table tbody tr:hover {
        background: #1a1a2e;
    }

    body.dark-mode .para-card {
        background: #16213e;
        border-color: #2a2a4a;
    }
    body.dark-mode .para-card-header {
        border-bottom-color: #2a2a4a;
    }
    body.dark-mode .para-card-header h4 {
        color: #e2e8f0;
    }
    body.dark-mode .para-card-body {
        color: #cbd5e1;
    }
    body.dark-mode .para-card-body::-webkit-scrollbar-thumb {
        background: #4a5568;
    }
    body.dark-mode .para-tag.errors {
        background: #3b1111;
        border-color: #7f1d1d;
    }
    body.dark-mode .para-tag.omissions {
        background: #064e3b;
        border-color: #065f46;
    }

    body.dark-mode .result-table {
        background: #16213e;
        border-color: #2a2a4a;
    }
    body.dark-mode .result-table > h4 {
        color: #e2e8f0;
    }
    body.dark-mode .result-stat-card {
        background: #1a1a2e;
        border-color: #2a2a4a;
    }
    body.dark-mode .result-stat-card .stat-label {
        color: #94a3b8;
    }
    body.dark-mode .results-section {
        background: #16213e;
        border-color: #2a2a4a;
    }
    body.dark-mode .results-section-header {
        border-bottom-color: #2a2a4a;
    }
    body.dark-mode .results-section-header h2 {
        color: #e2e8f0;
    }
    body.dark-mode .compact-list li {
        border-bottom-color: #1e293b;
    }
    body.dark-mode .compact-list li:hover {
        background: #1a1a2e;
    }
    body.dark-mode .compact-list .cl-label {
        color: #94a3b8;
    }
    body.dark-mode .compact-list .cl-value {
        color: #e2e8f0;
    }
    body.dark-mode .result-paragraphs p {
        background: #0f0f23;
        color: #e2e8f0;
        border-color: #2a2a4a;
    }
    body.dark-mode .result-paragraphs h4 {
        color: #e2e8f0;
    }
    body.dark-mode .result-legend {
        border-top-color: #2a2a4a;
    }

    .result-actions {
        display: flex;
        justify-content: center;
        gap: 12px;
        padding: 20px 16px 8px;
        flex-wrap: wrap;
    }
    .result-action-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 10px 22px;
        border-radius: 10px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        border: none;
        transition: all 0.2s ease;
        letter-spacing: 0.3px;
    }
    .result-action-btn i {
        font-size: 16px;
    }
    .btn-download {
        background: linear-gradient(135deg, #3b82f6, #2563eb);
        color: #fff;
    }
    .btn-download:hover {
        background: linear-gradient(135deg, #2563eb, #1d4ed8);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(37,99,235,0.35);
    }
    .btn-share-wa {
        background: linear-gradient(135deg, #25d366, #128c7e);
        color: #fff;
    }
    .btn-share-wa:hover {
        background: linear-gradient(135deg, #128c7e, #075e54);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(37,211,102,0.35);
    }
    .btn-share-fb {
        background: linear-gradient(135deg, #1877f2, #0d65d9);
        color: #fff;
    }
    .btn-share-fb:hover {
        background: linear-gradient(135deg, #0d65d9, #0a4fb0);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(24,119,242,0.35);
    }
    .btn-share-x {
        background: linear-gradient(135deg, #333, #111);
        color: #fff;
    }
    .btn-share-x:hover {
        background: linear-gradient(135deg, #111, #000);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(0,0,0,0.35);
    }
    .result-watermark {
        display: none;
        text-align: center;
        padding: 12px 0 4px;
        font-size: 13px;
        font-weight: 700;
        color: #64748b;
        letter-spacing: 0.5px;
    }
    .result-watermark span {
        background: linear-gradient(135deg, #3b82f6, #8b5cf6);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }

    body.dark-mode .btn-download {
        background: linear-gradient(135deg, #3b82f6, #2563eb);
    }
    body.dark-mode .result-watermark {
        color: #94a3b8;
    }

    .full-screen .content-area {
        width: 100% !important;
        height: auto;
        position: fixed;
        top: 64px;
        left: 0;
        z-index: 1000;
        background-color: white;
        padding: 10px;
    }
    .full-screen {
        width: 100% !important;
        padding: 0 15px;
        box-sizing: border-box;
    }
    .full-screen #RRBPassage,
    .full-screen #userInput {
        width: calc(100% - 20px);
        margin: 10px;
        font-size: 22px;
        display: block;
    }
    .half-screen .content-area {
        width: auto !important;
        position: static;
    }

    @media (max-width: 768px) {
        .result-stats-row { gap: 8px; }
        .result-stat-card { min-width: 80px; padding: 10px 8px; }
        .result-stat-card .stat-value { font-size: 18px; }
        .result-stat-card .stat-label { font-size: 9px; }
        .header-inner {
            padding: 0 12px;
            height: 56px;
            gap: 6px;
        }
        .header-logo { height: 34px; }
        .header-nav-btn .header-btn-text { display: none; }
        .header-nav-btn { padding: 6px 8px; }
        .header-nav { gap: 4px; }
        .header-sep { margin: 0 6px; display: none; }
        .header-timer { padding: 4px 10px; }
        .header-timer i { font-size: 14px; }
        .header-timer-value { font-size: 15px; }
        .header-timer-label { font-size: 7px; }
        .header-user { padding: 3px 8px 3px 3px; margin-left: 6px; }
        .header-user-avatar { width: 26px; height: 26px; }
        .header-user-name { font-size: 11px; }
        .page-body { padding: 12px; }
        .typing-card-body { padding: 12px; }
        .half-screen {
            width: 70% !important;
            margin: 0 auto;
            padding: 0 10px;
        }
        .full-screen {
            width: 100% !important;
            left: 0;
            padding: 0 5px;
        }
    }

    .ntpc-breadcrumb {
        background: #f8fafc;
        padding: 8px 16px;
        border-bottom: 1px solid #e2e8f0;
        font-family: 'Inter', sans-serif;
        font-size: 0.78rem;
    }
    .ntpc-breadcrumb-list {
        list-style: none;
        display: flex;
        align-items: center;
        gap: 0;
        margin: 0;
        padding: 0;
    }
    .ntpc-breadcrumb-list li {
        display: flex;
        align-items: center;
        color: #64748b;
    }
    .ntpc-breadcrumb-list li a {
        color: #2563eb;
        text-decoration: none;
        font-weight: 500;
    }
    .ntpc-breadcrumb-list li a:hover {
        text-decoration: underline;
    }
    .ntpc-breadcrumb-list li + li::before {
        content: "›";
        margin: 0 8px;
        color: #94a3b8;
        font-size: 1rem;
        font-weight: 600;
    }
    .ntpc-breadcrumb-list li:last-child {
        color: #374151;
        font-weight: 600;
    }
