/* Formatting Toolbar Styles - Enhanced UI */

/* Toolbar Container */
.toolbar-container {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 0.5rem;
    padding: 0.5rem;
    max-width: 900px;
    width: 100%;
    margin: 1rem auto 0;
}

/* Toolbar Buttons - Improved */
.toolbar-btn {
    padding: 0.5rem;
    border-radius: 0.375rem;
    background: transparent;
    border: 1px solid transparent;
    color: #94a3b8;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 2rem;
    min-height: 2rem;
}

.toolbar-btn:hover {
    background: rgba(148, 163, 184, 0.15);
    border-color: rgba(148, 163, 184, 0.25);
    color: #e2e8f0;
    transform: translateY(-1px);
}

.toolbar-btn:active,
.toolbar-btn.active {
    background: rgba(148, 163, 184, 0.2);
    color: #f1f5f9;
    transform: translateY(0);
}

/* Toolbar Select - Enhanced */
.toolbar-select {
    cursor: pointer;
    outline: none;
    font-size: 0.8125rem;
    font-weight: 500;
    min-width: 110px;
    padding: 0.375rem 0.75rem;
    padding-right: 2rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(100, 116, 139, 0.3);
    color: #cbd5e1;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.25rem;
}

.toolbar-select:hover {
    background-color: rgba(51, 65, 85, 0.6);
    border-color: rgba(148, 163, 184, 0.4);
}

.toolbar-select:focus {
    outline: 2px solid rgba(94, 252, 232, 0.4);
    outline-offset: 2px;
    background-color: rgba(51, 65, 85, 0.7);
    border-color: rgba(94, 252, 232, 0.5);
}

/* Dividers - Subtle */
.toolbar-divider {
    width: 1px;
    height: 1.25rem;
    background: rgba(148, 163, 184, 0.2);
    margin: 0 0.25rem;
}

/* Character Count & Status - Refined */
#toolbarCharCount,
#checkStatus {
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.01em;
}

#checkStatus {
    color: #64748b;
}

/* Light Mode Toolbar - Enhanced */
body[data-theme="light"] .toolbar-container {
    background: rgba(241, 245, 249, 0.6);
    border-color: rgba(203, 213, 225, 0.5);
}

body[data-theme="light"] .toolbar-btn {
    color: #64748b;
}

body[data-theme="light"] .toolbar-btn:hover {
    background: rgba(100, 116, 139, 0.12);
    border-color: rgba(100, 116, 139, 0.2);
    color: #334155;
}

body[data-theme="light"] .toolbar-btn:active,
body[data-theme="light"] .toolbar-btn.active {
    background: rgba(100, 116, 139, 0.18);
    color: #0f172a;
}

body[data-theme="light"] .toolbar-select {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(203, 213, 225, 0.6);
    color: #475569;
}

body[data-theme="light"] .toolbar-select:hover {
    background: rgba(255, 255, 255, 1);
    border-color: rgba(148, 163, 184, 0.5);
}

body[data-theme="light"] .toolbar-select:focus {
    outline-color: rgba(6, 182, 212, 0.4);
    background: rgba(255, 255, 255, 1);
}

body[data-theme="light"] .toolbar-divider {
    background: rgba(100, 116, 139, 0.2);
}

body[data-theme="light"] #checkStatus {
    color: #94a3b8;
}

body[data-theme="light"] #toolbarCharCount {
    color: #64748b;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .toolbar-btn {
        padding: 0.375rem;
        min-width: 1.75rem;
        min-height: 1.75rem;
    }

    .toolbar-select {
        min-width: 80px;
        font-size: 0.75rem;
    }
}