/**
 * PC Bouwer Frontend Styles
 * VERSION: 3.1.11 - Bronze Gaming Theme (FPS Settings Highlight Fix)
 * 
 * FIXES & IMPROVEMENTS:
 * - ✅ Toegevoegd specifieke highlight voor FPS settings knoppen
 * - ✅ Verbeterde z-index en focus styling voor actieve knoppen
 * - ✅ Behoudt alle bestaande stijlen
 */

/* Fonts */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@500;700&family=Roboto:wght@400;500;700&display=swap');

/* Global Resets & Base */
.pc-bouwer-configurator,
.pc-bouwer-configurator * {
    font-family: 'Roboto', sans-serif;
    box-sizing: border-box;
}

.pc-bouwer-configurator {
    width: 100%;
    margin: 0 auto;
    padding: 2rem;
    background-color: #0d0d0d;
    color: #f2f2f2;
}

/* Step Visibility */
.pb-step {
    display: none;
}

.pb-step.active {
    display: block;
}

/* Progress Bar */
.pb-progress-container {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 2px solid #333;
}

.pb-progress-bar {
    height: 8px;
    background-color: #333;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.pb-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #cd7f32, #ffcc80);
    transition: width 0.3s ease;
}

.pb-progress-steps {
    display: flex;
    justify-content: space-between;
}

.pb-progress-step {
    color: #666;
    font-size: 0.9rem;
}

.pb-progress-step.active {
    color: #cd7f32;
    font-weight: 700;
}

/* Step 1: Game Selection */
.pb-step-games {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 2rem;
    border: 2px solid #333;
}

.pb-step-games h2 {
    color: #cd7f32;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.pb-game-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.pb-game-category {
    background-color: #0d0d0d;
    border: 2px solid #333;
    border-radius: 8px;
    padding: 1.5rem;
}

.pb-category-title {
    color: #cd7f32;
    font-size: 1.2rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #333;
    padding-bottom: 0.5rem;
}

.pb-game-checkbox {
    display: block;
    padding: 0.8rem;
    margin-bottom: 0.5rem;
    background-color: #1a1a1a;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
}

.pb-game-checkbox:hover {
    background-color: #222;
    border-left: 3px solid #cd7f32;
    padding-left: 1rem;
}

.pb-game-checkbox input[type="checkbox"] {
    margin-right: 0.8rem;
    cursor: pointer;
    width: 18px;
    height: 18px;
}

.pb-game-checkbox label {
    cursor: pointer;
    color: #f2f2f2;
}

.pb-game-checkbox input[type="checkbox"]:checked ~ * {
    color: #cd7f32;
    font-weight: 500;
}

/* Step 2: Unified Controls */
.pb-step-results {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 2rem;
    border: 2px solid #333;
}

.pb-step-results > h2 {
    color: #cd7f32;
    font-size: 2rem;
    text-align: center;
    margin-bottom: 0.5rem;
}

.pb-step-results > p {
    text-align: center;
    color: #888;
    margin-bottom: 2rem;
}

