/*
 * Elu ja Ilu: the application's own base styles in one file
 * (formerly calender.css, style.css, eluilu-ui.css and admin-ui.css,
 * in that order). Page-specific styles stay in lists.css, articles.css
 * and closed-days.css.
 */

:root {
    /* Fallback; footer.php measures the real navbar height */
    --navbar-height: 47px;

    /* Design tokens */
    --elu-bg: #f4f6f6;
    --elu-surface: #fff;
    --elu-ink: #263737;
    --elu-muted: #576767;
    --elu-line: #dce3e2;
    --elu-border: #849593;
    --elu-coral: #f59b90;
    --elu-accent: #a3423b;
    --elu-accent-hover: #87352f;
    --elu-soft: #fff0ed;
    --elu-green: #21634e;
    --elu-danger: #a52d35;
    --elu-radius: 14px;
    --elu-radius-card: 12px;
    --elu-radius-control: 7px;
    --elu-radius-dialog: 16px;
    /* One height for text fields, selects and buttons so they line up on a row */
    --elu-control-height: 44px;
    /* Vertical rhythm between blocks in the staff views: a tool, kept compact */
    --elu-admin-gap: 16px;
    --elu-availability-border: #808080b3;
    --elu-space-1: 4px;
    --elu-space-2: 8px;
    --elu-space-3: 12px;
    --elu-space-4: 16px;
    --elu-space-5: 24px;
    --elu-space-6: 32px;
    --elu-space-7: 48px;

    /* Theme settings (app/theme.php) may override these and the tokens above;
       --elu-hero-image and --elu-hero-position are set only when changed. */
    --elu-primary-text: #fff;
    --elu-btn-primary: #a3423b;
    --elu-btn-primary-hover: #87352f;
    --elu-btn-save: #21634e;
    --elu-btn-save-hover: #1b5241;
    --elu-btn-save-text: #fff;
    --elu-btn-back: #757575;
    --elu-btn-back-hover: #616161;
    --elu-btn-back-text: #fff;
    --elu-btn-arrived: #008080;
    --elu-btn-arrived-hover: #006a6a;
    --elu-btn-arrived-text: #fff;
    --elu-btn-noshow: #d24400;
    --elu-btn-noshow-hover: #ae3800;
    --elu-btn-noshow-text: #fff;
    --elu-btn-cancel: #a52d35;
    --elu-btn-cancel-hover: #89252c;
    --elu-btn-cancel-text: #fff;
    --elu-btn-notes: #375c70;
    --elu-btn-notes-hover: #2e4c5d;
    --elu-btn-notes-text: #fff;
    --elu-btn-complete: #21634e;
    --elu-btn-complete-hover: #1b5241;
    --elu-btn-complete-text: #fff;
}

/* ============================================================
 * Calendar, Select2 and SweetAlert basics (formerly calender.css)
 * ============================================================ */

.fc-resource div span:hover {
    cursor: pointer;
}

.fc .fc-toolbar.fc-header-toolbar {
    margin-top: .5em;
    margin-bottom: .5em;
}

.fc-toolbar-chunk {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-grow: 1; /* Ensure center title takes space */
}

.fc .fc-toolbar-title:hover {
    color: #ccc;
    cursor: pointer;
}

.fc .fc-toolbar-title {
    font-size: 14px;
    margin: 0px;
    padding: 0px;
}

#fc-dom-1 {
    display: none;
}

.flatpickr-input[readonly] {
    cursor: pointer;
    width: 200px;
    text-align: center;
}

.tippy-box[data-theme~='booking-preview'] {
    background: var(--elu-surface);
    color: var(--elu-ink);
    border: 1px solid var(--elu-line);
    border-left: 3px solid var(--booking-tip-category, var(--elu-accent));
    border-radius: 8px;
    box-shadow: 0 8px 28px rgba(38,55,55,.18);
    font-family: 'Open Sans', sans-serif;
    font-size: 13px;
    line-height: 1.5;
    max-width: calc(100vw - 24px);
    text-align: left;
}
.tippy-box[data-theme~='booking-preview'] .tippy-content {
    padding: 16px 18px;
    max-height: min(560px, calc(100vh - 48px));
    overflow-y: auto;
    overflow-wrap: anywhere;
}
.booking-tip-header { display: flex; flex-wrap: wrap; gap: 3px 12px; justify-content: space-between; font-size: 11px; color: var(--elu-muted); font-variant-numeric: tabular-nums; }
.booking-tip-time { color: var(--elu-ink); }
.booking-tip-client { margin-top: 7px; font-size: 18px; line-height: 1.35; font-weight: 600; }
.booking-tip-services { margin: 8px 0 0; font-size: 13px; line-height: 1.6; }
.booking-tip-details { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px 18px; border-top: 1px solid var(--elu-line); padding-top: 13px; margin: 13px 0 0; }
.booking-tip-detail dt { font-size: 11px; font-weight: 400; color: var(--elu-muted); }
.booking-tip-detail dd { margin: 3px 0 0; font-size: 14px; font-variant-numeric: tabular-nums; }
.booking-tip-footer { margin-top: 13px; padding-top: 12px; border-top: 1px solid var(--elu-line); }
/* Status colours come from the calendar colour settings (--cal-*, app/calendar-colors.php). */
.booking-tip-status { display: inline-block; border-radius: 4px; padding: 3px 8px; font-size: 11px; color: var(--cal-scheduled-text); background: var(--cal-scheduled-bg); }
.booking-tip-status--arrived { color: var(--cal-arrived-text); background: var(--cal-arrived-bg); }
.booking-tip-status--completed { color: var(--cal-completed-text); background: var(--cal-completed-bg); }
.booking-tip-status--noshow { color: var(--cal-noshow-text); background: var(--cal-noshow-bg); }
.booking-tip-status--timeoff { color: var(--cal-timeoff-text); background: var(--cal-timeoff-bg); }

.tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px;
    border-radius: 5px;
    font-size: 12px;
    display: none;
}

/* Increase z-index of select2 dropdown to appear above modal */
.select2-dropdown {
    z-index: 9999 !important; /* Or any value higher than your modal */
}

/* In case select2 is in a modal */
.swal2-modal .select2-dropdown {
    z-index: 9999 !important;
}

.swal2-modal {
    overflow: visible !important;
}

.select2-container {
    box-sizing: border-box;
    display: inline-block;
    position: relative;
    vertical-align: middle;
}

label {
    display: inline-block;
    margin-top: .5rem;
}

.eventFilter {
    box-sizing: border-box;
    background-color: #eaf0ee;
    padding: 20px;
    margin-bottom: 0px;
}

.service-slots::after {
    content: "";
    display: table;
    clear: both;
}

.employee-slots {
    box-sizing: border-box;
    background-color: #eaf0ee;
    padding: 0px;
    margin-bottom: 0px;
}

.employee-slots::after {
    content: "";
    display: table;
    clear: both;
}

.category_button_label,
.service_button_label,
.available_slot_button_label,
.staff_button_label {
    font-size: 14px;
}

div:where(.swal2-container) div:where(.swal2-html-container) {
    font-size: 14px !important;
}

#calendar-date-visible {
    min-height: var(--elu-control-height);
}

.form-control {
    font-size: 14px !important;
}

div:where(.swal2-container) button:where(.swal2-styled):where(.swal2-confirm) {
    font-size: 14px !important;
}

div:where(.swal2-container) button:where(.swal2-styled):where(.swal2-deny) {
    font-size: 14px !important;
}

div:where(.swal2-container) button:where(.swal2-styled):where(.swal2-cancel) {
    font-size: 14px !important;
}

/* Replaces animate.css (70 kB): only these Swal animations are used in the calendar.
   Same durations and movement as animate.css v4. */
.animate__animated {
    animation-duration: 1s;
    animation-fill-mode: both;
}

.animate__animated.animate__faster {
    animation-duration: 0.5s;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 100%, 0);
    }
    to {
        opacity: 1;
        transform: translateZ(0);
    }
}

@keyframes fadeOutDown {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
        transform: translate3d(0, 100%, 0);
    }
}

.animate__fadeInUp {
    animation-name: fadeInUp;
}

.animate__fadeOutDown {
    animation-name: fadeOutDown;
}

@media (prefers-reduced-motion: reduce) {
    .animate__animated {
        animation-duration: 1ms !important;
        animation-iteration-count: 1 !important;
    }
}

/* ============================================================
 * Base layout: login, sidebar, navbar, banner (formerly style.css)
 * ============================================================ */

/* Structure */
html,
body {
    height: 100%;
    margin: 0;
}

body {
    font-family: 'Open Sans', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background: var(--elu-surface);
    font-size: 15px;
    line-height: 1.45;
    color: #000;
}

.h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6 {
    font-family: "Lora", serif;
    color: var(--elu-ink);
    letter-spacing: -1px;
}

.dropdown-menu {
    font-size: 14px;
	min-width: 1rem;
}

/* login form */
.login {
    position: absolute;
    inset: 0;
    background: var(--elu-surface);
    color: #fff;
    text-align: center;
    user-select: none;
    overflow: hidden;
}

.login .login-form {
    position: absolute;
    width: 320px;
    height: 320px;
    left: 50%;
    top: 30%;
    margin-left: -160px;
    margin-top: -160px;
    text-align: center;
}

.login form {
    position: absolute;
    left: 0;
    width: 100%;
}

.login form>* {
    transition: transform .4s ease,opacity .4s linear;
}

.login .logo {
    display: block;
    color: #fff;
    opacity: .5;
    margin-bottom: 20px;
}

.login label {
    position: relative;
    width: 240px;
    margin: 14px auto;
    display: block;
    height: 33px;
    text-align: left;
    transition: margin .2s ease,transform .4s ease,opacity .4s linear,height .2s ease;
}

.login label>span {
    position: absolute;
    z-index: 3;
    pointer-events: none;
    top: 7px;
    left: 10px;
    font-size: 13px;
    opacity: .5;
    transition: transform .2s ease;
}

.login label.filled>span {
    transform: translate(-100%) translate(-20px);
}

.login input {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: #6e7f8d;
    border-radius: 5px;
    box-shadow: none;
    border: none;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 33px;
    line-height: 33px;
    box-sizing: border-box;
    padding: 0 10px;
    font-size: 13px;
    color: #fff;
    transition: background-color .2s linear;
}

.login input:focus {
    outline: none;
    box-shadow: none;
    background: #81929e;
}

.login form>.err {
    display: block;
    position: relative;
    height: 0;
    width: 240px;
    margin: 0 auto;
    transition: height .2s ease,transform .4s ease,opacity .4s linear;
}

.login form>.err .msg {
    position: absolute;
    top: 6px;
    left: 0;
    width: 100%;
    box-sizing: border-box;
    background: #ff5252;
    transform-origin: 50% 0;
    opacity: 0;
    transform: scale(0);
    padding: .4em 1em;
    border-radius: 4px;
    transition: opacity .2s linear,transform .6s ease;
}

.login form>.err.visible {
    height: 40px;
}

.login form>.err.visible .msg {
    transform: scale(1);
    opacity: 1;
    transition: opacity .2s linear,transform .25s cubic-bezier(.4,1.5,.5,1);
}

@media screen and (max-width: 480px) {
    .login label {
        margin-top: 26px;
        margin-bottom: 26px;
    }
    .login label.filled>span {
        transform: translateY(-28px);
    }
}

/* admin front */
.booking-wrapper-admin {
    position: relative;
    min-height: calc(100vh - 57px);
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--elu-hero-image, url("../images/bg-registration-form.jpg")) no-repeat var(--elu-hero-position, right center);
    background-size: cover;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

/* user front */
.booking-wrapper {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    background: var(--elu-hero-image, url("../images/bg-registration-form.jpg")) no-repeat var(--elu-hero-position, right center);
    background-size: cover;
    overflow: hidden;
}

.booking-inner {
    position: absolute;
    top: 50%;
    left: 11.07%;
    transform: translateY(-50%);
    width: 510px;
    max-height: 70vh;
    overflow-y: auto;
}

.booking-form {
    width: 100%;
    padding-top: 30px;
    padding-right: 30px;
    padding-left: 30px;
    padding-bottom: 5px;
    background: var(--elu-surface);
}

.booking-form-row {
    display: flex;
    margin-bottom: 5px;
}

.booking-form-row.last {
    margin-bottom: 22px;
}

.booking-form-row .booking-form-wrapper {
    width: 50%;
}

.booking-form-row .full-length {
    width: 100%;
}

.booking-form-row .booking-form-wrapper:first-child {
    margin-right: 25px;
}

.booking-form-wrapper {
    position: relative;
}

#category_id .btn {
    font-size: 14px;
    padding: .65rem .75rem;
    vertical-align: middle;
}

.btn .badge {
    line-height: normal;
    vertical-align: middle;
    font-size: 75%;
    font-weight: 100;
}

@media (max-width: 1199px) {
    .booking-wrapper {
        background-position: center center;
    }
}

@media (max-width: 991px) {
    .booking-inner {
        width: 60%;
    }
}

