/* =========================================================
   Homepage Page Styles
   Scope: Only styles unique to the home page.
   Global tokens live in design_system/variables.css
   ========================================================= */

/* ── Shared Section Utilities ─────────────────────────── */

.homepage-container {
    background-color: var(--color-grey-5);
    color: var(--color-grey-80);
    overflow-x: hidden;
}

.homepage-container h1,
.homepage-container h2,
.homepage-container h3,
.homepage-container h4,
.homepage-container p {
    margin: 0;
    padding: 0;
}

/* ── Buttons ──────────────────────────────────────────── */

.premium-btn {
    display: inline-block;
    padding: 0.75rem 1.75rem;
    background-color: var(--category-university);
    color: var(--color-grey-0);
    text-decoration: none;
    border-radius: var(--radius-circle);
    font-weight: 600;
    font-size: 0.9375rem;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
    box-shadow: 0 4px 14px rgba(0, 114, 79, 0.25);
}

.premium-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 114, 79, 0.35);
    background-color: #005f42;
    color: var(--color-grey-0);
    opacity: 1;
}

.premium-btn-outline {
    background-color: transparent;
    color: var(--category-university);
    border: 2px solid var(--category-university);
    box-shadow: none;
}

.premium-btn-outline:hover {
    background-color: var(--category-university);
    color: var(--color-grey-0);
    box-shadow: 0 4px 14px rgba(0, 114, 79, 0.25);
}

/* ── Section Headers ──────────────────────────────────── */

.hp-section-header {
    text-align: center;
    margin-block-end: 3rem;
}

.hp-section-title {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 800;
    margin-block-end: 1rem;
    color: var(--color-grey-90);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.hp-section-subtitle {
    display: inline-block;
    font-size: 0.8125rem;
    text-transform: uppercase;
    color: var(--category-university);
    letter-spacing: 0.12em;
    font-weight: 700;
    margin-block-end: 0.875rem;
    padding: 0.25rem 0.875rem;
    background-color: var(--category-university-light);
    border: 1px solid var(--category-university-hover);
    border-radius: var(--radius-circle);
}

.hp-section-desc {
    font-size: 1.0625rem;
    color: var(--color-grey-50);
    max-width: 60ch;
    margin: 0 auto;
    line-height: 1.7;
}

/* ── Scroll Reveal ────────────────────────────────────── */

.hp-reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.55s ease, transform 0.55s ease;
}

.hp-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.hp-reveal-delay-1 { transition-delay: 0.1s; }
.hp-reveal-delay-2 { transition-delay: 0.2s; }
.hp-reveal-delay-3 { transition-delay: 0.3s; }
.hp-reveal-delay-4 { transition-delay: 0.4s; }


/* ── 1. Hero ──────────────────────────────────────────── */

.hp-hero {
    position: relative;
    overflow: hidden;
}

/* Full-width angled accent — lives on the outer section */
.hp-hero::before {
    content: '';
    position: absolute;
    inset-inline-end: 0;
    top: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(160deg, var(--category-university-light) 0%, var(--category-university-hover) 100%);
    clip-path: polygon(18% 0%, 100% 0%, 100% 100%, 0% 100%);
    pointer-events: none;
    z-index: 0;
}

[dir="rtl"] .hp-hero::before {
    inset-inline-end: unset;
    inset-inline-start: 0;
    clip-path: polygon(0% 0%, 82% 0%, 100% 100%, 0% 100%);
}

.hp-hero-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 5rem 2rem 4rem;
    gap: 3rem;
    max-width: 1280px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

@media (min-width: 768px) {
    .hp-hero-inner {
        flex-direction: row;
        padding: 7rem 2rem 6rem;
        min-height: 82vh;
    }
}

.hp-hero-content {
    flex: 1;
    text-align: start;
}

.hp-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--category-university);
    background-color: var(--category-university-light);
    border: 1px solid var(--category-university-hover);
    border-radius: var(--radius-circle);
    padding: 0.3rem 0.875rem;
    margin-block-end: 1.25rem;
    letter-spacing: 0.03em;
}

.hp-hero-title {
    font-size: clamp(2.25rem, 5vw, 3.75rem);
    font-weight: 800;
    line-height: 1.12;
    margin-block-end: 0.75rem;
    color: var(--color-grey-90);
    letter-spacing: -0.03em;
}

