/* =========================================================
   FINGER THAILAND - HOME PAGE
   Purple / pink brand palette, optimized motion and layout.
   Load this file only on the home page.
========================================================= */

.ft-home {
    --ft-primary: #a855f7;
    --ft-secondary: #d946ef;
    --ft-accent: #8b5cf6;
    --ft-ink: #1f2937;
    --ft-muted: #64748b;
    --ft-border: #e9dff3;
    --ft-soft: #faf7fd;
    color: var(--ft-ink);
    overflow: clip;
}

.ft-home *,
.ft-home *::before,
.ft-home *::after {
    box-sizing: border-box;
}

.ft-home img {
    display: block;
    max-width: 100%;
}

.ft-home a {
    text-decoration: none;
}

.ft-home h1,
.ft-home h2,
.ft-home h3,
.ft-home p {
    overflow-wrap: anywhere;
}

.ft-home h1,
.ft-home h2,
.ft-home h3 {
    color: var(--ft-ink);
    font-weight: 700;
    letter-spacing: -.35px;
}

.ft-home p {
    color: var(--ft-muted);
    line-height: 1.8;
}

.ft-home .btn-primary {
    color: #fff;
    background: linear-gradient(135deg, var(--ft-primary), var(--ft-secondary));
    border: 0;
    box-shadow: 0 7px 18px rgba(168, 85, 247, .18);
}

.ft-home .btn-primary:hover,
.ft-home .btn-primary:focus {
    color: #fff;
    filter: brightness(.97);
}

.ft-home .btn-outline-primary {
    color: var(--ft-primary);
    border-color: var(--ft-primary);
    background: #fff;
}

.ft-home .btn-outline-primary:hover,
.ft-home .btn-outline-primary:focus {
    color: #fff;
    border-color: var(--ft-primary);
    background: var(--ft-primary);
}

.ft-home .btn {
    border-radius: 999px;
    font-weight: 600;
    padding: .72rem 1.25rem;
}

.ft-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: clamp(3.25rem, 7vw, 6.5rem) 0;
    background:
        radial-gradient(ellipse at 88% 10%, rgba(217, 70, 239, .16), transparent 34%),
        radial-gradient(ellipse at 8% 92%, rgba(168, 85, 247, .09), transparent 38%),
        linear-gradient(135deg, #fbf8ff 0%, #f5edff 55%, #fff 100%);
}

/* ลายเส้นเรขาคณิตบาง ๆ เพิ่มมิติให้พื้นหลัง Hero */
.ft-hero::before {
    position: absolute;
    z-index: 0;
    inset: 0;
    content: "";
    pointer-events: none;
    background-image:
        repeating-linear-gradient(
            135deg,
            transparent 0,
            transparent 27px,
            rgba(139, 92, 246, .055) 28px,
            rgba(139, 92, 246, .055) 29px,
            transparent 30px,
            transparent 56px
        ),
        radial-gradient(circle, rgba(168, 85, 247, .15) 1px, transparent 1.6px);
    background-size: auto, 22px 22px;
    opacity: .62;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 18%, #000 82%, transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 18%, #000 82%, transparent 100%);
}

/* วงแสงนุ่มและเส้นวงกลมโปร่งด้านขวา */
.ft-hero::after {
    position: absolute;
    z-index: 0;
    top: -190px;
    right: -110px;
    width: min(58vw, 680px);
    aspect-ratio: 1;
    border: 1px solid rgba(168, 85, 247, .10);
    border-radius: 50%;
    content: "";
    pointer-events: none;
    background:
        radial-gradient(circle at 50% 50%, transparent 0 43%, rgba(168, 85, 247, .045) 43.2% 43.5%, transparent 43.8% 59%, rgba(217, 70, 239, .055) 59.2% 59.5%, transparent 59.8%),
        radial-gradient(circle at 50% 50%, rgba(217, 70, 239, .10), transparent 68%);
}

.ft-hero > * {
    position: relative;
    z-index: 1;
}

