/* 1099toW2.com - Simple, clean, Western-friendly styles */

:root {
    --color-primary: #2563eb;
    --color-primary-dark: #1d4ed8;
    --color-accent: #f59e0b;
    --color-accent-light: #fff7ed;
    --color-success: #10b981;
    --color-danger: #ef4444;
    --color-text: #1f2937;
    --color-text-light: #6b7280;
    --color-bg: #ffffff;
    --color-bg-soft: #f9fafb;
    --color-border: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius: 0.75rem;
    --container: 65rem;
}

* {
    box-sizing: border-box;
}

html {
    font-size: 16px;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.6;
}

a {
    color: var(--color-primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 1.25rem;
}

/* Header */
.site-header {
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    padding: 0.5rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.logo {
    font-size: 1.2rem;
    font-weight: 800;
    line-height: 2.2rem;
    color: var(--color-primary);
    white-space: nowrap;
    display: flex;
}
.logo img{
    margin-right: 8px;
}

.main-nav {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
    font-size: 0.95rem;
}

.main-nav a {
    color: var(--color-text);
    font-weight: 500;
}

.main-nav a:hover {
    color: var(--color-primary);
}

/* Language dropdown */
.language-dropdown {
    position: relative;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: 0.5rem;
    background: var(--color-bg);
    color: var(--color-text);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
}

.lang-btn:hover {
    border-color: var(--color-primary);
}

.lang-btn .caret {
    font-size: 0.65rem;
}

.lang-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 0.35rem);
    min-width: 8rem;
    list-style: none;
    margin: 0;
    padding: 0.35rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 0.5rem;
    box-shadow: var(--shadow-lg);
    display: none;
    z-index: 200;
}

.lang-menu.open {
    display: block;
}

.lang-menu li a {
    display: block;
    padding: 0.5rem 0.75rem;
    border-radius: 0.35rem;
    color: var(--color-text);
    font-size: 0.9rem;
}

.lang-menu li a:hover,
.lang-menu li a.active {
    background: var(--color-bg-soft);
    color: var(--color-primary);
    text-decoration: none;
}

/* Hero */
.hero {
    background: linear-gradient(180deg, #eff6ff 0%, var(--color-bg) 100%);
    padding: 5rem 0 4rem;
    text-align: center;
}

.hero h1 {
    font-size: 2.25rem;
    margin: 0 0 0.75rem;
    line-height: 1.2;
}

.hero .lead {
    font-size: 1.15rem;
    color: var(--color-text-light);
    max-width: 45rem;
    margin: 0 auto;
}

/* SEO intro */
.seo-intro {
    padding-bottom: 2rem;
    color: var(--color-text);
}

.seo-intro p {
    margin-bottom: 1rem;
}

.seo-intro p:last-child {
    margin-bottom: 0;
}

/* Calculator */
.calculator-section {
    padding: 1rem 0 3rem;
}

.calc-form {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem 1.5rem;
}

@media (max-width: 64rem) {
    .form-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 40rem) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

.form-row {
    display: flex;
    flex-direction: column;
}

.form-row label {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
    color: var(--color-text);
}

.form-row .field-hint {
    font-size: 0.78rem;
    color: var(--color-text-light);
    margin-bottom: 0.35rem;
    line-height: 1.4;
}

input[type="text"],
input[type="number"],
select {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: 0.5rem;
    font-size: 1rem;
    font-family: inherit;
    background: var(--color-bg);
}

input:focus,
select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.form-actions {
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
    text-align: center;
}

.btn-primary,
.btn-secondary {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}

.btn-primary {
    background: var(--color-primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--color-primary-dark);
}

.btn-secondary {
    background: var(--color-bg-soft);
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

/* Results */
.results {
    margin-top: 1rem;
}

.results-title {
    text-align: center;
    font-size: 1.5rem;
    margin-bottom: 1.25rem;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

@media (max-width: 64rem) {
    .results-grid {
        grid-template-columns: 1fr;
    }
}

.result-column {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 1.25rem;
    box-shadow: var(--shadow);
}

.result-column.highlight {
    background: var(--color-accent-light);
    border-color: var(--color-accent);
}

.result-column h3 {
    margin: 0 0 1rem;
    font-size: 1.1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--color-primary);
}

.result-column.highlight h3 {
    border-color: var(--color-accent);
}

.result-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--color-border);
    font-size: 0.95rem;
}

