:root {
    --background: #f4f5f2;
    --surface: #ffffff;
    --surface-soft: #edf1ee;
    --surface-blue: #e9f0f5;

    --text: #090a09;
    --text-soft: #585c57;
    --text-muted: #858a83;

    --line: #d8dcd6;
    --line-dark: #b8bdb6;

    --black: #080908;
    --white: #ffffff;

    --success: #166534;
    --success-background: #effaf2;

    --danger: #b42318;
    --danger-background: #fff1f1;

    --warning: #8a5a00;
    --warning-background: #fff8e6;

    --gradient:
        radial-gradient(circle at 5% 20%, rgba(91, 255, 108, 0.88), transparent 32%),
        radial-gradient(circle at 40% 10%, rgba(130, 239, 204, 0.82), transparent 35%),
        radial-gradient(circle at 68% 72%, rgba(133, 192, 255, 0.72), transparent 42%),
        radial-gradient(circle at 92% 20%, rgba(230, 151, 182, 0.72), transparent 36%),
        linear-gradient(120deg, #cbffd1 0%, #b9ede3 42%, #c9b5f2 100%);

    --sidebar-width: 252px;
    --transition: 180ms ease;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: var(--background);
}

body {
    margin: 0;
    min-height: 100vh;

    font-family:
        Inter,
        e-Ukraine,
        Manrope,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    color: var(--text);
    background: var(--background);
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

/* ------------------------------------------------ */
/* APP LAYOUT */
/* ------------------------------------------------ */

.app-shell {
    display: grid;
    grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 30;

    width: var(--sidebar-width);
    height: 100vh;

    display: flex;
    flex-direction: column;

    padding: 20px 16px;

    color: var(--text);
    background: rgba(255, 255, 255, 0.96);

    border-right: 1px solid var(--line);
}

.content {
    grid-column: 2;
    min-width: 0;
}

.content-inner {
    width: min(100%, 1540px);
    margin: 0 auto;
    padding: 34px 34px 70px;
}

/* ------------------------------------------------ */
/* BRAND */
/* ------------------------------------------------ */

.sidebar-top {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 28px;
}

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

.brand-mark {
    display: grid;
    place-items: center;

    width: 42px;
    height: 42px;

    color: var(--white);
    background: var(--black);

    border-radius: 13px;

    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.brand-content strong,
.brand-content small {
    display: block;
}

.brand-content strong {
    font-size: 16px;
    line-height: 1.1;
    letter-spacing: -0.025em;
}

.brand-content small {
    margin-top: 4px;

    color: var(--text-muted);

    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.15em;
}

.mobile-menu-button {
    display: none;

    border: 0;
    background: transparent;

    font-size: 24px;
    cursor: pointer;
}

/* ------------------------------------------------ */
/* SIDEBAR NAVIGATION */
/* ------------------------------------------------ */

.sidebar-navigation {
    overflow-y: auto;
    scrollbar-width: thin;
}

.nav-section {
    margin: 26px 12px 10px;

    color: var(--text-muted);

    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.nav-list {
    display: grid;
    gap: 3px;
}

.nav-link {
    position: relative;

    display: flex;
    align-items: center;
    gap: 13px;

    min-height: 46px;
    padding: 0 13px;

    color: var(--text-soft);

    border-radius: 0;

    font-size: 13px;
    font-weight: 600;

    transition:
        color var(--transition),
        background var(--transition);
}

.nav-link::before {
    position: absolute;
    left: 0;
    top: 50%;

    width: 3px;
    height: 0;

    content: "";

    background: var(--black);

    transform: translateY(-50%);
    transition: height var(--transition);
}

.nav-link:hover {
    color: #ffffff;
    background: #111111;
}

.nav-link:hover .nav-icon {
    color: #ffffff;
}

.nav-link.active {
    color: #ffffff;
    background: #111111;
}

.nav-link.active .nav-icon {
    color: #ffffff;
}

.nav-link.active::before {
    background: #ffffff;
}

.nav-link.active {
    color: var(--text);
    background: #edf0ec;
}

.nav-link.active::before {
    height: 24px;
}

.nav-icon {
    display: grid;
    place-items: center;

    width: 22px;

    color: var(--text);

    font-size: 16px;
    font-weight: 500;
}

/* ------------------------------------------------ */
/* SIDEBAR USER */
/* ------------------------------------------------ */

.sidebar-user {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;

    margin-top: auto;
    padding-top: 18px;

    border-top: 1px solid var(--line);
}

.avatar {
    display: grid;
    place-items: center;

    width: 40px;
    height: 40px;

    color: var(--white);
    background: var(--black);

    border-radius: 50%;

    font-size: 11px;
    font-weight: 800;
}

.sidebar-user-info {
    min-width: 0;
}

.sidebar-user-info strong,
.sidebar-user-info small {
    display: block;

    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-user-info strong {
    font-size: 11px;
}

.sidebar-user-info small {
    margin-top: 3px;

    color: var(--text-muted);
    font-size: 9px;
}

.icon-button {
    display: inline-grid;
    place-items: center;

    width: 36px;
    height: 36px;

    padding: 0;

    color: inherit;
    background: transparent;

    border: 0;
    border-radius: 50%;

    cursor: pointer;
    transition:
        color var(--transition),
        background var(--transition);
}

.icon-button:hover {
    background: var(--surface-soft);
}

.logout-button {
    font-size: 18px;
}

/* ------------------------------------------------ */
/* TOPBAR */
/* ------------------------------------------------ */

.topbar {
    position: relative;

    min-height: 112px;

    overflow: hidden;

    background: var(--gradient);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.topbar::after {
    position: absolute;
    inset: 0;

    content: "";

    pointer-events: none;

    background:
        linear-gradient(
            90deg,
            rgba(255, 255, 255, 0.08),
            rgba(255, 255, 255, 0)
        );
}

.topbar-content {
    position: relative;
    z-index: 2;

    width: min(100%, 1540px);
    min-height: 112px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;

    margin: 0 auto;
    padding: 24px 34px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;

    font-size: 12px;
}

.breadcrumb strong {
    font-weight: 750;
}

.crumb {
    color: rgba(0, 0, 0, 0.58);
}

.breadcrumb-separator {
    color: rgba(0, 0, 0, 0.35);
}

.top-actions,
.actions {
    display: flex;
    align-items: center;
    gap: 9px;
}

/* ------------------------------------------------ */
/* BUTTONS */
/* ------------------------------------------------ */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    min-height: 42px;
    padding: 0 18px;

    color: var(--text);
    background: var(--surface);

    border: 1px solid rgba(0, 0, 0, 0.16);
    border-radius: 999px;

    font-size: 12px;
    font-weight: 700;
    line-height: 1;

    cursor: pointer;

    transition:
        transform var(--transition),
        color var(--transition),
        background var(--transition),
        border-color var(--transition);
}

.button:hover {
    transform: translateY(-1px);
}

.button-dark {
    color: var(--white);
    background: var(--black);
    border-color: var(--black);
}

.button-dark:hover {
    background: #242624;
}

.button-secondary {
    background: rgba(255, 255, 255, 0.66);
    backdrop-filter: blur(10px);
}

.button-secondary:hover {
    background: var(--white);
}

.button-small {
    min-height: 34px;
    padding: 0 13px;
    font-size: 11px;
}

.button-full {
    width: 100%;
}

.button-plus {
    font-size: 18px;
    line-height: 0;
}

/* ------------------------------------------------ */
/* PAGE HEADINGS */
/* ------------------------------------------------ */

.page-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 50px;

    padding: 24px 0 30px;

    border-bottom: 1px solid var(--line);
}

.page-heading.compact {
    align-items: center;
    padding: 15px 0 24px;
}

.page-heading h1 {
    max-width: 760px;

    margin: 6px 0 0;

    font-size: clamp(38px, 4vw, 64px);
    font-weight: 500;
    line-height: 0.98;
    letter-spacing: -0.055em;
}

.page-heading.compact h1 {
    font-size: clamp(32px, 3vw, 46px);
}

.page-heading p {
    margin: 10px 0 0;

    color: var(--text-soft);

    font-size: 13px;
    line-height: 1.55;
}

.page-heading > p {
    max-width: 500px;
    margin: 0;

    text-align: right;
}

.eyebrow {
    color: var(--text-muted);

    font-size: 9px;
    font-weight: 750;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

/* ------------------------------------------------ */
/* LAYOUT GRIDS */
/* ------------------------------------------------ */

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
    gap: 20px;

    margin-top: 28px;
}

.two-columns,
.detail-grid,
.case-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;

    margin-top: 20px;
}

/* ------------------------------------------------ */
/* CARDS */
/* ------------------------------------------------ */

.card {
    position: relative;

    padding: 24px;

    background: var(--surface);

    border: 0;
    border-top: 1px solid var(--line-dark);
    border-radius: 0;

    box-shadow: none;
}

.card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;

    margin-bottom: 22px;
}

.card h2 {
    margin: 0 0 6px;

    font-size: 20px;
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.card p {
    margin: 0;

    color: var(--text-soft);

    font-size: 12px;
    line-height: 1.55;
}

.dark-card {
    color: var(--white);
    background: var(--black);
    border-top-color: var(--black);
}

.dark-card p {
    color: #aaada7;
}

/* ------------------------------------------------ */
/* STATS */
/* ------------------------------------------------ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;

    background: var(--line);
    border: 1px solid var(--line);
}

.stat {
    display: block;

    min-height: 140px;
    padding: 20px;

    background: var(--surface-soft);

    transition: background var(--transition);
}

.stat:hover {
    background: var(--surface);
}

.stat small,
.stat span {
    display: block;
}

.stat small {
    color: var(--text-muted);

    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.stat strong {
    display: block;

    margin: 18px 0 10px;

    font-size: 40px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: -0.05em;
}

.stat span {
    color: var(--text-soft);
    font-size: 10px;
}

/* ------------------------------------------------ */
/* QUICK ACTIONS */
/* ------------------------------------------------ */

.quick-actions {
    display: grid;
}

.quick-actions a {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 17px 0;

    color: var(--white);
    background: transparent;

    border-bottom: 1px solid #303230;
    border-radius: 0;

    font-size: 12px;
    font-weight: 600;

    transition:
        color var(--transition),
        padding var(--transition);
}

.quick-actions a:hover {
    padding-left: 8px;
    color: #c8ffd0;
    background: transparent;
}

/* ------------------------------------------------ */
/* LISTS */
/* ------------------------------------------------ */

.simple-list {
    display: grid;
}

.simple-list > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;

    padding: 15px 0;

    border-top: 1px solid var(--line);

    transition: padding var(--transition);
}

.simple-list > a:first-child {
    border-top: 0;
}

.simple-list > a:hover {
    padding-left: 7px;
}

.simple-list strong,
.simple-list span {
    display: block;
}

.simple-list strong {
    font-size: 13px;
}

.simple-list div > span {
    margin-top: 4px;

    color: var(--text-muted);
    font-size: 10px;
}

.text-link,
.row-action {
    font-size: 11px;
    font-weight: 700;
}

.row-action {
    padding: 8px 13px;

    border: 1px solid var(--text);
    border-radius: 999px;
}

/* ------------------------------------------------ */
/* BADGES */
/* ------------------------------------------------ */

.badge {
    display: inline-flex !important;
    align-items: center;

    width: max-content;
    min-height: 24px;
    padding: 0 10px;

    color: var(--text-soft) !important;
    background: var(--surface-soft);

    border: 1px solid var(--line);
    border-radius: 999px;

    font-size: 9px !important;
    font-weight: 700;
}

/* ------------------------------------------------ */
/* FILTERS AND INPUTS */
/* ------------------------------------------------ */

.filterbar {
    display: flex;
    gap: 10px;

    margin-bottom: 22px;
}

.filterbar input {
    flex: 1;
}

.filterbar select {
    min-width: 210px;
}

input,
select,
textarea {
    width: 100%;

    padding: 13px 14px;

    color: var(--text);
    background: var(--surface);

    border: 1px solid var(--line-dark);
    border-radius: 0;

    outline: none;

    transition:
        border-color var(--transition),
        box-shadow var(--transition);
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--black);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
}

textarea {
    min-height: 130px;
    resize: vertical;
}

/* ------------------------------------------------ */
/* TABLES */
/* ------------------------------------------------ */

.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;

    border-collapse: collapse;

    font-size: 12px;
}

