/* --- BWG ENTERPRISE DESIGNER THEME --- */
body {
    background-color: #0A0F0C;
    color: white;
    margin: 0;
}

*, *::before, *::after {
    box-sizing: border-box;
}

/* LEFT PANE: TOOLBOX */
.toolbox-pane {
    width: 260px;
    background-color: #0D1610;
    border-right: 1px solid #1E3028;
    padding: 20px;
    overflow-y: auto;
}

    .toolbox-pane h4 {
        color: #2E7D52;
        font-weight: bold;
        font-size: 14px;
        letter-spacing: 2px;
        text-transform: uppercase;
    }

    .toolbox-pane hr {
        border-color: #1E3028;
    }

.tool-btn {
    display: block;
    width: 100%;
    text-align: left;
    padding: 12px 15px;
    margin-bottom: 8px;
    background-color: #162210;
    color: #E0E0E0;
    border: 1px solid #2E7D52;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s ease-in-out;
}

    .tool-btn:hover {
        background-color: #2E7D52;
        color: white;
    }

/* MIDDLE PANE: CANVAS */
.canvas-pane {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    padding: 30px;
    background-color: #0A0F0C;
    overflow-y: auto;
}

.canvas-header {
    margin-bottom: 20px;
}

.title-input {
    font-weight: bold;
    color: white;
    background-color: transparent;
    border: none;
    border-bottom: 2px solid #2E7D52;
    border-radius: 0;
    font-size: 28px;
    padding-left: 0;
}

    .title-input:focus {
        background-color: transparent;
        color: white;
        box-shadow: none;
        border-bottom: 2px solid #4CAF50;
    }

.canvas-body {
    flex-grow: 1;
    background-color: #0D1610;
    border: 1px solid #1E3028;
    padding: 24px;
    border-radius: 8px;
}

.canvas-element {
    padding: 16px;
    border: 1px solid #1E3028;
    margin-bottom: 12px;
    background-color: #162210;
    color: white;
    cursor: pointer;
    border-radius: 6px;
    transition: border 0.2s;
}

    .canvas-element.selected {
        border: 2px solid #90CAF9; /* Light blue selection highlight */
        background-color: #1A291E;
    }

.empty-state {
    text-align: center;
    color: #4A6B5A;
    margin-top: 50px;
    font-style: italic;
    font-weight: bold;
}

/* RIGHT PANE: PROPERTIES */
.properties-pane {
    width: 320px;
    background-color: #0D1610;
    border-left: 1px solid #1E3028;
    padding: 20px;
    overflow-y: auto;
}

    .properties-pane h4 {
        color: #90CAF9;
        font-weight: bold;
        font-size: 14px;
        letter-spacing: 2px;
        text-transform: uppercase;
    }

    .properties-pane hr {
        border-color: #1E3028;
    }

    .properties-pane .form-label {
        color: #A0A0A0;
        font-size: 12px;
        font-weight: bold;
        text-transform: uppercase;
        margin-bottom: 4px;
    }

    .properties-pane .form-control,
    .properties-pane .form-select {
        background-color: #162210;
        border: 1px solid #2E7D52;
        color: white;
    }

        .properties-pane .form-control:focus,
        .properties-pane .form-select:focus {
            background-color: #1A291E;
            border-color: #90CAF9;
            color: white;
            box-shadow: none;
        }
/* --- RESET & BASE --- */
body {
    background-color: #0A0F0C;
    color: white;
    margin: 0;
}

*, *::before, *::after {
    box-sizing: border-box;
}

/* --- LAYOUT --- */
.page {
    display: flex;
    min-height: 100vh;
    background-color: #0A0F0C;
}

main {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    background-color: #0A0F0C;
    overflow: hidden;
}

.content {
    flex-grow: 1;
    padding: 0;
    background-color: #0A0F0C;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

/* --- SIDEBAR SHELL --- */
/* The .sidebar div in MainLayout just provides the left column.
   Its actual width is driven by .sidebar-inner's collapsed/expanded state. */
.sidebar {
    background-color: #0D1610;
    border-right: 1px solid #1E3028;
    position: relative;
    flex-shrink: 0;
    overflow: visible;
    /* Width matches the inner collapsed width by default */
    width: 56px;
    transition: width 0.25s ease;
}

    /* When sidebar-inner is expanded, push the shell width too */
    .sidebar:has(.sidebar-expanded) {
        width: 220px;
    }

.sidebar-inner {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 100;
    background-color: #0D1610;
    border-right: 1px solid #1E3028;
    transition: width 0.25s ease;
}

.sidebar-collapsed {
    width: 56px;
}

.sidebar-expanded {
    width: 220px;
}

/* Hide labels when collapsed */
.sidebar-collapsed .nav-label,
.sidebar-collapsed .brand-text,
.sidebar-collapsed .nav-section-label,
.sidebar-collapsed .nav-footer-label {
    opacity: 0;
    width: 0;
    overflow: hidden;
    white-space: nowrap;
}

/* Center icons when collapsed */
.sidebar-collapsed .nav-item {
    justify-content: center;
    padding: 14px 0;
}

.sidebar-collapsed .sidebar-brand {
    justify-content: center;
    padding: 14px 0;
}

/* --- BRAND --- */
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px;
    border-bottom: 1px solid #1E3028;
    white-space: nowrap;
}

