/* =========================================
   1. CORE SETTINGS & RESET
   ========================================= */
:root {
    --primary-purple: #9d50bb;
    --glass-bg: rgba(0, 0, 0, 0.224);
    --glass-border: rgba(255, 255, 255, 0.3);
    --text-white: #ffffff;
    --text-shadow: 0 2px 10px rgba(255, 255, 255, 0.3);
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Kanit', sans-serif;
    background-size: cover;
    background-position: center;
    color: var(--text-white);
    overflow-x: hidden;
    overflow-y: auto;
    height: auto;
    background-attachment: fixed;
}

body.no-scroll {
    overflow: hidden;
    height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px;
}


/* =========================================
   2. NAVIGATION (ชุด 1 และ ชุด 2)
   ========================================= */

/* --- Navbar ชุดที่ 1 (ใน Glass Card) --- */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

/* --- Navbar ชุดที่ 2 (Fixed Floating) --- */
.navbar-fixed {
    position: fixed;
    top: -120px;
    left: 5%;
    right: 5%;
    width: 90%;
    padding: 10px 40px;
    background-color: rgba(0, 0, 0, 0.57);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 3000;
    transition: all 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    box-sizing: border-box;
    border-radius: 0 0px 30px 30px;
}

.navbar-fixed.show {
    top: 0;
}

/* --- Shared Nav Styles --- */
.nav-links {
    list-style: none;
    display: flex;
    gap: 35px;
    margin: 0;
    padding: 10px 35px 8px 35px;
    transition: all 0.5s ease;
    font-size: 1.2rem;
    margin-left: auto;
    /* เพิ่มบรรทัดนี้เพื่อดันเมนูไปทางขวา */
}

.nav-links a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.8);
    transition: 0.5s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-white);
    font-weight: 600;
}


/* =========================================
   3. HERO & SLIDER
   ========================================= */
.hero-header {
    height: auto;
    display: flex;
    justify-content: center;
    align-items: center;
    background-image: url('/img/1.jpg');
    background-size: cover;
}

.glass-card {
    width: 90%;
    max-width: 95%;
    /* เปลี่ยนจาก height: 85vh เป็น min-height */
    min-height: 85vh;
    height: 80vh;
    /* ให้ยืดหยุ่นตามเนื้อหา */
    margin-top: 2%;
    margin-bottom: 3%;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    padding: 40px;
    display: flex;
    flex-direction: column;
    position: relative;
    /* นำ overflow: hidden ออกเพื่อให้เนื้อหาที่ยาวกว่าจอไถอ่านได้ */
    overflow: visible;
}

.slider-container {
    flex: 1;
    position: relative;
    width: 100%;
    margin-top: 5%;
}

.slide {
    display: none;
    height: 100%;
    animation: fadeEffect 0.8s ease-in-out;
}

.slide.active {
    display: flex;
    align-items: center;
}

.slide-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
    width: 100%;
}

.text-section h1 {
    font-size: clamp(2rem, 5vw, 6rem);
    line-height: 1.1;
    margin-bottom: 20px;
}

.text-section p,
.features-mini {
    font-size: clamp(1rem, 2vw, 1.8rem);
    line-height: 1.6;
    margin-bottom: 30px;
    opacity: 0.9;
    max-width: 800px;
}

