.edu-account {
    position: relative;
    font-family: "Noto Sans TC", "Segoe UI", sans-serif;
    font-size: 14px;
    line-height: 1.4;
    color: #1f1f1f;
}

.edu-account--fixed {
    position: fixed;
    top: 12px;
    right: 12px;
    z-index: 10000;
}

.edu-account--nav {
    position: relative;
    flex-shrink: 0;
}

.edu-account-login,
.edu-account-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 6px 12px 6px 8px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    background: #fff;
    color: #1f1f1f;
    text-decoration: none;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08), 0 8px 24px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    font: inherit;
}

.edu-account-login:hover,
.edu-account-chip:hover,
.edu-account-chip[aria-expanded="true"] {
    background: #f8f9fa;
}

.edu-account-google-icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
    align-items: center;
    justify-content: center;
}

.edu-account-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    background: #e8eaed;
}

.edu-account-avatar--fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: #3c4043;
}

.edu-account-name {
    max-width: 9.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}

.edu-account-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 160px;
    padding: 6px;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.edu-account-menu a {
    display: block;
    padding: 8px 10px;
    border-radius: 8px;
    color: #1f1f1f;
    text-decoration: none;
}

.edu-account-menu a:hover {
    background: #f1f3f4;
}

.edu-account--nav .edu-account-menu {
    right: 0;
}

@media (max-width: 720px) {
    .edu-account-login {
        padding: 6px 8px;
    }
    .edu-account-name {
        max-width: 5.5rem;
    }
}

@media print {
    .edu-account {
        display: none !important;
    }
}