th {
    padding: 13px 12px;

    color: var(--text-muted);

    border-bottom: 1px solid var(--black);

    font-size: 9px;
    font-weight: 750;
    letter-spacing: 0.08em;
    text-align: left;
    text-transform: uppercase;
}

td {
    padding: 17px 12px;

    border-bottom: 1px solid var(--line);

    vertical-align: middle;
}

tbody tr {
    transition: background var(--transition);
}

tbody tr:hover {
    background: var(--surface-soft);
}

td strong,
td small {
    display: block;
}

td small {
    margin-top: 4px;

    color: var(--text-muted);
    font-size: 9px;
}

.empty-state {
    padding: 50px 25px;

    color: var(--text-muted);

    font-size: 12px;
    text-align: center;
}

/* ------------------------------------------------ */
/* PAGINATION */
/* ------------------------------------------------ */

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    padding: 24px;
}

.pagination a {
    display: grid;
    place-items: center;

    width: 38px;
    height: 38px;

    background: var(--surface);

    border: 1px solid var(--line);
    border-radius: 50%;
}

/* ------------------------------------------------ */
/* FORMS */
/* ------------------------------------------------ */

.form-card {
    max-width: 1160px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.field-wide {
    grid-column: 1 / -1;
}

.field label {
    display: block;

    margin-bottom: 8px;

    font-size: 10px;
    font-weight: 750;
}

.required,
.error,
.danger-text {
    color: var(--danger);
}

.help {
    display: block;

    margin-top: 6px;

    color: var(--text-muted);

    font-size: 9px;
    line-height: 1.45;
}

.form-actions {
    display: flex;
    gap: 10px;

    padding-top: 14px;
}

/* ------------------------------------------------ */
/* MESSAGES */
/* ------------------------------------------------ */

.messages {
    display: grid;
    gap: 8px;

    margin-bottom: 18px;
}

.message {
    padding: 14px 16px;

    background: var(--surface);

    border: 1px solid var(--line);
    border-left: 4px solid var(--black);
    border-radius: 0;

    font-size: 11px;
}

.message.success,
.success-box {
    color: var(--success);
    background: var(--success-background);
    border-color: #b7e5c1;
}

.message.error,
.error-box {
    color: var(--danger);
    background: var(--danger-background);
    border-color: #f1bdb8;
}

.error-box,
.success-box,
.notice {
    padding: 15px;

    font-size: 11px;
    line-height: 1.5;
}

.notice {
    margin-bottom: 18px;

    background: var(--surface-blue);
    border-left: 4px solid var(--black);
}

/* ------------------------------------------------ */
/* DATA LIST */
/* ------------------------------------------------ */

.data-list {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);

    margin: 16px 0 0;
}

