* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px 20px;
    text-align: center;
}

.header h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.header p {
    font-size: 0.9rem;
    opacity: 0.9;
}

.content {
    padding: 30px;
}

.input-section {
    margin-bottom: 30px;
}

.input-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.input-group {
    display: flex;
    flex-direction: column;
}

.input-group label {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 8px;
    font-weight: 500;
}

.input-group input {
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.calculate-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 30px;
}

.calculate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.calculate-btn:active {
    transform: translateY(0);
}

.result-section {
    display: none;
}

.result-section.active {
    display: block;
}

.summary-card {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 25px;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
}

.summary-item {
    text-align: center;
}

.summary-item .label {
    font-size: 0.85rem;
    opacity: 0.9;
    margin-bottom: 5px;
}

.summary-item .value {
    font-size: 1.5rem;
    font-weight: 700;
}

.results-table {
    background: #f8f9fa;
    border-radius: 15px;
    overflow: hidden;
}

.results-header {
    background: #667eea;
    color: white;
    padding: 20px;
    font-weight: 600;
    font-size: 1.1rem;
}

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

th {
    background: #f8f9fa;
    font-weight: 600;
    color: #555;
    font-size: 0.9rem;
}

td {
    font-size: 0.95rem;
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background: #f8f9fa;
}

.profit {
    color: #f5576c;
    font-weight: 600;
}

.loss {
    color: #667eea;
    font-weight: 600;
}

.footer {
    text-align: center;
    padding: 20px;
    color: #999;
    font-size: 0.85rem;
    border-top: 1px solid #e0e0e0;
    margin-top: 30px;
}

.footer a {
    color: #667eea;
    text-decoration: none;
}

/* SEO 内容样式 */
.seo-content {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.seo-content h2 {
    font-size: 1.3rem;
    color: #667eea;
    margin: 20px 0 10px 0;
}

.seo-content h2:first-child {
    margin-top: 0;
}

.seo-content p {
    line-height: 1.6;
    color: #555;
    margin-bottom: 15px;
}

.seo-content ol,
.seo-content ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.seo-content li {
    line-height: 1.8;
    color: #555;
    margin-bottom: 8px;
}

.seo-content strong {
    color: #667eea;
    font-weight: 600;
}

/* 面包屑导航 */
.breadcrumb {
    padding: 15px 0;
    font-size: 0.9rem;
    color: #666;
}

.breadcrumb a {
    color: #667eea;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

/* 结构化数据 */
.structured-data {
    display: none;
}

@media (max-width: 768px) {
    .header h1 {
        font-size: 1.5rem;
    }

    .content {
        padding: 20px;
    }

    .input-row {
        grid-template-columns: 1fr;
    }

    .summary-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    th, td {
        padding: 10px;
        font-size: 0.85rem;
    }

    table {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .summary-grid {
        grid-template-columns: 1fr;
    }

    .table-container {
        font-size: 0.8rem;
    }

    th, td {
        padding: 8px;
    }
}