/*
 * Sensor Size Button - Style v7 (Border Added)
 * ================================================
 * This version adds a border to the main button wrapper for visual consistency.
 */

/* Main container for positioning */
#sensor-size-main-container {
    position: absolute;
    right: 20px;
    bottom: 240px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    height: 45px;
}

/* The static wrapper for the button */
#sensor-size-wrapper {
    position: relative;
    width: 45px;
    height: 45px;
    background-color: #2a2a2a;
    border-radius: 50%;
    border: 1px solid #444;
    /* Added for visual consistency */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    flex-shrink: 0;
    transition: background-color 0.2s ease-in-out;
    box-sizing: border-box;
    /* Ensure border is included in the size */
}

/* --- HOVER EFFECT for the background --- */
#sensor-size-wrapper:hover {
    background-color: #3a3a3a;
    /* Slightly lighter on hover */
}

/* The main button is a transparent clickable area */
#sensor-size-button {
    width: 100%;
    height: 100%;
    background-color: transparent;
    border-radius: 50%;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Icon style */
#sensor-size-button .app-icon {
    transform: scale(1.2);
}

/* The expanding container for the options */
#sensor-size-options-container {
    position: absolute;
    right: 0;
    top: 0;
    height: 45px;
    background-color: #2a2a2a;
    border-radius: 22.5px;
    display: flex;
    align-items: center;
    width: 45px;
    opacity: 0;
    transition: width 0.4s cubic-bezier(0.25, 0.8, 0.25, 1),
        opacity 0.2s ease;
    overflow: hidden;
    z-index: 10;
}

/* Expanded state for the options container */
#sensor-size-options-container.expanded {
    width: 280px;
    opacity: 1;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Wrapper for the content inside the expanding container */
.sensor-content-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 0 50px 0 10px;
    box-sizing: border-box;
}

/* The adaptive moving indicator */
#sensor-selected {
    position: absolute;
    top: 5px;
    left: 0;
    height: 35px;
    background-color: #555;
    border-radius: 17.5px;
    transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1),
        width 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    will-change: transform, width;
}

/* Sensor option text styles */
.sensor-option {
    position: relative;
    color: white;
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    padding: 0 8px;
    opacity: 0;
    transition: opacity 0.3s ease 0.2s;
}

/* When expanded, the options become visible */
#sensor-size-options-container.expanded .sensor-option {
    opacity: 1;
}

/* Mobile Vertical Centering */
@media (hover: none) and (pointer: coarse) {
    #sensor-size-main-container {
        bottom: calc(50% + 7.5px);
    }
}