/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f4f4f9;
    color: #333;
    font-size: 16px;
    line-height: 1.6;
    margin-top: 20px;
    margin-bottom: 20px;
}

.container {
    max-width: 450px;
    margin: 0 auto;
    background: #fff;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    animation: fadeIn 0.8s ease-out;
}

h1 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
    font-size: 24px;
    font-weight: 600;
}

.form-group {
    margin-bottom: 15px;
    position: relative;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #333;
}

input[type="date"] {
    position: relative;
    padding: 14px;
    border: 1px solid #e0e0e0;
    border-radius: 15px;
    font-size: 14px;
    background-color: #f4f4f9;
    transition: all 0.3s ease;
    height: 48px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
      /* Ini yang kamu ubah */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23333' viewBox='0 0 24 24'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;

    /* Ubah jarak ikon ke kanan di sini */
    background-position: right 10px center; /* ubah 10px ke 12px atau 15px sesuai kebutuhan */
    background-size: 16px;
}

input[type="text"],
input[type="number"],
input[type="date"],
select {
    width: 100%;
    padding: 14px 40px 14px 14px; /* Padding kanan disesuaikan untuk ikon */
    border: 1px solid #e0e0e0;
    border-radius: 15px;
    font-size: 14px;
    background-color: #f4f4f9;
    transition: all 0.3s ease;
    height: 48px; /* Fixed height for consistency */
}

/* Hide default date picker icon */
/* input[type="date"]::-webkit-calendar-picker-indicator {
    display: none;
} */

input:focus,
select:focus {
    border-color: #00bfa5;
    box-shadow: 0 0 8px rgba(0, 191, 165, 0.5);
    outline: none;
}

select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23333'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 12px;
}

.input-icon {
    position: relative;
}

.input-icon i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #aaa;
    font-size: 16px;
    pointer-events: none;
    line-height: 1;
    height: 100%;
    display: flex;
    align-items: center;
}

.map {
    height: 300px;
    margin-top: 10px;
    margin-bottom: 5px;
    border: 1px solid #e0e0e0;
    border-radius: 15px;
    position: relative;
}

/* Styling for the search box in the map */
.leaflet-control-geocoder-form input {
    width: 100%;
    padding: 10px 10px 10px 40px; /* Space for the search icon */
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    font-size: 14px;
    background-color: #f4f4f9;
    transition: all 0.3s ease;
    box-shadow: none !important; /* Remove default shadow */
    outline: none !important; /* Remove default focus outline */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23aaa'%3E%3Cpath d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0016 9.5c0-3.59-2.91-6.5-6.5-6.5S3 5.91 3 9.5s2.91 6.5 6.5 6.5c1.61 0 3.07-.58 4.23-1.54l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 15px center;
    background-size: 16px;
}

.leaflet-control-geocoder-form input:focus {
    border-color: #00bfa5;
    box-shadow: 0 0 8px rgba(0, 191, 165, 0.5);
}

.leaflet-control-geocoder-form {
    margin: 20px; /* Add space around the search box */
    border-radius: 8px; /* Rounded corners */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Soft shadow */
}

.leaflet-control-geocoder-alternatives {
    background-color: #fff;
    border: 5px solid #e0e0e0;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-height: 200px;
    overflow-y: auto;
    margin-top: 10px; /* Space between map and results */
}

.leaflet-control-geocoder-alternative {
    padding: 10px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.leaflet-control-geocoder-alternative:hover {
    background-color: #e0f7fa;
    transform: scale(1.02);
}

button {
    display: block;
    width: 100%;
    padding: 14px;
    background: linear-gradient(90deg, #00bfa5, #00a897);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    cursor: pointer;
    transition: transform 0.3s ease;
    margin-top: 20px;
}

button:hover {
    transform: scale(1.05);
}

a.btn-home {
    display: block;
    width: 100%;
    padding: 14px;
    background: linear-gradient(90deg, #ffda0b, #f4a402);
    color: white;
    text-align: center;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.3s ease;
    margin-top: 20px;
}

a.btn-home:hover {
    transform: scale(1.05);
}


/* Modal Success Styles */
.modal-success-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-success-box {
    background: #ffffff;
    padding: 25px 30px;
    border-radius: 10px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    position: relative;
    text-align: center;
}

.modal-success-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #aaa;
}

.modal-success-title {
    color: #28a745;
    margin-bottom: 10px;
}

.modal-success-message {
    margin-bottom: 20px;
}

.modal-success-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.btn-success {
    background-color: #28a745;
    color: white;
    padding: 8px 16px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
    padding: 8px 16px;
    border-radius: 5px;
    text-decoration: none;
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 480px) {
    .container {
        padding: 15px;
    }
}