.ft-hero h1 {
    max-width: 700px;
    margin: .9rem 0 1.1rem;
    font-size: clamp(2rem, 4.1vw, 3.45rem);
    line-height: 1.22;
}

.ft-eyebrow,
.ft-kicker {
    display: inline-block;
    color: var(--ft-primary);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .11em;
}

.ft-hero-lead {
    max-width: 640px;
    margin-bottom: .7rem;
    font-size: clamp(1rem, 1.5vw, 1.12rem);
}

.ft-area-line {
    margin-bottom: 1.5rem;
    color: #6b4b83 !important;
}

.ft-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    align-items: center;
}

.ft-hero-points {
    display: grid;
    gap: .45rem;
    margin: 1.5rem 0 0;
    padding: 0;
    list-style: none;
    color: #475569;
    font-size: .94rem;
}

.ft-hero-points li::before {
    content: "✓";
    margin-right: .55rem;
    color: var(--ft-primary);
    font-weight: 800;
}

.ft-hero-image {
    width: 100%;
    height: auto;
    max-height: 510px;
    object-fit: contain;
}

.ft-section {
    padding: clamp(3rem, 6vw, 5.2rem) 0;
}

.ft-section-soft {
    background: var(--ft-soft);
}

.ft-section-heading {
    max-width: 760px;
    margin: 0 auto 2rem;
    text-align: center;
}

.ft-section-heading h2,
.ft-area-section h2,
.ft-contact h2 {
    margin: .55rem 0 .75rem;
    font-size: clamp(1.55rem, 3vw, 2.35rem);
    line-height: 1.3;
}

.ft-section-heading p {
    margin: 0 auto;
    max-width: 680px;
}

.ft-product-card,
.ft-content-card {
    height: 100%;
    overflow: hidden;
    border: 1px solid var(--ft-border);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 5px 18px rgba(31, 41, 55, .045);
}

.ft-product-image {
    display: flex;
    min-height: 190px;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: #fff;
}

.ft-product-image img {
    width: 100%;
    height: 175px;
    object-fit: contain;
}

.ft-product-body {
    padding: .2rem 1rem 1.2rem;
}

.ft-product-type {
    color: var(--ft-primary);
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .08em;
}

.ft-product-body h3 {
    margin: .35rem 0 .45rem;
    font-size: 1.08rem;
}

.ft-product-body p {
    min-height: 3.3em;
    margin-bottom: .65rem;
    font-size: .9rem;
    line-height: 1.65;
}

.ft-text-link {
    color: #9333ea;
    font-size: .92rem;
    font-weight: 700;
}

.ft-text-link:hover {
    color: #7e22ce;
    text-decoration: underline;
}

.ft-product-more,
.ft-centered-link {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .7rem;
    margin-top: 1.7rem;
}

.ft-area-section {
    padding: clamp(3rem, 6vw, 5rem) 0;
    background: linear-gradient(135deg, #f7efff, #fff7fd);
    border-top: 1px solid #f0e4fa;
    border-bottom: 1px solid #f0e4fa;
}

.ft-area-section h2 {
    margin-top: .55rem;
}

.ft-area-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.ft-area-card {
    min-height: 210px;
    padding: 1.35rem;
    border: 1px solid var(--ft-border);
    border-radius: 18px;
    background: rgba(255,255,255,.9);
}

.ft-area-number {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    margin-bottom: .8rem;
    border-radius: 50%;
    color: #fff;
    background: linear-gradient(135deg, var(--ft-primary), var(--ft-secondary));
    font-size: .8rem;
    font-weight: 700;
}

.ft-area-card h3 {
    margin-bottom: .4rem;
    font-size: 1.15rem;
}

.ft-area-card p,
.ft-area-note {
    margin: 0;
    font-size: .9rem;
}

.ft-area-note {
    margin-top: .75rem;
    font-size: .82rem;
}

.ft-benefit-list {
    display: grid;
    gap: .8rem;
}

.ft-benefit-list > div {
    display: flex;
    gap: .9rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--ft-border);
    border-radius: 15px;
    background: #fff;
}

.ft-benefit-list > div > span {
    display: inline-flex;
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    background: var(--ft-primary);
    font-weight: 800;
}