.glass-inner-box {
    width: 100%;
    max-width: 800px;
    height: 600px;
    border-radius: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.glass-inner-box img {
    max-width: 100%;
    animation: float 6s ease-in-out infinite;
}

.slider-dots {
    display: flex;
    gap: 12px;
    margin-top: 0px;
}

.dot {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    cursor: pointer;
    transition: 0.3s;
}

.dot.active {
    background: var(--primary-purple);
    width: 35px;
    border-radius: 10px;
}


/* =========================================
   4. SERVICES & WHY US
   ========================================= */

/* --- Services Section --- */
.services-section {
    position: relative;
    width: 100%;
    padding: 100px 0;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-color: rgba(255, 255, 255, 0.905);
    background-blend-mode: overlay;
}

.section-title {
    text-align: center;
    color: var(--primary-purple);
    font-size: 2.8rem;
    margin-bottom: 70px;
    text-shadow: var(--text-shadow);
    background: linear-gradient(90deg, #9900ff, #b700ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
}

.service-card {
    padding: 40px;
    border-radius: 25px;
    text-align: center;
    color: var(--primary-purple);
    transition: all 0.4s ease;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.service-card:hover {
    transform: translateY(-15px);
    border-color: var(--primary-purple);
    box-shadow: 0 12px 40px 0 rgba(157, 80, 187, 0.3);
}

.service-icon-img {
    width: 100px;
    height: 100px;
    object-fit: contain;
    margin-bottom: 25px;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
    /* สีม่วงสดใส (Purple) */
    filter: brightness(0) saturate(100%) invert(26%) sepia(89%) saturate(1583%) hue-rotate(250deg) brightness(100%) contrast(80%);
}

.service-card h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--primary-purple);
    text-shadow: var(--text-shadow);
    background: linear-gradient(90deg, #9900ff, #b700ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.service-card p {
    font-size: 1rem;
    color: rgb(0, 0, 0);
    line-height: 1.7;
    flex-grow: 1;
    margin-bottom: 30px;
}

/* --- Why Us (Features Grid Pro) --- */
.why-TongWebStudio-section {
    padding: 120px 0;
    background: linear-gradient(60deg, transparent,#000, rgb(255, 0, 225), #f05df8, #000);
    background-color: rgba(0, 0, 0, 0.8);
    background-blend-mode: overlay;
}

.features-grid-pro {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    perspective: 1000px;
}

.feature-item.glass {
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 50px 35px;
    border-radius: 35px;
    text-align: center;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    overflow: hidden;
}

.feature-item.glass::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: rotate(45deg);
    transition: 0.8s;
}

.feature-item.glass:hover::before {
    left: 100%;
    top: 100%;
}

.feature-item.glass:hover {
    transform: translateY(-15px);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(157, 80, 187, 0.5);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.icon-box {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, rgba(157, 80, 187, 0.2), rgba(157, 80, 187, 0.05));
    border-radius: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 30px;
    font-size: 2rem;
    color: var(--primary-purple);
    transition: 0.4s;
    border: 1px solid rgba(157, 80, 187, 0.2);
}

.feature-item.glass:hover .icon-box {
    background: var(--primary-purple);
    color: white;
    transform: scale(1.1) rotate(8deg);
    box-shadow: 0 0 20px rgba(157, 80, 187, 0.6);
}

.feature-item h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 18px;
    color: #fff;
    letter-spacing: 0.5px;
}

.feature-item p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.7;
    margin: 0;
}


/* =========================================
   5. WORKING PROCESS
   ========================================= */
.process-split-section {
    padding: 100px 0;
    background: #000;
    color: #fff;


}

.process-container {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 60px;
    align-items: start;
}

.process-left {
    position: sticky;
    top: 200px;
}

.sticky-image-container {
    position: relative;
    border-radius: 40px;
    overflow: hidden;
    aspect-ratio: 6/5;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.process-visual {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
}

.glow-effect {
    position: absolute;
    bottom: -20%;
    right: -20%;
    width: 70%;
    height: 70%;
    background: radial-gradient(circle, rgba(157, 80, 187, 0.3) 0%, transparent 70%);
    filter: blur(40px);
}

.section-title-left {
    font-size: 2.5rem;
    margin-bottom: 40px;
    text-transform: uppercase;
    font-weight: 700;
    display: inline-block;
    transition: letter-spacing 0.5s ease;
}

.section-title-left:hover {
    letter-spacing: 5px;
    color: #9d50bb;
}

.process-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.process-horizontal-card {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.2, 1, 0.3, 1);
}

.process-horizontal-card.reveal {
    opacity: 1;
    transform: translateY(0);
}

.process-horizontal-card.glass {
    display: flex;
    align-items: flex-start;
    gap: 25px;
    padding: 35px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    border-radius: 30px;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.process-horizontal-card.glass:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(157, 80, 187, 0.5);
    transform: translateX(10px);
}

.process-horizontal-card.glass::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(157, 80, 187, 0.1), transparent);
    transform: skewX(-25deg);
    transition: 0.75s;
}

.process-horizontal-card.glass:hover::after {
    left: 150%;
}

