.me-main-content {
    margin-top: 18px;
    margin-bottom: 120px;
}

.me-shell {
    max-width: 1480px;
    margin: 0 auto;
    padding: 0 20px 28px;
}

.me-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 12px;
    background: rgba(16, 21, 31, 0.55);
    backdrop-filter: blur(4px);
}

.me-brand {
    color: #fff;
    font-weight: 800;
    letter-spacing: 0.2px;
    margin-right: 6px;
}

.me-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.me-nav a,
.me-nav-link {
    padding: 7px 11px;
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 8px;
    color: #e7f1ff;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.08);
    font-weight: 700;
}

.me-nav a.active {
    background: #1f7ae0;
    border-color: #1f7ae0;
    color: #fff;
}

.me-card {
    background: rgba(18, 23, 32, 0.66);
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 12px;
    color: #f4f6fa;
}

.me-card h1,
.me-card h2,
.me-card h3,
.me-card p {
    color: #fff;
}

.me-card h1,
.me-card h2,
.me-card h3 {
    margin-top: 0;
}

.me-row,
.me-toolbar-row,
.me-filter-row,
.me-actions-row,
.me-badge-row,
.me-section-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.me-section-head {
    justify-content: space-between;
    margin-bottom: 10px;
}

.me-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.me-input,
.me-select,
.me-textarea {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #7f8ea0;
    border-radius: 8px;
    padding: 9px 11px;
    font-size: 14px;
    background: #ffffff;
    color: #1f2e3c;
}

.me-label {
    display: grid;
    gap: 6px;
    font-weight: 700;
    color: #ecf2f8;
}

.me-btn {
    border: 1px solid #1f7ae0;
    background: #1f7ae0;
    color: #fff;
    border-radius: 8px;
    padding: 8px 12px;
    font-weight: 700;
    cursor: pointer;
}

.me-btn.alt {
    background: #fff;
    color: #1f7ae0;
}

.me-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.me-link-btn {
    border: 0;
    background: transparent;
    color: #1f7ae0;
    cursor: pointer;
    font-weight: 700;
}

.me-status {
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 8px;
    background: rgba(219, 231, 246, 0.94);
    color: #203142;
}

.me-status.error {
    background: rgba(255, 226, 226, 0.95);
    color: #7b1e1e;
}

.me-status.success {
    background: rgba(222, 244, 228, 0.95);
    color: #1f5b2d;
}

.me-table-wrap {
    overflow: auto;
}

.me-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
    background: #fff;
    color: #1f2e3c;
    border-radius: 10px;
    overflow: hidden;
}

.me-table th,
.me-table td {
    text-align: left;
    border-bottom: 1px solid #e4eaf1;
    padding: 9px 10px;
    vertical-align: middle;
}

.me-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 12px;
}

.me-item-card {
    border: 1px solid rgba(255, 255, 255, 0.23);
    border-radius: 10px;
    padding: 11px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}

.me-item-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 9px 16px rgba(10, 15, 26, 0.32);
    border-color: rgba(255, 255, 255, 0.42);
}

.me-item-head {
    display: flex;
    align-items: center;
    gap: 10px;
}

.me-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(145, 165, 190, 0.95);
}

.me-small {
    color: #d8e2f0;
    font-size: 12px;
}

.me-code,
.me-storage-code {
    font-family: Consolas, monospace;
    font-size: 12px;
    word-break: break-all;
}

.me-search-shell,
.me-search-stage {
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 14px;
    padding: 14px;
    background: linear-gradient(180deg, rgba(15, 22, 33, 0.62), rgba(12, 18, 28, 0.48));
}

.me-hero-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: end;
    background: linear-gradient(135deg, rgba(16, 24, 37, 0.92), rgba(23, 79, 146, 0.66));
}

.me-kicker {
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #acd2ff;
}

.me-hero-copy h1 {
    margin-bottom: 8px;
}

.me-toolbar-row {
    margin-bottom: 14px;
}

.me-storage-hero {
    margin-top: 8px;
}

.me-storage-hero-card {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 14px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.14), rgba(31, 122, 224, 0.22));
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.me-storage-avatar {
    width: 74px;
    height: 74px;
    border-radius: 18px;
    object-fit: cover;
    background: #fff;
    box-shadow: 0 8px 20px rgba(10, 15, 26, 0.25);
}

.me-storage-copy h3,
.me-storage-copy p {
    margin: 0;
}

.me-storage-copy p + p {
    margin-top: 4px;
}

.me-search-card {
    overflow: visible;
}

.me-search-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
}

.me-search-summary {
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
    color: #d7ebff;
    font-weight: 700;
    white-space: nowrap;
}

.me-search-bar-wrap {
    position: relative;
}

.me-search-inline {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
}

.me-search-input {
    padding: 12px 14px;
    font-size: 15px;
}

