/* ================= RESET ================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* ================= BODY (GRADIENT) ================= */
body {
    color: #fff;
    overflow-x: hidden;
    background: linear-gradient(135deg, #0a0a0f, #1c1c2e, #1a1a2a);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ================= HEADER ================= */
.header-container {
    position: relative;
    padding: 20px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-logo {
    height: 100px;
    width: auto;
    border: 3px solid #1abc9c;
    border-radius: 15px;
    padding: 5px;
    box-shadow: 0 6px 15px rgba(0,255,240,0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.header-logo:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(0,255,240,0.7);
}

.header-texts {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
}

.header-text {
    font-size: 32px;
    font-weight: 800;
    background: linear-gradient(90deg, #ff4e50, #f9d423);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 3px 10px rgba(0,0,0,0.3);
}

.header-texts h1 {
    font-size: 30px;
    font-weight: 700;
    color: #21cf0a;
    text-shadow: 2px 2px 10px rgba(0,255,240,0.5);
    line-height: 1.2;
}

.header-texts p {
    font-size: 16px;
    font-weight: 500;
    color: #ffcc00;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.3);
    margin: 0;
    letter-spacing: 1px;
}

/* ================= HERO ================= */
.hero {
    text-align: center;
    padding: 80px 20px;
}

.hero h1 {
    font-size: 40px;
    margin-bottom: 25px;
    animation: fadeIn 1s ease;
    color: #00f0ff;
    text-shadow: 0 0 10px #00f0ff;
}

/* ================= UNIQUE BUTTONS ================= */
.hero button,
.modal-content button,
#loadMoreBtn,
.card button {
    padding: 14px 28px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    background: linear-gradient(135deg, #ff0080, #00fff0);
    color: #fff;
    box-shadow: 0 4px 20px rgba(255,0,128,0.3);
    transition: 0.4s ease;
}

.hero button:hover,
.modal-content button:hover,
#loadMoreBtn:hover,
.card button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(0,255,240,0.5);
}

/* ================= SEARCH ================= */
.search-box {
    text-align: center;
    margin: 30px 0;
}

.search-box input {
    padding: 14px;
    width: 280px;
    border-radius: 12px;
    border: none;
    outline: none;
    background: #111;
    color: #fff;
}

/* ================= MEMBERS ================= */
#members {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    padding: 20px;
}

.card {
    width: 200px;
    padding: 20px;
    border-radius: 20px;
    text-align: center;
    background: rgba(255,255,255,0.05);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(0,255,240,0.3);
    transition: 0.4s ease;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 0 25px rgba(0,255,240,0.5);
}

.card img {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #00fff0;
}

.card h3 {
    margin: 10px 0;
}

.status {
    font-size: 13px;
}

.status.active { color: #00fff0; }
.status.offline { color: #aaa; }

/* ================= MODAL ================= */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    justify-content: center;
    align-items: center;
    z-index: 2000;
    overflow-y: auto;
}

.modal-content {
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(15px);
    padding: 30px;
    border-radius: 20px;
    width: 420px;
    max-width: 95%;
    text-align: center;
    border: 1px solid rgba(0,255,240,0.3);
    box-shadow: 0 0 25px rgba(0,255,240,0.3);
}

.modal-content input,
.modal-content select {
    width: 90%;
    padding: 12px;
    margin: 10px 0;
    border: none;
    border-radius: 10px;
    background: #111;
    color: #fff;
    outline: none;
}

.modal-content input:focus,
.modal-content select:focus {
    background: #222;
    box-shadow: 0 0 10px #00fff0;
}

.close {
    position: absolute;
    right: 20px;
    top: 15px;
    cursor: pointer;
    font-size: 20px;
    color: #00fff0;
}

/* ================= FILE BUTTON ================= */
input[type="file"] { display: none; }

.file-label {
    display: inline-block;
    padding: 12px 20px;
    background: #111;
    border-radius: 10px;
    cursor: pointer;
    text-align: center;
    transition: 0.3s;
    border: 1px solid #00fff0;
}

.file-label:hover {
    background: #222;
}

/* ================= PROFILE MODAL ================= */
#profileModal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.85);
    border-radius: 20px;
    padding: 25px;
    width: 90%;
    max-width: 450px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
    z-index: 1000;
}

#profileModal #profileData {
    max-height: 80vh;
    overflow-y: auto;
    padding-right: 10px;
}

#profileModal #profileData::-webkit-scrollbar {
    width: 8px;
}

#profileModal #profileData::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.05);
    border-radius: 10px;
}

#profileModal #profileData::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #00fff0, #ff0080);
    border-radius: 10px;
}

