/* === GLOBAL STYLES === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #2c3e50;
    overflow-x: hidden;
    min-height: 100vh;
}

#gameContainer {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
}

/* === SCREEN MANAGEMENT === */
.screen {
    display: none;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.5s ease;
}

.screen.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* === WELCOME SCREEN === */
.welcome-content {
    text-align: center;
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.welcome-content h1 {
    font-size: 3em;
    margin-bottom: 30px;
    color: #2c3e50;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.smartphone-intro {
    margin: 30px 0;
    animation: phoneGlow 2s infinite alternate;
}

@keyframes phoneGlow {
    from { filter: drop-shadow(0 0 5px rgba(52, 152, 219, 0.3)); }
    to { filter: drop-shadow(0 0 15px rgba(52, 152, 219, 0.6)); }
}

.intro-text {
    font-size: 1.2em;
    line-height: 1.6;
    margin: 30px 0;
    color: #34495e;
}

/* === BUTTONS === */
.main-button {
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 1.2em;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
    font-weight: 600;
}

.main-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
}

.main-button:disabled {
    background: #95a5a6;
    cursor: not-allowed;
    box-shadow: none;
}

.secondary-button {
    background: transparent;
    color: #3498db;
    border: 2px solid #3498db;
    padding: 12px 25px;
    font-size: 1em;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-left: 15px;
}

.secondary-button:hover {
    background: #3498db;
    color: white;
}

/* === BUILDING SCREEN === */
.building-content {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.building-content h2 {
    text-align: center;
    font-size: 2.2em;
    margin-bottom: 20px;
    color: #2c3e50;
}

.instruction {
    text-align: center;
    font-size: 1.1em;
    margin-bottom: 30px;
    color: #7f8c8d;
}

.build-container {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    margin-bottom: 30px;
}

.cpu-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    min-height: 400px;
}

.drop-zone {
    border: 3px dashed #bdc3c7;
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

.drop-zone.drag-over {
    border-color: #3498db;
    background: #e3f2fd;
    transform: scale(1.05);
}

.drop-zone.filled {
    border-color: #27ae60;
    background: #e8f5e8;
}

.drop-hint {
    font-size: 1.1em;
    color: #7f8c8d;
    line-height: 1.4;
}

.components-box {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
}

.components-box h3 {
    margin-bottom: 15px;
    color: #2c3e50;
}

.draggable-components {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.component {
    background: white;
    border-radius: 10px;
    padding: 15px;
    cursor: move;
    transition: all 0.3s ease;
    border: 2px solid #ecf0f1;
    display: flex;
    align-items: center;
    gap: 15px;
}

.component:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.component.dragging {
    opacity: 0.5;
    transform: rotate(5deg);
}

.component span {
    font-weight: 600;
    color: #2c3e50;
}

/* === SIMULATION SCREEN === */
.simulation-content {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.simulation-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    margin-bottom: 30px;
}

.cpu-visualization {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    position: relative;
    min-height: 400px;
}

.cpu-component {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 3px solid #ecf0f1;
    position: relative;
}

.cpu-component.active {
    border-color: #3498db;
    background: #e3f2fd;
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

.cpu-component.processing {
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.component-icon {
    font-size: 3em;
    margin-bottom: 10px;
}

.component-label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
    line-height: 1.2;
}

.component-data {
    background: white;
    border-radius: 8px;
    padding: 10px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #e74c3c;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1em;
}

.data-flow {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 10;
}

.step-controls {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
}

.current-step h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.3em;
}

.current-step p {
    margin-bottom: 10px;
    line-height: 1.4;
}

#stepDescription {
    font-size: 1.1em;
    font-weight: 600;
    color: #3498db;
}

#stepExplanation {
    color: #7f8c8d;
    font-style: italic;
}

/* === PRACTICE SCREEN === */
.practice-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    margin-bottom: 30px;
}

.practice-controls {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
}

