/* --- Master Canvas Settings --- */
.shahzad-platform-canvas {
    max-width: 1050px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    padding: 0 24px;
    background: #ffffff;
}

.homepage-section {
    padding: 60px 0;
}

.section-header-block {
    margin-bottom: 40px;
    text-align: left;
}

.platform-section-title {
    font-size: 1.85rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 10px 0;
    letter-spacing: -0.5px;
}

.platform-section-subtitle {
    font-size: 1.05rem;
    color: #475569;
    margin: 0;
    max-width: 750px;
    line-height: 1.5;
}

/* --- Section 1: Minimalist Post Feed Layout --- */
.blog-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.minimal-post-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.post-date {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #94a3b8;
    font-weight: 600;
    margin-bottom: 8px;
}

.post-card-title a {
    font-size: 1.15rem;
    font-weight: 600;
    color: #0f172a;
    text-decoration: none;
    line-height: 1.4;
}

.post-card-title a:hover {
    color: #4f46e5;
}

.post-card-excerpt {
    font-size: 0.9rem;
    color: #475569;
    line-height: 1.6;
    margin: 10px 0 16px 0;
}

.post-read-link {
    font-size: 0.85rem;
    font-weight: 600;
    color: #4f46e5;
    text-decoration: none;
}

/* --- Section 2: Book Split Layout & Layering --- */
.hero-content-split {
    display: flex;
    align-items: center;
    gap: 60px;
}

.hero-visual-zone {
  flex: 1;
  position: relative;
  min-height: 460px; /* Slightly taller to give the elements breathing room */
  display: flex;
  align-items: flex-start; /* Aligns the primary book container higher up */
  justify-content: flex-start;
}

.book-layer {
  position: absolute;
  left: 15px;
  top: 10px;
  z-index: 1; /* Sits cleanly in the background layer */
}

.img-book-cover {
  width: 270px; /* Made larger to take command of the left column space */
  height: auto;
  border-radius: 6px;
  box-shadow: 12px 20px 40px rgba(0, 0, 0, 0.22); /* Deeper drop shadow for premium depth */
}

.app-screenshot-layer {
  position: absolute;
  right: -15px; /* Pushes the mockup out slightly into the center gap */
  bottom: -10px; /* Brings it down to sit directly next to the codebase tags */
  width: 310px;  /* Proportional size so it doesn't swallow the larger book cover */
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  z-index: 2; /* Forces the app to overlap on top of the book cover's bottom corner */
}

.window-header {
    background: #f1f5f9;
    padding: 6px 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid #e2e8f0;
}

.window-header .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #cbd5e1;
}

.window-title {
    font-size: 0.7rem;
    color: #64748b;
    margin-left: 8px;
    font-family: monospace;
}

.img-app-screen {
    width: 100%;
    height: auto;
    display: block;
}

.hero-text-zone {
    flex: 1.2;
}

.hero-headline {
    font-size: 2.25rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.2;
    margin: 0 0 16px 0;
    letter-spacing: -0.5px;
}

.hero-lead {
    font-size: 1.1rem;
    color: #334155;
    font-weight: 500;
    line-height: 1.5;
    margin: 0 0 16px 0;
}

.hero-body {
    font-size: 0.95rem;
    color: #64748b;
    line-height: 1.6;
    margin: 0 0 28px 0;
}

/* --- Direct PDF and KDP Purchase Buttons --- */
.hero-action-buttons {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 36px;
    flex-wrap: wrap;
}

.btn-hero-primary {
    background: #0f172a;
    color: #ffffff;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.2s;
}

.btn-hero-primary:hover {
    background: #4f46e5;
}

.btn-hero-secondary {
    background: #ffffff;
    color: #0f172a;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid #cbd5e1;
    transition: background 0.2s;
}

.btn-hero-secondary:hover {
    background: #f8fafc;
    border-color: #94a3b8;
}

.btn-chapter-link {
    font-size: 0.9rem;
    font-weight: 600;
    color: #4f46e5;
    text-decoration: none;
    margin-left: 8px;
}

/* --- GitHub Tags --- */
.hero-github-footer {
    border-top: 1px solid #edf2f7;
    padding-top: 20px;
}

.github-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #94a3b8;
    font-weight: 600;
    display: block;
    margin-bottom: 10px;
}

.repo-tag-group {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.repo-tag {
    font-size: 0.78rem;
    font-weight: 500;
    background: #f1f5f9;
    color: #334155;
    padding: 5px 10px;
    border-radius: 4px;
    text-decoration: none;
    border: 1px solid #e2e8f0;
}

.repo-tag:hover {
    background: #e2e8f0;
    color: #0f172a;
}

/* --- Section 3: Dynamic Course Rows & Stats Container --- */

/* Core course row alignment and style */
.premium-course-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 32px 0;
  border-bottom: 1px solid #e2e8f0;
  gap: 40px;
}

/* This targets the absolute last row and strips its line out completely */
.premium-course-row:last-of-type {
  border-bottom: none;
  padding-bottom: 0; /* Tightens space to keep the layout feeling neat */
}