@media (max-width: 767px) {
    .booking-inner {
        width: 80%;
        box-shadow: none;
        -webkit-box-shadow: none;
        -moz-box-shadow: none;
        -ms-box-shadow: none;
        -o-box-shadow: none;
    }
    .booking-wrapper {
        display: block;
    }
    .booking-form {
        padding: 30px 20px;
    }
    .booking-form-row {
        display: block;
    }
    .booking-form-row .booking-form-wrapper {
        width: 100%;
        margin-bottom: 25px;
    }
    .booking-form-row .booking-form-wrapper:first-child {
        margin-right: 0;
    }
    .booking-form-row .full-length {
        margin-right: 0px;
        width: 100%;
    }
}

#alert_success,
#alert_danger {
    position: absolute;
    top: 0px;
    left: 50%;
    transform: translateX(-50%);
    width: auto; /* Adjust width dynamically */
    min-width: 600px; /* Ensure it has a minimum width */
    max-width: 90%; /* Prevent overflow on small screens */
    z-index: 19000;
    text-align: center; /* Center text */
    padding: 15px; /* Adjust padding for better look */
}

/* admin front */
.wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
    align-items: stretch;
    z-index: 0;
}

/* Force the main menu UL to wrap into two rows */
#navbarSupportedContent > .navbar-nav {
    flex-wrap: wrap;
    justify-content: center;
}

/* Optional: control how many items per row */
#navbarSupportedContent > .navbar-nav > .nav-item {
    flex: 0 0 auto; /* prevents stretching */
    padding: 0 10px;
}

#sidebar {
    min-width: 200px;
    max-width: 200px;
    transition: all 0.5s ease-in-out;
    border-right: 1px solid #eeeeee;
    background-color: rgba(0,0,0,.05);
    position: fixed;
    overflow-y: auto;
    overflow-x: hidden;
    top: 47px;
    bottom: 0;
    left: 0;
    height: calc(100vh - 57px);
}

#sidebar.active {
    margin-left: -200px;
}

@media (max-width: 768px) {
    #sidebar {
        margin-left: -200px;
    }
    #sidebar.active {
        margin-left: 0;
    }
}

.sidebar ul {
    list-style: none;
    margin: 0px;
    padding: 0px;
}

.sidebar li a {
    background-color: rgba(0,0,0,.05);
    display: block;
    padding: 16px 12px;
    color: #000;
    border-bottom: 1px solid #000;
    text-decoration: none;
}

.sidebar li a.collapsed {
    background-color: rgba(0,0,0,.05);
    display: block;
    padding: 18px 12px;
    color: #000;
    border-bottom: 1px solid #000;
    text-decoration: none;
}

.sidebar li a.collapsed.active {
    background-color: rgba(0,0,0,.05);
    display: block;
    padding: 18px 12px;
    color: #fff;
    border-bottom: 1px solid #000;
    text-decoration: none;
}

.sidebar li a.active {
    background-color: #000000;
    color: #fff;
    border-bottom: 1px solid #cccccc;
    transition: all 0.5s ease-in-out;
}

li a.active .fa-angle-right {
    cursor: pointer;
    transform: rotate(90deg);
    transition: 0.1s;
}

.sidebar li a:hover {
    background-color: #000000 !important;
    color: #fff;
    border-bottom: 1px solid #cccccc;
}

.sidebar li a i {
    padding-right: 5px;
}

.sidebar ul li .sub-menu li a {
    position: relative;
}

.sidebar ul li .sub-menu li a:before {
    font-family: FontAwesome;
    content: "\f105";
    display: inline-block;
    padding-left: 0px;
    padding-right: 10px;
}

.sub-menu {
    border-left: 5px solid #000000;
}

.hidden {
    width: 0px !important;
    min-width: 0px !important;
    max-width: 0px !important;
    display: none;
}

#content {
    width: calc(100% - 200px);
    padding: 0px;
    padding-top: 49px;
    min-height: 100vh;
    transition: all 0.3s;
    position: absolute;
    top: 0;
    right: 0;
}

#calendar {
    width: 100%;
    margin: 0px auto;
    min-height: 100vh;
}

.fc-resourceTimeGrid3-button {
    white-space: nowrap;
    overflow: hidden; /* Prevents overflowing content */
}

@media (max-width: 768px) {
    #content {
        width: calc(100%);
        padding: 0px;
        padding-top: 49px;
        min-height: 100vh;
        transition: all 0.3s;
        position: absolute;
        top: 0;
        right: 0;
    }
    .navbar-collapse {
        -ms-flex-preferred-size: 100%;
        flex-basis: 100%;
        -ms-flex-positive: 1;
        flex-grow: 1;
        -ms-flex-align: center;
        align-items: center;
        background-color: var(--elu-surface);
        width: 100%;
        padding: 20px;
        border: 1px solid #ccc;
    }
    .fc-resourceSelect-button {
        font-size: 0 !important; /* Hides text */
        position: relative;
    }
    /* Add the Font Awesome icon */
    .fc-resourceSelect-button::before {
        content: "\f2be";
        font-family: "FontAwesome";
        font-weight: 900;
        font-size: 16px;
        display: inline-block;
        padding: 0.25em 0.5em;
        border-radius: 0.25em !important;
    }
}

@media (max-width: 450px) and (orientation: portrait) {
    .fc .fc-resourceTimeGridDay-button,
    .fc .fc-resourceTimeGridWeek-button,
    .fc .fc-resourceSelect-button,
    .fc .fc-resourceTimeGrid3-button,
    .fc .fc-dayGridMonth-button {
        display: none;
    }
}

.navbar-brand {
    padding-top: 0px;
}

.menubar {
    margin-bottom: 0px;
}

a {
    color: #222;
    text-decoration: none;
    background-color: transparent;
}

a:hover {
    color: #666;
    text-decoration: none;
}

/* Select2 */
.select2-container--default .select2-selection--multiple {
    background-color: var(--elu-surface);
    border: 1px solid #ced4da;
    border-radius: 4px;
    cursor: text;
    height: 38px;
}

.select2-container--default.select2-container--focus .select2-selection--multiple {
    border: 1px solid #ced4da !important;
    outline: 0;
}

.select2-container--default .select2-selection--single {
    background-color: var(--elu-surface);
    border: 1px solid #ced4da;
    border-radius: .25rem;
    display: block;
    width: 100%;
    line-height: 1.5;
    color: #7f7f7f !important;
    transition: border-color .15s ease-in-out,box-shadow .15s ease-in-out;
    margin-right: 5px;
    margin-top: 0px;
    padding: 3px 3px !important;
    height: 38px;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #7f7f7f !important;
    line-height: 28px;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: #888 transparent transparent transparent;
    border-style: solid;
    border-width: 5px 4px 0 4px;
    height: 0;
    left: 50%;
    margin-left: -4px;
    margin-top: -2px;
    position: absolute;
    top: 18px;
    width: 0;
}

.select2-container .select2-search--inline .select2-search__field {
    box-sizing: border-box;
    border: none;
    font-size: 100%;
    margin-top: 8px;
    padding: 0;
}

.dt-search {
    position: static;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: var(--elu-space-2);
    margin-bottom: var(--elu-space-4);
    min-width: 0;
}

.dt-search label {
    margin: 0;
}

.dt-search input {
    width: min(240px, 100%);
    max-width: 100%;
    min-width: 0;
}

.dt-info,
.pagination {
    padding-top: 10px;
}

.dt-buttons {
    float: right;
    padding-left: 20px;
}

.dt-buttons .btn {
    background-color: #000 !important;
    border-color: #fff !important;
    color: #fff !important;
    font-size: 0.75em;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: .55rem .75rem;
}

/* Fixed navbar; its height defines the offset (--navbar-height) */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 20; /* above the banner */
    width: 100%;
    background-color: var(--elu-surface);
    border-bottom: 1px solid #eeeeee;
    padding: .3rem 1rem;
}

/* Banner always sits below the navbar, no matter how tall it becomes */
.banner {
    position: fixed;
    top: calc(var(--navbar-height));
    left: 0;
    width: 100%;
    background: #F59B90;
    height: 42px;
    z-index: 10;
}

.banner-contact {
    display: flex;
    flex: auto;
    flex-direction: row;
    white-space: nowrap;
    justify-content: center;
}

.banner-contact .contact-block {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    justify-self: center;
    padding-right: 20px;
    padding-left: 20px;
    border-left: none;
}

.contact-block svg {
    width: 20px;
    margin-top: 10px;
    position: static;
    float: left;
    margin-right: 7px;
    display: inline-block;
    vertical-align: middle;
    -webkit-transform: translateY(0);
    -moz-transform: translateY(0);
    transform: translateY(0);
    color: #fff;
}

.contact-block a {
    margin-top: 10px;
    color: #fff;
}

.banner-address {
    color: #fff;
}

.banner-address span {
    margin-top: 10px;
}

/* Tileview (employees.php) */
.tileview-block {
    margin-top: .5rem;
    margin-bottom: .5rem;
    margin-left: auto;
    margin-right: auto;
    max-width: var(--width-l);
}

.tileview {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    max-width: calc(var(--width-l) + 2 * var(--spacing-m));
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    padding-top: .5rem;
    padding-bottom: .5rem;
    z-index: 1;
    padding-left: 0;
    padding-right: 0;
}

.tileview-media {
    -ms-grid-row-align: stretch;
    align-self: stretch;
    margin: 0;
    padding: 0;
    position: relative;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    width: 100%;
}

@media (min-width: 720px) {
    .tileview-media {
        width: 50%;
        flex-shrink: 0;
    }
}

@media (max-width: 720px) {
    .first {
        order: 1;
    }
    .second {
        order: 2;
    }
}

.tileview-media img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    height: auto;
    object-fit: cover;
}

.tileview-content {
    max-width: calc(var(--width-l) + 2 * var(--spacing-m));
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    z-index: 1;
    display: flex;
    padding: 2rem var(--spacing-m) 0;
    word-break: break-word;
    text-align: center;
}

@media (min-width: 1400px) {
    .tileview-content {
        padding-left: 3.5rem;
        padding-right: 3.5rem;
    }
}

@media (min-width: 1200px) {
    .tileview-content {
        padding-top: 2.5rem;
        padding-bottom: 2.5rem;
    }
}

@media (min-width: 720px) {
    .tileview-content {
        justify-content: center;
        padding-left: 2.5rem;
        padding-right: 2.5rem;
        padding-bottom: 2rem;
        width: 50%;
    }
}

