﻿.is-page {
    direction: rtl;
    width: 100%;
    min-width: 0;
}

.is-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.is-stat {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 76px;
    padding: 12px 14px;
    border: 1px solid #d7dee5;
    border-radius: 14px;
    background: #fff;
}

.is-stat__icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
}

.is-stat--online .is-stat__icon {
    color: #15803d;
    background: rgba(34, 197, 94, .14);
}

.is-stat--offline .is-stat__icon {
    color: #b91c1c;
    background: rgba(239, 68, 68, .12);
}

.is-stat--files .is-stat__icon {
    color: #0b5f8f;
    background: rgba(24, 123, 191, .12);
}

.is-stat--req .is-stat__icon {
    color: #b45309;
    background: rgba(245, 158, 11, .16);
}

.is-stat__meta {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.is-stat__value {
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1;
    color: #044464;
}

.is-stat__label {
    font-size: .78rem;
    color: #64748b;
    font-weight: 600;
}

.is-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(280px, .88fr);
    gap: 16px;
    align-items: start;
}

.is-panel {
    border: 1px solid rgba(4, 68, 100, .12);
    border-radius: 16px;
    background: #fff;
    overflow: hidden;
    min-width: 0;
}

.is-panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    padding: 14px 18px;
    border-bottom: 1px solid rgba(4, 68, 100, .08);
    background: linear-gradient(135deg, #eef6fb 0%, #f8fbfd 100%);
}

.is-panel__title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: .98rem;
    font-weight: 800;
    color: #044464;
}

.is-panel__title-ic {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(4, 68, 100, .1);
    color: #044464;
}

.is-panel__subtitle {
    font-size: .78rem;
    color: #64748b;
    font-weight: 400;
    margin-top: 2px;
}

.is-progress {
    font-size: .76rem;
    font-weight: 700;
    color: #0b5f8f;
    background: rgba(24, 123, 191, .1);
    padding: 4px 10px;
    border-radius: 999px;
}

.is-panel__body {
    padding: 16px 18px 8px;
}

.is-banner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid rgba(4, 68, 100, .1);
    background: linear-gradient(135deg, #eef6fb 0%, #f7fafc 100%);
    margin-bottom: 14px;
    font-size: .86rem;
    line-height: 1.6;
}

.is-banner__icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: rgba(4, 68, 100, .08);
}

.is-banner--warn {
    border-color: rgba(176, 106, 20, .28);
    background: linear-gradient(135deg, #fff7ea 0%, #f7fafc 100%);
    color: #7a4b0a;
}

.is-banner--error {
    border-color: rgba(180, 35, 24, .25);
    background: linear-gradient(135deg, #fdeeee 0%, #f7fafc 100%);
    color: #8a2218;
}

.is-stepper {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    list-style: none;
    margin: 0;
    padding: 14px 10px 0;
    border-bottom: 1px solid rgba(4, 68, 100, .08);
    position: relative;
}

    .is-stepper::before {
        content: "";
        position: absolute;
        top: 28px;
        right: 12%;
        left: 12%;
        height: 2px;
        background: #e2e8f0;
        z-index: 0;
    }

.is-stepper__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    position: relative;
    z-index: 1;
    padding: 4px 6px 12px;
    color: #94a3b8;
}

.is-stepper__num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #64748b;
    font-size: .78rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.is-stepper__item.is-current .is-stepper__num {
    background: #044464;
    color: #fff;
}

.is-stepper__item.is-done .is-stepper__num {
    background: #22c55e;
    color: #fff;
}

.is-stepper__label {
    font-size: .72rem;
    font-weight: 700;
}

.is-stepper__item.is-current .is-stepper__label,
.is-stepper__item.is-done .is-stepper__label {
    color: #044464;
}

.is-section {
    padding: 14px 0 16px;
    border-bottom: 1px solid rgba(4, 68, 100, .07);
}

    .is-section:last-child {
        border-bottom: 0;
    }

.is-section--locked {
    opacity: .62;
}

.is-section__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.is-section__title {
    font-size: .88rem;
    font-weight: 800;
    color: #044464;
}

.is-section__hint {
    font-size: .76rem;
    color: #64748b;
    margin-top: 3px;
}

.is-section__actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.is-node-search {
    min-width: min(220px, 100%);
    max-width: 260px;
}

.is-locked-hint {
    font-size: .82rem;
    color: #94a3b8;
    padding: 8px 0 2px;
}

.is-selected-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 10px;
    background: rgba(34, 197, 94, .08);
    border: 1px solid rgba(34, 197, 94, .2);
    font-size: .82rem;
    color: #166534;
    margin-bottom: 12px;
}