.data-list dt,
.data-list dd {
    margin: 0;
    padding: 13px 0;

    border-bottom: 1px solid var(--line);

    font-size: 11px;
}

.data-list dt {
    color: var(--text-muted);
}

.data-list dd {
    font-weight: 650;
}

/* ------------------------------------------------ */
/* CODE */
/* ------------------------------------------------ */

.json-view {
    max-height: 400px;
    overflow: auto;

    padding: 16px;

    color: #e7e9e5;
    background: var(--black);

    border: 0;
    border-radius: 0;

    font-size: 10px;
    line-height: 1.6;

    white-space: pre-wrap;
    word-break: break-word;
}

.variable-code,
code {
    font-family:
        ui-monospace,
        SFMono-Regular,
        Menlo,
        Monaco,
        Consolas,
        monospace;
}

.variable-code {
    padding: 6px 8px;

    color: var(--white);
    background: var(--black);

    border-radius: 4px;

    font-size: 9px;
}

/* ------------------------------------------------ */
/* ENTITY LIST */
/* ------------------------------------------------ */

.entity-list {
    display: grid;
}

.entity-row {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 15px 0;

    border-top: 1px solid var(--line);
}

.entity-row:first-child {
    border-top: 0;
}

.entity-row div {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 9px;
    align-items: center;
}

