html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    overscroll-behavior: none;
    touch-action: none;
    margin: 0;
    padding: 0;
    background: #fdfdfd;
}

#phet-stage {
    position: absolute;
    top: 0;
    left: 0;
    transform-origin: top left;
    background: #fdfdfd;
    width: 1280px;
    height: 720px;
}

.phet-theme {
    font-family: inherit;
}

.cap-nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: #1e293b;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    color: white;
    font-family: 'Outfit', sans-serif;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.2rem;
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
}

#simCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    touch-action: none;
}

.controls-panel {
    position: absolute;
    top: 80px;
    right: 20px;
    width: 320px;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    z-index: 10;
    display: flex;
    flex-direction: column;
    padding: 15px;
    gap: 15px;
    font-family: 'Outfit', sans-serif;
}

.control-box {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 10px;
}

.control-box h4 {
    margin: 0 0 10px 0;
    font-size: 0.9rem;
    color: #334155;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.slider-group {
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
}

.slider-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
    margin-bottom: 5px;
    display: flex;
    justify-content: space-between;
}

.slider-group label span {
    color: #2563eb;
}

input[type="range"] {
    width: 100%;
    cursor: pointer;
}

.bar-graphs {
    display: flex;
    gap: 15px;
    justify-content: space-around;
    align-items: flex-end;
    height: 80px;
    margin-bottom: 15px;
    padding-top: 10px;
}

.bar-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    width: 30%;
}

.bar {
    width: 25px;
    height: 50px;
    background: #e2e8f0;
    border: 1px solid #cbd5e1;
    border-radius: 3px;
    position: relative;
    overflow: hidden;
}

.bar .fill {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0%;
    transition: height 0.05s linear;
}

.cap-fill {
    background: #3b82f6;
}

.charge-fill {
    background: #ef4444;
}

.energy-fill {
    background: #f59e0b;
}

.bar-label {
    font-size: 0.65rem;
    color: #64748b;
    font-weight: 600;
    text-align: center;
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.checkbox-group label {
    font-size: 0.85rem;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}