.tileview-text {
    max-width: 100%;
    width: 100%;
    word-break: break-word;
    text-align: center;
    padding-top: .5rem;
    padding-bottom: .5rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.tileview-image {
    width: 100%;
    line-height: 0;
}

/* ============================================================
 * Theme: booking form, calendar page, dialogs (formerly eluilu-ui.css)
 * ============================================================ */

body.booking-page,
body.calendar-page {
    background: var(--elu-bg);
    color: var(--elu-ink);
    font: 15px/1.6 'Open Sans',sans-serif;
}

.skip-link {
    position: fixed;
    left: 16px;
    top: -100px;
    z-index: 200000;
    background: var(--elu-surface);
    color: var(--elu-accent);
    padding: 12px 18px;
}

.skip-link:focus {
    top: 12px;
}

:is(.booking-page,.calendar-page) :is(a,button,input,select,textarea):focus-visible,
.eluilu-dialog :is(a,button,input,select,textarea):focus-visible {
    outline: 3px solid var(--elu-green);
    outline-offset: 3px;
}

:is(.booking-page,.calendar-page) .navbar {
    background: var(--elu-surface);
    border-bottom: 1px solid var(--elu-line);
    box-shadow: none;
}

:is(.booking-page,.calendar-page) .navbar-brand {
    color: var(--elu-ink);
}

:is(.booking-page,.calendar-page) .btn-primary {
    background: var(--elu-btn-primary);
    border-color: var(--elu-btn-primary);
    color: var(--elu-primary-text);
    border-radius: 7px;
    box-shadow: none;
    font-size: 14px;
}

:is(.booking-page,.calendar-page) .btn-primary:hover {
    background: var(--elu-btn-primary-hover);
    border-color: var(--elu-btn-primary-hover);
}

:is(.booking-page,.calendar-page) .form-control {
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    color: var(--elu-ink);
    background: var(--elu-surface);
    min-height: 44px;
    font-size: 15px;
}

.booking-page .booking-wrapper,
.booking-page .booking-wrapper-admin {
    display: block;
    min-height: 0;
    background: none;
    padding: 32px max(24px,calc((100vw - 1200px)/2)) 64px;
    position: static;
    overflow: visible;
}

.booking-page .booking-inner {
    position: static;
    top: auto;
    left: auto;
    transform: none;
    width: auto;
    max-height: none;
    overflow: visible;
    display: grid;
    grid-template-columns: minmax(0,1fr) 300px;
    gap: 32px;
    align-items: start;
    margin: 0;
}

.booking-page .booking-form {
    padding: 32px;
    background: var(--elu-surface);
    border-radius: var(--elu-radius);
    border: 1px solid var(--elu-line);
    min-width: 0;
    box-shadow: 0 12px 38px #26373706;
}

.booking-page .booking-form>h2 {
    font: 500 30px/1.3 Lora,Georgia,serif;
    margin: 0 0 24px;
    color: var(--elu-ink);
}

.booking-hero {
    max-width: 1200px;
    margin: 28px auto 0;
    display: grid;
    grid-template-columns: 1fr 40%;
    min-height: 280px;
    background: #eaf0ee;
    border-radius: var(--elu-radius);
    overflow: hidden;
}

.booking-hero-copy {
    padding: 38px 46px;
}

.booking-eyebrow {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .05em;
    color: var(--elu-accent);
    margin: 0 0 14px;
}

.booking-hero h1 {
    font: 500 clamp(32px,3.6vw,48px)/1.12 Lora,Georgia,serif;
    color: var(--elu-ink);
    margin-bottom: 18px;
    letter-spacing: -1px;
}

.booking-hero-text {
    font-size: 15px;
    max-width: 560px;
    color: var(--elu-muted);
}

.booking-hero-text p {
    margin: 0 0 10px;
}

.booking-hero-text>:last-child {
    margin-bottom: 0;
}

.booking-hero-photo {
    background: var(--elu-hero-image, url('../images/bg-registration-form.jpg')) var(--elu-hero-position, right center)/cover no-repeat;
    min-height: 240px;
}

body.form-page.booking-result-page {
    background: var(--elu-hero-image, url('../images/bg-registration-form.jpg')) var(--elu-hero-position, right center)/cover no-repeat;
}

.form-page.booking-result-page .booking-wrapper {
    background: transparent;
}

/* Free times on the client's reschedule page (confirm-reschedule.php) */
.reschedule-times {
    margin-top: 16px;
}

.reschedule-times-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.reschedule-time {
    min-width: 64px;
    min-height: 40px;
}

.reschedule-time[aria-pressed="true"] {
    background: var(--elu-accent);
    border-color: var(--elu-accent);
    color: var(--elu-primary-text);
}

.booking-steps {
    display: flex;
    list-style: none;
    padding: 0;
    gap: 0;
    border-bottom: 1px solid var(--elu-line);
    margin: 0 0 28px;
}

.booking-steps li {
    flex: 1;
}

.booking-steps button {
    background: transparent;
    border: 0;
    border-bottom: 2px solid transparent;
    width: 100%;
    padding: 10px 4px 15px;
    text-align: left;
    color: var(--elu-muted);
    font: 600 12px/1.4 'Open Sans',sans-serif;
}

.booking-steps button[aria-current=step] {
    color: var(--elu-accent);
    border-color: var(--elu-accent);
}

.booking-steps button:disabled {
    opacity: .6;
    cursor: default;
}

.booking-panel h3 {
    font-size: 23px;
    font-weight: 600;
    line-height: 1.3;
    color: var(--elu-ink);
    margin: 0 0 14px;
}

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

.flow-note {
    font-size: 13px;
    color: var(--elu-muted);
}

.booking-page .switch-container {
    display: block !important;
}

.booking-page .category-master-buttons {
    display: grid;
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 8px;
    margin: 22px 0 !important;
}

.booking-page .category-master-buttons .btn {
    min-height: 108px;
    background: var(--elu-surface) !important;
    border: 1px solid var(--elu-border) !important;
    color: var(--elu-ink) !important;
    flex-direction: column;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.5;
    text-transform: none !important;
    padding: 12px 8px !important;
    margin: 0 !important;
    white-space: normal;
}

.booking-page .category-master-buttons .fa {
    font-size: 23px;
    color: var(--elu-accent);
}

.booking-page .category-master-buttons .btn:hover {
    border-color: var(--elu-accent) !important;
}

.booking-page .category-master-buttons .btn[aria-pressed=true] {
    background: var(--elu-soft) !important;
    border-color: var(--elu-accent) !important;
    box-shadow: inset 0 0 0 1px var(--elu-accent);
}

.booking-page .booking-form-row {
    margin: 20px 0;
    gap: 16px;
}

.booking-page .booking-form-wrapper:first-child {
    margin-right: 0;
}

.booking-page .booking-form-wrapper {
    flex: 1;
    min-width: 0;
}

.booking-page .full-length {
    min-width: 0;
}

.booking-page label {
    font-size: 13px;
    font-weight: 600;
    color: var(--elu-ink);
    margin-bottom: 7px;
}

.booking-page .category_button_label,
.booking-page .service_button_label {
    display: block;
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    padding: 14px 16px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 8px !important;
    white-space: normal;
}

.booking-page .category_button_label:has(input:checked),
.booking-page .service_button_label:has(input:checked) {
    background: var(--elu-soft);
    border-color: var(--elu-accent);
}

.booking-page .service_button_label .badge {
    background: var(--elu-soft);
    color: var(--elu-accent);
    font-size: 12px;
    font-weight: 600;
}

.booking-page .service_button_label {
    position: relative;
    padding-right: 112px;
}

.booking-page .service_button_label > .badge {
    position: absolute;
    top: 50%;
    right: 16px;
    transform: translateY(-50%);
    margin-top: 0 !important;
    float: none;
}

.booking-page input[type=checkbox] {
    accent-color: var(--elu-accent);
    width: 17px;
    height: 17px;
    vertical-align: middle;
    margin-right: 6px;
}

.booking-page #employee label {
    display: inline-flex;
    gap: 6px;
    align-items: center;
    padding: 8px 10px;
    margin: 4px;
    border: 1px solid var(--elu-line);
    border-radius: 6px;
}

.booking-page .service-slots {
    display: flow-root;
    margin: 12px 0 22px;
    line-height: 2;
}

.booking-page .available_slot_button_label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    line-height: 1.25;
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    background: var(--elu-surface) !important;
    font-size: 14px;
    padding: 7px 12px;
    margin: 5px 7px 5px 0 !important;
    min-height: 40px;
}

/* #event: outweighs the staff form label colour (.staff-ui #content form label) for logged-in staff */
.booking-page #event .available_slot_button_label:has(input:checked) {
    background: var(--elu-accent) !important;
    color: #fff;
    border-color: var(--elu-accent);
}

/* Overlaps another selected time: shown dimmed and struck through, not by colour alone */
.booking-page .available_slot_button_label:has(input:disabled) {
    opacity: .55;
    border-style: dashed;
    text-decoration: line-through;
    cursor: not-allowed;
}

.booking-page .available_slot_button_label input {
    width: 14px;
    height: 14px;
    margin: 0;
    flex: 0 0 auto;
}

.booking-page #event>div {
    margin-bottom: 20px;
}

.booking-page #event .alert {
    background: #eaf0ee !important;
    color: var(--elu-ink) !important;
    font-size: 13px;
    border-left: 3px solid var(--elu-coral);
}

.flow-actions {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    border-top: 1px solid var(--elu-line);
    padding-top: 22px;
    margin-top: 24px;
}

.flow-actions .btn {
    min-height: 44px;
    padding: 10px 22px;
}

.flow-actions .btn-primary {
    margin-left: auto;
}

.flow-back {
    color: var(--elu-muted);
    background: var(--elu-surface);
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    font-size: 14px;
}

.flow-error,
.flow-field-error {
    display: block;
    color: var(--elu-danger);
    font-size: 13px;
    margin: 6px 0 0;
}

.flow-error:empty,
.flow-field-error:empty {
    display: none;
}

.flow-status {
    font-size: 13px;
    color: var(--elu-muted);
}

.flow-status:empty,
.staff-note:empty {
    display: none;
}

.flow-field-error+[aria-invalid=true],
.booking-page [aria-invalid=true] {
    border-color: var(--elu-danger);
}

.external-notice {
    padding: 14px;
    background: #eaf0ee;
    border-radius: 7px;
    font-size: 13px;
    color: var(--elu-muted);
}

.booking-page .tervisekeskus-container a {
    background: var(--elu-accent) !important;
    font-size: 13px;
    text-transform: none !important;
}

.booking-page #booking-events {
    display: none !important;
}

.booking-summary {
    position: sticky;
    top: calc(var(--navbar-height,60px) + 20px);
    padding: 24px;
    background: var(--elu-surface);
    border-radius: var(--elu-radius);
    border: 1px solid var(--elu-line);
    font-size: 13px;
}

.booking-summary h2 {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 24px;
}

.summary-item {
    padding-bottom: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--elu-line);
}

.summary-item strong {
    display: block;
    font-size: 13px;
    line-height: 1.6;
}

.summary-item p {
    font-size: 11px;
    color: var(--elu-muted);
    margin: 8px 0 0;
}

.summary-totals>p:first-child {
    font-size: 12px;
    color: var(--elu-muted);
}

.summary-totals>p:last-child {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 18px 0 0;
}

.summary-totals strong {
    font-size: 25px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.calendar-page #content {
    /* Height of the field labels above the heading controls (12px × 1.6) */
    --calendar-label-height: 19.2px;
    position: relative;
    top: auto;
    right: auto;
    min-width: 0;
    margin-left: 200px;
    padding: calc(var(--navbar-height,55px) + 28px) 28px 40px;
}

/* The labels use the top space, so the title starts where it does on other staff pages
   (.staff-ui #content sets the same padding without the label height) */
.staff-ui .calendar-page #content {
    padding-top: calc(var(--navbar-height,56px) + 20px - var(--calendar-label-height));
}

@media (max-width: 767px) {
    .staff-ui .calendar-page #content {
        padding-top: calc(var(--navbar-height,56px) + 16px - var(--calendar-label-height));
    }
}

/* The title sits on the same line as the date field and buttons below their labels */
.calendar-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
	margin-top: 8px;
    margin-bottom: 10px;
}

.calendar-heading h1 {
	display: flex;
	align-items: center;
	min-height: calc(var(--elu-control-height) + var(--calendar-label-height));
	padding-top: var(--calendar-label-height);
	font: 500 30px/1.25 Lora,Georgia,serif;
	margin: 0;
	color: var(--elu-ink);
}

.calendar-heading p {
    font-size: 12px;
    color: var(--elu-muted);
    margin: 6px 0 0;
}

.calendar-heading-actions {
    display: flex;
    align-items: end;
    gap: 12px;
    flex-wrap: wrap;
    min-width: 0;
    max-width: 100%;
}

.calendar-heading-actions label {
    font-size: 12px;
    margin: 0;
    color: var(--elu-muted);
    min-width: 0;
}

.calendar-heading-actions input,
.calendar-heading-actions select {
    max-width: 100%;
    display: block;
    min-height: var(--elu-control-height);
    background: var(--elu-surface);
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    padding: 7px 10px;
    font: 13px 'Open Sans',sans-serif;
    color: var(--elu-ink);
}

.calendar-heading-actions .btn {
    padding-left: 16px;
    padding-right: 16px;
}

@media (max-width: 767px) {
    .calendar-heading-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }
    .calendar-heading-actions input,
    .calendar-heading-actions select {
        width: 100%;
    }
    .calendar-heading-actions .btn {
        min-width: 0;
        padding-left: 8px;
        padding-right: 8px;
        white-space: normal;
    }
}

.calendar-viewport {
    overflow: auto;
    border: 1px solid var(--elu-line);
    border-radius: 12px;
    background: var(--elu-surface);
    padding: 18px;
    isolation: isolate;
}

.calendar-page #calendar {
    min-width: 0;
}

.calendar-page .fc {
    --fc-border-color: #e4eae8;
    --fc-today-bg-color: #fff8f5;
    --fc-now-indicator-color: var(--elu-accent);
    font-size: 12px;
}

.calendar-page .fc .fc-header-toolbar {
    gap: 16px;
    flex-wrap: wrap;
    margin: 0 0 20px;
}

.calendar-page .fc .fc-toolbar-chunk {
    flex-grow: 0;
    flex-wrap: wrap;
    gap: 6px;
}

.calendar-page .fc .fc-toolbar-title {
    font-size: 17px;
    color: var(--elu-ink);
}

.calendar-page .fc .fc-button {
    background: var(--elu-surface) !important;
    border: 1px solid var(--elu-line) !important;
    color: var(--elu-muted) !important;
    border-radius: 6px !important;
    box-shadow: none !important;
    padding: 8px 10px;
    font-size: 12px;
}

.calendar-page .fc .fc-button-active {
    background: var(--elu-soft) !important;
    color: var(--elu-accent) !important;
    border-color: var(--elu-coral) !important;
}

.fc .fc-button-primary:disabled {
  background: var(--elu-soft) !important;
  color: var(--elu-accent) !important;
  border-color: var(--elu-coral) !important;
}

.calendar-page .fc .fc-col-header-cell-cushion {
    padding: 12px 4px;
    color: var(--elu-ink);
    text-decoration: none;
    font-weight: 600;
}

.calendar-page .fc .fc-timegrid-slot {
    height: 30px;
}

