/* The in-app administration renderer owns this stylesheet; /dealer.html is separate. */
.admin-full-page { display: none; }
.admin-mode .app-content { display: none; }
.admin-mode .admin-full-page { display: block; height: calc(100vh - 60px); min-width: 1050px; color: #2d2c33; background: #eff3f6; }
.admin-full-page .dealer-page { height: 100%; display: grid; grid-template-rows: 60px 70px minmax(0, 1fr); padding-bottom: 20px; }
.dealer-admin-top { display: flex; align-items: center; justify-content: space-between; padding: 0 20px; border-bottom: 1px solid #e6eaee; background: #fff; }
.dealer-admin-top .dealer-page-title { font-size: 24px; font-weight: 400; line-height: normal; }
.dealer-page-actions { display: flex; align-items: center; gap: 10px; }
.dealer-action-blue { width: 36px; height: 36px; padding: 0; border: 0; border-radius: 4px; background: #4285f4; cursor: pointer; }
.dealer-action-blue svg { display: block; width: 36px; height: 36px; }
.dealer-action-blue:hover { background: #2a77f5; }
.dealer-admin-tabs { display: flex; align-items: end; gap: 5px; padding: 20px 20px 0; }
.dealer-admin-tab { position: relative; height: 45px; padding: 14px 20px 0; align-self: end; display: flex; align-items: flex-start; justify-content: center; border: 1px solid #e6eaee; border-bottom: 0; border-radius: 4px 4px 0 0; font: 400 14px/normal Lato, sans-serif; color: #999da8; background: #fff; cursor: pointer; text-align: center; }
.dealer-admin-tab.active { height: 50px; padding-top: 17px; font-size: 16px; color: #2d2c33; }
.dealer-admin-tab.active::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: #fff; z-index: 1; }
.dealer-admin-tab:hover { color: #2d2c33; }
.dealer-section-panel { min-height: 0; margin: 0 20px; overflow: auto; background: #fff; border: 1px solid #e6eaee; border-radius: 0 4px 4px; }
.admin-full-page button:focus-visible { outline: 2px solid #4285f4; outline-offset: 2px; }

/* Access table, including the observable zero-user state. */
.dealer-access-section { height: 100%; min-height: 0; display: flex; flex-direction: column; }
.dealer-toolbar { flex: 0 0 60px; display: flex; align-items: center; padding: 12px 20px; }
.dealer-toolbar-spacer { flex: 1; }
.dealer-search-wrap { position: relative; display: block; width: 250px; height: 36px; }
.dealer-search { width: 100%; height: 36px; padding: 5px 34px 5px 10px; border: 1px solid rgba(153,157,168,.4); border-radius: 4px; outline: 0; font: 14px/normal Lato,sans-serif; color: #2d2c33; background: #fff; }
.dealer-search:focus { border-color: #4285f4; }
.dealer-search::placeholder { color: #999da8; opacity: 1; }
.dealer-search-wrap svg { position: absolute; right: 8px; top: 8px; width: 20px; height: 20px; fill: none; stroke: #999da8; stroke-width: 1.5; pointer-events: none; }
.dealer-rights-table { width: 100%; table-layout: fixed; font-size: 14px; }
.dealer-rights-table th { height: 36px; font-size: 12px; font-weight: 400; text-align: left; color: rgba(45,44,51,.7); background: #f8fafc; border-block: 1px solid #e6eaee; }
.dealer-rights-table td { height: 56px; border-bottom: 1px solid #e6eaee; }
.dealer-access-table { display: block; flex: 0 0 auto; }
.dealer-access-table thead, .dealer-access-table tbody { display: block; }
.dealer-access-table tr { display: flex; padding-left: 10px; }
.dealer-access-table th, .dealer-access-table td { flex: 1 1 116px; min-width: 116px; padding: 9px 10px; }
.dealer-access-table th:first-child, .dealer-access-table td:first-child { flex-grow: 5; }
.dealer-access-table th:nth-child(4), .dealer-access-table td:nth-child(4), .dealer-access-table th:nth-child(6), .dealer-access-table td:nth-child(6) { flex-basis: 140px; min-width: 140px; }
.dealer-access-table th:nth-child(5), .dealer-access-table td:nth-child(5) { flex-basis: 204px; min-width: 204px; }
.dealer-access-table th:not(:first-child) { position: relative; padding-left: 20px; }
.dealer-access-table th:not(:first-child)::before { content: ''; position: absolute; left: 10px; top: 6px; height: 22px; border-left: 1px solid #e6eaee; }
.dealer-access-empty { flex: 1; min-height: 100px; display: flex; align-items: center; justify-content: center; padding: 16px 12px 12px; color: #999da8; font-size: 24px; }

/* Depot settings keep their existing values and save handler. */
.dealer-settings-savebar { height: 56px; display: flex; align-items: center; justify-content: flex-end; padding: 10px 20px; }
.dealer-settings-grid { display: flex; gap: 20px; align-items: flex-start; }
.dealer-timezone-grid { padding: 20px; border-bottom: 1px solid #e6eaee; }
.dealer-field { display: flex; flex: 0 0 260px; flex-direction: column; gap: 6px; margin: 0; }
.dealer-field-label, .dealer-field-hint { font: 12px/normal Lato,sans-serif; color: rgba(45,44,51,.7); }
.dealer-control { display: block; width: 260px; height: 36px; padding: 5px 10px; border: 1px solid rgba(153,157,168,.4); border-radius: 4px; background: white; color: #2d2c33; font: 14px/normal Lato,sans-serif; outline: 0; }
.dealer-control:focus { border-color: #4285f4; }
.dealer-select-wrap { display: block; position: relative; }
.dealer-select-wrap select { appearance: none; padding-right: 30px; }
.dealer-select-wrap::after { content: ''; position: absolute; top: 11px; right: 9px; width: 14px; height: 14px; background: #999da8; mask: url('/nimbus-icons/user-chevron.svg') center / contain no-repeat; pointer-events: none; }
.dealer-activation-block { padding: 20px; }
.dealer-online-card { display: flex; align-items: center; justify-content: space-between; padding: 12px; border: 1px solid #e6eaee; border-radius: 4px; margin-bottom: 20px; }
.dealer-online-title { font-size: 18px; line-height: normal; margin-bottom: 4px; }
.dealer-online-text { color: rgba(45,44,51,.7); font: 12px/normal Lato,sans-serif; }
.dealer-toggle { display: inline-block; vertical-align: top; flex: 0 0 80px; height: 41px; padding: 8px 22px; cursor: pointer; }
.dealer-toggle span { position: relative; display: inline-block; vertical-align: middle; width: 36px; height: 16px; line-height: 20px; background: #eff3f6; border: 1px solid #eff3f6; border-radius: 20px; box-shadow: inset 0 1px 2px rgba(45,44,51,.35); }
.dealer-toggle span::after { content: ''; position: absolute; width: 23px; height: 23px; left: -4px; top: -5px; background: #fff; border-radius: 50%; box-shadow: 0 0 4px rgba(45,44,51,.35); }
.dealer-toggle:has(input:checked) span::after { left: 15px; background: #32a754; }
.dealer-settings-title { font-size: 14px; line-height: normal; margin-bottom: 12px; }
.dealer-green-btn { display: inline-flex; align-items: center; gap: 4px; height: 36px; padding: 9px 16px 9px 12px; font: 700 14px/normal Lato,sans-serif; background: #32a754; border: 1px solid transparent; color: #fff; border-radius: 4px; cursor: pointer; }
.dealer-green-btn:hover:not(:disabled) { background: #03983a; }

/* Notifications list and empty state. */
.dealer-notifications-section { display: flex; flex-direction: column; height: 100%; }
.dealer-section-toolbar { height: 56px; flex: 0 0 56px; padding: 10px 20px; }
.dealer-notifications-table { display: block; }
.dealer-notifications-table thead, .dealer-notifications-table tbody { display: block; }
.dealer-notifications-table tr { display: grid; grid-template-columns: minmax(0,1fr) 90px minmax(0,calc(50% - 158px)) 120px 206px; padding-left: 20px; }
.dealer-notifications-table th, .dealer-notifications-table td { padding: 9px 10px; }
.dealer-notifications-table th:first-child, .dealer-notifications-table td:first-child { padding-left: 0; }
.dealer-empty-container { position: relative; flex: 1; min-height: 350px; }
.dealer-info-block { position: absolute; top: 50%; margin-top: -175px; width: 100%; padding: 22px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.dealer-info-icon { display: flex; align-items: center; justify-content: center; width: 120px; height: 120px; flex: 0 0 120px; margin-bottom: 16px; border-radius: 50%; background: #f8fafc; color: rgba(153,157,168,.7); }
.dealer-info-icon svg { width: 70px; height: 70px; fill: currentColor; }
.dealer-info-block h1 { margin: 10px 0; font-size: 24px; line-height: normal; font-weight: 400; color: #2d2c33; }
.dealer-info-block p { width: 360px; margin: 0 0 27px; font: 14px/normal Lato,sans-serif; color: rgba(45,44,51,.7); }
.dealer-green-btn img { width: 18px; height: 18px; filter: brightness(0) invert(1); }
.dealer-entry-dialog { width: 500px; max-width: calc(100vw - 40px); padding: 20px; border: 1px solid #e6eaee; border-radius: 4px; color: #2d2c33; }
.dealer-entry-dialog::backdrop { background: rgba(45,44,51,.4); }
.dealer-entry-dialog h2 { font-size: 24px; font-weight: 400; margin: 0 0 20px; }
.dealer-entry-dialog .dealer-field { margin-bottom: 16px; font-size: 12px; }
.dealer-entry-dialog footer { display: flex; justify-content: flex-end; gap: 10px; }
.dealer-entry-dialog footer > button { height: 36px; border: 1px solid #e6eaee; border-radius: 4px; padding: 8px 16px; cursor: pointer; }
.dealer-form-error { color: #d94f4f; }

/* Locator metadata table; an empty local dataset is never filled with original links. */
.dealer-locator-section { display: flex; flex-direction: column; height: 100%; }
.dealer-locator-table { display: block; }
.dealer-locator-table thead, .dealer-locator-table tbody { display: block; }
.dealer-locator-table tr { display: grid; grid-template-columns: minmax(200px,1fr) 230px 210px 210px 110px 170px; padding-left: 20px; }
.dealer-locator-table th, .dealer-locator-table td { padding: 9px 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dealer-locator-table th:first-child, .dealer-locator-table td:first-child { padding-left: 0; }
.dealer-locator-table td { display: flex; align-items: center; }
.dealer-locator-table a { color: #4285f4; }
.dealer-locator-empty { flex: 1; display: flex; align-items: center; justify-content: center; font-size: 24px; color: #999da8; }
.dealer-row-btn { height: 36px; padding: 7px; margin-right: 10px; border: 1px solid #e6eaee; border-radius: 4px; background: white; font-size: 12px; cursor: pointer; }

/* Route-group master/detail surface. */
.dealer-groups-section { height: 100%; display: flex; flex-direction: column; }
.dealer-groups-toolbar { display: flex; align-items: center; flex: 0 0 57px; border-bottom: 1px solid #e6eaee; padding-right: 10px; }
.dealer-groups-search { display: flex; gap: 20px; padding: 10px 14px 10px 20px; width: 340px; flex: 0 0 340px; }
.dealer-square-btn { width: 36px; padding: 8px; flex: 0 0 36px; }
.dealer-search-wrap > img { position: absolute; width: 20px; height: 20px; top: 8px; right: 8px; pointer-events: none; }
.dealer-group-heading { flex: 1; padding-left: 28px; font-size: 16px; }
.dealer-groups-toolbar .dealer-row-btn { width: 36px; padding: 7px; }
.dealer-row-btn img { width: 20px; height: 20px; display: block; }
.dealer-groups-content { display: flex; flex: 1; min-height: 0; }
.dealer-groups-list { flex: 0 0 340px; overflow: auto; box-shadow: inset -1px 0 #e6eaee; }
.dealer-group-row { width: 100%; height: 81px; display: flex; flex-direction: column; gap: 6px; padding: 12px 20px; border: 0; border-bottom: 1px solid #e6eaee; background: white; text-align: left; cursor: pointer; color: #2d2c33; font-size: 16px; }
.dealer-group-row.active, .dealer-group-row:hover { background: rgba(66,133,244,.05); }
.dealer-group-row small { font-size: 12px; color: #999da8; }
.dealer-group-routes { display: flex; flex: 1; min-width: 0; overflow: auto; }
.dealer-group-type { flex: 0 0 auto; border-right: 1px solid #e6eaee; min-width: 320px; }
.dealer-group-type h3 { margin: 0; height: 43px; display: flex; align-items: center; gap: 18px; padding: 14px 25px 8px; font-size: 14px; font-weight: 400; }
.dealer-group-type h3 img { width: 18px; height: 18px; }
.dealer-group-route-columns { display: flex; flex-direction: column; flex-wrap: wrap; align-content: flex-start; height: calc(100% - 43px); }
.dealer-group-route { height: 36px; display: flex; align-items: center; gap: 10px; padding: 5px 25px; font-size: 14px; }
.dealer-group-route-number { border: 1px solid #e6eaee; border-radius: 4px; padding: 3px 8px; }
.dealer-group-route-name { width: 200px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dealer-groups-no-results { padding: 20px; color: #999da8; font-size: 14px; }
.dealer-group-route-picker { max-height: 300px; overflow: auto; margin: 15px 0; }
.dealer-group-route-picker label { display: block; padding: 5px 0; font-size: 14px; }

.dealer-notifications-table th:not(:first-child):not(:last-child) { position: relative; }
.dealer-notifications-table th:not(:first-child):not(:last-child)::before { content: ""; position: absolute; left: 0; top: 7px; height: 22px; border-left: 1px solid #e6eaee; }