.card-number {
    font-size: 1.2rem;
    font-weight: 800;
    color: #9d50bb;
    opacity: 0.8;
}

.card-content h3 {
    font-size: 1.4rem;
    margin-bottom: 8px;
    color: #fff;
}

.card-content p {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.6;
    margin: 0;
}

.icon-box-pro {
    transition: transform 0.3s ease-out;
}

.process-card.glass:hover .icon-box-pro {
    transform: scale(1.1) rotate(-5deg);
    filter: brightness(1.2);
}


/* =========================================
   6. BUTTONS & FORM ELEMENTS
   ========================================= */
.header-actions {
    display: flex;
    gap: 3.5px;
    justify-content: center;
    align-items: center;
    margin-top: -6px;
}

.btn-purple {
    background: var(--primary-purple);
    color: white;
    border: none;
    padding: 16px 35px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(157, 80, 187, 0.4);
    transition: 0.3s;
}

.btn-white-outline {
    background: transparent;
    color: white;
    border: 2px solid #fff;
    padding: 14px 35px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.3s;
}

.btn-purple:hover,
.btn-white-outline:hover {
    transform: translateY(-3px) scale(1.02);
}

.btn-purple-small {
    background: var(--primary-purple);
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: 0.3s;
    text-decoration: none;
    display: inline-block;
    margin-top: 15px;
}

.btn-purple-small:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(157, 80, 187, 0.4);
}

.btn-purple-send {
    background: var(--primary-purple);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    transition: 0.3s;
}

.btn-purple-send:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 20px rgba(157, 80, 187, 0.4);
}

/* Icons & Language */
.icon-link {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    font-size: 1.4rem;
    transition: all 0.3s ease;
    color: #fff;
    margin-top: 1px;
}

.icon-link.whatsapp:hover {
    background: #25D366;
}

.icon-link.line:hover {
    background: #06C755;
}

.lang-btn {
    cursor: pointer;
    color: #fff;
    transition: 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius:5px 15px 5px 15px;
    padding: 6px 6px;
    font-size: 1.2rem;
    background-color: #000;
}

.lang-btn.active {
    opacity: 1;
    font-weight: bold;
    background: var(--primary-purple);
    border-radius:15px 5px 15px 5px;
    padding: 6px 6px;
}

/* =========================================
   7. FOOTER & CONTACT
   ========================================= */
.main-footer {
    padding: 140px 0 20px;
    background: linear-gradient(to top, rgba(102, 6, 113, 0.9), transparent);
    background-image: url(/img/1.jpg);
    background-size: cover;
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 60px;
    padding: 60px;
    border-radius: 40px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
}

.contact-info-side h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #fff, var(--primary-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.contact-methods {
    margin: 40px 0;
}

.method-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    font-size: 1.1rem;
    opacity: 0.8;
}

.method-item i {
    color: var(--primary-purple);
    font-size: 1.4rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-group {
    position: relative;
    width: 100%;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-family: inherit;
    outline: none;
    transition: 0.3s;
}

.form-group label {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.5);
    pointer-events: none;
    transition: 0.3s;
}

.form-group textarea~label {
    top: 25px;
}

.form-group input:focus~label,
.form-group input:not(:placeholder-shown)~label,
.form-group textarea:focus~label,
.form-group textarea:not(:placeholder-shown)~label {
    top: -10px;
    left: 10px;
    font-size: 0.85rem;
    color: var(--primary-purple);
    background: #1a1a2e;
    padding: 0 5px;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-purple);
    background: rgba(255, 255, 255, 0.08);
}

.footer-bottom {
    text-align: center;
    margin-top: 60px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    opacity: 0.6;
}


/* =========================================
   8. FLOATING CONTACT MENU
   ========================================= */
.contact-menu {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 9999;
}

.main-btn {
    background: #9d50bb;
    color: var(--primary-purple);
    border: none;
    padding: 12px 12px;
    border-radius: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    box-shadow: 0 1px 0 0px var(--text-white);
}

.main-btn:hover {
    background: var(--glass-border);
}

.sub-menu {
    display: none;
    flex-direction: column;
    gap: 10px;
    position: absolute;
    bottom: 60px;
    right: 0;
    width: 46px;
}

