/* Form Container */
.form-container {
    background-color: #ffffff;
    border-radius: 15px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    margin: 2rem auto;
    max-width: 600px;
    padding: 2rem;
}

.form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.form-header h2 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

/* Form Controls */
.form-floating {
    position: relative;
}

.form-floating>label {
    padding: 1rem 0.75rem;
    opacity: 0.65;
    transform-origin: 0 0;
    transition: opacity .1s ease-in-out, transform .1s ease-in-out;
}

.form-floating--active>label {
    opacity: 0.65;
    transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
    background-color: white;
    height: auto;
    padding: 0 0.5rem;
    margin-left: 0.5rem;
    margin-top: -0.5rem;
}

.form-floating>.select2-container {
    height: calc(3.5rem + 2px) !important;
}

.form-floating>.select2-container .select2-selection {
    height: calc(3.5rem + 2px) !important;
    padding: 1rem 0.75rem !important;
    border-radius: 0.375rem;
    border: 1px solid #ced4da;
    background-color: #fff;
}

.form-floating>.select2-container .select2-selection__rendered {
    padding: 0 !important;
    line-height: 1.5 !important;
    height: 1.5rem !important;
    margin-top: 0.25rem;
    color: #212529;
}

.form-floating>.select2-container .select2-selection__arrow {
    height: 100% !important;
    top: 0 !important;
}

.form-floating>.select2-container .select2-selection__placeholder {
    color: transparent;
}

.form-control,
.form-select {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 1rem 0.75rem;
    transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 0 0.25rem rgba(76, 175, 80, 0.25);
}

/* Submit Button */
.btn-primary {
    background-color: #4CAF50;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    padding: 1rem;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: #388E3C;
    transform: translateY(-2px);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Custom Footer Styles */
footer {
    background-color: #1a1a1a !important;
}

.social-icons a:hover {
    color: #4CAF50 !important;
    transition: color 0.3s ease;
}

/* Custom Navbar Styles */
.navbar {
    background-color: #1a1a1a !important;
}

.navbar-brand {
    font-weight: bold;
    color: #4CAF50 !important;
}

.nav-link:hover {
    color: #4CAF50 !important;
}

.dropdown-menu {
    background-color: #2d2d2d;
    border: 1px solid #3d3d3d;
}

.dropdown-item {
    color: #f0f0f0;
}

.dropdown-item:hover {
    background-color: #3d3d3d;
    color: #4CAF50;
}

/* Form Validation Styles */
.was-validated .form-control:invalid,
.form-control.is-invalid {
    border-color: #dc3545;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.was-validated .form-control:valid,
.form-control.is-valid {
    border-color: #198754;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23198754' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

/* Result Page Styles */
.result-container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.result-card {
    background-color: #ffffff;
    border-radius: 15px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.result-header {
    text-align: center;
    margin-bottom: 2rem;
}

.result-header h2 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.system-specs {
    background-color: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.spec-item {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.spec-item:last-child {
    margin-bottom: 0;
}

.spec-item i {
    font-size: 1.2rem;
    width: 30px;
    color: #4CAF50;
}

.spec-label {
    font-weight: 600;
    margin-right: 0.5rem;
    color: #6c757d;
}

.performance-result {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
}

.result-icon {
    font-size: 2.5rem;
    margin-right: 1.5rem;
}

.result-details h3 {
    margin-bottom: 0.5rem;
    font-weight: 600;
}

/* Performance levels */
.performance-high {
    background-color: #e8f5e9;
    color: #2e7d32;
}

.performance-good {
    background-color: #e3f2fd;
    color: #1565c0;
}

.performance-medium {
    background-color: #fff3e0;
    color: #ef6c00;
}

.performance-low {
    background-color: #ffebee;
    color: #c62828;
}

.performance-unknown {
    background-color: #f5f5f5;
    color: #757575;
}

/* Performance Gauge */
.performance-gauge {
    margin-bottom: 2rem;
}

.gauge-label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.gauge-bar {
    height: 10px;
    background-color: #e9ecef;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 0.5rem;
    position: relative;
}

.gauge-fill {
    height: 100%;
    width: 0;
    position: absolute;
    left: 0;
    top: 0;
    transition: width 1.5s ease-out;
}

/* Performance level specific styles */
.performance-high .gauge-fill,
div.gauge-fill.performance-high {
    background-color: #2e7d32;
    width: 100%;
}

.performance-good .gauge-fill,
div.gauge-fill.performance-good {
    background-color: #1565c0;
    width: 75%;
}

.performance-medium .gauge-fill,
div.gauge-fill.performance-medium {
    background-color: #ef6c00;
    width: 50%;
}

.performance-low .gauge-fill,
div.gauge-fill.performance-low {
    background-color: #c62828;
    width: 25%;
}

.gauge-markers {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: #6c757d;
    padding: 0 2px;
}

.result-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.result-actions .btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
}

/* Print styles */
@media print {

    .navbar,
    .footer {
        display: none;
    }

    .result-container {
        margin: 0;
        padding: 0;
    }

    .result-card {
        box-shadow: none;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .result-container {
        margin: 1rem;
    }

    .result-card {
        padding: 1.5rem;
    }

    .performance-result {
        flex-direction: column;
        text-align: center;
    }

    .result-icon {
        margin: 0 0 1rem 0;
    }

    .result-actions {
        flex-direction: column;
    }

    .result-actions .btn {
        width: 100%;
    }
}

/* Select2 Custom Styles */
.select2-container--bootstrap-5 .select2-selection {
    min-height: calc(3.5rem + 2px) !important;
}

.select2-container--bootstrap-5 .select2-dropdown {
    border-color: #4CAF50;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    margin-top: 2px;
}

.select2-container--bootstrap-5 .select2-results__option--highlighted[aria-selected] {
    background-color: #4CAF50 !important;
    color: #fff;
}

.select2-container--bootstrap-5.select2-container--focus .select2-selection,
.select2-container--bootstrap-5.select2-container--open .select2-selection {
    border-color: #4CAF50 !important;
    box-shadow: 0 0 0 0.25rem rgba(76, 175, 80, 0.25) !important;
}

/* Fix for dropdown search box */
.select2-container--bootstrap-5 .select2-search--dropdown .select2-search__field {
    padding: 0.5rem;
    border-radius: 0.25rem;
    border: 1px solid #ced4da;
}

.select2-container--bootstrap-5 .select2-search--dropdown .select2-search__field:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 0 0.25rem rgba(76, 175, 80, 0.25);
    outline: none;
}