*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    color: #ffffff;
    background-color: #000;
    background-image:
        linear-gradient(
            -58deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.015) 38%,
            rgba(255, 255, 255, 0.035) 50%,
            rgba(255, 255, 255, 0.015) 62%,
            rgba(255, 255, 255, 0.02) 75%,
            rgba(255, 255, 255, 0.015) 100%
        ),
        radial-gradient(ellipse at 22% 28%, rgba(30, 45, 90, 0.18) 0%,transparent 58%),
        radial-gradient(ellipse at 78% 72%,rgba(65, 30, 65, 0.18) 0%,transparent 58%),
        linear-gradient(135deg,rgb(4, 4, 6) 0%,rgb(12, 12, 14) 50%,rgb(8, 8, 10) 100%);
    background-attachment: fixed;
}


nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #080808;
    border-bottom: 1px solid #1d1d1d;
    padding: 1rem 2rem;
}

nav > a {
    text-decoration: none;
    font-size: 20px;
    font-weight: bold;
    color: #fff;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 3rem;
    margin: 0;
    padding: 0;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

nav ul a {
    text-decoration: none;
    font-size: 18px;
    color: #fff;
    position: relative;
    display: inline-block;
    transition: color 0.4s ease;
}

nav ul a::after {
    content: "";
    position: absolute;
    bottom: -6px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #b8c0ff;
    border-radius: 2px;
    transform: translateX(-50%);
    transition:
        width 0.15s ease,
        left 0.15s ease,
        transform 0.15s ease;
}

nav ul a:hover:not(.active1) {
    color: #b8c0ff;
}

nav ul a:hover:not(.active1)::after {
    width: 50%;
}

nav ul a.active1 {
    color: #b8c0ff;
    font-weight: 600;
}

nav ul a.active1::after {
    width: 100%;
}

.sim-container{
    max-width: 1900px;
    margin: 80px auto 0;
    padding: 2rem;
    padding-top: 0;
}
.sim-header{
    margin-bottom: 2rem;
    text-align: center;
}

.sim-header h1{
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #fff, #aaa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sim-header p{
    color: #aaa;
    font-size: 1.1rem;   
}

.sim-subtitle{
    color: #888;
    font-size: 0.95rem;
    margin-top: 0.5rem;
}

.sim-layout{
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 1024px){
    .sim-layout{
        grid-template-columns: 1fr;
    }
}

.sim-controls {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    align-items: center;
}

.sim-btn{
    padding: 0.75rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 2rem;
    background: linear-gradient(135deg, rgba(80, 80, 160, 0.6), rgba(120, 60, 120, 0.6));
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.95rem;
    font-family: inherit;
}

.sim-btn:hover{
    background: linear-gradient(135deg, rgba(100, 100, 180, 0.8), rgba(140, 80, 140, 0.8));
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(100, 100, 180, 0.3);
}

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

.sim-btn:disabled{
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.sim-btn-primary{
    background: linear-gradient(135deg, rgba(100,100,200,0.7), rgba(150,80,150,0.7));
}

.sim-btn-secondary{
    background: rgba(40, 40, 40, 0.8);
}

.sim-btn-secondary:hover{
    background: rgba(60, 60, 60, 0.9);
}

.sim-stats{
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}

.sim-stat-card{
    background: rgba(20, 20, 20, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 1.25rem;
    text-align: center;
    transition: all 0.3s;
}

.sim-stat-card:hover{
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.sim-stat-value{
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.sim-stat-value.blue{ color: #6b9eff; }
.sim-stat-value.green{ color: #6bffb4; }
.sim-stat-value.purple{ color: #b56bff; }
.sim-stat-value.orange{ color: #ffb56b; }
.sim-stat-value.red{ color: #ff6b6b; }
.sim-stat-value.yellow{ color: #ffeb6b; }

.sim-stat-label{
    font-size: 0.85rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sim-sidebar{
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    min-width: 0;
    max-width: 400px;
}

.sim-panel{
    background: rgba(20, 20, 20, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: border-color 0.3s;
    overflow: hidden;
    word-wrap: break-word;
    margin-bottom: 20px;
}

.sim-panel-header{
    font-size: 1.3rem;
    margin-bottom: 1.25rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sim-panel-icon{
    font-size: 1.5rem;
}

.sim-control-group{
    margin-bottom: 1.5rem;
}

.sim-control-group:last-child{
    margin-bottom: 0;
}

.sim-control-label{
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.6rem;
    font-size: 0.9rem;
    color: #ccc;
}

.sim-control-value{
    color: #6b9eff;
    font-weight: 600;
    font-size: 1rem;
}

input[type="range"]{
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    -webkit-appearance: none;
    cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb{
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6b9eff, #a56bff);
    cursor: pointer;
    transition: all 0.2s;
}

input[type="range"]::-webkit-slider-thumb:hover{
    width: 22px;
    height: 22px;
    box-shadow: 0 0 10px rgba(107, 158, 255, 0.5);
}

input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6b9eff, #a56bff);
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

input[type="range"]::-moz-range-thumb:hover {
    width: 22px;
    height: 22px;
    box-shadow: 0 0 10px rgba(107, 158, 255, 0.5);
}

input[type="range"]:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.sim-toggle{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
}

.sim-toggle-switch{
    position: relative;
    width: 50px;
    height: 26px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 13px;
    cursor: pointer;
    transition: background 0.3s;
}

.sim-toggle-switch.active{
    background: linear-gradient(135deg, #6b9eff, #a56bff);
}

.sim-toggle-switch::after{
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: transform 0.3s;
}

.sim-toggle-switch.active::after{
    transform: translateX(24px);
}

.sim-info-list{
    list-style: none;
    font-size: 0.9rem;
    line-height: 1.8;
    color: #ccc;
    padding: 0;
    margin: 0;
}

.sim-info-list li{
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.sim-info-list li::before{
    content: "•";
    position: absolute;
    left: 0;
    color: #6b9eff;
    font-weight: bold;
    font-size: 1.2rem;
}

.sim-badge{
    display: inline-block;
    padding: 0.35rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sim-badge-easy{
    background: rgba(107, 255, 180, 0.2);
    color: #6bffb4;
    border: 1px solid rgba(107, 255, 180, 0.3);
}

.sim-badge-medium{
    background: rgba(255, 235, 107, 0.2);
    color: #ffeb6b;
    border: 1px solid rgba(255, 235, 107, 0.3);
}

.sim-badge-hard{
    background: rgba(255, 107, 107, 0.2);
    color: #ff6b6b;
    border: 1px solid rgba(255, 107, 107, 0.3);
}

.sim-divider{
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 1.5rem 0;
}

.sim-formula{
    background: rgba(10, 10, 40, 0.6);
    border-left: 2px solid #6b9eff;
    padding: 1rem 1.25rem;
    border-radius: 0.5rem;
    margin: 1rem 0;
    font-family: 'Georgia', 'Times New Roman', serif;
}

.sim-formula-equation{
    text-align: center;
    font-size: 1.5rem;
    font-weight: 500;
    letter-spacing: 1px;
    color: #ffffff;
    margin-bottom: 0.5rem;
    font-style: italic;
}

.sim-formula-description{
    text-align: center;
    font-size: 0.85rem;
    color: #b8c0ff;
    font-family: system-ui, -apple-system, sans-serif;
    font-style: normal;
}

.sim-vector-display{
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 0.5rem;
    margin-top: 1rem;
}

.sim-vector-component{
    flex: 1;
    text-align: center;
}

.sim-vector-component-label{
    font-size: 0.75rem;
    color: #888;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.sim-vector-component-value{
    font-size: 1.3rem;
    font-weight: bold;
    font-family: 'Courier New', monospace;
}

@media (max-width: 768px){
    body{
        padding: 1rem;
    }
    
    .sim-container{
        padding: 1rem;
        margin-top: 70px;
    }
    
    .sim-header h1{
        font-size: 1.8rem;
    }
    
    .sim-stats{
        grid-template-columns: repeat(2, 1fr);
    }
    
    .sim-controls{
        flex-direction: column;
    }
    
    .sim-btn{
        width: 100%;
    }
}

.mb-1 {
    margin-bottom: 0.5rem;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mb-3 {
    margin-bottom: 1.5rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.mt-1 {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.mt-3 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 2rem;
}

.hidden{
    display: none;
}

.visible{
    display: block;
}

.mode-selector {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 15px;
}

.quiz-progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.quiz-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #6b9eff, #a56bff);
    width: 0%;
    transition: width 0.3s ease;
}

.quiz-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    padding: 0 1rem;
}

.quiz-question-counter, .quiz-score {
    font-size: 1.1rem;
    color: #ccc;
}

.quiz-question-counter span, .quiz-score span {
    color: #6b9eff;
    font-weight: bold;
}

.quiz-card, .quiz-results {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 2rem;
}

.quiz-question {
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.quiz-option {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
    color: #ccc;
    font-size: 1.05rem;
}

.quiz-option:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(107, 158, 255, 0.5);
}

.quiz-option.selected {
    background: rgba(107, 158, 255, 0.2);
    border-color: #6b9eff;
    color: #fff;
}

.quiz-option.correct {
    background: rgba(107, 255, 180, 0.2);
    border-color: #6bffb4;
    color: #6bffb4;
}

.quiz-option.incorrect {
    background: rgba(255, 107, 107, 0.2);
    border-color: #ff6b6b;
    color: #ff6b6b;
}

.quiz-option.disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.quiz-feedback {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.feedback-content {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.feedback-icon {
    font-size: 2rem;
}

.feedback-text {
    font-size: 1.2rem;
    font-weight: bold;
}

.feedback-text.correct {
    color: #6bffb4;
}

.feedback-text.incorrect {
    color: #ff6b6b;
}

.feedback-explanation {
    color: #ccc;
    line-height: 1.6;
}

.quiz-controls {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.results-header h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #6b9eff, #a56bff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.results-score {
    text-align: center;
    margin-bottom: 3rem;
}

.results-percentage {
    font-size: 4rem;
    font-weight: bold;
    background: linear-gradient(135deg, #6b9eff, #a56bff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1rem;
}

.results-fraction {
    font-size: 1.5rem;
    color: #ccc;
    margin-bottom: 1rem;
}

.results-message {
    font-size: 1.3rem;
    color: #6b9eff;
}

.results-breakdown {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.breakdown-item {
    display: flex;
    justify-content: space-between;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.breakdown-label {
    color: #ccc;
}

.breakdown-value {
    font-weight: bold;
    font-size: 1.2rem;
}

.breakdown-value.green {
    color: #6bffb4;
}

.breakdown-value.red {
    color: #ff6b6b;
}

.breakdown-value.blue {
    color: #6b9eff;
}

.results-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.question-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    padding: 1rem;
}

.question-dot {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
    color: #ccc;
}

.question-dot:hover {
    background: rgba(107, 158, 255, 0.3);
}

.question-dot.current {
    background: #6b9eff;
    color: #fff;
}

.question-dot.answered {
    background: rgba(107, 255, 180, 0.3);
    border: 2px solid #6bffb4;
}

.question-dot.incorrect {
    background: rgba(255, 107, 107, 0.3);
    border: 2px solid #ff6b6b;
}

@media (max-width: 1024px) {
    .quiz-layout {
        grid-template-columns: 1fr;
    }
}

li::before{
    transform: translateY(-6px);
}

.quiz-layout {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 2rem;
    margin-top: 2rem;
}

.quiz-sidebar1,
.quiz-sidebar2 {
    max-width: 400px;
    width: 100%;
}

.quiz-main {
    min-height: 600px;
}

.dropdown {
    position: relative;
    cursor: pointer;
}

.dropdown > a {
    cursor: default;
    pointer-events: none;
}

.dropdown-content {
    position: absolute;
    top: calc(100% + 20px);
    left: 50%;
    transform: translateX(-10%);
    background: linear-gradient(135deg, rgba(3, 3, 5, 0.98), rgba(3, 3, 5, 0.98));
    backdrop-filter: blur(10px);
    min-width: 200px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    padding: 8px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.dropdown:hover .dropdown-content {
    opacity: 1;
    visibility: visible;
}

.dropdown-content a {
    display: block;
    padding: 12px 20px;
    color: #fff;
    text-decoration: none;
    font-size: 18px;
    border-radius: 8px;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.dropdown-content a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(3, 3, 5, 0.98), rgba(3, 3, 5, 0.98));
    transition: left 0.4s ease;
    z-index: -1;
}

.dropdown-content a:not(:last-child) {
    margin-bottom: 4px;
}

.dropdown-content a:hover:not(.active2) {
    background-color: rgba(80, 80, 160, 0.3);
    color: #b8c0ff;
    transform: translateX(4px);
}

.dropdown-content a.active2 {
    background-color: rgba(80, 80, 160, 0.3);
    color: #b8c0ff;
}

.dropdown-content a:hover:not(.active2)::before {
    left: 100%;
}

.dropdown-content::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-600%);
    width: 0;
    height: 0;
    background: linear-gradient(135deg, rgba(3, 3, 5, 0.98), rgba(3, 3, 5, 0.98));
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid rgba(255, 255, 255, 0.12);
}

.dropdown-content::after {
    content: '';
    position: absolute;
    top: -7px;
    left: 50%;
    transform: translateX(-600%);
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid rgba(3, 3, 5, 0.98);
}
.dropdown::after {
    content: "";
    position: absolute;
    bottom: -6px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #b8c0ff;
    border-radius: 2px;
    transform: translateX(-50%);
    transition:
        width 0.15s ease,
        left 0.15s ease,
        transform 0.15s ease;
}

.dropdown:hover::after {
    width: 50%;
}
.dropdown:hover > a {
    color: #b8c0ff;
}
.dropdown::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 20px;
    background: transparent;
}