/*
 * File Name: style.css
 * Location: /assets/css/
 * Description: Main styles for the Member Management System.
 */

/* ================================================= */
/* === General Body and Layout === */
/* ================================================= */

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f0f2f5;
    margin: 0;
    color: #1c1e21;
    line-height: 1.6;
}

.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

.main-content {
    flex-grow: 1;
    padding: 30px;
}

.content-column {
    max-width: 900px;
    margin: 0 auto;
}

/* ================================================= */
/* === Sidebar Styles === */
/* ================================================= */

.sidebar {
    width: 280px;
    background-color: #343a40;
    color: white;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}
.sidebar-header {
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid #495057;
}
.sidebar-header h3 {
    margin: 0;
    color: #f1c40f;
    font-size: 1.5em;
}
.sidebar-header a {
    text-decoration: none;
}
.sidebar .nav {
    flex-grow: 1;
    margin-top: 20px;
    list-style: none;
    padding: 0;
}
.sidebar .nav-link {
    color: #adb5bd;
    padding: 12px 20px;
    text-decoration: none;
    display: block;
    border-left: 3px solid transparent;
    font-weight: 500;
}
.sidebar .nav-link:hover {
    background-color: #495057;
    color: white;
}
.sidebar .nav-link.active {
    background-color: #495057;
    color: white;
    border-left-color: #f1c40f;
}
.sidebar-footer {
    margin-top: auto;
    border-top: 1px solid #495057;
    padding: 10px 20px;
    font-size: 0.9em;
}

/* ================================================= */
/* === General UI Elements (Cards, Forms, Buttons) === */
/* ================================================= */

.card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    overflow: hidden;
}
.card-header {
    padding: 16px;
    border-bottom: 1px solid #dddfe2;
}
.card-header h2 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
}
.card-body {
    padding: 16px;
}
.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    font-weight: bold;
    margin-bottom: 8px;
}
.form-control, .form-control-file {
    width: 100%;
    padding: 10px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1em;
}
.btn {
    padding: 10px 15px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1em;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    transition: background-color 0.2s, box-shadow 0.2s;
}
.btn-primary {
    background-color: #1877f2;
    color: white;
}
.btn-primary:hover {
    background-color: #166fe5;
}
.btn-secondary {
    background-color: #6c757d;
    color: white;
}
.btn-secondary:hover {
    background-color: #5a6268;
}

/* ================================================= */
/* === Member Profile Page Styles === */
/* ================================================= */

.profile-header-container {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}
.cover-photo-container {
    height: 350px;
    background-color: #ddd;
    border-radius: 8px 8px 0 0;
    background-size: cover;
    background-position: center;
}
.profile-meta {
    padding: 0 30px;
}
.profile-details-row {
    display: flex;
    align-items: flex-end;
    margin-top: -30px;
    position: relative;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}
.profile-picture-container {
    width: 168px;
    height: 168px;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    background-color: #f0f2f5;
    flex-shrink: 0;
    position: relative;
    margin-top: -120px;
    margin-left: 30px;
}
.profile-picture {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.profile-info {
    margin-left: 30px;
}
.profile-info h1 {
    margin: 0;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
}
.profile-info p {
    color: #65676b;
    margin-top: 4px;
    font-size: 1.05rem;
}
.profile-bio {
    padding: 20px 0;
}
.profile-bio p {
    text-align: center;
    font-size: 1rem;
    color: #65676b;
    margin: 0;
}

/* ================================================= */
/* === Social Media Links Styles === */
/* ================================================= */

.social-links-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    padding: 10px 0;
}
.social-link-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: #e9ecef;
    padding: 8px 15px;
    border-radius: 20px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: background-color 0.2s;
}
.social-link-item:hover {
    background-color: #d8dde1;
}
.social-link-item .fa {
    font-size: 1.2em;
}

.fa-facebook-square { color: #3b5998; }
.fa-twitter { color: #1da1f2; }
.fa-linkedin { color: #0077b5; }
.fa-instagram { color: #e4405f; }
.fa-youtube { color: #ff0000; }
.fa-whatsapp { color: #25d366; }
.fa-snapchat-ghost {
    color: #fffc00;
    text-shadow: 0 0 2px black;
}
.fa-tiktok { color: #000; }
.fa-link { color: #6c757d; }
.fa-phone, .fa-mobile, .fa-building, .fa-home { color: #343a40; }
.fa-envelope { color: #d93025; }
.fa-map-marker { color: #4285f4; }
.fa-commenting { color: #0084ff; }


/* ================================================= */
/* === Modal Styles === */
/* ================================================= */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}
.modal-content {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #ddd;
    padding-bottom: 15px;
    margin-bottom: 20px;
}
.modal-header h2 {
    margin: 0;
}
.close-modal-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    line-height: 1;
}
.social-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
}
.social-grid-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s, box-shadow 0.2s;
}
.social-grid-item:hover {
    background-color: #f8f9fa;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.social-grid-item .fa {
    font-size: 2.5em;
}
.social-grid-item span {
    font-weight: 500;
}

/* Dynamic social fields in form */
.dynamic-social-field {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
}
.dynamic-social-field .fa {
    font-size: 1.5em;
    width: 25px;
    text-align: center;
}
.dynamic-social-field input {
    flex: 1;
}
.dynamic-social-field .remove-social-btn {
    background-color: #dc3545;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
    font-size: 1.2em;
    line-height: 1;
}

/* === RESPONSIVE STYLES === */
@media screen and (max-width: 768px) {
    /* Hides the sidebar on small screens */
    .sidebar {
        display: none;
    }

    .main-content {
        padding: 20px;
    }
}