:root {
    --primary-color: #1e3799;
    --secondary-color: #0c2461;
    --accent-color: #4a69bd;
    --text-color: #2f3640;
    --light-gray: #f5f6fa;
    --success-color: #44bd32;
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

body {
    line-height: 1.6;
    color: var(--text-color);
}

.hero {
    background-image: url('../resourcesnew/Book cover banners/IT cover Banner.jpg');
    /* background-image: linear-gradient(rgba(30, 55, 153, 0.8), rgba(12, 36, 97, 0.9)), url('../resources/Life-Science-cover-Banner.jpg'); */
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    color: white;
    padding: 2rem;
    animation: fadeIn 1s ease-out;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* background: linear-gradient(135deg, rgba(30, 55, 153, 0.8), rgba(12, 36, 97, 0.8)); */
    z-index: 1;
}

.hero-container {
    display: flex;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto 0 0;
    gap: 2rem;
    position: relative;
    z-index: 2;
}

/* .journal-cover {
    background: linear-gradient(45deg, var(--accent-color), var(--primary-color));
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    transform: rotate(-3deg);
    transition: var(--transition);
} */

.journal-cover:hover {
    transform: rotate(0deg) scale(1.02);
}

.journal-cover img {
    width: 280px;
    /* height: 320px; */
    object-fit: cover;
}

.journal-info {
    flex: 1;
}

.journal-info h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.metrics {
    display: flex;
    gap: 10px;
    padding-top: 1rem;
}

.metric-card {
    width: 100px;
    height: 100px;
    perspective: 1000px;
    cursor: pointer;
}

.metric-card .front,
.metric-card .back {
    width: 100%;
    height: 100%;
    position: absolute;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 14px;
    font-weight: bold;
    color: #0c2461;
    border-radius: 10px;
    border: 2px solid whitesmoke;
    transition: transform 0.6s;
}

.metric-card .front {
    background: #F1F1F2;
}

.metric-card .back {
    background: rgb(232, 226, 226);
    transform: rotateY(180deg);
    font-size: 22px;
}

.metric-card.flipped .front {
    transform: rotateY(180deg);
}

.metric-card.flipped .back {
    transform: rotateY(0);
}

@media (max-width: 768px) {
    .hero-container {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .journal-cover {
        width: 200px;
        height: 280px;
        margin-bottom: 1rem;
    }

    .journal-info h1 {
        font-size: 2rem;
    }

    .journal-cover img {
        width: 280px;
        height: 320px;
    }

    .metrics {
        justify-content: center;
        flex-wrap: wrap;
    }

    .metric-card {
        width: 80px;
        height: 80px;
        margin: 0.5rem;
    }
}

@media (max-width: 480px) {
    .hero-container {
        padding: 1rem;
    }

    .journal-cover {
        width: 160px;
        height: 240px;
    }

    .journal-info h1 {
        font-size: 1.5rem;
    }

    .journal-info h3 {
        font-size: 0.9rem;
    }

    .journal-info p {
        font-size: 0.8rem;
    }

    .journal-cover img {
        width: 280px;
        height: 300px;
    }

    .metric-card {
        width: 70px;
        height: 70px;
        margin: 0.3rem;
    }

    .metric-card .front,
    .metric-card .back {
        font-size: 12px;
    }
}

.top-header {
    background: #fff;
    padding: 0.2rem 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.logo {
    font-size: auto;
    font-weight: 800;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: auto;
    font-size: 25px;
}

.logo img {
    height: 60px;
    width: auto;
    border-radius: 10px;
}

.top-nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.top-nav a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.top-nav a:hover {
    background: var(--light-gray);
    color: var(--primary-color);
}

.dropdown {
    position: relative;
    display: inline-block;
    border-right: 1px solid gray;
    padding-right: 2rem;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: white;
    min-width: 200px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-radius: var(--border-radius);
    padding: 0.5rem 0;
    z-index: 1;
}

.dropdown:hover .dropdown-content {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.dropdown-content a {
    display: block;
    padding: 0.75rem 1rem;
}

.body-nav {
    background: var(--background-color);
    padding: 1rem 2rem;
    display: flex;
    gap: 2rem;
    align-items: center;
    font-family: Arial, sans-serif;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.body-nav a {
    color: var(--text-color);
    text-decoration: none;
    padding: 0.5rem 0;
    position: relative;
    font-weight: bold;
    font-size: 1rem;
    transition: color var(--transition);
}

.body-nav a:hover {
    color: var(--accent-color);
}

.dropdown2 {
    position: relative;
}

.dropdown-content2 {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: rgb(247, 249, 252);
    padding: 0.5rem 0;
    z-index: 1002;
    min-width: 200px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.dropdown2:hover .dropdown-content2 {
    display: block;
}

.dropdown-content2 a {
    display: block;
    padding: 0.75rem 1.5rem;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: normal;
    transition: background 0.2s, color 0.2s;
}

.dropdown-content2 a:hover {
    background: var(--accent-color);
    color: white;
}

@media (max-width: 768px) {
    .body-nav {
        padding: 1rem;
        gap: 1.5rem;
        justify-content: flex-start;
    }

    .dropdown2 {
        width: 100%;
    }

    .dropdown-content2 {
        position: relative;
        width: 100%;
        min-width: unset;
        background: rgb(247, 249, 252);
        border-radius: 4px;
        margin-top: 0.5rem;
        box-shadow: none;
    }

    .dropdown-content2 a {
        padding: 0.75rem 1.5rem;
        border-left: 3px solid transparent;
        text-align: left;
    }

    .dropdown-content2 a:hover {
        border-left: 3px solid var(--accent-color);
        background: white;
        color: var(--accent-color);
    }
}

@media (max-width: 576px) {
    .body-nav {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 1rem;
        padding-left: 1rem;
    }

    .dropdown2 {
        width: 100%;
    }

    .dropdown2 > a {
        display: block;
        width: 100%;
        text-align: left;
    }

    .dropdown-content2 {
        width: 100%;
        box-shadow: none;
    }

    .dropdown-content2 a {
        padding: 0.75rem 1.5rem;
        text-align: left;
    }
}

.main-nav {
    position: relative;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-color);
    padding: 0.5rem;
    position: relative;
    z-index: 1001;
    font-weight: bold;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    list-style: none;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 1rem;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    font-weight: bold;
}

.nav-links .dropdown-content {
    display: none;
    position: absolute;
    background: white;
    padding: 0.5rem 0;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-radius: var(--border-radius);
    z-index: 1002;
    list-style: none;
    min-width: 200px;
}

.nav-links .dropdown-content a {
    font-weight: bold;
}

.nav-links .dropdown:hover .dropdown-content {
    display: block;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
    }

    .nav-links {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        background: white;
        margin-top: 1.5rem;
        padding: 1rem;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        z-index: 1000;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    }

    .nav-links.show {
        display: flex;
    }

    .nav-links .dropdown-content {
        position: static;
        box-shadow: none;
        display: none;
        padding: 0;
        margin-top: 0.5rem;
    }

    .nav-links .dropdown.active .dropdown-content {
        display: block;
    }

    .nav-links a {
        padding: 0.75rem 1rem;
        display: block;
        border: none;
    }

    .nav-links > li {
        border: none;
    }
}

.about-section {
    padding: 2rem 2rem;
    background: var(--light-gray);
}

.about-section h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
}

.stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    flex-wrap: wrap;
}

.stat-item {
    flex: 1 1 calc(25% - 2rem);
    text-align: center;
    padding: 1.5rem;
    border-right: 1px solid #eee;
    transition: var(--transition);
}

.stat-item:last-child {
    border: none;
}

@media (max-width: 1200px) {
    .stat-item {
        flex: 1 1 calc(33.33% - 2rem);
    }
}

@media (max-width: 900px) {
    .stat-item {
        flex: 1 1 calc(50% - 2rem);
    }
}

@media (max-width: 600px) {
    .stats {
        flex-direction: column;
        gap: 1.5rem;
    }

    .stat-item {
        flex: 1 1 100%;
        border-right: none;
    }
}
.stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.95rem;
    color: #666;
}

.editor-section {
    padding: 0.5rem 2rem;
    background: linear-gradient(rgb(236, 228, 228), white);
    color: rgb(4, 30, 86);
}

.editor-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-top: 1rem;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem;
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.editor-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.15);
}