.is-fields-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.is-node-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 10px;
}

.is-node-card {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 12px;
    border: 1px solid #d7dee5;
    border-radius: 14px;
    background: #fff;
    cursor: pointer;
    text-align: right;
    min-height: 108px;
    position: relative;
    transition: border-color .15s, background .15s, box-shadow .15s;
}

    .is-node-card:hover:not(.is-node-card--disabled):not(.is-selected) {
        border-color: #187bbf;
        background: #f8fbfd;
    }

    .is-node-card.is-selected {
        border-color: #044464;
        background: #f2f7fa;
        box-shadow: inset 0 0 0 1px #044464;
    }

.is-node-card--disabled {
    opacity: .58;
    cursor: not-allowed;
    background: #f8f8f8;
}

.is-node-card__mark {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid #cbd5e1;
}

.is-node-card.is-selected .is-node-card__mark {
    border-color: #044464;
    background: #044464;
    box-shadow: inset 0 0 0 3px #fff;
}

.is-node-card__ic {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(4, 68, 100, .08);
    color: #044464;
}

.is-node-card__body {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.is-node-card__name {
    font-size: .88rem;
    font-weight: 800;
    color: #044464;
    line-height: 1.35;
}

.is-node-card__region {
    font-size: .74rem;
    color: #64748b;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.is-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.is-status-dot--online {
    background: #22c55e;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, .65);
    animation: is-dot-pulse 1.8s ease-out infinite;
}

.is-status-dot--offline {
    background: #ef4444;
}

@keyframes is-dot-pulse {
    0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, .55); }
    70% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); }
    100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.is-status-label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 700;
    width: fit-content;
}

.is-status-label--online {
    color: #15803d;
    background: rgba(34, 197, 94, .12);
}

.is-status-label--offline {
    color: #b91c1c;
    background: rgba(239, 68, 68, .1);
}

.is-dropzone {
    width: 100%;
    border: 1px dashed rgba(4, 68, 100, .28);
    background: #f8fbfd;
    border-radius: 14px;
    padding: 22px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: #64748b;
    cursor: pointer;
}

    .is-dropzone strong {
        color: #044464;
        font-size: .9rem;
        margin-top: 4px;
    }

    .is-dropzone span {
        font-size: .78rem;
    }

    .is-dropzone:hover {
        border-color: #187bbf;
        background: #eef6fb;
    }

.is-dropzone__ic {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(24, 123, 191, .12);
    color: #0b5f8f;
    font-size: 1.15rem;
}

.is-file-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 220px;
    overflow: auto;
}

.is-file-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 12px;
    background: #f7fafc;
    border: 1px solid rgba(4, 68, 100, .08);
}

.is-file-row__ic {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #0b5f8f;
    flex-shrink: 0;
}

.is-file-row__name {
    flex: 1;
    min-width: 0;
    font-size: .84rem;
    font-weight: 700;
    color: #044464;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.is-file-row__tag {
    font-size: .68rem;
    font-weight: 700;
    color: #0b5f8f;
    background: rgba(24, 123, 191, .1);
    padding: 2px 8px;
    border-radius: 999px;
}

.is-file-row__remove {
    border: 0;
    background: transparent;
    color: #94a3b8;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    cursor: pointer;
}

    .is-file-row__remove:hover {
        background: rgba(239, 68, 68, .1);
        color: #b91c1c;
    }

.is-composer__foot {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 18px 16px;
    border-top: 1px solid rgba(4, 68, 100, .08);
    background: #fbfcfd;
}

.is-submit-btn {
    min-width: 220px;
}

.is-submit-hint {
    font-size: .78rem;
    color: #94a3b8;
}

.is-inbox .is-req-list {
    max-height: min(72vh, 820px);
    overflow: auto;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.is-req-card {
    border: 1px solid rgba(4, 68, 100, .1);
    border-radius: 14px;
    padding: 12px 14px;
    background: #fff;
}

.is-req-card__top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.is-req-card__title {
    font-size: .88rem;
    color: #044464;
    line-height: 1.4;
}

.is-req-card__dest {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
    color: #64748b;
    font-size: .78rem;
}

.is-req-card__dates {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 8px;
    font-size: .72rem;
    color: #94a3b8;
}

.is-req-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 700;
    line-height: 1.4;
    white-space: nowrap;
    flex-shrink: 0;
}

