:root {
    --primary-color: #fa0000;
    --secondary-color1: #19308a;
    --secondary-color2: #ffbf00;
    --white: #ffffff;
    --black: #000000;
    --gray-light: #f5f5f5;
    --gray-dark: #333333;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Kanit", sans-serif;
}

body {
    background-color: var(--white);
    color: var(--black);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Header Styles */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color1));
    color: var(--white);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

header.scrolled {
    padding: 0.5rem 0;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color1));
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--white);
    display: flex;
    align-items: center;
}

.logo span {
    color: var(--secondary-color2);
    margin-left: 0.5rem;
}

.logo:hover {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 1.5rem;
    position: relative;
}

nav ul li a {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.3s ease;
}

nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--secondary-color2);
    transition: width 0.3s ease;
}

nav ul li a:hover::after {
    width: 100%;
}

nav ul li a:hover {
    color: var(--secondary-color2);
}

.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
}

/* Main Content */
main {
    margin-top: 80px;
    min-height: calc(100vh - 160px);
}

.section {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

.section-title h2 {
    font-size: 2.5rem;
    color: var(--secondary-color1);
    display: inline-block;
    position: relative;
    padding-bottom: 0.5rem;
}

.section-title h2::after {
    content: '';
    position: absolute;
    width: 50%;
    height: 4px;
    bottom: 0;
    left: 25%;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color2));
    border-radius: 2px;
}

/* Slider Section */
.slider-container {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.slider {
    display: flex;
    transition: transform 0.5s ease;
    height: 100%;
}

.slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: var(--white);
    padding: 2rem;
}

.slide-content h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.slide-content p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.slider-nav {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 1rem;
    transform: translateY(-50%);
    z-index: 10;
}

.slider-nav button {
    background: rgba(255, 255, 255, 0.3);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
}

.slider-nav button:hover {
    background: var(--primary-color);
    transform: scale(1.1);
}

.slider-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
    z-index: 10;
}

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

.slider-dot.active {
    background: var(--secondary-color2);
    transform: scale(1.2);
}

/* Gallery Section */
.gallery {
    background-color: var(--white);
}

.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.gallery-item {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
}

.gallery-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.gallery-item-content {
    padding: 1.5rem;
}

.gallery-item-content h3 {
    color: var(--secondary-color1);
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.gallery-item-content p {
    color: var(--gray-dark);
    margin-bottom: 1rem;
}

.gallery-item-content .btn {
    display: inline-block;
    background: var(--primary-color);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.gallery-item-content .btn:hover {
    background: var(--secondary-color1);
    transform: translateY(-2px);
}

.load-more {
    text-align: center;
    margin-top: 2rem;
}

.load-more-btn {
    background: var(--secondary-color1);
    color: var(--white);
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(25, 48, 138, 0.3);
}

.load-more-btn:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(250, 0, 0, 0.3);
}

/* Works Section */
.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.work-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.work-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.work-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.work-card-content {
    padding: 1.5rem;
}

.work-card-content h3 {
    color: var(--secondary-color1);
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.work-card-content .work-category {
    display: inline-block;
    background: var(--secondary-color2);
    color: var(--black);
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    margin-bottom: 0.8rem;
}

.work-card-content p {
    color: var(--gray-dark);
    margin-bottom: 1rem;
}

.work-card-content .work-link {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.work-card-content .work-link i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.work-card-content .work-link:hover {
    color: var(--secondary-color1);
}

.work-card-content .work-link:hover i {
    transform: translateX(3px);
}

/* Footer */
footer {
    background: linear-gradient(135deg, var(--secondary-color1), var(--black));
    color: var(--white);
    padding: 3rem 0 1.5rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-col h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    display: inline-block;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    width: 50%;
    height: 3px;
    bottom: -5px;
    left: 0;
    background: var(--secondary-color2);
}

.footer-col p {
    margin-bottom: 1rem;
    opacity: 0.9;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--white);
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--secondary-color2);
    color: var(--black);
    transform: translateY(-3px);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--white);
    text-decoration: none;
    opacity: 0.9;
    transition: all 0.3s ease;
    display: inline-block;
}

.footer-links a:hover {
    color: var(--secondary-color2);
    transform: translateX(5px);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    opacity: 0.8;
    font-size: 0.9rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(250, 0, 0, 0.3);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--secondary-color1);
    transform: translateY(-5px);
}

/* Responsive Styles */
@media (max-width: 992px) {
    .slider-container {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .header-container {
        padding: 0 1rem;
    }

    .hamburger {
        display: block;
    }

    nav {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 80%;
        height: calc(100vh - 70px);
        background: var(--primary-color);
        transition: all 0.5s ease;
        z-index: 999;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    }

    nav.active {
        left: 0;
    }

    nav ul {
        flex-direction: column;
        padding: 2rem;
    }

    nav ul li {
        margin: 1rem 0;
    }

    .slider-container {
        height: 350px;
    }

    .slide-content h3 {
        font-size: 1.5rem;
    }

    .slide-content p {
        font-size: 1rem;
    }

    .section {
        padding: 3rem 1rem;
    }

    .section-title h2 {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .slider-container {
        height: 300px;
    }

    .slide-content {
        padding: 1rem;
    }

    .slide-content h3 {
        font-size: 1.2rem;
    }

    .slide-content p {
        font-size: 0.9rem;
    }

    .gallery-container {
        grid-template-columns: 1fr;
    }

    .works-grid {
        grid-template-columns: 1fr;
    }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-col h3::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .social-links {
        justify-content: center;
    }
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

.fade-in {
    animation: fadeIn 0.8s ease forwards;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.delay-3 {
    animation-delay: 0.6s;
}
