/* ============================================================
   HOW-TO STEPS SECTION — Redesign (Oct 2026)
   Card style like reference: dark golden bg, illustration top,
   white text bottom — 4 cards in a row
   ============================================================ */

/* Override section background to light */
.hp-steps-section {
    background: #f9fafb !important;
    padding: 72px 0 80px !important;
}

.hp-steps-section .hp-section-header h2,
.hp-steps-section .hp-section-header p {
    color: #111827 !important;
}

.hp-steps-section .hp-badge-premium {
    background: #fef3c7 !important;
    color: #92400e !important;
    border: 1px solid #fde68a !important;
}

/* 4-column grid */
.hp-howto-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-top: 40px;
}

/* Each card */
.hp-howto-card {
    background: #ffffff;
    border: 1px solid #f3f4f6;
    border-radius: 24px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.hp-howto-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.1);
}

/* Illustration area - top half of card */
.hp-howto-illustration {
    flex: 0 0 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px 20px 20px;
    position: relative;
    min-height: 200px;
}

/* Body area - bottom half */
.hp-howto-body {
    padding: 20px 22px 24px;
}

.hp-howto-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #111827;
    line-height: 1.3;
    margin: 0 0 10px;
    letter-spacing: -0.01em;
}

.hp-howto-desc {
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.6;
    margin: 0;
}

/* ---- ILLUSTRATION 1: Form mock ---- */
.illus-1 { background: linear-gradient(160deg, #fef9ee 0%, #fef3c7 100%); }

.illus-mock-form {
    background: rgba(255,255,255,0.95);
    border-radius: 16px;
    padding: 18px;
    width: 100%;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.illus-mock-label {
    font-size: 0.65rem;
    color: #9ca3af;
    margin-bottom: 6px;
    font-weight: 600;
    letter-spacing: 0.04em;
}

.illus-mock-input {
    border: 1.5px solid #e5e7eb;
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 0.75rem;
    color: #111827;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 2px;
    background: #fff;
}

.illus-mock-prefix {
    color: #9ca3af;
}

.illus-mock-val {
    font-weight: 700;
    color: #111827;
}

.illus-mock-btn {
    background: #111827;
    color: #fff;
    border-radius: 10px;
    padding: 8px 14px;
    font-size: 0.72rem;
    font-weight: 700;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

/* ---- ILLUSTRATION 2: Product stack ---- */
.illus-2 { background: linear-gradient(160deg, #f0fdf4 0%, #dcfce7 100%); }

.illus-product-stack {
    position: relative;
    width: 120px;
    height: 140px;
}

.illus-product-card {
    position: absolute;
    border-radius: 14px;
    width: 110px;
    height: 130px;
}

.illus-card-back-2 {
    background: linear-gradient(135deg, #22d3ee, #06b6d4);
    bottom: 0; left: 20px;
    transform: rotate(-8deg);
    opacity: 0.7;
}

.illus-card-back-1 {
    background: linear-gradient(135deg, #fb923c, #f97316);
    bottom: 0; left: 10px;
    transform: rotate(-4deg);
    opacity: 0.85;
}

.illus-card-front {
    background: #fff;
    bottom: 0; left: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.illus-prod-img {
    width: 44px;
    height: 44px;
    background: #fef3c7;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: #d97706;
}

.illus-prod-info { text-align: center; }

.illus-prod-name {
    font-size: 0.65rem;
    font-weight: 700;
    color: #111827;
}

.illus-prod-price {
    font-size: 0.6rem;
    color: #10b981;
    font-weight: 600;
}

/* ---- ILLUSTRATION 3: Link bio card ---- */
.illus-3 { background: linear-gradient(160deg, #eff6ff 0%, #dbeafe 100%); }

.illus-link-card {
    background: rgba(255,255,255,0.95);
    border-radius: 16px;
    padding: 16px 20px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.illus-link-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fef3c7;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: #d97706;
    border: 2px solid #fde68a;
}

.illus-link-url {
    font-size: 0.68rem;
    font-weight: 700;
    color: #374151;
    background: #f3f4f6;
    border-radius: 8px;
    padding: 5px 12px;
    letter-spacing: -0.01em;
}

.illus-link-socials {
    display: flex;
    gap: 8px;
}

.illus-social-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #fbbf24;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    color: #fff;
}

/* ---- ILLUSTRATION 4: Notification cards ---- */
.illus-4 { background: linear-gradient(160deg, #fdf4ff 0%, #f3e8ff 100%); }

.illus-notif-wrap {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.illus-notif-card {
    background: rgba(255,255,255,0.95);
    border-radius: 14px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.illus-notif-2 {
    opacity: 0.85;
    transform: scale(0.96);
    transform-origin: left;
}

.illus-notif-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #fef3c7;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #d97706;
    flex-shrink: 0;
}

.illus-notif-title {
    font-size: 0.65rem;
    color: #6b7280;
    font-weight: 600;
}

.illus-notif-amount {
    font-size: 0.85rem;
    font-weight: 800;
    color: #059669;
    letter-spacing: -0.02em;
}

/* Responsive */
@media (max-width: 991.98px) {
    .hp-howto-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

@media (max-width: 575.98px) {
    .hp-steps-section {
        padding: 48px 0 56px !important;
    }

    .hp-howto-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        margin-top: 28px;
    }

    .hp-howto-illustration {
        flex: 0 0 150px;
        min-height: 150px;
        padding: 20px 14px 16px;
    }

    .hp-howto-body {
        padding: 14px 16px 18px;
    }

    .hp-howto-title {
        font-size: 0.95rem;
    }

    .hp-howto-desc {
        font-size: 0.78rem;
    }
}

/* Mobile: 4 steps become a swipeable scroll-snap slider */
.hp-howto-dots {
    display: none;
}

@media (max-width: 767.98px) {
    .hp-howto-grid {
        display: flex;
        gap: 12px;
        margin-left: calc(var(--bs-gutter-x, 1.5rem) * -0.5);
        margin-right: calc(var(--bs-gutter-x, 1.5rem) * -0.5);
        padding: 4px calc(var(--bs-gutter-x, 1.5rem) * 0.5) 12px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scroll-padding: 0 calc(var(--bs-gutter-x, 1.5rem) * 0.5);
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;
        scrollbar-width: none;
    }

    .hp-howto-grid::-webkit-scrollbar {
        display: none;
    }

    .hp-howto-card {
        flex: 0 0 78%;
        scroll-snap-align: start;
    }

    .hp-howto-card:hover {
        transform: none;
    }

    /* Off-screen slides never intersect the viewport vertically-scoped
       observer, so reveal them unconditionally inside the slider */
    .hp-howto-grid .reveal-up {
        opacity: 1;
        transform: none;
    }

    .hp-howto-illustration {
        flex-basis: 170px;
        min-height: 170px;
    }

    .hp-howto-title {
        font-size: 1rem;
    }

    .hp-howto-desc {
        font-size: 0.85rem;
    }

    .hp-howto-dots {
        display: flex;
        justify-content: center;
        gap: 6px;
        margin-top: 10px;
    }

    .hp-howto-dots button {
        width: 8px;
        height: 8px;
        padding: 0;
        border: 0;
        border-radius: 999px;
        background: #d1d5db;
        transition: width 0.3s ease, background 0.3s ease;
    }

    .hp-howto-dots button.is-active {
        width: 22px;
        background: #0f172a;
    }
}