.row-left-content {
    flex: 1;
}

.row-heading-line {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.course-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0;
}

.platform-pill {
    font-size: 0.78rem;
    font-weight: 500;
    background-color: #f1f5f9;
    color: #475569;
    padding: 3px 8px;
    border-radius: 4px;
}

.platform-pill.certification {
    background-color: #e0f2fe;
    color: #0369a1;
}

.course-summary {
    font-size: 0.95rem;
    color: #334155;
    line-height: 1.5;
    margin: 0 0 12px 0;
    max-width: 700px;
}

.course-specifications {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 0.82rem;
}

.spec-rating {
    color: #d97706;
    font-weight: 700;
}

.spec-text {
    color: #64748b;
}

.spec-divider {
    color: #cbd5e1;
}

.spec-promo {
    color: #16a34a;
    font-weight: 600;
    background-color: #f0fdf4;
    padding: 1px 6px;
    border-radius: 4px;
}

.row-right-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    min-width: 200px;
}

.enrollment-metric {
    font-size: 0.8rem;
    color: #94a3b8;
}

.btn-hub-primary {
    display: inline-block;
    background: #0f172a;
    color: #ffffff;
    text-decoration: none;
    padding: 11px 20px;
    border-radius: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    width: 100%;
    box-sizing: border-box;
}

.btn-hub-primary:hover {
    background: #4f46e5;
}

/* --- Divider & Circles --- */
.platform-metrics-divider {
    margin-top: 100px;
    text-align: center;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px dashed #cbd5e1;
    line-height: 0.1em;
}

.metrics-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #94a3b8;
    background: #ffffff;
    padding: 0 15px;
    display: inline-block;
    margin: 0;
}

.course-stats-container {
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 24px;
    padding: 50px 10px 10px 10px;
}

.stat-item {
    flex: 1;
    min-width: 200px;
    max-width: 260px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    margin-bottom: 16px;
}

.circle-coral {
    border: 2.5px solid #fca5a5;
}

.circle-green {
    border: 2.5px solid #86efac;
}

.circle-blue {
    border: 2.5px solid #93c5fd;
}

.stat-number {
    font-size: 2.1rem;
    font-weight: 300;
    color: #1e293b;
}

.stat-label {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    color: #475569;
    margin-bottom: 6px;
}

.stat-description {
    font-size: 0.88rem;
    line-height: 1.5;
    color: #64748b;
    margin: 0;
}

/* --- Responsive Breakpoints --- */
@media (max-width: 900px) {
    .hero-content-split {
        flex-direction: column-reverse;
        gap: 40px;
    }

    .hero-visual-zone {
        width: 100%;
        min-height: 340px;
    }

    .blog-posts-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .premium-course-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .premium-course-row:last-of-type {
    border-bottom: none;
    padding-bottom: 0; /* Tightens space to keep the layout feeling neat */
    }

    .row-right-actions {
        align-items: flex-start;
        width: 100%;
    }

    .course-stats-container {
        flex-direction: column;
        align-items: center;
        gap: 40px;
    }
}

/* --- Horizontal Blog Row Containers --- */
.blog-posts-rows-container {
    display: flex;
    flex-direction: column;
}

.premium-post-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 28px 0;
    border-bottom: 1px solid #e2e8f0;
    gap: 32px;
    transition: border-color 0.25s ease;
}

.premium-post-row:hover {
    border-bottom-color: #6366f1;
    /* Matches the subtle interactive shift of your courses */
}

/* Left Date Block */
.post-row-left-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 8px;
    border-radius: 6px;
    text-align: center;
}

.post-meta-month {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    color: #475569;
}

.post-meta-year {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 500;
}

/* Center Content Block */
.post-row-center-content {
    flex: 1;
}

.post-row-title {
    margin: 0 0 6px 0;
}

.post-row-title a {
    font-size: 1.25rem;
    font-weight: 600;
    color: #0f172a;
    text-decoration: none;
    line-height: 1.4;
    transition: color 0.2s;
}

.post-row-title a:hover {
    color: #4f46e5;
}

.post-row-excerpt {
    font-size: 0.95rem;
    color: #64748b;
    line-height: 1.5;
    margin: 0;
    max-width: 760px;
}

/* Right Action Block */
.post-row-right-action {
    min-width: 140px;
    text-align: right;
}

.btn-post-row-action {
    display: inline-block;
    color: #4f46e5;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 6px;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

.btn-post-row-action:hover {
    background: #f5f3ff;
    border-color: #ddd6fe;
}

/* --- Mobile Breakdown Adaptations --- */
@media (max-width: 768px) {
    .premium-post-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        padding: 24px 0;
    }

    .post-row-left-date {
        flex-direction: row;
        gap: 6px;
        padding: 4px 10px;
        min-width: auto;
    }

    .post-row-right-action {
        text-align: left;
        width: 100%;
    }

    .btn-post-row-action {
        padding: 8px 0;
    }
}