* {
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
}

body {
    background: linear-gradient(1000deg, #0e042c, #161423);
    color: #fff;
    font-size: 15px;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

/* Background decorative elements */
.bg-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.element {
    position: absolute;
    opacity: 0.1;
    border-radius: 50%;
}

.element-1 {
    width: 200px;
    height: 200px;
    background: #673AB7;
    top: 10%;
    left: 5%;
}

.element-2 {
    width: 150px;
    height: 150px;
    background: #3F51B5;
    bottom: 15%;
    right: 10%;
}

.element-3 {
    width: 100px;
    height: 100px;
    background: #2196F3;
    top: 50%;
    left: 20%;
}

.element-4 {
    width: 80px;
    height: 80px;
    background: #03A9F4;
    bottom: 30%;
    right: 25%;
}

.qr-icon {
    position: absolute;
    font-size: 24px;
    color: rgba(255, 255, 255, 0.1);
}

.qr-1 { top: 15%; right: 15%; transform: rotate(15deg); }
.qr-2 { bottom: 20%; left: 15%; transform: rotate(-10deg); }
.qr-3 { top: 40%; right: 25%; transform: rotate(25deg); }

.container {
    margin: 20px auto;
    background-color: #fff;
    color: #000;
    padding: 25px;
    border-radius: 12px;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 1;
}

.header {
    margin-top: 0;
    font-weight: 600;
    font-size: 18px;
    margin-bottom: 20px;
    text-align: center;
    color: #333;
}

.search-box {
    margin-bottom: 25px;
    width: 100%;
    height: 45px;
    padding-left: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.3s;
}

.search-box:focus {
    border-color: #4d63f4;
    outline: none;
}

.btn {
    background: rgb(77, 99, 244);
    color: #fff;
    border: 0;
    box-shadow: 0 10px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    height: 45px;
    border-radius: 8px;
    cursor: pointer;
    opacity: 1;
    font-size: 16px;
    font-weight: 500;
    transition: opacity 0.3s ease, transform 0.1s ease-in-out;
}

/* Hover effect */
.btn:hover {
    opacity: 0.85;
}

/* Active (click) effect */
.btn:active {
    opacity: 0.7;
    transform: scale(0.97);
}

.download-btn {
    background: #28a745;
    color: #fff;
    border: 0;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    height: 45px;
    border-radius: 8px;
    cursor: pointer;
    opacity: 1;
    font-size: 16px;
    font-weight: 500;
    margin-top: 15px;
    transition: opacity 0.3s ease, transform 0.1s ease-in-out;
    display: none;
}

.download-btn:hover {
    opacity: 0.85;
}

.download-btn:active {
    opacity: 0.7;
    transform: scale(0.97);
}

#imgBox {
    width: 180px;
    border-radius: 8px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.8s;
    margin: 0 auto;
}

#imgBox img {
    width: 100%;
    padding: 15px;
}

#imgBox.show-img {
    max-height: 300px;
    margin: 20px auto;
    border: 1px solid #d1d1d1;
}

.error {
    animation: shake 0.1s linear 10;
}

@keyframes shake {
    0% { transform: translateX(0); }
    25% { transform: translateX(-2px); }
    50% { transform: translateX(0); }
    75% { transform: translateX(2px); }
    100% { transform: translateX(0); }
}

.footer {
    text-align: center;
    margin-top: 25px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}