.hp-hero-title-accent {
    background: linear-gradient(135deg, var(--category-university), #00b374);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hp-hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-grey-50);
    margin-block-end: 1.25rem;
    font-weight: 400;
}

.hp-hero-desc {
    font-size: 1.0625rem;
    line-height: 1.7;
    margin-block-end: 2rem;
    color: var(--color-grey-60);
}

.hp-hero-image-wrap {
    flex: 1;
    display: flex;
    justify-content: center;
}

.hp-hero-image {
    max-width: 100%;
    height: auto;
    max-height: 520px;
    object-fit: cover;
    border-radius: var(--radius-large);
    box-shadow:
        0 32px 64px -12px rgba(0, 114, 79, 0.2),
        0 8px 24px rgba(0, 0, 0, 0.1);
    transform: perspective(2000px) rotateY(-6deg) rotateX(2deg);
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.6s ease;
}

.hp-hero-image:hover {
    transform: perspective(2000px) rotateY(0deg) rotateX(0deg);
    box-shadow: 0 40px 80px -12px rgba(0, 114, 79, 0.25);
}

[dir="rtl"] .hp-hero-image { transform: perspective(2000px) rotateY(6deg) rotateX(2deg); }
[dir="rtl"] .hp-hero-image:hover { transform: perspective(2000px) rotateY(0deg) rotateX(0deg); }


/* ── 2. Features Grid ─────────────────────────────────── */

.hp-features {
    padding: 5rem 2rem;
    background-color: var(--color-grey-0);
}

.hp-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    max-width: 1280px;
    margin: 0 auto;
}

.hp-feature-card {
    background: var(--color-grey-0);
    border: 1px solid var(--color-grey-20);
    padding: 2rem 1.75rem;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-category);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    position: relative;
    overflow: hidden;
}

/* Animated accent bar on hover */
.hp-feature-card::after {
    content: '';
    position: absolute;
    inset-block-start: 0;
    inset-inline-start: 0;
    width: 3px;
    height: 0;
    background-color: var(--category-university);
    transition: height 0.3s ease;
}

.hp-feature-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.08);
    border-color: var(--category-university-hover);
}

.hp-feature-card:hover::after {
    height: 100%;
}

.hp-feature-icon {
    width: 52px;
    height: 52px;
    margin-block-end: 1.5rem;
    object-fit: contain;
}

.hp-feature-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-block-end: 0.6rem;
    color: var(--color-grey-80);
}

.hp-feature-desc {
    color: var(--color-grey-50);
    line-height: 1.65;
    font-size: 0.9375rem;
}


/* ── 3. Story Tiles ───────────────────────────────────── */

.hp-stories {
    padding: 5rem 2rem;
    max-width: 1280px;
    margin: 0 auto;
}

.hp-stories-content {
    text-align: center;
    margin-block-end: 3rem;
}

.hp-stories-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (min-width: 768px) {
    .hp-stories-grid { grid-template-columns: repeat(4, 1fr); }
}

.hp-story-tile {
    overflow: hidden;
    border-radius: var(--radius-large);
    aspect-ratio: 3 / 4;
}

.hp-story-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.hp-story-tile:hover img { transform: scale(1.05); }


/* ── 4. Process ───────────────────────────────────────── */

.hp-process {
    padding: 6rem 2rem;
    background-color: var(--color-grey-90);
    color: var(--color-grey-0);
}

.hp-process .hp-section-title { color: var(--color-grey-0); }
.hp-process .hp-section-desc  { color: var(--color-grey-40); }

/* On dark bg: use secondary bright green for the eyebrow pill */
.hp-process .hp-section-subtitle {
    color: #00e592;
    background-color: rgba(0, 229, 146, 0.08);
    border-color: rgba(0, 229, 146, 0.2);
}

.hp-process-grid {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    max-width: 1100px;
    margin: 4rem auto 0;
    position: relative;
}

@media (min-width: 768px) {
    .hp-process-grid {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }

    /* Connecting dashed line through circle centers */
    .hp-process-grid::before {
        content: '';
        position: absolute;
        top: 1.5rem; /* half of 3rem circle height */
        inset-inline-start: 12.5%;
        width: 75%;
        height: 1px;
        background: linear-gradient(to right,
            var(--category-university) 0%,
            rgba(0, 114, 79, 0.25) 100%
        );
        z-index: 0;
    }

    [dir="rtl"] .hp-process-grid::before {
        background: linear-gradient(to left,
            var(--category-university) 0%,
            rgba(0, 114, 79, 0.25) 100%
        );
    }
}

.hp-process-step {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 1;
}

.hp-process-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--category-university);
    color: var(--color-grey-0);
    font-weight: 700;
    font-size: 1.125rem;
    border-radius: var(--radius-circle);
    margin: 0 auto 1.5rem;
    box-shadow: 0 0 0 6px rgba(0, 114, 79, 0.15);
}

