/* Reset dan Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
    margin: 0;
    padding: 0;
    font-size: 18px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
    background-color: #fff;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
}

/* Header Styles */
header {
    background-color: #4a6da7;
    color: white;
    padding: 25px 0;
    text-align: center;
    border-radius: 10px;
    margin-bottom: 25px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

header h1 {
    color: #1a365d;
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.3;
}

/* Navigation Styles */
nav {
    background-color: #f0f5ff;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 25px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

nav ul {
    list-style-type: none;
    padding: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 0;
}

.nav-btn {
    padding: 15px 20px;
    background-color: #e7eef9;
    color: #4a6da7;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    min-width: 180px;
    text-align: center;
}

.nav-btn:hover {
    background-color: #3498db;
    color: white;
}

.nav-btn.active {
    background-color: #2980b9;
    color: white;
}

/* Section Styles */
.section {
    display: none;
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 25px;
}

.section.active {
    display: block;
}

.section h2 {
    margin-bottom: 25px;
    color: #1a365d;
    border-bottom: 3px solid #ecf0f1;
    padding-bottom: 12px;
    font-size: 1.8rem;
    font-weight: 700;
}

/* Table Styles */
.table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    border-radius: 8px;
    overflow: hidden;
}

table th, table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid #ddd;
    font-size: 1.1rem;
}

table th {
    background-color: #e6f0ff;
    font-weight: bold;
    color: #1a365d;
    font-size: 1.15rem;
}

table tr:hover {
    background-color: #f5f5f5;
}

/* DataTables Custom Styling */
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_processing,
.dataTables_wrapper .dataTables_paginate {
    margin-bottom: 15px;
    color: #333;
    font-size: 1.1rem;
}

/* Meningkatkan tampilan DataTables pada mobile */
.dataTables_wrapper {
    padding: 10px 0;
}

.dataTables_wrapper .dataTables_filter {
    margin-bottom: 20px;
}

.dataTables_wrapper .dataTables_filter input {
    padding: 12px;
    width: 100%;
    max-width: 300px;
    border: 2px solid #bbd6ff;
    border-radius: 8px;
    font-size: 1.1rem;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Tombol Pengurutan */
.sort-button {
    margin-right: 10px;
    margin-bottom: 15px;
    float: left;
    padding: 12px 20px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
}

.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    padding: 10px 15px;
    margin: 0 3px;
    border: 1px solid #bbd6ff;
    border-radius: 8px;
    background-color: #f5f5f5;
    color: #1a365d !important;
    font-size: 1.1rem;
    font-weight: 600;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background-color: #3498db !important;
    color: white !important;
    border-color: #3498db;
}

table.dataTable thead th {
    position: relative;
    background-image: none !important;
}

table.dataTable thead th.sorting:after,
table.dataTable thead th.sorting_asc:after,
table.dataTable thead th.sorting_desc:after {
    position: absolute;
    right: 8px;
    display: block;
    font-family: Arial, sans-serif;
}

table.dataTable thead th.sorting:after {
    content: "\2195";
    opacity: 0.5;
}

table.dataTable thead th.sorting_asc:after {
    content: "\2191";
}

table.dataTable thead th.sorting_desc:after {
    content: "\2193";
}

/* Form Styles */
.form-group {
    margin-bottom: 25px;
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #4a6da7;
}

.form-text {
    display: block;
    margin-top: 5px;
    font-size: 0.85rem;
    color: #6c757d;
    font-style: italic;
}

label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #1a365d;
    font-size: 1.15rem;
}

input[type="text"],
textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #bbd6ff;
    border-radius: 8px;
    font-size: 1.1rem;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.required-field {
    border: 1px solid #e74c3c;
    background-color: rgba(231, 76, 60, 0.05);
}

.required-field::placeholder {
    color: #e74c3c;
}

/* Dropdown Styles */
.input-with-dropdown {
    position: relative;
    width: 100%;
}

datalist {
    width: 100%;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 0 0 4px 4px;
    max-height: 200px;
    overflow-y: auto;
}

