/**
 * Sales Training Page Styles
 * Follows bassmah design system (PAGE-BUILD-CHECKLIST.md)
 */

.sales-page {
    --brand: #2f5aae;
    --brand-light: #338eaa;
    --green: #27ae60;
    --green-light: #2ecc71;
    --dark: #0c1a2a;
    --text-light: #334155; /* was #64748b — darkened per client feedback (faded text on desktop) */
    --light-bg: #f0f4f8;
    --shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 25px 60px rgba(0, 0, 0, 0.12);
    --radius: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sales-page * { box-sizing: border-box; }
.sales-page .container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ═══════════════════════════════════════════════════
   1. HERO
═══════════════════════════════════════════════════ */
.sales-hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0c1a2a 0%, #1a3a6b 50%, #2f5aae 100%);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
    padding: 100px 20px 80px;
}

.sales-hero.has-bg { background-color: #0c1a2a; }

.sales-hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(12, 26, 42, 0.88) 0%, rgba(26, 58, 107, 0.78) 50%, rgba(47, 90, 174, 0.72) 100%);
    z-index: 1;
}

.sales-hero.has-bg .sales-hero__overlay {
    background: linear-gradient(135deg, rgba(12, 26, 42, 0.85) 0%, rgba(26, 58, 107, 0.75) 50%, rgba(47, 90, 174, 0.65) 100%);
}

.sales-hero__shapes { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 1; }
.sales-hero__shape  { position: absolute; border-radius: 50%; }

.sales-hero__shape--1 { width: 320px; height: 320px; top: -100px; right: -80px; background: rgba(255, 255, 255, 0.04); }
.sales-hero__shape--2 { width: 480px; height: 480px; bottom: -180px; left: -120px; background: rgba(39, 174, 96, 0.06); animation: salesFloat 15s ease-in-out infinite; }
.sales-hero__shape--3 { width: 200px; height: 200px; top: 30%; left: 10%; border: 2px solid rgba(255, 255, 255, 0.08); background: transparent; }
.sales-hero__shape--4 { width: 140px; height: 140px; bottom: 20%; right: 12%; border-radius: 24px; background: rgba(255, 255, 255, 0.05); transform: rotate(45deg); animation: salesFloat 12s ease-in-out infinite reverse; }

@keyframes salesFloat {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    50%      { transform: translate(20px, -30px) rotate(8deg); }
}

.sales-hero__content { position: relative; z-index: 2; text-align: center; color: #fff; }

.sales-hero__badge {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 50px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
}

.sales-hero__title {
    font-size: clamp(30px, 5vw, 52px);
    font-weight: 900;
    line-height: 1.3;
    margin: 0 0 18px;
    color: #fff;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.sales-hero__desc {
    font-size: clamp(15px, 2vw, 18px);
    line-height: 1.7;
    max-width: 720px;
    margin: 0 auto 32px;
    color: rgba(255, 255, 255, 0.92);
}

.sales-hero__cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 36px;
    background: linear-gradient(135deg, var(--green), var(--green-light));
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 700;
    box-shadow: 0 8px 30px rgba(39, 174, 96, 0.35);
    transition: var(--transition);
}

.sales-hero__cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(39, 174, 96, 0.5);
    color: #fff;
}

.sales-hero__scroll-hint {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    width: 28px;
    height: 46px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 14px;
    display: flex;
    justify-content: center;
    padding-top: 8px;
}
.sales-hero__scroll-hint span {
    width: 4px; height: 8px;
    background: #fff; border-radius: 2px;
    animation: salesScroll 1.6s ease-in-out infinite;
}
@keyframes salesScroll {
    0%   { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(16px); opacity: 0; }
}
@media (max-width: 768px) { .sales-hero__scroll-hint { display: none; } }

/* ═══════════════════════════════════════════════════
   SECTION COMMON
═══════════════════════════════════════════════════ */
.sales-intro, .sales-programs-intro, .sales-instructor, .sales-partners, .sales-gallery {
    position: relative;
    padding: 80px 0;
    overflow: hidden;
}

.sales-intro, .sales-partners, .sales-gallery {
    background: linear-gradient(160deg, #f8fbff, #eaf1fd 30%, #f0f4f8);
}

.sales-programs-intro { background: #fff; padding: 80px 0 40px; }
.sales-instructor { background: #fff; }

.sales-intro::before,
.sales-programs-intro::before,
.sales-instructor::before,
.sales-partners::before,
.sales-gallery::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, #27ae60, #338eaa, #2f5aae);
    z-index: 1;
}

.sales-intro__title,
.sales-programs-intro__title,
.sales-instructor__title,
.sales-partners__title,
.sales-gallery__title {
    font-size: clamp(28px, 4vw, 38px);
    font-weight: 900;
    line-height: 1.3;
    text-align: center;
    color: var(--dark);
    margin: 0 0 50px;
    position: relative;
}

.sales-intro__title::after,
.sales-programs-intro__title::after,
.sales-instructor__title::after,
.sales-partners__title::after,
.sales-gallery__title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--green), var(--brand));
    border-radius: 2px;
    margin: 16px auto 0;
}