.editor-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--accent-color);
    border: 4px solid rgba(255, 255, 255, 0.2);
}

.row {
    margin: 0;
}

.loader {
    display: none;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 1rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.scroll-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--primary-color);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.scroll-to-top.visible {
    opacity: 1;
}

.view-more-btn {
    margin-top: 1rem;
    padding: 0.5rem 1rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
}

.view-more-btn:hover {
    background: var(--accent-color);
}

.about-popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    width: 60%;
    max-width: 600px;
    overflow-y: auto;
    max-height: 90vh;
}

.popup-content {
    position: relative;
    font-size: 1rem;
    line-height: 1.5;
}

.close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 1.5rem;
    color: #888;
    cursor: pointer;
}

.close-btn:hover {
    color: #1e3799;
}

#aboutPopup.show {
    display: block;
}

.popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.popup-overlay.show {
    display: block;
}

@media (max-width: 768px) {
    .about-popup {
        width: 80%;
        padding: 1.5rem;
    }

    .popup-content {
        font-size: 0.9rem;
    }

    .close-btn {
        font-size: 1.25rem;
    }
}

@media (max-width: 576px) {
    .about-popup {
        width: 90%;
        padding: 1rem;
    }

    .popup-content {
        font-size: 0.85rem;
    }
}

.footer {
    /* background: #1e3799; */
    background-image: url('../resources/Footer\ Update_final.jpg');
    color: white;
    padding-top: 20px; 
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 0.75rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease, padding-left 0.3s ease;
}

.footer-section a:hover {
    color: white;
    padding-left: 5px;
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
}

.copyright-section {
    background-color: #0c2461;
    padding: 20px 0;
    margin: 0;
}

.copyright-section p {
    margin: 0;
    font-size: 14px;
    color: #a8b2d1;
}

.copyright-section a {
    color: #a8b2d1;
    text-decoration: none;
    transition: color 0.3s ease;
}

.copyright-section a:hover {
    color: white;
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-section h3 {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-section h3 {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    .footer-section ul li {
        margin-bottom: 0.5rem;
    }
}

.editor-section {
    padding: 2rem 2rem;
    background: linear-gradient(rgb(236, 228, 228), white);
    color: rgb(4, 30, 86);
}


.editor-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--accent-color);
    border: 4px solid rgba(255, 255, 255, 0.2);
}