.calendar-page .fc .fc-timegrid-slot-label-cushion {
    font-size: 10px;
    color: var(--elu-muted);
    padding: 0 8px;
}

.calendar-page .fc .fc-event {
    border: 0;
    border-left: 3px solid currentColor;
    border-radius: 5px;
    box-shadow: none;
    padding: 4px 5px;
    cursor: pointer;
    line-height: 1.25;
}

.calendar-page .fc .fc-event-main {
    color: inherit !important;
    overflow: hidden;
}

.calendar-event-time,
.calendar-event-status {
    font-size: 10px;
}

.calendar-event-title {
    font-size: 12px;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-event-service {
    font-size: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-legend {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    padding: 14px 0;
    font-size: 11px;
    color: var(--elu-muted);
}

.calendar-legend span {
    display: flex;
    gap: 6px;
    align-items: center;
}

.calendar-legend i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--cal-scheduled-text);
}

.calendar-legend .arrived i {
    background: var(--cal-arrived-text);
}

.calendar-legend .completed i {
    background: var(--cal-completed-text);
}

.calendar-legend .timeoff i {
    background: var(--cal-timeoff-text);
}

body .swal2-popup.eluilu-dialog {
    font-family: 'Open Sans',sans-serif;
    font-size: 14px;
    border-radius: var(--elu-radius-dialog);
    padding: 0 0 var(--elu-space-5);
    /* border-top: 4px solid var(--elu-coral); */
    color: var(--elu-ink);
    box-shadow: 0 24px 90px #172c2c33;
    max-width: calc(100vw - 24px);
    background: var(--elu-surface);
}

body .eluilu-dialog .swal2-title {
    text-align: left;
    font: 600 24px/1.35 'Open Sans',sans-serif;
    padding: 24px 28px 0;
    color: var(--elu-ink);
}

body .eluilu-dialog .swal2-html-container {
    font-size: 14px;
    line-height: 1.6;
    padding: 20px 28px 0;
    text-align: left;
    color: var(--elu-ink);
    overflow: visible;
}

body .eluilu-dialog .swal2-actions {
    gap: 10px;
    margin-top: 24px;
    padding: 0 28px;
    justify-content: flex-end;
    max-width: 100%;
    flex-wrap: wrap;
}

body .eluilu-dialog .swal2-styled {
    border-radius: 7px;
    padding: 11px 18px;
    margin: 0;
    font-size: 14px;
    box-shadow: none;
}

body .eluilu-dialog .swal2-confirm {
    background: var(--elu-btn-primary) !important;
    color: var(--elu-primary-text) !important;
}

body .eluilu-dialog .swal2-cancel {
    background: var(--elu-btn-back) !important;
    color: var(--elu-btn-back-text) !important;
    border: 1px solid var(--elu-border);
}

body .eluilu-dialog .swal2-cancel:hover {
    background: var(--elu-btn-back-hover) !important;
}

body .eluilu-dialog .swal2-deny {
    background: var(--elu-danger) !important;
}

body .eluilu-dialog .swal2-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 18px 22px 0;
    border-top: 1px solid var(--elu-line);
    color: var(--elu-muted);
}

body .eluilu-dialog .swal2-footer .btn {
    font-size: 12px;
    flex: 1 1 40%;
    border-radius: 7px;
}

body .eluilu-dialog label {
    font-size: 12px;
    font-weight: 600;
    color: var(--elu-muted);
    margin: 12px 0 6px;
}

body .eluilu-dialog .form-control {
    border: 1px solid var(--elu-border);
    border-radius: var(--elu-radius-control);
    min-height: 44px;
    background: var(--elu-surface);
    color: var(--elu-ink);
    font-size: 14px;
}

body .eluilu-dialog .select2-container {
    min-width: 0;
    max-width: 100%;
}

body .eluilu-dialog .select2-container--default .select2-selection {
    border: 1px solid var(--elu-border);
    border-radius: var(--elu-radius-control);
    min-height: 44px;
    background: var(--elu-surface);
    color: var(--elu-ink);
}

body .eluilu-dialog .select2-container .select2-selection__placeholder,
body .eluilu-dialog .select2-search__field::placeholder {
    color: var(--elu-muted);
    opacity: 1;
}

body .eluilu-dialog .select2-container--default .select2-selection__rendered {
    line-height: 35px;
}

/* Match the booking dialog fields for both installed Select2 themes. */
body .eluilu-dialog .select2-container .select2-selection--multiple {
    /* The Bootstrap4 theme sets its minimum height with !important. */
    min-height: 44px !important;
    height: auto;
    padding: 5px 10px;
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    background: var(--elu-surface);
    color: var(--elu-ink);
    font: 14px/1.5 'Open Sans', sans-serif;
}

body .eluilu-dialog .select2-selection--multiple .select2-selection__rendered {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--elu-space-1);
    padding: 0;
    margin: 0;
    line-height: 1.7 !important;
}

body .eluilu-dialog .select2-selection--multiple .select2-selection__choice {
    float: none;
    margin: 0;
    padding: 2px 7px;
    border: 1px solid var(--elu-line);
    border-radius: 4px;
    background: var(--elu-soft);
    color: var(--elu-ink);
    font: inherit;
    line-height: 1.5;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
}

body .eluilu-dialog .select2-selection--multiple .select2-search--inline {
    float: none;
    margin: 0;
    flex: 1 1 80px;
    min-width: 0;
}

body .eluilu-dialog .select2-selection--multiple .select2-search__field {
    min-height: 28px;
    max-width: 100%;
    margin: 0;
    padding: 0;
    color: var(--elu-ink);
    font: inherit;
}

body .eluilu-dialog .select2-container--focus .select2-selection--multiple,
body .eluilu-dialog .select2-container--open .select2-selection--multiple {
    outline: 2px solid var(--elu-accent);
    outline-offset: 2px;
}

div.dt-processing > div:last-child > div {
    background: var(--elu-accent);
}

body .eluilu-dialog .swal2-validation-message {
    margin: 18px 28px 0;
    background: var(--elu-soft);
    color: var(--elu-danger);
    border-radius: 7px;
    text-align: left;
    font-size: 13px;
}

body .eluilu-dialog .swal2-icon {
    margin-top: 24px;
}

body .swal2-container {
    padding: 12px;
}

.eluilu-dialog .swal2-close {
    color: var(--elu-muted);
}

.eluilu-dialog input[readonly] {
    background: var(--elu-bg);
}

.login-page .login {
    position: relative;
    min-height: 100vh;
    overflow: visible;
    background: var(--elu-bg);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--elu-ink);
    padding: 32px 16px;
}

.login-page .login .login-form {
    position: static;
    margin: 0;
    transform: none;
    width: min(400px,100%);
    height: auto;
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-top: 4px solid var(--elu-coral);
    border-radius: 14px;
    padding: 30px;
}

.login-page .login form {
    position: static;
}

.login-page .login label {
    width: 100%;
    height: auto;
    margin: 0 0 18px;
}

.login-page .login label>span {
    position: static;
    display: block;
    color: var(--elu-muted);
    font-size: 13px;
    margin: 0 0 7px;
    opacity: 1;
    transform: none;
}

.login-page .login input {
    position: static;
    height: auto;
    line-height: 1.5;
    background: var(--elu-surface);
    color: var(--elu-ink);
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    min-height: 44px;
    width: 100%;
    padding: 9px 12px;
}

.login-page .login #password_label {
    margin-bottom: 7px;
}
.login-page .login #password_label>span {
    margin-bottom: 0;
}
.login-password {
    position: relative;
}
.login-page .login .login-password input {
    padding-right: 52px;
}
.login-page .login .password-toggle {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 0 7px 7px 0;
    background: transparent;
    color: var(--elu-muted);
    cursor: pointer;
}
.login-page .login .password-toggle:hover {
    color: var(--elu-ink);
}

.login-page .login .logo {
    opacity: 1;
    margin-bottom: 30px;
}

.login-page .login-title {
    margin: var(--elu-space-3) 0 0;
    font: 400 14px/1.5 'Open Sans', sans-serif;
    color: var(--elu-ink);
}

.login-page .login .logo img {
    max-width: 55px;
    height: auto;
}

.login-page .login .btn {
    width: 100% !important;
    background: var(--elu-btn-primary);
    color: var(--elu-primary-text);
    border: 1px solid var(--elu-btn-primary);
    min-height: 44px;
    border-radius: 7px;
}

.login-page :focus-visible,
.login-page .login input:focus-visible {
    outline: 3px solid var(--elu-green);
    outline-offset: 3px;
}

.login-page .err {
    color: var(--elu-danger);
    margin-bottom: 18px;
}

@media (max-width: 1280px) {
    .booking-hero {
        margin-left: 24px;
        margin-right: 24px;
    }
    .booking-page .booking-inner {
        grid-template-columns: minmax(0,1fr) 270px;
        gap: 24px;
    }
    .booking-page .booking-wrapper {
        padding-inline: 24px;
    }
    .booking-hero-copy {
        padding: 32px;
    }
}

@media (max-width: 850px) {
    .booking-page .booking-inner {
        grid-template-columns: minmax(0,1fr) 235px;
        gap: 20px;
    }
    .booking-page .booking-form {
        padding: 24px;
    }
    .booking-summary {
        padding: 20px;
    }
    .calendar-page #content {
        padding-right: 16px;
        padding-bottom: 24px;
        padding-left: 16px;
    }
    .calendar-heading h1 {
        font-size: 25px;
    }
    .calendar-viewport {
        padding: 12px;
    }
}

@media (max-width: 700px) {
    .booking-hero {
        margin: 18px 16px 0;
        grid-template-columns: 1fr 30%;
        min-height: 200px;
    }
    .booking-hero-copy {
        padding: 26px 22px;
    }
    .booking-hero h1 {
        font-size: 30px;
    }
    .booking-hero-photo {
        min-height: 200px;
    }
    .booking-hero-text {
        font-size: 13px;
    }
    .booking-page .booking-wrapper,
    .booking-page .booking-wrapper-admin {
        padding: 22px 16px 40px;
    }
    .booking-page .booking-inner {
        grid-template-columns: 1fr;
        gap: 22px;
    }
    .booking-page .booking-form {
        padding: 24px 20px;
    }
    .booking-summary {
        position: static;
        padding: 22px;
    }
    .booking-summary h2 {
        margin-bottom: 18px;
    }
    .booking-page .booking-form>h2 {
        font-size: 27px;
    }
    .booking-panel h3 {
        font-size: 21px;
    }
    .booking-page .booking-form-row {
        display: flex;
        flex-wrap: wrap;
    }
    .booking-page .booking-form-wrapper {
        width: 100%;
        flex: auto;
        margin-bottom: 0;
    }
    .booking-page .category-master-buttons .btn {
        font-size: 10px;
        padding: 10px 6px !important;
    }
    .booking-page .booking-form-row .booking-form-wrapper:first-child {
        margin-right: 0;
    }
    .booking-steps button {
        font-size: 11px;
        padding: 8px 5px 12px;
    }
    .calendar-page .fc .fc-header-toolbar {
        align-items: start;
        gap: 12px;
    }
    .calendar-page .fc .fc-toolbar-chunk:last-child {
        display: flex;
        width: 100%;
    }
    .calendar-page .fc .fc-toolbar-chunk:last-child .btn-group {
        display: flex;
        width: 100%;
    }
    .calendar-page .fc .fc-toolbar-chunk:last-child button {
        flex: 1;
        padding: 8px 5px;
    }
    .calendar-page .fc .fc-col-header-cell-cushion {
        font-size: 10px;
    }
    .calendar-event-title {
        font-size: 11px;
    }
    .calendar-event-service,
    .calendar-event-status {
        font-size: 9px;
    }
    .calendar-viewport.multi-resource #calendar {
        min-width: 650px;
    }
    .calendar-viewport.single-resource #calendar {
        min-width: 0;
    }
    .calendar-page .modal-dialog {
        max-width: calc(100vw - 20px) !important;
        width: auto !important;
        margin: 10px;
    }
    body .eluilu-dialog .swal2-title {
        font-size: 21px;
        padding: 22px 20px 0;
    }
    body .eluilu-dialog .swal2-html-container {
        padding: 16px 20px 0;
    }
    body .eluilu-dialog .swal2-actions {
        padding: 0 20px;
    }
    body .eluilu-dialog .swal2-footer {
        padding-inline: 20px;
    }
    .eluilu-dialog .row {
        margin-left: -6px;
        margin-right: -6px;
    }
    .eluilu-dialog [class*=col-] {
        padding-inline: 6px;
    }
    .summary-totals strong {
        font-size: 23px;
    }
}

