/* Google Fonts Alef is loaded via HTML link tag for better reliability */

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

html {
    direction: rtl;
    font-family: 'Alef', 'Noto Sans Hebrew', 'Arial Hebrew', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
}

body {
    background-color: #ffffff;
    color: #333333;
    max-width: 660px;
    margin: 0 auto;
    padding: 20px;
}

/* Full width layout for index page only */
body.index-page {
    max-width: 100%;
    padding: 20px 40px;
}

body.index-page main,
body.index-page .index-header,
body.index-page .authors-grid,
body.index-page .index-stats {
    max-width: 100%;
    width: 100%;
}

/* Header Styles */
.site-header {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
    gap: 20px;
}

.site-logo-link {
    text-decoration: none;
    flex-shrink: 0;
    margin-top: -6px; /* Align logo center with main title center only */
}

.site-logo {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    transition: opacity 0.3s ease;
}

.site-logo-link:hover .site-logo {
    opacity: 0.8;
}

.site-header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.site-title-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: opacity 0.3s ease;
}

.site-title-link:hover {
    opacity: 0.8;
}

.site-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
    line-height: 1.2;
}

.site-subtitle {
    font-size: 1.1rem;
    color: #7f8c8d;
    font-weight: 400;
}

/* Author Page Styles */
.author-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 30px;
    background: transparent;
    color: #333333;
}

.author-avatar {
    margin-bottom: 20px;
}

.avatar-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.author-header h1 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #333333;
}

.author-header .author-subtitle {
    font-size: 1.1rem;
    color: #555555;
    line-height: 1.6;
    margin-top: 15px;
}

.author-header .author-subtitle p {
    margin: 5px 0;
    font-size: 1rem;
}

.author-info {
    display: none; /* Hide the old author-info section */
}

/* Post List Styles */
.author-posts h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 25px;
    text-align: center;
    position: relative;
}

.author-posts h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 50%;
    transform: translateX(50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
}

.post-item {
    background-color: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.post-item:hover {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.post-item h3 {
    margin-bottom: 10px;
}

.post-item h3 a {
    color: #2c3e50;
    text-decoration: none;
    font-size: 1.3rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.post-item h3 a:hover {
    color: #667eea;
}

.post-date, .post-tags {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 5px;
}

.post-note {
    font-size: 0.85rem;
    color: #28a745;
    font-weight: 600;
    background-color: #d4edda;
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
}

/* Individual Post Styles */
.post-header {
    text-align: right;
    margin-bottom: 40px;
    padding: 20px 0;
}

.post-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #333333;
    line-height: 1.2;
}

.post-meta {
    font-size: 1rem;
    opacity: 0.9;
}

.post-meta p {
    margin-bottom: 8px;
}

.post-meta a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.post-meta a:hover {
    color: white;
    border-bottom-color: white;
}

.post-meta strong {
    font-weight: 600;
}

/* Post Content Styles */
.post-content {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
}

.post-content p {
    margin-bottom: 20px;
    text-align: justify;
}

.post-content br {
    line-height: 2.5;
}

.post-content figure {
    margin: 30px 0;
    text-align: center;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Navigation Styles */
.navigation {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.navigation a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.navigation a:hover {
    color: #2c3e50;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        padding: 15px;
    }
    
    .site-header {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    
    .site-logo-link {
        margin-top: 0; /* Reset margin on mobile when stacked */
    }
    
    .site-logo {
        width: 50px;
        height: 50px;
    }
    
    .site-title {
        font-size: 2rem;
    }
    
    .author-header h1 {
        font-size: 1.8rem;
    }
    
    .post-header h1 {
        font-size: 2rem;
    }
    
    .post-content {
        font-size: 1rem;
    }
    
    .avatar-image {
        width: 100px;
        height: 100px;
    }
}

@media (max-width: 480px) {
    .site-header {
        gap: 10px;
    }
    
    .site-logo {
        width: 40px;
        height: 40px;
    }
    
    .site-title {
        font-size: 1.6rem;
    }
    
    .author-header h1 {
        font-size: 1.5rem;
    }
    
    .post-header h1 {
        font-size: 1.6rem;
    }
    
    .post-header, .author-header {
        padding: 20px 15px;
    }
}
/* Index Page Styles */
.index-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px 20px;
    background: transparent;
    color: #333333;
}

.index-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: #333333;
}

.index-description {
    font-size: 1.1rem;
    color: #555555;
    line-height: 1.6;
}

.authors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 50px;
}

.author-card {
    background-color: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.author-card:hover {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.author-card-name {
    margin-bottom: 15px;
}

.author-card-name a {
    color: #2c3e50;
    text-decoration: none;
    font-size: 1.4rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.author-card-name a:hover {
    color: #667eea;
}

.author-card-stats p {
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: #6c757d;
}

.author-card-stats strong {
    color: #2c3e50;
    font-weight: 600;
}

.index-stats {
    text-align: center;
    margin-top: 50px;
    padding: 30px;
    background-color: #f8f9fa;
    border-radius: 15px;
    border-right: 4px solid #667eea;
}

.index-stats h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 25px;
}

.stats-grid {
    display: flex;
    justify-content: center;
    gap: 50px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #667eea;
    line-height: 1;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 1.1rem;
    color: #7f8c8d;
    font-weight: 400;
}

footer {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 2px solid #f0f0f0;
    text-align: center;
}

.footer-text {
    color: #7f8c8d;
    font-size: 0.9rem;
}

/* Responsive Design for Index */
@media (max-width: 768px) {
    .index-header h1 {
        font-size: 2rem;
    }
    
    .authors-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .stats-grid {
        flex-direction: column;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .index-header {
        padding: 20px 15px;
    }
    
    .index-header h1 {
        font-size: 1.6rem;
    }
    
    .author-card {
        padding: 15px;
    }
    
    .stat-number {
        font-size: 2rem;
    }
}

