/* Grammar Check Specific UI */

.hidden { display: none !important; }

.gf-workspace {
    max-width: 1200px !important;
}

.gf-dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: stretch;
}

/* Panels */
.gf-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 4px 15px var(--shadow);
}

.gf-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.gf-badge-success {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.gf-panel-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.gf-relative-body {
    position: relative;
}

.gf-textarea {
    flex-grow: 1;
    min-height: 400px;
    border: none;
    border-radius: 0;
    padding: 25px;
    resize: none;
    font-size: 1.05rem;
    line-height: 1.8;
}

.gf-textarea:focus {
    box-shadow: none;
    background: var(--bg-card);
}

/* Custom Output Box styling for highlighting */
.gf-output-box {
    background: var(--bg-input);
    overflow-y: auto;
}

/* Highlight corrected words in Green */
.gf-correction {
    background-color: rgba(16, 185, 129, 0.15);
    color: var(--success);
    border-bottom: 2px solid var(--success);
    border-radius: 3px;
    padding: 0 2px;
    transition: 0.3s;
    font-weight: 600;
}
.gf-correction:hover {
    background-color: var(--success);
    color: white;
}

.gf-panel-footer {
    display: flex;
    gap: 15px;
    padding: 20px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
}

/* Buttons */
.gf-generate-btn {
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.3);
}
.gf-generate-btn:hover {
    background: linear-gradient(135deg, var(--primary-dark), #2563eb);
}

.gf-btn-success {
    background: var(--success) !important;
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.25) !important;
}

/* Processing Overlay */
.gf-processing-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

[data-theme="dark"] .gf-processing-overlay {
    background: rgba(15, 23, 42, 0.8);
}

.gf-loader {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border);
    border-top-color: var(--success);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.gf-processing-overlay p {
    font-weight: 700;
    color: var(--success);
    font-size: 1.1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Responsiveness */
@media (max-width: 900px) {
    .gf-dashboard-grid {
        grid-template-columns: 1fr;
    }
    .gf-textarea {
        min-height: 250px;
    }
}