.me-search-results {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 30;
    display: none;
    max-height: 360px;
    overflow-y: auto;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(9, 16, 27, 0.26);
    border: 1px solid rgba(36, 63, 92, 0.14);
}

.me-search-results.open {
    display: block;
}

.me-search-result,
.me-search-empty {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 0;
    border-bottom: 1px solid #edf2f7;
    background: #fff;
    text-align: left;
}

.me-search-result {
    cursor: pointer;
}

.me-search-result:hover {
    background: #f7fbff;
}

.me-search-result:last-child,
.me-search-empty:last-child {
    border-bottom: 0;
}

.me-search-result-image {
    width: 38px;
    height: 38px;
    object-fit: contain;
    flex: 0 0 auto;
}

.me-search-result-copy {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.me-search-result-title {
    color: #162333;
    font-weight: 700;
}

.me-search-result-subtitle,
.me-search-empty {
    color: #4c6077;
    font-size: 13px;
}

.me-search-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #e6f2ff;
    font-weight: 700;
}

.me-product-grid {
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 18px;
    padding: 18px 0 0;
}

.me-product-card {
    max-width: none;
    min-width: 0;
    width: 100%;
    text-align: left;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(241, 247, 255, 0.98));
    box-shadow: 0 16px 30px rgba(10, 15, 26, 0.18);
}

.me-product-top {
    display: grid;
    grid-template-columns: 104px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
}

.me-product-image-shell {
    display: grid;
    place-items: center;
    min-height: 104px;
    border-radius: 16px;
    background: radial-gradient(circle at top, #ffffff, #dfeaf8);
    border: 1px solid #d8e5f4;
}

.me-product-image {
    max-width: 84px;
    max-height: 84px;
}

.me-product-title {
    margin: 8px 0 4px;
    color: #112133;
}

.me-product-subtitle {
    margin: 0;
    color: #5a6b80;
    font-size: 13px;
    line-height: 1.45;
}

.me-product-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 16px 0 12px;
}

.me-stat-card {
    padding: 10px 12px;
    border-radius: 14px;
    background: #eff5fb;
    border: 1px solid #d9e4f1;
}

.me-stat-card span {
    display: block;
    color: #57708a;
    font-size: 12px;
    margin-bottom: 4px;
}

.me-stat-card strong {
    color: #112133;
    font-size: 18px;
}

.me-product-details {
    margin: 12px 0;
    color: #24364a;
}

.me-product-details summary {
    cursor: pointer;
    font-weight: 700;
}

.me-product-details p {
    margin: 8px 0 0;
    color: #31465c;
}

.me-product-actions {
    display: grid;
    grid-template-columns: minmax(0, 110px) minmax(0, 1fr);
    gap: 10px;
    align-items: center;
}

.me-amount-input {
    text-align: center;
}

.me-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.me-badge.known {
    background: rgba(45, 168, 88, 0.14);
    color: #166534;
}

.me-badge.unknown {
    background: rgba(185, 28, 28, 0.14);
    color: #991b1b;
}

.me-badge.neutral {
    background: rgba(31, 122, 224, 0.12);
    color: #1558a3;
}

.me-badge.frozen {
    background: rgba(255, 196, 0, 0.2);
    color: #7a5600;
}

.me-empty-state {
    padding: 26px;
    border-radius: 16px;
    text-align: center;
    color: #d7e7f7;
    background: rgba(255, 255, 255, 0.08);
    border: 1px dashed rgba(255, 255, 255, 0.18);
}

@media (max-width: 980px) {
    .me-hero-card,
    .me-search-head,
    .me-section-head {
        grid-template-columns: 1fr;
        display: grid;
    }

    .me-product-top {
        grid-template-columns: 1fr;
    }

    .me-product-image-shell {
        min-height: 120px;
    }
}

@media (max-width: 820px) {
    .me-grid-2 {
        grid-template-columns: 1fr;
    }

    .me-search-inline,
    .me-product-actions,
    .me-product-stats {
        grid-template-columns: 1fr;
    }

    .me-search-summary {
        white-space: normal;
    }
}
.me-header-shell {
    display: grid;
    gap: 12px;
    margin-bottom: 16px;
}

.me-header--primary {
    justify-content: space-between;
}

.me-header--tools {
    align-items: end;
    justify-content: space-between;
    gap: 14px;
}

.me-brand-wrap {
    display: grid;
    gap: 4px;
}

.me-brand-eyebrow {
    margin: 0;
    color: #acd2ff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.me-header-search-shell {
    flex: 1 1 420px;
    min-width: 260px;
}

.me-header-field {
    display: grid;
    gap: 8px;
    color: #eef6ff;
    font-weight: 700;
    min-width: 180px;
}

.me-header-field span {
    font-size: 12px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #b7d8ff;
}