.entity-row a {
    grid-column: 2;

    color: var(--text-muted);
    font-size: 10px;
}

.code-pill {
    grid-row: 1 / 3;

    padding: 5px 7px;

    background: var(--surface-soft);

    border: 1px solid var(--line);
    border-radius: 4px;

    font:
        10px ui-monospace,
        SFMono-Regular,
        Menlo,
        monospace;
}

/* ------------------------------------------------ */
/* TEMPLATE CARDS */
/* ------------------------------------------------ */

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

    background: var(--line);
    border: 1px solid var(--line);
}

.template-card {
    display: grid;
    grid-template-columns: 62px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;

    min-height: 120px;
    padding: 20px;

    background: var(--surface);

    border: 0;
    border-radius: 0;

    transition:
        background var(--transition),
        transform var(--transition);
}

.template-card:hover {
    background: var(--surface-soft);
    box-shadow: none;
    transform: none;
}

.file-icon {
    display: grid;
    place-items: center;

    height: 62px;

    color: var(--white);
    background: var(--black);

    border-radius: 0;

    font-size: 10px;
    font-weight: 800;
}

.template-card h2 {
    margin: 7px 0 5px;

    font-size: 17px;
}

.template-card small {
    color: var(--text-muted);
    font-size: 9px;
}

.arrow {
    font-size: 24px;
}

