/* secon.dev exact replication CSS */
/* Based on actual secon.dev design analysis */

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

body {
    font-family: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
    font-size: 20px;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
    margin: 0;
    padding: 0;
}

/* Typography - secon.dev style */
h1, h2, h3, h4, h5, h6 {
    font-family: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
    color: #333;
    line-height: 1.3;
    margin: 0;
}

a {
    color: #0066cc;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Top Navigation - secon.dev exact style */
.top-nav {
    position: fixed;
    top: 0;
    right: calc(50% - 600px + 60px);
    z-index: 1000;
    padding: 10px 0;
}

.top-nav a {
    color: #666;
    margin-left: 20px;
    font-size: 16px;
    text-decoration: none;
}

.top-nav a:hover {
    color: #333;
}

/* Main Container - centered single column */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 60px 20px 60px;
}

/* Site Title - large prominent heading */
.site-title {
    font-size: 120px;
    font-weight: bold;
    font-family: 'Times New Roman', 'Georgia', serif;
    text-align: center;
    margin: 40px 0 60px 0;
    color: #333;
    letter-spacing: -1px;
    line-height: 1.1;
}

.site-title a {
    color: #333;
    text-decoration: none;
}

/* Section Titles */
.section-title {
    font-size: 32px;
    font-weight: bold;
    margin: 40px 0 20px 0;
    color: #333;
}

/* Content Sections - for multiple categories */
.content-section {
    margin-bottom: 50px;
}

.content-section:first-child .section-title {
    margin-top: 0;
}

/* Section More Link */
.section-more {
    margin-top: 30px;
    text-align: center;
}

.more-link {
    color: #0066cc;
    text-decoration: none;
    font-size: 16px;
    font-weight: normal;
}

.more-link:hover {
    text-decoration: underline;
}

/* Back to top */
.back-to-top {
    margin-top: 40px;
    text-align: left;
}

/* Profile Section */
.profile-section {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
}

.profile-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.profile-info {
    flex: 1;
}

.profile-text {
    font-size: 20px;
    color: #333;
    margin: 0 0 12px 0;
    line-height: 1.6;
}

.social-links {
    display: flex;
    gap: 12px;
    align-items: center;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: #f5f5f5;
    border-radius: 50%;
    color: #666;
    text-decoration: none;
    transition: all 0.2s ease;
}

.social-link:hover {
    background-color: #0066cc;
    color: white;
    transform: translateY(-1px);
}

/* Article List - secon.dev minimal style */
.article-list {
    margin-bottom: 40px;
}

.article-item {
    margin-bottom: 20px;
    border-bottom: none;
    padding-bottom: 0;
}

.article-date {
    font-size: 16px;
    color: #999;
    margin-bottom: 4px;
}

.article-date .char-count {
    color: #ccc;
    margin-left: 8px;
}

.article-title {
    font-size: 20px;
    font-weight: normal;
    line-height: 1.4;
    margin: 0;
}

.article-title a {
    color: #333;
    text-decoration: none;
}

.article-title a:hover {
    color: #0066cc;
}

/* Single Article Page */
.article-full {
    max-width: 1200px;
}

.article-full .article-header {
    margin-bottom: 30px;
    text-align: left;
}

.article-full .article-title {
    font-size: 2em;
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.3;
}

.article-full .article-meta {
    font-size: 16px;
    color: #999;
    margin-bottom: 30px;
    text-align: right;
}

.article-full .article-content {
    color: #333;
    font-size: 20px;
    line-height: 1.7;
}

.article-full .article-content h1,
.article-full .article-content h2,
.article-full .article-content h3 {
    margin-top: 40px;
    margin-bottom: 16px;
    font-weight: bold;
}

.article-full .article-content h2 {
    font-size: 24px;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
}

.article-full .article-content p {
    margin-bottom: 16px;
}

.article-full .article-content img {
    max-width: 100%;
    height: auto;
    margin: 20px 0;
}

.article-full .article-content pre {
    background-color: #2d3748;
    color: #e2e8f0;
    padding: 16px;
    border-radius: 4px;
    overflow-x: auto;
    margin: 20px 0;
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 16px;
    line-height: 1.4;
}

.article-full .article-content code {
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 16px;
}