#profileData img.profile-pic {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 12px;
    border: 3px solid #00fff0;
}

#profileData .cnic-images img {
    width: 48%;
    height: 120px;
    object-fit: cover;
    border: 2px solid #00fff0;
    border-radius: 10px;
}

#profileData #qrCode {
    width: 180px;
    height: 180px;
    border: 2px solid #00fff0;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 15px auto;
    border-radius: 12px;
}

#profileData .btns {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 10px;
}

#profileData .btns button {
    padding: 8px 16px;
    border: none;
    border-radius: 12px;
    font-size: 13px;
    cursor: pointer;
    font-weight: bold;
    color: #000;
    background: linear-gradient(135deg, #00fff0, #ff0080);
    transition: 0.3s;
}

#profileData .btns button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 12px #00fff0;
}

/* ================= GALLERY ================= */
#public-gallery-section {
    padding: 40px 20px;
    text-align: center;
}

#publicGalleryContainer {
    display: grid;
    grid-template-columns: repeat(auto-fill,minmax(280px,1fr));
    gap: 20px;
    padding: 10px;
}

.public-gallery-box {
    width: 100%;
    height: 250px;
    border-radius: 18px;
    overflow: hidden;
    position: relative;
    background: #111;
    transition: .4s;
}

.public-gallery-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: .5s;
}

.public-gallery-box:hover img {
    transform: scale(1.1);
}

.public-gallery-box:hover {
    box-shadow: 0 0 25px #00fff0;
}

/* ================= ADMIN GALLERY ================= */
.gallery-box {
    width: 200px;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.gallery-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-box-controls {
    position: absolute;
    bottom: 5px;
    width: 100%;
    display: flex;
    justify-content: space-between;
}

/* ================= ADMIN GALLERY SCROLL FIX ================= */
#adminGalleryList {
    max-height: 400px;
    overflow-y: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-right: 5px;
}

#adminGalleryList::-webkit-scrollbar {
    width: 8px;
}

#adminGalleryList::-webkit-scrollbar-thumb {
    background: linear-gradient(#00fff0, #ff0080);
    border-radius: 10px;
}

/* ================= PREMIUM FONTS ================= */
.section-title {
    font-size: 32px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 10px;
    background: linear-gradient(90deg,#32aaaa,#555153);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 1.5px;
}

.section-subtitle {
    text-align: center;
    color: #aaa;
    font-size: 14px;
    margin-bottom: 35px;
    letter-spacing: 1px;
}

.member-name {
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.5px;
}

.member-info {
    font-size: 13px;
    color: #bbb;
}

/* ================= LOAD MORE ================= */
#loadMoreBtn {
    display: block;
    margin: 30px auto;
}

/* ================= MESSAGE ================= */
#msgBox {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 15px 25px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 16px;
    color: #fff;
    display: none;
    z-index: 9999;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
    transition: all 0.3s ease;
}
#msgBox.success { background-color: #1abc9c; }
#msgBox.error { background-color: #e74c3c; }
#msgBox.warning { background-color: #f39c12; }

/* ================= NAVBAR ================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0,255,240,0.3);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: bold;
    color: #00fff0;
}

.logo img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

nav a {
    margin: 0 12px;
    text-decoration: none;
    color: #fff;
    font-size: 15px;
    transition: .3s;
}

nav a:hover {
    color: #00fff0;
}

/* MOBILE ADJUSTMENTS */
@media (max-width: 768px) {
    #members {
        justify-content: space-between;
    }
    #members .card {
        width: calc((100% - 40px) / 3);
        margin-bottom: 20px;
    }
    .card {
        width: 32%;
        padding: 10px;
    }
    .card img {
        width: 70px;
        height: 70px;
    }
    .card h3 {
        font-size: 12px;
    }
    nav {
        display: none;
        flex-direction: column;
        background: #111;
        width: 100%;
        text-align: center;
    }
    nav.active {
        display: flex;
    }
    .menu-toggle {
        display: block;
    }
}