.me-header-field--search .me-search-bar-wrap {
    position: relative;
}

.me-header-field--storage {
    flex: 0 0 290px;
}

.me-header-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.me-selection-shell {
    position: relative;
    flex: 0 0 auto;
}

.me-selection-toggle {
    min-width: 190px;
    justify-content: space-between;
    gap: 14px;
}

.me-selection-toggle.active {
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.me-selection-count {
    min-width: 28px;
    height: 28px;
    padding: 0 8px;
    border-radius: 999px;
    background: rgba(9, 16, 27, 0.22);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.me-selection-panel {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: min(520px, calc(100vw - 48px));
    max-height: 72vh;
    overflow: auto;
    z-index: 40;
    padding: 16px;
    border-radius: 16px;
    background: rgba(10, 15, 24, 0.97);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.38);
}

.me-selection-panel-head p {
    margin: 4px 0 0;
    color: #c5d6ea;
    font-size: 13px;
}

.me-selection-list,
.me-selection-items {
    display: grid;
    gap: 12px;
    margin-top: 12px;
}

.me-selection-empty {
    display: grid;
    gap: 8px;
    padding: 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: #eff6ff;
}

.me-selection-empty p {
    margin: 0;
    color: #c7d7ea;
}

.me-selection-row {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.me-selection-image {
    width: 54px;
    height: 54px;
    object-fit: contain;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.92);
    padding: 6px;
}

.me-selection-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.me-selection-copy strong,
.me-selection-copy span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.me-selection-copy span {
    color: #c7d7ea;
    font-size: 13px;
}

.me-selection-controls {
    display: grid;
    gap: 8px;
    justify-items: end;
}

.me-selection-input {
    width: 110px;
}

.me-selection-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.me-selection-summary {
    display: grid;
    gap: 4px;
    color: #eff6ff;
}

.me-selection-summary span {
    color: #c7d7ea;
    font-size: 13px;
}

.me-selection-footer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.me-product-card.is-limited {
    border-color: rgba(255, 255, 255, 0.1);
    opacity: 0.92;
}

.me-product-stock-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 14px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    color: #dfefff;
    font-weight: 700;
}

.me-product-stock-row strong {
    color: #ffffff;
}

.me-load-more-wrap {
    display: flex;
    justify-content: center;
    padding-top: 18px;
}

#loadMoreBtn[hidden],
#meSelectionPanel[hidden] {
    display: none !important;
}

@media (max-width: 980px) {
    .me-header--tools {
        align-items: stretch;
    }

    .me-header-field--storage,
    .me-selection-shell,
    .me-header-actions {
        flex: 1 1 100%;
    }

    .me-selection-toggle {
        width: 100%;
    }

    .me-selection-panel {
        left: 0;
        right: auto;
        width: min(100%, calc(100vw - 40px));
    }
}

@media (max-width: 720px) {
    .me-selection-row {
        grid-template-columns: 1fr;
    }

    .me-selection-controls {
        justify-items: stretch;
    }

    .me-selection-input {
        width: 100%;
    }
}

.me-product-stats--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.me-product-card,
.me-product-card h3,
.me-product-card p,
.me-product-card summary,
.me-product-card .product-name,
.me-product-card .product-price,
.me-product-card .me-product-title,
.me-product-card .me-product-subtitle,
.me-product-card .me-stat-card span,
.me-product-card .me-stat-card strong,
.me-product-card .me-product-details,
.me-product-card .me-product-details p {
    color: #112133;
}

.me-product-card .me-badge.neutral {
    color: #1558a3;
}

.me-product-card .me-product-stock-row {
    background: #eff5fb;
    color: #24364a;
    border: 1px solid #d9e4f1;
}

.me-product-card .me-product-stock-row strong {
    color: #112133;
}

.me-status--inline {
    margin-top: 0;
    min-width: 260px;
}

.me-filter-row--inventory {
    align-items: stretch;
}

.me-filter-row--inventory > * {
    flex: 0 0 auto;
}

.me-filter-row--inventory .me-select,
.me-filter-row--inventory .me-btn,
.me-filter-row--inventory .me-search-summary,
.me-filter-row--inventory .me-storage-hero {
    min-height: 44px;
}

.me-storage-hero--inline {
    flex: 1 1 320px;
    margin-top: 0;
}

.me-storage-inline-card {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 7px 12px;
    border: 1px solid #d7e2ee;
    border-radius: 10px;
    background: #ffffff;
    color: #1f2e3c;
}

.me-storage-inline-card.is-empty {
    color: #5d7085;
}

.me-storage-inline-card.is-frozen {
    border-color: #f0cf72;
    background: #fff8dd;
}

.me-storage-avatar--inline {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    flex: 0 0 auto;
    box-shadow: none;
}

.me-storage-inline-copy {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    min-width: 0;
    color: #1f2e3c;
}

