*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

body { 
    display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background:  linear-gradient(90deg, #74b6ff 0%, #1bdcfd 50%, #45d9fc 100%);
}


h2 {
    background: #1dbcfd;
    color: #fff;
    letter-spacing: 0.1rem;
    padding: 1rem;
    cursor: default;
}

.wrapper {
    width: 60vh;
    background: #fff;
    padding: 2rem;
    box-shadow: 0 0px 2.2px rgba(0, 0, 0, 0.028), 0 0px 5.3px rgba(0, 0, 0, 0.04) rgba(0, 0, 0, 0.05);
    transition: max-width 0.5s ease; /* Smooth transition for width changes */
}

.wrapper p{
    color: #062c33;
    display: block;
    margin: 1rem 0 0.5rem 0;
}


.loading, .success-message {
    display: none;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    font-size: 18px;
    margin-top: 20px;
}

.loading {
    color: white;
    animation: loadingTransition 3s linear forwards;
}

@keyframes loadingTransition {
    0% {
        background-color: #ff0000; /* Red */
    }
    100% {
        background-color: #5cb85c; /* Green */
    }
}

.success-message {
    background-color: #5cb85c;
    color: white;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #fff;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
    display: inline-block;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    width: 80%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    animation: fadeIn 0.5s ease-in-out;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

.modal p {
    font-size: 18px;
    margin: 20px 0;
}

.modal img {
    width: 50px;
    height: 50px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-50px); }
    to { opacity: 1; transform: translateY(0); }
}

.button-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}

button {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    background-color: #007bff;
    color: white;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

button:hover {
    background: rgba(173, 216, 230, 1);
    color: black;
}

button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}


.foto input{
    position: relative;
    padding: auto;
    background: #1dbcfd
}

.foto input:hover{
    background-color: #0056b3;
}

form img{
    padding-top: 10px;
    height: 30%;
    width: 30%;
    object-fit: cover;
}



form label {
    background: #F5F5F5;
    display: block;
    padding: 12px;
    border-radius: 4px;
    width: 100%;
    line-height: 25px;
    border: 1px solid #e5e5e5;
    position: relative;
    cursor: pointer;
}

.sebelumnya {
    background: red;
    color: #fff;
    font-weight: bold;
    margin-top: 1rem ;
    padding: 0.5rem 1rem;
    border: none;
    cursor: pointer;
    transition: background 0.15s;
}

.sebelumnya:hover {
    background: rgba(173, 216, 230, 1);
    color: black;
}

.selanjutnya {
    background: #23fd23;
    color: #fff;
    font-weight: bold;
    margin-top: 1rem ;
    padding: 0.5rem 1rem;
    border: none;
    cursor: pointer;
    transition: background 0.15s;
}

.selanjutnya:hover {
    background: rgba(173, 216, 230, 1);
    color: black;
}

    /* style2.css */

/* Style untuk progress bar */
progress {
    width: 100%;
    height: 20px;
    border: none;
    border-radius: 10px;
    background-color: #f5f5f5;
    overflow: hidden;
    margin-top: 20px;
}

/* Warna progress bar */
progress::-webkit-progress-value {
    background-color: #4CAF50;
    border-radius: 10px;
    transition: width 0.5s ease;
}

/* Style untuk teks persentase */
progress::-webkit-progress-value::after {
    content: attr(value) '%';
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-weight: bold;
    color: #fff;
}

/* Animasi saat progress bar berubah */
progress::-webkit-progress-value {
    transition: width 0.5s ease;
}

/* Warna latar belakang progress bar */
#progress::-webkit-progress-bar {
    background-color: #ddd;
    border-radius: 10px;
}

/* Style saat hover */
progress:hover {
    cursor: pointer;
}

/* Style saat tidak aktif */
progress:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}


/*Respond*/

@media screen and (min-width: 456px) {
    .wrapper {
        max-width: 70%; /* Adjusted max-width for smoother transition */
    }
}

@media screen and (min-width: 768px) {
    .wrapper {
        max-width: 65%;
    }
}

@media screen and (min-width: 992px) {
    .wrapper {
        max-width: 55%;
    }
}

@media screen and (min-width: 1200px) {
    .wrapper {
        max-width: 45%;
    }
}

@media screen and (min-width: 1500px) {
    .wrapper {
        max-width: 35%;
    }
}