.plotter-container {
    margin: 20px auto;
    padding: 20px;
    width: 768px;
    max-width: 100%;
    background: #1a1a1a;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,.3);
    font-family: "Book Antiqua", Palatino, serif;
    color: #fff;
}

.input-group {
    display: flex;
    gap: 15px;
    margin-bottom: 5px;
    flex-wrap: wrap;
}

.input-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 250px;
}

.input-row label {
    font-size: 16px;
    font-weight: 500;
    color: #fff;
    white-space: nowrap;
    min-width: 50px;
}

#function-x,
#function-y {
    flex: 1;
    height: 40px;
    padding: 8px 16px;
    font-size: 16px;
    border: 2px solid #444;
    background: #2a2a2a;
    color: #fff;
    border-radius: 4px;
    transition: border-color .3s;
    font-family: "Book Antiqua", Palatino, serif;
}

#function-x:focus,
#function-y:focus {
    border-color: #00ff00;
    outline: 0;
}

.config-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
    flex-wrap: wrap;
    gap: 15px;
}

.range-config {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.range-input {
    display: flex;
    align-items: center;
    gap: 8px;
}

.range-input label {
    font-size: 14px;
    font-family: "Book Antiqua", Palatino, serif;
    font-weight: 500;
    color: #ccc;
    white-space: nowrap;
}

.range-input input {
    width: 80px;
    max-width: 80px;
    height: 36px;
    padding: 4px 8px;
    font-size: 14px;
    font-family: "Book Antiqua", Palatino, serif;
    border: 2px solid #444;
    background: #2a2a2a;
    color: #fff;
    border-radius: 4px;
    transition: border-color .3s;
}

#line-color {
    width: 50px;
    height: 36px;
    padding: 2px;
    border: 2px solid #444;
    border-radius: 4px;
    cursor: pointer;
    background-color: #2a2a2a;
}

.range-input input:focus,
#line-color:focus {
    border-color: #00ff00;
    outline: 0;
}

#run-button {
    height: 40px;
    padding: 0 32px;
    background-color: #00ff00;
    color: #000;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .3s;
    font-family: "Book Antiqua", Palatino, serif;
}

#run-button:hover {
    background-color: #00dd00;
}

#run-button:active {
    background-color: #00bb00;
}

#run-button:disabled {
    background-color: #666;
    color: #999;
    cursor: not-allowed;
}

.plots-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}

.plot-xy-main {
    grid-column: span 2;
}

.plot-item {
    background: #0a0a0a;
    border: 1px solid #333;
    border-radius: 4px;
    overflow: hidden;
}

.plot-title {
    padding: 10px 15px;
    background: #1a1a1a;
    border-bottom: 1px solid #333;
    font-size: 14px;
    font-weight: 500;
    color: #00ff00;
    text-align: center;
}

.plot-canvas {
    width: 100%;
    height: 220px;
    background: #0a0a0a;
}

.plot-xy-main .plot-canvas {
    height: 350px;
}

@media (max-width: 768px) {
    .input-group {
        flex-direction: column;
    }
    
    .input-row {
        width: 100%;
        min-width: auto;
    }
    
    .config-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    #run-button {
        width: 100%;
    }
    
    .plots-grid {
        grid-template-columns: 1fr;
    }
    
    .plot-xy-main {
        grid-column: span 1;
    }
    
    .plot-xy-main .plot-canvas {
        height: 280px;
    }
}

@media (max-width: 600px) {
    .range-config {
        flex-direction: column;
        width: 100%;
    }
    
    .range-input {
        width: 100%;
    }
}