.brand-dot {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: #162210;
    border: 1px solid #2E7D52;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    color: #2E7D52;
    flex-shrink: 0;
}

.brand-text {
    font-size: 13px;
    font-weight: bold;
    color: #E0E0E0;
    transition: opacity 0.2s, width 0.2s;
}

/* --- NAV ITEMS --- */
.nav-section-label {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #2E7D52;
    padding: 14px 16px 6px;
    white-space: nowrap;
    transition: opacity 0.2s, width 0.2s;
}

.nav-item-wrap {
    position: relative;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    color: #A0A0A0;
    font-size: 13px;
    text-decoration: none;
    border-left: 2px solid transparent;
    transition: background 0.15s, color 0.15s;
    cursor: pointer;
    width: 100%;
    white-space: nowrap;
}

    .nav-item:hover {
        background: #162210;
        color: #E0E0E0;
    }

    .nav-item.active {
        background: #162210;
        color: #90CAF9;
        border-left-color: #90CAF9;
    }

.nav-icon {
    font-size: 15px;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.nav-label {
    transition: opacity 0.2s, width 0.2s;
}

.nav-spacer {
    flex: 1;
}

.nav-footer-label {
    padding: 12px 16px;
    border-top: 1px solid #1E3028;
    font-size: 11px;
    color: #2E7D52;
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
    transition: opacity 0.2s, width 0.2s;
}

/* --- HOVER POPUP --- */
.nav-popup {
    position: absolute;
    left: 228px;
    width: 260px;
    background: #1A1F1C;
    border: 1px solid #2E3A30;
    border-radius: 10px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
    z-index: 999;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
}

    .nav-popup.show {
        opacity: 1;
        pointer-events: all;
    }

.popup-screenshot {
    width: 100%;
    height: 130px;
    object-fit: cover;
    object-position: top;
    display: block;
    border-bottom: 1px solid #2A3028;
}

.popup-body {
    padding: 14px 16px 16px;
}

.popup-title {
    font-size: 14px;
    font-weight: bold;
    color: #F0F0F0;
    margin-bottom: 6px;
}

.popup-desc {
    font-size: 12px;
    color: #A0A0A0;
    line-height: 1.65;
    margin-bottom: 12px;
}

.popup-link {
    font-size: 12px;
    color: #2E7D52;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.15s;
}

    .popup-link:hover {
        color: #4CAF50;
    }

/* --- DESIGNER PAGE --- */
.designer-container {
    display: flex;
    flex: 1;
    height: calc(100vh - 60px); /* subtract footer height */
    background-color: #0A0F0C;
    border-top: 2px solid #1E3028;
    overflow: hidden;
}

/* --- BRAND --- */
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px;
    border-bottom: 1px solid #1E3028;
}

.brand-dot {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: #162210;
    border: 1px solid #2E7D52;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    color: #2E7D52;
    flex-shrink: 0;
}

.brand-text {
    font-size: 13px;
    font-weight: bold;
    color: #E0E0E0;
}

/* --- NAV LABELS & ITEMS --- */
.nav-section-label {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #2E7D52;
    padding: 14px 16px 6px;
}

.nav-item-wrap {
    position: relative;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    color: #A0A0A0;
    font-size: 13px;
    text-decoration: none;
    border-left: 2px solid transparent;
    transition: background 0.15s, color 0.15s;
    cursor: pointer;
    width: 100%;
}

/* Force transparent background everywhere in sidebar */
.sidebar-inner a,
.sidebar-inner a:visited,
.sidebar-inner a:focus {
    background-color: transparent;
    color: #A0A0A0;
    text-decoration: none;
    outline: none;
    box-shadow: none;
}

.nav-item:hover {
    background: #162210;
    color: #E0E0E0;
}

.nav-item.active {
    background: #162210;
    color: #90CAF9;
    border-left-color: #90CAF9;
}

/* Kill any Bootstrap focus ring on nav links */
.sidebar-inner .nav-item:focus-visible {
    outline: none;
    box-shadow: none;
}