.is-req-badge--warn {
    color: #9a6700;
    background: rgba(245, 158, 11, .14);
}

.is-req-badge--info {
    color: #0b5f8f;
    background: rgba(24, 123, 191, .1);
}

.is-req-badge--ok {
    color: #166534;
    background: rgba(34, 197, 94, .12);
}

.is-req-badge--err {
    color: #b91c1c;
    background: rgba(239, 68, 68, .1);
}

.is-req-badge--muted {
    color: #64748b;
    background: rgba(100, 116, 139, .1);
}

.is-req-hint {
    font-size: .74rem;
    color: #94a3b8;
    line-height: 1.45;
    margin-top: 6px;
}

.is-req-error {
    font-size: .74rem;
    color: #b91c1c;
    line-height: 1.45;
    margin-top: 4px;
}

.is-page .is-empty {
    text-align: center;
    padding: 40px 18px;
    color: #64748b;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.is-page .is-empty--compact {
    padding: 22px 12px;
}

.is-page .is-empty .mud-icon-root {
    font-size: 1.8rem;
    opacity: .5;
}

@media (max-width: 1100px) {
    .is-layout {
        grid-template-columns: 1fr;
    }

    .is-inbox .is-req-list {
        max-height: none;
    }
}

@media (max-width: 720px) {
    .is-stats {
        grid-template-columns: 1fr 1fr;
    }

    .is-fields-grid {
        grid-template-columns: 1fr;
    }

    .is-stepper__label {
        font-size: .66rem;
    }

    .is-node-search {
        max-width: none;
        width: 100%;
    }

    .is-submit-btn {
        width: 100%;
        min-width: 0;
    }
}

.layout-theme.theme-dark .is-panel,
.layout-theme.theme-dark .is-stat,
.layout-theme.theme-dark .is-node-card,
.layout-theme.theme-dark .is-req-card,
body.app-dark-mode .is-panel,
body.app-dark-mode .is-stat,
body.app-dark-mode .is-node-card,
body.app-dark-mode .is-req-card {
    background: #1a2836;
    border-color: rgba(150, 191, 218, 0.28);
}

.layout-theme.theme-dark .is-panel__head,
.layout-theme.theme-dark .is-composer__foot,
body.app-dark-mode .is-panel__head,
body.app-dark-mode .is-composer__foot {
    background: linear-gradient(180deg, rgba(150, 191, 218, 0.12) 0%, rgba(150, 191, 218, 0.04) 100%);
    border-color: rgba(150, 191, 218, 0.16);
}

.layout-theme.theme-dark .is-panel__title,
.layout-theme.theme-dark .is-section__title,
.layout-theme.theme-dark .is-node-card__name,
.layout-theme.theme-dark .is-req-card__title,
.layout-theme.theme-dark .is-stat__value,
.layout-theme.theme-dark .is-file-row__name,
.layout-theme.theme-dark .is-dropzone strong,
.layout-theme.theme-dark .is-stepper__item.is-current .is-stepper__label,
.layout-theme.theme-dark .is-stepper__item.is-done .is-stepper__label,
body.app-dark-mode .is-panel__title,
body.app-dark-mode .is-section__title,
body.app-dark-mode .is-node-card__name,
body.app-dark-mode .is-req-card__title,
body.app-dark-mode .is-stat__value,
body.app-dark-mode .is-file-row__name,
body.app-dark-mode .is-dropzone strong,
body.app-dark-mode .is-stepper__item.is-current .is-stepper__label,
body.app-dark-mode .is-stepper__item.is-done .is-stepper__label {
    color: #d7eef8;
}

.layout-theme.theme-dark .is-panel__subtitle,
.layout-theme.theme-dark .is-section__hint,
.layout-theme.theme-dark .is-stat__label,
.layout-theme.theme-dark .is-node-card__region,
.layout-theme.theme-dark .is-req-card__dest,
.layout-theme.theme-dark .is-req-card__dates,
.layout-theme.theme-dark .is-req-hint,
.layout-theme.theme-dark .is-submit-hint,
.layout-theme.theme-dark .is-page .is-empty,
.layout-theme.theme-dark .is-locked-hint,
body.app-dark-mode .is-panel__subtitle,
body.app-dark-mode .is-section__hint,
body.app-dark-mode .is-stat__label,
body.app-dark-mode .is-node-card__region,
body.app-dark-mode .is-req-card__dest,
body.app-dark-mode .is-req-card__dates,
body.app-dark-mode .is-req-hint,
body.app-dark-mode .is-submit-hint,
body.app-dark-mode .is-page .is-empty,
body.app-dark-mode .is-locked-hint {
    color: #9db6c7;
}

