:root {
    font-family:
        Segoe UI,
        Arial,
        sans-serif;
    color: #242932;
    background: #f5f6f8;
    font-size: 14px;
    letter-spacing: 0;
}
* {
    box-sizing: border-box;
}
body {
    margin: 0;
}
button,
input,
select,
textarea {
    font: inherit;
}
button {
    cursor: pointer;
    border: 1px solid #cfd4da;
    background: #fff;
    color: #303740;
    padding: 9px 15px;
    border-radius: 5px;
    min-height: 38px;
}
button:hover {
    background: #edf3f2;
}
button:disabled {
    opacity: 0.55;
    cursor: wait;
}
.primary {
    background: #007c70;
    border-color: #007c70;
    color: white;
}
.primary:hover {
    background: #00665c;
}
input,
select,
textarea {
    border: 1px solid #cbd1d8;
    border-radius: 4px;
    padding: 10px;
    background: white;
    min-width: 0;
    width: 100%;
    color: #242932;
}
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #007c7055;
    outline-offset: 1px;
}
input[type="checkbox"] {
    width: 17px;
    height: 17px;
    accent-color: #007c70;
}
h1 {
    font-size: 25px;
    font-weight: 600;
    margin: 6px 0;
}
h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 20px;
}
small {
    color: #66717a;
}
label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    font-weight: 500;
}
label.check {
    flex-direction: row;
    align-items: center;
    align-self: center;
}
#shell {
    display: grid;
    grid-template-columns: 228px minmax(0, 1fr);
    min-height: 100vh;
}
aside {
    background: #fff;
    border-right: 1px solid #dfe3e7;
    padding: 28px 16px;
    display: flex;
    flex-direction: column;
}
.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 12px 48px;
}
.brand strong {
    font-size: 22px;
}
.brand span {
    display: block;
    color: #647078;
    margin-top: 1px;
}
.nav-label {
    font-size: 10px;
    color: #7a858c;
    padding: 0 12px;
    margin-bottom: 12px;
}
nav {
    display: grid;
    gap: 6px;
}
nav button {
    text-align: left;
    border: 0;
    background: none;
    padding: 12px;
}
nav button.active {
    background: #e3f2ef;
    color: #006a60;
    font-weight: 600;
    border-left: 3px solid #008577;
}
.aside-bottom {
    margin-top: auto;
    padding: 36px 10px 0;
    display: grid;
    gap: 12px;
    color: #748087;
}
.aside-bottom button {
    font-size: 12px;
}
main {
    padding: 34px 36px;
    min-width: 0;
}
header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-bottom: 30px;
}
.eyebrow {
    color: #73818a;
    font-size: 10px;
}
.firm {
    background: #e9edf0;
    border: 1px solid #d7dfe5;
    padding: 8px 12px;
    font-size: 12px;
    border-radius: 4px;
    white-space: nowrap;
}
.metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    background: #fff;
    border-top: 1px solid #e0e4e8;
    border-bottom: 1px solid #e0e4e8;
    margin-bottom: 28px;
}
.metrics > div {
    padding: 22px 20px;
    border-right: 1px solid #e0e4e8;
}
.metrics > div:last-child {
    border: 0;
}
.metrics span {
    color: #68747d;
    font-size: 12px;
}
.metrics strong {
    display: block;
    font-size: 30px;
    font-weight: 600;
    margin-top: 10px;
}
#done {
    color: #007e6d;
}
#failed {
    color: #b54c36;
}
.toolbar {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.toolbar input {
    flex: 1;
    min-width: 160px;
}
.toolbar select {
    width: 200px;
}
.toolbar h2 {
    flex: 1;
    margin: 0;
}
.table-scroll {
    overflow: auto;
    background: #fff;
    border: 1px solid #dfe3e7;
}
table {
    border-collapse: collapse;
    width: 100%;
    text-align: left;
    font-size: 12px;
}
th {
    padding: 13px 12px;
    background: #f0f2f4;
    color: #626e78;
    font-weight: 500;
    white-space: nowrap;
}
td {
    padding: 15px 12px;
    border-top: 1px solid #e6e9ec;
    max-width: 320px;
    overflow-wrap: anywhere;
}
td small {
    display: block;
    margin-top: 4px;
}
tbody tr:hover {
    background: #fafcfb;
}
.badge {
    display: inline-block;
    padding: 5px 7px;
    border-radius: 3px;
    font-size: 10px;
    background: #e9edf1;
    white-space: nowrap;
}
.badge.AKTARILDI {
    color: #006e59;
    background: #e2f3ec;
}
.badge.HATA,
.badge.KONTROL_GEREKIYOR {
    color: #a03729;
    background: #fdebe7;
}
.badge.BEKLIYOR,
.badge.ISLENIYOR {
    color: #846019;
    background: #fff3d4;
}
.table-footer {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 2px;
    font-size: 11px;
    color: #78828a;
}
.empty {
    text-align: center;
    padding: 60px 20px;
    color: #7b8790;
}
.form-page {
    max-width: 880px;
}
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
}
.wide {
    grid-column: 1/-1;
}
.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 24px;
    padding: 20px 0;
    border-top: 1px solid #dce1e5;
}
.account-note {
    display: grid;
    gap: 6px;
    color: #52686b;
    font-size: 12px;
    align-self: center;
}
.info {
    color: #5c6972;
    margin: 16px 0;
    line-height: 1.7;
}
.line-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr 38px;
    gap: 8px;
    margin-bottom: 10px;
}
.line-row button {
    padding: 5px;
}
.auth {
    display: grid;
    min-height: 100vh;
    place-items: center;
    border-top: 6px solid #008577;
}
.auth form {
    width: min(400px, calc(100vw - 40px));
    display: grid;
    gap: 22px;
}
.auth h1,
.auth h2 {
    margin: 0;
}
.auth h2 {
    color: #69727b;
    font-size: 16px;
}
#setup-note {
    font-size: 12px;
    line-height: 1.6;
    color: #68747d;
    margin: 0;
}
dialog {
    border: 1px solid #d1d9df;
    border-radius: 6px;
    padding: 24px;
    max-width: min(850px, 94vw);
    width: 850px;
    max-height: 90vh;
}
dialog::backdrop {
    background: #18262c66;
}
.dialog-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}
.dialog-heading h2 {
    margin: 0;
}
.dialog-heading button {
    font-size: 22px;
    padding: 0;
    width: 36px;
}
pre {
    background: #f1f4f6;
    padding: 18px;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    font-size: 12px;
    max-height: 50vh;
    overflow: auto;
}
dl {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 12px;
    font-size: 13px;
}
dt {
    color: #707d85;
}
dd {
    margin: 0;
    overflow-wrap: anywhere;
}
#notice {
    position: fixed;
    bottom: 24px;
    right: 24px;
    max-width: min(540px, 90vw);
    padding: 16px 22px;
    background: #193f38;
    color: #fff;
    box-shadow: 0 4px 20px #0002;
    border-radius: 5px;
    z-index: 10;
    line-height: 1.5;
}
#notice.error {
    background: #8f3026;
}
output {
    display: block;
    white-space: pre-wrap;
    line-height: 1.6;
}
button.link {
    color: #007f73;
    background: transparent;
    border: 0;
    padding: 3px 8px;
}
[hidden] {
    display: none !important;
}
@media (max-width: 900px) {
    #shell {
        grid-template-columns: 180px minmax(0, 1fr);
    }
    main {
        padding: 24px 18px;
    }
    .metrics > div {
        padding: 18px 12px;
    }
    .metrics strong {
        font-size: 25px;
    }
    .line-row {
        grid-template-columns: 1fr 1fr;
    }
    .form-grid {
        gap: 16px;
    }
}
@media (max-width: 620px) {
    #shell {
        display: block;
    }
    aside {
        padding: 14px;
        border-right: 0;
        border-bottom: 1px solid #ddd;
    }
    .brand {
        margin: 0 0 14px;
    }
    .brand strong {
        font-size: 18px;
    }
    .brand span {
        display: inline;
        margin-left: 10px;
    }
    .brand > img {
        width: 28px;
        height: 28px;
    }
    .nav-label {
        display: none;
    }
    nav {
        grid-template-columns: 1fr 1fr;
        gap: 3px;
    }
    nav button {
        font-size: 12px;
        padding: 8px;
    }
    .aside-bottom {
        padding: 10px 0 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    .aside-bottom button {
        padding: 4px 10px;
        min-height: 30px;
    }
    main {
        padding: 22px 14px;
    }
    h1 {
        font-size: 21px;
    }
    header {
        margin-bottom: 20px;
    }
    .metrics {
        grid-template-columns: 1fr 1fr;
    }
    .metrics > div {
        border-bottom: 1px solid #e0e4e8;
    }
    .form-grid {
        grid-template-columns: 1fr;
    }
    .wide {
        grid-column: auto;
    }
    .toolbar select {
        width: 160px;
    }
    .table-footer {
        font-size: 10px;
    }
    dl {
        grid-template-columns: 105px 1fr;
    }
}
/* Integration workspace */
button:focus-visible,
a:focus-visible,
summary:focus-visible {
    outline: 2px solid #1b9f8e;
    outline-offset: 3px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.queue-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 22px;
}

