/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

/* Card Styles */
.card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #3498db, #2ecc71);
}

.card-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.card-header h1 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 28px;
}

.card-header p {
    color: #7f8c8d;
    font-size: 18px;
}

/* Form Steps */
.form-step {
    display: none;
}

.form-step.active {
    display: block;
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Form Elements */
.form-group {
    margin-bottom: 20px;
    position: relative;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
}

input[type="text"],
input[type="number"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
    background-color: #f9f9f9;
}

input[type="text"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
    border-color: #3498db;
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    background-color: #fff;
}

.radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.radio-group label {
    display: flex;
    align-items: center;
    font-weight: normal;
    cursor: pointer;
    padding: 8px 12px;
    background-color: #f8f9fa;
    border-radius: 6px;
    transition: all 0.2s;
    margin-bottom: 0;
}

.radio-group label:hover {
    background-color: #e9ecef;
}

.radio-group input[type="radio"] {
    margin-right: 8px;
}

.skor-select {
    width: 100px;
}

/* Custom Select Styles */
.custom-select {
    position: relative;
    width: 100%;
}

#divisi_search {
    width: 100%;
    padding: 12px 15px;
    padding-right: 40px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
    background-color: #f9f9f9;
}

#divisi_search:focus {
    border-color: #3498db;
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    background-color: #fff;
}

.dropdown-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: #7f8c8d;
    transition: transform 0.3s;
}

.custom-select.active .dropdown-icon {
    transform: translateY(-50%) rotate(180deg);
}

.options-container {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 250px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.custom-select.active .options-container {
    display: block;
    animation: fadeIn 0.3s;
}

.option {
    padding: 12px 15px;
    cursor: pointer;
    transition: all 0.2s;
    border-bottom: 1px solid #f0f0f0;
}

.option:last-child {
    border-bottom: none;
}

.option:hover {
    background-color: #f0f8ff;
    color: #3498db;
}

.option.selected {
    background-color: #e1f0ff;
    color: #3498db;
    font-weight: 600;
}

.no-results {
    padding: 12px 15px;
    color: #7f8c8d;
    font-style: italic;
}

/* Buttons */
button {
    padding: 12px 25px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-next, .btn-submit {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    box-shadow: 0 4px 6px rgba(52, 152, 219, 0.2);
}

.btn-next:hover, .btn-submit:hover {
    background: linear-gradient(135deg, #2980b9 0%, #2573a7 100%);
    box-shadow: 0 6px 8px rgba(52, 152, 219, 0.3);
    transform: translateY(-2px);
}

.btn-next:active, .btn-submit:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(52, 152, 219, 0.2);
}

.btn-prev {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
    color: white;
    box-shadow: 0 4px 6px rgba(149, 165, 166, 0.2);
}

.btn-prev:hover {
    background: linear-gradient(135deg, #7f8c8d 0%, #6c7b7d 100%);
    box-shadow: 0 6px 8px rgba(149, 165, 166, 0.3);
    transform: translateY(-2px);
}

.btn-prev:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(149, 165, 166, 0.2);
}

.button-group {
    margin-top: 30px;
    display: flex;
    justify-content: space-between;
}

/* Progress Bar */
.progress-bar {
    height: 8px;
    background-color: #ecf0f1;
    border-radius: 4px;
    margin-top: 30px;
    overflow: hidden;
    position: relative;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #3498db, #2ecc71);
    width: 33.33%;
    transition: width 0.5s ease-in-out;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    font-size: 12px;
    color: #7f8c8d;
}

/* Note */
.note {
    background-color: #f8f9fa;
    border-left: 4px solid #3498db;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    position: relative;
}

.note p {
    margin: 0;
    color: #2c3e50;
}

.note::before {
    content: '"';
    font-size: 32px;
    color: #3498db;
    position: absolute;
    left: 10px;
    top: 5px;
    opacity: 0.3;
}

/* Thank You Page */
.thankyou-card {
    text-align: center;
    padding: 50px;
}

.thankyou-card h1 {
    color: #27ae60;
    margin-bottom: 20px;
    font-size: 32px;
}

.thankyou-card p {
    margin-bottom: 15px;
    font-size: 18px;
    color: #7f8c8d;
}

/* Form Validation Styles */
input.error, select.error, textarea.error {
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.2);
}

.error-message {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

input.error + .error-message,
select.error + .error-message,
textarea.error + .error-message {
    display: block;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .card {
        padding: 20px;
    }
    
    .button-group {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-prev, .btn-next, .btn-submit {
        width: 100%;
    }
    
    .radio-group {
        flex-direction: column;
        gap: 10px;
    }
    
    .options-container {
        max-height: 200px;
    }
    
    .card-header h1 {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    input[type="text"],
    input[type="number"],
    input[type="date"],
    select,
    textarea {
        padding: 10px;
    }
    
    .thankyou-card {
        padding: 30px 20px;
    }
    
    .thankyou-card h1 {
        font-size: 24px;
    }
    
    .thankyou-card p {
        font-size: 16px;
    }
}

/* Animation for form steps */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.form-step.active {
    animation: slideIn 0.4s ease-out;
}

/* Loading spinner for submit button */
.btn-submit.loading {
    position: relative;
    color: transparent;
}

.btn-submit.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin: -10px 0 0 -10px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Selection highlight for options */
.option.highlighted {
    background-color: #3498db;
    color: white;
}

/* Scrollbar styling for options container */
.options-container::-webkit-scrollbar {
    width: 8px;
}

.options-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 0 4px 4px 0;
}

.options-container::-webkit-scrollbar-thumb {
    background: #c4c4c4;
    border-radius: 4px;
}

.options-container::-webkit-scrollbar-thumb:hover {
    background: #a0a0a0;
}

