/*
Theme Name: Astra Child
Description: Simple child theme for custom homepage
Template: astra
Version: 1.0.21
*/

/* Global Site Background */
body {
    background-color: #e0f2f7; /* Light blue background */
}

/* Fix flex direction issue for homepage sections */
.home .homepage-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: block;
}

/* === Section Styling - White BG + Spacing Between Sections === */
.home .homepage-section,
.home .homepage-hero {
    background-color: #ffffff;
    margin-bottom: 60px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
    .home .homepage-section,
    .home .homepage-hero {
        margin-bottom: 40px;
    }
}

/* === Homepage Hero / About Me Section - Modern Design === */
.home .homepage-hero {
    background-color: #ffffff; /* White background */
    color: #1a202c; /* Dark gray for readability */
    padding: 1em 0;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05); /* Softer shadow */
}

.home .homepage-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 70%, rgba(255,255,255,0.05) 0%, transparent 60%);
    pointer-events: none;
    z-index: 1;
}

.home .hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.home .about-intro {
    margin-bottom: 2rem;
}

.home .intro-label {
    display: inline-block;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--ast-global-color-0, #046bd2);
    position: relative;
    padding-left: 20px;
    margin-top: 12px;
}

.home .intro-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 2px;
    background: var(--ast-global-color-0, #046bd2);
}

.home .hero-title {
    font-size: clamp(2.5rem, 5vw, 3rem);
    font-weight: 700;
    margin-bottom: 0rem;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: #1a202c;
}

.home .hero-subtitle {
    font-size: clamp(1.3rem, 2.5vw, 1.6rem);
    font-weight: 500;
    color: #4a5568;
    margin-bottom: 2rem;
}

.home .hero-description {
    color: #4a5568; /* Readable on white */
}

.home .stat-label {
    color: #718096; /* Muted label text */
}

.home .hero-cta a.primary {
    background-color: var(--ast-global-color-0, #046bd2);
    color: #fff;
}

.home .hero-cta a.secondary {
    color: var(--ast-global-color-0, #046bd2);
    border-color: var(--ast-global-color-0, #046bd2);
}

.home .hero-cta {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 2rem;
}

.home .hero-cta a.cta-button {
    display: inline-block;
    padding: 14px 30px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.home .hero-cta a.primary {
    background-color: var(--ast-global-color-0, #046bd2);
    color: #fff;
    border: none;
}

.home .hero-cta a.primary:hover {
    background-color: var(--ast-global-color-1, #045cb4);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(4, 107, 210, 0.3);
}

.home .hero-cta a.secondary {
    background-color: transparent;
    color: var(--ast-global-color-0, #046bd2);
    border: 2px solid var(--ast-global-color-0, #046bd2);
}

.home .hero-cta a.secondary:hover {
    background-color: var(--ast-global-color-0, #046bd2);
    color: #fff;
    border-color: var(--ast-global-color-0, #046bd2);
    transform: translateY(-2px);
}


.home .about-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
}

.home .about-image {
    flex: 1 1 300px;
    max-width: 350px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.home .about-image:hover {
    transform: scale(1.03);
}

.home .about-image img,
.home .about-image .profile-placeholder {
    width: 100%;
    height: auto;
    display: block;
}

.home .about-text {
    flex: 1 1 400px;
}

/* === General Homepage Section Styling === */
.home .homepage-section {
    padding: 2em 0;
}

.home .section-header {
    text-align: center;
    margin-bottom: 2em;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.home .section-title {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--ast-global-color-2, #1a202c);
    letter-spacing: -0.025em;
    position: relative;
}

.home .section-title::after {
    content: '';
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--ast-global-color-0, #046bd2), var(--ast-global-color-1, #045cb4));
    display: block;
    margin: 20px auto 0;
    border-radius: 2px;
}

.home .section-description {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--ast-global-color-3, #6b7280);
    line-height: 1.6;
    font-weight: 400;
    opacity: 0.8;
}

/* === Posts Grid - Override Astra's layout for homepage === */
.home .posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr));
    gap: clamp(30px, 5vw, 40px);
    margin-bottom: clamp(40px, 6vw, 60px);
}

/* === Post Card Styling === */
.home .posts-grid .ast-article-post {
    width: 100%;
    margin-bottom: 0;
    background: var(--ast-global-color-4, #ffffff);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--ast-border-color, rgba(0,0,0,0.05));
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 0;
}

.home .posts-grid .ast-article-post::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--ast-global-color-0, #046bd2), var(--ast-global-color-1, #045cb4));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 2;
}

.home .posts-grid .ast-article-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.home .posts-grid .ast-article-post:hover::before {
    opacity: 1;
}

.home .posts-grid .ast-article-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    padding: 0;
}

/* === Featured Image Styling === */
.home .posts-grid .ast-blog-featured-section {
    height: 220px;
    overflow: hidden;
    flex-shrink: 0;
}

.home .posts-grid .ast-blog-featured-section .post-thumb-img-content img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.home .posts-grid .ast-article-post:hover .ast-blog-featured-section .post-thumb-img-content img {
    transform: scale(1.05);
}

/* === Post Content Area === */
.home .posts-grid .post-content {
    padding: clamp(24px, 4vw, 32px);
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* === Section CTA Button === */
.home .section-cta {
    text-align: center;
    margin-top: clamp(40px, 6vw, 60px);
}

.home .view-all-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: transparent;
    color: var(--ast-global-color-0, #046bd2);
    border: 2px solid var(--ast-global-color-0, #046bd2);
    padding: 16px 32px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.home .view-all-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--ast-global-color-0, #046bd2);
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
}

.home .view-all-link:hover {
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(4, 107, 210, 0.3);
}

.home .view-all-link:hover::before {
    left: 0;
}

.home .view-all-link .arrow {
    transition: transform 0.3s ease;
    font-weight: normal;
}

.home .view-all-link:hover .arrow {
    transform: translateX(4px);
}

/* === No Posts Message === */
.home .no-posts {
    text-align: center;
    padding: 40px 20px;
    color: var(--ast-global-color-3, #6b7280);
    font-style: italic;
    grid-column: 1 / -1;
}

/* === Animation for posts === */
.home .posts-grid .ast-article-post {
    animation: fadeInUp 0.6s ease forwards;
    animation-fill-mode: backwards;
}

.home .posts-grid .ast-article-post:nth-child(1) { animation-delay: 0.1s; }
.home .posts-grid .ast-article-post:nth-child(2) { animation-delay: 0.2s; }
.home .posts-grid .ast-article-post:nth-child(3) { animation-delay: 0.3s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