.me-storage-inline-copy strong {
    color: #102131;
    font-size: 14px;
}

.me-storage-inline-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #52667d;
    font-size: 12px;
}

.me-storage-inline-meta span {
    white-space: nowrap;
}

.me-search-summary,
.me-search-pill {
    background: #ffffff;
    color: #1f2e3c;
    border: 1px solid #d7e2ee;
    font-size: 12px;
    font-weight: 600;
}

.me-search-pill {
    margin-top: 10px;
}

.me-search-pill .me-link-btn {
    color: #1f2e3c;
}

.me-search-result-subtitle,
.me-search-empty {
    color: #33475d;
    font-size: 12px;
}

.me-product-grid {
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 14px;
    padding: 8px 0 0;
}

.me-product-card {
    display: flex;
    flex-direction: column;
    max-width: 220px;
    min-width: 0;
    width: 100%;
    min-height: 100%;
    margin: 0 auto;
    padding: 0;
    border: 1px solid #d8e0e8;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.me-product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.14);
}

.me-product-image-shell {
    display: grid;
    place-items: center;
    min-height: 132px;
    padding: 12px;
    border-bottom: 1px solid #edf2f7;
    border-radius: 0;
    background: #ffffff;
}

.me-product-image {
    width: 100%;
    height: 96px;
    max-width: 120px;
    max-height: 96px;
    object-fit: contain;
}

.me-product-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    padding: 12px;
}

.me-product-badges {
    min-height: 22px;
    margin-bottom: 6px;
}

.me-product-title {
    margin: 0;
    font-size: 15px;
    line-height: 1.3;
    min-height: 2.6em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.me-product-subtitle {
    margin: 6px 0 0;
    color: #42576d;
    font-size: 11px;
    line-height: 1.4;
    min-height: 1.4em;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

.me-product-meta-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 10px 0;
}

.me-product-meta {
    padding: 8px 9px;
    border: 1px solid #e1e9f1;
    border-radius: 8px;
    background: #f8fbff;
    text-align: left;
}

.me-product-meta span {
    display: block;
    margin-bottom: 2px;
    font-size: 10px;
    line-height: 1.2;
    letter-spacing: 0.04em;
    text-transform: lowercase;
    color: #64788f;
}

.me-product-meta strong {
    color: #132436;
    font-size: 15px;
    line-height: 1.2;
}

.me-product-details {
    margin: 10px 0;
    font-size: 12px;
}

.me-product-details summary {
    color: #1b3248;
    font-size: 12px;
}

.me-product-details p {
    font-size: 12px;
    line-height: 1.45;
}

.me-product-actions {
    margin-top: auto;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 8px;
}

.me-amount-input,
.me-product-actions .me-btn {
    min-height: 38px;
}

@media (max-width: 980px) {
    .me-filter-row--inventory > * {
        flex: 1 1 100%;
    }

    .me-status--inline {
        min-width: 100%;
    }
}

@media (max-width: 720px) {
    .me-product-grid {
        grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    }

    .me-product-card {
        max-width: none;
    }
}


.me-search-card--compact {
    padding: 12px 14px;
}

.me-search-card--compact .me-filter-row--inventory {
    gap: 12px;
    align-items: center;
}

.me-search-card--compact .me-storage-hero--inline {
    flex: 1 1 420px;
}

.me-search-card--compact #sortSelect {
    flex: 0 0 240px;
}

.me-page-inventory .me-card {
    background: rgba(14, 20, 30, 0.74);
}

.me-page-inventory .me-search-card {
    margin-bottom: 10px;
    position: relative;
    z-index: 1400;
}

.me-page-inventory .me-section-head {
    justify-content: center;
    margin-bottom: 14px;
}

.me-page-inventory .me-section-head > div {
    width: 100%;
    text-align: center;
}

.me-page-inventory .me-section-head h2,
.me-page-inventory .me-section-head p {
    text-align: center;
}

.me-page-inventory .me-section-head h2 {
    margin-bottom: 6px;
    font-size: 38px;
    line-height: 1.05;
}

.me-page-inventory .me-section-head p {
    margin: 0;
    color: #d0ddee;
    font-size: 14px;
}

.me-header--primary {
    gap: 14px;
}

.me-nav.me-top-nav {
    flex: 1 1 auto;
}