.sub-menu.active {
    display: flex;
}

.contact-item {
    padding: 10px 15px;
    border-radius: 10px;
    text-decoration: none;
    color: white;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    transition: 0.3s;
}

.contact-item:hover {
    opacity: 0.9;
    transform: translateX(-5px);
}

/* =========================================
   9. RESPONSIVE & ANIMATIONS
   ========================================= */

/* --- Animations --- */
@keyframes fadeEffect {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }
}

/* --- Media Queries --- */
@media (max-width: 1024px) {
    .glass-card {
        width: 95%;
        height: auto;
        min-height: 80vh;
        padding: 20px;
        margin-top: -120px;
    }

    .slide-wrapper {
        flex-direction: column-reverse;
        text-align: center;
    }

    .text-section h1 {
        font-size: 2.8rem;
    }

    .features-grid-pro {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
        padding: 40px;
    }

    .menu-toggle,
    .menu-toggle-btn {
        display: flex;
        flex-direction: column;
        gap: 5px;
        cursor: pointer;
        z-index: 10000;
        position: relative;
    }

    .bar {
        width: 28px;
        height: 3px;
        background: white;
        transition: 1.4s;
    }

    /* Toggle Animation */
    .menu-toggle.is-active .bar:nth-child(2),
    .menu-toggle-btn.is-active .bar:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.is-active .bar:nth-child(1),
    .menu-toggle-btn.is-active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .menu-toggle.is-active .bar:nth-child(3),
    .menu-toggle-btn.is-active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}

@media (max-width: 992px) {
    .process-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .process-left {
        position: relative;
        top: 0;
    }

    .sticky-image-container {
        aspect-ratio: 16/9;
    }

    .section-title-left {
        text-align: center;
    }

    .process-horizontal-card.glass:hover {
        transform: translateY(-5px);
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 7vh;
        left: 0;
        right: 0;
        max-width: 100%;
        height: 90vh;
        background: rgba(0, 0, 0, 0.9);
        backdrop-filter: blur(10px);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        visibility: hidden;
        opacity: 0;
        transition: all 0.4s ease-in-out;
        z-index: 9999;
    }

    .nav-links.active {
        visibility: visible;
        opacity: 1;
        transform: translateY(0);
    }

    .nav-links li {
        margin: 15px 0;
    }

    .nav-links a {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 50px;
    }

    .service-card {
        padding: 30px;
    }

    .service-card h3 {
        font-size: 1.5rem;
    }

    .features-grid-pro {
        grid-template-columns: 1fr;
    }

    .feature-item.glass {
        padding: 40px 25px;
    }

    .text-section h1 {
        font-size: 2.2rem;
    }

    .glass-inner-box {
        height: 200px;
    }

    .cta-buttons {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }
}

/* --- About Why Us (Typography Style) --- */
.about-why-us {
    padding: 120px 0;
    color: #fff;
    background-color: #000;
}

