/* Core-Web Admin 3.0 - Native iOS/macOS Design System */
/* Code DNA: Obsidian Deep, Copper Accents, Apple Squircle */


:root {
    /* --- 1. Color System (Obsidian Deep) --- */
    /* Bases */
    --system-background: #0D0F0F;
    /* Obsidian Deep */
    --system-secondary-background: #1C1C1E;
    /* Secondary grouping */
    --system-tertiary-background: #2C2C2E;
    /* Search bars, inputs */

    /* Text */
    --label-primary: #FFFFFF;
    /* High Emphasis */
    --label-secondary: rgba(255, 255, 255, 0.70);
    /* Improved Medium Emphasis */
    --label-tertiary: rgba(255, 255, 255, 0.40);
    /* Improved Low Emphasis */

    /* Separators */
    --separator: rgba(84, 84, 88, 0.65);
    /* Opaque separator */
    --separator-non-opaque: rgba(84, 84, 88, 0.36);
    /* Translucent separator */

    /* Tints / Brand */
    --tint-accent: #B87333;
    /* Copper (Primary Action) */
    --tint-active: #C6A87C;
    /* Sand/Honey (Active State) */
    --tint-destructive: #FF453A;
    /* iOS Red */
    --tint-success: #30D158;
    /* iOS Green */

    /* Materials (Liquid Glass) */
    /* Base for glass elements */
    --glass-background: rgba(13, 15, 15, 0.70);
    --glass-filter: blur(20px) saturate(180%);

    /* --- 2. Typography (San Francisco) --- */
    --font-stack: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", sans-serif;

    /* Hierarchy */
    --font-large-title: 34px;
    --font-title-1: 28px;
    --font-title-2: 22px;
    --font-headline: 17px;
    /* Semibold */
    --font-body: 17px;
    /* Regular */
    --font-caption-1: 12px;

    /* Weights */
    --weight-regular: 400;
    --weight-semibold: 600;
    --weight-bold: 700;

    /* --- 3. Geometry (Apple Squircle) --- */
    --radius-container: 22px;
    --radius-button: 12px;
    --radius-small: 8px;

    /* --- 4. Layout Dimensions --- */
    --sidebar-width: 260px;
    --sidebar-collapsed-width: 68px;
    --master-width: 375px;
    /* iOS iPhone Width Standard per Code DNA */
    --toolbar-height: 52px;

    /* Responsive adjustments */
    --content-padding: 64px;
}

@media (max-width: 1440px) {
    :root {
        --sidebar-width: 240px;
        --content-padding: 40px;
    }
}

@media (max-width: 1200px) {
    :root {
        --sidebar-width: 220px;
        --content-padding: 32px;
    }
}

/* --- Reset & Base --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

[data-theme="light"] {
    --system-background: #F2F2F7;
    --system-secondary-background: #FFFFFF;
    --system-tertiary-background: #E5E5EA;
    --label-primary: #000000;
    --label-secondary: rgba(60, 60, 67, 0.60);
    --label-tertiary: rgba(60, 60, 67, 0.30);
    --separator: rgba(60, 60, 67, 0.36);
    --separator-non-opaque: rgba(60, 60, 67, 0.12);
    --glass-background: rgba(255, 255, 255, 0.70);
}

[data-theme="light"] .sidebar-header img {
    filter: brightness(0);
    opacity: 0.85;
}

[data-theme="light"] .nav-item:hover {
    background: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .user-profile {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .bento-cell:hover {
    background: #F9F9F9;
}

[data-theme="light"] .action-btn {
    background: #FFFFFF;
}

[data-theme="light"] .action-btn:hover {
    background: #F2F2F7;
}

body {
    background-color: var(--system-background);
    color: var(--label-primary);
    font-family: var(--font-stack);
    font-size: var(--font-body);
    line-height: 1.4;
    height: 100vh;
    overflow: hidden;
    display: flex;
    user-select: none;
    /* App-like feel */
}

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

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

