/**
 * Homepage Styles — P0 Redesign
 *
 * Text-first layout with ink-wash mountain aesthetic.
 * Sections: Hero → Three Paths → Testimonials → First Book
 *
 * @package Yi
 */

/* ====== Hero Section ====== */
.hero-section {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 80%;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0.92) 0%,
        rgba(255, 255, 255, 0.82) 35%,
        rgba(255, 255, 255, 0.55) 70%,
        rgba(255, 255, 255, 0.25) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 720px;
    text-align: center;
    padding: 40px 24px 120px;
    margin-top: -40px;
}

.hero-title {
    font-family: var(--font-secondary);
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 700;
    color: #1a2e4a;
    line-height: 1.2;
    margin-bottom: 24px;
    letter-spacing: -0.5px;
    text-shadow: 0 1px 4px rgba(255, 255, 255, 0.6);
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.15rem);
    color: #3a4e6a;
    line-height: 1.7;
    margin-bottom: 36px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 0 1px 3px rgba(255, 255, 255, 0.5);
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary-cta {
    display: inline-block;
    padding: 14px 36px;
    background: linear-gradient(135deg, #2e4e7e, #1a3460);
    color: #ffffff !important;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.25s ease;
    box-shadow: 0 4px 16px rgba(46, 78, 126, 0.35);
    letter-spacing: 0.3px;
}

.btn-primary-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(46, 78, 126, 0.45);
    background: linear-gradient(135deg, #3a5e92, #2e4e7e);
    text-decoration: none;
    color: #ffffff !important;
}

.btn-secondary-cta {
    display: inline-block;
    padding: 14px 36px;
    background: transparent;
    color: #2e4e7e !important;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    border: 2px solid #2e4e7e;
    transition: all 0.25s ease;
}

.btn-secondary-cta:hover {
    background: rgba(46, 78, 126, 0.08);
    transform: translateY(-2px);
    text-decoration: none;
    color: #2e4e7e !important;
}

/* ====== Three-Path Entry ====== */
.paths-section {
    background: #f8f6f2;
    padding: 80px 24px;
}

.paths-container {
    max-width: 1000px;
    margin: 0 auto;
}

.paths-heading {
    font-family: var(--font-secondary);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: #1a2e4a;
    text-align: center;
    margin-bottom: 48px;
}

.paths-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.path-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 28px;
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid rgba(46, 78, 126, 0.08);
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.path-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(46, 78, 126, 0.12);
    border-color: rgba(46, 78, 126, 0.15);
    text-decoration: none;
}

.path-number {
    font-family: var(--font-secondary, serif);
    font-size: 1.8rem;
    font-weight: 700;
    color: rgba(46, 78, 126, 0.12);
    margin-bottom: 12px;
    line-height: 1;
    letter-spacing: -1px;
}

.path-title {
    font-family: var(--font-secondary);
    font-size: 1.3rem;
    font-weight: 700;
    color: #1a2e4a;
    margin-bottom: 12px;
}

.path-desc {
    font-size: 0.95rem;
    color: #5a6a7e;
    line-height: 1.6;
    margin-bottom: 20px;
    flex: 1;
}

.path-link {
    font-size: 0.95rem;
    font-weight: 600;
    color: #2e4e7e;
    transition: color 0.2s ease;
}

.path-card:hover .path-link {
    color: var(--color-gold);
}

/* ====== See It in Action: Case Studies ====== */
.cases-section {
    background: #ffffff;
    padding: 72px 24px;
}

.cases-container {
    max-width: 820px;
    margin: 0 auto;
    text-align: center;
}

.cases-heading {
    font-family: var(--font-secondary, serif);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: #1a2e4a;
    margin-bottom: 10px;
}

.cases-subtitle {
    font-size: 1rem;
    color: #5a6a7e;
    line-height: 1.6;
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* 5-card grid: 3 cards on top row, 2 on bottom row, centered.
   Bumped from 2-col to repeat(3, 1fr) when we expanded from 4 to 5 cases. */
.cases-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    text-align: left;
    margin-bottom: 24px;
}
@media (max-width: 980px) {
    .cases-grid { grid-template-columns: 1fr 1fr; }
}

