/* Reset gaya default browser */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Gaya body dan container */
body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 400px;
    padding: 30px;
    background-color: #fff;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    animation: fadeIn 1s ease-in-out;
    position: relative;
}

h2 {
    text-align: center;
    color: #4a4a4a;
    margin-bottom: 25px;
    font-size: 28px;
    font-weight: 700;
    position: relative;
}

h2 i {
    color: #667eea;
    margin-right: 8px;
}

/* Gaya input form */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    font-weight: bold;
    color: #333;
    font-size: 14px;
    margin-bottom: 8px;
    display: block;
}

.input-group label i {
    color: #667eea;
    margin-right: 8px;
}

form input, form select {
    width: 100%;
    padding: 14px;
    border: 2px solid #ccc;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
}

form input:focus, form select:focus {
    border-color: #667eea;
    box-shadow: 0 0 5px rgba(102, 126, 234, 0.5);
    outline: none;
}

/* Gaya tombol */
form button {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    text-transform: uppercase;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

form button:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46c1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* Gaya hasil */
#hasil {
    display: none;
    margin-top: 30px;
    padding: 20px;
    background-color: #f4f4f4;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    animation: fadeInUp 0.7s ease;
}

#hasil p {
    font-size: 16px;
    margin: 10px 0;
    font-weight: bold;
    color: #333;
    text-align: center;
}

/* Gaya dropdown */
.dropdown {
    margin-bottom: 20px;
    position: relative;
}

.dropdown-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.dropdown-btn i {
    margin-left: 10px;
    font-size: 18px;
    transition: transform 0.3s ease;
}

/* Rotate icon on open */
.dropdown-btn .rotate {
    transform: rotate(180deg);
}

.dropdown-btn:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46c1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #f9f9f9;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    z-index: 1;
    width: 100%;
    border-radius: 8px;
    animation: fadeIn 0.3s ease-in-out;
    top: 55px; /* adjust as per your dropdown button height */
}

.dropdown-content a {
    color: black;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-weight: bold;
    border-radius: 8px;
}

.dropdown-content a:hover {
    background-color: #f1f1f1;
}

.dropdown-open {
    display: block;
}

/* Animasi */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsif untuk perangkat kecil */
@media (max-width: 600px) {
    .container {
        padding: 20px;
    }

    h2 {
        font-size: 24px;
    }

    form input, form select {
        font-size: 12px;
        padding: 12px;
    }

    form button {
        font-size: 16px;
        padding: 12px;
    }

    #hasil p {
        font-size: 14px;
    }

    .dropdown-btn {
        font-size: 16px;
        padding: 12px;
    }
}

.copy-icon {
    position: absolute;
    right: 0; /* Posisikan di sebelah kanan */
    bottom: 0; /* Posisikan di bawah */
    cursor: pointer;
    font-size: 20px; /* Ukuran ikon */
    margin: 10px; /* Memberi ruang di sekitar ikon */
    color: #007bff; /* Warna ikon */
}
.copy-icon:hover {
    color: #0056b3; /* Warna saat di-hover */
}