.current-task h3 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.step-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.step-button {
    background: white;
    border: 2px solid #ecf0f1;
    padding: 12px 15px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    font-size: 1em;
}

.step-button:hover {
    border-color: #3498db;
    background: #e3f2fd;
}

.step-button.correct {
    border-color: #27ae60;
    background: #e8f5e8;
    color: #27ae60;
    font-weight: 600;
}

.step-button.wrong {
    border-color: #e74c3c;
    background: #fdf2f2;
    color: #e74c3c;
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* === SUCCESS SCREEN === */
.success-content {
    text-align: center;
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.badge {
    background: linear-gradient(45deg, #f1c40f, #f39c12);
    border-radius: 20px;
    padding: 30px;
    margin: 30px auto;
    max-width: 300px;
    box-shadow: 0 10px 25px rgba(241, 196, 15, 0.3);
}

.badge-icon {
    font-size: 4em;
    margin-bottom: 15px;
}

.badge-text {
    font-size: 1.5em;
    font-weight: 700;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.learned-concepts {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin: 30px 0;
    text-align: left;
}

.learned-concepts h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    text-align: center;
}

.learned-concepts ul {
    list-style: none;
}

.learned-concepts li {
    padding: 8px 0;
    font-size: 1.1em;
    line-height: 1.4;
}

/* === PROGRESS BAR === */
.progress-bar {
    background: #ecf0f1;
    border-radius: 25px;
    height: 10px;
    margin: 20px 0;
    overflow: hidden;
}

.progress-fill {
    background: linear-gradient(45deg, #27ae60, #2ecc71);
    height: 100%;
    width: 0%;
    transition: width 0.5s ease;
    border-radius: 25px;
}

/* === GAME CONTROLS === */
.game-controls {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    gap: 10px;
    z-index: 1000;
}

.control-button {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 1.2em;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.control-button:hover {
    background: white;
    transform: scale(1.1);
}

/* === MODAL (Fortsetzung) === */
.modal {
   display: none;
   position: fixed;
   z-index: 2000;
   left: 0;
   top: 0;
   width: 100%;
   height: 100%;
   background-color: rgba(0,0,0,0.5);
   backdrop-filter: blur(5px);
}

.modal-content {
   background-color: white;
   margin: 10% auto;
   padding: 30px;
   border-radius: 20px;
   width: 80%;
   max-width: 500px;
   position: relative;
   box-shadow: 0 20px 40px rgba(0,0,0,0.2);
   animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
   from {
       transform: translateY(-50px);
       opacity: 0;
   }
   to {
       transform: translateY(0);
       opacity: 1;
   }
}

.close {
   position: absolute;
   right: 15px;
   top: 15px;
   font-size: 2em;
   cursor: pointer;
   color: #aaa;
   transition: color 0.3s ease;
}

.close:hover {
   color: #e74c3c;
}

/* === ANIMATIONS === */
@keyframes dataFlow {
   0% {
       stroke-dashoffset: 100%;
       opacity: 0;
   }
   20% {
       opacity: 1;
   }
   100% {
       stroke-dashoffset: 0;
       opacity: 1;
   }
}

.data-path {
   stroke: #3498db;
   stroke-width: 3;
   fill: none;
   stroke-dasharray: 10;
   animation: dataFlow 2s ease-in-out;
}

.data-particle {
   fill: #e74c3c;
   r: 5;
   animation: particleMove 2s ease-in-out;
}

@keyframes particleMove {
   0% { opacity: 0; }
   10% { opacity: 1; }
   90% { opacity: 1; }
   100% { opacity: 0; }
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 768px) {
   #gameContainer {
       padding: 10px;
   }
   
   .build-container,
   .simulation-container,
   .practice-container {
       grid-template-columns: 1fr;
       gap: 20px;
   }
   
   .cpu-layout,
   .cpu-visualization {
       grid-template-columns: 1fr;
       gap: 15px;
   }
   
   .welcome-content h1 {
       font-size: 2em;
   }
   
   .smartphone-intro svg {
       width: 150px;
       height: 300px;
   }
   
   .main-button {
       padding: 12px 25px;
       font-size: 1em;
   }
   
   .modal-content {
       width: 95%;
       margin: 5% auto;
       padding: 20px;
   }
   
   .component {
       flex-direction: column;
       text-align: center;
       gap: 10px;
   }
   
   .component svg {
       width: 60px;
       height: 60px;
   }
}

@media (max-width: 480px) {
   .welcome-content {
       padding: 20px;
   }
   
   .building-content,
   .simulation-content,
   .practice-content,
   .success-content {
       padding: 20px;
   }
   
   .step-buttons {
       gap: 8px;
   }
   
   .step-button {
       padding: 10px 12px;
       font-size: 0.9em;
   }
   
   .game-controls {
       top: 10px;
       right: 10px;
   }
   
   .control-button {
       width: 40px;
       height: 40px;
       font-size: 1em;
   }
}

/* === ACCESSIBILITY === */
@media (prefers-reduced-motion: reduce) {
   *, *::before, *::after {
       animation-duration: 0.01ms !important;
       animation-iteration-count: 1 !important;
       transition-duration: 0.01ms !important;
   }
}

.sr-only {
   position: absolute;
   width: 1px;
   height: 1px;
   padding: 0;
   margin: -1px;
   overflow: hidden;
   clip: rect(0, 0, 0, 0);
   white-space: nowrap;
   border: 0;
}

/* Focus styles for keyboard navigation */
button:focus,
.component:focus {
   outline: 3px solid #3498db;
   outline-offset: 2px;
}

/* === TOOLTIP SYSTEM === */
.tooltip-container {
    position: absolute;
    background: white;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    max-width: 300px;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    border: 2px solid #3498db;
}

.tooltip-container.visible {
    opacity: 1;
    pointer-events: auto;
}

.technical-term {
    cursor: help;
    border-bottom: 2px dotted #3498db;
    transition: all 0.3s ease;
}

.technical-term:hover {
    background: #e3f2fd;
    padding: 2px 4px;
    border-radius: 4px;
}

#tooltipTitle {
    color: #2c3e50;
    margin-bottom: 10px;
    font-weight: 700;
}

#tooltipTechnical {
    color: #3498db;
    font-weight: 600;
    margin-bottom: 8px;
}

#tooltipExplanation {
    color: #34495e;
    line-height: 1.4;
    margin-bottom: 10px;
}

.tooltip-analogy {
    background: #f8f9fa;
    padding: 8px;
    border-radius: 5px;
    border-left: 3px solid #f39c12;
}

/* === BINARY DISPLAY === */
.binary-controls {
    text-align: center;
    margin: 20px 0;
}

.switch {
    position: relative;
    display: inline-block;
    width: 120px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9em;
    color: white;
    font-weight: 600;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #3498db;
}

input:checked + .slider:before {
    transform: translateX(86px);
}

.binary-display {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    margin: 10px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

.decimal {
    font-size: 1.2em;
    font-weight: 600;
    color: #2c3e50;
}

.equals {
    color: #7f8c8d;
}

.binary {
    font-family: 'Courier New', monospace;
    font-size: 1.1em;
    font-weight: 700;
    color: #e74c3c;
    background: white;
    padding: 4px 8px;
    border-radius: 4px;
    letter-spacing: 2px;
}

.label {
    font-size: 0.9em;
    color: #7f8c8d;
    font-style: italic;
}

/* === CPU STATUS === */
.cpu-status {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin: 20px 0;
}

#clockDisplay, #busActivity {
    background: #2c3e50;
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-family: 'Courier New', monospace;
    font-weight: 600;
    font-size: 0.9em;
}

/* === ENHANCED PRACTICE === */
.step-buttons-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin: 20px 0;
}

