* {
    box-sizing: border-box;
    margin: 0;
}

main {
    max-width: 1400px;
    width: 90%;
    margin: 50px auto 50px auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

h2 {
    text-align: center;
    font-size: 50px;
    background: linear-gradient(to bottom, #4d6799, #31466b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    margin: 0 0 50px 0;
    user-select: none;
}

h3 {
    text-align: left;
    width: 100%;
    font-size: 35px;
    background: linear-gradient(to bottom, #f5daa4, #dec184);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    margin: 0 0 20px 0;
    user-select: none;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e5e0da;
    font-size: 25px;
    text-align: center;
    margin-bottom: 20px;
}

table tr {
    padding: 20px;
}

table th {
    padding: 20px;
    background: #3B537F;
    color: #f5daa4;
    border-right: 2px solid #31466b;
}

table th:last-child {
    border-right: none;
}

table td {
    padding: 12px 20px;
    background: #fffbf7;
    color: #746d68;
    border-right: 1px solid #e5e0da;
    border-bottom: 1px solid #e5e0da;
}

table td:last-child {
    border-right: none;
}

table tr:last-child td {
    border-bottom: none;
}

table td strong {
    font-weight: bold;
    color: #4d6799;
}

table tr td:last-child {
    text-align: left;
    text-indent: 20px;
}

.link-container{
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px 30px ;
    margin-bottom: 50px;
}

.link-container:last-child{
    margin-bottom: 0;
}

.link-container > a{
    text-decoration: none;
    width: 100%;
    background-color: #fffbf7;
    border: 2px solid #ddd7d2;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    overflow: hidden;
    transition: border-color 0.3s ease, background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
    padding: 18px 25px;
    font-size: 25px;
    font-weight: bold;
    color: #3B537F;
    text-align: center;
    height: fit-content;
    margin: 0 0 auto 0;
}

.link-container > a:hover{
    color: #fffbf7;
    background-color: #3B537F;
    border-color: #3B537F;
    transform: translateY(-5px);
}
.subject-dropdown {
    background-color: #fffbf7;
    border: 2px solid #ddd7d2;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    overflow: hidden;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 10px;
}

.subject-dropdown.is-expanded {
    border-color: #dec184;
}

.subject-dropdown summary {
    padding: 18px 25px;
    font-size: 24px;
    font-weight: bold;
    background: linear-gradient(to bottom, #4d6799, #31466b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    user-select: none;
}

.subject-dropdown summary::-webkit-details-marker {
    display: none;
}

.subject-dropdown summary::after {
    content: '+';
    color: #dec184;
    font-size: 28px;
    line-height: 1;
    font-weight: normal;
    transition: transform 0.3s ease;
    position: absolute;
    right: 25px;
}

.subject-dropdown.is-expanded summary::after {
    content: '−';
}

.subject-list {
    margin: 0;
    padding: 0 25px;
    list-style-type: none;
    border-top: 1px solid transparent;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, opacity 0.3s ease-out, padding 0.3s ease-out;
}

.subject-dropdown.is-expanded .subject-list {
    max-height: 400px;
    opacity: 1;
    padding: 15px 25px 20px 25px;
    border-top: 1px solid #ddd7d2;
}

.subject-list li {
    color: #746d68;
    font-size: 22px;
    padding: 8px 0;
    position: relative;
    padding-left: 20px;
}

.subject-list li::before {
    content: "•";
    color: #dec184;
    font-size: 24px;
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    line-height: 1;
}

.subject-list li a {
    text-decoration: none;
    color: #3b537f;
    transition: color 0.3s ease-in-out;
}

.subject-list li a:hover {
    color: #5f80bc;
    transition: color 0.3s ease-in-out;
}


@media screen and (max-width: 1024px) {
    h2 {
        font-size: 40px;
    }
    h3 {
        font-size: 28px;
    }
    .staff-container {
        gap: 30px;
    }
    .subject-dropdown summary, .subject-dropdown summary::after, .link-container > a, table {
        font-size: 20px;
    }
    .subject-list li, .subject-list li::before {
        font-size: 18px;
    }
    table th, table td {
        padding: 12px;
    }
}

@media screen and (max-width: 768px) {
    .link-container{
        grid-template-columns: repeat(1, 1fr);
        gap: 10px
    }
    table tr td:last-child {
        text-indent: 0;
    }
}

@media screen and (max-width: 480px) {
    h2 {
        font-size: 32px;
    }
    h3 {
        font-size: 23px;
    }
    .subject-dropdown summary,.subject-dropdown summary::after, .subject-list li, .subject-list li::before, .link-container > a, table {
        font-size: 16px;
    }
    .subject-list li{
        padding-left: 15px;
    }
}
