/* Vest view specific styles - all scoped to #vest-view */

#vest-view .app-container {
    min-height: 100%;
    background: transparent;
    padding-bottom: 40px;
}

/* Header */
#vest-view .header {
    padding: 12px 15px;
    padding-top: 70px;
    border-bottom: 1px solid #222;
}

#vest-view .title-section {
    text-align: center;
}

#vest-view .pin-logo {
    font-size: 28px;
    margin-bottom: 6px;
}

#vest-view h1 {
    font-size: 24px;
    letter-spacing: 3px;
    margin-bottom: 4px;
}

#vest-view .subtitle {
    color: #888;
    font-size: 12px;
}

/* Band Dropdown - Top Center */
#vest-view .band-dropdown-container {
    max-width: 400px;
    margin: 0 auto 15px auto;
    position: relative;
}

#vest-view .band-dropdown-header {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    padding: 10px 15px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
}

#vest-view .band-dropdown-header:hover {
    background: #2a2a2a;
    border-color: #00ccff;
}

#vest-view .dropdown-label {
    font-size: 12px;
    font-weight: bold;
    color: #fff;
}

#vest-view .dropdown-arrow {
    font-size: 10px;
    color: #888;
    transition: transform 0.2s;
}

#vest-view .band-dropdown-header.open .dropdown-arrow {
    transform: rotate(180deg);
}

#vest-view .band-dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 5px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
}

#vest-view .band-dropdown-list.hidden {
    display: none;
}

/* Main Content */
#vest-view .main-content {
    display: flex;
    gap: 15px;
    padding: 15px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Vest Container */
#vest-view .vest-container {
    flex: 1;
    position: relative;
    background: #0a0a0a;
    border: 1px solid #222;
    border-radius: 8px;
    padding: 15px;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#vest-view .vest-image {
    max-width: 100%;
    max-height: 800px;
    object-fit: contain;
    position: relative;
    z-index: 1;
    pointer-events: none;
}

#vest-view .patches-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

#vest-view .patch-item {
    position: absolute;
    cursor: move;
    pointer-events: auto;
    user-select: none;
}

#vest-view .patch-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
}

#vest-view .patch-item.selected {
    outline: 2px dashed #00ccff;
    outline-offset: 2px;
}

#vest-view .patch-item:hover:not(.selected) {
    outline: 1px solid #888;
    outline-offset: 2px;
}

/* Resize/Rotate Handles */
#vest-view .resize-handle {
    position: absolute;
    width: 12px;
    height: 12px;
    background: #00ccff;
    border: 2px solid #fff;
    border-radius: 50%;
    pointer-events: auto;
    z-index: 10;
}

#vest-view .resize-handle.nw { top: -6px; left: -6px; cursor: nw-resize; }
#vest-view .resize-handle.ne { top: -6px; right: -6px; cursor: ne-resize; }
#vest-view .resize-handle.sw { bottom: -6px; left: -6px; cursor: sw-resize; }
#vest-view .resize-handle.se { bottom: -6px; right: -6px; cursor: se-resize; }

#vest-view .rotate-handle {
    position: absolute;
    width: 16px;
    height: 16px;
    background: #ff4444;
    border: 2px solid #fff;
    border-radius: 50%;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    cursor: grab;
    pointer-events: auto;
    z-index: 10;
}

#vest-view .rotate-handle:active {
    cursor: grabbing;
}

#vest-view .rotate-handle::before {
    content: '';
    position: absolute;
    width: 2px;
    height: 18px;
    background: #fff;
    top: 14px;
    left: 50%;
    transform: translateX(-50%);
}

/* Sidebar */
#vest-view .sidebar {
    width: 280px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#vest-view .card {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    padding: 12px;
}

#vest-view .card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: bold;
    margin-bottom: 10px;
    font-size: 12px;
    text-transform: uppercase;
}

/* Progress Card */
#vest-view .progress-card {
    background: linear-gradient(135deg, #2a1515 0%, #1a1a1a 100%);
    border-color: #3a2020;
}

#vest-view .fire-icon {
    font-size: 16px;
}

#vest-view .progress-percent {
    font-size: 32px;
    font-weight: bold;
    text-align: center;
    margin: 5px 0;
}

#vest-view .progress-bar {
    width: 100%;
    height: 6px;
    background: #2a2a2a;
    border-radius: 3px;
    overflow: hidden;
    margin: 8px 0 6px 0;
}

#vest-view .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff4444 0%, #ff8844 100%);
    width: 0%;
    transition: width 0.5s ease;
}

#vest-view .progress-text {
    text-align: center;
    color: #888;
    font-size: 10px;
}