.ft-benefit-list h3 {
    margin: 0 0 .2rem;
    font-size: 1rem;
}

.ft-benefit-list p {
    margin: 0;
    font-size: .9rem;
}

.ft-content-image {
    display: block;
    overflow: hidden;
    background: #f8f5fb;
}

.ft-content-image img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.ft-content-body {
    padding: 1.1rem 1.2rem 1.25rem;
}

.ft-content-body h3 {
    margin: .45rem 0 .55rem;
    font-size: 1.05rem;
    line-height: 1.5;
}

.ft-content-body h3 a {
    color: var(--ft-ink);
}

.ft-content-body h3 a:hover {
    color: var(--ft-primary);
}

.ft-content-body p {
    margin-bottom: .75rem;
    font-size: .9rem;
}

.ft-location-tag {
    display: inline-block;
    padding: .2rem .65rem;
    border-radius: 999px;
    color: #7e22ce;
    background: #f3e8ff;
    font-size: .75rem;
    font-weight: 700;
}

.ft-narrow {
    max-width: 900px;
}

.ft-faq {
    display: grid;
    gap: .75rem;
}

.ft-faq .accordion-item {
    overflow: hidden;
    border: 1px solid var(--ft-border);
    border-radius: 14px;
    background: #fff;
}

.ft-faq .accordion-button {
    padding: 1.1rem 1.25rem;
    color: var(--ft-ink);
    background: #fff;
    font-size: 1rem;
    font-weight: 700;
    box-shadow: none;
}

.ft-faq .accordion-button:not(.collapsed) {
    color: #7e22ce;
    background: #fbf7ff;
}

.ft-faq .accordion-button:focus {
    border-color: var(--ft-primary);
    box-shadow: 0 0 0 .2rem rgba(168, 85, 247, .12);
}

.ft-faq .accordion-body {
    color: var(--ft-muted);
    line-height: 1.8;
}

