/* Shared UI components used by admin and account pages. */

.admin-brand-mark {
display: grid;
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    padding: 6px;
    grid-template-columns: repeat(2, 1fr);
    gap: 3px;
    overflow: hidden;
    place-items: stretch;
    border: 1px solid #c7d9ed;
    border-radius: 12px;
    background: linear-gradient(145deg, #edf5ff, #dfeefc);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.admin-brand-mark i {
border-radius: 3px;
    background: var(--brand);
}

.admin-brand-mark i:nth-child(2) {
background: #65a2e5;
}

.admin-brand-mark i:nth-child(3) {
background: #86b8ea;
}

.admin-brand-mark i:nth-child(4) {
background: #b9d7f3;
}

.admin-brand-mark.has-logo {
padding: 0;
}

.admin-brand-mark img {
width: 100%;
    height: 100%;
    grid-column: 1 / -1;
    object-fit: cover;
}

.detail-rich-content {
min-width: 0;
    color: #4f657a;
    font-size: 13px;
    line-height: 1.85;
    overflow-wrap: anywhere;
}

.detail-rich-content > :first-child {
margin-top: 0;
}

.detail-rich-content > :last-child {
margin-bottom: 0;
}

.detail-rich-content h1,
.detail-rich-content h2,
.detail-rich-content h3 {
margin: 1.4em 0 0.55em;
    color: #263d52;
    line-height: 1.35;
}

.detail-rich-content h1 {
font-size: 22px;
}

.detail-rich-content h2 {
font-size: 19px;
}

.detail-rich-content h3 {
font-size: 16px;
}

.detail-rich-content p,
.detail-rich-content ul,
.detail-rich-content ol,
.detail-rich-content blockquote {
margin: 0.8em 0;
}

.detail-rich-content a {
color: var(--brand-deep);
}

.detail-rich-content blockquote {
padding: 10px 14px;
    border-left: 3px solid #a9c8e8;
    color: #60778c;
    background: #f5f9fd;
}

.detail-rich-content figure {
margin: 18px 0;
}

.detail-rich-content figcaption {
margin-top: 7px;
    color: var(--muted);
    font-size: 11px;
    text-align: center;
}

.admin-brand-mark {
width: 38px;
    height: 38px;
    padding: 5px;
}

.admin-brand-mark i {
display: block;
}

.user-avatar {
display: grid;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 10px;
    color: #fff;
    background: var(--brand);
    font-size: 13px;
    font-weight: 750;
    text-transform: uppercase;
}

.user-copy {
display: grid;
    min-width: 0;
    gap: 1px;
}

.user-copy strong {
overflow: hidden;
    color: #31485e;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-copy small {
color: #8495a5;
    font-size: 9px;
}

.admin-page-heading {
display: flex;
    margin-bottom: 24px;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
}

.admin-page-heading.compact {
align-items: center;
}

.admin-page-heading h1 {
margin: 0;
    color: #1b2f43;
    font-size: 29px;
    font-weight: 820;
    letter-spacing: -0.025em;
    line-height: 1.2;
}

.admin-page-heading p,
.admin-page-heading > div > span {
display: block;
    margin: 6px 0 0;
    color: #74889c;
    font-size: 11px;
}

.admin-primary-button,
.admin-secondary-button {
display: inline-flex;
    min-height: 38px;
    padding: 0 14px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-radius: var(--radius-sm);
    font-size: 11px;
    font-weight: 680;
    text-decoration: none;
    cursor: pointer;
}

.admin-primary-button {
border: 1px solid var(--brand);
    color: #fff;
    background: var(--brand);
}

.admin-primary-button:hover {
border-color: var(--brand-deep);
    background: var(--brand-deep);
}

.admin-secondary-button {
border: 1px solid #d1dfec;
    color: #4d657c;
    background: #f8fbfe;
}

.admin-secondary-button:hover {
border-color: #b6cee5;
    color: var(--brand-deep);
    background: var(--brand-pale);
}

.admin-primary-button svg,
.admin-secondary-button svg {
width: 14px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-width: 1.8;
}

.account-group {
display: flex;
    flex: 0 0 auto;
    margin-left: 14px;
    padding-left: 14px;
    align-items: center;
    border-left: 1px solid #dbe5ee;
}

.account-link {
display: inline-flex;
    min-height: 40px;
    padding: 0 7px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 8px;
    color: #415a73;
    background: transparent;
    font-size: 14px;
    font-weight: 650;
    text-decoration: none;
}

.account-avatar {
display: grid;
    width: 28px;
    height: 28px;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid #cedae6;
    border-radius: 50%;
    color: #42627f;
    background: #f3f7fb;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.account-avatar svg {
width: 14px;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-width: 1.8;
}

.account-label {
min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.account-link:hover {
color: var(--brand-deep);
    background: rgba(232, 242, 252, 0.78);
}

.admin-panel,
.form-card,
.side-save-card,
.settings-note,
.password-card {
min-width: 0;
    border: 1px solid #d8e3ed;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-sm);
}

.admin-panel,
.form-card,
.password-card {
padding: 22px;
}

.admin-panel-heading,
.form-card-heading {
display: flex;
    margin-bottom: 18px;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.admin-panel-heading h2,
.form-card-heading h2,
.settings-note h3,
.side-save-card h3 {
margin: 0;
    color: #243b51;
    font-size: 15px;
    font-weight: 760;
}

.admin-panel-heading p,
.form-card-heading p {
margin: 3px 0 0;
    color: var(--muted);
    font-size: 10px;
}

.panel-count {
color: var(--muted);
    font-size: 10px;
}

.admin-empty {
display: grid;
    min-height: 160px;
    padding: 28px;
    place-content: center;
    gap: 8px;
    border: 1px dashed #d5e1eb;
    border-radius: 12px;
    color: var(--muted);
    background: #f9fbfd;
    text-align: center;
}

.admin-empty h3 {
margin: 0;
    color: #40586f;
    font-size: 16px;
}

.admin-empty > span {
display: grid;
    color: var(--brand);
    place-items: center;
}

.admin-empty > span svg {
width: 30px;
    height: 30px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.admin-empty p {
margin: 0;
}

.submission-status {
display: inline-flex;
    min-height: 24px;
    padding: 0 8px;
    align-items: center;
    border-radius: 999px;
    color: #708396;
    background: #f0f4f7;
    font-size: 9px;
    font-weight: 650;
    white-space: nowrap;
}

.table-edition,
.table-type {
display: inline-flex;
    min-height: 24px;
    padding: 0 8px;
    align-items: center;
    border-radius: 6px;
    white-space: nowrap;
}

.table-edition {
color: #526f8e;
    background: #edf3fa;
}

.table-type {
color: #9a6e30;
    background: #faead1;
}

.admin-form-side {
align-self: start;
}

.settings-layout,
.admin-form-layout {
display: grid;
    grid-template-columns: minmax(0, 1fr) 270px;
    align-items: start;
    gap: 18px;
}

.admin-form-main {
display: grid;
    gap: 16px;
}

.side-save-card,
.settings-note {
position: sticky;
    top: 84px;
    padding: 18px;
}

.settings-note p,
.side-save-card p,
.security-note span,
.security-note p {
color: var(--muted);
    font-size: 10px;
    line-height: 1.7;
}

.security-note {
display: grid;
    margin-top: 14px;
    padding: 11px;
    gap: 4px;
    border: 1px solid #e8dcc5;
    border-radius: 9px;
    background: #fffaf1;
}

.security-note strong {
color: #8f681f;
    font-size: 10px;
}

.form-grid {
display: grid;
    gap: 15px;
}

.form-grid.two-columns {
grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-wide {
grid-column: 1 / -1;
}

.form-grid label {
display: grid;
    min-width: 0;
    gap: 6px;
}

.form-grid label > span {
color: #526a80;
    font-size: 11px;
    font-weight: 680;
}

.form-grid input,
.form-grid textarea,
.form-grid select {
width: 100%;
    min-width: 0;
    min-height: 42px;
    padding: 9px 11px;
    border: 1px solid #cfdce8;
    border-radius: 9px;
    outline: 0;
    color: #263a4e;
    background: #f7fafc;
}

.form-grid textarea {
min-height: 100px;
    line-height: 1.7;
    resize: vertical;
}

.form-grid select {
appearance: auto;
}

select option,
select optgroup {
color: #263a4e;
    background-color: #fff;
}

.ui-select {
position: relative;
    width: 100%;
    min-width: 0;
}

.ui-select-native {
position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    pointer-events: none;
}

.ui-select-trigger {
display: flex;
    width: 100%;
    min-width: 0;
    min-height: 42px;
    padding: 0 12px;
    align-items: center;
    gap: 10px;
    border: 1px solid #cfdce8;
    border-radius: 9px;
    outline: 0;
    color: #263a4e;
    background: #f7fafc;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.ui-select-trigger:hover {
border-color: #b8cee2;
    background: #fff;
}

.ui-select-value {
min-width: 0;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ui-select-trigger.is-placeholder .ui-select-value {
color: #7b8ea1;
}

.ui-select-trigger svg {
width: 16px;
    height: 16px;
    flex: 0 0 auto;
    fill: none;
    stroke: #647b91;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
    transition: transform 150ms ease;
}

.ui-select.is-open .ui-select-trigger {
border-color: #8fb8df;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(45, 115, 205, 0.1);
}

.ui-select.is-open .ui-select-trigger svg {
transform: rotate(180deg);
}

.ui-select.is-invalid .ui-select-trigger {
border-color: #d9a5a5;
    box-shadow: 0 0 0 3px rgba(185, 93, 93, 0.09);
}

.ui-select.is-disabled {
opacity: 0.65;
}

.ui-select-trigger:disabled {
cursor: not-allowed;
}

.ui-select-popover {
position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 320px;
    max-width: calc(100vw - 24px);
    max-height: min(360px, calc(100vh - 150px));
    padding: 6px;
    overflow-y: auto;
    overscroll-behavior: contain;
    border: 1px solid #d4e1ec;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(33, 61, 89, 0.16);
    scrollbar-color: #c5d4e2 transparent;
    scrollbar-width: thin;
}

.ui-select-popover::-webkit-scrollbar {
width: 8px;
}

.ui-select-popover::-webkit-scrollbar-thumb {
border: 2px solid #fff;
    border-radius: 999px;
    background: #c5d4e2;
}

.ui-select-list {
display: grid;
    gap: 1px;
}

.ui-select-group-label {
padding: 8px 10px 5px;
    color: #7b8da0;
    font-size: 12px;
    font-weight: 750;
    letter-spacing: 0.02em;
}

.ui-select-group-label:first-child {
padding-top: 5px;
}

.ui-select-option {
display: flex;
    width: 100%;
    min-height: 38px;
    padding: 0 10px;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: 0;
    border-radius: 8px;
    outline: 0;
    color: #40586e;
    background: transparent;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.ui-select-option:hover,
.ui-select-option:focus-visible {
color: var(--brand-deep);
    background: #f1f7fd;
}

.ui-select-option.is-selected {
color: var(--brand-deep);
    background: #e8f2fc;
    font-weight: 700;
}

.ui-select-option:disabled {
color: #9aa9b7;
    cursor: not-allowed;
}

.ui-select-check {
visibility: hidden;
    color: var(--brand);
    font-weight: 800;
}

.ui-select-option.is-selected .ui-select-check {
visibility: visible;
}

.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus {
border-color: #9dbfe2;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(45, 115, 205, 0.09);
}

.form-grid label > small {
color: #8798a8;
    font-size: 9px;
    line-height: 1.55;
}

.form-section-title,
.settings-section-heading {
display: flex;
    padding: 14px 0 9px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid #e2e9f0;
    color: #334b61;
    font-size: 12px;
    font-weight: 700;
}

.form-section-title:first-child,
.settings-section-heading:first-child {
border-top: 0;
}

.settings-section-heading strong {
font-size: 13px;
}

.settings-section-heading span {
color: var(--muted);
    font-size: 10px;
    font-weight: 500;
}

.form-submit-row {
display: flex;
    margin-top: 18px;
    align-items: center;
    gap: 9px;
}

.form-error-box {
padding: 11px 13px;
    border: 1px solid #edcccc;
    border-radius: 9px;
    color: #a64f4f;
    background: #fff2f2;
    font-size: 11px;
    line-height: 1.65;
}

.form-error-box p {
margin: 3px 0;
}

.server-form-error {
width: min(100%, 1120px);
    margin: 0 auto 16px;
}

.choice-options {
display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.choice-option {
position: relative;
}

.choice-option input {
position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.choice-option span {
display: inline-flex;
    min-height: 34px;
    padding: 0 12px;
    align-items: center;
    border: 1px solid #d9e3ec;
    border-radius: var(--radius-sm);
    color: #5c7185;
    background: #f8fafc;
    font-size: 11px;
    cursor: pointer;
}

.choice-option input:checked + span {
border-color: #aec9e4;
    color: var(--brand-deep);
    background: var(--brand-pale);
}

.choice-options.is-invalid .choice-option span {
border-color: #dfb4b4;
    background: #fff7f7;
}

.form-choice-field {
display: grid;
    gap: 7px;
}

.form-choice-error {
color: var(--danger) !important;
}

.server-form-wizard {
width: min(100%, 1120px);
    margin: 0 auto;
}

.server-wizard-card {
overflow: visible;
    border: 1px solid #d6e2ec;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-sm);
}

.server-wizard-heading {
display: flex;
    padding: 24px 28px 20px;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}

.server-wizard-kicker {
display: block;
    color: var(--brand);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.1em;
}

.server-wizard-heading h1 {
margin: 4px 0 0;
    color: #1b2f43;
    font-size: 29px;
    font-weight: 820;
    letter-spacing: -0.025em;
    line-height: 1.2;
}

.server-wizard-heading p {
margin: 7px 0 0;
    color: #74889c;
    font-size: 13px;
    line-height: 1.6;
}

.server-wizard-cancel {
flex: 0 0 auto;
    padding: 6px 0 6px 12px;
    color: #708497;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
}

.server-wizard-cancel:hover {
color: var(--brand-deep);
}

.server-wizard-progress {
display: grid;
    padding: 24px 28px;
    grid-template-columns: minmax(0, 1fr) 58px minmax(0, 1fr) 58px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid #e0e9f1;
    border-radius: 15px 15px 0 0;
    background: #fbfdff;
}

.server-wizard-step {
display: flex;
    min-width: 0;
    padding: 0;
    align-items: center;
    gap: 11px;
    border: 0;
    color: #8a9aab;
    background: transparent;
    text-align: left;
}

.server-wizard-step:disabled {
cursor: default;
}

.server-wizard-number {
display: grid;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    place-items: center;
    border-radius: 50%;
    color: #8a9aab;
    background: #edf2f7;
    font-size: 15px;
    font-weight: 800;
}

.server-wizard-label {
display: grid;
    min-width: 0;
    gap: 2px;
}

.server-wizard-label strong {
overflow: hidden;
    color: #6c8093;
    font-size: 14px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.server-wizard-label small {
overflow: hidden;
    color: #96a5b3;
    font-size: 12px;
    line-height: 1.4;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.server-wizard-step.is-active .server-wizard-number {
color: #fff;
    background: var(--brand);
    box-shadow: 0 6px 15px rgba(45, 115, 205, 0.2);
}

.server-wizard-step.is-active .server-wizard-label strong {
color: #263d53;
}

.server-wizard-step.is-active .server-wizard-label small {
color: #6f8396;
}

.server-wizard-step.is-complete .server-wizard-number {
color: var(--brand-deep);
    background: var(--brand-pale);
}

.server-wizard-step.is-complete .server-wizard-label strong {
color: #48647e;
}

.server-wizard-line {
height: 1px;
    background: #dbe4ed;
}

.server-wizard-line.is-complete {
background: #b7d1ea;
}

.server-wizard-panel {
scroll-margin-top: 90px;
    padding: 28px;
}

.server-wizard-panel[hidden] {
display: none;
}

.server-wizard-panel-head {
display: flex;
    margin-bottom: 22px;
    padding-bottom: 15px;
    align-items: flex-start;
    gap: 12px;
    border-bottom: 1px solid #e8eef4;
}

.server-wizard-panel-head > span {
padding-top: 2px;
    color: var(--brand);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.server-wizard-panel-head h2 {
margin: 0;
    color: #263d53;
    font-size: 19px;
}

.server-wizard-panel-head p {
margin: 4px 0 0;
    color: #718598;
    font-size: 13px;
    line-height: 1.6;
}

.server-wizard-footer {
display: flex;
    padding: 18px 28px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    border-top: 1px solid #e0e9f1;
    border-radius: 0 0 15px 15px;
    background: #f9fcfe;
}

.server-wizard-footer > small {
max-width: 660px;
    color: #7a8d9f;
    font-size: 12px;
    line-height: 1.6;
}

.server-wizard-actions {
display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
}

.server-wizard-actions .admin-primary-button,
.server-wizard-actions .admin-secondary-button {
min-width: 92px;
}

.form-choice-field > span,
.rich-editor-field > span {
color: #526a80;
    font-size: 11px;
    font-weight: 680;
}

.form-choice-field > small,
.rich-editor-field > small {
color: #8798a8;
    font-size: 9px;
    line-height: 1.55;
}

.server-version-control {
display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
}

.server-version-control > select {
width: 100%;
    min-width: 0;
    max-width: 100%;
}

.server-version-control > .ui-select {
width: 100%;
    min-width: 0;
    max-width: 100%;
}

.rich-editor-field {
display: grid;
    gap: 8px;
}

.rich-editor {
overflow: hidden;
    border: 1px solid #d2dfe9;
    border-radius: 10px;
    background: #fbfdfe;
}

.rich-editor-toolbar {
display: flex;
    padding: 8px;
    flex-wrap: wrap;
    gap: 6px;
    border-bottom: 1px solid #e2e9f0;
    background: #f5f9fc;
}

.rich-editor-toolbar button,
.rich-editor-toolbar a {
display: inline-flex;
    min-height: 34px;
    padding: 0 11px;
    align-items: center;
    justify-content: center;
    border: 1px solid #d7e2eb;
    border-radius: 7px;
    color: #587087;
    background: #fff;
    font-size: 14px;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.rich-editor-toolbar a:hover,
.rich-editor-toolbar button:hover {
    border-color: #b6cee4;
    color: var(--brand-deep);
    background: var(--brand-pale);
}

.rich-editor-toolbar .rich-editor-status {
    margin-left: auto;
    align-self: center;
}

.rich-editor textarea {
width: 100%;
    min-height: 210px;
    padding: 12px;
    border: 0;
    outline: 0;
    background: #fff;
    line-height: 1.7;
    resize: vertical;
}

.rich-editor-preview-panel {
padding: 14px;
    border-top: 1px solid #e2e9f0;
    background: #fff;
}

.rich-editor-status {
padding: 7px 10px;
    color: var(--muted);
    font-size: 9px;
}

.rich-editor-status.is-error {
color: var(--danger);
}

.rich-editor-video-card {
display: flex;
    margin: 0;
    padding: 8px;
    align-items: center;
    gap: 10px;
    border: 0;
    border-bottom: 1px solid #e2e9f0;
    border-radius: 0;
    background: #f8fbfd;
}

.rich-editor-video-card button {
    flex: 0 0 auto;
    min-height: 30px;
    margin-left: auto;
    padding: 0 9px;
    border: 1px solid #d7e2eb;
    border-radius: 7px;
    color: #587087;
    background: #fff;
    font-size: 10px;
    cursor: pointer;
}

.rich-editor-video-card button + button {
    margin-left: 0;
}

.rich-editor-video-mark {
display: grid;
    width: 28px;
    height: 28px;
    place-items: center;
    border-radius: 7px;
    color: #fff;
    background: var(--brand);
    font-size: 10px;
    font-weight: 800;
}

.rich-editor-video-mark svg {
    width: 14px;
    height: 14px;
    fill: currentColor;
}

.rich-editor-video-copy {
display: grid;
    flex: 1 1 auto;
    min-width: 0;
    gap: 2px;
}

.rich-editor-video-copy strong {
overflow: hidden;
    color: #40586e;
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rich-editor-video-copy small {
color: var(--muted);
    font-size: 9px;
}

.site-image-setting {
display: grid;
    gap: 8px;
}

.site-image-label {
color: #526a80;
    font-size: 11px;
    font-weight: 680;
}

.site-image-upload {
display: flex;
    align-items: flex-start;
    gap: 12px;
}

.site-image-preview {
display: grid;
    width: 64px;
    height: 64px;
    flex: 0 0 auto;
    overflow: hidden;
    place-items: center;
    border: 1px solid #d6e2ec;
    border-radius: 11px;
    color: var(--muted);
    background: #f3f7fa;
    font-size: 9px;
}

.site-image-preview.is-favicon {
width: 48px;
    height: 48px;
}

.site-image-preview img {
width: 100%;
    height: 100%;
    object-fit: cover;
}

.site-image-upload-control {
display: grid;
    min-width: 0;
    gap: 6px;
}

.site-image-upload-control > small {
color: var(--muted);
    font-size: 9px;
}

.site-image-reset {
display: inline-flex !important;
    width: fit-content;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 5px !important;
    color: var(--muted);
    font-size: 9px;
}

.site-image-reset input {
width: 14px;
    min-height: 14px;
}

.admin-flash {
margin-bottom: 14px;
    padding: 11px 13px;
    border: 1px solid #d2e4da;
    border-radius: 9px;
    color: #34795c;
    background: #edf8f2;
    font-size: 11px;
}

.admin-flash.error {
border-color: #edcccc;
    color: var(--danger);
    background: #fff2f2;
}

.admin-flash.info {
border-color: #d3e3f2;
    color: var(--brand-deep);
    background: #eff7fe;
}

.admin-flash.fade-out {
opacity: 0;
    transition: opacity 300ms ease;
}

.password-toggle {
position: absolute;
    top: 50%;
    right: 8px;
    min-height: 27px;
    padding: 0 7px;
    border: 0;
    border-radius: 6px;
    color: var(--brand-deep);
    background: var(--brand-pale);
    font-size: 9px;
    cursor: pointer;
}

.auth-form label:has(.password-toggle) input {
padding-right: 58px;
}

.rich-editor-video-preview {
margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid #e1e9f0;
}

.rich-editor-video-preview h3 {
margin: 0 0 9px;
    color: #40586e;
    font-size: 13px;
}

.video-dialog {
    width: min(calc(100% - 28px), 620px);
    max-height: calc(100dvh - 32px);
    padding: 0;
    overflow: auto;
    border: 0;
    border-radius: 16px;
    background: transparent;
}

.video-dialog::backdrop {
    background: rgba(25, 43, 62, 0.42);
    backdrop-filter: blur(3px);
}

.video-dialog-card {
    display: grid;
    padding: 22px;
    gap: 14px;
    border: 1px solid #d7e2ed;
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-lg);
}

.video-dialog-card h3 {
    margin: 0;
    color: #243b51;
    font-size: 20px;
}

.video-dialog-card > p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.75;
}

.video-dialog-card label {
    display: grid;
    gap: 6px;
}

.video-dialog-card label > span {
    color: #526a80;
    font-size: 11px;
    font-weight: 680;
}

.video-dialog-card input {
    width: 100%;
    min-height: 42px;
    padding: 9px 11px;
    border: 1px solid #cfdce8;
    border-radius: 9px;
    outline: 0;
    color: #263a4e;
    background: #f7fafc;
}

.video-dialog-card input:focus {
    border-color: #9dbfe2;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(45, 115, 205, 0.09);
}

.video-dialog-actions {
    display: flex;
    margin-top: 2px;
    justify-content: flex-end;
    gap: 8px;
}

.video-dialog-actions button {
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid #d1dfec;
    border-radius: 8px;
    color: #4d657c;
    background: #f8fbfe;
    font-size: 11px;
    font-weight: 680;
    cursor: pointer;
}

.video-dialog-actions button:last-child {
    border-color: var(--brand);
    color: #fff;
    background: var(--brand);
}

.video-dialog-error {
    margin: 0;
    color: var(--danger);
    font-size: 11px;
}

@media (max-width: 1024px) {
.settings-layout,
.admin-form-layout {
grid-template-columns: minmax(0, 1fr);
}

.settings-note,
.side-save-card {
position: static;
}
}

@media (max-width: 760px) {
.server-wizard-heading {
padding: 19px 16px 16px;
        gap: 12px;
}

.server-wizard-heading h1 {
font-size: 24px;
}

.server-wizard-heading p {
font-size: 12px;
}

.server-wizard-cancel {
padding-top: 3px;
        font-size: 12px;
}

.admin-page-heading {
align-items: flex-start;
        flex-direction: column;
}

.form-grid.two-columns {
grid-template-columns: 1fr;
}

.server-wizard-progress {
padding: 16px;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
}

.server-wizard-line {
display: none;
}

.server-wizard-step {
align-items: flex-start;
        gap: 7px;
}

.server-wizard-number {
width: 30px;
        height: 30px;
        flex-basis: 30px;
        font-size: 13px;
}

.server-wizard-label strong {
font-size: 13px;
}

.server-wizard-label small {
font-size: 10px;
}

.server-wizard-panel {
padding: 20px 16px;
}

.server-wizard-panel-head {
margin-bottom: 18px;
        padding-bottom: 12px;
}

.server-wizard-panel-head h2 {
font-size: 17px;
}

.server-wizard-panel-head p {
font-size: 12px;
}

.server-wizard-footer {
padding: 15px 16px;
        align-items: stretch;
        flex-direction: column;
        gap: 13px;
}

.server-wizard-actions {
width: 100%;
}

.server-wizard-actions > button {
flex: 1;
}

.site-image-upload {
flex-direction: column;
}
}

@media (max-width: 520px) {
.server-wizard-label small {
display: none;
}

.server-wizard-label strong {
font-size: 12px;
}

.rich-editor-video-card {
    padding: 8px;
    gap: 8px;
}

/* Readability baseline for shared labels and controls. */
button,
input,
select,
textarea {
    font-size: 13px;
}

small {
    font-size: 12px;
}

.form-grid label > span,
.form-choice-field > span,
.rich-editor-field > span,
.site-image-label {
    font-size: 13px;
}

.form-grid label > small,
.form-choice-field > small,
.rich-editor-field > small {
    font-size: 11px;
}

.admin-primary-button,
.admin-secondary-button,
.submission-status,
.table-edition,
.table-type,
.panel-count {
    font-size: 12px;
}

.rich-editor-video-card button {
    padding: 0 8px;
}

.video-dialog-card {
    padding: 18px;
}

.video-dialog-actions button {
    flex: 1;
}
}