.case-card {
    display: block;
    padding: 20px;
    background: #f8f6f2;
    border-radius: 10px;
    border: 1px solid rgba(46, 78, 126, 0.06);
    text-decoration: none;
    transition: all 0.25s ease;
}

.case-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(46, 78, 126, 0.1);
    border-color: rgba(46, 78, 126, 0.12);
    text-decoration: none;
}

.case-tag {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #8a6d1b;
    background: rgba(212, 175, 55, 0.12);
    padding: 2px 8px;
    border-radius: 3px;
    margin-bottom: 8px;
}

.case-card h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a2e4a;
    line-height: 1.4;
    margin: 0;
}

.case-card:hover h3 {
    color: #2e4e7e;
}

.cases-more-link {
    font-size: 0.95rem;
    font-weight: 600;
    color: #2e4e7e;
    text-decoration: none;
}

.cases-more-link:hover {
    color: var(--color-gold, #d4af37);
}

@media (max-width: 768px) {
    .cases-grid {
        grid-template-columns: 1fr;
    }
    .cases-section {
        padding: 48px 16px;
    }
}

/* ====== Testimonials ====== */
.testimonials-section {
    background: #ffffff;
    padding: 80px 24px;
}

.testimonials-container {
    max-width: 900px;
    margin: 0 auto;
}

.testimonials-heading {
    font-family: var(--font-secondary);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: #1a2e4a;
    text-align: center;
    margin-bottom: 48px;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.testimonial-card {
    background: #f8f6f2;
    border-radius: 12px;
    padding: 32px;
    margin: 0;
    border-left: 4px solid var(--color-gold, #d4af37);
}

.testimonial-text {
    font-size: 0.95rem;
    color: #3a4e6a;
    line-height: 1.7;
    font-style: italic;
    margin-bottom: 20px;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.testimonial-author strong {
    font-size: 1rem;
    color: #1a2e4a;
    font-style: normal;
}

.testimonial-author span {
    font-size: 0.85rem;
    color: #7a8a9e;
    font-style: normal;
}

/* ====== Books Preview / Your First Book ====== */
.books-preview-section {
    background: #f8f6f2;
    padding: 80px 24px;
}

.books-preview-container {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.books-preview-heading {
    font-family: var(--font-secondary);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: #1a2e4a;
    margin-bottom: 12px;
}

.books-preview-subtitle {
    font-size: 1rem;
    color: #5a6a7e;
    margin-bottom: 36px;
    line-height: 1.6;
}

.first-book-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 36px 32px;
    text-align: left;
    border: 1px solid rgba(46, 78, 126, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    margin-bottom: 32px;
}

.first-book-card h3 {
    font-family: var(--font-secondary);
    font-size: 1.3rem;
    font-weight: 700;
    color: #1a2e4a;
    margin-bottom: 6px;
}

.first-book-author {
    font-size: 0.9rem;
    color: var(--color-gold, #d4af37);
    font-weight: 600;
    margin-bottom: 16px;
}

.first-book-desc {
    font-size: 0.95rem;
    color: #5a6a7e;
    line-height: 1.7;
    margin-bottom: 24px;
}

.btn-book-cta {
    display: inline-block;
    padding: 10px 24px;
    background: var(--color-gold, #d4af37);
    color: #ffffff !important;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.25s ease;
}

.btn-book-cta:hover {
    background: #c49a2d;
    transform: translateY(-1px);
    text-decoration: none;
    color: #ffffff !important;
}

.books-preview-more {
    margin-top: 12px;
}

/* ====== Responsive ====== */
@media (max-width: 768px) {
    .hero-section {
        min-height: 70vh;
    }

    .hero-content {
        padding: 40px 20px 60px;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .btn-primary-cta,
    .btn-secondary-cta {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }

    .paths-section,
    .testimonials-section,
    .books-preview-section {
        padding: 48px 16px;
    }

    .paths-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .path-card {
        padding: 28px 20px;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .testimonial-card {
        padding: 24px;
    }

    .first-book-card {
        padding: 24px 20px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.5rem;
    }

    .hero-subtitle {
        font-size: 0.9rem;
    }
}

/* ====== Remove old homepage styles that might interfere ====== */
.front-page-redesign .ui-homepage-container,
.front-page-redesign .decorative-layer,
.front-page-redesign .main-background,
.front-page-redesign .particle-layer {
    display: none !important;
}
