/* ========================================
   SHIFT CALCULATOR BLOG - COMPLETE STYLESHEET
   File: blog.css
   Version: 1.0
   Description: Standalone CSS for blog and articles
   ======================================== */

/* Global Reset & Base Styles for Blog */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

/* Navigation Bar */
nav {
    background: rgba(255,255,255,0.98);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5em;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    cursor: pointer;
}

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

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
}

.nav-links a {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

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

.nav-links a.active {
    color: #667eea;
    font-weight: 600;
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
    color: #333;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Section */
header {
    text-align: center;
    color: white;
    padding: 40px 20px;
}

h1 {
    font-size: 3em;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.subtitle {
    font-size: 1.2em;
    opacity: 0.95;
    margin-bottom: 15px;
}

/* Breadcrumb Navigation */
.breadcrumb {
    font-size: 0.9em;
    opacity: 0.9;
    margin-top: 10px;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.breadcrumb a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.breadcrumb span {
    color: rgba(255,255,255,0.8);
}

/* Featured Blog Post */
.blog-post {
    background: white;
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 40px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.featured-post {
    border: 3px solid #667eea;
}

.featured-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 70px rgba(102, 126, 234, 0.25);
}

.post-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 8px 18px;
    border-radius: 25px;
    font-size: 0.85em;
    font-weight: 600;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
    z-index: 10;
}

.post-image {
    width: 100%;
    height: 300px;
    border-radius: 15px;
    margin-bottom: 25px;
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 0.9em;
    color: #666;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.post-date,
.post-category,
.post-reading-time {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
}

.post-category {
    color: #667eea;
    font-weight: 600;
}

.blog-post h2 {
    color: #333;
    margin-bottom: 20px;
    font-size: 2.2em;
    line-height: 1.3;
    font-weight: 700;
}

.post-excerpt {
    font-size: 1.15em;
    color: #555;
    margin-bottom: 25px;
    line-height: 1.8;
    font-weight: 400;
}

/* Post Content Styling */
.post-content {
    margin-top: 30px;
    line-height: 1.9;
    color: #333;
}

.post-content h3 {
    color: #667eea;
    margin-top: 35px;
    margin-bottom: 18px;
    font-size: 1.7em;
    font-weight: 600;
}

.post-content h4 {
    color: #333;
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 1.3em;
    font-weight: 600;
}

.post-content p {
    margin-bottom: 18px;
    color: #444;
    font-size: 1.05em;
}

.post-content ul,
.post-content ol {
    margin: 20px 0;
    padding-left: 30px;
}

.post-content li {
    margin-bottom: 12px;
    color: #444;
    line-height: 1.8;
}

.post-content li strong {
    color: #667eea;
    font-weight: 600;
}

.post-content a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease;
}

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

/* Code Blocks in Posts */
.post-content code {
    background: #f5f7fa;
    padding: 3px 8px;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #667eea;
    border: 1px solid #e0e0e0;
}

.post-content pre {
    background: #2d3748;
    padding: 20px;
    border-radius: 12px;
    overflow-x: auto;
    margin: 25px 0;
}

.post-content pre code {
    background: none;
    padding: 0;
    border: none;
    color: #e2e8f0;
}

/* Blockquotes in Posts */
.post-content blockquote {
    border-left: 5px solid #667eea;
    padding-left: 25px;
    margin: 25px 0;
    font-style: italic;
    color: #555;
    background: #f5f7fa;
    padding: 20px 25px;
    border-radius: 8px;
}

/* Tables in Posts */
.post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    border-radius: 10px;
    overflow: hidden;
}

.post-content th,
.post-content td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.post-content th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
}

.post-content tr:hover {
    background: #f5f7fa;
}

.post-content tr:last-child td {
    border-bottom: none;
}

/* Read More Button */
.read-more-btn {
    display: inline-block;
    margin-top: 25px;
    padding: 14px 32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1.05em;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

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

/* Blog Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

/* Blog Card */
.blog-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.15);
}

.blog-card .post-image {
    height: 200px;
    margin-bottom: 0;
    border-radius: 0;
}

.blog-card-content {
    padding: 25px;
}

.blog-card h3 {
    color: #333;
    margin-bottom: 12px;
    font-size: 1.35em;
    line-height: 1.4;
    font-weight: 600;
}

.blog-card p {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.7;
    font-size: 0.95em;
}

/* Post Tags */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.tag {
    background: #f5f7fa;
    color: #667eea;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
    border: 2px solid #e0e0e0;
    transition: all 0.3s ease;
}

.tag:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* Content Section */
.content-section {
    background: white;
    border-radius: 20px;
    padding: 40px;
    margin: 30px 0;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.content-section h2 {
    color: #667eea;
    font-size: 2em;
    margin-bottom: 30px;
    font-weight: 700;
}

/* Category Grid */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.category-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 20px;
    padding: 35px;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 3px solid transparent;
}

.category-card:hover {
    transform: translateY(-10px);
    border-color: #667eea;
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.2);
}

.category-icon {
    font-size: 3.5em;
    margin-bottom: 15px;
}