/* Controls Card */
#vest-view .controls-card {
    background: #1a1a1a;
}

#vest-view .gear-icon {
    font-size: 14px;
}

#vest-view .control-group {
    margin-bottom: 12px;
}

#vest-view .control-group:last-of-type {
    margin-bottom: 10px;
}

#vest-view .control-group label {
    display: block;
    font-size: 10px;
    font-weight: bold;
    color: #888;
    margin-bottom: 6px;
}

#vest-view .slider-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

#vest-view .slider-container input[type="range"] {
    flex: 1;
    -webkit-appearance: none;
    height: 4px;
    background: #2a2a2a;
    border-radius: 2px;
    outline: none;
}

#vest-view .slider-container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    background: #00ccff;
    border-radius: 50%;
    cursor: pointer;
}

#vest-view .slider-container input[type="range"]::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: #00ccff;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

#vest-view .slider-container span {
    min-width: 35px;
    text-align: right;
    color: #00ccff;
    font-size: 12px;
    font-weight: bold;
}

#vest-view .remove-btn {
    width: 100%;
    padding: 8px;
    background: #3a1515;
    color: #ff6666;
    border: 1px solid #4a2020;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 12px;
    transition: all 0.3s;
}

#vest-view .remove-btn:hover {
    background: #4a2020;
    border-color: #5a2525;
}

/* Patches Grid in Dropdown */
#vest-view .patches-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

#vest-view .patch-list-item {
    padding: 12px 15px;
    background: #0a0a0a;
    border-bottom: 1px solid #2a2a2a;
    cursor: grab;
    transition: all 0.2s;
    font-size: 14px;
    font-weight: 500;
    color: #fff;
    user-select: none;
}

#vest-view .patch-list-item:first-child {
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
}

#vest-view .patch-list-item:last-child {
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
    border-bottom: none;
}

#vest-view .patch-list-item:hover {
    background: #1a1a1a;
    color: #00ccff;
    padding-left: 20px;
}

#vest-view .patch-list-item.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

#vest-view .patch-list-item:active {
    cursor: grabbing;
}

/* Actions */
#vest-view .actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

#vest-view .toggle-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    cursor: pointer;
}

#vest-view .toggle-slider {
    position: relative;
    width: 42px;
    height: 22px;
    background: #2a2a2a;
    border-radius: 11px;
    transition: background 0.3s;
}

#vest-view .toggle-slider::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    background: #666;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: all 0.3s;
}

#vest-view input[type="checkbox"] {
    display: none;
}

#vest-view input[type="checkbox"]:checked + .toggle-slider {
    background: #ff6600;
}

#vest-view input[type="checkbox"]:checked + .toggle-slider::before {
    left: 22px;
    background: #fff;
}

#vest-view .toggle-label {
    flex: 1;
}

#vest-view .toggle-label strong {
    display: block;
    font-size: 11px;
    margin-bottom: 1px;
}

#vest-view .toggle-label span {
    font-size: 9px;
    color: #888;
}

#vest-view .save-btn {
    padding: 10px;
    background: linear-gradient(135deg, #006600 0%, #008800 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 13px;
    transition: all 0.3s;
}

#vest-view .save-btn:hover {
    background: linear-gradient(135deg, #007700 0%, #009900 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 136, 0, 0.3);
}

#vest-view .reset-btn {
    padding: 8px;
    background: #2a2a2a;
    color: #ffaa00;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 12px;
    transition: all 0.3s;
}

#vest-view .reset-btn:hover {
    background: #3a3a3a;
    border-color: #4a4a4a;
}

/* Responsive */
@media (max-width: 1024px) {
    #vest-view .main-content {
        flex-direction: column;
    }

    #vest-view .sidebar {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
    }

    #vest-view .sidebar .card {
        flex: 1;
        min-width: 280px;
    }

    #vest-view .vest-column .patches-card {
        max-width: 600px;
        max-height: 250px;
    }
}

@media (max-width: 768px) {
    #vest-view h1 {
        font-size: 24px;
    }

    #vest-view .vest-container {
        min-height: 400px;
    }

    #vest-view .vest-column .patches-card {
        max-width: 100%;
        max-height: 200px;
    }

    #vest-view .sidebar {
        flex-direction: column;
    }
}

/* Scrollbar for vest view */
#vest-view ::-webkit-scrollbar {
    width: 8px;
}

#vest-view ::-webkit-scrollbar-track {
    background: #1a1a1a;
}

#vest-view ::-webkit-scrollbar-thumb {
    background: #3a3a3a;
    border-radius: 4px;
}

#vest-view ::-webkit-scrollbar-thumb:hover {
    background: #4a4a4a;
}
