/* GIAO DIỆN SOFT BRUTALISM - BOX SHADOW GENERATOR */
.tool-container {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    max-width: 1000px; margin: 20px auto;
    border: 3px solid #111111; border-radius: 12px;
    box-shadow: 6px 6px 0px #111111; padding: 30px;
    background: #ffffff; color: #111111; box-sizing: border-box;
}

h2.tool-title {
    font-family: 'Montserrat', sans-serif; font-size: 2rem; text-align: center;
    text-transform: uppercase; margin-top: 0; margin-bottom: 25px; font-weight: 900;
}

.main-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }

.panel-heading {
    font-family: 'Montserrat', sans-serif; font-size: 1.2rem; font-weight: 900;
    margin-top: 0; margin-bottom: 20px; border-bottom: 3px dashed #111111; padding-bottom: 10px;
}

/* --- Cột Điều Khiển --- */
.controls-panel {
    background-color: #f4f4f4; border: 3px solid #111111; border-radius: 8px;
    padding: 25px; box-shadow: 4px 4px 0px #111111;
}

.slider-group { margin-bottom: 20px; }
.slider-group label { display: flex; justify-content: space-between; font-weight: 800; margin-bottom: 10px; font-size: 1rem; }
.slider-group span { color: #2d7bb5; }

/* Custom Range Slider phong cách Brutalism */
.slider-brutal {
    -webkit-appearance: none; width: 100%; height: 12px; background: #e0e0e0;
    border: 2px solid #111111; border-radius: 6px; outline: none; cursor: pointer;
}
.slider-brutal::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none; width: 22px; height: 22px;
    background: #ffb7b2; border: 3px solid #111111; border-radius: 4px; cursor: pointer;
    box-shadow: 2px 2px 0px #111111;
}

.color-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 20px; }
.color-picker-group label { display: block; font-weight: 700; font-size: 0.9rem; margin-bottom: 5px; text-align: center;}
.color-picker-group input[type="color"] {
    width: 100%; height: 40px; border: 3px solid #111111; border-radius: 6px;
    padding: 0; cursor: pointer; background: none; box-shadow: 2px 2px 0px #111111;
}

.checkbox-container {
    display: flex; align-items: center; cursor: pointer;
    font-weight: 800; font-size: 1.05rem; user-select: none; margin-top: 10px;
}
.checkbox-container input {
    margin-right: 10px; width: 22px; height: 22px; accent-color: #111111; cursor: pointer;
}

/* --- Cột Hiển Thị & Code --- */
.preview-panel { display: flex; flex-direction: column; gap: 20px; }

.preview-area {
    width: 100%; height: 300px; border: 3px solid #111111; border-radius: 8px;
    background-color: #ffffff; display: flex; align-items: center; justify-content: center;
    position: relative; overflow: hidden;
}

/* Ô Box mẫu */
.preview-box {
    width: 150px; height: 150px; background-color: #fdfd96; border: 3px solid #111111;
    border-radius: 12px; transition: box-shadow 0.1s, background-color 0.2s;
    box-shadow: 10px 10px 0px 0px rgba(17, 17, 17, 1);
}

.code-wrapper { background-color: #e6f7ff; border: 3px solid #111111; border-radius: 8px; padding: 20px; box-shadow: 4px 4px 0px #111111; }
.code-wrapper h4 { margin: 0 0 10px 0; font-family: 'Montserrat', sans-serif; font-size: 1rem; }

.code-box {
    background-color: #111111; color: #b5ead7; padding: 15px; border-radius: 6px;
    font-family: monospace; font-size: 1.1rem; word-break: break-all; margin-bottom: 15px;
}

.btn-copy {
    width: 100%; cursor: pointer; font-family: 'Montserrat', sans-serif; font-size: 1.1rem;
    font-weight: 900; padding: 15px; border: 3px solid #111111; border-radius: 8px;
    box-shadow: 4px 4px 0px #111111; transition: transform 0.1s, box-shadow 0.1s;
    text-transform: uppercase; color: #111111; background-color: #b5ead7;
}
.btn-copy:active { transform: translate(4px, 4px); box-shadow: 0px 0px 0px #111111; }

/* Toast */
#toastCSS {
    visibility: hidden; min-width: 200px; background-color: #111111; color: #ffffff;
    text-align: center; border-radius: 8px; padding: 12px; position: fixed;
    z-index: 9999; bottom: 30px; left: 50%; transform: translateX(-50%);
    font-weight: bold; opacity: 0; transition: opacity 0.3s, bottom 0.3s;
}
#toastCSS.show { visibility: visible; opacity: 1; bottom: 50px; }

@media (max-width: 800px) {
    .main-layout { grid-template-columns: 1fr; }
}