/* Unified Controls Block */
.pb-unified-controls {
    margin: 0 auto 2rem;
    background: linear-gradient(135deg, #1a1a1a, #0d0d0d);
    border: 2px solid #cd7f32;
    border-radius: 10px;
    padding: 2rem;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

/* Budget Section */
.pb-budget-filter-section {
    border-right: 2px solid #333;
    padding-right: 2rem;
}

.pb-budget-filter-section h3 {
    color: #cd7f32;
    font-size: 1.2rem;
    margin: 0 0 0.5rem 0;
}

.pb-budget-filter-section > p {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.pb-budget-value {
    color: #ffcc80;
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
}

/* Budget Sliders */
.pb-budget-sliders {
    position: relative;
    height: 50px;
    margin: 0 1rem 0.8rem 1rem;
}

.pb-range-track {
    position: absolute;
    width: 100%;
    height: 8px;
    background: linear-gradient(90deg, #333 0%, #cd7f32 0%, #cd7f32 100%, #333 100%);
    border-radius: 5px;
    transform: translateY(-50%);
    top: 50%;
    pointer-events: none;
    z-index: 1;
}

.pb-range-min,
.pb-range-max {
    position: absolute;
    width: 100%;
    height: 8px;
    background: transparent;
    border-radius: 5px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    transform: translateY(-50%);
    top: 50%;
    pointer-events: none;
    z-index: 2;
}

.pb-range-min::-webkit-slider-thumb,
.pb-range-max::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: #cd7f32;
    cursor: pointer;
    border-radius: 50%;
    border: 3px solid #0d0d0d;
    box-shadow: 0 0 10px rgba(205, 127, 50, 0.6);
    pointer-events: all;
    z-index: 10;
    position: relative;
    top: 0; /* Zorgt ervoor dat de thumb op de track ligt */
}

.pb-range-min::-moz-range-thumb,
.pb-range-max::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: #cd7f32;
    cursor: pointer;
    border-radius: 50%;
    border: 3px solid #0d0d0d;
    box-shadow: 0 0 10px rgba(205, 127, 50, 0.6);
    pointer-events: all;
    z-index: 10;
    position: relative;
    top: 0; /* Zorgt ervoor dat de thumb op de track ligt */
}

.pb-budget-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: #888;
}

/* Resolution Section */
.pb-resolution-section {
    border-right: 2px solid #333;
    padding-right: 2rem;
}

.pb-resolution-section h3 {
    color: #cd7f32;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.pb-resolution-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pb-resolution-btn {
    background-color: #0d0d0d;
    border: 2px solid #333;
    color: #f2f2f2;
    padding: 0.6rem 1rem;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
}

.pb-resolution-btn.active {
    border-color: #cd7f32;
    color: #cd7f32;
    background-color: rgba(205, 127, 50, 0.1);
}

/* Settings Section */
.pb-settings-section h3 {
    color: #cd7f32;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.pb-settings-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pb-setting-btn {
    background-color: #1a1a1a;
    border: 2px solid #333;
    color: #f2f2f2;
    padding: 0.8rem 1.2rem;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    white-space: nowrap;
    position: relative;
    z-index: 1;
}

.pb-setting-btn:hover {
    border-color: #cd7f32;
    transform: scale(1.05);
}

.pb-setting-btn.active {
    border-color: #cd7f32;
    color: #cd7f32;
    background-color: rgba(205, 127, 50, 0.1);
    transform: scale(1.05);
    z-index: 2;
}

/* Results Grid */
.pb-results-container {
    padding: 0 2rem;
}

.pb-config-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    max-width: 100%;
}

@media (min-width: 1200px) {
    .pb-config-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.pb-config-card {
    background-color: #0d0d0d;
    border: 2px solid #333;
    border-radius: 10px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    transition: all 0.3s;
    position: relative;
}

.pb-config-card:hover {
    border-color: #cd7f32;
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
}

.pb-config-card.stretch-deal {
    border-top: 4px solid #ff6b6b;
}

/* Config Header */
.pb-config-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.pb-config-title h3 {
    color: #cd7f32;
    font-size: 1.3rem;
    margin: 0;
}

.pb-config-price {
    color: #ffcc80;
    font-size: 1.5rem;
    font-weight: 700;
}

/* Specs */
.pb-config-specs {
    margin-bottom: 1rem;
    padding: 1.2rem;
    background-color: #1a1a1a;
    border-radius: 5px;
}

/* FPS Preview */
.pb-fps-preview {
    background-color: #1a1a1a;
    border-radius: 5px;
    padding: 1.2rem;
    margin-bottom: 1rem;
    min-height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.pb-fps-preview-header {
    color: #cd7f32;
    font-size: 1rem;
    margin-bottom: 0.8rem;
    text-align: center;
    word-wrap: break-word;
}

.pb-fps-preview-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pb-fps-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.pb-fps-game-name {
    color: #f2f2f2;
    font-weight: 500;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 60%;
}

.pb-fps-values {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-weight: 700;
    flex: 0 0 auto;
    min-width: 120px;
}

.pb-fps-native {
    color: #888;
}

.pb-fps-arrow {
    color: #cd7f32;
}

.pb-fps-upscaled {
    color: #00ff41;
}

/* Pro/Con List */
.pb-pro-con-list {
    margin: 1rem 0;
    padding: 1rem;
    background: #1a1a1a;
    border-radius: 8px;
    border-left: 3px solid #333;
}

.pb-pro-item,
.pb-con-item {
    font-size: 0.9rem;
    padding-left: 1.5rem;
    position: relative;
    line-height: 1.3;
    margin-bottom: 0.5rem;
}

.pb-pro-item {
    color: #00ff41;
}

.pb-con-item {
    color: #ffa500;
}

.pb-pro-item::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #00ff41;
    font-weight: 700;
}

.pb-con-item::before {
    content: "!";
    position: absolute;
    left: 0;
    color: #ffa500;
    font-weight: 700;
}

/* Badges */
.pb-config-badges {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 1rem 0;
}

.pb-badge {
    background-color: #0d0d0d;
    border: 1px solid #cd7f32;
    color: #cd7f32;
    padding: 0.3rem 0.7rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
}

.pb-badge-cores {
    border-color: #00d9ff;
    color: #00d9ff;
}

.pb-badge-x3d {
    border-color: #ff6600;
    color: #ff6600;
}

.pb-badge-resolution {
    border-color: #00ff41;
    color: #00ff41;
}

/* CTA Buttons */
.pb-config-cta {
    display: flex;
    gap: 0.8rem;
    margin-top: auto;
    padding-top: 1rem;
}

.pb-btn-cta {
    flex: 1;
    padding: 0.7rem 0.8rem;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    font-size: 0.85rem;
}

.pb-btn-cta-primary {
    background: linear-gradient(135deg, #cd7f32, #ffcc80);
    color: #0d0d0d;
}

.pb-btn-cta-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(205, 127, 50, 0.5);
}

.pb-btn-cta-secondary {
    background-color: transparent;
    border: 2px solid #cd7f32;
    color: #cd7f32;
}

.pb-btn-cta-secondary:hover {
    background-color: #cd7f32;
    color: #0d0d0d;
}

/* FPS Modal */
.pb-fps-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
}