/* หัวข้อแบบกระจก */
.glass-header-box {
    background: rgba(0, 0, 0, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 0.5px solid rgba(255, 255, 255, 0.9);
    border-radius: 30px;
    padding: 60px 40px;
    text-align: center;
    max-width: 1200px;
    margin: 0 auto 80px auto;
}

.glass-header-box h2 {
    font-size: clamp(2rem, 5vw, 3rem);
    margin-bottom: 20px;
    background: linear-gradient(90deg, #fff, #4309e2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-line {
    width: 80px;
    height: 4px;
    background: #b194ff;
    margin: 20px auto;
    border-radius: 10px;
}

/* ส่วนเนื้อหา Typography */
.typography-content {
    display: flex;
    flex-direction: column;
    gap: 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.typo-item {
    position: relative;
    padding-left: 100px;
    /* เว้นที่ให้ตัวเลขด้านหลัง */
}

/* ลูกเล่นตัวเลขด้านหลัง (Background Number) */
.typo-item::before {
    content: attr(data-number);
    position: absolute;
    left: 0px;
    top: -35px;
    font-size: 7rem;
    font-weight: 800;
    color: rgba(177, 148, 255, 0.5);
    /* สีม่วงบางๆ */
    line-height: 1;
    z-index: 0;
    font-family: 'Kanit', sans-serif;
}

.typo-item h3 {
    font-size: 1.8rem;
    color: #b194ff;
    margin-bottom: 15px;
    position: relative;
    z-index: 1;
}

.typo-item p {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
    max-width: 1200px;
    position: relative;
    z-index: 1;
}

/* ขีดข้างหัวข้อเพิ่มลูกเล่น */
.typo-item h3::after {
    content: '';
    display: block;
    width: 0;
    height: 2px;
    background: #b194ff;
    transition: width 0.5s ease;
    margin-top: 5px;
}

.typo-item:hover h3::after {
    width: 150px;
}

/* สำหรับมือถือ */
@media (max-width: 768px) {
    .typo-item {
        padding-left: 0;
        padding-top: 50px;
    }

    .typo-item::before {
        font-size: 4rem;
        top: 0;
    }
}

@media (max-width: 768px) {
    .glass-card {
        width: 80%;
        /* ขยายให้กว้างขึ้นอีกนิดบนจอเล็ก */
        min-height: 70vh;
        /* ยกเลิกการบังคับความสูงขั้นต่ำ */
        height: 80vh;
        padding: 25px 20px;
        /* ลด padding เพื่อเพิ่มพื้นที่เนื้อหา */
        margin: 20px;
        /* เพิ่ม margin บน-ล่างเพื่อให้การ์ดไม่ติดขอบจอเกินไป */
        border-radius: 20px;
        /* ลดความโค้งลงเล็กน้อยให้รับกับขอบจอ */
        overflow: visible;
        /* มั่นใจว่าเนื้อหาไม่โดนตัด */
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .slide-wrapper {
        gap: 0px;
        margin-bottom: 20%;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        right: -30px;
        width: 100vh;
        height: 100vh;
        background: rgba(0, 0, 0, 0.98);
        /* เพิ่มความเข้มเพื่อบังเนื้อหาด้านหลัง */
        display: flex;
        flex-direction: column;
        justify-content: center;
        /* จัดให้อยู่กึ่งกลางแนวตั้ง */
        align-items: center;
        gap: 2rem;
        /* ระยะห่างระหว่างเมนูแต่ละข้อ */
        z-index: 9999;
        /* มั่นใจว่าอยู่บนสุด */
        border-radius: 0%;
        /* เริ่มต้นซ่อนไว้ */
        visibility: hidden;
        opacity: 0;
        transition: all 0.3s ease;
        background-image: url(/img/1.jpg);
        background-color: rgba(0, 0, 0, 0.439);
        background-blend-mode: overlay;
    }

    .nav-links.active {
        visibility: visible;
        opacity: 1;
    }

    /* ซ่อนรายการที่ซ้อนกัน (ถ้ามีตัวหนังสือซ้อนในภาพ) */
    .nav-item {
        font-size: 1.8rem;
        font-weight: 600;
        color: white;
        text-decoration: none;
    }
}

.contact-logo {
    display: block;
    margin-bottom: 25px;
}

@media (max-width: 768px) {
    .contact-logo {
        text-align: center;
        /* บนมือถือให้โลโก้อยู่ตรงกลาง */
    }
}

/* จัดการขนาดรูปภาพภายในสไลด์ */
.slide-logo img {
    height: 30px;
    /* ปรับให้เท่ากับ font-size ของไอคอน */
    width: auto;
    /* ทำให้เป็นสีขาวเทาเข้ากับธีม */
    opacity: 0.5;
    transition: 0.3s;
}

.slide-logo:hover img {
    filter: grayscale(0%) brightness(100%);
    /* กลับเป็นสีจริงเมื่อ Hover */
    opacity: 1;
}

/* ปรับปรุงความกว้างของ Track ตามจำนวนไอคอน (12 ไอคอน x 2 ชุด = 24) */
.logos-slide-track {
    display: flex;
    width: calc(120px * 24);
    animation: scrollLogos 25s linear infinite;
}

.slide-logo {
    width: 120px;
    /* ระยะห่างระหว่างโลโก้ */
    flex-shrink: 0;
}

@keyframes scrollLogos {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(-120px * 12));
    }

    /* เลื่อนไปแค่ครึ่งเดียวของทั้งหมด */
}