/* General layout */
body {
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #ffe6f2, #e0f7fa);
    font-family: 'Poppins', sans-serif;
}

.main-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    gap: 15px;
}

/* Canvas */
canvas {
    border: 3px dashed #ffb6c1;
    border-radius: 12px;
    background-color: #fffdfd;
    box-shadow: 0 5px 15px rgba(255, 182, 193, 0.3);
    cursor: crosshair;
}

/* Color buttons */
.colors {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.colors button {
    border: 2px solid #fff;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 3px 5px rgba(0, 0, 0, 0.1);
}

.colors button:hover {
    transform: scale(1.3);
    box-shadow: 0 4px 8px rgba(255, 182, 193, 0.5);
}

/* Pastel color palette */
.colors button:nth-of-type(1) { background-color: #fff176; } /* pastel yellow */
.colors button:nth-of-type(2) { background-color: #81d4fa; } /* baby blue */
.colors button:nth-of-type(3) { background-color: #757575; } /* soft gray */
.colors button:nth-of-type(4) { background-color: #f48fb1; } /* pink */
.colors button:nth-of-type(5) { background-color: #a5d6a7; } /* mint green */
.colors button:nth-of-type(6) { background-color: #ffffff; } /* white */


/* Range input (brush size) */
#brush {
    appearance: none;
    width: 200px;
    height: 6px;
    background: #f8bbd0;
    border-radius: 5px;
    outline: none;
    margin: 10px 0;
}
#brush::-webkit-slider-thumb {
    appearance: none;
    width: 18px;
    height: 18px;
    background: #ec407a;
    border-radius: 50%;
    cursor: pointer;
    transition: 0.2s;
}
#brush::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

/* Transparency slider */
#transparent {
    appearance: none;
    width: 200px;
    height: 6px;
    border-radius: 3px;
    outline: none;
    margin: 10px 0;
    background: linear-gradient(to right, rgba(0, 0, 255, 0.1), rgba(0, 0, 255, 1));
}

#transparent::-webkit-slider-thumb {
    appearance: none;
    width: 18px;
    height: 18px; /* added for consistent shape */
    background: blue;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

#transparent::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    background: #3f51b5;
}

/* Buttons (Clear & Save) */
button#clear,
button#save {
    background-color: #ffccdc;
    border: none;
    color: #5e5e5e;
    border-radius: 10px;
    padding: 8px 16px;
    margin: 5px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(255, 182, 193, 0.3);
    transition: transform 0.2s, background 0.2s;
}

button#clear:hover,
button#save:hover {
    transform: scale(1.1);
    background-color: #ffb6c1;
}

/* Subtle animation when hovering the main area */
.main-container:hover canvas {
    box-shadow: 0 8px 20px rgba(255, 182, 193, 0.5);
}