.step-button.enhanced {
    background: white;
    border: 2px solid #ecf0f1;
    padding: 15px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    font-size: 1em;
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
}

.step-button.enhanced::before {
    content: attr(data-order);
    background: #95a5a6;
    color: white;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.8em;
}

.step-button.enhanced.correct::before {
    background: #27ae60;
    content: "✓";
}

.step-button.enhanced.wrong::before {
    background: #e74c3c;
    content: "✗";
}

.practice-feedback {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    margin-top: 20px;
    text-align: center;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.practice-feedback.success {
    background: #e8f5e8;
    color: #27ae60;
    border: 2px solid #27ae60;
}

.practice-feedback.error {
    background: #fdf2f2;
    color: #e74c3c;
    border: 2px solid #e74c3c;
}

/* === DATA BUS ANIMATION === */
.data-bit {
    filter: drop-shadow(0 0 3px rgba(0,0,0,0.3));
    animation: bitPulse 0.5s infinite alternate;
}

@keyframes bitPulse {
    from { opacity: 0.7; }
    to { opacity: 1; }
}

/* === ENHANCED COMPONENTS === */
.drop-zone.enhanced {
    transition: all 0.3s ease;
    position: relative;
}

.drop-zone.enhanced:hover .technical-term {
    background: #e3f2fd;
    padding: 2px 4px;
    border-radius: 4px;
}

.enhanced .technical-term {
    font-weight: 600;
    color: #2c3e50;
}

.enhanced small {
    color: #7f8c8d;
    font-size: 0.8em;
}

/* === V2.0 SPECIFIC ENHANCEMENTS === */

.version-badge {
    background: linear-gradient(45deg, #8e44ad, #9b59b6);
    color: white;
    padding: 5px 15px;
    border-radius: 15px;
    font-size: 0.8em;
    margin-bottom: 20px;
    display: inline-block;
    font-weight: 600;
}

.feature-highlights {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.feature {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.1);
    padding: 10px 15px;
    border-radius: 20px;
    color: white;
    font-weight: 600;
}

.feature-icon {
    font-size: 1.2em;
}

.component.enhanced {
    background: white;
    border-radius: 12px;
    padding: 15px;
    cursor: move;
    transition: all 0.3s ease;
    border: 2px solid #ecf0f1;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.component.enhanced:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    border-color: #3498db;
}

.component-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.component-name {
    font-weight: 700;
    color: #2c3e50;
    font-size: 1.1em;
}

.component-info small {
    color: #7f8c8d;
    font-size: 0.85em;
    line-height: 1.2;
}

.progress-text {
    position: absolute;
    right: 10px;
    top: 90%;
    transform: translateY(-50%);
    font-size: 0.9em;
    color: #2c3e50;
    font-weight: 600;
    z-index: 10; 
}

.binary-controls {
    text-align: center;
    margin: 20px 0;
}

.cpu-status {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 15px 0;
}

#clockDisplay, #busActivity, #instructionCounter {
    background: #2c3e50;
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-family: 'Fira Code', 'Courier New', monospace;
    font-weight: 600;
    font-size: 0.8em;
    text-align: center;
}

.practice-task {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    margin: 20px 0;
    text-align: center;
}

.practice-task h3 {
    color: #2c3e50;
    font-size: 1.5em;
    margin-bottom: 10px;
}

.progress-indicator {
    background: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 600;
    color: #3498db;
    margin: 10px 0;
    display: inline-block;
}

.practice-controls-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
}

