/* DsfX Convert - 共通スタイル */

@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css');

/* ヘッダー */
.main-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
}

.logo-section {
    flex: 1;
}

.logo-link {
    text-decoration: none;
    color: inherit;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.2rem;
    background: linear-gradient(45deg, #ffffff, #f0f8ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline {
    font-size: 0.9rem;
    opacity: 0.9;
    font-weight: 300;
}

.header-nav {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

/* モバイルメニュー */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
}

/* フッター */
.main-footer {
    background: #2c3e50;
    color: white;
    padding: 3rem 0 1rem 0;
    margin-top: auto;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-title {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-subtitle {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: #ecf0f1;
}

.footer-description {
    color: #bdc3c7;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.company-links {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.company-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 0;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.company-link:hover {
    color: #5a67d8;
    background: rgba(102, 126, 234, 0.1);
    padding-left: 0.5rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #667eea;
}

.footer-bottom {
    border-top: 1px solid #34495e;
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-copyright {
    color: #95a5a6;
}

.footer-note {
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.footer-tech {
    color: #95a5a6;
}

.tech-note {
    font-size: 0.9rem;
    font-style: italic;
}

.tech-detail {
    font-size: 0.8rem;
    color: #7f8fa6;
    margin-top: 0.3rem;
}

/* パンくずナビ */
.breadcrumb {
    background: #f8f9fa;
    padding: 1rem 0;
    border-bottom: 1px solid #e9ecef;
}

.breadcrumb-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.breadcrumb-nav a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-nav a:hover {
    color: #5a67d8;
}

.breadcrumb-separator {
    color: #6c757d;
}

.breadcrumb-current {
    color: #495057;
    font-weight: 500;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .header-container {
        flex-wrap: wrap;
        position: relative;
    }
    
    .header-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        flex-direction: column;
        padding: 1rem 2rem;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    }
    
    .header-nav.active {
        display: flex;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .mobile-menu-toggle.active span:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }
    
    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active span:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .breadcrumb-container {
        padding: 0 1rem;
    }
}

@media (max-width: 480px) {
    .header-container {
        padding: 1rem;
    }
    
    .footer-container {
        padding: 0 1rem;
    }
}/* Markdown変換ツール専用スタイル */

:root {
    --container-max: 1200px;
    --radius-lg: 12px;
    --primary-grad: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --bg-white: #ffffff;
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-primary: 0 4px 20px rgba(102, 126, 234, 0.3);
}

body {
    background: var(--bg-white);
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin: 0;
    padding: 0;
}

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

header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
    background: var(--primary-grad);
    color: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-primary);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
    font-weight: 300;
}

.tool-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-card);
    border: 1px solid #e2e8f0;
}

/* タブナビゲーション */
.converter-tabs {
    display: flex;
    background: #f1f5f9;
    border-radius: var(--radius-lg);
    padding: 0.5rem;
    margin-bottom: 2rem;
    gap: 0.5rem;
}

.tab-button {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    border-radius: var(--radius-lg);
    background: transparent;
    color: #64748b;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1rem;
}

.tab-button:hover {
    background: #e2e8f0;
    color: #475569;
}

