/* Admin-specific styles extracted from common.css on 2026-04-05. */

        .admin-tools {
            position: relative;
            z-index: 70;
        }

.admin-tab-row {
            display: flex;
            align-items: flex-end;
            gap: 0;
            margin-bottom: 12px;
            position: relative;
            z-index: 40;
            padding: 2px 0 1px;
            background: transparent;
            border-bottom: 1px solid rgba(162, 184, 201, 0.55);
            overflow-x: auto;
            overflow-y: visible;
        }

.admin-tab-row.survey-settings-tab-row {
            align-items: center;
            justify-content: space-between;
            overflow: visible;
        }

.admin-section-tab-btn {
            min-width: fit-content;
            width: auto;
            justify-content: center;
            padding: 2px 16px 11px;
            margin-bottom: -1px;
            white-space: nowrap;
            overflow: visible;
            text-overflow: clip;
            border: none;
            border-radius: 0;
            background: transparent;
            color: var(--muted);
            box-shadow: none;
            font-size: 0.92rem;
            font-weight: 800;
            min-height: 36px;
            transition: color 0.18s ease, transform 0.18s ease;
        }

        .admin-section-tab-btn:hover,
        .admin-section-tab-btn:focus-visible {
            border: none;
            background: transparent;
            color: var(--accent);
            box-shadow: none;
            transform: translateY(-1px);
        }

        .admin-section-tab-btn.active {
            background: transparent;
            color: var(--primary);
            border: none;
            box-shadow: none;
            position: relative;
        }

        .admin-section-tab-btn.active::after {
            content: "";
            position: absolute;
            left: 12px;
            right: 12px;
            bottom: 0;
            height: 2px;
            background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
            border-radius: 999px;
        }

        .admin-tab-panel[hidden] {
            display: none !important;
        }

        @media (max-width: 1280px) {
            .admin-tab-row {
                gap: 0;
            }
        }

        @media (max-width: 760px) {
            .admin-tab-row {
                display: grid;
                grid-template-columns: repeat(2, minmax(0, 1fr));
                gap: 8px;
                border-bottom: none;
                overflow: visible;
            }

            .admin-section-tab-btn {
                min-width: 0;
                width: 100%;
                padding: 10px 12px;
                margin-bottom: 0;
                border: 1px solid rgba(162, 184, 201, 0.55);
                border-radius: 14px;
                background: #fff;
                font-size: 0.8rem;
                white-space: normal;
                line-height: 1.35;
            }

            .admin-section-tab-btn.active::after {
                left: 10px;
                right: 10px;
                bottom: 6px;
            }

            .branding-settings-grid {
                grid-template-columns: 1fr;
            }

            .official-document-settings-grid {
                grid-template-columns: 1fr;
            }

            .branding-settings-span-2 {
                grid-column: auto;
            }

            .branding-preview-grid {
                grid-template-columns: 1fr;
            }
        }

        @media (max-width: 760px) {
            #admin-app-list,
            #admin-slot-list,
            #admin-history-list {
                min-width: 0 !important;
                width: 100%;
                table-layout: fixed;
            }

            #admin-app-list colgroup,
            #admin-slot-list colgroup {
                display: none;
            }

            #admin-app-wrap,
            #admin-slot-wrap,
            #admin-history-wrap {
                overflow-x: hidden;
            }

            #admin-app-list th,
            #admin-app-list td,
            #admin-slot-list th,
            #admin-slot-list td,
            #admin-history-list th,
            #admin-history-list td {
                padding: 8px 6px;
                font-size: 0.7rem;
                white-space: normal;
                word-break: break-word;
            }

            #admin-app-list th:last-child,
            #admin-app-list td:last-child {
                width: 88px;
            }

            #admin-slot-list th:nth-child(1),
            #admin-slot-list td:nth-child(1) {
                width: 36px;
                min-width: 36px;
            }

            #admin-slot-list th:nth-child(2),
            #admin-slot-list td:nth-child(2) {
                width: 78px;
            }

            #admin-slot-list th:nth-child(4),
            #admin-slot-list td:nth-child(4),
            #admin-slot-list th:nth-child(5),
            #admin-slot-list td:nth-child(5) {
                display: none;
            }

            #admin-slot-list th:nth-child(6),
            #admin-slot-list td:nth-child(6) {
                width: 58px;
            }

            #admin-history-list th:nth-child(1),
            #admin-history-list td:nth-child(1) {
                width: 88px;
            }

            #admin-history-list th:nth-child(2),
            #admin-history-list td:nth-child(2) {
                width: 66px;
            }

            #admin-history-list th:nth-child(3),
            #admin-history-list td:nth-child(3) {
                display: none;
            }

            .member-master-detail,
            .member-master-detail.store-master-management {
                grid-template-columns: 1fr;
                gap: 12px;
            }

            .member-master-list {
                position: static;
            }

            .member-list-header,
            .member-list-table-row {
                grid-template-columns: 38px minmax(0, 1fr) 104px;
                padding-right: 0;
            }

            .member-list-header .member-list-head-cell:nth-child(3),
            .member-list-header .member-list-head-cell:nth-child(4),
            .member-list-table-row .member-list-cell:nth-child(3),
            .member-list-table-row .member-list-cell:nth-child(4) {
                display: none;
            }

            .member-list-head-cell,
            .member-list-cell {
                padding: 10px 8px;
            }

            .member-list-status {
                min-width: 60px;
                padding-inline: 8px;
                font-size: 0.58rem;
            }

            .store-master-summary-grid,
            .store-master-filterbar {
                grid-template-columns: 1fr;
            }

            .store-master-filterbar {
                padding: 12px;
                gap: 10px;
            }

            .store-master-list-table th,
            .store-master-list-table td {
                padding: 10px 8px;
                font-size: 0.72rem;
            }
        }

        .store-mapping-grid {
            display: grid;
            grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
            gap: 18px;
        }

        .store-mapping-detail {
            border: 1px solid var(--line-soft);
            border-radius: 24px;
            background: linear-gradient(180deg, rgba(250, 252, 255, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
            padding: 18px;
        }

        .store-mapping-search {
            width: 100%;
            margin-bottom: 12px;
        }

        .store-mapping-list {
            display: grid;
            gap: 10px;
            max-height: 560px;
            overflow: auto;
            padding-right: 4px;
        }

        .store-mapping-item {
            border: 1px solid rgba(197, 214, 224, 0.92);
            border-radius: 18px;
            background: #fff;
            padding: 12px 14px;
            cursor: pointer;
            transition: 0.18s ease;
        }

        .store-mapping-item:hover,
        .store-mapping-item:focus-visible {
            transform: translateY(-1px);
            border-color: rgba(74, 127, 154, 0.38);
            box-shadow: 0 10px 20px rgba(18, 73, 100, 0.08);
        }

        .store-mapping-item.active {
            border-color: rgba(31, 109, 146, 0.42);
            background: linear-gradient(180deg, rgba(234, 245, 252, 0.98) 0%, rgba(250, 253, 255, 0.98) 100%);
            box-shadow: 0 14px 24px rgba(18, 73, 100, 0.12);
        }

        .store-mapping-item-head {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 10px;
            margin-bottom: 6px;
        }

        .store-mapping-item-name {
            font-size: 0.96rem;
            font-weight: 800;
            color: var(--ink);
        }

        .store-mapping-item-meta {
            color: var(--muted);
            font-size: 0.78rem;
            font-weight: 700;
        }

        .store-mapping-item-foot {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
            margin-top: 8px;
        }

        .store-mapping-chip {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 5px 10px;
            border-radius: 999px;
            background: rgba(233, 242, 248, 0.95);
            color: #2a5f7a;
            font-size: 0.72rem;
            font-weight: 800;
        }

        .store-mapping-chip.store {
            background: rgba(227, 245, 236, 0.98);
            color: #257250;
        }
        .store-mapping-chip.bbm {
            background: #e7f8ee;
            color: #047857;
        }

        .branding-settings-section {
            margin-top: 16px;
            padding-top: 16px;
            border-top: 1px solid rgba(210, 226, 236, 0.9);
        }

        .official-document-settings-section {
            margin-top: 16px;
            padding-top: 16px;
            border-top: 1px solid rgba(210, 226, 236, 0.9);
        }

        .official-document-settings-grid {
            display: grid;
            grid-template-columns: minmax(0, 1fr) minmax(240px, 0.72fr);
            gap: 14px;
            align-items: stretch;
        }

        #official-seal-file {
            display: block;
            width: 100%;
            color: #567183;
            font-size: 0.83rem;
        }

        .official-seal-actions {
            margin-top: 10px;
        }

        .official-seal-preview-card {
            border: 1px solid rgba(210, 226, 236, 0.9);
            border-radius: 14px;
            padding: 14px;
            background: rgba(255, 255, 255, 0.86);
        }

        .official-seal-preview-surface {
            min-height: 92px;
            display: grid;
            place-items: center;
            border: 1px dashed rgba(148, 170, 184, 0.8);
            border-radius: 12px;
            background: #ffffff;
            overflow: hidden;
        }

        .official-seal-preview-surface span {
            color: #7a8c9c;
            font-size: 0.82rem;
            font-weight: 700;
        }

        .official-seal-preview-surface img {
            display: block;
            max-width: 100%;
            max-height: 82px;
            object-fit: contain;
        }

        .branding-settings-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 12px 14px;
        }

        .branding-settings-span-2 {
            grid-column: span 2;
        }

        .branding-settings-grid input[type="color"] {
            width: 100%;
            min-height: 46px;
            padding: 4px;
            border-radius: 14px;
            border: 1px solid rgba(182, 205, 220, 0.95);
            background: rgba(255, 255, 255, 0.94);
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.72);
            cursor: pointer;
            appearance: none;
            -webkit-appearance: none;
        }

        .branding-settings-grid input[type="color"]::-webkit-color-swatch-wrapper {
            padding: 0;
            border-radius: 10px;
        }

        .branding-settings-grid input[type="color"]::-webkit-color-swatch {
            border: none;
            border-radius: 10px;
        }

        .branding-settings-grid input[type="color"]::-moz-color-swatch {
            border: none;
            border-radius: 10px;
        }

        .branding-file-label {
            display: block;
            margin: 10px 0 6px;
            color: #6d8395;
            font-size: 0.78rem;
            font-weight: 700;
        }

        #branding-brand-logo-file,
        #branding-signature-logo-file {
            display: block;
            width: 100%;
            color: #567183;
            font-size: 0.83rem;
        }

        .branding-actions {
            margin-top: 12px;
            display: flex;
            justify-content: flex-end;
        }

        .branding-preview-grid {
            margin-top: 18px;
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 14px;
        }

        .branding-preview-card {
            padding: 16px;
            border-radius: 18px;
            border: 1px solid rgba(210, 226, 236, 0.92);
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 250, 253, 0.96));
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
        }

        .branding-preview-label {
            margin: 0 0 12px;
            color: #6a8195;
            font-size: 0.76rem;
            font-weight: 800;
            letter-spacing: 0.08em;
        }

        .branding-preview-topbar {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 14px 16px;
            border-radius: 16px;
            background: #ffffff;
            border: 1px solid rgba(214, 228, 238, 0.95);
        }

        .branding-preview-topbar-logo,
        .branding-preview-login-logo {
            width: 48px;
            height: 48px;
            display: flex;
            align-items: center;
            justify-content: center;
            flex: 0 0 auto;
        }

        .branding-preview-topbar-logo img,
        .branding-preview-login-logo img {
            max-width: 100%;
            max-height: 100%;
            object-fit: contain;
        }

        .branding-preview-topbar-copy p {
            margin: 0 0 4px;
            color: #6f91a7;
            font-size: 0.82rem;
            font-weight: 800;
            letter-spacing: 0.04em;
        }

        .branding-preview-topbar-copy strong {
            display: block;
            color: #173e56;
            font-size: 1rem;
            font-weight: 900;
            line-height: 1.3;
        }

        .branding-preview-login {
            min-height: 260px;
            padding: 20px 22px;
            border-radius: 24px;
            color: #ffffff;
            display: flex;
            flex-direction: column;
            justify-content: space-between;
            gap: 18px;
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.12);
        }

        .branding-preview-login-brand {
            display: flex;
            align-items: center;
            gap: 14px;
        }

        .branding-preview-login-copy strong {
            display: block;
            margin-bottom: 4px;
            color: #ffffff;
            font-size: 0.96rem;
            font-weight: 800;
            letter-spacing: 0.04em;
        }

        .branding-preview-login-copy span {
            display: block;
            color: rgba(255,255,255,0.82);
            font-size: 0.84rem;
            line-height: 1.45;
        }

        .branding-preview-login-title {
            font-family: Georgia, "Times New Roman", serif;
            font-size: clamp(2rem, 4vw, 2.9rem);
            line-height: 0.96;
            letter-spacing: -0.04em;
            font-weight: 700;
            color: #ffffff;
        }

        .branding-preview-login-tagline {
            display: flex;
            flex-direction: column;
            gap: 4px;
            font-family: Georgia, "Times New Roman", serif;
            font-size: clamp(1.3rem, 2.6vw, 1.9rem);
            line-height: 1.04;
            letter-spacing: -0.04em;
            font-weight: 600;
        }

        .branding-preview-login-tagline span {
            color: #ffffff;
        }

        .branding-preview-login-tagline .accent {
            color: var(--branding-login-tagline-accent);
        }

        .branding-preview-signature {
            display: flex;
            justify-content: flex-end;
        }

        .branding-preview-signature img {
            height: 42px;
            width: auto;
            object-fit: contain;
            filter: brightness(0) invert(1);
            opacity: 0.92;
        }

        .settings-note {
            margin: 12px 0 0;
            color: #6c8196;
            font-size: 0.78rem;
            line-height: 1.5;
        }

