/* Base Styles */
:root {
    --primary-color: #FF6B00;
    --secondary-color: #0056B3;
    --text-color: #333;
    --light-text: #666;
    --bg-color: #FFFFFF;
    --card-bg: #F8F8F8;
    --header-bg: #FFFFFF;
    --footer-bg: #1A1A1A;
    --footer-text: #CCCCCC;
    --border-color: #E0E0E0;
}

[data-theme="dark"] {
    --primary-color: #FF8C42;
    --secondary-color: #4D9DFF;
    --text-color: #E0E0E0;
    --light-text: #AAAAAA;
    --bg-color: #121212;
    --card-bg: #1E1E1E;
    --header-bg: #1A1A1A;
    --footer-bg: #0D0D0D;
    --footer-text: #999999;
    --border-color: #333333;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.3s, color 0.3s;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Sarabun', 'Helvetica Neue', Arial, sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Utility Bar */
.utility-bar {
    background-color: var(--header-bg);
    padding: 8px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.utility-items {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
}

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    position: relative;
    width: 40px;
    height: 20px;
    padding: 0;
}

.theme-toggle i {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
}

.theme-toggle .fa-moon {
    left: 5px;
    color: var(--text-color);
}

.theme-toggle .fa-sun {
    right: 5px;
    color: var(--text-color);
}

.language-switcher {
    display: flex;
    border-radius: 4px;
    overflow: hidden;
}

.lang-btn {
    padding: 4px 12px;
    border: none;
    background-color: var(--card-bg);
    color: var(--text-color);
    cursor: pointer;
    font-size: 14px;
}

.lang-btn.active {
    background-color: var(--primary-color);
    color: white;
}

/* Header */
.header {
    background-color: var(--header-bg);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img {
    height: 50px;
}

.logo h1 {
    font-size: 24px;
    color: var(--primary-color);
    font-weight: 700;
}

.navbar ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

.navbar a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    font-size: 16px;
    transition: color 0.3s;
}

.navbar a:hover {
    color: var(--primary-color);
}

.mobile-menu-btn {
    display: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-color);
}

/* Hero Section */
.hero {
    padding: 80px 0;
    background: linear-gradient(135deg, rgba(255, 107, 0, 0.1) 0%, rgba(0, 86, 179, 0.1) 100%);
}

.hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.hero-content {
    flex: 1;
}

.hero h2 {
    font-size: 42px;
    margin-bottom: 20px;
    color: var(--primary-color);
    line-height: 1.2;
}

.hero p {
    font-size: 18px;
    margin-bottom: 30px;
    color: var(--light-text);
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #E05E00;
}

.hero-image {
    flex: 1;
    text-align: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Sections Common Styles */
.section-title {
    text-align: center;
    font-size: 36px;
    margin-bottom: 50px;
    color: var(--primary-color);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    margin: 15px auto 0;
}

/* Services Section */
.services {
    padding: 80px 0;
    background-color: var(--bg-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.service-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.service-card h3 {
    padding: 20px 20px 10px;
    font-size: 20px;
    color: var(--primary-color);
}

.service-card p {
    padding: 0 20px 20px;
    color: var(--light-text);
}

/* Products Section */
.products {
    padding: 80px 0;
    background-color: var(--card-bg);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.product-card {
    background-color: var(--bg-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.product-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.product-card h3 {
    padding: 20px 20px 10px;
    font-size: 20px;
    color: var(--primary-color);
}

.product-card p {
    padding: 0 20px 20px;
    color: var(--light-text);
}

/* About Section */
.about {
    padding: 80px 0;
    background-color: var(--bg-color);
}

.about .container {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-content {
    flex: 1;
}

.about-image {
    flex: 1;
}

.about-image img {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.about p {
    margin-bottom: 20px;
    color: var(--light-text);
}

.stats {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
}

.stat-item {
    text-align: center;
}

.number {
    display: block;
    font-size: 36px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.stat-item span:not(.number) {
    font-size: 16px;
    color: var(--light-text);
}

/* Articles Section */
.articles {
    padding: 80px 0;
    background-color: var(--card-bg);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.article-card {
    background-color: var(--bg-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.article-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.article-content {
    padding: 20px;
}

.article-card h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.article-card p {
    color: var(--light-text);
    margin-bottom: 15px;
}

.read-more {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    display: inline-block;
    transition: color 0.3s;
}

.read-more:hover {
    color: #E05E00;
}

/* Contact Section */
.contact {
    padding: 80px 0;
    background-color: var(--bg-color);
}

.contact-container {
    display: flex;
    gap: 50px;
}

.contact-info {
    flex: 1;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
}

.info-item i {
    font-size: 20px;
    color: var(--primary-color);
    margin-right: 15px;
    margin-top: 3px;
}

.contact-form {
    flex: 1;
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 16px;
    background-color: var(--card-bg);
    color: var(--text-color);
}

.form-group textarea {
    height: 150px;
    resize: vertical;
}

/* Footer */
.footer {
    background-color: var(--footer-bg);
    color: var(--footer-text);
    padding: 60px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col img {
    height: 50px;
    margin-bottom: 20px;
}

.footer-col p {
    margin-bottom: 20px;
    line-height: 1.6;
}

.footer-col h3 {
    color: white;
    margin-bottom: 20px;
    font-size: 20px;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    color: var(--footer-text);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-col ul li a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    font-size: 18px;
    transition: background-color 0.3s;
}

.social-links a:hover {
    background-color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--footer-text);
}

/* Responsive Styles */
@media (max-width: 992px) {
    .hero .container,
    .about .container,
    .contact-container {
        flex-direction: column;
    }
    
    .hero-content,
    .hero-image,
    .about-content,
    .about-image,
    .contact-info,
    .contact-form {
        flex: none;
        width: 100%;
    }
    
    .hero-image,
    .about-image {
        margin-top: 40px;
    }
}

@media (max-width: 768px) {
    .navbar {
        position: fixed;
        top: 0;
        left: -100%;
        width: 80%;
        height: 100vh;
        background-color: var(--header-bg);
        padding: 30px;
        transition: left 0.3s;
        z-index: 1001;
    }
    
    .navbar.active {
        left: 0;
    }
    
    .navbar ul {
        flex-direction: column;
        gap: 20px;
    }
    
    .mobile-menu-btn {
        display: block;
        z-index: 1002;
    }
    
    .section-title {
        font-size: 30px;
        margin-bottom: 40px;
    }
    
    .hero h2 {
        font-size: 36px;
    }
}

@media (max-width: 576px) {
    .stats {
        flex-direction: column;
        gap: 30px;
    }
    
    .hero h2 {
        font-size: 30px;
    }
    
    .section-title {
        font-size: 28px;
    }
}