.badge.enhanced {
    background: linear-gradient(135deg, #f1c40f, #f39c12);
    border-radius: 25px;
    padding: 40px;
    margin: 30px auto;
    max-width: 350px;
    box-shadow: 0 15px 35px rgba(241, 196, 15, 0.3);
    position: relative;
    overflow: hidden;
}

.badge.enhanced::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
    transform: rotate(45deg);
    animation: badgeShine 3s infinite;
}

@keyframes badgeShine {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.badge-subtitle {
    font-size: 0.9em;
    color: rgba(255,255,255,0.8);
    margin-top: 5px;
}

.performance-stats {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin: 25px 0;
}

.stats-grid {
   display: grid;
   grid-template-columns: repeat(3, 1fr);
   gap: 20px;
   margin-top: 15px;
}

.stat {
   text-align: center;
   background: white;
   padding: 15px;
   border-radius: 10px;
   box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.stat-number {
   display: block;
   font-size: 2em;
   font-weight: 700;
   color: #3498db;
   margin-bottom: 5px;
}

.stat-label {
   color: #7f8c8d;
   font-size: 0.9em;
   font-weight: 600;
}

.learned-concepts.enhanced {
   background: #f8f9fa;
   border-radius: 20px;
   padding: 30px;
   margin: 30px 0;
}

.concepts-grid {
   display: grid;
   grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
   gap: 20px;
   margin-top: 20px;
}

.concept {
   background: white;
   padding: 20px;
   border-radius: 12px;
   display: flex;
   align-items: flex-start;
   gap: 15px;
   box-shadow: 0 3px 10px rgba(0,0,0,0.1);
   transition: transform 0.3s ease;
}

.concept:hover {
   transform: translateY(-3px);
}

.concept-icon {
   font-size: 2em;
   flex-shrink: 0;
}

.concept-text {
   line-height: 1.4;
}

.concept-text strong {
   color: #2c3e50;
   display: block;
   margin-bottom: 5px;
}

.success-actions {
   display: flex;
   justify-content: center;
   gap: 15px;
   flex-wrap: wrap;
   margin-top: 30px;
}

.modal-content.enhanced {
   max-width: 600px;
   max-height: 80vh;
   overflow-y: auto;
}

.help-navigation {
   display: flex;
   justify-content: space-between;
   margin-top: 20px;
   padding-top: 20px;
   border-top: 1px solid #ecf0f1;
}

.difficulty-indicator {
   background: rgba(255,255,255,0.9);
   padding: 5px 10px;
   border-radius: 15px;
   font-size: 0.8em;
   font-weight: 600;
   color: #2c3e50;
   margin-top: 10px;
}

.bus-visualization {
   position: absolute;
   top: 0;
   left: 0;
   width: 100%;
   height: 100%;
   pointer-events: none;
   z-index: 1;
}

.data-bit {
   filter: drop-shadow(0 0 3px rgba(0,0,0,0.3));
   animation: bitPulse 0.5s infinite alternate;
}

@keyframes bitPulse {
   from { opacity: 0.7; transform: scale(1); }
   to { opacity: 1; transform: scale(1.1); }
}

/* === RESPONSIVE ENHANCEMENTS === */
@media (max-width: 768px) {
   .feature-highlights {
       flex-direction: column;
       align-items: center;
       gap: 15px;
   }
   
   .stats-grid {
       grid-template-columns: 1fr;
       gap: 15px;
   }
   
   .concepts-grid {
       grid-template-columns: 1fr;
       gap: 15px;
   }
   
   .concept {
       padding: 15px;
   }
   
   .component.enhanced {
       flex-direction: column;
       text-align: center;
       gap: 10px;
   }
   
   .success-actions {
       flex-direction: column;
       align-items: center;
   }
   
   .help-navigation {
       flex-direction: column;
       gap: 10px;
   }
}

/* === ACCESSIBILITY IMPROVEMENTS === */
@media (prefers-reduced-motion: reduce) {
   .badge.enhanced::before {
       animation: none;
   }
   
   .data-bit {
       animation: none;
   }
   
   * {
       transition-duration: 0.1s !important;
   }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
   .component.enhanced {
       border-width: 3px;
   }
   
   .technical-term {
       border-bottom-width: 3px;
   }
   
   .binary {
       border: 2px solid #2c3e50;
   }
}

/* Dark mode preparation */
@media (prefers-color-scheme: dark) {
   :root {
       --bg-primary: #2c3e50;
       --bg-secondary: #34495e;
       --text-primary: #ecf0f1;
       --text-secondary: #bdc3c7;
       --accent-color: #3498db;
   }
}