body { 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    background-color: #f4f4f9; 
    color: #333; 
    margin: 0;
}

.page-container {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    overflow: hidden;
}

header {
    background-color: #066ae1;
    color: #ffffff;
    padding: 0.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left {
    display: flex;
    align-items: center;
}

.logo {
    height: 40px;
    margin-right: 1rem;
}

header h1 {
    color: #ffffff;
    margin: 0;
    font-size: 1.5rem;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

#user-info {
    font-size: 0.9rem;
    text-align: right;
}

#logout-btn {
    background-color: #ffffff;
    color: #066ae1;
    border: 1px solid #ffffff;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s;
    white-space: nowrap;
}

#logout-btn:hover {
    background-color: #f0f0f0;
}

footer {
    background-color: #066ae1;
    color: #ffffff;
    text-align: center;
    padding: 1rem 0;
    flex-shrink: 0;
    /* margin-top: 2rem; */
}

main { 
    max-width: 1200px; 
    margin: 2rem auto; 
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
    overflow-y: auto;
}

.form-container { 
    background-color: #fff; 
    padding: 2rem; 
    border-radius: 8px; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.1); 
    margin-bottom: 2rem; 
    /* overflow-x: auto */
}

.data-container {
    background-color: #fff; 
    padding: 2rem; 
    border-radius: 8px; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.1); 
    margin-bottom: 2rem; 
    overflow-x: auto 
}

.table-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

#search-input {
    padding: 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 250px;
}

h2 { 
    color: #34495e; 
    margin-top: 0;
}

form { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); 
    gap: 1rem; 
}

input, textarea { 
    padding: 0.8rem; 
    border: 1px solid #ccc; 
    border-radius: 4px; 
    font-size: 1rem; 
}

textarea { 
    grid-column: 1 / -1; 
    resize: vertical; 
}

button[type="submit"] { 
    grid-column: 1 / -1; 
    background-color: #066ae1; 
    color: white; 
    border: none; 
    cursor: pointer; 
    transition: background-color 0.3s;
    padding: 0.8rem;
    font-size: 1rem;
    border-radius: 4px;
}

button[type="submit"]:hover { 
    background-color: #055ac8;
}

table { 
    width: 100%; 
    border-collapse: collapse; 
    margin-top: 1rem; 
    overflow-x: auto;
    display: block;
}

th, td { 
    padding: 0.8rem; 
    text-align: left;
    border-bottom: 1px solid #ddd; 
    white-space: nowrap;
}

th { 
    background-color: #ecf0f1; 
}

th[data-sort] {
    cursor: pointer;
    user-select: none;
}

th[data-sort]:hover {
    background-color: #dfe6e9;
}

.action-btn {
    color: white;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-right: 5px;
}

.edit-btn {
    background-color: #f39c12;
}
.edit-btn:hover {
    background-color: #e67e22;
}

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

/* Modal Styles */
.modal {
    display: none; 
    position: fixed; 
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 2rem;
    border: 1px solid #888;
    width: 80%;
    max-width: 700px;
    border-radius: 8px;
    position: relative;
}

.close-btn {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 25px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-btn:hover, .close-btn:focus {
    color: black;
}

/* --- Birthday Popup Styles --- */
#birthday-popup {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 280px;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1001;
    padding: 1.5rem;
    font-size: 0.9rem;
}

#birthday-popup h3 {
    margin-top: 0;
    color: #066ae1;
    text-align: center;
}

#birthday-popup ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

#birthday-popup li {
    padding: 4px 0;
    text-align: center;
    border-bottom: 1px solid #eee;
}

#birthday-popup li:last-child {
    border-bottom: none;
}

.bio-link {
    color: #066ae1;
    text-decoration: none;
    font-weight: bold;
}
.bio-link:hover {
    text-decoration: underline;
}

/* --- Bio Page Image & Button Styles --- */

.profile-picture-container {
    text-align: center; /* Centers the content */
}

#profile-picture {
    width: 200px;
    height: 200px;
    object-fit: cover; /* Prevents image from stretching */
    border-radius: 8px;
    border: 1px solid #ddd;
    background-color: #f8f8f8;
    display: block; /* Helps with centering */
    margin: 0 auto 1rem auto; /* Adds space below the image */
}

.picture-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
}

#change-pic-btn, #remove-pic-btn {
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s;
}

#change-pic-btn {
    background-color: #3498db;
    color: white;
}
#change-pic-btn:hover {
    background-color: #2980b9;
}

#remove-pic-btn {
    background-color: #bdc3c7;
    color: #34495e;
}
#remove-pic-btn:hover {
    background-color: #95a5a6;
}

#back-button {
    display: inline-block;
    margin-bottom: 1.5rem;
    color: #066ae1;
    text-decoration: none;
    font-weight: bold;
}
#back-button:hover {
    text-decoration: underline;
}

#splash-screen {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.6);
    color: #333;
}

#splash-screen .modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 2rem;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    border-radius: 8px;
}

.splash-agree {
    margin: 1.5rem 0;
}

#agree-btn {
    background-color: #27ae60;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
}

#agree-btn:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

/* --- Pagination Styles --- */
.pagination-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1.5rem;
    gap: 1rem;
    user-select: none;
}

.pagination-controls button {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    background-color: #fff;
    border-radius: 4px;
    cursor: pointer;
}

.pagination-controls button:hover:not(:disabled) {
    backgrond-color: #f0f0f0;
}

.pagination-controls button:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}