/* --- Component: Sidebar (Liquid Glass) --- */
.app-sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--system-secondary-background);
    border-right: 0.5px solid var(--separator-non-opaque);
    display: flex;
    flex-direction: column;
    z-index: 100;
    flex-shrink: 0;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.app-sidebar.collapsed {
    width: var(--sidebar-collapsed-width);
}

.sidebar-header {
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.sidebar-header img {
    height: 32px;
    width: auto;
    filter: brightness(0) invert(1);
    transition: opacity 0.2s;
}

.app-sidebar.collapsed .sidebar-header {
    padding: 0;
    justify-content: center;
}

.app-sidebar.collapsed .sidebar-header img {
    display: none;
}

.sidebar-toggle {
    background: transparent;
    border: none;
    color: var(--label-tertiary);
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--label-primary);
}

.sidebar-toggle svg {
    width: 20px;
    height: 20px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.app-sidebar.collapsed #sidebar-toggle svg {
    transform: rotate(180deg);
}

/* Theme Toggle Button Style */
.theme-toggle-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 0.5px solid var(--separator-non-opaque);
    color: var(--label-secondary);
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(10px);
}

.theme-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--label-primary);
    transform: translateY(-1px);
}

[data-theme="light"] .theme-toggle-btn {
    background: rgba(0, 0, 0, 0.05);
    color: var(--label-secondary);
}

[data-theme="light"] .theme-toggle-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    color: var(--label-primary);
}


/* Sidebar Footer */
.sidebar-footer {
    margin-top: auto;
    padding: 12px 10px;
    border-top: 0.5px solid var(--separator-non-opaque);
}


.app-sidebar nav {
    flex: 1;
    padding: 0 12px;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    margin-bottom: 4px;
    border-radius: 10px;
    color: var(--label-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    text-wrap: nowrap;
    overflow: hidden;
}

.app-sidebar.collapsed .nav-item {
    justify-content: center;
    padding: 10px 0;
}

.app-sidebar.collapsed .nav-item span {
    display: none;
}

.app-sidebar.collapsed .sf-icon {
    margin-right: 0;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--label-primary);
}

.nav-item.active {
    background: var(--tint-accent);
    color: #FFFFFF;
    box-shadow: 0 4px 12px rgba(184, 115, 51, 0.3);
}


/* Hide text in collapsed items if needed but usually better to just clip */
.nav-item {
    white-space: nowrap;
    overflow: hidden;
}

.sidebar-label {
    padding: 24px 12px 8px 12px;
    font-size: 11px;
    font-weight: 700;
    color: var(--label-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: opacity 0.2s;
}

.app-sidebar.collapsed .sidebar-label {
    opacity: 0;
}




/* sf symbols (svg sizing) */
.sf-icon {
    width: 20px;
    height: 20px;
    margin-right: 14px;
    fill: currentColor;
    display: block;
    flex-shrink: 0;
}

/* User Profile Chip (Bottom of Sidebar) */
.user-profile {
    margin: 12px;
    margin-top: auto;
    padding: 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 12px;
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s;
}

.app-sidebar.collapsed .user-profile {
    padding: 12px 0;
    justify-content: center;
    background: transparent;
    border-color: transparent;
}

.app-sidebar.collapsed .user-info {
    display: none;
}


.user-profile:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--tint-accent), var(--tint-active));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    color: white;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    flex-shrink: 0;
}

