/*
 * Admin UX redesign (owner 2026-11-02): calmer, clearer screens for non-technical staff.
 * Display only -- loaded after the theme, changes no behaviour. Remove the <link> in
 * layouts/partials/head-css.blade.php to switch the whole redesign off.
 */

/* ---- page header: what this page is for ---- */
.ux-page-intro {
    margin: 4px 0 20px;
    padding: 18px 22px;
    background: var(--bs-secondary-bg, #fff);
    border: 1px solid var(--bs-border-color, #e7e9ee);
    border-left: 4px solid #29628b;
    border-radius: 10px;
}
.ux-page-intro__title {
    margin: 0 0 4px;
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--bs-heading-color, #1f2937);
}
.ux-page-intro__text {
    margin: 0;
    max-width: 920px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--bs-secondary-color, #5b6472);
}

/* ---- sidebar: readable logo on the dark menu, clearer active item ---- */
.main-nav .logo-box .logo-lg,
.main-nav .logo-box .logo-sm {
    background: #fff;
    border-radius: 8px;
    padding: 4px 8px;
}
.main-nav .nav-link,
.main-nav .sub-nav-link {
    font-size: 0.95rem;
}
.main-nav .sub-nav-item .sub-nav-link.active,
.main-nav .nav-item .nav-link.active {
    font-weight: 600;
}
.main-nav .ux-nav-hint {
    display: block;
    font-size: 0.72rem;
    line-height: 1.25;
    opacity: 0.6;
    white-space: normal;
    margin-top: 1px;
}
html[data-menu-size="condensed"] .main-nav .ux-nav-hint,
html[data-menu-size="sm-hover"] .main-nav .ux-nav-hint {
    display: none;
}

/* ---- buttons: icon buttons also say what they do ---- */
.btn .ux-btn-label {
    margin-left: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    vertical-align: middle;
}
.btn.btn-sm:has(.ux-btn-label) {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}

/* ---- forms: field help in plain words ---- */
.ux-help {
    display: block;
    margin-top: 4px;
    font-size: 0.8rem;
    line-height: 1.4;
    color: var(--bs-secondary-color, #6b7280);
}
.ux-section-note {
    margin: 0 0 12px;
    font-size: 0.85rem;
    color: var(--bs-secondary-color, #6b7280);
}

/* ---- a save bar that stays in view on long forms ---- */
.ux-sticky-actions {
    position: sticky;
    bottom: 0;
    z-index: 20;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin: 16px -12px 0;
    padding: 12px 16px;
    background: var(--bs-body-bg, #fff);
    border-top: 1px solid var(--bs-border-color, #e7e9ee);
    box-shadow: 0 -6px 16px rgba(15, 23, 42, 0.06);
    border-radius: 10px 10px 0 0;
}
.ux-sticky-actions .ux-sticky-actions__hint {
    margin-right: auto;
    font-size: 0.85rem;
    color: var(--bs-secondary-color, #6b7280);
}

/* ---- tables: a little more room, readable headers ---- */
.table > thead th {
    font-weight: 600;
    white-space: nowrap;
}
.table > tbody td {
    vertical-align: middle;
}

/* ---- tools you rarely need, folded away ---- */
.ux-fold > summary {
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 1rem;
}
.ux-fold > summary::-webkit-details-marker { display: none; }
.ux-fold > summary::before {
    content: "\25B8";
    display: inline-block;
    transition: transform 0.15s;
}
.ux-fold[open] > summary::before { transform: rotate(90deg); }
.ux-fold > summary .ux-fold__hint {
    font-weight: 400;
    font-size: 0.85rem;
    color: var(--bs-secondary-color, #6b7280);
}

/* dates, amounts and action buttons on one line */
.table.ux-nowrap td { white-space: nowrap; }

/* "Go to ..." links in card footers stay on one line */
.card-footer a { white-space: nowrap; margin-left: 8px; }