.pb-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
}

.pb-modal-content {
    position: relative;
    background-color: #1a1a1a;
    border: 2px solid #cd7f32;
    border-radius: 10px;
    width: 90%;
    max-width: 1200px;
    max-height: 90vh;
    margin: 2rem auto;
    overflow: hidden;
    z-index: 10001;
}

.pb-modal-header {
    background-color: #0d0d0d;
    border-bottom: 2px solid #cd7f32;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.pb-modal-header h2 {
    color: #cd7f32;
    font-size: 1.5rem;
    margin: 0;
}

.pb-modal-close {
    background: none;
    border: none;
    color: #cd7f32;
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.pb-modal-close:hover {
    color: #ffcc80;
    transform: rotate(90deg);
}

.pb-modal-body {
    padding: 1.5rem;
    max-height: calc(90vh - 100px);
    overflow-y: auto;
}

.fps-game-section {
    margin-bottom: 2rem;
}

.fps-game-title {
    color: #cd7f32;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.pb-fps-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
    table-layout: auto;
}

.pb-fps-table th,
.pb-fps-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #333;
    color: #f2f2f2;
    word-wrap: break-word;
    min-width: 150px;
}

.pb-fps-table thead {
    background-color: #0d0d0d;
    border-bottom: 2px solid #cd7f32;
}

.pb-fps-table th {
    color: #cd7f32;
    font-weight: 700;
}

.pb-fps-table tr:hover {
    background-color: #222;
}

.pb-fps-table tr.current-resolution {
    background-color: rgba(205, 127, 50, 0.1);
}

.pb-fps-table td.pb-fps-placeholder {
    text-align: center;
    vertical-align: middle;
}

.pb-fps-table td.pb-fps-placeholder div {
    display: inline-block;
    width: 100%;
    padding: 8px;
}

/* Loading States */
.pb-loading {
    text-align: center;
    padding: 3rem;
}

.pb-spinner {
    border: 4px solid #333;
    border-top: 4px solid #cd7f32;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

.pb-spinner-small {
    border: 3px solid #333;
    border-top: 3px solid #cd7f32;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 0 auto 0.5rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Navigation Buttons */
.pb-navigation {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.pb-btn-next,
.pb-btn-prev,
.pb-btn-restart {
    padding: 1rem 2.5rem;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    font-size: 1rem;
}

.pb-btn-next {
    background: linear-gradient(135deg, #cd7f32, #ffcc80);
    color: #0d0d0d;
}

.pb-btn-next:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(205, 127, 50, 0.5);
}

.pb-btn-next:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pb-btn-prev,
.pb-btn-restart {
    background-color: transparent;
    border: 2px solid #cd7f32;
    color: #cd7f32;
}

.pb-btn-prev:hover,
.pb-btn-restart:hover {
    background-color: #cd7f32;
    color: #0d0d0d;
}

/* Responsive */
@media (max-width: 1200px) {
    .pb-unified-controls {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .pb-resolution-buttons,
    .pb-settings-buttons {
        flex-direction: row;
    }
    
    .pb-budget-filter-section {
        border-right: none;
        padding-right: 0;
    }
    
    .pb-resolution-section {
        border-right: none;
        padding-right: 0;
    }
}

@media (max-width: 768px) {
    .pc-bouwer-configurator {
        padding: 1rem;
    }
    
    .pb-config-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .pb-config-cta {
        flex-direction: column;
    }
    
    .pb-modal-content {
        margin: 1rem;
        width: 95%;
        max-width: none;
    }
    
    .pb-game-categories {
        grid-template-columns: 1fr;
    }
    
    .pb-fps-preview {
        padding: 1rem;
    }
    
    .pb-fps-table th,
    .pb-fps-table td {
        padding: 0.6rem;
        font-size: 0.8rem;
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .pb-unified-controls {
        padding: 1rem;
    }
    
    .pb-budget-sliders {
        margin: 0 0.5rem 0.8rem 0.5rem;
    }
    
    .pb-resolution-buttons,
    .pb-settings-buttons {
        flex-direction: column;
    }
}