.contrast-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 2px solid #ffffff;
    cursor: pointer;
    padding: 0;
    /* Diagonal split, top-left to bottom-right corner */
    background: linear-gradient(135deg, #f5c518 50%, #000000 50%);
    transition: 0.2s;
}

.contrast-btn:hover {
    border-color: #cccccc;
}

.contrast-btn:focus-visible {
    outline: 3px solid #2563eb;
    outline-offset: 2px;
}

/* Contrast mode is ON — button now previews normal mode colors */
.contrast-btn[aria-pressed="true"] {
    background: linear-gradient(135deg, #ffffff 50%, #2563eb 50%);
}

.top-wrapper {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.font-resize-widget {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    white-space: nowrap;
}

.font-btn {
    color:black;
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 6px;
    border: 2px solid #ffffff;
    background: #ffffff;
    font-weight: bold;
    font-size: 12px;
    line-height: 1;
    cursor: pointer;
    transition: 0.2s;
    flex-shrink: 0;
}

.font-btn:hover {
    border-color: #cccccc;
    background: #f5c518;
}

.font-btn:focus-visible {
    outline: 3px solid #2563eb;
    outline-offset: 2px;
}

@media (max-width: 767px) {
    .top-wrapper {
        justify-content: space-between;
        margin-top: 8px;
    }
}