/* Holographic Encoding Experiment Styles */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #0a0a15 0%, #1a1020 50%, #0a0a15 100%);
    color: #e0e0e0;
    min-height: 100vh;
    padding: 80px 2rem 2rem;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

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

h1 {
    font-size: 2.5rem;
    background: linear-gradient(90deg, #ff6b6b, #feca57, #48dbfb, #ff9ff3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.subtitle {
    color: #888;
    font-size: 1.1rem;
    font-style: italic;
}

/* Theory Panel */
.theory-panel {
    background: rgba(255, 107, 107, 0.05);
    border: 1px solid rgba(255, 107, 107, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.theory-panel h2 {
    color: #ff6b6b;
    margin-bottom: 1rem;
}

.formula-box {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.formula {
    font-family: 'Times New Roman', serif;
    font-size: 2rem;
    color: #feca57;
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}

.formula-explanation {
    color: #aaa;
    font-size: 1rem;
    max-width: 700px;
    margin: 0 auto;
}

.formula-explanation strong {
    color: #ff6b6b;
}

.insight-box {
    background: rgba(254, 202, 87, 0.1);
    border-left: 3px solid #feca57;
    padding: 1rem 1.5rem;
    border-radius: 0 8px 8px 0;
}

.insight-box h3 {
    color: #feca57;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.insight-box p {
    color: #aaa;
    line-height: 1.6;
}

.insight-box em {
    color: #ff6b6b;
    font-style: normal;
    font-weight: 600;
}

/* Canvas Container */
.canvas-container {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.canvas-wrapper.main {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1rem;
    max-width: 700px;
    width: 100%;
}

.canvas-wrapper h3 {
    color: #ff6b6b;
    font-size: 1rem;
    margin-bottom: 0.75rem;
    text-align: center;
}

.canvas-wrapper canvas {
    width: 100%;
    height: auto;
    background: #000;
    border-radius: 8px;
    display: block;
}

.canvas-label {
    text-align: center;
    color: #666;
    font-size: 0.85rem;
    margin-top: 0.5rem;
}

/* Shards Display */
.shards-display {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.shards-display h3 {
    color: #feca57;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.shards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
}

.shard {
    background: rgba(255, 107, 107, 0.05);
    border: 1px solid rgba(255, 107, 107, 0.2);
    border-radius: 8px;
    padding: 0.75rem;
    text-align: center;
}

.shard canvas {
    width: 100%;
    background: #000;
    border-radius: 4px;
}

.shard-label {
    font-size: 0.75rem;
    color: #666;
    margin-top: 0.5rem;
}

.shard-accuracy {
    font-size: 0.85rem;
    color: #feca57;
    font-weight: 600;
}

/* Controls */
.controls {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.control-group label {
    color: #888;
    font-size: 0.9rem;
}

.control-group input[type="range"] {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    background: #333;
    border-radius: 3px;
    outline: none;
}

.control-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    background: linear-gradient(135deg, #ff6b6b, #feca57);
    border-radius: 50%;
    cursor: pointer;
}

.control-group select {
    background: #1a1a2e;
    border: 1px solid #444;
    color: #e0e0e0;
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
}

.checkbox-group {
    flex-direction: row;
    align-items: center;
}

.checkbox-group input {
    margin-right: 0.5rem;
    width: 18px;
    height: 18px;
    accent-color: #ff6b6b;
}

.button-group {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-items: flex-end;
}

.btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid #444;
    color: #e0e0e0;
    padding: 0.75rem 1.25rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.btn:hover {
    border-color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
}

.btn.primary {
    background: linear-gradient(90deg, #ff6b6b, #feca57);
    color: #0a0a0f;
    border: none;
    font-weight: 600;
}

.btn.primary:hover {
    transform: scale(1.02);
}

/* Accuracy Panel */
.accuracy-panel {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.accuracy-panel h3 {
    color: #feca57;
    margin-bottom: 1.5rem;
}

.accuracy-formula {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.term {
    text-align: center;
}

.term .label {
    display: block;
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
}

.term .value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ff6b6b;
    font-family: 'Courier New', monospace;
}

.term .formula-small {
    display: block;
    color: #666;
    font-size: 0.75rem;
    font-family: 'Courier New', monospace;
    margin-top: 0.25rem;
}

.accuracy-chart {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 1rem;
}

.accuracy-chart canvas {
    width: 100%;
    height: auto;
}

/* Explanation Panel */
.explanation-panel {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.explanation-panel h3 {
    color: #ff6b6b;
    margin-bottom: 1.5rem;
}

.concept-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.concept {
    text-align: center;
}

.concept-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.concept h4 {
    color: #fff;
    margin-bottom: 0.5rem;
}

.concept p {
    color: #888;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Reference Section */
.reference-section {
    background: rgba(254, 202, 87, 0.05);
    border: 1px solid rgba(254, 202, 87, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.reference-section h3 {
    color: #feca57;
    margin-bottom: 1rem;
}

.reference-section ul {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 0.75rem;
}

.reference-section li {
    color: #aaa;
    font-size: 0.9rem;
    padding-left: 1rem;
    border-left: 2px solid #feca57;
}

.reference-section strong {
    color: #ff6b6b;
}

/* Footer */
footer {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #333;
    color: #666;
}

footer p {
    margin-bottom: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 70px 1rem 1rem;
    }
    
    h1 {
        font-size: 1.8rem;
    }
    
    .formula {
        font-size: 1.5rem;
    }
    
    .controls {
        grid-template-columns: 1fr;
    }
    
    .button-group {
        justify-content: center;
    }
    
    .shards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

/* Focus states */
button:focus,
input:focus,
select:focus {
    outline: 2px solid #ff6b6b;
    outline-offset: 2px;
}

/* Motion preference */
@media (prefers-reduced-motion: reduce) {
    * {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}