.menu-toggle {
    display: none;
    font-size: 26px;
    cursor: pointer;
    color: #00fff0;
}

/* ================= FILE PREVIEWS ================= */
#previewPic,
#previewFront,
#previewBack {
    display: block;
    width: 300px;
    height: 200px;
    max-width: 100%;
    object-fit: cover;
    border-radius: 12px;
    border: 3px solid #00fff0;
    margin: 10px auto;
}

.cnic-preview-container {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    max-width: 260px;
    margin: 10px auto;
}

.cnic-preview-container img {
    flex: 1 1 48%;
    width: 48%;
    height: 120px;
    object-fit: cover;
    border: 2px solid #00fff0;
    border-radius: 10px;
}

@media(max-width:500px){
    #previewPic,
    #previewFront,
    #previewBack {
        width: 90%;
        height: auto;
    }
    .cnic-preview-container img {
        flex: 1 1 100%;
        width: 100%;
        height: auto;
    }
}

/* ================= CONTACT ADVANCE DESIGN ================= */
#contact-section {
    position: relative;
    padding: 60px 20px;
    text-align: center;
    overflow: hidden;
}

#contact-section::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent, #00fff020, transparent);
    animation: slideBg 6s linear infinite;
}

@keyframes slideBg {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.contact-container {
    position: relative;
    z-index: 1;
    border-radius: 20px;
    padding: 35px;
    background: rgba(255,255,255,0.05);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(0,255,240,0.3);
    transition: 0.4s;
}

.contact-container::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(45deg,#00fff0,#ff0080,#00fff0);
    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.contact-container:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 0 35px rgba(0,255,240,0.5);
}

/* GLOBAL SCROLLBAR */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #111;
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(#00fff0,#ff0080);
    border-radius: 10px;
}
/* ================= MOBILE TEXT FIX ================= */
@media (max-width: 768px) {

    /* HEADER FIX */
    .header-container {
        padding: 15px 10px;
        text-align: center;
    }

    .header-left {
        flex-direction: column;
        gap: 10px;
    }

    .header-logo {
        height: 120px;
    }

    .header-text {
        font-size: 22px;
        text-align: center;
    }

    .header-texts h1 {
        font-size: 23px;
        text-align: center;
    }

    .header-texts p {
        font-size: 15px;
        text-align: center;
        letter-spacing: 0.5px;
    }

    /* HERO TEXT FIX */
    .hero h1 {
        font-size: 31px;
        line-height: 1.3;
    }

    /* BODY TEXT GLOBAL */
    body {
        font-size: 18px;
    }

    /* SECTION TITLES */
    .section-title {
        font-size: 28px;
    }

    .section-subtitle {
        font-size: 12px;
    }

    /* CARD TEXT */
    .member-name {
        font-size: 18px;
    }

    .member-info {
        font-size: 13px;
    }
}
.customModal{
    position:fixed;
    top:0;left:0;
    width:100%;
    height:100%;
    background:rgba(0,0,0,0.75);
    display:flex;
    align-items:center;
    justify-content:center;
    z-index:9999;
}

.customModal .box{
    background:#111;
    padding:20px;
    width:320px;
    border-radius:12px;
    text-align:center;
    box-shadow:0 0 20px #00fff0;
}

.customModal input{
    width:100%;
    margin:8px 0;
    padding:10px;
    border:1px solid #00fff0;
    background:#000;
    color:#fff;
    border-radius:6px;
}

.customModal button{
    width:100%;
    margin-top:10px;
    padding:10px;
    border:none;
    cursor:pointer;
    font-weight:bold;
}

.customModal .danger{
    background:red;
    color:#fff;
}

.glow{
    box-shadow:0 0 25px #00fff0;
}
.unique-save-btn {
    background: linear-gradient(45deg, #00ff99, #00ccff);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    color: black;
    font-weight: bold;
    cursor: pointer;
    margin-right: 10px;
}

.unique-cancel-btn {
    background: linear-gradient(45deg, #ff4d4d, #ff0000);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    color: white;
    font-weight: bold;
    cursor: pointer;
}
/* ================= ANIMATION ================= */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}