.freshness {
    color: #5f6d75;
    font-size: 12px;
}

aside {
    background: #182a2d;
    border-right-color: #203a3d;
    color: #f6faf9;
}

.brand span,
.aside-bottom,
.nav-label {
    color: #b4c7c7;
}
nav button {
    color: #e4eeee;
}
nav button img {
    filter: brightness(0) invert(1);
    opacity: 0.8;
}
nav button:hover,
nav button.active {
    background: #264746;
    color: #fff;
}
nav button.active {
    border-left-color: #64c7b6;
}
.aside-bottom button {
    color: #e4eeee;
    background: #213a3c;
    border-color: #3d595a;
}
.aside-bottom button:hover {
    background: #294b4b;
}
header {
    border-bottom: 1px solid #dde4e6;
    padding-bottom: 18px;
    margin-bottom: 20px;
}
main {
    width: 100%;
    max-width: 1680px;
}

.tabs {
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 6px;
    border-bottom: 1px solid #dce3e6;
    margin-bottom: 20px;
}

.tabs button {
    border: 0;
    border-bottom: 2px solid transparent;
    border-radius: 4px 4px 0 0;
    background: transparent;
    color: #5b6870;
    font-weight: 600;
    margin-bottom: -1px;
}

.tabs button[aria-pressed="true"] {
    background: #e5f1ee;
    border-bottom-color: #007a6d;
    color: #005d52;
}