.store-mapping-chip-remove {
            border: 1px solid rgba(37, 114, 80, 0.18);
            background: rgba(255, 255, 255, 0.82);
            color: #1f6b4d;
            font-size: 0.7rem;
            font-weight: 800;
            line-height: 1;
            padding: 5px 8px;
            border-radius: 999px;
            cursor: pointer;
            opacity: 1;
            transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.store-mapping-chip-remove:hover {
            background: rgba(255, 240, 242, 0.98);
            border-color: rgba(214, 94, 128, 0.28);
            color: #b23b62;
}

        .store-mapping-detail-head {
            display: flex;
            justify-content: space-between;
            gap: 12px;
            align-items: flex-start;
            margin-bottom: 14px;
        }

        .store-mapping-detail-head h3 {
            margin: 0;
            font-size: 1.12rem;
            color: var(--ink);
        }

        .store-mapping-detail-head p {
            margin: 4px 0 0;
            color: var(--muted);
            font-size: 0.82rem;
        }

        .store-mapping-actions {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
            align-items: center;
            justify-content: flex-end;
        }

        .store-mapping-summary {
            display: grid;
            grid-template-columns: repeat(3, minmax(0, 1fr));
            gap: 10px;
            margin-bottom: 14px;
        }

        .store-mapping-summary .metric-chip {
            min-height: 70px;
        }

        .store-mapping-store-list {
            display: grid;
            gap: 8px;
            max-height: 312px;
            overflow-y: auto;
            overflow-x: hidden;
            padding-right: 4px;
        }

        .store-mapping-toolbar {
            display: grid;
            gap: 8px;
            margin: 12px 0 10px;
        }

        .store-mapping-toolbar-row {
            display: grid;
            gap: 10px;
        }

        .store-mapping-toolbar-row-top {
            grid-template-columns: minmax(0, 1fr) 132px auto;
            align-items: center;
        }

        .store-mapping-toolbar-row-bottom {
            grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
            align-items: center;
        }

        .store-mapping-toolbar-right {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-left: auto;
        }

        .store-mapping-search-input {
            min-width: 0;
            max-width: none;
            width: 100%;
        }

        .store-mapping-filter-toggle {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            font-size: 0.8rem;
            color: var(--muted-strong);
            font-weight: 700;
            justify-self: start;
        }

        .store-mapping-filter-toggle input {
            accent-color: var(--teal);
        }

        .store-mapping-store-card {
            border: 1px solid rgba(205, 218, 227, 0.9);
            border-radius: 14px;
            background: #fff;
            padding: 8px 10px;
        }

        .store-mapping-store-card label {
            display: grid;
            grid-template-columns: 18px minmax(0, 1fr);
            align-items: center;
            gap: 8px;
            cursor: pointer;
            min-width: 0;
        }

        .store-mapping-store-main {
            display: grid;
            grid-template-columns: minmax(150px, 1fr) minmax(84px, 0.62fr) minmax(180px, 1.25fr) minmax(86px, 0.62fr);
            align-items: center;
            gap: 3px 10px;
            min-width: 0;
        }

        .store-mapping-store-main strong {
            color: var(--ink);
            font-size: 0.83rem;
            line-height: 1.2;
            min-width: 0;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .store-mapping-store-sub {
            color: var(--muted);
            font-size: 0.7rem;
            line-height: 1.28;
            min-width: 0;
        }

        .store-mapping-store-meta,
        .store-mapping-store-phone,
        .store-mapping-store-address {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .store-mapping-note {
            margin-top: 12px;
        }

        .admin-grid { display: grid; grid-template-columns: 0.88fr 1.12fr; gap: 10px; margin-bottom: 10px; }

        .admin-login-grid { display: grid; grid-template-columns: 0.72fr 1.28fr; gap: 10px; margin-bottom: 10px; }

        .admin-badge {
            display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 999px; background: #fff; border: 1px solid var(--line-soft);
            color: var(--muted); font-size: 0.8rem; font-weight: 800;
        }

        .admin-badge.online { color: var(--primary); background: var(--primary-soft); border-color: transparent; }

        .admin-tools.is-locked { opacity: 0.4; pointer-events: none; user-select: none; }

        #admin-ui-settings-panel.is-locked { opacity: 0.7; }

        .admin-lock-note { margin-top: 12px; color: var(--muted); font-size: 0.84rem; line-height: 1.6; }

        .member-actions { display: flex; gap: 6px; flex-wrap: wrap; }

        .member-actions .btn-ghost,
        .member-actions .btn-danger {
            width: 100%;
        }

        .member-actions .btn-mini { padding: 7px 9px; font-size: 0.72rem; }

        .member-action-cell { display: grid; gap: 6px; min-width: 92px; }

        .admin-action-group .btn-danger {
            min-height: 42px;
            padding: 0 16px;
            border-radius: 999px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            font-size: 0.8rem;
            font-weight: 800;
            white-space: nowrap;
        }

        .admin-action-group .btn-excel,
        .admin-action-group .btn-ghost,
        .admin-action-group .btn-main {
            min-height: 42px;
            padding: 0 16px;
            border-radius: 999px;
        }

        .admin-action-group {
            display: flex;
            align-items: center;
            justify-content: flex-end;
            gap: 8px;
            flex-wrap: wrap;
        }

        .admin-record-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr); gap: 10px; }

        .admin-record-grid.single-panel { grid-template-columns: 1fr; }

        .admin-grid { grid-template-columns: 1fr; }

        .system-zone-panel,
        .danger-zone-panel {
            background: #fff;
        }

        .system-zone-panel--backup {
            border: 1px solid rgba(105, 152, 173, 0.24);
            background: linear-gradient(180deg, #f7fbfe 0%, #ffffff 100%);
        }

        .system-zone-panel--recovery {
            border: 1px solid rgba(214, 147, 57, 0.22);
            background: linear-gradient(180deg, #fffaf2 0%, #ffffff 100%);
        }

        .system-zone-panel--danger,
        .danger-zone-panel {
            border: 1px solid rgba(226, 105, 139, 0.22);
            background: linear-gradient(180deg, #fff8fb 0%, #ffffff 100%);
        }

        .system-zone-grid,
        .danger-zone-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 12px;
            margin-top: 12px;
        }

        .system-zone-panel--backup .system-zone-grid,
        .system-zone-panel--recovery .system-zone-grid {
            grid-template-columns: 1fr;
        }

        .system-zone-item,
        .danger-zone-item {
            border: 1px solid rgba(226, 105, 139, 0.16);
            border-radius: 14px;
            background: #fff;
            padding: 14px;
            display: grid;
            gap: 10px;
        }

        .system-zone-panel--backup .system-zone-item {
            border-color: rgba(105, 152, 173, 0.18);
        }

        .system-zone-panel--recovery .system-zone-item {
            border-color: rgba(214, 147, 57, 0.18);
        }

        .system-zone-item h3,
        .danger-zone-item h3 {
            margin: 0;
            font-size: 0.98rem;
            color: var(--text);
        }

        .system-zone-item p,
        .danger-zone-item p {
            margin: 0;
            color: var(--muted);
            font-size: 0.82rem;
            line-height: 1.6;
        }

        #admin-backup-panel[hidden],
        #admin-recovery-panel[hidden],
        #admin-danger-panel[hidden],
        .system-zone-item[hidden],
        .danger-zone-item[hidden] {
            display: none !important;
        }

        .system-zone-note,
        .danger-zone-note {
            margin-top: 10px;
            color: var(--muted);
            font-size: 0.78rem;
            line-height: 1.6;
        }

        .admin-inline-toggle {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            padding: 10px 14px;
            border-radius: 999px;
            border: 1px solid var(--line-soft);
            background: rgba(255,255,255,0.86);
            color: var(--ink-soft);
            font-size: 0.84rem;
            font-weight: 700;
        }

        .admin-inline-toggle input {
            width: 16px;
            height: 16px;
            accent-color: var(--primary);
        }

        #admin-app-list, #admin-history-list { min-width: 680px; }
        #admin-app-list {
            table-layout: fixed;
        }
        #admin-app-list th:nth-child(3),
        #admin-app-list td:nth-child(3) {
            max-width: 260px;
        }
        #admin-app-list th:nth-child(6),
        #admin-app-list td:nth-child(6) {
            width: 96px;
            min-width: 96px;
            text-align: center;
        }
        #admin-app-list td:nth-child(6) .status-pill {
            min-width: 70px;
            padding: 5px 12px;
            white-space: nowrap;
        }
        #admin-app-list th:last-child,
        #admin-app-list td:last-child {
            width: 196px;
        }
        #admin-app-list .table-actions {
            flex-wrap: nowrap;
            gap: 6px;
        }
        #admin-app-list .table-actions button {
            min-width: 46px;
            padding: 6px 8px;
            white-space: nowrap;
        }

