* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: #1a1a1a;
    color: #ffffff;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 900px;
    background: #2a2a2a;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

header {
    background: #3a3a3a;
    padding: 20px;
    text-align: center;
}

h1 {
    font-size: 24px;
    margin-bottom: 5px;
}

.subtitle {
    font-size: 14px;
    opacity: 0.8;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

.control-panel, .data-panel {
    padding: 20px;
}

.panel-section {
    margin-bottom: 25px;
}

h2 {
    font-size: 18px;
    margin-bottom: 15px;
}

.form-group {
    margin-bottom: 15px;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #4a4a4a;
    border-radius: 6px;
    resize: vertical;
    font-family: monospace;
    font-size: 14px;
    background: #3a3a3a;
    color: #ffffff;
}

button {
    padding: 10px 15px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-primary {
    background: #5c6bc0;
    color: white;
}

.btn-primary:hover {
    background: #3f51b5;
}

.btn-success {
    background: #43a047;
    color: white;
}

.btn-success:hover {
    background: #388e3c;
}

.btn-danger {
    background: #d32f2f;
    color: white;
}

.btn-danger:hover {
    background: #c62828;
}

.btn-secondary {
    background: #757575;
    color: white;
}

.btn-secondary:hover {
    background: #546e7a;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.port-info {
    background: #3a3a3a;
    padding: 10px;
    border-radius: 6px;
    margin-top: 10px;
    font-size: 14px;
}
.sent-data {
    color: lightblue; /* ���͵�����Ϊǳ��ɫ */
}
.received-data {
    color: lightgreen; /* ���յ�����Ϊǳ��ɫ */
}