/* ------------------------------------------------ */
/* VARIABLES */
/* ------------------------------------------------ */

.variable-chip-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;

    background: var(--line);
    border: 1px solid var(--line);
}

.variable-chip {
    padding: 15px;

    background: var(--surface);

    border: 0;
    border-radius: 0;
}

.variable-chip code,
.variable-chip span {
    display: block;
}

.variable-chip code {
    overflow: hidden;

    font-size: 10px;
    text-overflow: ellipsis;
}

.variable-chip span {
    margin-top: 7px;

    color: var(--success);
    font-size: 8px;
}

/* ------------------------------------------------ */
/* PREVIEW */
/* ------------------------------------------------ */

.preview-card iframe {
    width: 100%;
    height: 720px;

    background: #e5e6e3;

    border: 1px solid var(--line);
    border-radius: 0;
}

/* ------------------------------------------------ */
/* LOGIN */
/* ------------------------------------------------ */

.login-page {
    min-height: 100vh;

    display: grid;
    place-items: center;

    padding: 30px;

    background: var(--gradient);
}

.login-card {
    width: min(460px, 100%);

    padding: 38px;

    background: rgba(255, 255, 255, 0.94);

    border: 1px solid rgba(0, 0, 0, 0.13);
    border-radius: 0;

    box-shadow: none;

    backdrop-filter: blur(18px);
}

.login-brand {
    padding-bottom: 12px;
    color: var(--text);
}

.login-card h1 {
    margin: 22px 0 8px;

    font-size: 38px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: -0.05em;
}

.muted {
    color: var(--text-muted) !important;
}

.form-stack p {
    margin: 16px 0;
}

