/* Reset some default styles */
body, h1, h2, h3, p {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

header {
    background: #333;
    color: #fff;
    padding: 1rem 0;
}

header .container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    margin: 0;
}

nav ul {
    list-style: none;
    display: flex;
}

nav ul li {
    margin-left: 1rem;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
}

nav ul li a:hover {
    text-decoration: underline;
}

main {
    padding: 2rem 0;
    flex: 1;
}

.hero {
    background: #f4f4f4;
    padding: 2rem;
    text-align: center;
    position: relative;
}

.hero-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    margin-bottom: 1rem;
}

.hero h2 {
    margin-bottom: 1rem;
}

.cta-button {
    display: inline-block;
    padding: 0.5rem 1rem;
    margin: 0.5rem;
    color: #fff;
    background: #007BFF;
    text-decoration: none;
    border-radius: 5px;
}

.cta-button:hover {
    background: #0056b3;
}

.about, .departments, .our-team {
    padding: 2rem 0;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Grid Layout for Departments */
.department-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 columns */
    gap: 1rem;
}

.department-item {
    border: 3px solid #007BFF; /* Border around each box */
    box-shadow: 0 0 9px rgba(0, 0, 0, 0.9);
    border-radius: 3px;
    overflow: visible;
    text-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
    height: 280px; /* Fixed height for consistency */
}

.department-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.department-info {
    background: #007BFF;
    color: #fff;
    padding: 0.5rem;
    width: 100%;
    flex: 6; /* Allow the text container to grow */
    display: flex;
    flex-direction: column;
    justify-content: center; /* Center content vertically */
    box-sizing: border-box;
}

.department-info h3 {
    margin: 0;
    font-size: 1.2rem;
}

.department-info p {
    margin: 0;
    font-size: 0.9rem;
}

.our-team {
    padding: 2rem 0;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.team-member {
    border: 3px solid #007BFF;
    box-shadow: 0 0 9px rgba(0, 0, 0, 0.9);
    border-radius: 3px;
    overflow: visible;
    text-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
    height: 350px;
}

.team-image {
    width: 100%;
    height: 67%; /* Adjust height for team member images */
    object-fit: cover;
}

.team-info {
    background: #007BFF;
    color: #fff;
    padding: 1.7rem;
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: center; /* Center content vertically */
    box-sizing: border-box;
}

.team-info h3 {
    margin: 0;
    font-size: 1.2rem;
}

.team-info p {
    margin: 0;
    font-size: 0.9rem;
}

.discord-button {
    display: inline-block;
    padding: 0.5rem 1rem;
    color: #fff;
    background: #007BFF;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1rem;
    text-align: center;
    transition: background 0.3s, border-color 0.3s;
}

.discord-button:hover {
    background: #0056b3;
}

footer {
    background: #333;
    color: #fff;
    text-align: center;
    padding: 1rem 0;
    margin-top: auto;
}