.layout-theme.theme-dark .is-banner,
body.app-dark-mode .is-banner {
    background: linear-gradient(180deg, rgba(150, 191, 218, 0.12) 0%, rgba(150, 191, 218, 0.04) 100%);
    border-color: rgba(150, 191, 218, 0.22);
    color: #c5d4de;
}

.layout-theme.theme-dark .is-banner--warn,
body.app-dark-mode .is-banner--warn {
    background: rgba(245, 158, 11, .12);
    border-color: rgba(245, 158, 11, .35);
    color: #f0d48a;
}

.layout-theme.theme-dark .is-banner--error,
body.app-dark-mode .is-banner--error {
    background: rgba(239, 68, 68, .12);
    border-color: rgba(239, 68, 68, .35);
    color: #fca5a5;
}

.layout-theme.theme-dark .is-dropzone,
.layout-theme.theme-dark .is-file-row,
body.app-dark-mode .is-dropzone,
body.app-dark-mode .is-file-row {
    background: #162230;
    border-color: rgba(150, 191, 218, 0.22);
}

.layout-theme.theme-dark .is-node-card:hover:not(.is-node-card--disabled):not(.is-selected),
body.app-dark-mode .is-node-card:hover:not(.is-node-card--disabled):not(.is-selected) {
    border-color: #7eb6d4;
    background: rgba(150, 191, 218, 0.1);
}

.layout-theme.theme-dark .is-node-card.is-selected,
body.app-dark-mode .is-node-card.is-selected {
    border-color: #7eb6d4;
    background: rgba(150, 191, 218, 0.14);
    box-shadow: inset 0 0 0 1px #7eb6d4;
}

.layout-theme.theme-dark .is-node-card--disabled,
body.app-dark-mode .is-node-card--disabled {
    background: #162230;
}

.layout-theme.theme-dark .is-status-label--online,
body.app-dark-mode .is-status-label--online {
    color: #4ade80;
    background: rgba(34, 197, 94, .16);
}

.layout-theme.theme-dark .is-status-label--offline,
body.app-dark-mode .is-status-label--offline {
    color: #fca5a5;
    background: rgba(239, 68, 68, .16);
}

.layout-theme.theme-dark .is-req-badge--warn,
body.app-dark-mode .is-req-badge--warn {
    color: #f0d48a;
    background: rgba(245, 158, 11, .18);
}

.layout-theme.theme-dark .is-req-badge--info,
body.app-dark-mode .is-req-badge--info {
    color: #7eb6d4;
    background: rgba(24, 123, 191, .18);
}

.layout-theme.theme-dark .is-req-badge--ok,
body.app-dark-mode .is-req-badge--ok {
    color: #86efac;
    background: rgba(34, 197, 94, .16);
}

.layout-theme.theme-dark .is-req-badge--err,
.layout-theme.theme-dark .is-req-error,
body.app-dark-mode .is-req-badge--err,
body.app-dark-mode .is-req-error {
    color: #fca5a5;
}

.layout-theme.theme-dark .is-req-badge--err,
body.app-dark-mode .is-req-badge--err {
    background: rgba(239, 68, 68, .16);
}

.layout-theme.theme-dark .is-req-badge--muted,
body.app-dark-mode .is-req-badge--muted {
    color: #9db6c7;
    background: rgba(100, 116, 139, .22);
}

.layout-theme.theme-dark .is-selected-summary,
body.app-dark-mode .is-selected-summary {
    background: rgba(34, 197, 94, .12);
    border-color: rgba(34, 197, 94, .28);
    color: #86efac;
}

.layout-theme.theme-dark .is-stepper,
.layout-theme.theme-dark .is-section,
body.app-dark-mode .is-stepper,
body.app-dark-mode .is-section {
    border-color: rgba(150, 191, 218, 0.16);
}

.layout-theme.theme-dark .is-stepper::before,
body.app-dark-mode .is-stepper::before {
    background: #3d5160;
}

.layout-theme.theme-dark .is-stepper__num,
body.app-dark-mode .is-stepper__num {
    background: #3d5160;
    color: #9db6c7;
}