.me-nav-link,
.me-nav a {
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.me-header--tools {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px auto auto;
    gap: 12px;
    align-items: end;
}

.me-header-search-shell,
.me-header-field--storage,
.me-header-actions,
.me-selection-shell {
    min-width: 0;
}

.me-header-field span {
    margin-bottom: 2px;
    text-align: center;
}

.me-header-actions {
    align-self: end;
}

.me-selection-toggle {
    min-width: 170px;
}

.me-storage-inline-card {
    min-height: 48px;
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff, #f3f7fb);
}

.me-storage-inline-copy {
    justify-content: space-between;
}

.me-storage-inline-copy strong {
    font-size: 15px;
}

.me-storage-inline-meta {
    gap: 10px;
}

.me-storage-inline-meta span {
    position: relative;
}

.me-storage-inline-meta span + span::before {
    content: '?';
    margin-right: 10px;
    color: #9ab0c5;
}

.me-empty-state {
    display: grid;
    place-items: center;
    min-height: 220px;
    padding: 28px;
    border-radius: 18px;
    color: #f3f8ff;
    background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.04));
    border: 1px dashed rgba(214, 228, 245, 0.28);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}

.me-empty-state::before {
    content: 'Noch keine Treffer';
    display: block;
    font-size: 24px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
}

.me-product-grid {
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 14px;
    padding: 4px 0 0;
}

.me-product-card {
    align-self: start;
}

.me-product-title {
    text-align: center;
}

.me-product-subtitle {
    text-align: center;
}

.me-product-badges {
    justify-content: center;
}

.me-product-actions .me-btn {
    font-size: 13px;
}

.me-search-result-title {
    font-size: 13px;
    font-weight: 700;
    color: #101d2b !important;
}

.me-search-result-subtitle {
    color: #44586d !important;
    font-size: 11px;
    text-transform: none !important;
}

@media (max-width: 1180px) {
    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
    }

    .me-header-actions,
    .me-selection-shell {
        grid-column: span 1;
    }
}

@media (max-width: 900px) {
    .me-header--tools {
        grid-template-columns: 1fr;
    }

    .me-search-card--compact #sortSelect {
        flex: 1 1 100%;
    }

    .me-page-inventory .me-section-head h2 {
        font-size: 30px;
    }
}

.me-confirm-overlay {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.55);
    z-index: 10000;
}

.me-confirm-dialog {
    width: min(460px, 100%);
    padding: 22px;
    border-radius: 14px;
    background: #ffffff;
    color: #1f2e3c;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

.me-confirm-dialog h3 {
    margin: 0 0 10px;
    color: #132436;
    font-size: 22px;
    text-align: left;
}

.me-confirm-dialog p {
    margin: 0;
    color: #42576d;
    font-size: 14px;
    line-height: 1.5;
    text-align: left;
}

.me-confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.me-product-meta-list--single {
    grid-template-columns: minmax(0, 1fr);
}


.me-header--tools {
    display: grid;
    grid-template-columns: minmax(340px, 1.6fr) minmax(220px, 0.9fr) auto auto;
    gap: 14px;
    align-items: end;
}

.me-header-search-shell,
.me-header-field--storage,
.me-header-actions,
.me-selection-shell {
    align-self: stretch;
}

.me-header-field,
.me-header-search-shell {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.me-header-field span,
.me-brand-eyebrow {
    margin-bottom: 6px;
}

.me-header-field--search .me-search-bar-wrap,
.me-header-field--storage,
.me-header-actions,
.me-selection-shell {
    height: 100%;
}

.me-header-field--search .me-input,
.me-header-field--storage .me-select,
.me-header-actions .me-btn,
.me-selection-toggle {
    min-height: 46px;
    box-sizing: border-box;
}

.me-header-field--search .me-input,
.me-header-field--storage .me-select {
    border-radius: 10px;
}

.me-header-actions {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 10px;
    align-items: end;
}

.me-header-actions .me-btn {
    width: 100%;
    white-space: nowrap;
    padding: 0 14px;
}

.me-selection-shell {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.me-selection-toggle {
    width: 100%;
    padding: 0 16px;
    border-radius: 12px;
}

.me-selection-count {
    min-width: 30px;
    height: 30px;
}

.me-search-card--compact .me-filter-row--inventory {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 14px;
    align-items: stretch;
}

.me-search-card--compact .me-storage-hero--inline,
.me-search-card--compact #sortSelect {
    min-height: 46px;
}

.me-search-card--compact #sortSelect {
    width: 100%;
}

@media (max-width: 1180px) {
    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
    }

    .me-header-actions,
    .me-selection-shell {
        grid-column: span 1;
    }

    .me-header-actions {
        grid-auto-flow: row;
        grid-auto-rows: minmax(46px, auto);
    }
}

@media (max-width: 900px) {
    .me-search-card--compact .me-filter-row--inventory {
        grid-template-columns: 1fr;
    }
}

.me-header--tools {
    grid-template-columns: minmax(280px, 1fr) 200px 290px 150px;
}

.me-header-actions {
    grid-template-columns: repeat(3, minmax(86px, 1fr));
    grid-auto-flow: unset;
    grid-auto-columns: unset;
}

.me-header-actions .me-btn {
    font-size: 12px;
    padding: 0 10px;
}

.me-selection-toggle {
    min-width: 150px;
}

