/* ========================================
   MOBILE-FIRST OPTIMIZATION FOR EXISTING JAMARK CONTENT
   Add this to your style.css file
   ======================================== */

/* Mobile-First Base Styles */
.homepage-section {
    padding: 40px 0;
    background-color: #fff;
}

.homepage-section:nth-child(even) {
    background-color: #f9f9f4;
}

.homepage-section h2 {
    font-size: 1.8em;
    color: #2d4b2d;
    text-align: center;
    margin-bottom: 30px;
    font-weight: 600;
}

/* Mobile-First Grid - Vertical Stacking */
.homepage-grid {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 30px;
}

/* Project Cards - Mobile First */
.project-card-home {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e9ecef;
}

.project-card-home:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.project-card-home img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.project-card-home .card-content {
    padding: 20px;
}

.project-card-home h3 {
    font-size: 1.3em;
    color: #2d4b2d;
    margin-bottom: 10px;
    font-weight: 600;
    line-height: 1.3;
}

.project-card-home .meta {
    color: #8b5e3c;
    font-size: 0.9em;
    margin-bottom: 12px;
    font-weight: 500;
}

.project-card-home p:not(.meta) {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 0.95em;
}

.view-project-btn {
    display: inline-block;
    background-color: #5c8a3d;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.9em;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.view-project-btn:hover {
    background-color: #4e7730;
}

/* Testimonial Cards - Mobile First */
.testimonial-snippet {
    background: #fff;
    padding: 25px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    border-left: 4px solid #8b5e3c;
    transition: transform 0.3s ease;
}

.testimonial-snippet:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.testimonial-quote {
    font-style: italic;
    font-size: 1.05em;
    line-height: 1.6;
    color: #444;
    margin-bottom: 20px;
    position: relative;
}

.testimonial-quote::before {
    content: '"';
    font-size: 2.5em;
    color: #8b5e3c;
    position: absolute;
    top: -10px;
    left: -5px;
    opacity: 0.3;
    font-family: serif;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-avatar {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, #2d4b2d, #5c8a3d);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1em;
    font-weight: bold;
    flex-shrink: 0;
}

.author-info h4 {
    margin: 0;
    color: #2d4b2d;
    font-size: 1em;
    font-weight: 600;
}

.author-info p {
    margin: 2px 0 0 0;
    color: #666;
    font-size: 0.85em;
}

/* Blog Cards - Mobile First */
.blog-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e9ecef;
}

.blog-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.blog-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.blog-card .card-content {
    padding: 20px;
}

.blog-card h3 {
    font-size: 1.2em;
    color: #2d4b2d;
    margin-bottom: 8px;
    font-weight: 600;
    line-height: 1.3;
}

.blog-card .meta {
    color: #8b5e3c;
    font-size: 0.85em;
    margin-bottom: 12px;
}

.blog-card p:not(.meta) {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 0.9em;
}

.read-more-btn {
    display: inline-block;
    background-color: #8b5e3c;
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.85em;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.read-more-btn:hover {
    background-color: #734b2e;
}

/* User Auth Buttons - Mobile First */
.user-auth {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
    padding: 30px 0;
    background-color: #f4f3ec;
}

.btn-login,
.btn-join {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1em;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 200px;
    text-align: center;
}

.btn-login {
    background-color: #5c8a3d;
    color: white;
    border: 2px solid #5c8a3d;
}

.btn-login:hover {
    background-color: #4e7730;
    border-color: #4e7730;
    transform: translateY(-2px);
}

.btn-join {
    background-color: #8b5e3c;
    color: white;
    border: 2px solid #8b5e3c;
}

.btn-join:hover {
    background-color: #734b2e;
    border-color: #734b2e;
    transform: translateY(-2px);
}

/* Services Container - Mobile First */
.services-container {
    padding: 0 20px;
}

/* No Content Styling */
.no-content {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    background: #f8f9fa;
    border-radius: 12px;
}

.no-content h3 {
    color: #2d4b2d;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.no-content p {
    font-size: 1em;
    line-height: 1.6;
}

/* ========================================
   TABLET RESPONSIVE (min-width: 768px)
   ======================================== */
@media (min-width: 768px) {
    .homepage-section {
        padding: 60px 0;
    }
    
    .homepage-section h2 {
        font-size: 2.2em;
        margin-bottom: 40px;
    }
    
    /* 2-column grid for tablets */
    .homepage-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .user-auth {
        flex-direction: row;
        justify-content: center;
        gap: 20px;
    }
    
    .btn-login,
    .btn-join {
        width: auto;
        min-width: 180px;
    }
    
    .project-card-home img,
    .blog-card img {
        height: 220px;
    }
    
    .testimonial-quote {
        font-size: 1.1em;
    }
    
    .author-avatar {
        width: 50px;
        height: 50px;
        font-size: 1.2em;
    }
}

/* ========================================
   DESKTOP RESPONSIVE (min-width: 1024px)
   ======================================== */
@media (min-width: 1024px) {
    .homepage-section {
        padding: 80px 0;
    }
    
    .homepage-section h2 {
        font-size: 2.5em;
        margin-bottom: 50px;
    }
    
    /* 3-column grid for desktop */
    .homepage-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 35px;
    }
    
    .project-card-home,
    .blog-card {
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }
    
    .project-card-home:hover,
    .blog-card:hover {
        transform: translateY(-8px);
    }
    
    .project-card-home img,
    .blog-card img {
        height: 240px;
    }
    
    .testimonial-snippet {
        padding: 30px 25px;
    }
    
    .testimonial-quote {
        font-size: 1.15em;
        margin-bottom: 25px;
    }
    
    .user-auth {
        padding: 40px 0;
    }
}

/* ========================================
   LARGE DESKTOP (min-width: 1200px)
   ======================================== */
@media (min-width: 1200px) {
    .homepage-section {
        padding: 100px 0;
    }
    
    .homepage-grid {
        gap: 40px;
    }
    
    .project-card-home .card-content,
    .blog-card .card-content {
        padding: 25px;
    }
    
    .testimonial-snippet {
        padding: 35px 30px;
    }
    
    .project-card-home h3,
    .blog-card h3 {
        font-size: 1.4em;
    }
}

/* ========================================
   ACCESSIBILITY & UTILITIES
   ======================================== */

/* Focus states for keyboard navigation */
.view-project-btn:focus,
.read-more-btn:focus,
.btn-login:focus,
.btn-join:focus {
    outline: 3px solid rgba(92, 138, 61, 0.5);
    outline-offset: 2px;
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    .project-card-home,
    .blog-card,
    .testimonial-snippet,
    .btn-login,
    .btn-join {
        transition: none;
    }
    
    .project-card-home:hover,
    .blog-card:hover,
    .testimonial-snippet:hover,
    .btn-login:hover,
    .btn-join:hover {
        transform: none;
    }
}

/* Print styles */
@media print {
    .user-auth,
    .view-project-btn,
    .read-more-btn {
        display: none;
    }
    
    .homepage-section {
        padding: 20px 0;
    }
    
    .homepage-grid {
        gap: 20px;
    }
}