/* YAML Kontrol Aracı stilleri */

.yml-tool {
    display: grid;
    gap: 2rem;
}

.yml-tool__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.yml-panel {
    padding: 1.5rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-medium);
}

.yml-panel__title {
    font-size: 1.1rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-border);
}

.yml-disclaimer {
    padding: 0.85rem 1rem;
    margin-bottom: 1.25rem;
    font-size: 0.875rem;
    color: var(--color-text-muted);
    background: var(--color-surface-secondary);
    border: 1px solid var(--color-border);
    border-left: 3px solid var(--color-warning);
    border-radius: var(--border-radius-small);
}

.yml-editor-wrap {
    margin-bottom: 1rem;
}

.yml-editor {
    display: flex;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-small);
    background: var(--color-surface-secondary);
    overflow: hidden;
    min-height: 320px;
    max-height: 520px;
}

.yml-editor__gutter {
    flex-shrink: 0;
    width: 3rem;
    padding: 0.75rem 0.5rem;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.8rem;
    line-height: 1.5;
    text-align: right;
    color: var(--color-text-muted);
    background: var(--color-surface);
    border-right: 1px solid var(--color-border);
    overflow: hidden;
    user-select: none;
}

.yml-editor__gutter-line {
    height: 1.5em;
}

.yml-editor__gutter-line.is-highlight {
    color: var(--color-error);
    font-weight: 700;
}

.yml-editor__textarea {
    flex: 1;
    min-width: 0;
    min-height: 320px;
    max-height: 520px;
    padding: 0.75rem;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--color-text);
    background: transparent;
    border: none;
    resize: vertical;
    outline: none;
    tab-size: 2;
    white-space: pre;
    overflow: auto;
}

.yml-editor__textarea:focus {
    outline: none;
}

.yml-editor:focus-within {
    border-color: var(--color-primary);
}

.yml-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.yml-results-summary {
    padding: 0.85rem 1rem;
    margin-bottom: 1rem;
    border-radius: var(--border-radius-small);
    font-size: 0.9rem;
    font-weight: 600;
}

.yml-results-summary--ok {
    background: rgba(63, 185, 80, 0.12);
    border: 1px solid var(--color-success);
    color: var(--color-success);
}

.yml-results-summary--warn {
    background: rgba(210, 153, 34, 0.12);
    border: 1px solid var(--color-warning);
    color: var(--color-warning);
}

.yml-results-summary--error {
    background: rgba(248, 81, 73, 0.12);
    border: 1px solid var(--color-error);
    color: var(--color-error);
}

.yml-results-summary--idle {
    background: var(--color-surface-secondary);
    border: 1px solid var(--color-border);
    color: var(--color-text-muted);
    font-weight: 400;
}

.yml-results-counts {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
}

.yml-results-count {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.yml-results-count__badge {
    display: inline-block;
    min-width: 1.5rem;
    padding: 0.1rem 0.4rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-align: center;
    border-radius: 999px;
}

.yml-results-count--error .yml-results-count__badge {
    background: var(--color-error);
    color: #fff;
}

.yml-results-count--warning .yml-results-count__badge {
    background: var(--color-warning);
    color: #111;
}

.yml-results-count--info .yml-results-count__badge {
    background: var(--color-border);
    color: var(--color-text);
}

.yml-issue-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 420px;
    overflow-y: auto;
}

.yml-issue {
    padding: 0.65rem 0.75rem;
    font-size: 0.85rem;
    border-radius: var(--border-radius-small);
    border: 1px solid var(--color-border);
    background: var(--color-surface-secondary);
}

.yml-issue--error {
    border-left: 3px solid var(--color-error);
}

.yml-issue--warning {
    border-left: 3px solid var(--color-warning);
}

.yml-issue--info {
    border-left: 3px solid var(--color-border);
}

.yml-issue__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.yml-issue__line {
    color: var(--color-text-muted);
}

.yml-issue__level--error {
    color: var(--color-error);
}

.yml-issue__level--warning {
    color: var(--color-warning);
}

.yml-issue__level--info {
    color: var(--color-text-muted);
}

.yml-issue__message {
    margin: 0;
    line-height: 1.45;
}

.yml-results-empty {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin: 0;
}

.yml-info {
    margin-top: 2rem;
}

.yml-info h2 {
    font-size: 1.35rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}

.yml-info h3 {
    font-size: 1.1rem;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.yml-code-example {
    padding: 1rem;
    background: var(--color-surface-secondary);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-small);
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.85rem;
    overflow-x: auto;
    margin-bottom: 1rem;
}

@media (max-width: 900px) {
    .yml-tool__grid {
        grid-template-columns: 1fr;
    }

    .yml-editor {
        min-height: 260px;
    }

    .yml-editor__textarea {
        min-height: 260px;
    }
}