@media (max-width: 1260px) {
    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) 220px;
        grid-template-areas:
            'search storage'
            'actions selection';
    }

    .me-header-search-shell { grid-area: search; }
    .me-header-field--storage { grid-area: storage; }
    .me-header-actions { grid-area: actions; }
    .me-selection-shell { grid-area: selection; }
}

.me-main-content {
    width: min(96vw, 1760px);
}

.me-shell {
    max-width: 1720px;
    padding: 0 12px 28px;
}

.me-header-shell {
    gap: 10px;
}

.me-header {
    padding: 10px 12px;
    border-radius: 10px;
}

.me-header--primary {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
}

.me-brand-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
}

.me-brand {
    font-size: 28px;
    line-height: 1;
}

.me-nav.me-top-nav {
    justify-content: center;
}

.me-nav-link,
.me-nav a,
.me-btn {
    min-height: 42px;
    border-radius: 9px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.me-nav-link,
.me-nav a {
    background: rgba(255,255,255,0.06);
}

.me-nav-link--shop {
    background: rgba(255,255,255,0.08);
}

.me-header--tools {
    grid-template-columns: minmax(360px, 1.25fr) 240px 240px 170px;
    gap: 12px;
}

.me-header-field span {
    text-align: left;
    font-size: 11px;
}

.me-header-field--search .me-input,
.me-header-field--storage .me-select,
.me-selection-toggle,
.me-header-actions .me-btn {
    min-height: 42px;
}

.me-header-actions {
    grid-template-columns: repeat(2, minmax(110px, 1fr));
    gap: 8px;
}

.me-header-actions .me-btn,
.me-selection-toggle {
    background: #1f7ae0;
    border-color: #1f7ae0;
    color: #fff;
    box-shadow: none;
}

.me-header-actions .me-btn:hover,
.me-selection-toggle:hover {
    background: #1866bc;
    border-color: #1866bc;
}

.me-selection-count {
    background: rgba(10, 21, 36, 0.28);
    color: #fff;
}

.me-card {
    border-radius: 10px;
}

.me-search-card--compact .me-filter-row--inventory {
    grid-template-columns: minmax(0, 1fr) 160px;
}

.me-empty-state {
    min-height: 260px;
}

@media (max-width: 1380px) {
    .me-header--primary {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .me-brand-wrap {
        align-items: center;
    }

    .me-nav.me-top-nav {
        justify-content: center;
    }

    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) 220px 220px 160px;
    }
}

@media (max-width: 1180px) {
    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) 220px;
        grid-template-areas:
            'search storage'
            'actions selection';
    }
}

.me-header--tools {
    grid-template-columns: minmax(360px, 1.35fr) 240px 220px 150px;
    align-items: end;
}

.me-header-field span {
    font-size: 11px;
    letter-spacing: 0.08em;
    color: #c6ddfb;
}

.me-header-actions {
    grid-template-columns: repeat(2, minmax(100px, 1fr));
}

.me-header-actions .me-btn {
    font-size: 13px;
    font-weight: 700;
}

.me-selection-shell {
    position: relative;
    min-width: 0;
}

.me-selection-toggle {
    min-width: 0;
    gap: 8px;
    justify-content: space-between;
    padding: 0 12px;
    font-size: 13px;
    font-weight: 700;
}

.me-selection-toggle > span:first-child {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.me-selection-count {
    flex: 0 0 auto;
    min-width: 28px;
    height: 28px;
    font-size: 12px;
}

.me-selection-panel {
    top: calc(100% + 12px);
    right: 0;
    width: min(460px, calc(100vw - 40px));
}

.me-storage-inline-card,
.me-header-field--storage .me-select,
.me-header-field--search .me-input,
.me-header-actions .me-btn,
.me-selection-toggle {
    box-shadow: none;
}

.me-storage-inline-card,
.me-header-field--storage .me-select,
.me-header-field--search .me-input {
    font-size: 13px;
}

@media (max-width: 1380px) {
    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) 220px 220px 140px;
    }
}

@media (max-width: 1180px) {
    .me-header--tools {
        grid-template-columns: minmax(0, 1fr) 220px;
    }
}

.me-page-inventory .me-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
}

.me-page-inventory .me-header-shell {
    margin-bottom: 6px;
}

.me-selection-shell {
    position: static;
}

.me-selection-panel {
    position: static;
    width: 100%;
    max-height: none;
    margin-top: 12px;
    padding: 14px;
    border-radius: 14px;
    background: rgba(10, 15, 24, 0.94);
    box-shadow: none;
}

.me-selection-panel[hidden] {
    display: none !important;
}

.me-selection-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.me-selection-panel-head strong {
    color: #ffffff;
    font-size: 20px;
}

.me-selection-panel-head p {
    margin: 4px 0 0;
    color: #d7e4f3;
    font-size: 14px;
}

