/* ----------------------------------------
   Base & General Styling (Consistent)
   ---------------------------------------- */
body {
    font-family: 'Open Sans', sans-serif;
    line-height: 1.6;
    color: #333;
    padding-top: 20px;
}
.tasks-heading {
    text-align: center; font-size: 1.25rem; font-weight: 600;
    margin-bottom: 0.5rem; color: #444;
}
.v-tabs ul {
    display: flex; overflow-x: auto; white-space: nowrap; list-style: none;
    padding: 0; margin: 0 3%; border-bottom: 1px solid #ddd;
}
.v-tabs li { display: inline-block; margin: 0; }
.v-tabs a {
    display: inline-block; padding: 0.75rem 1.25rem;
    text-decoration: none; color: #333; font-weight: 500;
}
.v-tabs li.active > a { color: #3273dc; border-bottom: 3px solid #3273dc; }
.v-tabs a:hover { background-color: #f0f0f0; border-radius: 4px; }
.subheading-box {
    background-color: #f7fdf7; border-left: 4px solid #3c763d;
    padding: 0.75rem 1rem; margin: 1rem 3% 1.5rem 3%; border-radius: 4px;
}
.subheading-box .title { color: #3c763d; font-size: 1.25rem; margin: 0; font-weight: 600; }
.v-datalist-container.components-list {
    border: 2px solid #8dc63f; border-radius: 8px;
    padding: 1rem 1rem 10px 1rem; background-color: #fafafa;
}
.v-datalist-title, .v-datalist-subtitle {
    margin-bottom: 0.75rem; padding-bottom: 0.75rem;
    border-bottom: 1px solid #eee;
    text-align: center;
}
.white-boxed-panel {
    background-color: #fff; border: 1px solid #dbdbdb; border-radius: 6px;
    padding: 1.25rem; margin-bottom: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.07);
}

/* ----------------------------------------
   NEW STYLES FOR BPSK EXPERIMENT
   ---------------------------------------- */

/* Control Panel Layout */
.control-panel-grid {
    display: grid;
    grid-template-columns: 1fr; /* Single column */
    gap: 1.5rem;
    align-items: end;
}
.control-item, .control-item-full-width {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.slider-value {
    font-weight: bold;
    color: #3273dc;
    font-size: 1.1em;
}
input[type="range"] {
    width: 100%;
}
/* MODIFIED: Use .input and apply monospace font for bitstream */
.input {
    font-family: 'Courier New', Courier, monospace;
    font-size: 1.2em;
    letter-spacing: 2px; /* Add spacing for readability */
}

/* Info Panel for bits and text */
.info-panel {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Equal columns for bitstreams */
    gap: 1.5rem; /* Increased gap */
}
.info-panel .info-title {
    margin-bottom: 0.5rem;
    border: none;
    font-size: 1em;
    color: #555;
    text-align: left;
}
.info-panel p {
    background-color: #f0f3f5;
    padding: 0.75rem;
    border-radius: 4px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1.2em;
    word-wrap: break-word;
    min-height: 48px;
    letter-spacing: 1px;
}
/* MODIFIED: Styling for errors in the decoded bitstream */
#decoded-bits .error {
    color: #fff;
    background-color: #ff3860;
    font-weight: bold;
    padding: 2px 0;
}

/* ADDED: Observations Panel styling */
#observations-panel {
    margin-top: 1.5rem;
    padding: 1rem;
    text-align: center;
}
#observations p {
    font-size: 1.1em;
    line-height: 1.6;
    margin: 0;
    padding: 0.75rem;
    border-radius: 4px;
    border: 1px solid transparent;
}
#observations .correct {
    color: #155724;
    background-color: #d4edda;
    border-color: #c3e6cb;
}
#observations .incorrect {
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}
#observations .initial {
    color: #555;
    background-color: #e9ecef;
    border-color: #ced4da;
}

/* Plots Layout */
.plots-container {
    display: grid;
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 1.5rem;
    width: 100%;
}
@media (min-width: 1024px) {
    .plots-container {
        grid-template-columns: 1fr 1fr; /* 2x2 grid on desktop */
    }
}
.plot-wrapper {
    height: 300px;
}
.plot-wrapper canvas {
    width: 100%;
    height: 100%;
}

.scale-wrapper {
    transform: scale(0.8);
    transform-origin: top center; /* Keeps scaling centered at the top */
    width: 100%; /* Compensate for shrink so it aligns */
    margin: 0 auto;
}