nav button,
.primary,
#refresh,
#refresh-imports {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
}

nav button {
    justify-content: flex-start;
}
.icon {
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
}
.primary .icon {
    filter: brightness(0) invert(1);
}
.mono {
    font-variant-numeric: tabular-nums;
}
.table-scroll {
    position: relative;
    border-radius: 6px 6px 0 0;
}
.table-scroll table {
    min-width: 710px;
}
.table-footer {
    align-items: center;
}
.table-footer small {
    display: block;
    margin-top: 4px;
}
.pagination {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}
.pagination button {
    min-width: 33px;
    min-height: 32px;
    padding: 3px 8px;
    font-size: 17px;
}
.inline-error {
    margin-bottom: 12px;
    padding: 12px;
    border-left: 3px solid #ab4533;
    background: #fff0ed;
    color: #863023;
}
.error-help {
    padding: 12px;
    background: #fff3e9;
    border-left: 3px solid #b76c32;
    line-height: 1.55;
}
.error-help p {
    margin: 4px 0;
}
.error-help details {
    margin-top: 8px;
}
.error-help pre {
    max-height: 180px;
}
.badge.KUYRUGA_ALINMADI,
.badge.KAPALI,
.badge.ADAPTOR_BEKLIYOR {
    background: #fbeee0;
    color: #793f19;
}
.lookup-submit {
    margin-top: 16px;
}

.import-check { width: 48px; }
.import-check input { margin: 0; }
.badge.SECIM_BEKLIYOR { background: #e3f2ef; color: #006054; }
#selected-count { flex: 1; min-width: 70px; color: #52686b; }
.line-row {
    align-items: end;
}
#detail .form-actions:empty {
    display: none;
}
#connection-result:not(:empty) {
    padding: 14px;
    background: #e3f2ef;
}

@media (max-width: 620px) {
    #queue-view table {
        min-width: 0;
    }
    #queue-view tr > :is(:nth-child(1), :nth-child(3), :nth-child(5), :nth-child(6)) {
        display: none;
    }
    #queue-view th,
    #queue-view td {
        padding-inline: 8px;
    }
    #queue-view td[colspan] {
        display: table-cell;
    }
    .queue-actions {
        align-items: flex-start;
    }
    .tabs {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
    .marwiz #import-types {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    .tabs button {
        padding-inline: 6px;
    }
    .toolbar input {
        flex-basis: 100%;
    }
    .toolbar select {
        flex: 1;
    }
    .table-footer {
        align-items: flex-start;
    }
    .pagination {
        gap: 5px;
    }
}