input[list] {
    width: 100%;
}

textarea {
    min-height: 100px;
    resize: vertical;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.btn {
    padding: 15px 28px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.15rem;
    font-weight: 600;
    transition: background-color 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background-color: #3498db;
    color: white;
}

.btn-primary:hover {
    background-color: #2980b9;
}

.btn-secondary {
    background-color: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background-color: #7f8c8d;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.nav-btn.btn-danger {
    background-color: #dc3545;
    color: white;
}

.nav-btn.btn-danger:hover {
    background-color: #c82333;
}

.btn-danger:hover {
    background-color: #c0392b;
}

/* Action Buttons in Table */
.action-btn {
    padding: 6px 12px;
    margin-right: 5px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
}

/* Footer Styles */
footer {
    text-align: center;
    margin-top: 30px;
    padding: 20px 0;
    color: #666;
    font-size: 1em;
    background-color: #f0f5ff;
    border-radius: 10px;
    box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.05);
}

/* Aksesibilitas untuk Pengguna Lanjut Usia */
:focus {
    outline: 3px solid #ff6b00;
    outline-offset: 3px;
    box-shadow: 0 0 0 3px rgba(255, 107, 0, 0.3);
    transition: outline-color 0.2s ease-in-out;
}

.help-text {
    display: block;
    margin-top: 10px;
    padding: 12px;
    background-color: #fffde7;
    border-left: 4px solid #ffc107;
    border-radius: 8px;
    font-size: 1.1rem;
    color: #333;
    line-height: 1.5;
}

/* Peningkatan kontras untuk aksesibilitas */
.btn, .nav-btn {
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
}

.btn-primary, .nav-btn.active {
    background-color: #0056b3;
    color: white;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background-color: #0056b3 !important;
    color: white !important;
    font-weight: bold;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .container {
        padding: 10px;
        width: 100%;
        max-width: 100%;
    }
    
    header {
        padding: 15px 0;
    }
    
    header h1 {
        font-size: 1.8rem;
        line-height: 1.3;
        padding: 0 10px;
    }
    
    nav ul {
        flex-direction: column;
        gap: 12px;
        padding: 0 5px;
    }
    
    .nav-btn {
        width: 100%;
        padding: 15px;
        font-size: 1.2rem;
        text-align: center;
    }
    
    .section {
        padding: 15px 10px;
        margin-bottom: 20px;
    }
    
    .section h2 {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    /* Tabel responsif */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 15px;
    }
    
    table.dataTable {
        width: 100% !important;
    }
    
    table th, table td {
        padding: 12px 10px;
        font-size: 1.1rem;
    }
    
    /* DataTables responsif */
    .dataTables_wrapper .dataTables_length, 
    .dataTables_wrapper .dataTables_filter,
    .dataTables_wrapper .dataTables_info, 
    .dataTables_wrapper .dataTables_paginate {
        text-align: center;
        float: none;
        margin: 10px 0;
    }
    
    .dataTables_wrapper .dataTables_filter input {
        width: 80%;
        margin-left: 0;
        margin-top: 5px;
    }
    
    .dataTables_wrapper .dataTables_length select {
        width: 80px;
    }
    
    .dataTables_wrapper .dataTables_paginate .paginate_button {
        padding: 8px 12px;
        margin: 2px;
    }
    
    /* Tombol pengurutan */
    .sort-button {
        width: 100%;
        margin: 0 0 15px 0;
        padding: 12px;
        float: none;
        font-size: 1.1rem;
    }
    
    /* Form responsif */
    .form-group {
        margin-bottom: 20px;
    }
    
    label {
        font-size: 1.2rem;
        margin-bottom: 8px;
    }
    
    input[type="text"],
    textarea {
        padding: 15px;
        font-size: 1.1rem;
    }
    
    .form-text {
        font-size: 1rem;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn {
        width: 100%;
        padding: 15px;
        font-size: 1.2rem;
    }
}