/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #e3f2fd 0%, #ffffff 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

header h1 {
    color: #0d47a1;
    margin-bottom: 20px;
    font-size: 2.5rem;
}

/* Navigation Tabs */
.tabs {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    list-style: none;
    gap: 5px;
}

.tab {
    padding: 12px 20px;
    background: #bbdefb;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
    transition: all 0.3s ease;
    font-weight: 600;
}

.tab:hover {
    background: #90caf9;
}

.tab.active {
    background: #64b5f6;
    color: white;
}

/* Main Content */
main {
    max-width: 1000px;
    margin: 0 auto;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Card Styles */
.card {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.card h2 {
    color: #0d47a1;
    margin-bottom: 15px;
    font-size: 1.8rem;
}

.card p {
    color: #555;
    margin-bottom: 20px;
    font-size: 1.1rem;
}

/* Form Styles */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #1976d2;
}

.input-with-unit {
    display: flex;
    gap: 10px;
    align-items: center;
}

.input-with-unit input {
    flex: 3;
}

.input-with-unit select {
    flex: 1;
    padding: 12px;
    border: 2px solid #bbdefb;
    border-radius: 6px;
    font-size: 1rem;
    background: white;
    min-width: 80px;
}

.input-group input,
.input-group textarea,
.input-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #bbdefb;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s;
    background: white;
}

.input-group input:focus,
.input-group textarea:focus,
.input-group select:focus {
    outline: none;
    border-color: #64b5f6;
}

.input-group textarea {
    resize: vertical;
    font-family: monospace;
}

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.button-group button {
    flex: 1;
    min-width: 150px;
}

button {
    background: linear-gradient(to right, #2196f3, #21cbf3);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

button:hover {
    background: linear-gradient(to right, #1976d2, #00b0ff);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

button#demo-data-btn {
    background: linear-gradient(to right, #9c27b0, #673ab7);
}

button#demo-data-btn:hover {
    background: linear-gradient(to right, #7b1fa2, #512da8);
}

/* Results */
.result {
    margin-top: 20px;
    padding: 15px;
    border-radius: 6px;
    background: #e3f2fd;
    min-height: 50px;
}

.result h3 {
    color: #0d47a1;
    margin-bottom: 10px;
}

/* Info Box */
.info-box {
    margin-top: 15px;
    padding: 15px;
    border-radius: 6px;
    background: #f5f5f5;
    border-left: 4px solid #2196f3;
}

.info-box.warning {
    border-left-color: #ff9800;
    background: #fff3e0;
}

.info-box.error {
    border-left-color: #f44336;
    background: #ffebee;
}

.info-box.success {
    border-left-color: #4caf50;
    background: #e8f5e9;
}

/* Canvas for Standard Curve */
#curve-chart {
    width: 100%;
    max-width: 600px;
    height: auto;
    margin: 20px 0;
    border: 1px solid #bbdefb;
    border-radius: 6px;
}

/* Tooltip */
.tooltip {
    display: inline-block;
    width: 18px;
    height: 18px;
    background: #2196f3;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    text-align: center;
    line-height: 18px;
    cursor: help;
    margin-left: 5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .tabs {
        flex-direction: column;
        align-items: center;
    }
    
    .tab {
        width: 100%;
        text-align: center;
        border-radius: 8px;
    }
    
    .card {
        padding: 15px;
    }
    
    .card h2 {
        font-size: 1.5rem;
    }
    
    .input-with-unit {
        flex-direction: column;
    }
    
    .input-with-unit select {
        width: 100%;
        min-width: auto;
    }
    
    .button-group {
        flex-direction: column;
    }
}

/* Alert Styles */
.alert {
    padding: 15px;
    border-radius: 6px;
    margin: 10px 0;
    color: white;
    font-weight: 500;
}

.alert.error {
    background: #f44336;
}

.alert.success {
    background: #4caf50;
}

.alert.warning {
    background: #ff9800;
}

.alert.info {
    background: #2196f3;
}

/* Table for Dilution Series */
.dilution-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.dilution-table th,
.dilution-table td {
    border: 1px solid #bbdefb;
    padding: 10px;
    text-align: center;
}

.dilution-table th {
    background: #64b5f6;
    color: white;
}

.dilution-table tr:nth-child(even) {
    background: #e3f2fd;
}