.category-card h3 {
    color: #333;
    margin-bottom: 8px;
    font-size: 1.4em;
    font-weight: 600;
}

.category-card p {
    color: #666;
    font-size: 0.95em;
    font-weight: 500;
}

/* Newsletter Section */
.newsletter-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 50px 40px;
    margin: 50px 0;
    text-align: center;
    color: white;
    box-shadow: 0 20px 60px rgba(102, 126, 234, 0.3);
}

.newsletter-content h2 {
    color: white;
    margin-bottom: 15px;
    font-size: 2.2em;
    font-weight: 700;
}

.newsletter-content p {
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 30px;
    font-size: 1.15em;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.newsletter-form {
    display: flex;
    gap: 15px;
    max-width: 600px;
    margin: 0 auto 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.newsletter-input {
    flex: 1;
    min-width: 280px;
    padding: 16px 20px;
    border: none;
    border-radius: 12px;
    font-size: 1em;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.newsletter-input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255,255,255,0.3);
    transform: translateY(-2px);
}

.newsletter-btn {
    padding: 16px 40px;
    background: white;
    color: #667eea;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.05em;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.newsletter-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.newsletter-privacy {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.85em;
    margin-top: 15px;
}

/* Resources Grid */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.resource-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 15px;
    padding: 30px;
    text-decoration: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border-left: 5px solid #667eea;
}

.resource-card:hover {
    transform: translateX(10px);
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.2);
}

.resource-card h4 {
    color: #333;
    margin-bottom: 12px;
    font-size: 1.3em;
    font-weight: 600;
}

.resource-card p {
    color: #666;
    font-size: 1em;
    line-height: 1.6;
}

/* Footer */
footer {
    background: rgba(0,0,0,0.9);
    color: white;
    padding: 40px 20px 20px;
    margin-top: 50px;
}

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

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

.footer-section h3 {
    margin-bottom: 15px;
    font-size: 1.2em;
    color: white;
}

.footer-section p {
    color: #ccc;
    line-height: 1.6;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

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

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

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
    color: #999;
    font-size: 0.9em;
}

.footer-bottom p {
    margin-bottom: 5px;
}

/* Share Buttons */
.share-buttons {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 2px solid #f0f0f0;
    flex-wrap: wrap;
}

.share-btn {
    padding: 12px 24px;
    border-radius: 10px;
    text-decoration: none;
    font-size: 0.95em;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.share-btn.twitter {
    background: #1DA1F2;
    color: white;
}

.share-btn.facebook {
    background: #4267B2;
    color: white;
}

.share-btn.linkedin {
    background: #0077b5;
    color: white;
}

.share-btn.email {
    background: #667eea;
    color: white;
}

/* Animations */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.blog-post,
.blog-card {
    animation: slideIn 0.6s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
    h1 {
        font-size: 2em;
    }

    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .blog-post {
        padding: 25px;
    }

    .blog-post h2 {
        font-size: 1.7em;
    }

    .post-excerpt {
        font-size: 1em;
    }

    .post-content h3 {
        font-size: 1.4em;
    }

    .post-meta {
        gap: 12px;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }

    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .newsletter-section {
        padding: 35px 25px;
    }

    .newsletter-content h2 {
        font-size: 1.7em;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .newsletter-input,
    .newsletter-btn {
        width: 100%;
        min-width: 100%;
    }

    .resources-grid {
        grid-template-columns: 1fr;
    }

    .content-section {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.5em;
    }

    .post-badge {
        top: 10px;
        right: 10px;
        padding: 6px 12px;
        font-size: 0.75em;
    }

    .blog-post {
        padding: 20px;
    }

    .blog-post h2 {
        font-size: 1.4em;
    }

    .post-meta {
        flex-direction: column;
        gap: 8px;
    }

    .category-grid {
        grid-template-columns: 1fr;
    }

    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Print Styles for Blog Posts */
@media print {
    body {
        background: white;
    }

    .post-badge,
    .read-more-btn,
    .newsletter-section,
    nav,
    footer,
    .share-buttons {
        display: none;
    }

    .blog-post {
        box-shadow: none;
        border: 1px solid #e0e0e0;
        page-break-inside: avoid;
    }

    .post-content {
        color: black;
    }

    .post-content a {
        color: black;
        text-decoration: underline;
    }
}

/* Dark Mode Support (Optional) */
@media (prefers-color-scheme: dark) {
    body {
        background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%);
    }

    .blog-card,
    .blog-post,
    .category-card,
    .resource-card,
    .content-section {
        background: #2d3748;
        color: #e2e8f0;
    }

    .blog-post h2,
    .blog-card h3,
    .category-card h3,
    .post-content h3,
    .post-content h4 {
        color: #667eea;
    }

    .blog-card p,
    .post-excerpt,
    .post-content p,
    .post-content li {
        color: #cbd5e0;
    }

    .tag {
        background: #374151;
        border-color: #4b5563;
        color: #a5b4fc;
    }

    nav {
        background: rgba(45, 55, 72, 0.98);
    }

    .nav-links a {
        color: #e2e8f0;
    }
}