.royal-switch {
    box-sizing: border-box;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    max-width: 720px;
    margin: 0 auto 12px;
    padding: 3px;
    border: 1px solid #baa9a5;
    border-radius: 10px;
    background: #f3ebe7;
}

.royal-switch > :is(a, span) {
    box-sizing: border-box;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-content: center;
    align-items: baseline;
    gap: 1px 8px;
    min-height: 42px;
    padding: 4px 6px;
    border: 1px solid var(--royal-switch-border);
    border-radius: 7px;
    background: var(--royal-switch-surface);
    color: var(--royal-switch-text);
    line-height: 1.16;
    text-align: center;
    text-decoration: none;
}

.royal-switch-salon {
    --royal-switch-surface: #f5f5f9;
    --royal-switch-text: #335570;
    --royal-switch-border: #a8bed1;
    --royal-switch-active: #dcebf9;
    --royal-switch-highlight: #72a5d1;
}

.royal-switch-style {
    --royal-switch-surface: #faf1f3;
    --royal-switch-text: #883751;
    --royal-switch-border: #daa9b8;
    --royal-switch-active: #f4d8e1;
    --royal-switch-highlight: #c0758e;
}

.royal-switch strong { font-size: 12px; }
.royal-switch small { font-size: 11px; white-space: nowrap; }

.royal-switch > [aria-current="page"],
.royal-switch > a:hover {
    background: var(--royal-switch-active);
    border-color: var(--royal-switch-highlight);
}

.royal-switch > a:focus-visible {
    outline: 2px solid var(--royal-switch-highlight);
    outline-offset: 2px;
}

body.theme-dark .royal-switch { border-color: #424551; background: #111620; }

body.theme-dark .royal-switch-salon {
    --royal-switch-surface: #181f2b;
    --royal-switch-text: #cfdfec;
    --royal-switch-border: #3e5063;
    --royal-switch-active: #213a54;
    --royal-switch-highlight: #72a5d1;
}

body.theme-dark .royal-switch-style {
    --royal-switch-surface: #231b26;
    --royal-switch-text: #f2cad9;
    --royal-switch-border: #634354;
    --royal-switch-active: #512e42;
    --royal-switch-highlight: #c9819d;
}

@media (max-width: 480px) {
    .royal-switch > :is(a, span) { min-height: 42px; flex-direction: column; align-items: center; }
    .royal-switch strong { font-size: 11px; }
    .royal-switch small { font-size: 10px; }
}