.tab-button.active {
    background: var(--primary-grad);
    color: white;
    box-shadow: var(--shadow-primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* セクション共通スタイル */
.input-section,
.output-section,
.action-section,
.examples-section,
.stats-section,
.info-section {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-card);
    margin-bottom: 2rem;
    border: 1px solid #e2e8f0;
}

.input-section {
    background: #f8f9fa;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h3 {
    font-size: 1.3rem;
    color: #2d3748;
    margin: 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.input-options,
.output-options {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.file-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: #667eea;
    color: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.file-label:hover {
    background: #5a67d8;
    transform: translateY(-1px);
}

.file-label input[type="file"] {
    display: none;
}

.clear-btn,
.paste-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.clear-btn {
    background: #e53e3e;
    color: white;
}

.clear-btn:hover {
    background: #c53030;
    transform: translateY(-1px);
}

.paste-btn {
    background: #718096;
    color: white;
}

.paste-btn:hover {
    background: #4a5568;
    transform: translateY(-1px);
}

#markdownInput {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-lg);
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
    min-height: 400px;
    transition: all 0.2s ease;
    outline: none;
}

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

.text-info {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
    color: #718096;
    font-size: 0.9rem;
    font-weight: 500;
}

/* アクションセクション */
.action-section {
    text-align: center;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.convert-btn,
.copy-btn,
.download-btn {
    padding: 1rem 2rem;
    border: none;
    border-radius: var(--radius-lg);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 140px;
    justify-content: center;
}

.convert-btn {
    background: var(--primary-grad);
    color: white;
    box-shadow: var(--shadow-primary);
}

.convert-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.copy-btn {
    background: #4299e1;
    color: white;
}

.copy-btn:hover {
    background: #3182ce;
    transform: translateY(-1px);
}

.download-btn {
    background: #ed8936;
    color: white;
}

.download-btn:hover {
    background: #dd6b20;
    transform: translateY(-1px);
}

/* プレビューセクション */
.preview-container {
    background: var(--bg-white);
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-lg);
    min-height: 400px;
    overflow-y: auto;
}

.preview {
    padding: 2rem;
    line-height: 1.6;
    color: #2d3748;
}

.preview-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 200px;
    color: #a0aec0;
    text-align: center;
}

.preview-placeholder i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.preview-placeholder p {
    font-size: 1.1rem;
    margin: 0;
}

/* プレビュー内のMarkdownスタイル */
.preview h1, .preview h2, .preview h3, .preview h4, .preview h5, .preview h6 {
    color: #2d3748;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.preview h1 { font-size: 2rem; border-bottom: 2px solid #e2e8f0; padding-bottom: 0.5rem; }
.preview h2 { font-size: 1.5rem; }
.preview h3 { font-size: 1.3rem; }
.preview h4 { font-size: 1.1rem; }

.preview p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

.preview code {
    background: #f1f5f9;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
    font-size: 0.9em;
    color: #e53e3e;
}

.preview pre {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-lg);
    padding: 1rem;
    overflow-x: auto;
    margin: 1rem 0;
}

.preview pre code {
    background: none;
    padding: 0;
    color: #2d3748;
}

.preview blockquote {
    border-left: 4px solid #667eea;
    background: #f8fafc;
    margin: 1rem 0;
    padding: 1rem 1.5rem;
    color: #4a5568;
}

.preview ul, .preview ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.preview li {
    margin-bottom: 0.5rem;
}

.preview table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.preview th, .preview td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.preview th {
    background: #f8fafc;
    font-weight: 600;
    color: #2d3748;
}

.preview a {
    color: #667eea;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.2s ease;
}

.preview a:hover {
    border-bottom-color: #667eea;
}

.preview img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    margin: 1rem 0;
}

/* サンプルセクション */
.examples-section h3 {
    margin-bottom: 1.5rem;
    color: #2d3748;
    font-size: 1.3rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.examples-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.example-btn {
    background: var(--bg-white);
    padding: 1.5rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
    color: inherit;
}

.example-btn:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: var(--shadow-card);
}

.example-btn i {
    font-size: 1.5rem;
    color: #667eea;
    margin-bottom: 0.5rem;
}

.example-btn span {
    font-weight: 600;
    color: #2d3748;
    font-size: 1rem;
}

.example-btn small {
    color: #718096;
    font-size: 0.9rem;
}