.sales-programs-intro__title { margin-bottom: 0; }

.sales-page .section-badge {
    display: inline-block;
    width: fit-content;
    margin: 0 auto 16px;
    padding: 8px 22px;
    border-radius: 50px;
    background: linear-gradient(135deg, var(--brand), var(--brand-light));
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.3px;
    box-shadow: 0 6px 20px rgba(47, 90, 174, 0.25);
    text-align: center;
}

.sales-intro .container,
.sales-programs-intro .container,
.sales-instructor .container,
.sales-partners .container,
.sales-gallery .container { text-align: center; }

.sales-intro > .container > .section-badge,
.sales-programs-intro > .container > .section-badge,
.sales-instructor > .container > .section-badge,
.sales-partners > .container > .section-badge,
.sales-gallery > .container > .section-badge { display: block; }

/* ═══════════════════════════════════════════════════
   2. INTRO
═══════════════════════════════════════════════════ */
.sales-intro__text {
    max-width: 800px;
    margin: 0 auto 30px;
    font-size: 16px;
    line-height: 1.9;
    color: var(--text-light);
}

.sales-intro__tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    max-width: 900px;
    margin: 0 auto;
}

.sales-intro__tag {
    padding: 8px 18px;
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 50px;
    color: var(--dark);
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
}

.sales-intro__tag:hover {
    border-color: var(--green);
    background: #f0fdf4;
    color: var(--green);
    transform: translateY(-2px);
}

/* ═══════════════════════════════════════════════════
   3. PROGRAMS — each one full-width themed section
═══════════════════════════════════════════════════ */
.sales-program {
    position: relative;
    padding: 90px 0;
    overflow: hidden;
    text-align: right;
}

.sales-program__shapes {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}
.sales-program__shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.5;
}
.sales-program__shape--1 {
    width: 380px; height: 380px;
    top: -120px; right: -100px;
}
.sales-program__shape--2 {
    width: 280px; height: 280px;
    bottom: -80px; left: -60px;
}
.sales-program__shape--3 {
    width: 160px; height: 160px;
    top: 40%; left: 8%;
    border-radius: 32px;
    transform: rotate(45deg);
    opacity: 0.4;
}