.user-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--label-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-role {
    font-size: 10px;
    color: var(--label-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* User List Table */
.user-table {
    width: 100%;
    border-collapse: collapse;
}

.user-table th {
    text-align: left;
    padding: 12px 16px;
    font-size: 12px;
    font-weight: 700;
    color: var(--label-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 0.5px solid var(--separator-non-opaque);
}

.user-table td {
    padding: 16px;
    border-bottom: 0.5px solid var(--separator-non-opaque);
}

.user-row:hover {
    background: rgba(255, 255, 255, 0.02);
}

.role-badge {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.role-admin {
    background: rgba(184, 115, 51, 0.15);
    color: var(--tint-accent);
}

.role-editor {
    background: rgba(94, 92, 230, 0.15);
    color: #5E5CE6;
}

.role-viewer {
    background: rgba(255, 255, 255, 0.1);
    color: var(--label-secondary);
}

/* --- Component: Split View Container --- */
.split-view {
    display: flex;
    flex: 1;
    height: 100vh;
    overflow: hidden;
    width: 100%;
}

/* --- Component: Master List (Mail Style) --- */
.col-master {
    width: var(--master-width);
    min-width: 320px;
    max-width: 1000px;
    background: var(--system-background);
    border-right: 1px solid var(--separator-non-opaque);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    position: relative;
    transition: width 0.1s;
    /* Smooth resize */
}

.resize-handle {
    position: absolute;
    right: -8px;
    /* Stick out more */
    top: 0;
    bottom: 0;
    width: 16px;
    /* Double width for easier grabbing */
    cursor: col-resize;
    z-index: 1000;
    /* Higher Z-index */
}

.resize-handle:hover {
    background: rgba(184, 115, 51, 0.1);
    /* Hint on hover */
}

/* --- Component: Empty States --- */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    padding: 48px;
    color: var(--label-tertiary);
}

.empty-state-icon {
    width: 64px !important;
    height: 64px !important;
    min-width: 64px;
    min-height: 64px;
    max-width: 64px;
    max-height: 64px;
    margin-bottom: 24px;
    opacity: 0.25;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
}

.empty-state-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--label-secondary);
    letter-spacing: -0.01em;
}

.master-toolbar {
    height: var(--toolbar-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    background: var(--system-background);
    /* No bottom border on toolbar, part of scrollable area feels usually */
}

/* iOS Search Bar */
.search-container {
    padding: 8px 16px 16px 16px;
    /* 8pt grid */
    background: var(--system-background);
}

.ios-search-bar {
    background: var(--system-tertiary-background);
    border-radius: 10px;
    border: none;
    padding: 10px 12px 10px 36px;
    width: 100%;
    color: var(--label-primary);
    font-size: 16px;
    outline: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%238e8e93' viewBox='0 0 16 16'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001c.03.04.062.078.098.115l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1.007 1.007 0 0 0-.115-.1zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 12px center;
    transition: background 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.ios-search-bar:focus {
    background: rgba(255, 255, 255, 0.12);
}

/* --- Component: Segmented Control (Filter Tabs) --- */
.filter-tabs {
    display: flex;
    background: rgba(118, 118, 128, 0.24);
    border-radius: 8px;
    padding: 2px;
    margin-top: 12px;
    gap: 2px;
}

.filter-tab {
    flex: 1;
    border: none;
    background: transparent;
    color: var(--label-secondary);
    font-size: 13px;
    font-weight: 500;
    padding: 6px 0;
    border-radius: 7px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.filter-tab.active {
    background: #636366;
    color: var(--label-primary);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.filter-tab:hover:not(.active) {
    color: var(--label-primary);
}

.master-scroll {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

/* Mail Style Cell */
.object-cell {
    padding: 16px 24px;
    /* Generous padding (Anti-Excel) */
    border-bottom: 0.5px solid var(--separator-non-opaque);
    background: var(--system-background);
    cursor: pointer;
    transition: background 0.2s;
}

.object-cell:active,
.object-cell.selected {
    background: var(--system-secondary-background);
    /* Subtle selection highlight */
    border-left: 4px solid var(--tint-accent);
    /* Copper indicator */
}

.cell-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
}

.cell-title {
    font-size: 17px;
    font-weight: var(--weight-semibold);
    color: var(--label-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: normal;
    line-height: 1.3;
    margin-bottom: 4px;
}

.cell-date {
    font-size: 15px;
    color: var(--label-secondary);
}

.cell-subtitle {
    font-size: 15px;
    color: var(--label-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
}

/* --- Component: Details Area (Pages Style) --- */
.col-detail {
    flex: 1;
    background: var(--system-background);
    /* Deepest black for canvas */
    display: flex;
    flex-direction: column;
    position: relative;
    min-width: 0;
}

.detail-toolbar {
    height: var(--toolbar-height);
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--glass-background);
    backdrop-filter: var(--glass-filter);
    -webkit-backdrop-filter: var(--glass-filter);
    position: sticky;
    top: 0;
    z-index: 50;
}

.col-detail {
    flex: 1;
    background-color: var(--system-background);
    display: flex;
    flex-direction: column;
    position: relative;
    min-width: 0;
    overflow: hidden;
}

.detail-canvas {
    flex: 1;
    overflow-y: auto;
    padding: var(--content-padding);
    width: 100%;
    /* No margin auto here to keep it attached to toolbar width */
}

.post-title-input {
    font-size: 40px;
    /* Larger title */
    font-weight: var(--weight-bold);
    background: transparent;
    border: none;
    color: var(--label-primary);
    width: 100%;
    margin-bottom: 32px;
    outline: none;
    letter-spacing: -0.01em;
}

.post-title-input::placeholder {
    color: var(--label-tertiary);
}

/* Buttons (Squircle 12px) */
.btn-text {
    background: none;
    border: none;
    color: var(--tint-accent);
    font-size: 16px;
    cursor: pointer;
    font-weight: var(--weight-regular);
    padding: 8px 16px;
    border-radius: var(--radius-button);
}

.btn-text:hover {
    background: rgba(184, 115, 51, 0.1);
}

.btn-icon {
    background: none;
    border: none;
    color: var(--label-secondary);
    padding: 8px;
    border-radius: var(--radius-button);
    cursor: pointer;
}

.btn-icon:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--label-primary);
}

.btn-icon.active {
    background: rgba(184, 115, 51, 0.2);
    color: var(--tint-accent);
}

.btn-primary {
    background: var(--tint-accent);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(184, 115, 51, 0.3);
}

.btn-primary:hover {
    background: var(--tint-active);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(184, 115, 51, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

/* --- Component: Inspector Drawer (Numbers Style) --- */
.col-inspector {
    width: 280px;
    /* Tighter inspector */
    background: var(--system-secondary-background);
    border-left: 0.5px solid var(--separator-non-opaque);
    display: none;
    flex-direction: column;
    overflow-y: auto;
}

.col-inspector.visible {
    display: flex;
    animation: slideInRight 0.25s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.inspector-header {
    padding: 16px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--label-secondary);
    letter-spacing: 0.05em;
}

/* Grouped Form Cells (Inset Tables) */
.form-group {
    background: var(--system-tertiary-background);
    margin: 0 16px 24px 16px;
    border-radius: 12px;
    /* iOS Grouped Inset */
    overflow: hidden;
}

.form-cell {
    padding: 12px 16px;
    border-bottom: 0.5px solid var(--separator-non-opaque);
    display: flex;
    flex-direction: column;
}

.form-cell:last-child {
    border-bottom: none;
}

.form-label {
    font-size: 12px;
    color: var(--label-secondary);
    margin-bottom: 4px;
}

.form-input,
.form-select {
    background: transparent;
    border: none;
    color: var(--label-primary);
    font-size: 16px;
    width: 100%;
    outline: none;
}

/* Semantic Stats Grid (Dashboard) */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.stat-card {
    background: var(--system-secondary-background);
    border-radius: var(--radius-container);
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.stat-value {
    font-size: 40px;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--label-primary);
    margin: 8px 0;
}

.stat-label {
    font-size: 13px;
    text-transform: uppercase;
    color: var(--label-secondary);
    font-weight: 600;
}

/* Animations */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        width: 0;
        opacity: 0;
    }

    to {
        transform: translateX(0);
        width: 280px;
        opacity: 1;
    }
}

/* --- Component: Modals (Liquid Glass) --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    animation: fadeIn 0.2s ease-out;
}

.modal-content {
    background: var(--system-secondary-background);
    width: 100%;
    max-width: 440px;
    border-radius: 20px;
    padding: 24px;
    border: 0.5px solid var(--separator-non-opaque);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    animation: scaleUp 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.modal-header h2 {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes scaleUp {
    from {
        transform: scale(0.9) translateY(10px);
        opacity: 0;
    }

    to {
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

/* --- Component: Quill Editor (Canvas Integration) --- */
.ql-container.ql-snow {
    border: none !important;
    font-family: var(--font-stack) !important;
    font-size: 17px !important;
}

.ql-editor {
    padding: 0 !important;
    color: var(--label-primary) !important;
    line-height: 1.6 !important;
}

/* Placeholder Styling (The fix for invisible text) */
.ql-editor.ql-blank::before {
    color: var(--label-tertiary) !important;
    font-style: normal !important;
    opacity: 0.8;
    left: 0 !important;
}

.ql-toolbar.ql-snow {
    border: none !important;
    padding: 8px 0 !important;
    margin-bottom: 16px;
    border-bottom: 0.5px solid var(--separator-non-opaque) !important;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

/* Toolbar Buttons */
.ql-snow .ql-stroke {
    stroke: var(--label-secondary) !important;
}

.ql-snow .ql-fill {
    fill: var(--label-secondary) !important;
}

.ql-snow .ql-picker {
    color: var(--label-secondary) !important;
}

.ql-snow .ql-picker-options {
    background-color: var(--system-secondary-background) !important;
    border: 0.5px solid var(--separator) !important;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* --- Mobile Responsiveness (Vertical Stack) --- */
@media (max-width: 768px) {
    .split-view {
        flex-direction: column;
        height: auto;
        /* Allow scrolling body */
        overflow: auto;
    }

    /* 1. Sidebar becomes top navigation */
    .app-sidebar {
        width: 100%;
        height: auto;
        position: relative;
        border-right: none;
        border-bottom: 1px solid var(--separator-non-opaque);
        padding: 12px;
        background: var(--system-secondary-background);
        transform: none !important;
        backdrop-filter: none;
    }

    .sidebar-header {
        height: 40px;
        margin-bottom: 12px;
    }

    .app-sidebar nav {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }

    .app-sidebar .nav-item {
        margin-bottom: 0;
        font-size: 13px;
        padding: 6px 10px;
        background: var(--system-tertiary-background);
    }

    .app-sidebar .sf-icon {
        margin-right: 6px;
        width: 16px;
        height: 16px;
    }

    /* Hide some sidebar elements to save space */
    .app-sidebar div[style*="text-transform: uppercase"] {
        display: none;
    }

    .app-sidebar div[style*="margin-top: auto"] {
        margin-top: 0;
    }

    /* 2. Master List */
    .col-master {
        width: 100% !important;
        min-width: 0;
        max-width: none;
        height: auto;
        border-right: none;
        flex: none;
        display: block;
    }

    .master-scroll {
        max-height: 300px;
    }

    /* 3. Detail View */
    .col-detail {
        width: 100%;
        height: auto;
        border-left: none;
        flex: none;
        overflow: visible;
        position: relative;
        transform: none !important;
    }

    .detail-toolbar {
        position: sticky;
        top: 0;
        padding: 0 16px;
        background: var(--system-background);
        border-bottom: 0.5px solid var(--separator-non-opaque);
    }

    .detail-canvas {
        padding: 16px;
    }

    .resize-handle {
        display: none;
    }

    /* Stack Inspector */
    .col-inspector {
        position: relative;
        width: 100%;
        border-left: none;
        border-top: 1px solid var(--separator);
        transform: none;
        display: none;
    }

    .col-inspector.visible {
        display: flex;
        animation: none;
    }
}