/* ========== Font & Reset ========== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* ========== Body ========== */
body {
    background: linear-gradient(135deg, #fde047, #3b82f6); /* kuning ke biru */
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 60px;
}

p {
    text-align: center;
    margin-bottom: 20px;
}

/* ========== Card Form ========== */
form {
    background: #ffffff;
    width: 100%;
    max-width: 340px; /* lebih ramping dari 420px */
    padding: 25px 25px; /* dikurangi supaya form lebih pendek */
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    animation: fadeInUp 0.8s ease forwards;
    transform: translateY(20px);
    opacity: 0;
}

/* ========== Title ========== */
h1 {
    text-align: center;
    font-size: 24px; /* sedikit lebih kecil */
    font-weight: 700;
    margin-bottom: 10px; /* jarak antar judul dan input lebih kecil */
    color: #1e3a8a;
    text-shadow: 0 1px 3px rgba(30, 58, 138, 0.3);
}

/* ========== Input Group ========== */
.input-group {
    margin-bottom: 5px; /* sebelumnya 18px */
}

label {
    display: block;
    font-weight: 500;
    color: #1e293b;
    margin-bottom: 4px;
    font-size: 13px;
}

input {
    width: 100%;
    padding: 10px 12px; /* sebelumnya 12px 14px */
    border: 1.3px solid #cbd5e1;
    border-radius: 8px;
    font-size: 13px;
    transition: all 0.3s ease;
}

input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2.5px rgba(59,130,246,0.25);
    outline: none;
}


/* ========== Button ========== */
button {
    width: 100%;
    padding: 10px; /* lebih pendek */
    background: linear-gradient(90deg, #4f46e5, #3b82f6);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 3px 8px rgba(79,70,229,0.3);
    margin-top: 8px;
}

button:hover {
    background: linear-gradient(90deg, #4338ca, #2563eb);
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(37,99,235,0.4);
}

button:active {
    transform: scale(0.98);
}

/* ========== Animasi ========== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== Responsif ========== */
@media (max-width: 480px) {
    body {
        padding-top: 40px;
    }

    form {
        padding: 20px 18px;
        max-width: 300px;
    }

    h1 {
        font-size: 20px;
    }
}

/* =====================================================
   ======= Admin Page Styling (Blue–Yellow Theme) =======
   ===================================================== */

/* Google Font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/* ===== Reset & Base ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: linear-gradient(135deg, #fde047, #3b82f6);
    min-height: 100vh;
    color: #1e293b;
    padding: 30px;
    display: flex;
    justify-content: center;
}

/* ===== Admin Container ===== */
.admin-container {
    width: 100%;
    max-width: 1100px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 30px 35px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.15);
}

/* ===== Header Section ===== */
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

h1 {
    font-size: 26px;
    font-weight: 700;
    color: #1e3a8a;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 1px 3px rgba(30, 58, 138, 0.3);
}

.header-actions {
    display: flex;
    gap: 10px;
    color: black;
}

/* ===== Top Buttons ===== */
.btn {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 8px;
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 3px 8px rgba(79, 70, 229, 0.3);
}

.btn.tambah {
    background: linear-gradient(90deg, #facc15, #fde047);
    color: #1e3a8a;
}

.btn.logout {
    background: linear-gradient(90deg, #4f46e5, #3b82f6);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.15);
}

/* ===== Search Section ===== */
.search-container {
    text-align: center;
    margin-bottom: 25px;
}

.search-form input[type="text"] {
    width: 45%;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1.3px solid #cbd5e1;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-form input[type="text"]:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.25);
    outline: none;
}

.search-form button {
    padding: 10px 16px;
    background: linear-gradient(90deg, #4f46e5, #3b82f6);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    margin-left: 8px;
    transition: all 0.3s ease;
}

.search-form button:hover {
    background: linear-gradient(90deg, #4338ca, #2563eb);
    transform: translateY(-2px);
}

/* ===== Table Section ===== */
.table-container {
    overflow-x: auto;
    margin-bottom: 25px;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border: 1px solid #e2e8f0;
}

th {
    background: linear-gradient(90deg, #4f46e5, #3b82f6);
    color: #fff;
    padding: 14px 18px; /* more breathing room */
    font-weight: 600;
    text-transform: uppercase;
    font-size: 13.5px;
    letter-spacing: 0.3px;
    border-bottom: 2px solid #e2e8f0;
}

td {
    text-align: center;
    padding: 12px 16px; /* more spacing for clarity */
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    color: #1e293b;
    vertical-align: middle;
}

tr:nth-child(even) {
    background-color: #f8fafc; /* alternate row color */
}

tr:hover {
    background-color: #f1f5f9;
    transition: background-color 0.3s ease;
}

/* ===== Action Buttons ===== */
.action-cell {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.btn-ubah,
.btn-hapus {
    padding: 6px 12px;
    border-radius: 6px;
    color: white;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-ubah {
    background-color: #3b82f6;
}

.btn-hapus {
    background-color: #ef4444;
}

.btn-ubah:hover {
    background-color: #2563eb;
    transform: translateY(-1px);
}

.btn-hapus:hover {
    background-color: #dc2626;
    transform: translateY(-1px);
}

/* ===== Pagination ===== */
.pagination-container {
    text-align: center;
    margin-top: 20px;
}

.pagination-container a {
    display: inline-block;
    background-color: #4f46e5;
    color: white;
    padding: 6px 10px;
    margin: 3px;
    border-radius: 6px;
    font-size: 13px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.pagination-container a:hover {
    background-color: #2563eb;
}

.pagination-container a[style*="font-weight: bold"] {
    background-color: #fde047;
    color: #1e3a8a;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .admin-container {
        padding: 20px;
    }

    .search-form input[type="text"] {
        width: 70%;
    }

    table {
        width: 100%;
        font-size: 12.5px;
    }

    th, td {
        padding: 10px 12px;
    }

    .admin-header {
        flex-direction: column;
        gap: 10px;
    }

    .header-actions {
        flex-direction: column;
        gap: 8px;
    }
}

.remember-group {
  font-size: 13px;
  display: flex;
  align-items: center;  /* vertically center checkbox + label */
  gap: 8px;             /* small space between checkbox and text */
}

.remember-checkbox {
  width: auto;
  margin: 0;
}

.remember-label {
  display: inline-block;
  font-size: 0.95em;
  vertical-align: middle;
  padding-top: 3px;
}

.footer-text {
    margin-top: 20px; /* Adds space above the text */
    text-align: center; /* Optional: centers the text */
}

.form-edit {
  display: flex;
  flex-direction: column;
  max-width: 400px;
}

.form-edit label {
  margin-top: 10px;
}

.form-edit input {
  padding: 8px;
  border-radius: 5px;
  border: 1px solid #aaa;
}

.form-actions {
  margin-top: 15px;
  display: flex;
  gap: 10px;
}

.btn {
    display: inline-block;
    padding: 10px 16px;
    border-radius: 6px;
    color: white;
    text-decoration: none;
    font-weight: 500;
}

.btn.tambah {
    background-color: #28a745;
}

.btn.logout {
    background-color: #6c757d;
}

.btn.laporan {
    background-color: #007bff;
}

.btn:hover {
    opacity: 0.9;
}
