:root {
    --bg-color: #0d0d0d;
    --panel-color: #1a1a1a;
    --neon-blue: #00f0ff;
    --neon-purple: #9a00ff;
    --text-light: #e0e0e0;
    --text-accent: #b4c7ff;
}

body {
    font-family: 'Roboto Mono', monospace;
    background-color: var(--bg-color);
    color: var(--text-light);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: hidden;
}

header {
    width: 100%;
    padding: 30px 0;
    text-align: center;
    border-bottom: 1px solid var(--neon-blue);
    position: relative;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, var(--neon-blue) 0%, transparent 70%);
    opacity: 0.1;
    z-index: -1;
}

h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 3em;
    margin: 0;
    letter-spacing: 5px;
    text-shadow: 0 0 10px var(--neon-blue);
}

.cursor {
    animation: blink 1s infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

header p {
    font-size: 1em;
    letter-spacing: 2px;
    color: var(--text-accent);
}

.main-layout {
    display: flex;
    width: 95%;
    max-width: 1400px;
    margin-top: 40px;
    gap: 30px;
}

.component-viewer {
    flex: 3;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.component-display {
    width: 100%;
    height: 500px;
    background-color: var(--panel-color);
    border: 1px solid var(--neon-blue);
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    position: relative;
    transition: all 0.5s ease;
}

.component-display::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(45deg, var(--neon-blue) 0, var(--neon-blue) 1px, transparent 1px, transparent 20px);
    opacity: 0.05;
    pointer-events: none;
}

.info-panel {
    background-color: var(--panel-color);
    border: 1px solid var(--neon-purple);
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(154, 0, 255, 0.2);
    padding: 25px;
    text-align: left;
}

.info-panel h2 {
    font-family: 'Orbitron', sans-serif;
    color: var(--neon-blue);
    border-bottom: 1px solid var(--neon-purple);
    padding-bottom: 10px;
    margin-top: 0;
    font-size: 1.8em;
    text-shadow: 0 0 5px var(--neon-blue);
}

.info-panel p {
    font-size: 1.1em;
    color: var(--text-accent);
}

.component-list {
    flex: 1;
    background-color: var(--panel-color);
    border: 1px solid var(--neon-purple);
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(154, 0, 255, 0.2);
    padding: 20px;
}

.list-title {
    font-family: 'Orbitron', sans-serif;
    color: var(--neon-purple);
    text-align: center;
    font-size: 1.2em;
    letter-spacing: 2px;
    border-bottom: 1px solid var(--neon-blue);
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.list-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    cursor: pointer;
    border-radius: 8px;
    transition: background-color 0.3s, transform 0.3s, box-shadow 0.3s;
    margin-bottom: 10px;
}

.list-item:hover {
    background-color: rgba(0, 240, 255, 0.1);
    transform: translateX(10px);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.4);
}

.list-item.active {
    background-color: rgba(154, 0, 255, 0.2);
    border: 1px solid var(--neon-purple);
    box-shadow: 0 0 15px rgba(154, 0, 255, 0.6);
}

.list-item img {
    width: 60px;
    height: auto;
    filter: brightness(1.2) drop-shadow(0 0 5px var(--neon-blue));
    transition: transform 0.3s ease;
}

.list-item:hover img {
    transform: scale(1.1) rotateY(10deg);
}

.list-item span {
    font-size: 1em;
    letter-spacing: 1px;
}

.flip-container {
    width: 100%;
    height: 100%;
    perspective: 1000px;
}

.flipper {
    width: 100%;
    height: 100%;
    position: relative;
    transition: transform 0.8s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    transform-style: preserve-3d;
}

.flipped .flipper {
    transform: rotateY(180deg);
}

.front, .back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.back {
    transform: rotateY(180deg);
}

.front img, .back img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}