@media (max-width: 380px) {
    .booking-hero {
        grid-template-columns: 1fr;
    }
    .booking-hero-photo {
        display: none;
    }
    .booking-page .booking-form {
        padding: 22px 16px;
    }
    .booking-steps button {
        font-size: 10px;
    }
    .booking-page .category-master-buttons {
        gap: 6px;
    }
    .booking-page .category-master-buttons .btn {
        font-size: 10px;
        min-height: 100px;
    }
    .calendar-heading-actions .btn {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .booking-page *,
    .calendar-page *,
    .eluilu-dialog * {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

.booking-page [hidden],
.calendar-page [hidden] {
    display: none !important;
}

body.booking-page {
    padding-top: calc(var(--navbar-height,60px) + 48px);
}

body.booking-page:has(#sidebar) {
    padding-top: var(--navbar-height,60px);
}

.booking-page #content {
    position: relative;
    top: auto;
    right: auto;
    margin-left: 200px;
}

.calendar-page #sidebar {
    background: var(--elu-surface);
    top: var(--navbar-height,55px);
    height: calc(100vh - var(--navbar-height,55px));
    z-index: 30;
}

.calendar-page .sidebar li a {
    color: var(--elu-muted);
}

.calendar-page .sidebar li a.active {
    background: var(--elu-soft);
    color: var(--elu-accent);
}

@media (max-width: 767px) {
    body.booking-page {
        padding-top: var(--navbar-height,60px);
    }
    .calendar-page #content,
    .booking-page #content {
        margin-left: 0;
        width: 100% !important;
    }
    .calendar-page #sidebar {
        margin-left: 0;
        box-shadow: 12px 0 35px #26373720;
    }
    .calendar-page #sidebar.hidden {
        display: none !important;
    }
    .calendar-page .fc .fc-button-group {
        display: flex;
        flex-wrap: wrap;
    }
}

.booking-page .categoryFilter {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 8px;
}

.booking-page .category_button_label {
    font-size: 12px;
    padding: 11px 12px;
    margin: 0 !important;
}

.booking-page .serviceFilter {
    max-height: 480px;
    overflow: auto;
    padding: 4px;
    scroll-padding: 8px;
}

.booking-page .booking-steps[aria-label] {
    scroll-margin-top: 100px;
}

@media (max-width: 500px) {
    .booking-page .categoryFilter {
        grid-template-columns: 1fr;
    }
    .booking-page .serviceFilter {
        max-height: 400px;
    }
}

.booking-page .banner {
    background: var(--elu-soft);
    border-bottom: 1px solid var(--elu-line);
    color: var(--elu-ink);
}

.booking-page .banner a,
.booking-page .banner-address span {
    color: #743d37;
}

.booking-page .banner-address svg {
    color: var(--elu-accent);
}

.booking-page .banner svg [class$="b"] {
    fill: var(--elu-accent);
}

.booking-page .navbar .btn-primary {
    background: var(--elu-btn-primary) !important;
    border-color: var(--elu-btn-primary) !important;
    color: var(--elu-primary-text) !important;
}

@media (max-width: 1100px) {
    :is(.booking-page,.calendar-page) .navbar-expand-md {
        flex-wrap: wrap;
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .navbar-toggler {
        display: block !important;
        color: var(--elu-ink);
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .navbar-collapse {
        display: none !important;
        flex-basis: 100%;
        width: 100%;
        border: 0;
        background: var(--elu-surface);
        padding: 12px;
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .navbar-collapse.show {
        display: block !important;
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .navbar-nav {
        flex-direction: column;
        align-items: stretch;
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .dropdown-menu {
        position: static;
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .navbar-nav .nav-item {
        padding: 4px 0 !important;
    }
    :is(.booking-page,.calendar-page) .navbar-expand-md .navbar-nav .nav-link {
        text-align: left;
    }
    .booking-page .banner {
        display: none !important;
    }
    body.booking-page {
        padding-top: var(--navbar-height,60px);
    }
}

/* Content follows the sidebar state at every desktop width. */
body.sidebar-hidden #content {
    margin-left: 0 !important;
    width: 100% !important;
}

body.sidebar-hidden #sidebar {
    display: none !important;
}

.eluilu-dialog .swal2-actions {
    display: grid !important;
    grid-template-columns: repeat(2,minmax(0,1fr));
    grid-auto-rows: 1fr;
    gap: 10px;
    width: calc(100% - 48px);
    margin: 24px auto 20px;
}

.eluilu-dialog .swal2-actions>button {
    box-sizing: border-box !important;
    align-items: center;
    justify-content: center;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 48px;
    height: 100%;
    margin: 0 !important;
    padding: 10px 14px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    white-space: normal !important;
    border-radius: 7px !important;
}

.eluilu-dialog .swal2-footer[hidden] {
    display: none !important;
}

.staff-services {
    margin: 24px 0;
    padding: 20px;
    border: 1px solid var(--elu-line);
    border-radius: 8px;
}

.staff-services legend {
    font-size: 18px;
    width: auto;
    padding: 0 8px;
}

.staff-services-group {
    margin: 12px 0;
}

.staff-service-options {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(220px,1fr));
    gap: 8px;
}

.staff-service-options label {
    display: flex;
    align-items: start;
    gap: 8px;
    margin: 0;
    padding: 8px;
}

/* 18px box centred on the first 20.8px text line */
.staff-service-options input {
    margin: 1px 0 0;
    accent-color: var(--elu-accent);
}

@media (max-width: 380px) {
    .eluilu-dialog .swal2-actions {
        grid-template-columns: 1fr;
    }
}

.interface-languages {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0 24px;
    font-size: 13px;
}

.interface-languages a {
    padding: 8px;
    color: var(--elu-accent);
}

.interface-languages a[aria-current=true] {
    font-weight: 700;
    text-decoration: underline;
}

.interface-languages a:focus-visible {
    outline: 3px solid var(--elu-green);
    outline-offset: 2px;
}

/* Calendar booking buttons: change each class's --booking-button-* variables here. */
.booking-create-submit,
.booking-edit-save {
    --booking-button-bg: var(--elu-btn-save);
    --booking-button-hover: var(--elu-btn-save-hover);
    --booking-button-fg: var(--elu-btn-save-text);
}

.booking-create-back,
.booking-edit-back {
    --booking-button-bg: var(--elu-btn-back);
    --booking-button-hover: var(--elu-btn-back-hover);
    --booking-button-fg: var(--elu-btn-back-text);
    --booking-button-border: var(--elu-border);
}

.booking-edit-arrived {
    --booking-button-bg: var(--elu-btn-arrived);
    --booking-button-hover: var(--elu-btn-arrived-hover);
    --booking-button-fg: var(--elu-btn-arrived-text);
}

.booking-edit-noshow {
    --booking-button-bg: var(--elu-btn-noshow);
    --booking-button-hover: var(--elu-btn-noshow-hover);
    --booking-button-fg: var(--elu-btn-noshow-text);
}

.booking-edit-cancel {
    --booking-button-bg: var(--elu-btn-cancel);
    --booking-button-hover: var(--elu-btn-cancel-hover);
    --booking-button-fg: var(--elu-btn-cancel-text);
}

.booking-edit-notes {
    --booking-button-bg: var(--elu-btn-notes);
    --booking-button-hover: var(--elu-btn-notes-hover);
    --booking-button-fg: var(--elu-btn-notes-text);
}

.booking-edit-complete {
    --booking-button-bg: var(--elu-btn-complete);
    --booking-button-hover: var(--elu-btn-complete-hover);
    --booking-button-fg: var(--elu-btn-complete-text);
}

body .eluilu-dialog .swal2-actions>.booking-action {
    background: var(--booking-button-bg) !important;
    color: var(--booking-button-fg) !important;
    border: 1px solid var(--booking-button-border,var(--booking-button-bg)) !important;
    font-weight: 400;
}

body .eluilu-dialog .swal2-actions>.booking-action:hover {
    background: var(--booking-button-hover,var(--booking-button-bg)) !important;
    border-color: var(--booking-button-border,var(--booking-button-hover,var(--booking-button-bg))) !important;
}

body .booking-edit-dialog .swal2-actions {
    grid-template-columns: repeat(2,minmax(0,1fr));
}

body .booking-edit-dialog .booking-edit-complete {
    grid-column: 1/-1;
    justify-self: center;
    max-width: calc((100% - 10px)/2);
}

/* ============================================================
 * Administration shell, forms and buttons (formerly admin-ui.css)
 * ============================================================ */

/* Shared administration shell; uses the approved calendar palette. */
.fc .fc-bg-event.calendar-unavailable-range,
.fc .fc-bg-event.calendar-unavailable-specific,
.fc .fc-bg-event.calendar-unavailable-pause {
    /* Absences and shift breaks use the calendar colour settings, without background fading. */
    background-color: var(--cal-unavailable-bg);
    color: var(--cal-unavailable-text);
    border-left-color: var(--elu-availability-border);
    opacity: 1;
}

.fc .fc-bg-event.calendar-unavailable-pause {
    background-color: var(--cal-pause-bg);
    color: var(--cal-pause-text);
}

.fc .closed-calendar-day {
    opacity: 1;
    background: repeating-linear-gradient(135deg,var(--cal-closed-bg),var(--cal-closed-bg) 10px,var(--cal-closed-stripe) 10px,var(--cal-closed-stripe) 12px) !important;
    color: var(--cal-closed-text);
}

#content #seo {
    scroll-margin-top: calc(var(--navbar-height,56px) + 24px);
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--elu-line);
}

/* Date ranges share one calendar and keyboard reachable quick choices. */
.date-range-presets {
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 5px;
    padding: 8px;
    border-top: 1px solid var(--elu-line);
    background: var(--elu-surface);
}

.date-range-presets .btn {
    font-weight: 400;
    font-size: 11px;
    min-height: 44px;
    padding: 5px 3px;
    line-height: 1.35;
}

.flatpickr-calendar .date-range-presets .btn:focus-visible {
    outline: 3px solid var(--elu-green);
    outline-offset: 1px;
}

.admin-filters [data-filter-range]+input {
    min-width: 240px;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange,
.flatpickr-day.selected:hover,
.flatpickr-day.startRange:hover,
.flatpickr-day.endRange:hover {
    background: var(--elu-accent);
    border-color: var(--elu-accent);
    color: #fff;
}

.flatpickr-day.inRange {
    background: var(--elu-soft);
    border-color: var(--elu-soft);
    box-shadow: -5px 0 0 var(--elu-soft),5px 0 0 var(--elu-soft);
}

/* Bootstrap and both DataTables paging renderers. */
:is(.dt-container,.dataTables_wrapper) :is(.page-link,.paginate_button,.dt-paging-button) {
    color: var(--elu-accent) !important;
    background: var(--elu-surface) !important;
    border: 1px solid var(--elu-line) !important;
    font-weight: 400;
    box-shadow: none !important;
}

:is(.dt-container,.dataTables_wrapper) :is(.page-item.active .page-link,.paginate_button.current,.dt-paging-button.current) {
    color: #fff !important;
    background: var(--elu-accent) !important;
    border-color: var(--elu-accent) !important;
}

:is(.dt-container,.dataTables_wrapper) :is(.page-link,.paginate_button,.dt-paging-button):hover {
    color: var(--elu-accent-hover) !important;
    background: var(--elu-soft) !important;
    border-color: var(--elu-accent) !important;
}

:is(.dt-container,.dataTables_wrapper) :is(.page-item.disabled .page-link,.paginate_button.disabled,.dt-paging-button.disabled) {
    color: var(--elu-muted) !important;
    background: var(--elu-bg) !important;
    border-color: var(--elu-line) !important;
}

:is(.dt-container,.dataTables_wrapper) :is(.page-link,.paginate_button,.dt-paging-button):focus-visible {
    outline: 3px solid var(--elu-green);
    outline-offset: 2px;
}

@media (max-width: 575px) {
    .admin-filters [data-filter-range]+input {
        min-width: 0;
        width: 100%;
    }
}

.field-error {
    display: block;
    color: #9c2434;
    font-size: 13px;
    line-height: 1.5;
    margin: 6px 0;
}

.admin-filters>.field-error {
    flex-basis: 100%;
}

[aria-invalid=true] {
    border-color: #9c2434 !important;
}

.staff-ui #content .report-heading {
    font: 500 30px/1.25 Lora,Georgia,serif;
    margin: 0 0 12px;
    color: var(--elu-ink);
}

.staff-ui #payments-summary td {
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.staff-ui body {
    background: var(--elu-bg);
    color: var(--elu-ink);
    font-family: 'Open Sans',sans-serif;
    line-height: 1.6;
}

.staff-ui body:not(.public-content-page) {
    font-size: 14px;
}

.staff-ui .navbar {
    background: var(--elu-surface);
    border-bottom: 1px solid var(--elu-line);
    box-shadow: none;
}

.staff-ui #sidebar {
    position: fixed;
    left: 0;
    top: var(--navbar-height,56px);
    height: calc(100vh - var(--navbar-height,56px));
    margin-left: 0;
    background: var(--elu-surface);
    border-right: 1px solid var(--elu-line);
    overflow-y: auto;
    z-index: 30;
}

.staff-ui .sidebar li a,
.staff-ui .sidebar li a.collapsed {
    background: transparent;
    color: var(--elu-muted);
    border-bottom: 1px solid var(--elu-line);
    padding: 15px 12px;
    font-size: 13px;
}