/* Theme: Blue (Program 1) */
.sales-program--blue {
    background: linear-gradient(160deg, #eef4ff 0%, #dbe7fb 50%, #f0f4ff 100%);
}
.sales-program--blue .sales-program__shape--1 { background: rgba(47, 90, 174, 0.08); }
.sales-program--blue .sales-program__shape--2 { background: rgba(51, 142, 170, 0.10); }
.sales-program--blue .sales-program__shape--3 { background: rgba(47, 90, 174, 0.05); }
.sales-program--blue .sales-program__num { color: rgba(47, 90, 174, 0.10); }
.sales-program--blue .sales-program__icon { background: linear-gradient(135deg, #2f5aae, #338eaa); }
.sales-program--blue .sales-program__eyebrow { color: #2f5aae; }
.sales-program--blue .sales-program__item { border-right-color: #2f5aae; }
.sales-program--blue .sales-program__item:hover { background: linear-gradient(180deg, #eef4ff, #fff); }
.sales-program--blue .sales-program__item-num { background: linear-gradient(135deg, #2f5aae, #338eaa); }

/* Theme: Green (Program 2) */
.sales-program--green {
    background: linear-gradient(160deg, #ecfdf5 0%, #d1fae5 50%, #f0fdf4 100%);
}
.sales-program--green .sales-program__shape--1 { background: rgba(39, 174, 96, 0.10); }
.sales-program--green .sales-program__shape--2 { background: rgba(46, 204, 113, 0.10); }
.sales-program--green .sales-program__shape--3 { background: rgba(39, 174, 96, 0.05); }
.sales-program--green .sales-program__num { color: rgba(39, 174, 96, 0.12); }
.sales-program--green .sales-program__icon { background: linear-gradient(135deg, #27ae60, #2ecc71); }
.sales-program--green .sales-program__eyebrow { color: #16a34a; }
.sales-program--green .sales-program__item { border-right-color: #27ae60; }
.sales-program--green .sales-program__item:hover { background: linear-gradient(180deg, #ecfdf5, #fff); }
.sales-program--green .sales-program__item-num { background: linear-gradient(135deg, #27ae60, #2ecc71); }

/* Theme: Gold (Program 3) */
.sales-program--gold {
    background: linear-gradient(160deg, #fffbeb 0%, #fef3c7 50%, #fff8e1 100%);
}
.sales-program--gold .sales-program__shape--1 { background: rgba(217, 119, 6, 0.08); }
.sales-program--gold .sales-program__shape--2 { background: rgba(245, 158, 11, 0.10); }
.sales-program--gold .sales-program__shape--3 { background: rgba(217, 119, 6, 0.05); }
.sales-program--gold .sales-program__num { color: rgba(217, 119, 6, 0.12); }
.sales-program--gold .sales-program__icon { background: linear-gradient(135deg, #d97706, #f59e0b); }
.sales-program--gold .sales-program__eyebrow { color: #b45309; }
.sales-program--gold .sales-program__item { border-right-color: #d97706; }
.sales-program--gold .sales-program__item:hover { background: linear-gradient(180deg, #fffbeb, #fff); }
.sales-program--gold .sales-program__item-num { background: linear-gradient(135deg, #d97706, #f59e0b); }

.sales-program .container { position: relative; z-index: 2; }

.sales-program__header {
    display: grid;
    grid-template-columns: auto auto 1fr;
    align-items: center;
    gap: 24px;
    margin-bottom: 50px;
    position: relative;
}

.sales-program__num {
    font-size: clamp(80px, 12vw, 140px);
    font-weight: 900;
    line-height: 1;
    margin: 0;
    font-family: 'Tajawal', sans-serif;
    letter-spacing: -2px;
}

.sales-program__icon {
    width: 90px;
    height: 90px;
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.sales-program__icon img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.sales-program__head-text {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sales-program__eyebrow {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.sales-program__title {
    font-size: clamp(24px, 3.5vw, 34px);
    font-weight: 900;
    color: var(--dark);
    line-height: 1.3;
    margin: 0;
}

.sales-program__count {
    font-size: 14px;
    color: var(--text-light);
    margin: 0;
    font-weight: 600;
}

/* Curriculum: ONE themed container per program with bullets as list rows inside.
 * Client feedback: 54+ floating cards (3 programs × ~18 bullets) was chaotic —
 * now all bullets of ONE program sit inside a single card/box. */
.sales-program__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 0;
    row-gap: 0;
    margin-bottom: 40px;
    background: #fff;
    border-radius: 20px;
    border: 2px solid rgba(0, 0, 0, 0.06);
    padding: 16px 24px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    position: relative;
}
/* Top accent bar matching the program theme */
.sales-program__grid::before {
    content: '';
    position: absolute;
    top: 0; right: 0; left: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--program-accent-a, #2f5aae), var(--program-accent-b, #338eaa));
}
.sales-program--blue  .sales-program__grid { --program-accent-a: #2f5aae; --program-accent-b: #338eaa; background: linear-gradient(180deg, #f5f8ff, #fff); }
.sales-program--green .sales-program__grid { --program-accent-a: #27ae60; --program-accent-b: #2ecc71; background: linear-gradient(180deg, #f2fbf5, #fff); }
.sales-program--gold  .sales-program__grid { --program-accent-a: #d97706; --program-accent-b: #f59e0b; background: linear-gradient(180deg, #fffbf0, #fff); }

.sales-program__item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 10px;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    border-bottom: 1px dashed rgba(0, 0, 0, 0.08) !important;
    transition: background 0.2s ease;
}
/* Hide the bottom border on the last row of each column */
.sales-program__item:nth-last-child(-n+2):nth-child(odd),
.sales-program__item:last-child {
    border-bottom: none !important;
}
.sales-program__item:hover {
    transform: none !important;
    box-shadow: none !important;
    background: rgba(0, 0, 0, 0.02) !important;
}

.sales-program__item-num {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sales-program__item p {
    margin: 0;
    font-size: 15px;
    color: var(--dark);
    line-height: 1.65;
    font-weight: 600;
    flex: 1;
}

.sales-program__cta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    justify-content: center;
    padding-top: 20px;
}

.sales-program__download,
.sales-program__register {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
}

.sales-program__download {
    background: #fff;
    color: var(--dark);
    border: 2px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
}

.sales-program__download:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.10);
    color: var(--dark);
}

.sales-program__register {
    background: linear-gradient(135deg, var(--green), var(--green-light));
    color: #fff;
    box-shadow: 0 8px 26px rgba(39, 174, 96, 0.32);
}

.sales-program__register:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 36px rgba(39, 174, 96, 0.45);
    color: #fff;
}

@media (max-width: 1024px) {
    .sales-program { padding: 70px 0; }
    .sales-program__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .sales-program { padding: 60px 0; }
    .sales-program__header {
        grid-template-columns: 1fr;
        text-align: center;
        justify-items: center;
    }
    .sales-program__num { font-size: 60px; }
    .sales-program__head-text { align-items: center; text-align: center; }
    .sales-program__grid { grid-template-columns: 1fr; }
    .sales-program__item:hover { transform: none; }
}

/* ═══════════════════════════════════════════════════
   4. INSTRUCTOR
═══════════════════════════════════════════════════ */
.sales-instructor__grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 50px;
    align-items: center;
    background: linear-gradient(180deg, #f8fbff, #fff);
    border-radius: var(--radius);
    border: 2px solid #e8ecf1;
    padding: 40px;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
    text-align: right;
}

.sales-instructor__grid::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, #27ae60, #338eaa, #2f5aae);
}

.sales-instructor__image img {
    width: 100%;
    border-radius: 20px;
    object-fit: cover;
    aspect-ratio: 1;
    box-shadow: 0 15px 40px rgba(47, 90, 174, 0.18);
}

.sales-instructor__name {
    font-size: 24px;
    font-weight: 900;
    color: var(--dark);
    margin: 0 0 16px;
    line-height: 1.4;
}

.sales-instructor__desc {
    font-size: 16px;
    color: var(--text-light);
    line-height: 1.9;
    margin: 0 0 24px;
}

.sales-instructor__btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 30px;
    background: linear-gradient(135deg, var(--green), var(--green-light));
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 700;
    box-shadow: 0 8px 30px rgba(39, 174, 96, 0.3);
    transition: var(--transition);
}

.sales-instructor__btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(39, 174, 96, 0.4);
    color: #fff;
}

/* ═══════════════════════════════════════════════════
   5. PARTNERS
═══════════════════════════════════════════════════ */
/* Partners — flex-wrap matching /trainer/ pattern (mobile-friendly) */
.sales-partners__grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.sales-partner-card {
    width: 160px;
    height: 100px;
    background: #fff;
    border-radius: 16px;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #e8ecf1;
    transition: var(--transition);
}

.sales-partner-card:hover {
    transform: translateY(-5px);
    border-color: var(--brand);
    box-shadow: var(--shadow);
}

.sales-partner-card img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: grayscale(60%);
    opacity: 0.85;
    transition: var(--transition);
}
@media (max-width: 600px) {
    .sales-partner-card { width: calc(50% - 10px); height: 90px; }
}

.sales-partner-card:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

/* ═══════════════════════════════════════════════════
   7. GALLERY (Swiper)
═══════════════════════════════════════════════════ */
.sales-gallery__swiper-wrap {
    position: relative;
    padding: 0 50px;
}

.sales-gallery-swiper { padding-bottom: 50px; }

.sales-gallery-swiper .swiper-slide img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.sales-gallery-swiper .swiper-slide:hover img {
    transform: scale(1.02);
    box-shadow: var(--shadow-lg);
}

.sales-gallery__next,
.sales-gallery__prev {
    --swiper-navigation-color: #fff;
    --swiper-navigation-size: 22px;
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--brand), var(--brand-light));
    border-radius: 50%;
    box-shadow: 0 6px 20px rgba(47, 90, 174, 0.3);
}

.sales-gallery__pagination .swiper-pagination-bullet {
    background: var(--brand);
    opacity: 0.4;
}
.sales-gallery__pagination .swiper-pagination-bullet-active {
    opacity: 1;
    background: var(--green);
}

/* ═══════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .sales-instructor__grid { grid-template-columns: 250px 1fr; gap: 30px; padding: 30px; }
}

@media (max-width: 768px) {
    .sales-hero { min-height: 700px; padding: 100px 20px 60px; }
    .sales-intro, .sales-programs-intro, .sales-instructor, .sales-partners, .sales-gallery { padding: 60px 0; }

    .sales-instructor__grid { grid-template-columns: 1fr; text-align: center; }
    .sales-instructor__image { max-width: 280px; margin: 0 auto; }
    .sales-partner-card:hover { transform: translateY(-2px); }

    .sales-gallery__swiper-wrap { padding: 0 20px; }
    .sales-gallery__next, .sales-gallery__prev { display: none; }
}

/* ============ P5 text-legibility fix (client note: "faded text on desktop") ============ */
.sales-intro__text,
.sales-program__count,
.sales-program__desc,
.sales-instructor__desc,
.sales-program__curriculum-item,
.sales-program__feature {
    color: #0c1a2a !important;
    font-weight: 600;
}
.sales-program__curriculum-item,
.sales-program__feature {
    font-weight: 700;
}
@media (min-width: 1024px) {
    .sales-intro__text { font-size: 17px; line-height: 2; }
    .sales-program__curriculum-item { font-size: 15.5px; }
}