.result-line:last-child {
    border-bottom: none;
}

.result-line span:first-child {
    color: var(--color-text-light);
}

.result-line.main {
    font-size: 1.05rem;
    padding: 0.85rem 0;
}

.result-line.main strong {
    font-size: 1.35rem;
    color: var(--color-primary);
}

.result-column.highlight .result-line.main strong {
    color: #b45309;
}


.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-top: 1.25rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border: 1px solid #e5e7eb;
}

/* 表格主体 */
.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.95rem;
    background-color: #ffffff;
    min-width: 600px;
    /* 保证手机端不会把列挤到换行变形 */
}

/* 表头样式 */
.data-table thead {
    background-color: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
}

.data-table th {
    padding: 12px 16px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
}

/* 单元格样式 */
.data-table td {
    padding: 12px 16px;
    color: #334155;
    border-bottom: 1px solid #f1f5f9;
}

/* 隔行变色 (Zebra Striping) - 提升阅读舒适度 */
.data-table tbody tr:nth-child(even) {
    background-color: #f9fafb;
}

/* 鼠标悬停高亮效果 */
.data-table tbody tr:hover {
    background-color: #f1f5f9;
    transition: background-color 0.2s ease;
}

/* 突出第一列 (W-2 年薪) 加粗显示 */
.data-table td:first-child {
    font-weight: 600;
    color: #0f172a;
}

/* 突出最后一列 (1099 最低报价时薪) 使用强调色 */
.data-table td:nth-last-child(2) {
    font-weight: 600;
    color: #2563eb;
    /* 深蓝色强调 */
}

/* SEO 文章容器 */
/* 实战案例高亮框 */
.case-study-box {
    background-color: #f8f9fa;
    padding: 15px;
    border-left: 4px solid #007bff;
    margin: 15px 0;
}

/* 抵税项目下的间距提示 */
.write-offs-note {
    margin-top: 15px;
}

/* 页脚与免责声明 */
.article-footer {
    font-size: 0.9em;
    color: #6c757d;
    border-top: 1px solid #dee2e6;
    padding-top: 15px;
    margin-top: 20px;
}

/* FAQ */
.faq-section {
    background: var(--color-bg-soft);
    padding: 3rem 0;
}

.faq-section h2 {
    text-align: center;
    margin-bottom: 1.5rem;
}

.faq-item {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    margin-bottom: 0.75rem;
    padding: 1rem 1.25rem;
    box-shadow: var(--shadow-sm);
}

.faq-item summary {
    font-weight: 600;
    cursor: pointer;
}

.faq-item p {
    margin: 0.75rem 0 0;
    color: var(--color-text-light);
}

/* Content pages */
.content-page {
    padding: 3rem 0;
}

.content-page h1 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.content-body h2 {
    font-size: 1.35rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}

.content-body p {
    margin-bottom: 1rem;
}

/* Footer */
.site-footer {
    border-top: 1px solid var(--color-border);
    background: var(--color-bg-soft);
    padding: 2rem 0;
    text-align: center;
    font-size: 0.9rem;
    color: var(--color-text-light);
}

.footer-links {
    margin-bottom: 1rem;
}

.footer-links a {
    margin: 0 0.75rem;
    color: var(--color-text);
}

.footer-links a:hover {
    color: var(--color-primary);
}

.footer-disclaimer {
    margin: 0.5rem 0;
}

.footer-copy {
    margin: 0.5rem 0 0;
}

.nav-links{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}
.nav-links a {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border: 1px solid #e5e7eb;
    background-color: #f9fafb;
    padding: 1rem;
}

/* Responsive */
@media (max-width: 48rem) {
    .hero h1 {
        font-size: 1.75rem;
    }

    .header-inner {
        flex-wrap: wrap;
    }

    .main-nav {
        order: 3;
        width: 100%;
        gap: 0.75rem 1rem;
        justify-content: center;
    }

    .language-dropdown {
        order: 2;
    }

    .nav-links {
        grid-template-columns: repeat(1, 1fr);
    }
}