.ft-contact {
    padding: clamp(3rem, 6vw, 5rem) 0;
    background:
        radial-gradient(ellipse at 10% 90%, rgba(217, 70, 239, .2), transparent 38%),
        linear-gradient(125deg, #f5eaff, #fcf7ff);
}

.ft-contact p {
    max-width: 680px;
    margin: 0 auto 1.4rem;
}

@media (hover: hover) and (pointer: fine) {
    .ft-product-card,
    .ft-content-card,
    .ft-area-card {
        transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
    }

    .ft-product-card:hover,
    .ft-content-card:hover,
    .ft-area-card:hover {
        transform: translateY(-3px);
        border-color: rgba(168, 85, 247, .35);
        box-shadow: 0 12px 28px rgba(88, 28, 135, .09);
    }
}

@media (max-width: 575.98px) {
    .ft-hero {
        padding-top: 2.5rem;
        padding-bottom: 2.5rem;
    }

    .ft-hero h1 {
        font-size: 1.85rem;
    }

    .ft-actions .btn {
        width: 100%;
    }

    .ft-product-image {
        min-height: 145px;
        padding: .65rem;
    }

    .ft-product-image img {
        height: 130px;
    }

    .ft-product-body {
        padding: .15rem .75rem .9rem;
    }

    .ft-product-body h3 {
        font-size: .98rem;
    }

    .ft-product-body p {
        min-height: 4.8em;
        font-size: .82rem;
    }

    .ft-area-grid {
        grid-template-columns: 1fr;
    }

    .ft-area-card {
        min-height: 0;
    }

    .ft-content-image img {
        height: 185px;
    }

    .ft-product-more .btn {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ft-home *,
    .ft-home *::before,
    .ft-home *::after {
        scroll-behavior: auto !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}


/* Modern category selector */
.ft-category-section {
    position: relative;
    background: linear-gradient(180deg, #fff 0%, #fcf9ff 100%);
}

.ft-category-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
}

.ft-category-card {
    display: grid;
    grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
    min-height: 255px;
    overflow: hidden;
    border: 1px solid rgba(168, 85, 247, .15);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 10px 32px rgba(65, 32, 92, .055);
}

.ft-category-visual {
    position: relative;
    display: flex;
    min-height: 255px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 1.1rem;
    background: radial-gradient(circle at 50% 40%, #fff 0%, #f6edff 72%, #f1e5ff 100%);
}

.ft-category-visual::after {
    position: absolute;
    inset: auto 0 0;
    height: 35%;
    background: linear-gradient(180deg, transparent, rgba(61, 25, 85, .09));
    content: "";
    pointer-events: none;
}

.ft-category-visual img {
    width: 100%;
    height: 205px;
    object-fit: contain;
    transition: transform .35s ease;
}

.ft-category-index {
    position: absolute;
    z-index: 1;
    left: 1rem;
    top: 1rem;
    padding: .38rem .65rem;
    border: 1px solid rgba(255,255,255,.75);
    border-radius: 999px;
    color: #7136a0;
    background: rgba(255,255,255,.82);
    font-size: .64rem;
    font-weight: 800;
    letter-spacing: .07em;
    backdrop-filter: blur(8px);
}

.ft-category-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 1.5rem 1.45rem;
}

.ft-category-label {
    display: inline-flex;
    margin-bottom: .65rem;
    padding: .32rem .7rem;
    border-radius: 999px;
    color: #8b35bd;
    background: #f7edff;
    font-size: .72rem;
    font-weight: 700;
}

.ft-category-content h3 {
    margin: 0 0 .55rem;
    font-size: clamp(1.12rem, 1.6vw, 1.4rem);
    line-height: 1.35;
}

.ft-category-content p {
    margin: 0 0 1rem;
    font-size: .9rem;
    line-height: 1.72;
}

.ft-category-link {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    margin-top: auto;
    color: #8735b8;
    font-size: .9rem;
    font-weight: 800;
}

.ft-category-link span {
    display: inline-flex;
    width: 27px;
    height: 27px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    background: linear-gradient(135deg, var(--ft-primary), var(--ft-secondary));
    transition: transform .2s ease;
}

@media (hover: hover) and (pointer: fine) {
    .ft-category-card {
        transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
    }
    .ft-category-card:hover {
        transform: translateY(-4px);
        border-color: rgba(168, 85, 247, .35);
        box-shadow: 0 18px 42px rgba(88, 28, 135, .11);
    }
    .ft-category-card:hover .ft-category-visual img {
        transform: scale(1.045);
    }
    .ft-category-card:hover .ft-category-link span {
        transform: translateX(3px);
    }
}

@media (max-width: 991.98px) {
    .ft-category-grid { gap: 1rem; }
    .ft-category-card { grid-template-columns: 1fr; }
    .ft-category-visual { min-height: 205px; }
    .ft-category-visual img { height: 180px; }
    .ft-category-content { min-height: 220px; padding: 1.2rem; }
}

@media (max-width: 575.98px) {
    .ft-category-grid { grid-template-columns: 1fr; gap: .9rem; }
    .ft-category-card { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); min-height: 205px; border-radius: 17px; }
    .ft-category-visual { min-height: 205px; padding: .55rem; }
    .ft-category-visual img { height: 145px; }
    .ft-category-index { top: .55rem; left: .55rem; padding: .25rem .42rem; font-size: .52rem; }
    .ft-category-content { min-height: 205px; padding: .85rem .8rem; }
    .ft-category-label { margin-bottom: .4rem; padding: .24rem .5rem; font-size: .62rem; }
    .ft-category-content h3 { margin-bottom: .35rem; font-size: .98rem; }
    .ft-category-content p { margin-bottom: .6rem; font-size: .78rem; line-height: 1.55; }
    .ft-category-link { gap: .25rem; font-size: .75rem; }
    .ft-category-link span { width: 22px; height: 22px; flex: 0 0 22px; }
}

@media (max-width: 380px) {
    .ft-category-card { grid-template-columns: 1fr; }
    .ft-category-visual { min-height: 165px; }
    .ft-category-visual img { height: 145px; }
    .ft-category-content { min-height: 0; }
}