.staff-ui .sidebar li a.active,
.staff-ui .sidebar li a[aria-current=page] {
    background: var(--elu-soft);
    color: var(--elu-accent);
    font-weight: 600;
}

.staff-ui .sidebar li a:hover {
    background: var(--elu-soft) !important;
    color: var(--elu-accent) !important;
    border-color: var(--elu-line);
}

.staff-ui .sidebar .sub-menu li a {
    padding: 11px 12px 11px 12px;
    background: transparent;
}

.staff-ui #content {
    position: relative;
    top: auto;
    right: auto;
    margin-left: 200px;
    min-width: 0;
    width: calc(100% - 200px);
    padding: calc(var(--navbar-height,56px) + 20px) 24px 32px;
}

.staff-ui #content>.row {
    margin: 0;
}

.staff-ui #content>.row>.col-12 {
    padding: 0 !important;
}

.staff-ui #content .admin-page-title,
.staff-ui #content>.list-page .list-title {
    font: 500 30px/1.25 Lora,Georgia,serif;
    margin: 0 0 var(--elu-admin-gap);
    color: var(--elu-ink);
}

/* The summary line belongs to the title */
.staff-ui #content>.list-page .list-heading .list-title {
    margin-bottom: 4px;
}

.staff-ui #content .list-page {
    padding: 0;
    max-width: none;
}

.staff-ui .card {
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-radius: var(--elu-radius-card);
    box-shadow: none;
    margin: 0 0 var(--elu-admin-gap);
}

.staff-ui .card-body {
    padding: 20px;
}

.staff-ui .card-body>form {
    margin: 0;
}

.staff-ui .card-body form>.row {
    row-gap: 16px;
}

.staff-ui #content form:not([hidden]) label,
.form-page label {
    font-size: 13px;
    font-weight: 600;
    color: var(--elu-muted);
    margin-top: 12px;
    margin-bottom: 6px;
}

.staff-ui .form-control,
.form-page .form-control,
.staff-ui .dt-container .dt-input {
    min-height: var(--elu-control-height);
    height: auto;
    padding: 9px 12px;
    background: var(--elu-surface);
    color: var(--elu-ink);
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    font-size: 14px;
}

/* Native selects: Safari ignores min-height and padding on its own menu button, so the
   selects draw their own look with a fixed height (checked in macOS Safari).
   The arrow colour is --elu-muted (a data URI cannot use a variable). */
.staff-ui select.form-control:not([multiple]):not([size]),
.staff-ui .calendar-heading-actions select,
.form-page select.form-control:not([multiple]):not([size]) {
    -webkit-appearance: none;
    appearance: none;
    height: var(--elu-control-height);
    padding: 0 36px 0 12px;
    line-height: 1.4;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%23576767' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px 8px;
    text-overflow: ellipsis;
    cursor: pointer;
}

.staff-ui select.form-control:not([multiple]):not([size]):disabled,
.staff-ui .calendar-heading-actions select:disabled,
.form-page select.form-control:not([multiple]):not([size]):disabled {
    background-color: var(--elu-bg);
    color: var(--elu-muted);
    cursor: not-allowed;
}

.staff-ui textarea.form-control {
    min-height: 130px;
    resize: vertical;
}

.staff-ui input[type=color].form-control {
    padding: 4px;
    min-height: 44px;
    max-width: 180px;
}

.staff-ui input[type=checkbox]:not([role=switch]),
.staff-ui input[type=radio],
.form-page input[type=checkbox] {
    accent-color: var(--elu-accent);
    width: 18px;
    height: 18px;
    /* Keeps the box square beside long text in flex labels */
    flex-shrink: 0;
    vertical-align: middle;
}

.staff-ui input[type=file] {
    max-width: 100%;
    padding: 10px 0;
    color: var(--elu-muted);
}

.staff-ui input[type=file]::file-selector-button {
    padding: 8px 14px;
    background: var(--elu-surface);
    color: var(--elu-ink);
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    margin-right: 10px;
}

.admin-form-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
    padding-top: var(--elu-admin-gap);
    margin-top: var(--elu-admin-gap);
    border-top: 1px solid var(--elu-line);
}

/* Shared colour picker (app/color-field.php, js/color-field.js) */
.color-field label {
    display: block;
    line-height: 21px;
}

.color-field-controls {
    display: flex;
    gap: 8px;
    align-items: center;
}

.color-field-swatch {
    flex: 0 0 auto;
    width: 44px;
    height: 38px;
    padding: 2px;
    border: 1px solid var(--elu-border);
    border-radius: 6px;
    background: var(--elu-surface);
    cursor: pointer;
}

.color-field-swatch:focus-visible {
    outline: 3px solid var(--elu-accent);
    outline-offset: 2px;
}

.color-field-hex {
    width: 7.5em;
    font-family: SFMono-Regular, Consolas, monospace;
}

.color-field-error {
    margin: 4px 0 0;
    font-size: 13px;
    color: var(--elu-danger);
}

/* Calendar colour settings (settings/booking.php) */
.calendar-colors-card {
    container-type: inline-size;
    margin-top: var(--elu-space-5);
}

.calendar-colors-card h2 {
    font-size: 20px;
    margin: 0 0 8px;
}

.staff-ui #content form:not([hidden]) .booking-settings-options h2 > label {
    font: inherit;
    color: inherit;
    margin: 0;
}

.admin-checkbox-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.admin-checkbox-row input[type=checkbox] {
    position: static;
    flex: 0 0 18px;
    margin: 0;
}

/* One on/off control for admin forms, filters and list rows. */
input[type=checkbox].admin-switch,
input[type=checkbox].list-switch {
    appearance: none;
    position: relative;
    display: inline-block;
    flex: 0 0 40px;
    width: 40px;
    min-width: 40px;
    height: 24px;
    margin: 0;
    padding: 0;
    border: 1px solid var(--elu-muted);
    border-radius: 999px;
    background: var(--elu-surface);
    vertical-align: middle;
    cursor: pointer;
}
.admin-switch::after,
.list-switch::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--elu-muted);
    transition: transform .15s ease;
}
input[type=checkbox].admin-switch:checked,
input[type=checkbox].list-switch:checked { background: var(--elu-accent); border-color: var(--elu-accent); }
.admin-switch:checked::after,
.list-switch:checked::after { transform: translateX(16px); background: #fff; }
input[type=checkbox].admin-switch:focus-visible,
input[type=checkbox].list-switch:focus-visible { outline: 3px solid var(--elu-accent); outline-offset: 3px; }
input[type=checkbox].admin-switch:disabled,
input[type=checkbox].list-switch:disabled { opacity: .55; cursor: not-allowed; }
@media (prefers-reduced-motion: reduce) {
    .admin-switch::after,.list-switch::after { transition: none; }
}
.admin-checkbox-row label[for] { cursor: pointer; }

/* Weekday switch under its label, centred on the time fields beside it (shifts/edit_shifts.php) */
.shift-day-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.shift-day-toggle input[type=checkbox].admin-switch {
    /* The switch's 40px flex basis would set its height in a column */
    flex: 0 0 auto;
    margin-block: calc((var(--elu-control-height) - 24px) / 2);
}

.staff-ui #content form:not([hidden]) .admin-checkbox-row label {
    margin: 0;
}

.booking-settings-visibility {
    min-height: 44px;
}

.booking-date-calendar {
    max-width: calc(100vw - 16px);
}
.booking-date-calendar .flatpickr-rContainer {
    flex: 1;
    min-width: 0;
}
.booking-date-calendar :is(.flatpickr-days,.dayContainer) {
    width: 100%;
    min-width: 0;
    max-width: none;
}

.calendar-color-row {
    display: grid;
    /* Base layout also fits a narrow card beside the desktop sidebar. */
    grid-template-columns: minmax(0, 1fr);
    min-width: 0;
    gap: var(--elu-space-3) var(--elu-space-4);
    align-items: start;
    padding: 16px 0;
    margin: 0;
    border-top: 1px solid var(--elu-line);
}

.calendar-color-row legend {
    grid-column: 1 / -1;
    float: left;
    width: 100%;
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.calendar-color-fields {
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
}

/* Wide cards align previews with the fields in the container query below. */
.calendar-color-preview,
.calendar-color-contrast {
    display: flex;
    align-items: center;
    min-height: 44px;
    margin: 0;
}

.calendar-color-preview {
    padding: 4px 10px;
    border-left: 4px solid var(--elu-border);
    font-size: 13px;
    line-height: 1.35;
}

.calendar-color-contrast {
    font-size: 13px;
}

.calendar-color-contrast.is-low {
    color: var(--elu-danger);
    font-weight: 600;
}

/* Reset follows the fields in narrow cards; wide cards align it beside them. */
.calendar-color-reset {
    justify-self: start;
    margin-top: 0;
}

.calendar-color-preview--scheduled { background: var(--cal-scheduled-bg); color: var(--cal-scheduled-text); }
.calendar-color-preview--arrived { background: var(--cal-arrived-bg); color: var(--cal-arrived-text); }
.calendar-color-preview--completed { background: var(--cal-completed-bg); color: var(--cal-completed-text); }
.calendar-color-preview--noshow { background: var(--cal-noshow-bg); color: var(--cal-noshow-text); }
.calendar-color-preview--timeoff { background: var(--cal-timeoff-bg); color: var(--cal-timeoff-text); }
.calendar-color-preview--pause { background: var(--cal-pause-bg); color: var(--cal-pause-text); border-left-color: var(--elu-availability-border); }
.calendar-color-preview--unavailable { background: var(--cal-unavailable-bg); color: var(--cal-unavailable-text); border-left-color: var(--elu-availability-border); }
.calendar-color-preview--closed {
    background: repeating-linear-gradient(135deg,var(--cal-closed-bg),var(--cal-closed-bg) 10px,var(--cal-closed-stripe) 10px,var(--cal-closed-stripe) 12px);
    color: var(--cal-closed-text);
    border-left: 0;
}

@container (min-width: 920px) {
    .calendar-color-row {
        grid-template-columns: minmax(130px, 170px) minmax(0, 1fr) minmax(150px, 1fr) auto;
    }

    .calendar-color-preview,
    .calendar-color-contrast {
        margin-top: 39px;
    }

    .calendar-color-reset {
        justify-self: end;
        margin-top: 39px;
    }
}

/* Theme settings (settings/theme.php) */
.theme-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 440px);
    gap: 24px;
    align-items: start;
}

.theme-settings {
    container-type: inline-size;
    min-width: 0;
}

/* The first card and the preview panel start on the same line */
.theme-settings .card:first-child {
    margin-top: 0;
}

.theme-settings .card + .card {
    margin-top: 24px;
}

.theme-settings h2,
.theme-preview-panel h2 {
    font-size: 20px;
    margin: 0 0 8px;
}

.theme-settings h3 {
    font-size: 17px;
    margin: 0 0 8px;
}

.theme-color-group {
    min-width: 0;
    margin: 16px 0 0;
    padding: 0;
    border: 0;
}

.theme-color-group legend {
    width: 100%;
    margin: 0;
    padding: 12px 0 0;
    font-size: 16px;
    font-weight: 600;
    border-top: 1px solid var(--elu-line);
}

.theme-color-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 4px 16px;
    align-items: center;
    padding: 4px 0 8px;
}

.theme-color-help {
    margin: 0;
    font-size: 13px;
    color: var(--elu-muted);
}

.theme-color-reset {
    justify-self: start;
    margin-top: 0;
}

@container (min-width: 640px) {
    .theme-color-row {
        grid-template-columns: minmax(200px, 260px) minmax(180px, 1fr) auto;
    }

    .theme-color-row > .theme-color-help {
        margin-top: 39px;
    }

    .theme-color-reset {
        justify-self: end;
        margin-top: 39px;
    }
}

/* Button rows reuse the calendar colour row layout (.calendar-color-row) */
.theme-button-intro {
    margin: 8px 0 0;
}

.theme-button-row legend {
    padding-top: 0;
    border-top: 0;
}

.theme-button-preview {
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 7px;
}

.theme-button-preview--primary { background: var(--elu-btn-primary); color: var(--elu-primary-text); }
.theme-button-preview--back { background: var(--elu-btn-back); color: var(--elu-btn-back-text); border-color: var(--elu-border); }
.theme-button-preview--arrived { background: var(--elu-btn-arrived); color: var(--elu-btn-arrived-text); }
.theme-button-preview--noshow { background: var(--elu-btn-noshow); color: var(--elu-btn-noshow-text); }
.theme-button-preview--cancel { background: var(--elu-btn-cancel); color: var(--elu-btn-cancel-text); }
.theme-button-preview--save { background: var(--elu-btn-save); color: var(--elu-btn-save-text); }
.theme-button-preview--notes { background: var(--elu-btn-notes); color: var(--elu-btn-notes-text); }
.theme-button-preview--complete { background: var(--elu-btn-complete); color: var(--elu-btn-complete-text); }

