* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #4f46e5, #3b82f6);
    padding: 25px;
}


/* CONTAINER */

.container {
    width: 100%;
    max-width: 460px;
}


/* CARD */

.card {
    background: rgba(255, 255, 255, .95);
    backdrop-filter: blur(12px);
    padding: 35px;
    border-radius: 20px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, .2);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 18px;
    animation: fadeIn .5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(25px)
    }
    to {
        opacity: 1;
        transform: translateY(0)
    }
}

h1 {
    font-weight: 600;
    font-size: 26px;
    color: #111827;
}

.subtitle {
    font-size: 14px;
    color: #6b7280;
}


/* UPLOAD BOX */

.upload-box {
    border: 2px dashed #cbd5e1;
    border-radius: 16px;
    padding: 45px 20px;
    cursor: pointer;
    transition: .25s;
    background: #f8fafc;
    font-size: 15px;
    color: #64748b;
    display: block;
}

.upload-box:hover {
    border-color: #3b82f6;
    background: #eff6ff;
    color: #2563eb;
}


/* hide input */

#file-input {
    display: none;
}


/* IMAGE PREVIEW */

#preview,
#result-img {
    max-width: 100%;
    border-radius: 14px;
    display: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .15);
}


/* BUTTON*/

button {
    border: none;
    padding: 15px;
    border-radius: 14px;
    background: #3b82f6;
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: .25s;
    box-shadow: 0 4px 15px rgba(59, 130, 246, .4);
}

button:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

button:active {
    transform: scale(.97);
}


/* =====================================
   DOWNLOAD LINK
===================================== */

#download {
    display: none;
    text-decoration: none;
    padding: 14px;
    border-radius: 12px;
    background: #10b981;
    color: white;
    font-weight: 600;
    transition: .25s;
}

#download:hover {
    background: #059669;
}


/* LOADER */

.loader {
    width: 40px;
    height: 40px;
    border: 4px solid #e2e8f0;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    margin: auto;
    animation: spin 1s linear infinite;
    display: none;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}


/* MOBILE */

@media(max-width:480px) {
    .card {
        padding: 26px;
    }
    h1 {
        font-size: 22px;
    }
    .upload-box {
        padding: 35px 15px;
    }
}