.frontend .mobile-category-trigger { display: none; }
.frontend dialog.category-browser { padding: 0; border: 0; margin: 0; width: 100vw; max-width: none; height: 100dvh; max-height: none; border-radius: 0; color: #17243b; background: #fff; overflow: hidden; }
.category-browser-form { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.category-browser-header { display: flex; align-items: center; gap: 8px; flex-shrink: 0; padding: calc(10px + env(safe-area-inset-top)) 14px 10px; border-bottom: 1px solid #e2e8f0; background: #fff; }
.category-browser-header h2 { margin: 0; font-size: 18px; font-weight: 800; }
.category-browser-header button { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 10px; background: #f4f7fb; color: #17243b; }
.category-browser-header svg { width: 21px; }
.category-browser-body { display: grid; grid-template-columns: 90px minmax(0, 1fr); flex: 1; min-height: 0; }
.category-browser-rail { overflow-y: auto; overscroll-behavior: contain; background: #edf4ff; padding-bottom: 12px; scrollbar-width: thin; }
.category-browser-rail button { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 92px; padding: 14px 8px; border: 0; border-bottom: 1px solid #dfe8f5; background: transparent; color: #52637a; font: 600 11px/1.4 'DM Sans', sans-serif; overflow-wrap: anywhere; }
.category-browser-rail button[aria-pressed="true"] { color: #155bd7; background: #fff; }
.category-browser-rail button[aria-pressed="true"]::before { position: absolute; content: ''; width: 3px; left: 0; top: 12px; bottom: 12px; background: #155bd7; border-radius: 0 4px 4px 0; }
.category-browser-rail img, .category-rail-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; object-fit: cover; background: #e1ebfa; }
.category-rail-icon svg { width: 22px; }
.category-browser-content { min-width: 0; overflow-y: auto; overscroll-behavior: contain; padding: 16px 14px 24px; }
.category-browser-panel[hidden] { display: none; }
.category-browser-panel h4 { margin: 0 0 18px; font-size: 14px; font-weight: 800; }
.category-browser-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 10px; }
.category-browser-grid > button { display: flex; flex-direction: column; align-items: center; gap: 9px; min-width: 0; padding: 0; background: none; border: 0; color: #26354b; font: 600 11px/1.4 'DM Sans', sans-serif; overflow-wrap: anywhere; }
.category-option-image { position: relative; display: grid; place-items: center; width: 62px; max-width: 100%; aspect-ratio: 1; border-radius: 50%; border: 2px solid transparent; background: #f2f5fa; color: #5478b3; }
.category-option-image > img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.category-option-image > svg { width: 25px; height: 25px; }
.category-option-check { display: none; position: absolute; right: -2px; bottom: -2px; width: 20px; height: 20px; border-radius: 50%; border: 2px solid #fff; color: white; background: #155bd7; font-size: 11px; }
.category-browser-grid > button[aria-pressed="true"] { color: #155bd7; }
.category-browser-grid > button[aria-pressed="true"] .category-option-image { border-color: #155bd7; background: #e9f1ff; }
.category-browser-grid > button[aria-pressed="true"] .category-option-check { display: block; }
.category-browser-note { margin-top: 24px; color: #65758c; font-size: 13px; line-height: 1.7; }
.category-browser-footer { flex-shrink: 0; border-top: 1px solid #e2e8f0; padding: 10px 18px calc(14px + env(safe-area-inset-bottom)); background: #fff; box-shadow: 0 -4px 18px #17243b08; }
.category-browser-footer p { margin: 0 0 8px; font-size: 12px; color: #52637a; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.category-browser-footer button { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; min-height: 48px; border: 0; border-radius: 12px; background: #155bd7; color: #fff; font-size: 15px; font-weight: 700; }
.category-browser-footer svg { width: 18px; }
@media (max-width: 767px) {
    .frontend .mobile-category-trigger { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 14px; margin-bottom: 14px; border: 1px solid #cbdcf7; border-radius: 10px; color: #155bd7; background: #fff; font-size: 13px; font-weight: 700; text-decoration: none; }
    .mobile-category-trigger svg { width: 18px; }
}
@media (max-width: 350px) {
    .category-browser-body { grid-template-columns: 78px minmax(0, 1fr); }
    .category-browser-content { padding-inline: 12px; }
    .category-browser-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.category-browser-name { margin: 0 0 8px; font-size: 20px; line-height: 1.3; overflow-wrap: anywhere; }

.frontend .category-browser .advertisement-slot-category_modal { margin: 0 0 22px; }
.frontend .category-browser .advertisement-image { height: auto; max-height: 220px; object-fit: contain; }
.frontend .category-browser .advertisement-item { border-radius: 12px; box-shadow: none; }

.category-browser [hidden] { display: none !important; }
.category-search-home { flex: 1; overflow-y: auto; min-height: 0; background: #fff; }
.category-browser-header .category-search-action { margin-left: auto; width: auto; padding: 0 4px; background: transparent; color: #155bd7; font-size: 14px; font-weight: 800; text-decoration: underline; }
.category-search-fields { display: grid; gap: 10px; padding: 16px; }
.category-search-fields label { display: flex; align-items: center; gap: 12px; border: 1px solid #536071; border-radius: 5px; padding: 10px 12px; margin: 0; }
.category-search-fields label:focus-within { border-color: #155bd7; box-shadow: 0 0 0 2px #e5eeff; }
.category-search-fields svg { width: 20px; height: 20px; flex-shrink: 0; }
.category-search-fields input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 16px; color: #17243b; }
.category-recent, .category-popular { padding: 18px 16px; }
.category-popular { border-top: 5px solid #f4f5f7; }
.category-search-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.category-search-heading h3 { margin: 0; font-size: 14px; font-weight: 800; }
.category-search-heading button { border: 0; background: transparent; color: #155bd7; font-size: 13px; font-weight: 700; }
.category-recent-items { display: flex; flex-wrap: wrap; gap: 8px; }
.category-recent-items button { padding: 8px 12px; border: 1px solid #d5d9df; border-radius: 24px; background: #fff; font-size: 12px; max-width: 100%; overflow-wrap: anywhere; }
.category-popular-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px 8px; }
.category-popular-grid button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0; border: 0; background: none; min-width: 0; color: #17243b; }
.category-popular-grid button > span { display: grid; place-items: center; width: 100%; aspect-ratio: 1; border-radius: 10px; background: #f3f4f6; overflow: hidden; }
.category-popular-grid img { width: 80%; height: 80%; object-fit: contain; }
.category-popular-grid b { font-size: 10px; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.category-popular-grid button:focus-visible { outline: 2px solid #155bd7; outline-offset: 4px; border-radius: 6px; }
@media(max-width:350px) { .category-popular-grid { grid-template-columns: repeat(4,minmax(0,1fr)); } }
.category-location-picker { position: relative; }
.category-location-menu { position: absolute; z-index: 5; top: 0; left: 0; right: 0; max-height: min(490px, 65dvh); overflow-y: auto; overscroll-behavior: contain; border: 1px solid #d8dfe9; border-radius: 12px; background: #fff; box-shadow: 0 12px 30px #17243b26; }
.category-location-menu .category-place-search { margin: 8px; padding: 9px; border-color: #c6d6ef; }
.category-place-search:focus-within { outline: 2px solid #397dff; outline-offset: 1px; }
.category-location-menu button { display: flex; align-items: center; gap: 13px; width: 100%; padding: 13px 16px; border: 0; background: #fff; color: #17243b; text-align: left; font-size: 12px; }
.category-location-menu button:hover, .category-location-menu button:focus-visible { background: #edf4ff; outline: 0; }
.category-location-menu button svg { width: 18px; height: 18px; flex-shrink: 0; color: #96a1b2; }
.category-location-menu .category-current-location { color: #2563ff; padding-block: 18px; }
.category-current-location svg { color: #2563ff !important; }
.category-current-location b, .category-current-location small { display: block; }
.category-current-location small { margin-top: 5px; font-size: 10px; font-weight: 400; }
.category-location-menu section { border-top: 1px solid #e5eaf1; padding: 8px 0; }
.category-location-menu h4 { margin: 8px 16px; color: #8c98aa; font-size: 9px; font-weight: 500; text-transform: uppercase; }