.theme-button-help {
    grid-column: 1 / -1;
    margin: 0;
    font-size: 13px;
    color: var(--elu-muted);
}

.theme-contrast-title {
    margin-top: 24px !important;
}

.theme-contrast-summary {
    margin: 0 0 8px;
    font-weight: 600;
    color: var(--elu-green);
}

.theme-contrast-summary.is-low,
.theme-contrast-list .is-low {
    color: var(--elu-danger);
    font-weight: 600;
}

.theme-contrast-list {
    margin: 0;
    padding-left: 20px;
    font-size: 13px;
    line-height: 1.7;
    columns: 2 320px;
}

.theme-image-form {
    padding: 16px 0;
    border-top: 1px solid var(--elu-line);
}

.theme-image-body {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 20px;
    align-items: start;
}

.theme-image-thumb {
    display: grid;
    place-items: center;
    height: 120px;
    padding: 10px;
    background: repeating-conic-gradient(#eef1f0 0 25%, #fff 0 50%) 0 0/16px 16px;
    border: 1px solid var(--elu-line);
    border-radius: 8px;
}

.theme-image-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.theme-image-thumb--hero {
    padding: 0;
    overflow: hidden;
}

.theme-image-thumb--hero img {
    width: 100%;
    height: 100%;
    max-height: none;
    object-fit: cover;
}

.theme-image-current,
.theme-image-hint {
    margin: 4px 0 0;
    font-size: 13px;
    color: var(--elu-muted);
}

.theme-image-fields input[type=file] {
    display: block;
    max-width: 100%;
}

.theme-image-fields select {
    max-width: 220px;
}

.theme-image-message {
    margin: 8px 0 0;
    font-size: 13px;
    color: var(--elu-danger);
}

/* Also .admin-form-actions, so js/admin-ui.js adds no extra back link; without its divider line */
.theme-image-actions {
    margin-top: 14px;
    padding-top: 0;
    border-top: 0;
}

.theme-preview-panel {
    position: sticky;
    top: calc(var(--navbar-height, 56px) + 16px);
    padding: 24px;
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-radius: 12px;
}

.theme-preview-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.staff-ui .theme-preview-tabs .btn {
    min-height: 36px;
    padding: 6px 12px;
    font-size: 13px;
    color: var(--elu-muted);
    background: var(--elu-surface);
    border: 1px solid var(--elu-border);
}

.staff-ui .theme-preview-tabs .btn[aria-pressed=true] {
    color: var(--elu-surface);
    background: var(--elu-ink);
    border-color: var(--elu-ink);
}

/* The preview reads the --elu-* variables that js/theme-settings.js sets on #theme-preview */
.theme-preview {
    overflow: hidden;
    font-size: 13px;
    color: var(--elu-ink);
    background: var(--elu-bg);
    border: 1px solid var(--elu-line);
    border-radius: 8px;
}

.tp-browser {
    padding: 6px 8px 0;
    background: #dfe4e3;
}

.tp-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    font-size: 12px;
    color: #263737;
    background: #fff;
    border-radius: 6px 6px 0 0;
}

.tp-tab img {
    width: 16px;
    height: 16px;
    object-fit: contain;
}

.tp-view {
    min-height: 320px;
}

.tp-view > .tp-card,
.tp-thanks .tp-card,
.tp-login .tp-card {
    margin: 14px;
}

.tp-menu {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: var(--elu-surface);
    border-bottom: 1px solid var(--elu-line);
}

.tp-brand {
    display: flex;
    align-items: center;
    gap: 6px;
}

.tp-brand img {
    height: 26px;
    width: auto;
}

.tp-nav {
    margin-left: auto;
    color: var(--elu-muted);
}

.tp-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 130px;
    background: var(--elu-surface);
}

.tp-hero-copy {
    display: flex;
    flex-direction: column;
    padding: 14px;
    border-top: 3px solid var(--elu-coral);
}

.tp-hero-photo,
.tp-thanks {
    background: var(--elu-hero-image, url('../images/bg-registration-form.jpg')) var(--elu-hero-position, right center)/cover no-repeat;
}

.tp-eyebrow {
    font-size: 11px;
    color: var(--elu-accent);
}

.tp-title {
    display: block;
    margin: 4px 0;
    font-size: 17px;
    font-weight: 600;
}

.tp-text {
    display: block;
    color: var(--elu-muted);
}

.tp-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 14px;
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-radius: 8px;
}

.tp-label {
    margin-top: 6px;
    font-size: 12px;
    color: var(--elu-muted);
}

.tp-input {
    align-self: stretch;
    padding: 6px 9px;
    background: var(--elu-surface);
    border: 1px solid var(--elu-border);
    border-radius: 6px;
}

.tp-input-error {
    border: 2px solid var(--elu-danger);
}

.tp-error {
    font-size: 12px;
    color: var(--elu-danger);
}

.tp-success {
    font-size: 12px;
    color: var(--elu-green);
}

.tp-link {
    color: var(--elu-accent);
    text-decoration: underline;
}

.tp-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--elu-space-2);
    margin: var(--elu-space-2) 0;
}

.tp-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-self: stretch;
    gap: var(--elu-space-2);
    margin: var(--elu-space-2) 0;
}

.tp-btn {
    display: inline-block;
    padding: 6px 12px;
    text-align: center;
    border: 1px solid transparent;
    border-radius: 6px;
}

.tp-primary {
    color: var(--elu-primary-text);
    background: var(--elu-btn-primary);
}

.tp-primary:hover {
    background: var(--elu-btn-primary-hover);
}

.tp-secondary {
    color: var(--elu-muted);
    background: var(--elu-surface);
    border-color: var(--elu-border);
}

.tp-back {
    color: var(--elu-btn-back-text);
    background: var(--elu-btn-back);
    border-color: var(--elu-border);
}

.tp-cancel { color: var(--elu-btn-cancel-text); background: var(--elu-btn-cancel); }
.tp-save { color: var(--elu-btn-save-text); background: var(--elu-btn-save); }
.tp-save:hover { background: var(--elu-btn-save-hover); }
/* Like the booking dialog: Lõpeta broneering alone on the last line */
.tp-grid .tp-complete { grid-column: 1 / -1; justify-self: center; min-width: 50%; }
.tp-back:hover { background: var(--elu-btn-back-hover); }
.tp-cancel:hover { background: var(--elu-btn-cancel-hover); }
.tp-arrived:hover { background: var(--elu-btn-arrived-hover); }
.tp-noshow:hover { background: var(--elu-btn-noshow-hover); }
.tp-notes:hover { background: var(--elu-btn-notes-hover); }
.tp-complete:hover { background: var(--elu-btn-complete-hover); }

.tp-danger {
    color: var(--elu-danger);
    background: var(--elu-surface);
    border-color: var(--elu-danger);
}

.tp-arrived { color: var(--elu-btn-arrived-text); background: var(--elu-btn-arrived); }
.tp-noshow { color: var(--elu-btn-noshow-text); background: var(--elu-btn-noshow); }
.tp-notes { color: var(--elu-btn-notes-text); background: var(--elu-btn-notes); }
.tp-complete { color: var(--elu-btn-complete-text); background: var(--elu-btn-complete); }

.tp-wide {
    align-self: stretch;
    margin-top: 10px;
}

.tp-thanks,
.tp-login {
    display: flex;
    align-items: center;
    justify-content: center;
}

.tp-thanks .tp-card {
    max-width: 240px;
}

.tp-login .tp-card {
    width: 240px;
}

.tp-login-logo {
    align-self: center;
    height: 44px;
    width: auto;
}

.tp-email {
    padding: 14px;
}

.tp-mail {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    padding: 16px;
    background: var(--elu-surface);
    border-top: 4px solid var(--elu-accent);
}

.tp-mail-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: Georgia, serif;
    font-size: 15px;
}

.tp-mail-brand img {
    height: 30px;
    width: auto;
}

.tp-mail-footer {
    margin-top: 10px;
    font-size: 11px;
}

@media (max-width: 1199px) {
    .theme-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .theme-preview-panel {
        position: static;
    }
}

@media (max-width: 767px) {
    .theme-image-body {
        grid-template-columns: minmax(0, 1fr);
    }
}

.staff-ui .form-control[aria-invalid=true],
.form-page .form-control[aria-invalid=true] {
    border: 2px solid var(--elu-danger);
}

.staff-ui .admin-choice {
    display: flex;
    gap: 10px;
    align-items: start;
    cursor: pointer;
    margin: 0 !important;
    font-weight: 400 !important;
}

.staff-ui .admin-choice input {
    flex-shrink: 0;
    margin: 1px 0 0;
}

.form-page .admin-question {
    display: flex;
    align-items: start;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid var(--elu-line);
}

.form-page .admin-question input {
    flex-shrink: 0;
    margin: 4px 0 0;
}

.form-page .admin-question label {
    margin: 0;
    font-weight: 400;
    color: var(--elu-ink);
    cursor: pointer;
}

.staff-ui .jodit-container {
    border: 1px solid var(--elu-border);
    border-radius: 7px;
    max-width: 100%;
    margin-bottom: 18px;
}

.staff-ui .jodit-toolbar__box {
    border-radius: 7px 7px 0 0;
}

.staff-ui form[name=reportform] {
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-radius: 10px;
    padding: 12px 16px;
    margin: 0 0 var(--elu-admin-gap);
}

/* View, date range and employee on one line, the submit button last (reports/payments-details.php) */
.staff-ui form[name=reportform]>.row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px 16px;
    margin: 0;
}

.staff-ui form[name=reportform]>.row>div {
    flex: 0 1 240px;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
}

.staff-ui form[name=reportform]>.row>.report-form-submit {
    flex: 0 0 auto;
}

.staff-ui #content form[name=reportform]:not([hidden]) label {
    margin-top: 0;
}

.staff-ui form[name=reportform] input {
    width: 100%;
}

/* Cancelled bookings and busy time: listed, not counted (the status column says why) */
.staff-ui .report-page .report-row-excluded td {
    color: var(--elu-muted);
}

.staff-ui .report-page .card-body {
    font-variant-numeric: tabular-nums;
}

.staff-ui .report-page .card[style*="float"] {
    float: none !important;
    display: inline-block;
    vertical-align: top;
    max-width: 100%;
}

/* One button geometry, with functional primary / secondary / danger variants. */
body .btn {
    border-radius: 7px;
    font: 600 13px/1.4 'Open Sans',sans-serif;
    /* Vertical padding centres one text line in the control height (border 2px) */
    padding: calc((var(--elu-control-height) - 2px - 1.4em) / 2) 16px;
    min-height: var(--elu-control-height);
    box-shadow: none;
    white-space: normal;
    text-decoration: none;
    transition: background-color .16s,border-color .16s;
}

body .btn-primary {
    background: var(--elu-btn-primary) !important;
    border: 1px solid var(--elu-btn-primary) !important;
    color: var(--elu-primary-text) !important;
}

body .btn-primary:hover {
    background: var(--elu-btn-primary-hover) !important;
    border-color: var(--elu-btn-primary-hover) !important;
}

/* Colour reset buttons and list row actions look like secondary buttons; separate selectors
   (not inside :is) so each keeps its own specificity */
body :is(.btn-secondary,.btn-outline-secondary,.btn-default,.btn-light),
body .theme-color-reset,
body .calendar-color-reset,
body .list-table .col-actions a,
body .category-archive {
    background: var(--elu-surface);
    border: 1px solid var(--elu-border);
    color: var(--elu-muted);
}

body :is(.btn-secondary,.btn-outline-secondary,.btn-default,.btn-light):hover,
body .theme-color-reset:hover,
body .calendar-color-reset:hover,
body .list-table .col-actions a:hover,
body .category-archive:hover {
    background: var(--elu-bg);
    color: var(--elu-ink);
    border-color: var(--elu-ink);
}

/* The list actions are not .btn elements: the same size and shape as body .btn */
body .list-table .col-actions a,
body .category-archive {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    font: 400 13px/1.4 'Open Sans',sans-serif;
    padding: 10px 16px;
    min-height: var(--elu-control-height);
    text-decoration: none;
    vertical-align: middle;
    transition: background-color .16s,border-color .16s;
}

body :is(.btn-danger,.btn-outline-danger) {
    background: var(--elu-surface);
    color: var(--elu-danger);
    border: 1px solid var(--elu-danger);
}

body :is(.btn-danger,.btn-outline-danger):hover {
    background: var(--elu-danger);
    color: white;
}

body .btn-sm {
    padding: 7px 11px;
    min-height: 36px;
    font-size: 12px;
}

body .btn:disabled,
body .btn.disabled {
    opacity: .55;
    cursor: not-allowed;
    transform: none;
}

.staff-ui :is(a,button,input,select,textarea,summary):focus-visible,
.form-page :is(a,button,input,select,textarea):focus-visible,
body .btn:focus-visible {
    outline: 3px solid var(--elu-green);
    outline-offset: 3px;
    box-shadow: none;
}

.admin-data-page {
    max-width: 1500px;
}

