/* Feedback form and admin list — namespaced (.fb-*) to avoid clashing with other modules. */
.fb-form {
    display: grid;
    gap: .35rem;
    max-width: 640px;
}

.fb-field {
    display: grid;
    gap: .3rem;
    margin-bottom: .75rem;
}

.fb-field > label {
    font-weight: 600;
}

.fb-required {
    color: #ef4444;
    font-size: .8rem;
    font-weight: 500;
    margin-inline-start: .25rem;
}

.fb-admin input,
.fb-form input,
.fb-form select,
.fb-form textarea {
    width: 100%;
    padding: .6rem .75rem;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font: inherit;
    background: #fff;
    color: #111827;
    box-sizing: border-box;
}

.fb-form textarea {
    resize: vertical;
    min-height: 130px;
}

.fb-form input:focus,
.fb-form select:focus,
.fb-form textarea:focus {
    outline: 2px solid #ef4444;
    outline-offset: 1px;
    border-color: #ef4444;
}

.fb-form .fb-invalid {
    border-color: #ef4444;
    background: #fef2f2;
}

.fb-hint {
    margin: 0;
    font-size: .85rem;
    color: #6b7280;
}

.fb-field-error {
    margin: 0;
    font-size: .85rem;
    color: #b91c1c;
}

.fb-actions {
    margin-top: .5rem;
    display: flex;
    gap: .75rem;
    align-items: center;
}

.fb-status {
    margin-top: 1rem;
    font-weight: 600;
}

.fb-status.is-error {
    color: #b91c1c;
}

.fb-status.is-ok {
    color: #15803d;
}

/* Public feedback forms */
.fb-required-hint {
    max-width: 640px;
    margin-bottom: 1.4rem;
}

.fb-pair {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.fb-field {
    min-width: 0;
}

.fb-field > label {
    font-size: .88rem;
}

.fb-form select {
    min-width: 0;
    padding-inline-end: 2.2rem;
    text-overflow: ellipsis;
}

.fb-field-error:empty,
.fb-status:empty {
    display: none;
}

.fb-form .fb-hint {
    font-size: .78rem;
    line-height: 1.65;
}

.fb-actions .btn:disabled {
    cursor: wait;
    opacity: .6;
    box-shadow: none;
}

.fb-home-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.8fr);
    gap: clamp(2rem, 4vw, 4rem);
    margin-top: 2rem;
    scroll-margin-top: 12rem;
}

.fb-home-intro,
.fb-home-form-panel {
    min-width: 0;
}

.fb-home-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 1.3rem;
    border-radius: 14px;
    background: var(--primary-soft);
    color: var(--primary-hover);
    font-size: 1.5rem;
}

.fb-home-intro h2 {
    margin-bottom: .8rem;
    font-size: 1.5rem;
}

.fb-home-intro .tool-intro {
    margin-bottom: 1rem;
}

.fb-home-intro .fb-required-hint {
    margin: 0;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.fb-home-form-panel .fb-form {
    width: 100%;
    max-width: none;
}

@media (max-width: 800px) {
    .fb-home-section {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.6rem;
    }

    .fb-home-icon {
        width: 42px;
        height: 42px;
        margin-bottom: .8rem;
        border-radius: 11px;
        font-size: 1.2rem;
    }

    .fb-home-intro .fb-required-hint {
        padding-top: 0;
        border-top: 0;
    }
}

@media (max-width: 520px) {
    .fb-pair {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }

    .fb-home-section .fb-actions .btn {
        width: 100%;
    }
}

/* Admin list */
.fb-admin {
    max-width: 1000px;
}

.fb-admin-head {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.fb-admin-head h2 {
    margin-bottom: 0;
}

.fb-admin-head .fb-actions {
    margin-top: 0;
}

.fb-admin-list {
    margin-top: 1rem;
    display: grid;
    gap: .75rem;
}

.fb-admin-item {
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: .85rem 1rem;
    background: #fff;
}

.fb-admin-meta {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem .75rem;
    font-size: .85rem;
    color: #4b5563;
    margin-bottom: .35rem;
}

.fb-admin-message {
    margin: 0;
    white-space: pre-wrap;
    color: #111827;
}

.fb-badge {
    display: inline-block;
    padding: .1rem .55rem;
    border-radius: 999px;
    background: #fee2e2;
    color: #b91c1c;
    font-size: .75rem;
    font-weight: 600;
}

.fb-empty {
    margin-top: 1rem;
    color: #6b7280;
}