.nav-icon {
    font-size: 15px;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.nav-label {
    white-space: nowrap;
}

.nav-spacer {
    flex: 1;
}

.nav-footer-label {
    padding: 12px 16px;
    border-top: 1px solid #1E3028;
    font-size: 11px;
    color: #2E7D52;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* --- HOVER POPUP --- */
.nav-popup {
    position: fixed;
    width: 260px;
    background: #1A1F1C;
    border: 1px solid #2E3A30;
    border-radius: 10px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
    z-index: 9999;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
}

    .nav-popup.show {
        opacity: 1;
        pointer-events: all;
    }

.popup-screenshot {
    width: 100%;
    height: 130px;
    object-fit: cover;
    object-position: top;
    display: block;
    border-bottom: 1px solid #2A3028;
}

.popup-body {
    padding: 14px 16px 16px;
}

.popup-title {
    font-size: 14px;
    font-weight: bold;
    color: #F0F0F0;
    margin-bottom: 6px;
}

.popup-desc {
    font-size: 12px;
    color: #A0A0A0;
    line-height: 1.65;
    margin-bottom: 12px;
}

.popup-link {
    font-size: 12px;
    color: #2E7D52;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.15s;
}

    .popup-link:hover {
        color: #4CAF50;
    }

/* --- HOME HERO --- */
.home-hero {
    position: relative;
    flex: 1; /* stretch to fill remaining space in main */
    min-height: 0; /* allow flex shrink so footer stays visible */
    overflow: hidden;
    background: #0A0F0C;
}

.home-hero-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 40%;
    filter: brightness(0.28) saturate(0.7);
}

.home-hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, #0A0F0C 28%, transparent 65%), linear-gradient(to top, #0A0F0C 12%, transparent 55%);
}

.home-hero-content {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 48px;
}

.home-eyebrow {
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #2E7D52;
    margin-bottom: 14px;
}

.home-h1 {
    font-size: 38px;
    font-weight: bold;
    color: #F0F0F0;
    margin-bottom: 0;
    line-height: 1.15;
}

.home-divider {
    width: 40px;
    height: 2px;
    background: #2E7D52;
    margin: 20px 0;
}

.home-sub {
    font-size: 15px;
    color: #7A9A8A;
    max-width: 380px;
    line-height: 1.65;
    margin: 0;
}

/* --- FOOTER --- */
.omnis-footer {
    background-color: #0D1610;
    border-top: 1px solid #1E3028;
    padding: 15px 30px;
    margin-top: auto;
}

.footer-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.footer-logo {
    height: 50px;
    border-radius: 4px;
}

.footer-text p {
    margin: 0;
    line-height: 1.4;
}

.developed-by {
    color: #90CAF9;
    font-weight: bold;
    font-size: 14px;
}

.client-warning {
    color: #A0A0A0;
    font-size: 12px;
    font-style: italic;
}

/* --- APPROVALS PAGE --- */
.approvals-header h2 {
    color: white;
    font-weight: bold;
    margin-top: 20px;
}

.header-divider {
    border-color: #2E7D52;
    border-width: 2px;
    opacity: 1;
    margin-bottom: 30px;
}
/* --- FORM MANAGEMENT CONSOLE --- */
.console-header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    margin-bottom: 30px;
}

.console-title-group {
    display: flex;
    flex-direction: column;
}

.console-title {
    color: white;
    font-weight: bold;
    margin: 0;
    font-size: 28px;
}

.console-subtitle {
    color: #A0A0A0;
    font-size: 12px;
    letter-spacing: 2px;
}

.btn-create-new {
    background-color: #D32F2F;
    color: white;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.2s;
}

    .btn-create-new:hover {
        background-color: #B71C1C;
        color: white;
    }

.console-tabs {
    display: flex;
    gap: 24px;
    margin-bottom: 30px;
    border-bottom: 1px solid #1E3028;
    padding-bottom: 15px;
    align-items: baseline;
}

.tab-active {
    color: #4CAF50;
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 1px;
}

.tab-inactive {
    color: #6c757d;
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 1px;
}

.tab-hint {
    color: #888;
    font-size: 12px;
    font-style: italic;
    margin-left: 20px;
}

.section-divider {
    color: #2E7D52;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: 1px;
    margin-bottom: 20px;
}

    .section-divider.mt-4 {
        color: #6c757d;
        margin-top: 40px;
    }

.forms-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.form-card {
    background-color: #162210;
    border: 2px solid;
    border-radius: 8px;
    padding: 20px;
    width: 320px;
    display: flex;
    flex-direction: column;
}

.active-card {
    border-color: #2E7D52;
}

.retired-card {
    border-color: #333;
    background-color: #111;
    opacity: 0.8;
}

.form-card-category {
    font-size: 10px;
    color: #4CAF50;
    letter-spacing: 1px;
    font-weight: bold;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.retired-card .form-card-category {
    color: #6c757d;
}

.form-card-title {
    color: white;
    font-weight: bold;
    font-size: 18px;
    margin: 0 0 10px 0;
}

.retired-card .form-card-title {
    color: #A0A0A0;
}

.form-card-status {
    color: #4CAF50;
    font-size: 12px;
    font-weight: bold;
    margin-bottom: 20px;
}

.status-retired {
    color: #6c757d;
}

.form-card-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.btn-card-edit, .btn-card-retire, .btn-card-activate {
    flex: 1;
    padding: 8px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 13px;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
    transition: all 0.2s;
    background: transparent;
}

.btn-card-edit {
    color: white;
    border-color: #555;
}

    .btn-card-edit:hover {
        background-color: #222;
        color: white;
    }

.btn-card-retire {
    color: white;
    border-color: #555;
}

    .btn-card-retire:hover {
        background-color: #333;
        color: white;
    }

.btn-card-activate {
    color: #4CAF50;
    border-color: #4CAF50;
}

    .btn-card-activate:hover {
        background-color: #4CAF50;
        color: white;
    }