﻿.arq-modal .modal-content {
    border: 0;
    border-radius: 28px;
    overflow: hidden;
    max-height: 88vh;
    background: radial-gradient(circle at top right, rgba(59,130,246,.22), transparent 24%), radial-gradient(circle at bottom left, rgba(14,165,233,.16), transparent 28%), linear-gradient(180deg, #0f172a 0%, #111827 100%);
    box-shadow: 0 30px 80px rgba(2,6,23,.55);
    color: #e5eefc;
}

.arq-modal .modal-header {
    border-bottom: 1px solid rgba(148,163,184,.14);
    padding: .65rem 1rem;
    background: linear-gradient(180deg, rgba(255,255,255,.04) 0%, rgba(255,255,255,.01) 100%);
}

.arq-head {
    display: flex;
    align-items: center;
    gap: .75rem;
    width: 100%;
    min-width: 0;
}

.arq-head-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    color: #dbeafe;
    background: linear-gradient(135deg, rgba(59,130,246,.28), rgba(14,165,233,.18));
    border: 1px solid rgba(125,211,252,.22);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 10px 24px rgba(2,132,199,.16);
}

    .arq-head-icon i {
        font-size: 1rem;
        line-height: 1;
    }

.arq-title {
    margin: 0;
    font-size: .98rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: .01em;
    color: #f8fafc;
}

.arq-head-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem;
    margin-top: 0;
}

.arq-chip {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    padding: .3rem .55rem;
    border-radius: 999px;
    font-size: .66rem;
    font-weight: 700;
    color: #cfe2ff;
    background: rgba(15,23,42,.48);
    border: 1px solid rgba(148,163,184,.14);
    backdrop-filter: blur(8px);
    line-height: 1;
}

.arq-modal .btn-close {
    filter: invert(1) grayscale(1) brightness(1.4);
    opacity: .72;
    box-shadow: none !important;
    margin: 0;
    padding: .2rem;
    transform: scale(.9);
}

    .arq-modal .btn-close:hover {
        opacity: 1;
    }

.arq-modal .modal-body {
    padding: .9rem 1rem;
    overflow: hidden;
}

.arq-layout {
    display: grid;
    grid-template-columns: minmax(0,1.45fr) minmax(340px,.95fr);
    gap: 1rem;
    min-height: 0;
}

.arq-card {
    background: linear-gradient(180deg, rgba(15,23,42,.72) 0%, rgba(15,23,42,.58) 100%);
    border: 1px solid rgba(148,163,184,.12);
    border-radius: 24px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.04), 0 20px 40px rgba(2,6,23,.18);
    backdrop-filter: blur(14px);
    min-height: 0;
}

.arq-card-head {
    padding: .7rem 1rem;
    border-bottom: 1px solid rgba(148,163,184,.10);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
}

.arq-card-title {
    margin: 0;
    font-size: .9rem;
    font-weight: 800;
    color: #f8fafc;
    line-height: 1.1;
}

.arq-card-body {
    padding: .9rem 1rem 1rem 1rem;
    min-height: 0;
}