.me-selection-list {
    margin-top: 14px;
}

.me-selection-items {
    gap: 10px;
}

.me-selection-row {
    grid-template-columns: 64px minmax(0, 1fr) 122px;
    gap: 14px;
    padding: 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
}

.me-selection-image {
    width: 64px;
    height: 64px;
}

.me-selection-copy strong {
    color: #ffffff;
    font-size: 18px;
    line-height: 1.2;
}

.me-selection-copy span {
    color: #cfdded;
    font-size: 14px;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
}

.me-selection-controls {
    align-self: center;
    justify-items: stretch;
}

.me-selection-input {
    width: 100%;
    min-height: 42px;
}

.me-selection-remove {
    min-height: 42px;
    width: 100%;
}

.me-selection-footer {
    margin-top: 14px;
    padding-top: 14px;
}

.me-selection-summary strong {
    font-size: 18px;
}

.me-selection-summary span {
    font-size: 14px;
}

.me-selection-footer-actions {
    justify-content: flex-end;
}

.me-selection-footer-actions .me-btn {
    min-height: 42px;
}

.me-selection-toggle.active {
    background: #1866bc;
    border-color: #1866bc;
}

.me-storage-inline-meta span + span::before {
    content: '?';
}

@media (max-width: 900px) {
    .me-selection-row {
        grid-template-columns: 1fr;
    }
}

.me-selection-shell.is-open {
    grid-column: 1 / -1;
}

.me-selection-shell.is-open .me-selection-panel {
    position: static !important;
    width: 100% !important;
    max-width: none;
    margin-top: 12px;
}

.me-page-inventory .me-product-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

@media (max-width: 1700px) {
    .me-page-inventory .me-product-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
}

@media (max-width: 1450px) {
    .me-page-inventory .me-product-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 1180px) {
    .me-page-inventory .me-product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .me-page-inventory .me-product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .me-page-inventory .me-product-grid {
        grid-template-columns: 1fr;
    }
}

.me-search-bar-wrap {
    isolation: isolate;
}

.me-search-results {
    z-index: 500;
    background: #ffffff;
    border: 1px solid #d7e2ee;
    box-shadow: 0 18px 38px rgba(7, 18, 31, 0.34);
}

.me-search-results--floating {
    position: fixed !important;
    z-index: 20000 !important;
}

.me-search-result,
.me-search-empty {
    position: relative;
    z-index: 1;
    background: #ffffff;
}

.me-search-result-copy {
    gap: 2px;
}

.me-search-result-title {
    font-size: 12px;
    font-weight: 700;
    line-height: 1.15;
    text-transform: none !important;
}

.me-search-result-subtitle {
    font-size: 11px;
    font-weight: 500;
    color: #5b6f84 !important;
    text-transform: lowercase !important;
}


.me-page-setup .me-setup-shell {
    max-width: 1120px;
}

.me-page-setup .me-card {
    border-radius: 18px;
}

.me-setup-intro-card {
    display: grid;
    gap: 18px;
    justify-items: center;
    text-align: center;
}

.me-setup-intro-copy {
    display: grid;
    justify-items: center;
    text-align: center;
}

.me-setup-intro-copy h1 {
    margin: 8px 0 8px;
    font-size: 38px;
    line-height: 1.05;
}

.me-setup-intro-copy p {
    margin: 0 auto;
    max-width: 760px;
    color: #d6e2f0;
}

.me-stepper {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.me-stepper li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid rgba(173, 197, 221, 0.22);
    border-radius: 14px;
    background: rgba(9, 20, 34, 0.44);
    color: #dce8f6;
}

