/* General Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    color: #333;
    line-height: 1.6;
    background: #fff;
    transition: all 0.3s ease;
}

/* Top Bar */
.top-bar {
    background: #e6e6e6;
    padding: 5px 20px;
    text-align: right;
    font-size: 12px;
}

.top-bar-content a {
    color: #003087;
    text-decoration: none;
    margin: 0 5px;
}

.top-bar-content span {
    margin: 0 5px;
}

#screen-reader, #font-decrease, #font-reset, #font-increase, #contrast {
    cursor: pointer;
    color: #003087;
}

#screen-reader:hover, #font-decrease:hover, #font-reset:hover, #font-increase:hover, #contrast:hover {
    text-decoration: underline;
}

/* High Contrast Mode */
body.high-contrast {
    background: #000;
    color: #fff;
}

body.high-contrast a {
    color: #00f;
}

body.high-contrast .top-bar {
    background: #333;
}

body.high-contrast .main-nav {
    background: linear-gradient(to bottom, #444, #111);
}

body.high-contrast .members {
    background: #222;
}

body.high-contrast .member h3 {
    color: #fff;
}

body.high-contrast .member p {
    color: #ccc;
}

body.high-contrast .card {
    background: #333;
    border-color: #555;
}

body.high-contrast .card h3 {
    color: #fff;
}

body.high-contrast .announcements-list {
    background: #333;
}

body.high-contrast .announcement-item p {
    color: #fff;
}

body.high-contrast .announcement-item small {
    color: #ccc;
}

body.high-contrast .sidebar {
    background: #444;
}

body.high-contrast .sidebar h3 {
    color: #fff;
}

body.high-contrast footer {
    background: #111;
}

body.high-contrast .portfolio {
    background: #222;
}

body.high-contrast .portfolio-item .hover-content h1 {
    color: #fff;
}

body.high-contrast .portfolio-item .hover-content a {
    background: #00f;
    color: #fff;
}

/* Header */
header {
    background: #fff;
    border-bottom: 2px solid #f47920;
    padding: 10px 20px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-section {
    display: flex;
    align-items: center;
}

.logo-image {
    max-width: 80px; /* Default size for mobile */
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain; /* Maintains aspect ratio */
    margin-right: 15px;
}

.title h1 {
    font-size: 20px;
    color: #003087;
}

.title p {
    font-size: 14px;
    color: #666;
}

/* Navigation */
.main-nav {
    width: 100%;
    background: linear-gradient(to bottom, #87CEEB, #003087);
    padding: 10px 20px;
}

.main-nav .hamburger {
    display: block;
    font-size: 24px;
    background: none;
    border: none;
    cursor: pointer;
    color: #fff;
}

.main-nav .menu {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
}

.main-nav .menu li {
    position: relative;
    display: block;
    margin: 0;
}

.main-nav .menu a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    padding: 10px 15px;
    display: block;
}

.main-nav .menu li .dropdown {
    display: none;
    position: absolute;
    background: #003087;
    list-style: none;
    padding: 0;
    width: 200px;
    z-index: 3;
}

.main-nav .menu li .dropdown li {
    margin: 0;
}

.main-nav .menu li .dropdown a {
    padding: 8px 15px;
    color: #fff;
}

.main-nav .menu li:hover .dropdown {
    display: block;
}

/* Members Section */
.members {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: center;
    background: #f5f6f5;
}

.member {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.member-image {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #003087;
}

/* Main Content */
.main-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 20px;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.card {
    background: #f5f6f5;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.card h3 {
    color: #003087;
    margin-bottom: 10px;
    font-size: 18px;
}

.announcements-card {
    display: flex;
    flex-direction: column;
}

.announcements-list {
    max-height: 200px; /* Fixed height for scrollable area */
    overflow-y: auto; /* Enable vertical scrolling */
    padding: 10px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.announcement-item {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.announcement-item:last-child {
    border-bottom: none; /* Remove border from last item */
}

.announcement-item p {
    margin: 0 0 5px;
    font-size: 14px;
}

.announcement-item small {
    color: #666;
    font-size: 12px;
}

.sidebar {
    background: #e6e6e6;
    padding: 15px;
    border-radius: 5px;
}

.sidebar h3 {
    color: #003087;
    margin-bottom: 10px;
    font-size: 18px;
}

.sidebar ul {
    list-style: none;
}

.sidebar a {
    color: #003087;
    text-decoration: none;
    display: block;
    margin: 5px 0;
}

/* Portfolio Section */
.portfolio {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: #f5f6f5;
}

.portfolio-item {
    position: relative;
    width: 100%;
    max-width: 400px; /* Limits width on larger screens */
    margin: 0 auto; /* Centers on mobile */
}

.thumb {
    position: relative;
    overflow: hidden;
    border-radius: 5px;
}

.image img {
    width: 100%;
    height: auto;
    display: block;
}

.hover-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7); /* Semi-transparent overlay */
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

.portfolio-item:hover .hover-effect {
    opacity: 1;
}

.hover-content {
    text-align: center;
    color: #fff;
}

.hover-content h1 {
    font-size: 18px;
    margin: 5px 0;
    color: #fff;
}

.portfolio-btn {
    display: inline-block;
    padding: 10px 20px;
    background: #003087;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 10px;
    transition: background 0.3s ease;
}

.portfolio-btn:hover {
    background: #f47920; /* Orange on hover, matching theme */
}

/* Footer */
footer {
    background: #003087;
    color: #fff;
    padding: 20px;
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.footer-column h4 {
    margin-bottom: 10px;
    font-size: 16px;
}

.footer-column a {
    color: #fff;
    text-decoration: none;
}

.footer-bottom {
    text-align: center;
    margin-top: 20px;
    font-size: 12px;
}

/* Responsive Design - Laptop */
@media (min-width: 768px) {
    .top-bar {
        font-size: 14px;
    }

    .header-content {
        padding: 0 40px;
    }

    .logo-image {
        max-width: 100px; /* Larger logo for desktop */
        max-height: 100px;
    }

    .title h1 {
        font-size: 28px;
    }

    .main-nav {
        padding: 0 40px;
    }

    .main-nav .hamburger {
        display: none;
    }

    .main-nav .menu {
        display: flex;
        justify-content: space-around;
    }

    .main-nav .menu li {
        flex: 1;
        text-align: center;
    }

    .main-nav .menu li .dropdown {
        top: 100%;
        left: 0;
        width: 100%;
    }

    .members {
        flex-direction: row;
        justify-content: space-around;
        padding: 40px;
    }

    .main-content {
        flex-direction: row;
        padding: 40px;
        margin-top: 40px;
    }

    .content-grid {
        grid-template-columns: repeat(3, 1fr);
        flex: 3;
    }

    .sidebar {
        flex: 1;
    }

    .portfolio {
        flex-direction: row;
        justify-content: center;
        padding: 40px;
        gap: 40px;
    }

    .portfolio-item {
        max-width: 350px; /* Slightly smaller on desktop for spacing */
    }

    .footer-content {
        flex-direction: row;
        justify-content: space-between;
        padding: 0 40px;
    }
}