/* Component Styles - Matches Page Source bg-clr-1 */
.joint-filler-visualizer {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #28303D;
}

.joint-filler-visualizer .sidebar {
    background-color: #fdb82e !important;
    min-height: 100vh;
}

.section-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: #28303D;
}

/* Colors Container - The white box in AI image */
.colors-container {
    background: #fff;
    border-radius: 12px;
    padding: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.joint-wrap .colors {
    gap: 8px;
    justify-content: flex-start;
}

.joint-wrap .colors li {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    background-color: var(--bgClr);
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.joint-wrap .colors li:hover {
    transform: scale(1.15);
}

.joint-wrap .colors li.active {
    box-shadow: 0 0 0 2px #28303D;
}

/* Filter Sections */
.filter-sections {
    background: transparent;
}

.filter-section {
    padding: 15px 0;
}

.border-bottom-dashed {
    border-bottom: 1px dashed rgba(40, 48, 61, 0.15);
}

.radio-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.radio-list .form-check-label {
    font-size: 0.9rem;
    color: #28303D;
    font-weight: 500;
}

.radio-list .form-check-input:checked {
    background-color: #28303D;
    border-color: #28303D;
}

/* Upload Box - AI style */
.upload-dashed-box {
    border: 1px dashed #28303D;
    border-radius: 12px;
    padding: 12px 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.1);
}

#fileNameDisplay {
    font-size: 0.85rem;
    color: #28303D;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 120px;
}

.btn-upload-trigger {
    background: #fff;
    border: 1px solid #28303D;
    border-radius: 8px;
    padding: 5px 12px;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-upload-trigger:hover {
    background: #28303D;
    color: #fff;
}

/* Right Viewport */
.viewport-column {
    background: #fff;
    overflow: hidden;
}

.color-status-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #fff;
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 20;
    color: #28303D;
}

.room-wrapper-outer {
    width: 100%;
    height: 100%;
}

.room-wrapper {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 600px;
    perspective: 1500px;
    overflow: hidden;
}

.tile-block {
    position: absolute;
    inset: 0% 3.9%;
    /* Further expansion for high-angle perspective */
    background-color: #D2B189;
    display: flex;
    flex-wrap: wrap;
    align-content: flex-start;
    justify-content: center;
    overflow: hidden;
    transition: transform 0.5s ease;
    transform-origin: center;
    z-index: 1;
}

.room-wrapper:not(.room-wall-surface) .tile-block {
    transform: rotateX(60deg);
}

.tile-block .tile {
    width: 100px;
    height: 100px;
    margin: 0.5px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: all 0.3s;
}

.room-pic {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 5;
    pointer-events: none;
    mix-blend-mode: multiply;
    /* This allows floor details/shadows to overlap the tiles naturally */
}

/* Cropper Overlay */
#upload-image-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.95);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cropper-content {
    background: #fff;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    text-align: center;
}

.cropper-actions {
    margin-top: 20px;
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* Shape modifiers */
.joint-filler-visualizer .room-wrapper.rectangle .tile {
    width: 200px !important;
    height: 100px !important;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .joint-filler-visualizer .sidebar {
        min-height: auto;
    }
}