.me-stepper li.active {
    border-color: rgba(67, 145, 255, 0.65);
    background: linear-gradient(180deg, rgba(36, 93, 173, 0.42), rgba(15, 33, 58, 0.7));
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.me-stepper li.done {
    border-color: rgba(92, 198, 138, 0.3);
    background: linear-gradient(180deg, rgba(24, 70, 52, 0.45), rgba(10, 24, 21, 0.7));
}

.me-stepper-index {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    color: #ffffff;
    font-size: 14px;
    font-weight: 800;
    flex: 0 0 auto;
}

.me-stepper-copy {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.me-stepper-copy strong {
    color: #ffffff;
    font-size: 15px;
    line-height: 1.15;
}

.me-stepper-copy small {
    color: #aec3da;
    font-size: 12px;
    line-height: 1.2;
}

.me-setup-panel {
    padding: 28px;
}

.me-section-head--left {
    display: block;
}

.me-section-head--left,
.me-section-head--left h2,
.me-section-head--left p {
    text-align: left !important;
}

.me-section-head--left h2 {
    margin-bottom: 6px;
}

.me-section-head--left p {
    margin: 0 0 18px;
    color: #d0ddeb;
}

.me-setup-grid {
    gap: 16px;
}

.me-setup-subgrid {
    margin-top: 16px;
}

.me-setup-sidebox {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    min-height: 100%;
    padding: 18px;
    border: 1px solid rgba(183, 202, 221, 0.22);
    border-radius: 14px;
    background: rgba(255,255,255,0.05);
}

.me-page-setup .me-grid-2 {
    gap: 16px;
}

.me-setup-sidebox strong {
    color: #ffffff;
    font-size: 18px;
}

.me-setup-actions {
    margin-top: 18px;
    gap: 12px;
    flex-wrap: wrap;
}

.me-setup-review {
    display: grid;
    gap: 12px;
    padding: 18px;
    border: 1px solid rgba(183, 202, 221, 0.22);
    border-radius: 14px;
    background: rgba(255,255,255,0.05);
}

.me-setup-review div {
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(8, 18, 31, 0.45);
    color: #e6effa;
}

.me-setup-nav-card {
    background: rgba(10, 19, 31, 0.92);
    backdrop-filter: blur(12px);
}

.me-wizard-nav {
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.me-wizard-nav .me-btn {
    min-width: 150px;
}

@media (max-width: 980px) {
    .me-stepper {
        grid-template-columns: 1fr;
    }

    .me-page-setup .me-grid-2 {
        grid-template-columns: 1fr;
    }

    .me-setup-intro-copy h1 {
        font-size: 32px;
    }
}

.me-password-wrap {
    position: relative;
}

.me-password-input {
    position: relative;
    z-index: 1;
    padding-right: 52px;
    font-family: Arial, Helvetica, sans-serif;
    background: #ffffff;
    color: #12263a !important;
    -webkit-text-fill-color: #12263a;
}

.me-password-input:focus {
    color: #12263a !important;
    -webkit-text-fill-color: #12263a;
}

.me-password-input.is-masked {
    color: transparent;
    caret-color: #12263a;
    -webkit-text-fill-color: transparent;
}

.me-password-mask {
    position: absolute;
    left: 14px;
    right: 52px;
    top: 50%;
    z-index: 3;
    transform: translateY(-50%);
    overflow: hidden;
    color: #081521;
    font-size: 18px;
    font-weight: 900;
    line-height: 1;
    letter-spacing: 0.12em;
    text-shadow: none;
    white-space: nowrap;
    pointer-events: none;
}

.me-password-mask.is-hidden {
    display: none;
}

.me-password-toggle {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 10px;
    background-color: transparent;
    background-position: center;
    background-repeat: no-repeat;
    background-size: 18px 18px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2338516a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 12s3.5-6 10-6 10 6 10 6-3.5 6-10 6S2 12 2 12Z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
    appearance: none;
    cursor: pointer;
}

.me-password-toggle.is-visible {
    background-color: rgba(31, 122, 224, 0.12);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f7ae0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 12s3.5-6 10-6 10 6 10 6-3.5 6-10 6S2 12 2 12Z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E");
}

.me-input.is-readonly {
    background: #eef3f8;
    color: #5b6f82;
    cursor: not-allowed;
}

.me-select.is-readonly,
.me-btn.is-readonly,
.me-textarea.is-readonly {
    opacity: 0.6;
    cursor: not-allowed;
}

#assignItemSearchInput,
#catNameInput,
#catColorInput,
#storageSelect,
#assignCategorySelect {
    color: #12263a !important;
    -webkit-text-fill-color: #12263a !important;
    caret-color: #12263a;
    background: #ffffff;
}

#assignItemSearchInput::placeholder,
#catNameInput::placeholder,
#catColorInput::placeholder {
    color: #5d7085;
    -webkit-text-fill-color: #5d7085;
}

body.me-page-sticky-footer {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.me-main-content--fill {
    flex: 1 0 auto;
}

body.me-page-sticky-footer custom-footer2 {
    display: block;
    margin-top: auto;
}

.me-page-inventory #meHeaderHost,
.me-page-inventory .me-header-shell,
.me-page-inventory .me-search-card,
.me-page-inventory .me-header--tools,
.me-page-inventory .me-header-field--search,
.me-page-inventory .me-header-field--search .me-search-bar-wrap {
    position: relative;
}

.me-page-inventory #meHeaderHost,
.me-page-inventory .me-header-shell {
    z-index: 1300;
}

.me-page-inventory .me-header-field--search,
.me-page-inventory .me-header-field--search .me-search-bar-wrap {
    z-index: 1200;
}

.me-page-inventory .me-search-results {
    z-index: 2000;
}

.me-page-inventory #storageHero,
.me-page-inventory .me-filter-row--inventory,
.me-page-inventory .me-storage-hero,
.me-page-inventory .me-storage-inline-card {
    position: relative;
    z-index: 1;
}
