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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    text-align: center;
    margin-bottom: 40px;
}

header h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 10px;
}

header p {
    font-size: 1.2rem;
    color: #7f8c8d;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.input-methods {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    width: 100%;
    max-width: 1200px;
    margin-bottom: 30px;
}

.upload-section,
.text-input-section {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.upload-section h2,
.text-input-section h2 {
    color: #2c3e50;
    font-size: 1.5rem;
    margin-bottom: 20px;
    text-align: center;
}

.upload-section {
    max-width: none;
}

.text-input-container {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.upload-area {
    border: 2px dashed #3498db;
    border-radius: 10px;
    padding: 80px 20px;
    text-align: center;
    background-color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-area:hover {
    border-color: #2980b9;
    background-color: #ecf0f1;
}

.upload-area.drag-over {
    border-color: #27ae60;
    background-color: #d5f4e6;
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.upload-area h3 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.upload-area p {
    color: #7f8c8d;
    font-size: 1rem;
}

.upload-info {
    margin-top: 20px;
    text-align: center;
}

.upload-info p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.text-input-area {
    display: flex;
    flex-direction: column;
    gap: 15px;
    flex: 1;
    justify-content: space-between;
}

#csvTextInput {
    width: 100%;
    min-height: 280px;
    padding: 15px;
    border: 2px solid #3498db;
    border-radius: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 0.95rem;
    line-height: 1.5;
    resize: vertical;
    background-color: #fff;
    transition: border-color 0.3s ease;
    flex: 1;
}

#csvTextInput:focus {
    outline: none;
    border-color: #2980b9;
}

#csvTextInput::placeholder {
    color: #7f8c8d;
    line-height: 1.4;
}

.text-input-info {
    margin-top: 15px;
    text-align: center;
}

.text-input-info p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.loading {
    text-align: center;
    padding: 40px;
}

.spinner {
    border: 4px solid #ecf0f1;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.result-section {
    width: 100%;
    max-width: 1000px;
    margin-top: 30px;
}

.result-section h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.table-container {
    background-color: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    overflow-x: auto;
}

#tableOutput {
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.4;
    white-space: pre;
    margin: 0;
    color: #2c3e50;
}

.slack-info-panel {
    background-color: #e8f4f8;
    border: 1px solid #3498db;
    border-radius: 8px;
    padding: 15px;
    margin: 20px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.info-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.info-text {
    color: #2c3e50;
    font-size: 0.95rem;
    line-height: 1.4;
}

.info-text code {
    background-color: #34495e;
    color: #ecf0f1;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
}

.inline-icon {
    height: 1.2em;
    width: auto;
    vertical-align: middle;
    margin: 0 2px;
}

.result-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    justify-content: center;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: #3498db;
    color: white;
}

.btn-primary:hover {
    background-color: #2980b9;
}

.btn-secondary {
    background-color: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background-color: #7f8c8d;
}

.error-section {
    width: 100%;
    max-width: 600px;
    margin-top: 30px;
    text-align: center;
}

.error-message {
    background-color: #e74c3c;
    color: white;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.error-message h3 {
    margin-bottom: 10px;
}

/* SEO Content Sections */
.seo-content {
    max-width: 1000px;
    margin: 60px auto 0;
    padding: 0 20px;
}

.seo-content section {
    margin-bottom: 50px;
}

.seo-content h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 20px;
    text-align: center;
}

.seo-content h3 {
    color: #34495e;
    font-size: 1.3rem;
    margin-bottom: 10px;
}

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

/* How-to Section */
.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.step {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    border-left: 4px solid #3498db;
}

/* Benefits Section */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.benefit {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.benefit h3 {
    font-size: 1.1rem;
    margin-bottom: 15px;
}

/* FAQ Section */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: #fff;
    margin-bottom: 20px;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.faq-item h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.faq-item code {
    background: #34495e;
    color: #ecf0f1;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
}

/* Features Section */
.features-list {
    max-width: 800px;
    margin: 0 auto;
    list-style: none;
    padding: 0;
}

.features-list li {
    background: #f8f9fa;
    margin-bottom: 15px;
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #27ae60;
}

.features-list strong {
    color: #2c3e50;
}

/* Comparison Section */
.comparison-section {
    width: 100%;
    max-width: 1200px;
    margin: 60px auto 40px;
    padding: 0 20px;
}

.comparison-section h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 30px;
    text-align: center;
}

.comparison-demo {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 30px;
    align-items: start;
    margin-bottom: 40px;
}

.comparison-item {
    background: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.comparison-item h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    text-align: center;
}

.comparison-item.bad h3 {
    color: #e74c3c;
}

.comparison-item.good h3 {
    color: #27ae60;
}

.comparison-item .example-text {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    overflow-x: auto;
}

.comparison-item .example-text pre {
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    line-height: 1.3;
    margin: 0;
    white-space: pre;
    color: #2c3e50;
}

.comparison-note {
    text-align: center;
    font-style: italic;
    color: #7f8c8d;
    font-size: 0.9rem;
    margin: 0;
}

.comparison-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: #3498db;
    font-weight: bold;
}

.slack-workflow {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 30px;
    margin-top: 30px;
}

.slack-workflow h3 {
    color: #2c3e50;
    font-size: 1.5rem;
    margin-bottom: 20px;
    text-align: center;
}

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

.workflow-step {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.step-number {
    background: #3498db;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin: 0 auto 15px;
}

.workflow-step h4 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 1rem;
}

.workflow-step p {
    color: #7f8c8d;
    font-size: 0.9rem;
    line-height: 1.4;
}

.guides-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.guide-card {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.guide-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    text-decoration: none;
    color: inherit;
}

.guide-card h3 {
    color: #2c3e50;
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.guide-card p {
    color: #7f8c8d;
    font-size: 0.95rem;
    line-height: 1.4;
    margin-bottom: 15px;
}

.guide-cta {
    color: #3498db;
    font-weight: 600;
    font-size: 0.9rem;
}

footer {
    text-align: center;
    margin-top: 60px;
    padding-top: 20px;
    border-top: 1px solid #ecf0f1;
    color: #7f8c8d;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    header h1 {
        font-size: 2rem;
    }

    .input-methods {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .upload-area {
        padding: 40px 15px;
    }

    #csvTextInput {
        min-height: 150px;
    }

    .result-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 200px;
    }
    
    /* SEO content responsive */
    .seo-content {
        padding: 0 15px;
    }
    
    .seo-content h2 {
        font-size: 1.8rem;
    }
    
    .steps-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .benefits-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .step, .benefit, .faq-item {
        padding: 20px;
    }
    
    /* Comparison section mobile */
    .comparison-demo {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .comparison-arrow {
        order: 2;
        font-size: 1.5rem;
        transform: rotate(90deg);
    }
    
    .comparison-item.bad {
        order: 1;
    }
    
    .comparison-item.good {
        order: 3;
    }
    
    .workflow-steps {
        grid-template-columns: 1fr;
    }
    
    .guides-grid {
        grid-template-columns: 1fr;
    }
}