.arq-card-denoms {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

    .arq-card-denoms .arq-card-body {
        flex: 1;
        min-height: 0;
    }

.arq-denoms {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: .8rem;
    max-height: calc(88vh - 250px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: .35rem;
    scrollbar-gutter: stable;
}

    .arq-denoms::-webkit-scrollbar {
        width: 8px;
    }

    .arq-denoms::-webkit-scrollbar-thumb {
        background: rgba(148,163,184,.24);
        border-radius: 999px;
    }

    .arq-denoms::-webkit-scrollbar-track {
        background: transparent;
    }

.arq-item {
    position: relative;
    border-radius: 20px;
    padding: .85rem;
    background: linear-gradient(180deg, rgba(30,41,59,.78) 0%, rgba(15,23,42,.9) 100%);
    border: 1px solid rgba(148,163,184,.12);
    transition: .18s ease;
    overflow: hidden;
}

    .arq-item::before {
        content: "";
        position: absolute;
        inset: 0 auto 0 0;
        width: 4px;
        background: linear-gradient(180deg, #38bdf8 0%, #2563eb 100%);
        opacity: .85;
    }

    .arq-item:hover {
        transform: translateY(-2px);
        border-color: rgba(96,165,250,.32);
        box-shadow: 0 14px 28px rgba(2,6,23,.22);
    }

.arq-item-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    margin-bottom: .7rem;
}

.arq-denom {
    font-size: 1rem;
    font-weight: 900;
    color: #f8fafc;
    letter-spacing: .02em;
    line-height: 1;
}

.arq-denom-tag {
    font-size: .66rem;
    font-weight: 700;
    color: #8ecdfd;
    background: rgba(14,165,233,.12);
    border: 1px solid rgba(14,165,233,.18);
    padding: .24rem .48rem;
    border-radius: 999px;
    line-height: 1;
    white-space: nowrap;
}

.arq-input {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(148,163,184,.16);
    color: #f8fafc;
    border-radius: 16px;
    min-height: 46px;
    font-size: .95rem;
    font-weight: 800;
    text-align: center;
    box-shadow: none !important;
}

    .arq-input::placeholder {
        color: #8ea2c0;
    }

    .arq-input:focus {
        background: rgba(255,255,255,.08);
        border-color: rgba(96,165,250,.48);
        color: #fff;
        box-shadow: 0 0 0 .2rem rgba(59,130,246,.15) !important;
    }

.arq-item-total {
    margin-top: .65rem;
    font-size: .8rem;
    color: #98acc8;
    display: flex;
    justify-content: space-between;
    gap: .75rem;
}

    .arq-item-total strong {
        color: #e2e8f0;
        font-size: .88rem;
        font-weight: 900;
    }

.arq-side {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 0;
}

.arq-summary-main {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

    .arq-summary-main .arq-card-body {
        flex: 1;
        min-height: 0;
    }

.arq-summary-scroll {
    max-height: calc(88vh - 320px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: .35rem;
    scrollbar-gutter: stable;
}

    .arq-summary-scroll::-webkit-scrollbar {
        width: 8px;
    }

    .arq-summary-scroll::-webkit-scrollbar-thumb {
        background: rgba(148,163,184,.24);
        border-radius: 999px;
    }

    .arq-summary-scroll::-webkit-scrollbar-track {
        background: transparent;
    }

.arq-summary-block {
    border-radius: 20px;
    padding: 1rem;
    background: linear-gradient(180deg, rgba(30,41,59,.75) 0%, rgba(15,23,42,.88) 100%);
    border: 1px solid rgba(148,163,184,.12);
}

.arq-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    padding: .42rem 0;
    font-size: .88rem;
}

    .arq-summary-row span:first-child {
        color: #97a8c4;
        font-weight: 600;
    }

    .arq-summary-row span:last-child {
        color: #f8fafc;
        font-weight: 800;
    }

    .arq-summary-row.is-green span:last-child {
        color: #34d399;
    }

    .arq-summary-row.is-red span:last-child {
        color: #f87171;
    }

    .arq-summary-row.total {
        margin-top: .2rem;
        padding-top: .75rem;
        border-top: 1px solid rgba(148,163,184,.12);
    }

        .arq-summary-row.total span {
            color: #ffffff !important;
            font-weight: 900 !important;
            font-size: .98rem;
        }

.arq-counted {
    padding: 1rem;
    border-radius: 22px;
    background: radial-gradient(circle at top right, rgba(59,130,246,.18), transparent 35%), linear-gradient(135deg, rgba(14,165,233,.16) 0%, rgba(37,99,235,.18) 100%);
    border: 1px solid rgba(96,165,250,.18);
}

.arq-counted-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
}

.arq-counted-label {
    font-size: .86rem;
    font-weight: 800;
    color: #dbeafe;
}

.arq-counted-value {
    font-size: 1.45rem;
    line-height: 1;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: .02em;
}

.arq-diff {
    margin-top: .7rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    padding-top: .7rem;
    border-top: 1px solid rgba(191,219,254,.14);
    font-size: .88rem;
    font-weight: 800;
}

    .arq-diff.is-positive {
        color: #34d399;
    }

    .arq-diff.is-negative {
        color: #f87171;
    }

    .arq-diff.is-neutral {
        color: #cbd5e1;
    }

.arq-note-label {
    display: block;
    margin-bottom: .45rem;
    font-size: .78rem;
    font-weight: 800;
    color: #dbe7fb;
}

.arq-note {
    min-height: 95px;
    resize: none;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(148,163,184,.14);
    color: #f8fafc;
    border-radius: 18px;
    box-shadow: none !important;
}

    .arq-note::placeholder {
        color: #8ea2c0;
    }

    .arq-note:focus {
        background: rgba(255,255,255,.07);
        border-color: rgba(96,165,250,.42);
        color: #fff;
        box-shadow: 0 0 0 .2rem rgba(59,130,246,.14) !important;
    }

.arq-user-box {
    display: grid;
    grid-template-columns: repeat(3, minmax(0,1fr));
    gap: .75rem;
}

.arq-mini {
    border-radius: 18px;
    padding: .8rem;
    background: linear-gradient(180deg, rgba(15,23,42,.75) 0%, rgba(2,6,23,.78) 100%);
    border: 1px solid rgba(148,163,184,.12);
}

.arq-mini-label {
    font-size: .68rem;
    font-weight: 700;
    color: #90a4c3;
    margin-bottom: .24rem;
    line-height: 1;
}

.arq-mini-value {
    font-size: .84rem;
    font-weight: 800;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}

.arq-modal .modal-footer {
    border-top: 1px solid rgba(148,163,184,.12);
    padding: .75rem 1rem .9rem 1rem;
    background: rgba(2,6,23,.18);
}

.arq-btn {
    min-height: 42px;
    min-width: 145px;
    border-radius: 14px;
    font-weight: 800;
    font-size: .88rem;
    letter-spacing: .01em;
    box-shadow: none !important;
    padding: .55rem .95rem;
}

.arq-btn-secondary {
    color: #dbe7fb;
    border: 1px solid rgba(148,163,184,.18);
    background: rgba(15,23,42,.5);
}

    .arq-btn-secondary:hover {
        color: #fff;
        background: rgba(30,41,59,.85);
        border-color: rgba(148,163,184,.28);
    }

.arq-btn-primary {
    color: #fff;
    border: 0;
    background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
    box-shadow: 0 16px 30px rgba(37,99,235,.28) !important;
}

    .arq-btn-primary:hover {
        color: #fff;
        transform: translateY(-1px);
        background: linear-gradient(135deg, #38bdf8 0%, #2563eb 100%);
    }

.arq-btn-danger {
    color: #fff;
    border: 0;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

    .arq-btn-danger:hover {
        color: #fff;
        background: linear-gradient(135deg, #f87171 0%, #dc2626 100%);
    }

input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
}

@media (max-width: 1199.98px) {
    .arq-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 991.98px) {
    .arq-modal .modal-content {
        max-height: none;
    }

    .arq-modal .modal-body {
        overflow: visible;
    }

    .arq-denoms,
    .arq-summary-scroll {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

@media (max-width: 767.98px) {
    .arq-denoms {
        grid-template-columns: 1fr;
    }

    .arq-user-box {
        grid-template-columns: 1fr;
    }

    .arq-counted-value {
        font-size: 1.28rem;
    }

    .arq-head-meta {
        width: 100%;
        justify-content: flex-start;
    }
}

@media (max-width: 575.98px) {
    .arq-modal .modal-header,
    .arq-modal .modal-body,
    .arq-modal .modal-footer {
        padding: .8rem;
    }

    .arq-head {
        gap: .6rem;
        align-items: flex-start;
    }

    .arq-head-icon {
        width: 36px;
        height: 36px;
        border-radius: 11px;
    }

    .arq-title {
        font-size: .92rem;
    }

    .arq-chip {
        font-size: .63rem;
        padding: .28rem .45rem;
    }

    .arq-card-head {
        padding: .65rem .85rem;
    }

    .arq-card-body {
        padding: .8rem .85rem .9rem .85rem;
    }

    .arq-item {
        padding: .75rem;
    }

    .arq-btn {
        width: 100%;
        min-width: 100%;
    }
}