.hp-process-title {
    font-size: 1.0625rem;
    font-weight: 700;
    margin-block-end: 0.5rem;
    color: var(--color-grey-0);
}

.hp-process-desc {
    color: var(--color-grey-40);
    line-height: 1.65;
    font-size: 0.9375rem;
    max-width: 20ch;
    margin: 0 auto;
}


/* ── 5. Bento Grids ───────────────────────────────────── */

.hp-bento {
    padding: 5rem 2rem;
    max-width: 1280px;
    margin: 0 auto;
}

.hp-bento-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 768px) {
    .hp-bento-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .hp-bento-card-1 { grid-column: span 2; }
    .hp-bento-card-4 { grid-column: span 2; }
}

.hp-bento-card {
    position: relative;
    border-radius: var(--radius-large);
    overflow: hidden;
    background: var(--color-grey-80);
    box-shadow: var(--shadow-category);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 280px;
}

.hp-bento-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.15);
}

.hp-bento-content {
    position: absolute;
    inset: 0;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    background: linear-gradient(
        to top,
        rgba(15, 23, 42, 0.92) 0%,
        rgba(15, 23, 42, 0.5) 40%,
        transparent 100%
    );
    color: var(--color-grey-0);
    z-index: 2;
}

.hp-bento-title {
    font-size: 1.375rem;
    font-weight: 700;
    margin-block-end: 0.375rem;
    line-height: 1.3;
}

.hp-bento-desc {
    color: var(--color-grey-30);
    font-size: 0.9375rem;
    line-height: 1.5;
    white-space: pre-line;
}

.hp-bento-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    inset: 0;
    z-index: 1;
    transition: transform 0.4s ease;
}

.hp-bento-card:hover .hp-bento-img { transform: scale(1.04); }


/* ── 6. Testimonial ───────────────────────────────────── */

.hp-testimonial {
    padding: 5rem 2rem;
    background-color: var(--category-university);
    color: var(--color-grey-0);
    position: relative;
    overflow: hidden;
}

/* Radial glow accent */
.hp-testimonial::before {
    content: '';
    position: absolute;
    inset-inline-end: 5%;
    top: -30%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0, 229, 146, 0.2) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.hp-testimonial-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

@media (min-width: 768px) {
    .hp-testimonial-inner { flex-direction: row; }
}

.hp-testimonial-image-wrap {
    flex: 1;
    flex-shrink: 0;
}

.hp-testimonial-image-wrap img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border-radius: var(--radius-large);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hp-testimonial-content {
    flex: 2;
    position: relative;
}

/* Large decorative opening quote */
.hp-testimonial-content::before {
    content: '\201C';
    position: absolute;
    top: -1.5rem;
    inset-inline-start: -0.75rem;
    font-size: 7rem;
    line-height: 1;
    color: rgba(255, 255, 255, 0.15);
    font-family: Georgia, serif;
    pointer-events: none;
    user-select: none;
}

.hp-testimonial-quote {
    font-size: 1.375rem;
    font-weight: 400;
    line-height: 1.7;
    margin-block-end: 1.5rem;
    position: relative;
}