.form-stack label {
    display: block;

    margin-bottom: 7px;

    font-size: 10px;
    font-weight: 750;
}

/* ------------------------------------------------ */
/* TABLET */
/* ------------------------------------------------ */

@media (max-width: 1100px) {

    :root {
        --sidebar-width: 84px;
    }

    .sidebar {
        width: var(--sidebar-width);
        padding-inline: 12px;
    }

    .brand {
        justify-content: center;
        width: 100%;
    }

    .brand-content,
    .sidebar .nav-link span:not(.nav-icon),
    .nav-section,
    .sidebar-user-info {
        display: none;
    }

    .nav-link {
        justify-content: center;
        padding-inline: 0;
    }

    .nav-link::before {
        left: -12px;
    }

    .sidebar-user {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .dashboard-grid,
    .two-columns,
    .detail-grid,
    .case-columns {
        grid-template-columns: 1fr;
    }
}

/* ------------------------------------------------ */
/* MOBILE */
/* ------------------------------------------------ */

@media (max-width: 760px) {

    .app-shell {
        display: block;
    }

    .sidebar {
        position: sticky;
        top: 0;

        width: 100%;
        height: auto;

        padding: 10px 14px;

        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .sidebar-top {
        margin: 0;
    }

    .brand {
        justify-content: flex-start;
        width: auto;
    }

    .brand-mark {
        width: 38px;
        height: 38px;
    }

    .brand-content {
        display: block;
    }

    .mobile-menu-button {
        display: block;
    }

    .sidebar-navigation {
        display: none;

        max-height: calc(100vh - 140px);
        padding-top: 15px;
    }

    .sidebar.is-open .sidebar-navigation {
        display: block;
    }

    .sidebar .nav-link span:not(.nav-icon),
    .nav-section {
        display: inline;
    }

    .nav-link {
        justify-content: flex-start;
        padding-inline: 13px;
    }

    .nav-link::before {
        left: 0;
    }

    .sidebar-user {
        display: none;
    }

    .content {
        grid-column: auto;
    }

    .topbar {
        min-height: auto;
    }

    .topbar-content {
        min-height: 96px;
        padding: 20px 16px;
    }

    .top-actions {
        display: none;
    }

    .content-inner {
        padding: 22px 14px 50px;
    }

    .page-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 18px;

        padding-bottom: 22px;
    }

    .page-heading h1 {
        font-size: 42px;
    }

    .page-heading > p {
        max-width: none;
        text-align: left;
    }

    .stats-grid,
    .template-grid,
    .variable-chip-grid,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-grid,
    .two-columns,
    .detail-grid,
    .case-columns {
        gap: 14px;
    }

    .card {
        padding: 18px;
    }

    .filterbar {
        flex-direction: column;
    }

    .filterbar select {
        min-width: 0;
    }

    .data-list {
        grid-template-columns: 1fr;
    }

    .data-list dt {
        padding-bottom: 3px;
        border-bottom: 0;
    }

    .data-list dd {
        padding-top: 3px;
    }

    .preview-card iframe {
        height: 520px;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions .button {
        width: 100%;
    }

    .login-page {
        padding: 15px;
    }

    .login-card {
        padding: 26px 20px;
    }
}
















.object-filterbar {
    display: grid;
    grid-template-columns:
        minmax(240px, 2fr)
        minmax(160px, 1fr)
        minmax(180px, 1fr)
        minmax(180px, 1fr)
        auto
        auto;
    align-items: center;
}

.object-filterbar input,
.object-filterbar select {
    min-width: 0;
}

@media (max-width: 1250px) {
    .object-filterbar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .object-filterbar input {
        grid-column: 1 / -1;
    }
}

@media (max-width: 760px) {
    .object-filterbar {
        display: grid;
        grid-template-columns: 1fr;
    }

    .object-filterbar input {
        grid-column: auto;
    }

    .object-filterbar .button {
        width: 100%;
    }
}