/* 統計セクション */
.stats-section h3 {
    margin-bottom: 1.5rem;
    color: #2d3748;
    font-size: 1.3rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.stat-card {
    background: var(--bg-white);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-card);
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-icon {
    font-size: 2rem;
    color: #667eea;
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
    text-align: left;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 0.25rem;
    line-height: 1;
}

.stat-label {
    font-size: 0.8rem;
    color: #718096;
    font-weight: 500;
}

/* 情報セクション */
.info-section h3 {
    margin-bottom: 1.5rem;
    color: #2d3748;
    font-size: 1.3rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-content {
    color: #4a5568;
    line-height: 1.7;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.feature-item {
    text-align: center;
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: var(--radius-lg);
    border: 1px solid #e2e8f0;
}

.feature-icon {
    font-size: 2.5rem;
    color: #667eea;
    margin-bottom: 1rem;
}

.feature-item h4 {
    font-size: 1.2rem;
    color: #2d3748;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.feature-item p {
    color: #718096;
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

.markdown-guide {
    margin-bottom: 2rem;
}

.markdown-guide h4 {
    font-size: 1.2rem;
    color: #2d3748;
    margin-bottom: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.guide-item {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid #e2e8f0;
}

.guide-item h5 {
    font-size: 1rem;
    color: #2d3748;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.guide-item code {
    background: var(--bg-white);
    padding: 0.5rem;
    border-radius: 4px;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
    font-size: 0.8rem;
    color: #667eea;
    display: block;
    line-height: 1.4;
    border: 1px solid #e2e8f0;
}

.usage-examples {
    margin-bottom: 2rem;
}

.usage-examples h4 {
    font-size: 1.2rem;
    color: #2d3748;
    margin-bottom: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.usage-examples ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.usage-examples li {
    padding: 0.8rem 0;
    border-bottom: 1px solid #e2e8f0;
    color: #4a5568;
    line-height: 1.6;
}

.usage-examples li:last-child {
    border-bottom: none;
}

.usage-examples strong {
    color: #2d3748;
    font-weight: 600;
}

.privacy-note {
    background: linear-gradient(135deg, #e8f5e8 0%, #d4f4dd 100%);
    border: 2px solid #48bb78;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.privacy-icon {
    font-size: 2rem;
    color: #2f855a;
    flex-shrink: 0;
}

.privacy-text strong {
    color: #2f855a;
    font-size: 1.1rem;
    display: block;
    margin-bottom: 0.5rem;
}

.privacy-text p {
    color: #2f855a;
    margin: 0;
    line-height: 1.5;
    font-size: 0.95rem;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    header {
        margin-bottom: 2rem;
        padding: 1.5rem 1rem;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .tool-card {
        padding: 1.5rem;
    }
    
    .input-section,
    .output-section,
    .action-section,
    .examples-section,
    .stats-section,
    .info-section {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .input-options,
    .output-options {
        width: 100%;
        justify-content: flex-start;
    }
    
    .converter-tabs {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .tab-button {
        padding: 0.75rem;
    }
    
    .action-section {
        flex-direction: column;
        align-items: center;
    }
    
    .convert-btn,
    .copy-btn,
    .download-btn {
        width: 100%;
        max-width: 250px;
    }
    
    #markdownInput {
        min-height: 300px;
    }
    
    .preview-container {
        min-height: 300px;
    }
    
    .examples-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .guide-grid {
        grid-template-columns: 1fr;
    }
    
    .input-options,
    .output-options {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .file-label,
    .clear-btn,
    .paste-btn {
        width: 100%;
        justify-content: center;
    }
    
    .example-btn {
        text-align: center;
    }
    
    .feature-item {
        padding: 1rem;
    }
    
    .feature-icon {
        font-size: 2rem;
    }
    
    .privacy-note {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0.5rem;
    }
    
    header {
        margin-bottom: 1.5rem;
        padding: 1rem;
    }
    
    header h1 {
        font-size: 1.75rem;
    }
    
    .tool-card {
        padding: 1rem;
    }
    
    .input-section,
    .output-section,
    .action-section,
    .examples-section,
    .stats-section,
    .info-section {
        padding: 1rem;
    }
    
    .stat-card {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .stat-content {
        text-align: center;
    }
    
    #markdownInput {
        min-height: 250px;
        font-size: 0.8rem;
    }
    
    .preview-container {
        min-height: 250px;
    }
    
    .preview {
        padding: 1rem;
        font-size: 0.9rem;
    }
}