.member-role-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }

.member-role-search { width: min(320px, 100%); padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; font-size: 0.86rem; color: var(--text); }

.member-role-search:focus { outline: 3px solid rgba(104, 152, 173, 0.18); border-color: var(--primary); }

.member-role-toolbar-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-left: auto; }

.member-master-detail {
    display: grid;
    grid-template-columns: minmax(500px, 1.08fr) minmax(0, 1.42fr);
    gap: 16px;
    align-items: start;
}

.member-detail-panel {
    border: 1px solid #d8e2ee;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 22px rgba(15, 82, 112, 0.05);
}

.member-master-list { padding: 10px; position: sticky; top: 12px; }

.member-list-meta { padding: 2px 4px 8px; color: #53677b; font-size: 0.76rem; font-weight: 700; }

.member-list-scroller { max-height: 760px; overflow: auto; display: grid; gap: 0; padding-right: 14px; background: #fff; border: 1px solid #d9e3ee; border-radius: 12px; scrollbar-gutter: stable; }

.member-list-header,
.member-list-table-row {
    display: grid;
    grid-template-columns: 44px minmax(124px, 1.02fr) minmax(96px, 0.78fr) minmax(154px, 0.98fr) 132px;
    align-items: stretch;
    padding-right: 8px;
}

.member-list-header {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #f8fbfe;
    border-bottom: 1px solid #dbe7f0;
}

.member-list-head-cell,
.member-list-cell {
    min-width: 0;
    padding: 11px 12px;
    border-bottom: 1px solid #e5edf5;
    color: #5f7489;
    font-size: 0.74rem;
    font-weight: 800;
}

.member-list-head-cell {
    color: #5c748c;
    background: #f8fbfe;
}

.member-list-header .member-list-head-cell:last-child,
.member-list-header .member-list-head-cell:nth-child(5) {
    justify-content: center;
    text-align: center;
}

.member-list-head-button {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    padding: 0;
}

.member-list-head-button.active { color: #1f547a; }

.member-list-head-sort {
    font-size: 0.64rem;
    color: #2b6d99;
}

.member-list-head-check,
.member-list-cell-check {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 11px 8px;
}

.member-list-head-check input[type="checkbox"],
.member-list-cell-check input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
}

.member-list-cell-check input[type="checkbox"]:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.member-list-table-row {
    cursor: pointer;
    transition: background-color .14s ease;
}

.member-list-table-row:hover { background: #f7fbff; }

.member-list-table-row.active { background: #eef6fd; }

.member-list-table-row:last-child .member-list-cell,
.member-list-table-row:last-child .member-list-cell-check { border-bottom: 0; }

.member-list-name-wrap,
.member-list-id-wrap,
.member-list-org-wrap {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.member-list-primary {
    color: #18344a;
    font-size: 0.8rem;
    font-weight: 800;
    line-height: 1.2;
}

.member-list-secondary {
    color: #70859a;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.member-list-id-wrap .member-list-primary { font-size: 0.75rem; }

.member-list-status-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    padding-inline: 10px 18px;
}

.member-list-status {
    min-width: 74px;
    padding-inline: 12px;
    justify-content: center;
}

.member-cleanup-panel {
    margin-top: 12px;
    border: 1px solid rgba(226, 105, 139, 0.16);
    border-radius: 14px;
    background: linear-gradient(180deg, #fffafb 0%, #ffffff 100%);
    padding: 14px;
    display: grid;
    gap: 12px;
}

.member-cleanup-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.member-cleanup-head h4 {
    margin: 0 0 4px;
    font-size: 0.92rem;
    color: #163349;
}

.member-cleanup-head p {
    margin: 0;
    font-size: 0.78rem;
    line-height: 1.55;
    color: #678194;
}

.member-cleanup-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.member-cleanup-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid rgba(213, 226, 236, 0.92);
    border-radius: 12px;
    background: #fff;
    padding: 12px;
}

.member-cleanup-option input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-top: 2px;
    accent-color: var(--primary);
}

.member-cleanup-option-copy {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.member-cleanup-option-copy strong {
    color: #17344a;
    font-size: 0.82rem;
}

.member-cleanup-option-copy span {
    color: #6b8295;
    font-size: 0.73rem;
    line-height: 1.45;
}

.member-cleanup-actions {
    display: flex;
    justify-content: flex-end;
}

.member-list-card { position: relative; border: 0; border-bottom: 1px solid #e5edf5; border-radius: 0; background: #fff; padding: 9px 10px 9px 12px; cursor: pointer; transition: background-color .14s ease; text-align: left; width: 100%; }

.member-list-card:last-child { border-bottom: 0; }

.member-list-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: transparent; }

.member-list-card:hover { background: #f7fbff; }

.member-list-card.active { background: #eef6fd; }

.member-list-card.active::before { background: #2f7fc0; }

.member-list-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #7a8da3; font-size: 0.68rem; font-weight: 700; margin-bottom: 6px; }

.member-list-card-main { display: grid; grid-template-columns: 28px minmax(0,1fr) auto; align-items: start; gap: 8px; width: 100%; }

.member-list-avatar { width: 28px; height: 28px; border-radius: 8px; background: linear-gradient(180deg, #b7d6ff, #8ebdf9); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 0.78rem; font-weight: 800; box-shadow: inset 0 1px 0 rgba(255,255,255,0.35); }

.member-list-body { min-width: 0; }

.member-list-name { font-size: 0.78rem; line-height: 1.18; color: #142a3b; font-weight: 800; margin: 0 0 3px; }

.member-list-org { color: #617589; font-size: 0.67rem; line-height: 1.2; font-weight: 600; }

.member-list-role { color: #7a8da3; font-size: 0.66rem; line-height: 1.2; margin-top: 2px; font-weight: 600; }

.member-list-side { display: grid; justify-items: end; gap: 5px; min-width: 56px; }

.member-list-status { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 999px; background: #eef4fb; color: #49647f; font-size: 0.62rem; font-weight: 800; letter-spacing: 0.02em; }

.member-list-status.status-active { background: #edf9f0; color: #19703a; border: 1px solid rgba(25,112,58,0.12); }

.member-list-status.status-inactive { background: #f7f1ea; color: #8f6c46; }

.member-list-status.status-suspended { background: #fdecef; color: #b64f69; }

.member-list-side-note { color: #8193a5; font-size: 0.64rem; font-weight: 600; text-align: right; line-height: 1.15; }

.member-mini-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; padding-left: 36px; }

.member-mini-tag { display: inline-flex; align-items: center; padding: 2px 7px; border-radius: 999px; background: #eff4f9; color: #587089; font-size: 0.62rem; font-weight: 700; }

.member-detail-panel { padding: 12px; min-height: 640px; }

.member-detail-empty { border: 1px dashed #d8e2ee; border-radius: 12px; padding: 24px; color: var(--muted); text-align: center; background: #f8fbff; }

.manager-store-assignment-notice {
  color: #1f5fae !important;
  font-weight: 800;
  background: linear-gradient(180deg, #eef6ff 0%, #e4f0ff 100%);
  border: 1px solid #bfd8f6;
  border-radius: 12px;
  padding: 12px 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.member-detail-hero { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 14px 16px; border: 1px solid #dce7f3; border-radius: 12px; background: #f7fbff; margin-bottom: 0; }

.member-detail-kicker { margin: 0 0 4px; color: #4d6b82; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }

.member-detail-title { margin: 0; font-family: "Plus Jakarta Sans", "Noto Sans KR", sans-serif; font-size: 1.28rem; line-height: 1.16; color: var(--ink-strong); }

.member-detail-subtitle { margin-top: 4px; color: #687a8d; font-size: 0.82rem; font-weight: 700; }

.member-detail-badges { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }

.member-detail-tabs { display: flex; flex-wrap: wrap; gap: 0; margin: 0 0 12px; padding: 0 10px; border-bottom: 1px solid #d8e2ee; background: #fff; }

.member-detail-tab { border: 0; border-bottom: 2px solid transparent; background: transparent; color: #6a7f93; padding: 12px 14px 10px; margin-bottom: -1px; font-size: 0.84rem; font-weight: 800; cursor: pointer; border-radius: 0; }

.member-detail-tab:hover { color: var(--primary); background: rgba(15, 82, 112, 0.04); }

.member-detail-tab.active { color: var(--primary); border-bottom-color: var(--primary); box-shadow: none; }

.member-detail-card { border: 1px solid #dce7f3; border-radius: 12px; background: #fff; padding: 14px; }

.member-detail-card + .member-detail-card { margin-top: 12px; }

.member-detail-card h3 { margin: 0 0 6px; font-size: 0.96rem; color: var(--ink-strong); }

.member-detail-card .section-desc { margin: 0 0 12px; }

.organization-cleanup-card {
    overflow: visible;
}

.organization-cleanup-toolbar {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) auto;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.organization-cleanup-list {
    display: grid;
    gap: 6px;
    max-height: 360px;
    overflow: auto;
    padding-right: 4px;
}

.organization-cleanup-row {
    display: grid;
    grid-template-columns: 28px minmax(160px, 1fr) minmax(92px, auto) minmax(92px, auto);
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 8px 10px;
    border: 1px solid #dce7f3;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
}

.organization-cleanup-row:hover,
.organization-cleanup-row.is-selected {
    border-color: rgba(42, 112, 146, 0.42);
    background: #f0f8fc;
}

.organization-cleanup-value {
    min-width: 0;
    color: var(--ink-strong);
    font-weight: 850;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.organization-cleanup-count {
    justify-self: end;
    padding: 4px 8px;
    border-radius: 999px;
    background: #eef4f7;
    color: #486477;
    font-size: 0.72rem;
    font-weight: 800;
    white-space: nowrap;
}

.organization-cleanup-scope {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 10px 0;
}

.organization-cleanup-scope label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid #dce7f3;
    border-radius: 999px;
    background: #fff;
    color: var(--ink-strong);
    font-size: 0.78rem;
    font-weight: 850;
}

.organization-cleanup-scope label.is-disabled {
    opacity: 0.48;
}

.organization-cleanup-preview {
    margin-top: 8px;
}

.organization-cleanup-preview-box {
    display: grid;
    gap: 4px;
    padding: 10px 12px;
    border: 1px solid rgba(42, 112, 146, 0.24);
    border-radius: 10px;
    background: linear-gradient(180deg, #f8fcfe 0%, #eff8fc 100%);
}

.organization-cleanup-preview-box strong {
    color: #17465d;
    font-size: 0.86rem;
    overflow-wrap: anywhere;
}

.organization-cleanup-preview-box span,
.organization-cleanup-preview-box small {
    color: #5f7789;
    font-size: 0.74rem;
    font-weight: 750;
}

.member-master-detail.store-master-management {
    grid-template-columns: minmax(520px, 1.08fr) minmax(560px, 1.32fr);
}

.store-master-management .member-detail-panel {
    min-width: 0;
}

.store-master-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(260px, 1fr)); gap: 12px; margin-bottom: 14px; }

.store-master-summary-card { border: 1px solid #dce7f3; border-radius: 12px; background: #fff; padding: 14px 16px; box-shadow: 0 8px 22px rgba(15, 82, 112, 0.05); }

.store-master-summary-label { color: #62788e; font-size: 0.73rem; font-weight: 700; margin-bottom: 8px; }

.store-master-summary-value { color: #173247; font-family: "Plus Jakarta Sans", "Noto Sans KR", sans-serif; font-size: 1.62rem; font-weight: 800; line-height: 1; }

.store-master-summary-desc { margin-top: 6px; color: #7c90a3; font-size: 0.7rem; line-height: 1.35; }

.store-master-filterbar { display: grid; grid-template-columns: 180px 180px 150px minmax(220px, 1fr); gap: 10px 12px; align-items: end; margin-bottom: 14px; padding: 14px 16px; border: 1px solid #d8e2ee; border-radius: 12px; background: linear-gradient(180deg, #fbfdff 0%, #f4f8fc 100%); }

.store-master-filter-field { display: grid; gap: 6px; }

.store-master-filter-field label { color: #557086; font-size: 0.73rem; font-weight: 800; }

.store-master-filter-field input { width: 100%; min-height: 38px; padding: 9px 12px; border: 1px solid #cedaea; border-radius: 8px; background: #fff; color: #163247; font-size: 0.84rem; }

.store-master-list-shell { border: 1px solid #d9e3ee; border-radius: 12px; overflow: hidden; background: #fff; }

.store-master-list { display: block; }

.store-master-list-table { width: 100%; border-collapse: collapse; table-layout: fixed; }

.store-master-list-table thead th {
    padding: 11px 12px;
    border-bottom: 1px solid #dfe8f3;
    background: #f6fafe;
    color: #5a7388;
    font-size: 0.72rem;
    font-weight: 800;
    text-align: left;
}

.store-master-list-table tbody td:last-child { text-align: center; }

.store-master-list-table tbody tr {
    cursor: pointer;
    transition: background-color .14s ease;
}

.store-master-list-table tbody tr:hover { background: #f7fbff; }

.store-master-list-table tbody tr.active { background: #eef6fd; }

.store-master-list-table tbody tr.active td:first-child { box-shadow: inset 3px 0 0 #2f7fc0; }

.store-master-list-table tbody td {
    padding: 11px 12px;
    border-bottom: 1px solid #e5edf5;
    vertical-align: top;
}

.store-master-list-table tbody tr:last-child td { border-bottom: 0; }

.store-master-row-no { color: #70869b; font-size: 0.76rem; font-weight: 700; text-align: center; }

.store-master-list-name { color: #173247; font-size: 0.9rem; font-weight: 800; line-height: 1.2; overflow-wrap: anywhere; word-break: keep-all; }

.store-master-list-aux { display: grid; gap: 3px; margin-top: 6px; }

.store-master-list-address { color: #607487; font-size: 0.72rem; line-height: 1.42; overflow-wrap: anywhere; word-break: keep-all; }

.store-master-list-phone { color: #52728c; font-size: 0.72rem; font-weight: 700; }

.store-master-list-cell { color: #5d788f; font-size: 0.76rem; font-weight: 700; line-height: 1.4; overflow-wrap: anywhere; word-break: keep-all; }

.store-master-list-status { display: inline-flex; justify-content: center; width: 100%; }

.store-master-sheet { display: grid; gap: 10px; }

.store-master-sheet-header { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 16px; border: 1px solid #dce7f3; border-radius: 14px; background: linear-gradient(180deg, #f9fcff 0%, #f1f7fc 100%); }

.store-master-sheet-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }

.store-master-sheet-actions .btn-main,
.store-master-sheet-actions .btn-danger,
.store-master-sheet-actions .btn-ghost {
    min-height: 44px;
    min-width: 116px;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 0.83rem;
    font-weight: 800;
    white-space: nowrap;
    transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

.store-master-sheet-actions .btn-ghost {
    color: #24465d;
    background: linear-gradient(180deg, #ffffff 0%, #eef4f8 100%);
    border-color: #d6e3ee;
    box-shadow: 0 8px 18px rgba(30, 66, 93, 0.08);
}

.store-master-sheet-actions .btn-danger {
    color: #b13f63;
    background: linear-gradient(180deg, #fff1f5 0%, #f9dbe5 100%);
    border-color: #e8b8c7;
    box-shadow: 0 10px 20px rgba(196, 79, 116, 0.15);
}

.store-master-sheet-actions .btn-main {
    box-shadow: 0 12px 24px rgba(0, 51, 73, 0.18);
}

.store-master-sheet-actions .btn-ghost:hover,
.store-master-sheet-actions .btn-ghost:focus-visible {
    transform: none;
    color: #18364c;
    background: linear-gradient(180deg, #ffffff 0%, #e7f0f6 100%);
    border-color: #bfd3e2;
    box-shadow: 0 12px 24px rgba(30, 66, 93, 0.12);
}

.store-master-sheet-actions .btn-main:hover,
.store-master-sheet-actions .btn-main:focus-visible,
.store-master-sheet-actions .btn-danger:hover,
.store-master-sheet-actions .btn-danger:focus-visible {
    transform: none;
    color: #ffffff;
    background: linear-gradient(135deg, #d56a89 0%, #bf4d6f 100%);
    border-color: #bf4d6f;
    box-shadow: 0 14px 26px rgba(196, 79, 116, 0.24);
}

.store-master-sheet-actions .btn-main:hover,
.store-master-sheet-actions .btn-main:focus-visible {
    background: linear-gradient(135deg, #0d5776 0%, #0a4760 100%);
    border-color: transparent;
    box-shadow: 0 14px 28px rgba(0, 51, 73, 0.22);
}

.store-master-sheet-actions .btn-main:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

.store-master-sheet-actions-sep {
    width: 1px;
    align-self: stretch;
    min-height: 38px;
    background: #dce7f3;
    margin: 0 2px;
}

.store-master-sheet-topline { display: flex; flex-wrap: wrap; gap: 8px 10px; padding: 0; color: #698196; font-size: 0.78rem; font-weight: 700; }

.store-master-sheet-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }

.store-master-kpi {
    display: grid;
    gap: 3px;
    padding: 10px 12px;
    border: 1px solid #dde7f1;
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.store-master-kpi span {
    color: #6d8497;
    font-size: 0.69rem;
    font-weight: 700;
}

.store-master-kpi strong {
    color: #173247;
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.2;
}

.store-master-list-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.store-master-list-summary-text {
    color: #5f768b;
    font-size: 0.76rem;
    font-weight: 700;
}

.store-master-sheet-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.85fr); gap: 12px; }

.store-master-sheet-main,
.store-master-sheet-side { min-width: 0; display: grid; gap: 12px; align-content: start; }

.store-master-sheet-card { border: 1px solid #dce7f3; border-radius: 14px; background: #fff; padding: 13px 14px; }

.store-master-sheet-card-title { margin-bottom: 10px; color: #173247; font-size: 0.88rem; font-weight: 800; }

.store-master-detail-layout { display: grid; gap: 12px; }

.store-master-detail-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }

.store-master-detail-stat { border: 1px solid #dce7f3; border-radius: 12px; background: #fbfdff; padding: 12px 14px; }

.store-master-detail-stat-label { color: #698197; font-size: 0.72rem; font-weight: 700; margin-bottom: 6px; }

.store-master-detail-stat-value { color: #173247; font-size: 0.96rem; font-weight: 800; line-height: 1.25; }

.store-master-detail-note { border: 1px dashed #d8e2ee; border-radius: 12px; background: #f8fbff; padding: 12px 14px; color: #698095; font-size: 0.75rem; line-height: 1.5; }

.store-master-detail-topbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid #dce7f3; border-radius: 12px; background: linear-gradient(180deg, #f8fbff 0%, #eef5fb 100%); }

.store-master-detail-topmeta { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; color: #648097; font-size: 0.74rem; font-weight: 700; }

.store-master-detail-title-block { display: grid; gap: 4px; }

.store-master-detail-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) 320px; gap: 12px; align-items: start; }

.store-master-detail-sidebar { display: grid; gap: 12px; }

.store-master-detail-panelbox { border: 1px solid #dce7f3; border-radius: 12px; background: #fff; overflow: hidden; }

.store-master-detail-panelbox-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid #e3ebf4; background: #f7fbff; }

.store-master-detail-panelbox-head h3 { margin: 0; color: #173247; font-size: 0.86rem; font-weight: 800; }

.store-master-detail-panelbox-body { padding: 14px; }

.store-master-mini-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }

.store-master-mini-fact { border: 1px solid #e3ebf4; border-radius: 10px; background: #fbfdff; padding: 10px 12px; }

.store-master-mini-fact-label { color: #6a8297; font-size: 0.69rem; font-weight: 700; margin-bottom: 4px; }

.store-master-mini-fact-value { color: #173247; font-size: 0.88rem; font-weight: 800; line-height: 1.25; }

.store-master-actionbar { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; padding-top: 12px; border-top: 1px solid #e3ebf4; }

.store-master-actionbar .member-detail-actions { margin: 0; }

.store-master-linked-manager-list { display: grid; gap: 6px; }

.store-master-bbm-inline-field {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 6px 12px;
    align-items: center;
}

.store-master-bbm-inline-field label {
    margin: 0;
}

.store-master-bbm-inline-field .helper-text {
    grid-column: 2;
    margin-top: -2px;
}

.store-master-bbm-inline-field input::placeholder {
    font-size: 0.8rem;
    color: #8aa0b2;
    letter-spacing: -0.01em;
}

.store-master-linked-manager-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 12px; border: 1px solid #e5edf5; border-radius: 12px; background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%); }

.store-master-linked-manager-content { min-width: 0; display: grid; gap: 4px; }

.store-master-linked-manager-actions { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }

.store-master-linked-manager-name { color: #18364c; font-size: 0.8rem; font-weight: 800; }

.store-master-linked-manager-meta { color: #678298; font-size: 0.72rem; font-weight: 700; line-height: 1.4; word-break: keep-all; overflow-wrap: anywhere; }

.store-master-linked-manager-remove { min-width: 78px; }

@media (max-width: 1180px) {
    .store-master-sheet-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 960px) {
    .store-master-sheet-header {
        align-items: flex-start;
    }

    .store-master-sheet-grid {
        grid-template-columns: 1fr;
    }
}

.store-master-linked-manager-empty { color: #788da0; font-size: 0.75rem; line-height: 1.5; }

.member-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; }

.member-detail-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

.member-detail-bbm-summary {
    margin-top: 4px;
    color: #047857;
    font-weight: 900;
}

.member-detail-panel .perm-list { gap: 8px; }

.member-detail-panel .perm-pill { padding: 8px 12px; }

.member-store-summary-detail { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }

.member-bbm-store-block {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #e2edf3;
}

.member-bbm-store-title {
    margin-bottom: 8px;
    color: #0f5f4a;
    font-size: 0.76rem;
    font-weight: 900;
}

.member-store-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.member-store-summary .store-mapping-chip {
    margin: 0;
}

.member-store-summary-empty {
    color: var(--muted);
    font-size: 0.8rem;
}

.member-store-summary-actions {
    margin-top: 8px;
}

.member-store-inline-panel {
    margin-top: 12px;
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(19, 62, 88, 0.08);
    background: linear-gradient(180deg, rgba(247, 251, 254, 0.98) 0%, #ffffff 100%);
    box-shadow: inset 4px 0 0 rgba(19, 92, 127, 0.18);
}

.member-store-inline-panel[hidden] {
    display: none !important;
}

.member-connection-overview {
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
}

.member-connection-overview-head {
    margin-bottom: 10px;
}

.member-connection-overview-table {
    border: 1px solid #d7e3ef;
    border-radius: 12px;
    background: #fff;
    overflow: hidden;
}

.member-connection-grid {
    display: grid;
    grid-template-columns: 44px minmax(170px, 1fr) minmax(92px, 0.5fr) minmax(250px, 1.2fr) minmax(250px, 1.2fr) 92px;
}

.member-connection-grid.is-head {
    background: #f4f8fc;
    border-bottom: 1px solid #d7e3ef;
}

.member-connection-head-cell,
.member-connection-cell {
    padding: 10px 12px;
    min-width: 0;
}

.member-connection-head-cell {
    color: #597489;
    font-size: 0.73rem;
    font-weight: 800;
    background: transparent;
    border: none;
    text-align: left;
}

.member-connection-row {
    border-bottom: 1px solid #edf3f8;
}

.member-connection-row:last-child {
    border-bottom: 0;
}

.member-connection-row.is-active {
    background: rgba(15, 82, 112, 0.06);
}

.member-connection-check-cell {
    display: flex;
    align-items: center;
    justify-content: center;
}

.member-connection-sort-btn {
    cursor: pointer;
}

.member-connection-sort-btn:hover {
    color: #21465e;
}

.member-connection-primary {
    color: #18364c;
    font-size: 0.84rem;
    font-weight: 800;
}

.member-connection-primary.connection-link {
    cursor: pointer;
}

.member-connection-primary.connection-link:hover {
    color: var(--primary);
}

.member-connection-secondary {
    margin-top: 3px;
    color: #70879a;
    font-size: 0.74rem;
    font-weight: 700;
}

.member-connection-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.member-connection-chip {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid #d9e6f1;
    background: #f7fbff;
    color: #24475f;
    font-size: 0.73rem;
    font-weight: 700;
    line-height: 1.3;
}

.member-connection-chip.manager {
    background: #eef7ff;
    border-color: #cfe3f6;
}

.member-connection-chip.bbm {
    background: #eef9f1;
    border-color: #cfe9d7;
}

.member-connection-empty {
    padding: 16px;
    color: #73889b;
    font-size: 0.79rem;
}

.member-connection-action-cell {
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 1180px) {
    .member-connection-grid {
        grid-template-columns: 40px minmax(150px, 1fr) minmax(84px, 0.44fr) minmax(220px, 1fr) minmax(220px, 1fr) 84px;
    }
}

.member-store-inline-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.member-store-inline-head h3 {
    margin: 0;
    font-size: 1.18rem;
    color: var(--text);
}

.member-store-inline-head p {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.manager-store-setup-dialog {
    width: min(1120px, calc(100vw - 48px));
    max-height: calc(100vh - 56px);
    overflow: hidden;
    border-radius: 28px;
    border: 1px solid rgba(198, 216, 228, 0.98);
    background: linear-gradient(180deg, rgba(250, 252, 255, 0.99) 0%, rgba(255, 255, 255, 0.99) 100%);
    box-shadow: 0 26px 54px rgba(18, 53, 78, 0.18);
    padding: 22px 24px 20px;
    display: grid;
    gap: 14px;
}

.manager-store-setup-head h3 {
    margin: 0;
    font-size: 1.34rem;
    color: var(--text);
}

.manager-store-setup-head p {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.55;
}

.manager-store-setup-body {
    min-height: 0;
    overflow: auto;
    padding-right: 4px;
}

.manager-store-setup-body .member-store-inline-panel {
    margin-top: 0;
    padding: 0;
    border: none;
    background: transparent;
    box-shadow: none;
}

.manager-store-setup-body .member-store-inline-head {
    margin-bottom: 10px;
}

.manager-store-setup-body .member-store-inline-head h3,
.manager-store-setup-body .member-store-inline-head p {
    display: none;
}

        .manager-store-setup-body .store-mapping-store-list {
    max-height: min(44vh, 312px);
    gap: 6px;
}

.manager-store-setup-body .store-mapping-store-card {
    padding: 7px 10px;
    border-radius: 12px;
}

.manager-store-setup-body .store-mapping-store-card label {
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr);
    align-items: center;
    gap: 8px;
}

.manager-store-setup-body .store-mapping-store-main {
    display: grid;
    grid-template-columns: minmax(144px, 1fr) minmax(82px, 0.58fr) minmax(168px, 1.12fr) minmax(82px, 0.58fr);
    align-items: center;
    gap: 3px 8px;
    min-width: 0;
}

.manager-store-setup-body .store-mapping-store-main strong {
    font-size: 0.79rem;
    line-height: 1.18;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.manager-store-setup-body .store-mapping-store-sub {
    display: block;
    font-size: 0.67rem;
    line-height: 1.22;
    min-width: 0;
}

.manager-store-setup-body .store-mapping-item-foot {
    grid-column: 2 / span 3;
    margin-top: 2px;
}

@media (max-width: 1100px) {
    .store-mapping-toolbar-row-top,
    .store-mapping-toolbar-row-bottom {
        grid-template-columns: minmax(0, 1fr);
    }

    .store-mapping-store-main {
        grid-template-columns: minmax(0, 1fr);
        gap: 3px;
    }

    .manager-store-setup-body .store-mapping-store-card label {
        grid-template-columns: 20px minmax(0, 1fr);
    }

    .manager-store-setup-body .store-mapping-store-main {
        grid-template-columns: minmax(0, 1fr);
        gap: 3px;
    }

    .manager-store-setup-body .store-mapping-item-foot {
        grid-column: auto;
    }
}

.member-store-inline-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.admin-table-sort-btn {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0;
    border: none;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

.admin-table-sort-btn .sort-label {
    display: inline-block;
}

.admin-table-sort-btn .sort-arrow {
    display: inline-block;
    min-width: 10px;
    font-size: 0.68rem;
    color: var(--muted);
}

.admin-table-sort-btn.active {
    color: var(--accent);
    font-weight: 700;
}

.store-master-list-table .admin-table-sort-btn {
    justify-content: flex-start;
}

        #admin-slots-panel .table-wrap { overflow-x: auto; overflow-y: auto; max-height: 540px; }

        #admin-apps-panel .table-wrap { max-height: 320px; }

        #admin-apps-panel .table-wrap,
        #admin-slots-panel .table-wrap,
        #admin-history-panel .table-wrap { max-height: 430px; overflow-y: auto; overflow-x: auto; }

        #admin-privacy-panel .table-wrap { max-height: 430px; overflow-y: auto; overflow-x: auto; }

        #admin-app-list th:first-child,
        #admin-app-list td:first-child,
        #admin-slot-list th:first-child,
        #admin-slot-list td:first-child {
            width: 48px;
            min-width: 48px;
            text-align: center;
            padding-left: 0;
            padding-right: 0;
            vertical-align: middle;
        }

        #admin-app-list th.select-col,
        #admin-slot-list th.select-col {
            text-align: center;
            padding-left: 0;
            padding-right: 0;
        }

        #admin-app-list .table-select-head,
        #admin-slot-list .table-select-head {
            width: auto;
            height: auto;
            min-height: 0;
            margin: 0 auto;
            padding: 0;
            border: none;
            border-radius: 0;
            background: transparent;
            box-shadow: none;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        #admin-app-list input[type="checkbox"],
        #admin-slot-list input[type="checkbox"] {
            appearance: auto;
            -webkit-appearance: checkbox;
            width: 16px;
            height: 16px;
            margin: 0;
            padding: 0;
            border: none;
            border-radius: 0;
            background: transparent;
            box-shadow: none;
            vertical-align: middle;
            accent-color: #0f5b7f;
            opacity: 1;
            display: inline-block;
            cursor: pointer;
        }

        #admin-app-list input[type="checkbox"]:disabled,
        #admin-slot-list input[type="checkbox"]:disabled {
            cursor: not-allowed;
            opacity: 0.45;
        }

        #admin-slot-list .table-actions { display: flex; gap: 6px; flex-wrap: nowrap; }

        #admin-slot-list .table-actions button {
            min-width: 52px;
            padding: 6px 10px;
            font-size: 12px;
            border-radius: 12px;
            white-space: nowrap;
        }

        #admin-slot-list td:last-child .helper-text {
            margin-top: 4px;
            font-size: 11px;
            line-height: 1.35;
            display: block;
        }

        #admin-slot-list td:last-child {
            white-space: normal;
            overflow: visible;
        }

        #admin-slot-list td:nth-child(3) {
            text-align: left;
        }

        #admin-slot-list td:nth-child(2) {
            font-weight: 700;
            color: var(--text);
        }

        #admin-slot-list td:last-child {
            min-width: 214px;
        }

        #admin-slot-list td:nth-child(7) {
            text-align: center;
        }

        #admin-slot-list td {
            padding: 9px 8px;
        }

        #admin-slot-list th {
            font-size: 0.71rem;
        }

        .admin-register-grid {
            display: grid;
            grid-template-columns: repeat(3, minmax(0, 1fr));
            gap: 12px;
            margin-top: 12px;
        }

        .admin-register-actions {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            margin-top: 14px;
        }

        .admin-register-note {
            color: var(--muted);
            font-size: 0.9rem;
            line-height: 1.5;
        }

        @media (max-width: 900px) {
            .admin-register-grid { grid-template-columns: 1fr; }

            .admin-register-actions { flex-direction: column; align-items: stretch; }

            .admin-action-group {
                width: 100%;
                display: grid;
                grid-template-columns: 1fr;
            }

            .system-zone-grid,
            .danger-zone-grid { grid-template-columns: 1fr; }
        }

        @media (max-width: 640px) {
            .admin-lock-note { font-size: 0.8rem; }
        }

        .privacy-consent-admin-grid {
            display: grid;
            grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
            gap: 12px;
            align-items: stretch;
        }

        .privacy-consent-editor-card,
        .privacy-consent-records-card {
            border: 1px solid rgba(180, 202, 225, 0.72);
            border-radius: 20px;
            background: rgba(255, 255, 255, 0.92);
            box-shadow: 0 12px 24px rgba(18, 52, 81, 0.05);
            padding: 14px;
        }

        .privacy-consent-editor-card {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }

        .privacy-consent-records-card {
            display: flex;
            flex-direction: column;
            gap: 8px;
            min-height: 0;
            height: 100%;
            max-height: 1052px;
            align-self: stretch;
            overflow: hidden;
        }

        .privacy-consent-version-meta {
            display: flex;
            align-items: center;
            gap: 8px;
            flex-wrap: wrap;
            margin-bottom: 10px;
        }

        .privacy-consent-editor-head .section-desc {
            max-width: 720px;
            font-size: 0.8rem;
            line-height: 1.52;
        }

        .privacy-consent-editor-topline {
            display: flex;
            flex-direction: column;
            align-items: stretch;
            gap: 8px;
            padding: 0;
        }

        .privacy-consent-editor-note {
            margin: 0;
            max-width: none;
            color: #6a8195;
            font-size: 0.75rem;
            line-height: 1.48;
            text-align: left;
        }

        .privacy-consent-overview-strip,
        .privacy-consent-settings-summary {
            display: grid;
            gap: 6px;
            margin-bottom: 10px;
        }

        .privacy-consent-overview-strip {
            grid-template-columns: repeat(5, minmax(0, 1fr));
        }

        .privacy-consent-settings-summary {
            grid-template-columns: repeat(3, minmax(0, 1fr));
        }

        .privacy-consent-editor-head .section-title,
        .privacy-consent-records-head .section-title {
            font-size: 1.08rem;
            line-height: 1.2;
        }

        .privacy-consent-records-head {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            gap: 12px;
        }

        .privacy-consent-records-head .section-header {
            flex: 1 1 auto;
            margin-bottom: 0;
        }

        .privacy-consent-records-badge {
            flex: 0 0 auto;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-height: 34px;
            padding: 0 13px;
            border-radius: 999px;
            border: 1px solid rgba(184, 204, 221, 0.88);
            background: linear-gradient(180deg, rgba(250, 252, 254, 0.98), rgba(241, 247, 251, 0.96));
            color: #4f6980;
            font-size: 0.76rem;
            font-weight: 600;
            letter-spacing: 0.02em;
            white-space: nowrap;
        }

        .privacy-consent-record-summary {
            display: grid;
            grid-template-columns: repeat(4, minmax(0, 1fr));
            gap: 5px;
        }

        .privacy-consent-record-summary .metric-chip {
            min-height: 54px;
            padding: 8px 10px;
            border-radius: 15px;
            border: 1px solid rgba(189, 210, 228, 0.72);
            background: linear-gradient(180deg, rgba(248, 251, 254, 0.98), rgba(242, 247, 251, 0.96));
            box-shadow: 0 10px 22px rgba(18, 52, 81, 0.05);
        }

        .privacy-consent-record-summary .metric-chip span {
            color: #6f879a;
            font-size: 0.71rem;
            font-weight: 600;
            letter-spacing: 0.04em;
        }

        .privacy-consent-record-summary .metric-chip strong {
            margin-top: 3px;
            color: #173e56;
            font-size: 0.94rem;
            font-weight: 600;
        }

        .privacy-consent-overview-strip .metric-chip,
        .privacy-consent-settings-summary .metric-chip {
            min-height: 54px;
            padding: 8px 10px;
            border-radius: 16px;
            border: 1px solid rgba(189, 210, 228, 0.72);
            background: linear-gradient(180deg, rgba(248, 251, 254, 0.98), rgba(242, 247, 251, 0.96));
            box-shadow: 0 10px 22px rgba(18, 52, 81, 0.05);
        }

        .privacy-consent-overview-strip .metric-chip span,
        .privacy-consent-settings-summary .metric-chip span {
            color: #6f879a;
            font-size: 0.71rem;
            font-weight: 800;
            letter-spacing: 0.04em;
        }

        .privacy-consent-overview-strip .metric-chip strong,
        .privacy-consent-settings-summary .metric-chip strong {
            margin-top: 3px;
            color: #173e56;
            font-size: 0.92rem;
            font-weight: 900;
        }

        .privacy-consent-version-badge {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-height: 32px;
            padding: 0 12px;
            border-radius: 999px;
            font-size: 0.78rem;
            font-weight: 800;
            letter-spacing: 0.04em;
        }

        .privacy-consent-version-badge.is-on {
            color: #0f6f58;
            background: rgba(79, 184, 126, 0.16);
        }

        .privacy-consent-version-badge.is-off {
            color: #8f5c2c;
            background: rgba(244, 191, 117, 0.16);
        }

        .privacy-consent-settings-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 8px;
        }

        .privacy-consent-preview-card {
            margin: 0;
            padding: 10px;
            border-radius: 18px;
            border: 1px solid rgba(201, 219, 233, 0.82);
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 253, 0.96));
            box-shadow: 0 12px 22px rgba(18, 52, 81, 0.05);
        }

        .privacy-consent-preview-shell {
            padding: 11px 12px;
            border-radius: 18px;
            background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(248, 251, 254, 0.96));
            border: 1px solid rgba(213, 227, 238, 0.86);
        }

        .privacy-consent-preview-shell--editable {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .privacy-consent-preview-shell--editable {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }

        .privacy-consent-preview-toolbar {
            display: flex;
            justify-content: space-between;
            gap: 10px;
            align-items: flex-start;
        }

        .privacy-consent-preview-head h4 {
            margin: 0;
            color: #18354b;
            font-size: 1.08rem;
            font-weight: 900;
            letter-spacing: -0.025em;
            line-height: 1.2;
        }

        .privacy-consent-inline-layout {
            display: grid;
            grid-template-columns: 1fr;
            gap: 8px;
            align-items: start;
        }

        .privacy-consent-preview-notice-title {
            margin: 8px 0 10px;
            color: #18354b;
            font-size: 0.92rem;
            font-weight: 900;
            line-height: 1.35;
        }

        .privacy-consent-inline-field {
            display: flex;
            flex-direction: column;
            gap: 4px;
            min-width: 0;
        }

        .privacy-consent-inline-field label {
            color: #6c8296;
            font-size: 0.72rem;
            font-weight: 800;
            letter-spacing: 0.04em;
        }

        .privacy-consent-inline-input,
        .privacy-consent-inline-textarea {
            width: 100%;
            border: 1px solid rgba(196, 213, 226, 0.9);
            border-radius: 14px;
            background: rgba(255, 255, 255, 0.96);
            color: #18354b;
            font-size: 0.8rem;
            font-weight: 400;
            line-height: 1.48;
            padding: 9px 11px;
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.65);
            font-family: inherit;
        }

        .privacy-consent-inline-input:focus,
        .privacy-consent-inline-textarea:focus {
            outline: none;
            border-color: rgba(94, 151, 179, 0.88);
            box-shadow: 0 0 0 4px rgba(109, 157, 183, 0.16);
        }

        .privacy-consent-inline-input--title {
            font-size: 0.9rem;
            font-weight: 400;
        }

        .privacy-consent-inline-textarea {
            min-height: 84px;
            resize: vertical;
            overflow-y: auto;
        }

        .privacy-consent-inline-textarea--intro {
            min-height: 84px;
        }

        .privacy-consent-inline-textarea--compact {
            min-height: 72px;
        }

        .privacy-consent-inline-help {
            margin: 0;
            color: #7f95a8;
            font-size: 0.68rem;
            line-height: 1.4;
        }

        .privacy-consent-preview-intro,
        .privacy-consent-preview-copy {
            margin: 0;
            color: #587285;
            font-size: 0.82rem;
            line-height: 1.54;
        }

        .privacy-consent-preview-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 8px;
            margin-top: 8px;
        }

        .privacy-consent-preview-block {
            padding: 10px 10px 9px;
            border-radius: 15px;
            border: 1px solid rgba(211, 225, 236, 0.88);
            background: rgba(244, 248, 252, 0.96);
            display: flex;
            flex-direction: column;
            gap: 8px;
            min-height: 220px;
        }

        .privacy-consent-preview-block .privacy-consent-inline-field {
            flex: 1 1 auto;
        }

        .privacy-consent-preview-block .privacy-consent-inline-textarea {
            flex: 1 1 auto;
            min-height: 0;
        }

        #privacy-consent-purpose-items {
            min-height: 136px;
        }

        .privacy-consent-preview-block h5 {
            margin: 0 0 4px;
            color: #18354b;
            font-size: 0.79rem;
            font-weight: 900;
            line-height: 1.32;
        }

        .privacy-consent-preview-block ul {
            margin: 0;
            padding-left: 18px;
            color: #587285;
            font-size: 0.75rem;
            line-height: 1.42;
        }

        .privacy-consent-preview-block li + li {
            margin-top: 4px;
        }

        .privacy-consent-preview-foot {
            display: flex;
            justify-content: space-between;
            gap: 10px;
            align-items: flex-end;
            margin-top: 8px;
            padding: 8px 0 0;
        }

        .privacy-consent-preview-check {
            flex: 1 1 auto;
            min-height: 50px;
            border-radius: 14px;
            padding: 10px 12px;
            background: rgba(250, 252, 254, 0.98);
            border: 1px solid rgba(213, 227, 238, 0.88);
        }

        .privacy-consent-inline-field--checkbox {
            justify-content: center;
        }

        .privacy-consent-preview-check--editable {
            padding: 11px 12px;
        }

        .privacy-consent-preview-actions {
            display: flex;
            gap: 8px;
            flex: 0 0 auto;
        }

        .privacy-consent-preview-actions .btn {
            min-width: 100px;
            min-height: 38px;
            border-radius: 12px;
        }

        .privacy-consent-form-sections {
            display: grid;
            gap: 8px;
        }

        .privacy-consent-form-card {
            padding: 10px;
            border-radius: 15px;
            border: 1px solid rgba(207, 221, 232, 0.88);
            background: rgba(251, 253, 255, 0.97);
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.62);
        }

        .privacy-consent-form-card-head {
            margin-bottom: 6px;
        }

        .privacy-consent-form-card-head h4 {
            margin: 0 0 3px;
            color: #173e56;
            font-size: 0.84rem;
            font-weight: 900;
        }

        .privacy-consent-form-card-head p {
            margin: 0;
            color: #6c8296;
            font-size: 0.74rem;
            line-height: 1.42;
        }

        .privacy-consent-settings-grid .field.full {
            grid-column: 1 / -1;
        }

        .privacy-consent-settings-grid textarea {
            min-height: 68px;
            resize: vertical;
        }

        .privacy-consent-publish-toggle {
            min-height: 40px;
            border-radius: 12px;
            padding: 10px 12px;
            background: rgba(244, 248, 252, 0.96);
            border: 1px solid rgba(180, 202, 225, 0.62);
        }

        .privacy-consent-toolbar {
            display: grid;
            grid-template-columns: minmax(0, 1fr) auto;
            gap: 6px;
            align-items: end;
            margin: 0;
            padding: 10px;
            border-radius: 16px;
            border: 1px solid rgba(209, 223, 235, 0.82);
            background: linear-gradient(180deg, rgba(249, 252, 254, 0.98), rgba(244, 248, 252, 0.96));
        }

        .privacy-consent-toolbar-field {
            margin: 0;
        }

        .privacy-consent-toolbar-actions {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
            justify-content: flex-end;
        }

        .privacy-consent-toolbar-actions .btn {
            min-width: 96px;
            min-height: 36px;
            border-radius: 12px;
        }

        #privacy-consent-records-body-panel {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }

        .privacy-consent-target-input {
            width: 100%;
        }

        .privacy-consent-meta-row {
            margin: 0;
            padding: 0 2px;
            color: #6c8296;
            font-size: 0.74rem;
            font-weight: 700;
        }

        .privacy-consent-name-cell,
        .privacy-consent-affiliation-cell {
            display: flex;
            flex-direction: column;
            gap: 1px;
        }

        .privacy-consent-name-cell strong,
        .privacy-consent-affiliation-cell strong {
            font-size: 0.86rem;
            color: #18344b;
            font-weight: 400;
        }

        .privacy-consent-name-cell span,
        .privacy-consent-affiliation-cell span {
            color: #6c8296;
            font-size: 0.64rem;
            font-weight: 400;
            line-height: 1.2;
        }

        .privacy-consent-status-pill {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-height: 22px;
            padding: 0 8px;
            border-radius: 999px;
            font-size: 0.64rem;
            font-weight: 600;
            letter-spacing: 0.01em;
            white-space: nowrap;
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
        }

        .privacy-consent-status-pill--accepted {
            color: #0f6f58;
            background: rgba(79, 184, 126, 0.18);
        }

        .privacy-consent-status-pill--requested {
            color: #934f82;
            background: rgba(226, 105, 139, 0.16);
        }

        .privacy-consent-status-pill--pending {
            color: #9a5b19;
            background: rgba(244, 191, 117, 0.22);
        }

        .privacy-consent-status-pill--inactive {
            color: #5d7287;
            background: rgba(216, 227, 238, 0.72);
        }

        #privacy-consent-records-wrap {
            flex: 1 1 auto;
            min-height: 0;
            height: 932px;
            max-height: 932px;
            align-self: stretch;
            border-radius: 20px;
            border-color: rgba(205, 220, 233, 0.86);
            box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
            overflow-y: auto;
            overflow-x: hidden;
        }

        #admin-privacy-panel #privacy-consent-records-wrap {
            max-height: 932px;
            height: 932px;
            overflow-x: hidden;
            overflow-y: auto;
        }

        #privacy-consent-records-wrap table {
            width: 100%;
            min-width: 0;
            table-layout: fixed;
        }

        #privacy-consent-records-wrap table thead th {
            position: sticky;
            top: 0;
            z-index: 1;
            background: rgba(246, 250, 253, 0.98);
            padding-top: 7px;
            padding-bottom: 7px;
            font-size: 0.69rem;
            font-weight: 600;
        }

        #privacy-consent-records-wrap table thead th:nth-child(1),
        #privacy-consent-records-wrap table tbody td:nth-child(1) {
            width: 42px;
            min-width: 42px;
            max-width: 42px;
            text-align: center;
            padding-left: 0;
            padding-right: 0;
        }

        #privacy-consent-records-wrap table thead th:nth-child(2),
        #privacy-consent-records-wrap table tbody td:nth-child(2) {
            width: 15%;
        }

        #privacy-consent-records-wrap table thead th:nth-child(3),
        #privacy-consent-records-wrap table tbody td:nth-child(3) {
            width: 11%;
        }

        #privacy-consent-records-wrap table thead th:nth-child(4),
        #privacy-consent-records-wrap table tbody td:nth-child(4) {
            width: 22%;
        }

        #privacy-consent-records-wrap table thead th:nth-child(5),
        #privacy-consent-records-wrap table tbody td:nth-child(5) {
            width: 13%;
        }

        #privacy-consent-records-wrap table thead th:nth-child(6),
        #privacy-consent-records-wrap table tbody td:nth-child(6) {
            width: 20%;
        }

        #privacy-consent-records-wrap table thead th:nth-child(7),
        #privacy-consent-records-wrap table tbody td:nth-child(7) {
            width: 15%;
        }

        #privacy-consent-records-wrap .admin-table-sort-btn {
            justify-content: flex-start;
            white-space: normal;
            font-weight: 500;
        }

        #privacy-consent-records-wrap .admin-table-sort-btn .sort-label {
            white-space: normal;
            font-size: 0.68rem;
            font-weight: 500;
            line-height: 1.25;
        }

        #privacy-consent-records-wrap .admin-table-sort-btn .sort-arrow {
            font-size: 0.62rem;
            min-width: 8px;
        }

        #privacy-consent-records-wrap table td {
            vertical-align: middle;
            padding-top: 6px;
            padding-bottom: 6px;
            font-size: 0.7rem;
            font-weight: 400;
            line-height: 1.35;
        }

#privacy-consent-records-wrap .privacy-consent-name-cell strong,
#privacy-consent-records-wrap .privacy-consent-affiliation-cell strong {
    font-size: 0.8rem;
    line-height: 1.25;
    font-weight: 400;
}

#dutyfree-consent-records-wrap table thead th {
    font-size: 0.64rem;
    padding-top: 6px;
    padding-bottom: 6px;
}

#dutyfree-consent-records-wrap .admin-table-sort-btn .sort-label {
    font-size: 0.63rem;
    line-height: 1.2;
}

#dutyfree-consent-records-wrap .admin-table-sort-btn .sort-arrow {
    font-size: 0.58rem;
}

#dutyfree-consent-records-wrap table td {
    font-size: 0.66rem;
    line-height: 1.28;
    padding-top: 5px;
    padding-bottom: 5px;
}

#dutyfree-consent-records-wrap .privacy-consent-name-cell strong,
#dutyfree-consent-records-wrap .privacy-consent-affiliation-cell strong {
    font-size: 0.74rem;
    line-height: 1.2;
}

#dutyfree-consent-records-wrap .privacy-consent-name-cell span,
#dutyfree-consent-records-wrap .privacy-consent-affiliation-cell span {
    font-size: 0.62rem;
    line-height: 1.15;
}

        #privacy-consent-records-wrap tbody tr:hover {
            background: rgba(244, 249, 253, 0.94);
        }

        @media (max-width: 1180px) {
            .privacy-consent-admin-grid {
                grid-template-columns: 1fr;
            }

            .privacy-consent-overview-strip {
                grid-template-columns: repeat(3, minmax(0, 1fr));
            }

            .privacy-consent-record-summary {
                grid-template-columns: repeat(2, minmax(0, 1fr));
            }
        }

        @media (max-width: 900px) {
            .privacy-consent-overview-strip,
            .privacy-consent-settings-summary,
            .privacy-consent-preview-grid,
            .privacy-consent-settings-grid,
            .privacy-consent-record-summary {
                grid-template-columns: 1fr;
            }

            .privacy-consent-editor-topline {
                flex-direction: column;
                align-items: stretch;
            }

            .privacy-consent-editor-note {
                max-width: none;
                text-align: left;
            }

            .privacy-consent-inline-layout {
                grid-template-columns: 1fr;
            }

            .privacy-consent-toolbar {
                grid-template-columns: 1fr;
            }

            .privacy-consent-records-head {
                flex-direction: column;
                align-items: stretch;
            }

            .privacy-consent-preview-foot {
                flex-direction: column;
                align-items: stretch;
            }

            .privacy-consent-preview-toolbar {
                flex-direction: column;
                align-items: stretch;
            }

            .privacy-consent-preview-actions,
            .privacy-consent-toolbar-actions {
                justify-content: stretch;
            }

            .privacy-consent-preview-actions .btn,
            .privacy-consent-toolbar-actions .btn {
                flex: 1 1 auto;
            }
        }

        @media (max-width: 760px) {
            #admin-privacy-panel,
            #admin-privacy-panel .privacy-consent-admin-grid,
            #admin-privacy-panel .privacy-consent-editor-card,
            #admin-privacy-panel .privacy-consent-records-card,
            #admin-privacy-panel .privacy-consent-preview-card,
            #admin-privacy-panel .privacy-consent-preview-shell,
            #admin-privacy-panel #privacy-consent-records-wrap,
            #admin-privacy-panel .table-wrap {
                width: 100%;
                min-width: 0;
                max-width: 100%;
                box-sizing: border-box;
            }

            #admin-privacy-panel .privacy-consent-editor-card,
            #admin-privacy-panel .privacy-consent-records-card,
            #admin-privacy-panel .privacy-consent-preview-card {
                padding: 12px;
                border-radius: 16px;
            }

            #admin-privacy-panel .privacy-consent-preview-shell {
                padding: 10px;
                border-radius: 14px;
            }

            #admin-privacy-panel .privacy-consent-records-badge,
            #admin-privacy-panel .privacy-consent-version-badge {
                min-width: 0;
                max-width: 100%;
                white-space: normal;
                text-align: center;
            }

            #admin-privacy-panel .privacy-consent-editor-head .section-title,
            #admin-privacy-panel .privacy-consent-records-head .section-title {
                font-size: 1rem;
            }

            #admin-privacy-panel .privacy-consent-editor-note {
                font-size: 0.72rem;
                line-height: 1.45;
            }

            #admin-privacy-panel #privacy-consent-records-wrap {
                overflow-x: visible;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table {
                min-width: 0;
                width: 100%;
                table-layout: fixed;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table thead th,
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td {
                padding: 8px 6px;
                font-size: 0.78rem;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(3),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(3),
            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(6),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(6),
            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(7),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(7) {
                display: none;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(1),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(1) {
                width: 36px;
                min-width: 36px;
                max-width: 36px;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(2),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(2) {
                width: 37%;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(4),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(4) {
                width: 39%;
            }

            #admin-privacy-panel #privacy-consent-records-wrap table thead th:nth-child(5),
            #admin-privacy-panel #privacy-consent-records-wrap table tbody td:nth-child(5) {
                width: 24%;
            }

            #admin-privacy-panel #privacy-consent-records-wrap .admin-table-sort-btn,
            #admin-privacy-panel #privacy-consent-records-wrap .admin-table-sort-btn .sort-label {
                white-space: normal;
                line-height: 1.25;
            }

            #admin-privacy-panel #privacy-consent-records-wrap .privacy-consent-status-pill {
                min-height: 22px;
                padding: 0 7px;
                font-size: 0.64rem;
            }

            #admin-privacy-panel .privacy-consent-name-cell,
            #admin-privacy-panel .privacy-consent-affiliation-cell {
                gap: 2px;
            }

            #admin-privacy-panel .privacy-consent-name-cell strong,
            #admin-privacy-panel .privacy-consent-affiliation-cell strong,
            #admin-privacy-panel .privacy-consent-affiliation-cell span {
                word-break: keep-all;
                overflow-wrap: anywhere;
            }

            #admin-privacy-panel .privacy-consent-name-cell strong,
            #admin-privacy-panel .privacy-consent-affiliation-cell strong {
                font-size: 0.8rem;
            }

            #admin-privacy-panel .privacy-consent-name-cell span,
            #admin-privacy-panel .privacy-consent-affiliation-cell span {
                font-size: 0.64rem;
            }
        }
.survey-insight-filter-shell {
    display: grid;
    gap: 10px;
    padding: 16px 18px;
}

.survey-insight-filter-head {
    margin-bottom: 0;
    align-items: end;
}

.survey-insight-filter-head .section-title {
    margin-bottom: 4px;
}

.survey-insight-filter-head .section-desc {
    margin: 0;
    font-size: 12px;
    line-height: 1.5;
}

.survey-insight-filter-grid {
    display: grid;
    grid-template-columns: minmax(150px, 180px) minmax(150px, 180px) auto;
    gap: 10px;
    align-items: end;
}

.survey-insight-filter-actions {
    justify-content: flex-start;
    align-self: end;
}

.survey-insight-filter-shell .field label {
    margin-bottom: 6px;
    font-size: 12px;
}

.survey-insight-filter-shell .table-field {
    height: 40px;
}

.survey-insight-summary-note {
    margin: 0 0 14px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid rgba(218, 171, 67, 0.28);
    background: rgba(255, 248, 229, 0.9);
    color: #805e14;
    font-size: 13px;
    line-height: 1.6;
}

@media (max-width: 840px) {
    .survey-insight-filter-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 10px;
    }

    .survey-insight-filter-grid .field {
        display: grid;
        grid-template-columns: 58px minmax(0, 1fr);
        align-items: center;
        gap: 8px;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .survey-insight-filter-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        justify-content: stretch;
        gap: 8px;
        width: 100%;
    }

    .survey-insight-filter-actions .btn-main,
    .survey-insight-filter-actions .btn-ghost {
        width: 100%;
        min-width: 0;
        min-height: 38px;
        justify-content: center;
    }

    .survey-insight-filter-shell {
        padding: 14px;
    }

    .survey-insight-filter-shell .field label {
        margin-bottom: 0;
        font-size: 11px;
    }

    .survey-insight-filter-shell .table-field {
        height: 38px;
        width: 100%;
        inline-size: 100%;
        max-width: 100%;
        max-inline-size: 100%;
        min-width: 0;
        min-inline-size: 0;
        box-sizing: border-box;
        font-size: 0.78rem;
        padding-left: 8px;
        padding-right: 8px;
        text-align: left;
        overflow: hidden;
        text-overflow: ellipsis;
        appearance: none;
        -webkit-appearance: none;
    }
}

@media (max-width: 560px) {
    .survey-insight-filter-actions {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Mobile usability pass for manager store setup and compact admin review. */
@media (max-width: 760px) {
    .admin-tab-row {
        display: flex;
        grid-template-columns: none;
        overflow-x: auto;
        overflow-y: hidden;
        gap: 6px;
        padding-bottom: 6px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .admin-section-tab-btn {
        flex: 0 0 auto;
        width: auto;
        min-width: 92px;
        min-height: 40px;
        padding: 9px 12px;
        white-space: nowrap;
    }

    .manager-store-setup-overlay {
        padding: 10px;
        align-items: stretch;
    }

    .manager-store-setup-dialog {
        width: 100%;
        max-height: calc(100dvh - 20px);
        padding: 14px;
        border-radius: 18px;
    }

    .manager-store-setup-head h3 {
        font-size: 1.08rem;
        line-height: 1.25;
    }

    .manager-store-setup-head p {
        font-size: 0.78rem;
        line-height: 1.45;
    }

    .manager-store-setup-body {
        padding-right: 0;
    }

    .manager-store-setup-body .member-store-inline-panel,
    .manager-store-setup-body .store-mapping-detail {
        min-width: 0;
    }

    .manager-store-setup-body .store-mapping-summary {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .manager-store-setup-body .store-mapping-summary .metric-chip {
        min-height: 58px;
        padding: 9px 10px;
    }

    .manager-store-setup-body .store-mapping-toolbar {
        position: sticky;
        top: 0;
        z-index: 2;
        padding: 8px 0;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: blur(8px);
    }

    .store-mapping-actions,
    .store-mapping-toolbar-right {
        width: 100%;
        margin-left: 0;
        display: grid;
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .store-mapping-actions button,
    .store-mapping-toolbar-right > * {
        width: 100%;
        min-width: 0;
    }

    .store-mapping-detail-head {
        flex-direction: column;
    }

    .store-mapping-filter-toggle {
        justify-content: flex-start;
    }

    .store-mapping-chip {
        max-width: 100%;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .manager-store-setup-body .store-mapping-store-list {
        max-height: min(46dvh, 420px);
        padding-right: 0;
    }

    .manager-store-setup-body .store-mapping-store-card {
        padding: 10px;
        border-radius: 12px;
    }

    .manager-store-setup-body .store-mapping-store-card label {
        grid-template-columns: 24px minmax(0, 1fr);
        align-items: start;
    }

    .manager-store-setup-body .store-mapping-store-main {
        grid-template-columns: minmax(0, 1fr);
        gap: 4px;
    }

    .manager-store-setup-body .store-mapping-store-main strong,
    .manager-store-setup-body .store-mapping-store-sub,
    .manager-store-setup-body .store-mapping-store-meta,
    .manager-store-setup-body .store-mapping-store-phone,
    .manager-store-setup-body .store-mapping-store-address {
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        word-break: keep-all;
        overflow-wrap: anywhere;
    }
}

@media (max-width: 480px) {
    .admin-section-tab-btn {
        min-width: 84px;
        font-size: 0.72rem;
    }

    .manager-store-setup-dialog {
        padding: 12px;
        border-radius: 16px;
    }
}