.admin-heading {
    display: flex;
    justify-content: space-between;
    align-items: start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: var(--elu-admin-gap);
}

.admin-heading h1 {
    font: 500 30px/1.25 Lora,Georgia,serif;
    margin: 0;
}

.admin-heading p {
    margin: 6px 0 0;
    color: var(--elu-muted);
    max-width: 70ch;
}

.admin-filters {
    display: flex;
    gap: 12px;
    align-items: end;
    flex-wrap: wrap;
    margin: 0 0 var(--elu-admin-gap);
    padding: 12px 16px;
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-radius: 10px;
}

.admin-filters label {
    margin: 0 !important;
    font-size: 13px;
    font-weight: 600;
}

.admin-filters .form-control {
    margin-top: 6px;
}

.admin-filters.client-filters {
    align-items: center;
}

/* Switch and its text centred on one line, like the select label beside them */
.admin-filters label:has(> .admin-switch) {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.admin-filters .client-marketing-filter {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 1 auto;
    max-width: 100%;
    min-width: 0;
}

.client-marketing-filter label {
    flex-shrink: 0;
}

.admin-filters .client-marketing-filter .form-control {
    width: 160px;
    min-width: 0;
    margin-top: 0;
}

.admin-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 var(--elu-admin-gap);
}

.admin-tabs [aria-pressed=true] {
    background: var(--elu-ink);
    color: white;
    border-color: var(--elu-ink);
}

.admin-tabs [aria-pressed=true]::before {
    content: '\2713\00a0';
}

.admin-table-scroll {
    overflow-x: auto;
    max-width: 100%;
    border: 1px solid var(--elu-line);
    border-radius: 10px;
    background: var(--elu-surface);
    padding: 16px;
    scroll-margin-top: 80px;
}

.staff-ui .table {
    color: var(--elu-ink);
    margin-bottom: 0;
    background: var(--elu-surface);
    font-size: 13px;
    min-width: 650px;
}

.staff-ui .table thead th {
    background: #f0f4f2;
    border-top: 0;
    border-bottom: 1px solid var(--elu-line);
    font-size: 12px;
    font-weight: 600;
    color: var(--elu-muted);
    vertical-align: middle;
    padding: 13px 12px;
}

.staff-ui .table td,
.staff-ui .table tbody th {
    border-color: var(--elu-line);
    padding: 13px 12px;
    vertical-align: middle;
}

.staff-ui .table-striped tbody tr:nth-of-type(odd) {
    background: #fafcfb;
}

.staff-ui .table-hover tbody tr:hover {
    background: var(--elu-soft);
}

.staff-ui .table .admin-number,
.staff-ui .table .text-right {
    font-variant-numeric: tabular-nums;
    text-align: right !important;
    white-space: nowrap;
}

.admin-row-actions,
.admin-info-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.admin-row-actions .btn {
    min-width: 70px;
}

.admin-info-links .btn {
    min-width: 0;
}

.admin-status {
    display: inline-block;
    padding: 3px 9px;
    border-radius: 5px;
    background: #edf2f0;
    color: var(--elu-green);
    font-size: 12px;
    font-weight: 600;
}

.admin-status-warning {
    background: #fff1d6;
    color: #6b4200;
}

.admin-status-muted {
    background: #edf0f0;
    color: var(--elu-muted);
}

.admin-totals {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 24px;
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    padding: 12px 16px;
    margin: 0 0 var(--elu-admin-gap);
    border-radius: 10px;
    font-variant-numeric: tabular-nums;
}

.admin-totals strong {
    display: block;
    font-size: 20px;
    color: var(--elu-ink);
}

/* Page filters on the DataTables search row. A table names its filters with
   data-table-filters and js/admin-ui.js moves them here; without JS they stay above the table. */
.admin-table-top {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px 16px;
    margin-bottom: 12px;
}

.admin-table-top > .dt-search {
    margin: 0 0 0 auto;
}

.admin-table-top :is(.admin-filters,.admin-tabs,.admin-totals) {
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
}

/* Several filter groups in one block (gift cards: status buttons and totals) */
.admin-table-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 24px;
    margin-bottom: var(--elu-admin-gap);
}

.admin-table-top .admin-table-filters {
    margin-bottom: 0;
}

/* Totals as one line beside buttons, centred on the control height */
.admin-totals.admin-totals--inline {
    align-items: center;
    gap: 16px;
    min-height: var(--elu-control-height);
    padding: 0;
    border: 0;
    background: none;
    margin: 0;
}

.admin-totals--inline > div {
    display: flex;
    align-items: baseline;
    gap: 6px;
    color: var(--elu-muted);
}

.admin-totals--inline strong {
    display: inline;
    font-size: 16px;
}

/* One-line entry form: fields side by side, the save button at the end (sell/product-sales.php) */
.admin-entry-form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px 16px;
}

.admin-entry-field {
    flex: 1 1 150px;
    min-width: 0;
}

.staff-ui #content form.admin-entry-form:not([hidden]) label {
    margin-top: 0;
}

.admin-entry-form .admin-form-actions {
    margin: 0;
    padding: 0;
    border: 0;
}

.staff-ui .dataTables_wrapper .dataTables_filter {
    margin-bottom: 16px;
}

.staff-ui .dataTables_wrapper input,
.staff-ui .dataTables_wrapper select {
    border: 1px solid var(--elu-border);
    border-radius: 6px;
    padding: 8px;
    background: var(--elu-surface);
    color: var(--elu-ink);
}

.staff-ui .dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--elu-soft) !important;
    border: 1px solid var(--elu-accent);
    border-radius: 6px;
    color: var(--elu-accent) !important;
}

.staff-ui .dataTables_info {
    font-size: 12px;
    color: var(--elu-muted);
}

.form-page {
    background: var(--elu-bg);
    color: var(--elu-ink);
}

.form-page .booking-wrapper {
    position: static;
    display: block;
    min-height: 100vh;
    height: auto;
    overflow: visible;
    padding: 32px 16px;
    background: var(--elu-bg);
}

.form-page .booking-inner {
    position: static;
    transform: none;
    display: block;
    max-width: 760px;
    width: 100%;
    max-height: none;
    margin: auto;
    overflow: visible;
}

.form-page .booking-form {
    background: var(--elu-surface);
    border: 1px solid var(--elu-line);
    border-radius: var(--elu-radius-card);
    padding: var(--elu-space-5);
}

.form-page .booking-result-title {
    font: 500 28px/1.3 Lora,Georgia,serif;
}

.form-page .booking-form .booking-form-row {
    margin: 0;
}

.form-page .full-length {
    width: 100%;
}

.form-page .booking-form button {
    margin-top: 20px;
}

.booking-result-actions {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 12px;
    margin-top: 20px;
}

.booking-result-actions--single {
    grid-template-columns: minmax(0,1fr);
}

.form-page .booking-form .booking-result-actions > .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    margin: 0;
    white-space: normal;
    text-align: center;
}

@media (max-width: 1100px) {
    .staff-ui .navbar-expand-md {
        flex-wrap: wrap;
    }
    .staff-ui .navbar-expand-md .navbar-toggler {
        display: block !important;
    }
    .staff-ui .navbar-expand-md .navbar-collapse {
        display: none !important;
        flex-basis: 100%;
        background: var(--elu-surface);
        padding: 12px;
    }
    .staff-ui .navbar-expand-md .navbar-collapse.show {
        display: block !important;
    }
    .staff-ui .navbar-expand-md .navbar-nav {
        flex-direction: column;
        align-items: stretch;
    }
    .staff-ui .navbar-expand-md .dropdown-menu {
        position: static;
    }
}

@media (max-width: 767px) {
    .staff-ui #content {
        width: 100% !important;
        margin-left: 0;
        padding: calc(var(--navbar-height,56px) + 16px) 16px 24px;
    }
    .staff-ui #sidebar {
        margin-left: 0;
        box-shadow: 12px 0 35px #26373720;
    }
    .staff-ui #sidebar.hidden {
        display: none !important;
    }
    .staff-ui .card-body {
        padding: var(--elu-space-4);
    }
    .admin-filters>* {
        flex: 1 1 160px;
    }
    .admin-heading h1,
    .staff-ui #content .admin-page-title {
        font-size: 26px;
    }
    .admin-table-scroll {
        padding: 10px;
    }
    .form-page .booking-form {
        padding: 22px 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .staff-ui *,
    body .btn {
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

/* Button labels use regular weight throughout the application, including list controls. */
:is(button,input[type=button],input[type=submit],input[type=reset],.btn,.list-chip,.list-link-button,.list-text-button,.list-icon-button,.fc-button,.swal2-styled),
:is(button,.btn,.list-chip,.list-link-button,.list-text-button,.list-icon-button,.fc-button,.swal2-styled) :is(span,b,strong) {
    font-weight: 400 !important;
}

/* Public submenu pages inherit the body type size, including editor content.
 * Important is scoped here to override legacy inline sizes and staff table styles. */
body.public-content-page {
    background: var(--elu-bg);
    color: var(--elu-ink);
}

.public-content-page .card {
    background: var(--elu-surface);
}

.public-content-shell {
    padding-top: calc(var(--navbar-height, 47px) + var(--elu-space-6));
    padding-bottom: var(--elu-space-6);
}

.public-content-column {
    min-width: 0;
    padding-inline: var(--elu-space-4);
}

.public-content-shell .card-body {
    padding: var(--elu-space-5);
}

.public-content-title {
    font: 500 clamp(26px, 3vw, 32px)/1.25 Lora, Georgia, serif;
    margin: 0 0 var(--elu-space-5);
    color: var(--elu-ink);
}

.public-content-copy {
    max-width: 100%;
    overflow-wrap: anywhere;
}

.contact-details {
    display: grid;
    grid-template-columns: minmax(120px, auto) minmax(0, 1fr);
    gap: var(--elu-space-4) var(--elu-space-5);
    margin: var(--elu-space-5) 0 0;
}

.contact-details dt {
    color: var(--elu-muted);
    font-weight: 600;
}

.contact-details dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.staff-ui #content > .container-fluid {
    padding-inline: 0;
}

.staff-ui #content .public-content-shell {
    padding-top: 0;
}

@media (max-width: 767px) {
    .public-content-shell .card-body {
        padding: var(--elu-space-4);
    }

    .contact-details {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--elu-space-2);
    }

    .contact-details dd + dt {
        margin-top: var(--elu-space-4);
    }
}

.public-content-page table,
.public-content-page table * {
    font-size: inherit !important;
}

.public-service-table .service-price {
    white-space: nowrap;
    width: 1%;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.public-table-scroll {
    max-width: 100%;
    overflow-x: auto;
}

.public-table-scroll:focus-visible {
    outline: 3px solid var(--elu-accent);
    outline-offset: 3px;
}

.public-content-page .public-service-table {
    width: 100%;
    min-width: 0;
}

/* Public content tables: the approved coral price-list design. */
.public-content-page :is(table,.table) {
    width: 100%;
    border-collapse: collapse;
    background: var(--elu-surface);
    color: var(--elu-ink);
}

.public-content-page :is(table,.table) > thead > tr > th {
    background: var(--elu-soft);
    color: var(--elu-accent-hover);
    font-weight: 600;
    padding: 13px 16px;
    border: 0;
    border-bottom: 2px solid var(--elu-coral);
    vertical-align: middle;
}

.public-content-page :is(table,.table) > tbody > tr > :is(td,th) {
    padding: 18px 16px;
    border: 0;
    border-bottom: 1px solid var(--elu-line);
    vertical-align: middle;
}

.public-content-page :is(table,.table) > tbody > tr {
    background: var(--elu-surface);
}

.public-content-page :is(table,.table) > tbody > tr:hover {
    background: var(--elu-soft);
}

.public-content-page table :is(b,strong) {
    font-weight: 600;
}

.public-content-page table p {
    margin: 7px 0 0;
    color: var(--elu-muted);
    line-height: 1.6;
}

.public-service-description summary {
    width: fit-content;
    padding-block: 8px;
    color: var(--elu-accent-hover);
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.public-service-description summary:focus-visible {
    outline: 3px solid var(--elu-accent);
    outline-offset: 3px;
}

.public-service-description > div {
    max-width: 65ch;
    color: var(--elu-muted);
    line-height: 1.6;
}

@media (max-width: 520px) {
    .public-content-page :is(table,.table) > :is(thead,tbody) > tr > :is(td,th) {
        padding: 14px 10px;
    }
}

.frontpage-notice .modal-content {
    background: var(--elu-surface);
    color: var(--elu-ink);
    border-color: var(--elu-border);
}
.frontpage-notice .modal-body {
    overflow-wrap: anywhere;
}
.frontpage-notice .modal-body img {
    max-width: 100%;
    height: auto;
}
.frontpage-notice .modal-body table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
}
.frontpage-notice .close {
    color: var(--elu-ink);
    opacity: 1;
}
.frontpage-notice button:focus-visible {
    outline: 2px solid var(--elu-accent);
    outline-offset: 3px;
}
