body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f0f2f5;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    color: #333;
}

.container {
    background: white;
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

h1 {
    margin-bottom: 1.5rem;
    font-weight: 700;
    color: #1a1a1a;
}

.preview-card {
    background: #fafafa;
    padding: 1rem;
    border-radius: 15px;
    border: 1px solid #eee;
    margin-bottom: 2rem;
}

.preview-box {
    width: 100%;
    height: 150px;
    border-radius: 10px;
    margin-bottom: 1rem;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.1);
    transition: background-color 0.15s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

#previewHex {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-weight: 700;
    font-size: 1.2rem;
    color: white;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    pointer-events: none;
}

.color-values {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.value-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: white;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.label {
    font-size: 0.75rem;
    font-weight: bold;
    color: #888;
    text-transform: uppercase;
    width: 40px;
    text-align: left;
}

#hexValue, #rgbValue {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-weight: 600;
    flex-grow: 1;
    text-align: center;
}

.copy-btn {
    background: #f0f0f0;
    border: none;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    cursor: pointer;
    transition: background 0.2s;
}

.copy-btn:hover {
    background: #e0e0e0;
}

.controls {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.slider-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    font-weight: 600;
    font-size: 0.9rem;
}

.slider {
    -webkit-appearance: none;
    width: 100%;
    height: 8px;
    border-radius: 5px;
    outline: none;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: white;
    border: 2px solid #333;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.red-slider { background: linear-gradient(to right, #ffcccc, #ff0000); }
.green-slider { background: linear-gradient(to right, #ccffcc, #00ff00); }
.blue-slider { background: linear-gradient(to right, #ccccff, #0000ff); }

.actions {
    display: flex;
    justify-content: center;
}

.secondary-btn {
    background-color: #333;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s, background 0.2s;
}

.secondary-btn:active {
    transform: scale(0.95);
}

.secondary-btn:hover {
    background-color: #000;
}