.hp-testimonial-author {
    font-weight: 700;
    font-size: 1rem;
    opacity: 0.85;
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

/* Em-dash decoration before author name */
.hp-testimonial-author::before {
    content: '';
    display: inline-block;
    width: 1.75rem;
    height: 2px;
    background-color: rgba(255, 255, 255, 0.55);
    flex-shrink: 0;
}

/* ── 7. CTA Book Service ──────────────────────────────── */

.hp-cta-book {
    margin: 6rem auto 4rem;
    max-width: 1152px;
    padding-inline: 1rem;
    position: relative;
}

@media (min-width: 640px) {
    .hp-cta-book { padding-inline: 2rem; }
}

.hp-cta-bg {
    position: absolute;
    inset: 0;
    inset-inline: 1rem;
    background: linear-gradient(135deg, #001f16 0%, #00724f 100%);
    border-radius: 1.5rem;
    z-index: 0;
    overflow: hidden;
}
@media (min-width: 640px) {
    .hp-cta-bg { inset-inline: 2rem; }
}

/* Glow effects inside the BG layer so they get clipped */
.hp-cta-bg::before {
    content: '';
    position: absolute;
    top: -50%;
    inset-inline-end: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    filter: blur(40px);
}
.hp-cta-bg::after {
    content: '';
    position: absolute;
    bottom: -30%;
    inset-inline-start: -10%;
    width: 400px;
    height: 400px;
    background: rgba(16, 185, 129, 0.2);
    border-radius: 50%;
    filter: blur(60px);
}

.hp-cta-inner {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    padding: 3rem 2rem;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 768px) {
    .hp-cta-inner {
        flex-direction: row;
        justify-content: space-between;
        padding: 4rem;
        gap: 2.5rem;
    }
}

.hp-cta-content {
    flex: 1;
    text-align: center;
}

@media (min-width: 768px) {
    .hp-cta-content { text-align: start; }
}

html[dir="rtl"] .hp-cta-content {
    text-align: center;
}

@media (min-width: 768px) {
    html[dir="rtl"] .hp-cta-content { text-align: right; }
}

.hp-cta-title {
    font-size: clamp(2rem, 3.5vw, 2.5rem);
    font-weight: 800;
    color: #ffffff;
    line-height: 1.2;
    margin-block-end: 1rem;
}

.hp-cta-desc {
    font-size: 1.125rem;
    color: #e5e7eb;
    line-height: 1.7;
    margin-block-end: 2rem;
    max-width: 600px;
    margin-inline: auto;
    opacity: 0.95;
}
@media (min-width: 768px) {
    .hp-cta-desc { margin-inline: 0; }
}

.hp-cta-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    justify-content: center;
}
@media (min-width: 640px) {
    .hp-cta-actions {
        flex-direction: row;
    }
}
@media (min-width: 768px) {
    .hp-cta-actions { justify-content: flex-start; }
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    border-radius: 9999px;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
}

.primary-btn-light {
    background-color: #ffffff;
    color: var(--primary, #00724f);
    border: 1px solid transparent;
}
.primary-btn-light:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
    transform: translateY(-4px);
    background-color: #f9fafb;
    color: var(--primary, #00724f);
}

.secondary-btn-ghost {
    background-color: transparent;
    color: #ffffff;
    border: 1px solid rgba(255,255,255,0.4);
}
.secondary-btn-ghost:hover {
    background-color: rgba(255,255,255,0.1);
    border-color: #ffffff;
    color: #ffffff;
}

.hp-cta-visual {
    width: 100%;
    max-width: 380px;
    position: relative;
    display: none;
    flex: 1;
}

@media (min-width: 768px) {
    .hp-cta-visual { display: block; }
}

.hp-cta-mockup {
    background-color: #ffffff;
    border-radius: 1rem;
    padding: 1.5rem;
    position: relative;
    z-index: 2;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
    border: 1px solid #f3f4f6;
    transform: rotate(2deg);
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}
.hp-cta-mockup:hover {
    transform: rotate(0deg) translateY(-4px);
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.4);
}

[dir="rtl"] .hp-cta-mockup { transform: rotate(-2deg); }
[dir="rtl"] .hp-cta-mockup:hover { transform: rotate(0deg) translateY(-4px); }

.hp-cta-mockup-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-block-end: 1.5rem;
}

.hp-cta-icon-wrap {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 50%;
    background-color: #f9fafb;
    border: 1px solid #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.hp-cta-mockup-title {
    font-weight: 700;
    color: #111827;
    line-height: 1.2;
    margin-block-end: 0.25rem;
    font-size: 1.125rem;
}

.hp-cta-mockup-subtitle {
    font-size: 0.875rem;
    font-weight: 600;
    color: #00724f;
}

.hp-cta-bar {
    height: 0.5rem;
    background-color: #f3f4f6;
    border-radius: 9999px;
    margin-block-end: 1rem;
    width: 100%;
    overflow: hidden;
}
.hp-cta-bar-fill { height: 100%; border-radius: 9999px; }
.hp-cta-bar-1 .hp-cta-bar-fill { width: 75%; background-color: #00724f; }
.hp-cta-bar-2 .hp-cta-bar-fill { width: 50%; background-color: #10b981; }

.hp-cta-mockup-footer {
    margin-block-start: 1.5rem;
    padding-block-start: 1rem;
    border-top: 1px solid #f3f4f6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.hp-cta-expert {
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hp-cta-id {
    font-size: 0.75rem;
    font-weight: 700;
    color: #111827;
    background-color: #f3f4f6;
    padding: 0.25rem 0.6rem;
    border-radius: 0.375rem;
}

.hp-cta-mockup-shadow {
    position: absolute;
    top: -0.75rem;
    inset-inline-end: -0.75rem;
    width: 100%;
    height: 100%;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 1rem;
    transform: rotate(-3deg);
    z-index: 1;
}

[dir="rtl"] .hp-cta-mockup-shadow {
    inset-inline-end: unset;
    inset-inline-start: -0.75rem;
    transform: rotate(3deg);
}

