﻿.warehouse-data .header-section {
    display: flex;
    align-items: flex-start;
    gap: 0;
    background: #f8f9fa;
    padding: 24px;
    border: 1px solid lightgrey;
    border-radius: 8px;
}

.warehouse-data .header-left {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-right: 1.5rem;
/*    border-right: 1px solid #dee2e6; */}

.warehouse-data .vertical-divider {
    width: 1px;
    background: #dee2e6;
    margin: 0 24px;
    align-self: stretch;
}

.warehouse-data .header-right {
    min-width: 140px;
    width: 160px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
}

.warehouse-data .form-check-input[type="checkbox"] {
    width: 2.0em;
    height: 2.0em;
}

.warehouse-data .form-label {
    text-align: right;
    padding-left: 0;
    padding-right: 0.5rem;
    font-weight: bold;
}

.warehouse-data .form-check-input.custom-checkbox {
    margin-top: 0.25em;
    border: 1px solid grey;
}

.warehouse-data .form-check-label {
    text-align: right;
    align-self: flex-start;
    padding-top: 0.25em;
    font-weight: bold;
}

.warehouse-data .form-check {
    display: flex;
    align-items: flex-start;
}

/* Attribute Table */

.warehouse-editrecord .table td,
.warehouse-editrecord .table th {
    vertical-align: top;
}

.warehouse-editrecord #parent-warehouse-table .checkbox-col {
    width: 48px;
    text-align: center;
    vertical-align: top;
}

.warehouse-editrecord #parent-warehouse-table .parent-text-cell {
    vertical-align: top;
}

.warehouse-editrecord .table td.parent-action-col {
    width: 90px;
    text-align: center;
    vertical-align: top;
}

.warehouse-editrecord .collapse-child-warehouse-table {
    background: #f8f9fa;
    margin: 0;
    padding: 0;
    border: none;
}

.warehouse-editrecord .btn {
    width: 100%;
    max-width: 72px;
    min-width: 60px;
    min-height: 24px;
}

.warehouse-editrecord .btn-group .btn {
    padding: 0.25rem 0.5rem;
}

.warehouse-editrecord .child-action-add {
    width: 70px;
    padding: 0;
    text-align: right;
}

.warehouse-editrecord .child-action-col {
    width: 70px;
    text-align: center;
}

.warehouse-editrecord .child-action-col .btn {
    border: none;
}

.warehouse-editrecord .child-table-input {
    width: 100%;
    box-sizing: border-box;
}

.warehouse-editrecord .add-btn {
    float: right;
}

.warehouse-editrecord .pointer {
    cursor: pointer;
}

.warehouse-editrecord .parent-action-col .delete-parent-row.disabled {
    pointer-events: none;   /* Prevents click events */
    opacity: 0.5;           /* Visual indication of disabled state */
}

.warehouse-editrecord .child-table-body .child-action-col .delete-child-row.disabled {
    pointer-events: none;   /* Prevents click events */
    opacity: 0.5;           /* Visual indication of disabled state */
}

.warehouse-editrecord .btn-group-parent-table {
    display: flex;
}

    .warehouse-editrecord .btn-group-parent-table .btn {
        display: flex;
        align-items: center; /* Vertically centers the icon and text */
        justify-content: center; /* Horizontally centers them within the button */
        gap: 8px; /* Adds space between the icon and text */
        padding: 10px 15px;
        margin: 0px 2px;
    }

@media (max-width: 768px) {
    .warehouse-editrecord .header-section {
        flex-direction: column;
        gap: 1rem;
    }

    .warehouse-editrecord .header-right {
        flex: unset;
    }
}


/*
================================
    Attribute Hierarchy 
================================
*/

.warehouse-data #levels-container .levels-scroll-wrapper {
    overflow-x: auto;
    width: 100%;
}

.warehouse-data #levels-container .level-table, .level-rows {
    margin-left: 20px;
    border-left: 2px solid #eee;
    padding-left: 10px;
    min-width: 600px;
}

.warehouse-data #levels-container .level-row {
    display: grid;
    grid-template-columns: 500px 100px 120px;
    gap: 10px;
    align-items: center;
    margin-bottom: 5px;
}

.warehouse-data #levels-container .level-row input.form-control {
    width: 100%;
    min-width: 0;
    max-width: 500px;
}

.warehouse-data #levels-container .level-row button {
    width: 100px;
    min-width: 100px;
    max-width: 120px;
}

.warehouse-data #levels-container .sublevel-header {
    font-weight: bold;
    margin-top: 10px;
}

.warehouse-data #levels-container .sublevel-header .header-text {
    font-size: 1.25em;
}

.warehouse-data .btn-group-init {
    display: flex;
}

    .warehouse-data .btn-group-init .btn-outline-info {
        display: flex;
        align-items: center;        /* Vertically centers the icon and text */
        justify-content: center;    /* Horizontally centers them within the button */
        gap: 8px;                   /* Adds space between the icon and text */
        padding: 10px 15px;
        margin: 0px 2px;
        max-width: 100px;           /* Override bootstrap btn spec */
    }

#frmWarehouseEdit .form-label {
    text-align: right;
    align-self: flex-start;
    padding-top: 0.375rem; /* aligns with input */
}

#frmWarehouseEdit .form-check-input.custom-checkbox {
    height: 1.25em;
    width: 1.25em;
    margin-top: 0.50em;
}

#frmWarehouseEdit .form-check-label {
    text-align: right;
    align-self: flex-start;
    padding-top: 0.25em;
}

#frmWarehouseEdit .form-check {
    display: flex;
    align-items: flex-start;
}


/*
================================
    DISABLED ELEMENTS
================================
*/

#frmWarehouseEdit #addParentRow {
    display: none;
}

#frmWarehouseEdit .btn-group-init {
    display: none;
}

#frmWarehouseEdit .delete-parent-row {
    display: none;
}

#frmWarehouseEdit .add-child-row {
    display: none;
}

#frmWarehouseEdit .btn-attribute-value-remove {
    visibility: hidden;
}

#frmWarehouseEdit .btn-value-attribute-add {
    visibility: hidden;
}

#frmWarehouseEdit .child-action-col .delete-child-row {
    display: none;
}


