/* user-forms.css — User form, post editor form, settings form styles */

/* ── User Form ────────────────────────────────────────────── */

/* Dark card wrapper used by user create/edit form */
.form-wrap {
    max-width: 520px;
    margin: 3rem auto;
    background: #252526;
    border: 1px solid #3c3c3c;
    border-radius: 6px;
    padding: 2rem;
}

.form-wrap h1 {
    color: #d4d4d4;
    font-size: 1.2rem;
    margin: 0 0 1.5rem;
    border-bottom: 1px solid #3c3c3c;
    padding-bottom: 0.75rem;
}

/* Small helper / hint text below an input */
.form-hint {
    font-size: 0.75rem;
    color: #858585;
    margin-top: 0.2rem;
}

/* Row of action buttons at the bottom of a form */
.form-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

/* ── Post Editor Form (SkylarkCMS va-cont / Foundation Grid layout) ── */
.va-cont {
    display: block;
    width: 100%;
}

.va-inn {
    display: block;
    width: 100%;
    padding: 1rem;
}

.form-heading {
    color: #d4d4d4;
    margin-top: 0;
    margin-bottom: 1.2em;
    text-align: center;
    font-size: 1.1rem;
}

.form-row {
    position: relative;
    margin-top: 1.2rem;
}

.form-label {
    display: block;
    color: #9cdcfe;
    font-size: 0.82rem;
    margin-bottom: 0.3rem;
}

.form-textbox {
    width: 100%;
    box-sizing: border-box;
    padding: 0.45rem 0.6rem;
    background: #2d2d2d;
    border: 1px solid #555;
    border-radius: 3px;
    color: #d4d4d4;
    font-size: 0.9rem;
}

.form-textbox:focus {
    outline: none;
    border-color: #569cd6;
}

select.form-textbox option {
    background: #3c3c3c;
}

/* Mode toggle buttons bar */
#viewerBtn, #wysiwygBtn, #markdownBtn {
    margin: 0.5rem 0.25rem 0.5rem 0;
}

/* editor-container full width in Foundation grid */
#editor-container,
#viewer-container {
    width: 100%;
}

/* ── Roles sub-tabs ──────────────────────────────────────────────────────────── */
.roles-subtabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid #3c3c3c;
    margin-bottom: 16px;
}
.roles-subtab {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 10px 20px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    color: #858585;
    transition: color 0.15s, border-color 0.15s;
}
.roles-subtab:hover { color: #d4d4d4; }
.roles-subtab.active { color: #9cdcfe; border-bottom-color: #569cd6; }
.roles-subtab-label { font-size: 0.9rem; font-weight: 500; }
.roles-subtab-hint { font-size: 0.72rem; color: #666; margin-top: 2px; }
.roles-subtab.active .roles-subtab-hint { color: #888; }
.roles-pane-desc {
    margin: 4px 0 12px;
    color: #858585;
    font-size: 0.82rem;
    max-width: 600px;
    line-height: 1.5;
}

/* ── AI Providers — connection test result blocks ── */
.result-pre {
    background: #2d2d2d;
    color: #d4d4d4;
    padding: 12px;
    border-radius: 4px;
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 400px;
    overflow-y: auto;
}

.result-pre-sm {
    background: #252526;
    color: #858585;
    padding: 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 300px;
    overflow-y: auto;
}

details summary {
    cursor: pointer;
    color: #858585;
    font-size: 13px;
}

/* ── View detail page ─────────────────────────────────────── */
.view-wrap {
    max-width: 560px;
    margin: 3rem auto;
    background: #252526;
    border: 1px solid #3c3c3c;
    border-radius: 6px;
    padding: 2rem;
}

.view-wrap h1 {
    color: #d4d4d4;
    font-size: 1.2rem;
    margin: 0 0 1.5rem;
    border-bottom: 1px solid #3c3c3c;
    padding-bottom: 0.75rem;
}

.view-row {
    display: flex;
    padding: 0.6rem 0;
    border-bottom: 1px solid #2d2d2d;
    font-size: 0.9rem;
}

.view-row:last-of-type {
    border-bottom: none;
}
