@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap");

* {
    box-sizing: border-box;
}

body {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
        Tahoma, Geneva, Verdana, sans-serif;
    background: #121212;
    color: #eee;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
}

.tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
}

.tab {
    padding: 12px 24px;
    cursor: pointer;
    border-radius: 8px;
    background: #1e1e1e;
    border: 1px solid #333;
    user-select: none;
    font-weight: 600;
    color: #bbb;
    transition: background-color 0.3s, color 0.3s;
}

.tab.active {
    background: #eee;
    color: #121212;
    box-shadow: 0 0 10px 2px rgba(255, 255, 255, 0.6);
    border-color: #eee;
}

.upload-box {
    background: #1e1e1e;
    padding: 40px 50px;
    box-shadow: 0 0 15px 2px rgba(255, 255, 255, 0.1);
    max-width: 400px;
    width: 100%;
    text-align: center;
    border: 1px solid #333;
    border-radius: 16px;
    transition: box-shadow 0.3s ease;
}

.upload-box:hover {
    box-shadow: 0 0 30px 4px rgba(255, 255, 255, 0.2);
}

h1 {
    font-size: 24px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 24px;
    user-select: none;
}

/* Minimal slider styles */

input[type="range"] {
    -webkit-appearance: none;
    width: 100%;
    height: 4px;
    background: #444;
    border-radius: 2px;
    outline: none;
    margin: 0;
    cursor: pointer;
    transition: background 0.3s ease;
}

input[type="range"]:hover {
    background: #555;
}

/* Webkit browsers */
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: #4caf50;
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: none;
    transition: background 0.3s ease;
    margin-top: -5px;
    /* To vertically center thumb */
}

input[type="range"]:hover::-webkit-slider-thumb {
    background: #66bb6a;
}

/* Firefox */
input[type="range"]::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: #4caf50;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    box-shadow: none;
    transition: background 0.3s ease;
}

input[type="range"]:hover::-moz-range-thumb {
    background: #66bb6a;
}

/* Optional: style the filled part of the track in WebKit */
input[type="range"]::-webkit-slider-runnable-track {
    height: 4px;
    background: linear-gradient(to right,
            #4caf50 0%,
            #4caf50 calc((var(--value, 50) * 1%)),
            #444 calc((var(--value, 50) * 1%)),
            #444 100%);
    border-radius: 2px;
}

/* To update the filled part dynamically, you can update the --value CSS var via JS if you want */

input[type="file"] {
    display: none;
}

label.file-label {
    display: inline-block;
    margin-bottom: 16px;
    padding: 12px 24px;
    border: 2px dashed #bbb;
    background: #2a2a2a;
    color: #eee;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: border-color 0.3s ease, background-color 0.3s ease;
    user-select: none;
}

label.file-label:hover {
    border-color: #eee;
    background: #3a3a3a;
}

button {
    background: #eee;
    color: #121212;
    padding: 14px 30px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(255, 255, 255, 0.3);
    transition: background 0.25s ease, box-shadow 0.25s ease;
    width: 100%;
    max-width: 280px;
    user-select: none;
    margin-top: 12px;
}

button:disabled {
    background: #555;
    cursor: not-allowed;
    box-shadow: none;
    color: #999;
}

button:hover:not(:disabled) {
    background: #ddd;
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.5);
}

.preview-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.preview-wrapper {
    position: relative;
    width: 90px;
    height: 90px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 0 8px rgba(255 255 255 / 0.1),
        inset 0 0 8px rgba(255 255 255 / 0.05);
    background: #222;
    transition: box-shadow 0.25s ease;
}

.preview-wrapper:hover {
    box-shadow: 0 0 15px rgba(255 255 255 / 0.5),
        inset 0 0 15px rgba(255 255 255 / 0.15);
}

.preview-wrapper img,
.preview-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    user-select: none;
    border-radius: 12px;
}

.remove-btn {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 0, 0, 0.85);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.25s ease;
    user-select: none;
    padding: 0;
    z-index: 10;
}

.remove-btn:hover {
    background: rgba(255, 0, 0, 1);
}

.remove-btn svg {
    width: 14px;
    height: 14px;
    stroke: white;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.download-btn {
    margin-top: 15px;
    background: #4caf50;
    color: white;
    border: none;
    padding: 12px 20px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    display: inline-block;
    text-decoration: none;
}