.jsond-soft-wrapper {
    /* Biến CSS độc lập */
    --neo-border: 3px solid #111111;
    --neo-shadow: 5px 5px 0px #111111;
    
    --bg-main: #f0f4f8;
    --clr-yellow: #fde74c;
    --clr-cyan: #00f5d4;
    --clr-red: #ff006e;
    --clr-green: #06d6a0;
    --clr-white: #ffffff;
    --clr-text: #111111;

    max-width: 1200px; 
    margin: 0 auto;
    font-family: system-ui, -apple-system, sans-serif;
    color: var(--clr-text);
    background: var(--bg-main);
    padding: 20px;
    border: var(--neo-border);
    border-radius: 16px;
    box-shadow: 6px 6px 0px #111111;
}

.jsond-soft-wrapper * { box-sizing: border-box; }

.jsond-soft-header {
    background: #111; padding: 20px; color: #fff;
    border: var(--neo-border); border-radius: 12px;
    text-align: center; margin-bottom: 20px; box-shadow: var(--neo-shadow);
}
.jsond-soft-header h2 { margin: 0 0 10px 0; font-size: 1.8rem; font-weight: 900; color: var(--clr-cyan); text-transform: uppercase;}
.jsond-soft-header p { margin: 0; font-weight: 600; font-size: 0.95rem; color: #ccc;}

/* TOOLBAR */
.jsond-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 15px;}
.jsond-btn-group { display: flex; gap: 10px; }

.jsond-btn {
    background: #111; color: var(--clr-yellow); padding: 10px 20px;
    border: 2px solid #111; border-radius: 8px; font-size: 1rem; font-weight: 900;
    cursor: pointer; box-shadow: 3px 3px 0px #111; transition: 0.1s;
}
.jsond-btn:active { transform: translate(3px, 3px); box-shadow: 0px 0px 0px #111; }

.jsond-btn-swap {
    background: #fff; color: #111; padding: 10px 15px; border: 2px solid #111; border-radius: 8px; 
    font-size: 1rem; font-weight: 900; cursor: pointer; box-shadow: 3px 3px 0px #111; transition: 0.1s;
}
.jsond-btn-swap:active { transform: translate(3px, 3px); box-shadow: 0px 0px 0px #111; }

.jsond-btn-clear {
    background: #fff; color: var(--clr-red); padding: 10px 20px;
    border: 2px solid #111; border-radius: 8px; font-size: 1rem; font-weight: 900;
    cursor: pointer; box-shadow: 3px 3px 0px #111; transition: 0.1s;
}
.jsond-btn-clear:active { transform: translate(3px, 3px); box-shadow: 0px 0px 0px #111; }

.jsond-btn-toggle {
    background: #111; color: var(--clr-cyan); padding: 6px 12px; border: 2px solid #111; border-radius: 6px; 
    font-size: 0.85rem; font-weight: 900; cursor: pointer; box-shadow: 2px 2px 0px #111; transition: 0.1s;
}
.jsond-btn-toggle.active { background: var(--clr-cyan); color: #111; }
.jsond-btn-toggle:active { transform: translate(2px, 2px); box-shadow: 0px 0px 0px #111; }


/* BỐ CỤC 2 CỘT INPUT */
.jsond-main-layout { display: flex; flex-direction: column; gap: 20px; position: relative; margin-bottom: 20px;}
.jsond-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 20px;}
@media (min-width: 768px) { .jsond-main-layout { flex-direction: row; align-items: stretch; } }

/* CARDS */
.jsond-card {
    padding: 15px; border: var(--neo-border); background: #fff; position: relative;
    border-radius: 12px; box-shadow: var(--neo-shadow); display: flex; flex-direction: column; height: 100%; transition: 0.3s;
}
.jsond-bg-yellow { background: var(--clr-yellow); }
.jsond-bg-white { background: var(--clr-white); }
.jsond-flex-between { display: flex; justify-content: space-between; align-items: center; }

/* TIÊU ĐỀ & BADGE */
.jsond-section-title { font-size: 1.1rem; font-weight: 900; color: #111; text-transform: uppercase; }

.jsond-badge { white-space: nowrap; flex-shrink: 0; background: #eee; padding: 4px 10px; border: 2px solid #111; border-radius: 6px; font-weight: 900; font-size: 0.85rem; box-shadow: 2px 2px 0px #111;}
.jsond-badge.active { background: var(--clr-green); color: #111; }
.jsond-badge.error { background: var(--clr-red); color: #fff; }

/* TEXTAREA */
.jsond-textarea {
    width: 100%; min-height: 250px; flex: 1; padding: 15px; border: 3px solid #111; border-radius: 8px;
    font-size: 1rem; font-weight: 600; outline: none; box-shadow: inset 3px 3px 0px rgba(0,0,0,0.05); font-family: monospace; resize: vertical; line-height: 1.6; white-space: pre; background: #fff;
}
.jsond-textarea:focus { border-color: var(--clr-cyan); box-shadow: inset 3px 3px 0px rgba(0,0,0,0.05), 0 0 0 3px #111; }

/* KẾT QUẢ SO SÁNH */
.jsond-result-box {
    background: #fff; border: var(--neo-border); border-radius: 12px; padding: 20px; box-shadow: var(--neo-shadow);
}
.jsond-visual-content {
    background: #fdfdfd; border: 2px dashed #ccc; border-radius: 8px; padding: 15px; overflow-x: auto;
    font-family: monospace; font-size: 1rem; line-height: 1.6;
}

.jsond-no-diff {
    background: rgba(6, 214, 160, 0.2); border: 2px dashed var(--clr-green); color: #005a41; 
    padding: 20px; text-align: center; font-weight: bold; font-size: 1.1rem; border-radius: 8px;
}

/* Override CSS của jsondiffpatch để hợp tông Neo-brutalism */
.jsondiffpatch-delta { font-family: monospace !important; font-size: 15px !important;}
.jsondiffpatch-added { background-color: #d1f7ec !important; border: 1px solid var(--clr-green) !important; border-radius: 4px; padding: 0 4px;}
.jsondiffpatch-deleted { background-color: #ffdce8 !important; border: 1px solid var(--clr-red) !important; text-decoration: line-through; border-radius: 4px; padding: 0 4px;}
.jsondiffpatch-modified .jsondiffpatch-right-value { background-color: var(--clr-yellow) !important; color: #111 !important; border: 1px solid #111 !important; border-radius: 4px; padding: 0 4px; font-weight: bold;}
.jsondiffpatch-modified .jsondiffpatch-left-value { text-decoration: line-through; color: #888; margin-right: 5px;}

/* INFO BOX */
.jsond-info-box { background: rgba(255,255,255,0.6); padding: 15px; border: 2px dashed #111; border-radius: 8px; margin-top: 20px;}
.jsond-info-box h4 { margin: 0 0 5px 0; font-weight: 900; color: #111; font-size: 1rem;}
.jsond-info-box p { margin: 0; font-size: 0.9rem; font-weight: 600; line-height: 1.5; color: #333;}