.article-full .article-content pre code {
    background-color: transparent;
    padding: 0;
    color: inherit;
}

.article-full .article-content blockquote {
    border-left: 4px solid #ddd;
    padding-left: 16px;
    margin: 20px 0;
    color: #666;
}

.article-full .article-content ul,
.article-full .article-content ol {
    margin: 16px 0;
    padding-left: 0;
    list-style-position: inside;
}

.article-full .article-content ul li,
.article-full .article-content ol li {
    margin-bottom: 8px;
    padding-left: 0;
}

/* Photos page - black background grid */
.photos-container {
    background-color: #000;
    min-height: 100vh;
    padding: 60px 20px 20px 20px;
}

.photos-container .site-title {
    color: #fff;
}

.photos-container .top-nav a {
    color: #ccc;
}

.photos-container .top-nav a:hover {
    color: #fff;
}

.photos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 4px;
    max-width: 800px;
    margin: 0 auto;
}

.photo-item {
    aspect-ratio: 1;
    overflow: hidden;
    position: relative;
}

.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.2s ease;
}

.photo-item:hover img {
    transform: scale(1.05);
}

.photo-date {
    position: absolute;
    bottom: 4px;
    left: 4px;
    background-color: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 10px;
    padding: 2px 4px;
    border-radius: 2px;
}

/* Footer */
.site-footer {
    margin-top: 60px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
    color: #999;
    font-size: 16px;
}

/* Responsive Design */
@media (max-width: 1280px) {
    .container {
        max-width: 100%;
        padding: 40px 30px 15px 30px;
    }
    
    .top-nav {
        right: 30px;
    }
}

@media (max-width: 768px) {
    /* Base font size for mobile - optimized for ~24 Japanese chars per line */
    body {
        font-size: 18px;
    }
    
    .container {
        padding: 40px 15px 15px 15px;
    }
    
    /* Site title - larger for mobile */
    .site-title {
        font-size: 42px;
        margin: 20px 0 30px 0;
        letter-spacing: -0.5px;
    }
    
    /* Section titles - adjusted for mobile */
    .section-title {
        font-size: 26px;
        margin: 30px 0 15px 0;
    }
    
    /* Article titles - adjusted for mobile */
    .article-title {
        font-size: 18px;
    }
    
    /* Article full page - adjusted titles and text */
    .article-full .article-title {
        font-size: 28px;
    }
    
    .article-full .article-content {
        font-size: 18px;
    }
    
    .article-full .article-content h2 {
        font-size: 22px;
    }
    
    /* Code blocks - match mobile font size */
    .article-full .article-content pre {
        font-size: 16px;
    }
    
    .article-full .article-content code {
        font-size: 16px;
    }
    
    /* Profile text - adjusted for mobile */
    .profile-text {
        font-size: 18px;
    }
    
    .top-nav {
        position: static;
        text-align: center;
        padding: 20px 0;
        border-bottom: 1px solid #eee;
    }
    
    .top-nav a {
        margin: 0 15px;
        font-size: 14px;
    }
    
    .photos-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    }
    
    .profile-section {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .profile-image {
        width: 60px;
        height: 60px;
    }
    
    .social-links {
        justify-content: center;
    }
}

/* Extra small mobile devices */
@media (max-width: 480px) {
    /* Optimized text size for very small screens - still ~24 Japanese chars per line */
    body {
        font-size: 16px;
    }
    
    .site-title {
        font-size: 32px;
        margin: 15px 0 25px 0;
    }
    
    .section-title {
        font-size: 22px;
        margin: 25px 0 12px 0;
    }
    
    .article-title {
        font-size: 16px;
    }
    
    .article-full .article-title {
        font-size: 24px;
    }
    
    .article-full .article-content {
        font-size: 16px;
    }
    
    .article-full .article-content h2 {
        font-size: 20px;
    }
    
    /* Code blocks - match small mobile font size */
    .article-full .article-content pre {
        font-size: 14px;
    }
    
    .article-full .article-content code {
        font-size: 14px;
    }
    
    .profile-text {
        font-size: 16px;
    }
    
    .top-nav a {
        font-size: 13px;
        margin: 0 12px;
    }
    
    .container {
        padding: 30px 10px 10px 10px;
    }
}

/* No articles message */
.no-articles {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 60px 0;
}