/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #418660;
    --secondary-color: #D1BB9E;
    --accent-color: #5a8f7d;
    --light-accent: #7bb399;
    --text-dark: #1a202c;
    --text-medium: #2d3748;
    --text-light: #3a4a5c;
    --text-muted: #5a6c7d;
    --bg-light: #f0f9f0;
    --bg-white: #ffffff;
    --bg-gray: #f7faf7;
    --border-color: #d1e7dd;
    --border-light: #f0f9f0;
    --success-color: #22c55e;
    --gradient-primary: linear-gradient(135deg, #2d5a4a 0%, #5a8f7d 50%, #7bb399 100%);
    --gradient-accent: linear-gradient(135deg, #D1BB9E 0%, #E8D5C4 100%);
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    --primary-rgb: 65, 134, 96;
    --border-radius-sm: 6px;
    --border-radius-md: 8px;
    --border-radius-lg: 12px;
    --border-radius-xl: 16px;
    --transition-fast: 0.15s ease-out;
    --transition-normal: 0.3s ease-out;
    --transition-slow: 0.5s ease-out;
}

body {
    font-family: 'Inter', 'Sarabun', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.7;
    color: var(--text-dark);
    background-color: var(--bg-white);
    font-size: 16px;
    font-weight: 400;
    letter-spacing: -0.01em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 1.5rem;
    letter-spacing: -0.025em;
    color: var(--text-dark);
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 2rem;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 600;
    margin-bottom: 1rem;
}

h4 {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 600;
    margin-bottom: 0.75rem;
}

p {
    margin-bottom: 1.5rem;
    color: var(--text-medium);
    font-size: 1.125rem;
    line-height: 1.8;
}

.lead {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--text-medium);
    line-height: 1.7;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 16px 32px;
    border-radius: var(--border-radius-lg);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    text-align: center;
    transition: var(--transition-normal);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    min-width: 160px;
    letter-spacing: 0.025em;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--text-dark);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
    color: white;
}

.btn-secondary {
    background: var(--gradient-primary);
    color: var(--text-dark);
    box-shadow: var(--shadow-md);
}

.btn-secondary:hover {
    color: white;
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
}

.btn-accent {
    background: var(--gradient-accent);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-accent:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
}

/* Navigation */
.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--shadow-sm);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition-normal);
    border-bottom: 1px solid var(--border-light);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.nav-logo {
    display: flex;
    align-items: center;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition-fast);
}

.nav-logo:hover {
    color: var(--accent-color);
}

.company-logo {
    height: clamp(44px, 7vw, 56px);
    max-height: 64px;
    width: auto;
    margin-right: 14px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.company-name {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-left: 2px;
}

.company-name-en,
.company-name-th {
    color: #000000;
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.2;
    margin: 0;
}

.company-name-en {
    font-family: 'Inter', sans-serif;
}

.company-name-th {
    font-family: 'Sarabun', sans-serif;
    font-size: 0.85rem;
}

.company-name-separator {
    width: 100%;
    height: 1px;
    background-color: #000000;
    margin: 2px 0;
}

.nav-logo i {
    font-size: 1.75rem;
    margin-right: 12px;
}

.nav-menu {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 0.5rem;
}

.nav-item {
    position: relative;
}

.nav-link {
    text-decoration: none;
    color: var(--text-medium);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 12px 20px;
    border-radius: var(--border-radius-md);
    transition: var(--transition-fast);
    position: relative;
    letter-spacing: 0.01em;
}

.nav-link:hover {
    color: var(--primary-color);
    background-color: var(--bg-light);
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gradient-accent);
    transition: width var(--transition-fast);
    border-radius: 1px;
}

.nav-link:hover::after {
    width: 60%;
}

.lang-toggle {
    background: var(--gradient-accent);
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: var(--border-radius-md);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: var(--shadow-sm);
}

.lang-toggle:hover {
    background: var(--gradient-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: var(--text-dark);
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    background: var(--gradient-primary);
    color: white;
    padding: 140px 0 100px;
    margin-top: 80px;
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><radialGradient id="a" cx="50%" cy="50%" r="50%"><stop offset="0%" stop-color="rgba(255,255,255,0.1)"/><stop offset="100%" stop-color="rgba(255,255,255,0)"/></radialGradient></defs><circle cx="200" cy="200" r="100" fill="url(%23a)"/><circle cx="800" cy="300" r="150" fill="url(%23a)"/><circle cx="400" cy="700" r="120" fill="url(%23a)"/></svg>') no-repeat center center;
    background-size: cover;
    opacity: 0.3;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    justify-items: center;
    width: 100%;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    margin-bottom: 2rem;
    line-height: 1.1;
    padding-top: 6px;
    margin-top: 18px;
    background: linear-gradient(135deg, #ffffff 0%, #e8f5e8 50%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1), 0 4px 8px rgba(0,0,0,0.05);
    font-weight: 800;
    letter-spacing: -0.02em;
    transition: all 0.6s ease;
    position: relative;
    cursor: pointer;
}

.hero-content h1:hover {
    background: linear-gradient(90deg,
        #ffffff 0%,
        #00FF88 20%,
        #D1BB9E 40%,
        #4ECDC4 60%,
        #FFD93D 80%,
        #ffffff 100%);
    background-size: 200% 100%;
    animation: colorShift 2s ease-in-out infinite;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes colorShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.hero-content h1::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color), var(--primary-color));
    border-radius: 2px;
    opacity: 0.8;
}

.hero-content p {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.7;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
    max-width: 600px;
}

.hero-content ul {
    list-style: none;
    padding: 0;
    margin-bottom: 3rem;
    max-width: 650px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.hero-content li {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: rgba(255, 255, 255, 0.9);
    padding-left: 2rem;
    position: relative;
    line-height: 1.6;
    font-weight: 400;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    margin-bottom: 0;
    white-space: nowrap;
}

.hero-content li:hover {
    color: rgba(255, 255, 255, 1);
    transform: translateX(5px);
}

.hero-content li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 0;
    color: var(--accent-color);
    font-weight: bold;
    font-size: 1.2rem;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.hero-content li:hover::before {
    background: var(--accent-color);
    color: white;
    transform: scale(1.1);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-image {
    position: relative;
    width: clamp(320px, 36vw, 440px);
    height: clamp(320px, 36vw, 440px);
    margin: 0 auto 0 auto;
    margin-left: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--transition-normal), filter var(--transition-normal);
    will-change: transform, filter;
}

#sphereCanvas {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    transition: filter var(--transition-normal), transform var(--transition-normal);
}

/* Hover effects for hero sphere and left text */
.hero-image:hover {
    transform: scale(1.05);
}

.hero-image:hover #sphereCanvas {
    filter: drop-shadow(0 8px 20px rgba(var(--primary-rgb), 0.25)) drop-shadow(0 0 22px rgba(var(--primary-rgb), 0.45));
}

.hero-content {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: clamp(320px, 36vw, 440px);
    transition: transform var(--transition-normal), color var(--transition-normal);
    overflow: visible; /* prevent any internal clipping */
}

.hero-content:hover {
    transform: translateY(-4px);
}

.hero-content:hover h1 {
    animation: colorAlternate 2s infinite;
}

@keyframes colorAlternate {
    0%, 45% {
        color: #59AC77;
    }
    55%, 100% {
        color: #253900;
    }
}

.hero-content:hover p {
    color: rgba(255, 255, 255, 0.98);
}

.hero-content:hover .btn {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

/* Canvas overlay for hero particle trail */
.hero-particles {
    position: absolute;
    top: -24px; /* expand beyond text area to avoid clipping */
    left: -24px;
    width: calc(100% + 48px);
    height: calc(100% + 48px);
    pointer-events: none;
    z-index: 3;
}


/* Section Headers */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

/* About Section */
.about {
    padding: 80px 0;
    background-color: var(--bg-light);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.about-text h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.why-choose-us h3 {
    color: var(--primary-color);
}

.about-text p {
    font-size: 1.125rem;
    margin-bottom: 2rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
    background-color: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.stat-item h4 {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
}

.stat-item p {
    color: var(--text-dark);
    font-weight: 500;
    margin: 0;
}

.about-features {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.feature {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background-color: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.feature i {
    font-size: 2rem;
    color: var(--secondary-color);
    margin-top: 0.25rem;
}

.feature h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.feature p {
    margin: 0;
}

/* Services Section */
.services {
    padding: 80px 0;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.service-card {
    perspective: 1000px;
    min-height: 400px;
    position: relative;
    overflow: hidden;
}

.service-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.service-card:hover .service-card-inner {
    transform: rotateY(180deg);
}

.service-card-front, .service-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: var(--border-radius-xl);
    padding: 2.5rem;
    background: linear-gradient(145deg, var(--bg-white) 0%, #f8faf9 100%);
    box-shadow: var(--shadow-lg);
    border: 2px solid var(--primary-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-normal);
}

.service-card-front {
    transform: rotateY(0deg);
}

.service-card-back {
    transform: rotateY(180deg);
    padding: 2rem;
    background: linear-gradient(145deg, #f8faf9 0%, var(--bg-white) 100%);
}

.service-card-front::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-accent);
    transform: scaleX(0);
    transition: transform var(--transition-normal);
    border-radius: var(--border-radius-xl) var(--border-radius-xl) 0 0;
}

.service-card:hover .service-card-front::before {
    transform: scaleX(1);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-2xl);
}

.service-icon {
    width: 100px;
    height: 100px;
    background: var(--gradient-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    position: relative;
    box-shadow: var(--shadow-xl);
    transition: all var(--transition-normal);
}

.service-icon::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: var(--gradient-primary);
    z-index: -1;
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.service-card:hover .service-icon::after {
    opacity: 1;
}

.service-card:hover .service-icon {
    transform: scale(1.1);
}

.service-icon i {
    font-size: 2.5rem;
    color: white;
    z-index: 1;
}

.service-card h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-weight: 700;
    font-size: 1.25rem;
    text-align: center;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.service-card p {
    line-height: 1.7;
    color: var(--text-medium);
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    margin-bottom: 1rem;
}

.service-card-back p {
    margin-bottom: 1.25rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    text-align: center;
}

.service-card-back ul {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
    text-align: left;
    width: 100%;
}

.service-card-back li {
    margin-bottom: 1rem;
    padding-left: 1.75rem;
    position: relative;
    font-size: 0.95rem;
    line-height: 1.6;
    font-weight: 400;
    color: var(--text-dark);
}

.service-card-back li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
    font-size: 1.2rem;
    top: 0.1rem;
}

/* Team Section */
.team {
    padding: 80px 0;
    background-color: var(--bg-light);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.team-member {
    background-color: var(--bg-white);
    border-radius: var(--border-radius-xl);
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: all var(--transition-normal);
    border: 2px solid var(--primary-color);
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.team-member::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-accent);
    transform: scaleX(0);
    transition: transform var(--transition-normal);
    border-radius: var(--border-radius-xl) var(--border-radius-xl) 0 0;
}

.team-member:hover::before {
    transform: scaleX(1);
}

.team-member:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-2xl);
    border-color: var(--accent-color);
}

.team-member .member-photo {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    position: relative;
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-normal);
}

.team-member:hover .member-photo {
    transform: scale(1.1);
    box-shadow: var(--shadow-xl);
}

.team-member .member-photo::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: var(--gradient-primary);
    z-index: -1;
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.team-member:hover .member-photo::after {
    opacity: 1;
}

.team-member .member-photo i {
    font-size: 3rem;
    color: white;
    z-index: 1;
}

.team-member h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-weight: 700;
    font-size: 1.25rem;
}

.team-member .position {
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

.team-member p {
    color: var(--text-medium);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.team-member-back p {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0.5rem 0;
    text-align: center;
}

.member-photo {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.member-photo i {
    font-size: 3rem;
    color: white;
}

.team-member h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.position {
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Contact Section */
.contact {
    padding: 80px 0;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background-color: var(--bg-light);
    border-radius: 12px;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--secondary-color);
    margin-top: 0.25rem;
}

.contact-item h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.contact-item p {
    margin: 0;
    color: black;
}

/* Contact Form */
.contact-form {
    background-color: var(--bg-light);
    padding: 2rem;
    border-radius: 12px;
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 16px 16px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: var(--bg-white);
    font-family: inherit;
    min-height: 48px;
    box-sizing: border-box;
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
    padding-top: 20px;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(209, 187, 158, 0.1);
    transform: translateY(-1px);
}

.form-group label {
    position: absolute;
    left: 16px;
    top: 16px;
    color: var(--text-muted);
    transition: all 0.3s ease;
    pointer-events: none;
    background-color: var(--bg-white);
    padding: 0 4px;
    font-size: 1rem;
}

.form-group input:focus + label,
.form-group textarea:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:not(:placeholder-shown) + label,
.form-group select:focus + label {
    top: -8px;
    font-size: 0.875rem;
    color: var(--secondary-color);
    font-weight: 600;
}

.form-group select + label {
    top: -8px;
    font-size: 0.875rem;
    color: var(--secondary-color);
    font-weight: 600;
}

/* Mobile form enhancements */
@media (max-width: 768px) {
    .form-group input,
    .form-group textarea,
    .form-group select {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 18px 16px;
        min-height: 52px;
    }

    .form-group textarea {
        min-height: 140px;
    }

    .form-group label {
        font-size: 1rem;
        top: 18px;
    }

    .form-group input:focus + label,
    .form-group textarea:focus + label,
    .form-group input:not(:placeholder-shown) + label,
    .form-group textarea:not(:placeholder-shown) + label {
        top: -10px;
        font-size: 0.9rem;
    }
}

/* Footer */
.footer {
    background-color: #99D7CA;
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-logo-img {
    height: 48px;
    width: auto;
    margin-right: 12px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

.footer-company-name {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.footer-company-name-en,
.footer-company-name-th {
    color: white;
    font-weight: 600;
    line-height: 1.2;
    margin: 0;
}

.footer-company-name-en {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
}

.footer-company-name-th {
    font-family: 'Sarabun', sans-serif;
    font-size: 0.9rem;
}

.footer-company-name-separator {
    width: 100%;
    height: 1px;
    background-color: white;
    margin: 2px 0;
}

.footer-logo i {
    font-size: 1.5rem;
    margin-right: 10px;
    color: var(--accent-color);
}

.footer-section h4 {
    color: black;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--accent-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background-color: var(--secondary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
}

.footer .contact-info p {
    color: white;
}

.footer-bottom {
    border-top: 1px solid #374151;
    padding-top: 2rem;
    text-align: center;
    color: #9ca3af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--bg-white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow-md);
        padding: 2rem 0;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-item {
        margin: 1rem 0;
        width: 100%;
    }

    .nav-link {
        display: block;
        padding: 16px 24px;
        font-size: 1.1rem;
        min-height: 48px;
        width: 100%;
        box-sizing: border-box;
    }

    .lang-toggle {
        margin: 1rem auto;
        min-height: 44px;
        padding: 12px 20px;
    }

    .hero {
        min-height: auto;
        padding: 120px 0 80px;
        display: block;
    }

    .hero-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        gap: 3rem;
        padding: 0 20px;
        max-width: 100%;
    }

    .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        width: 100%;
        max-width: 600px;
        order: 1;
    }

    .hero-content h1 {
        font-size: clamp(1.5rem, 6vw, 2.2rem);
        line-height: 1.2;
        margin-bottom: 1.2rem;
        word-wrap: break-word;
        hyphens: auto;
        text-align: center;
        width: 100%;
        padding: 0 10px;
        box-sizing: border-box;
    }

    .hero-content p {
        font-size: 0.95rem;
        line-height: 1.5;
        margin-bottom: 1.5rem;
        text-align: center;
        max-width: 100%;
        width: 100%;
        padding: 0 10px;
        box-sizing: border-box;
    }

    .hero-content ul {
        text-align: center;
        max-width: 100%;
        margin-bottom: 2.5rem;
        width: 100%;
    }

    .hero-content li {
        font-size: 1rem;
        padding-left: 0;
        margin-bottom: 1rem;
        line-height: 1.5;
        word-wrap: break-word;
        text-align: center;
        justify-content: center;
        display: flex;
        align-items: center;
        gap: 0.8rem;
    }

.hero-content li::before {
    order: -1;
    margin-left: 0;
    margin-right: 0.5rem;
}

/* New hero structure styles */
.hero-title {
    margin-bottom: 1.5rem;
    text-align: center;
    width: 100%;
    white-space: nowrap; /* No wrapping on desktop */
    overflow: hidden;
    text-overflow: ellipsis; /* Add ellipsis if needed */
}

.hero-subtitle {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    text-align: center;
    max-width: 100%;
    width: 100%;
    color: rgba(255, 255, 255, 0.95);
    white-space: nowrap; /* No wrapping on desktop */
    overflow: hidden;
    text-overflow: ellipsis;
}

.hero-features {
    list-style: none;
    padding: 0;
    margin-bottom: 2.5rem;
    width: 100%;
    max-width: 100%;
}

.hero-feature-item {
    font-size: 1rem;
    padding-left: 0;
    margin-bottom: 1rem;
    line-height: 1.5;
    text-align: center;
    justify-content: center;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: rgba(255, 255, 255, 0.9);
    white-space: nowrap; /* No wrapping on desktop */
}

.hero-feature-item .feature-check {
    color: var(--accent-color);
    font-weight: bold;
    font-size: 1.2rem;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    flex-shrink: 0;
}

.hero-feature-item .feature-text {
    flex: 1;
    text-align: left;
    white-space: nowrap; /* No wrapping on desktop */
    overflow: hidden;
    text-overflow: ellipsis;
}

.hero-description {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    text-align: center;
    max-width: 100%;
    width: 100%;
    color: rgba(255, 255, 255, 0.95);
    white-space: nowrap; /* No wrapping on desktop */
    overflow: hidden;
    text-overflow: ellipsis;
}

    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
        width: 100%;
        max-width: 320px;
    }

    .hero-image {
        width: clamp(280px, 80vw, 350px);
        height: clamp(280px, 80vw, 350px);
        margin: 0 auto;
        order: 2;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 3rem;
        padding: 0 20px;
    }

    .about-text h3 {
        font-size: 1.8rem;
        margin-bottom: 1.5rem;
    }

    .about-text p {
        font-size: 1.1rem;
        line-height: 1.7;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        margin-top: 2rem;
    }

    .stat-item {
        padding: 2rem 1rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 0 20px;
    }

    .service-card {
        min-height: 450px;
    }

    .service-card-front,
    .service-card-back {
        padding: 2rem 1.5rem;
    }

    .service-card h3 {
        font-size: 1.2rem;
        margin-bottom: 1rem;
    }

    .team-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 0 20px;
    }

    .team-member {
        padding: 2rem 1.5rem;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 3rem;
        padding: 0 20px;
    }

    .contact-info {
        gap: 1.5rem;
    }

    .contact-item {
        padding: 2rem 1.5rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .contact-item i {
        align-self: flex-start;
    }

    .contact-form {
        padding: 2.5rem 1.5rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
        padding: 0 20px;
    }

    .footer-section h4 {
        margin-bottom: 1.5rem;
    }

    .footer-section ul li {
        margin-bottom: 1rem;
    }

    .social-links {
        justify-content: center;
    }

    h1 {
        font-size: clamp(1.8rem, 6vw, 2rem);
    }

    h2 {
        font-size: clamp(1.5rem, 5vw, 1.875rem);
    }

    h3 {
        font-size: clamp(1.3rem, 4vw, 1.5rem);
    }

    .btn {
        min-height: 48px;
        padding: 14px 28px;
        font-size: 1rem;
        width: 100%;
        max-width: 300px;
    }

    .section-header {
        margin-bottom: 3rem;
        padding: 0 20px;
    }

    .container {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero {
        padding: 100px 0 60px;
    }

    .hero-content h1 {
        font-size: 1.8rem;
        line-height: 1.1;
        margin-bottom: 1rem;
        word-break: break-word;
        hyphens: auto;
        text-align: center;
    }

    .hero-content p {
        font-size: 0.95rem;
        line-height: 1.5;
        margin-bottom: 1rem;
        text-align: center;
        word-wrap: break-word;
    }

    .hero-content ul {
        margin-bottom: 1.5rem;
    }

    .hero-content li {
        font-size: 0.9rem;
        padding-left: 1.8rem;
        margin-bottom: 0.6rem;
        line-height: 1.4;
        word-wrap: break-word;
    }

    .hero-content li::before {
        width: 20px;
        height: 20px;
        font-size: 1rem;
    }

    .hero-image {
        width: 250px;
        height: 250px;
        margin: 1rem auto;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 0.8rem;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        min-height: 44px;
        padding: 12px 24px;
        font-size: 0.95rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .service-card {
        padding: 1.5rem;
        min-height: 400px;
    }

    .service-card h3 {
        font-size: 1.1rem;
        margin-bottom: 0.8rem;
    }

    .about,
    .services,
    .team,
    .contact {
        padding: 50px 0;
    }

    .section-header {
        margin-bottom: 2rem;
    }

    .section-header h2 {
        font-size: 1.5rem;
        margin-bottom: 0.8rem;
    }

    .section-header p {
        font-size: 1rem;
    }
}

/* Mobile-specific text wrapping (overrides desktop no-wrap) */
@media (max-width: 768px) {
    .hero-title {
        white-space: normal; /* Enable wrapping on mobile */
        word-wrap: break-word;
        hyphens: auto;
        overflow: visible;
        text-overflow: clip;
    }

    .hero-subtitle {
        white-space: normal; /* Enable wrapping on mobile */
        word-wrap: break-word;
        hyphens: auto;
        overflow: visible;
        text-overflow: clip;
    }

    .hero-feature-item {
        white-space: normal; /* Allow text wrapping */
        word-wrap: break-word; /* Enable word breaking */
        hyphens: auto; /* Enable hyphenation */
        flex-direction: column; /* Stack text and bullet vertically */
        align-items: center; /* Center align all items */
        justify-content: center; /* Center justify */
        gap: 0.5rem; /* Small gap between text and bullet */
        text-align: center; /* Center align text */
        padding: 1rem 0.5rem; /* Add padding for breathing room */
        margin-bottom: 1.5rem; /* Space between items */
        position: relative; /* Ensure proper positioning context */
        overflow: visible; /* Allow content to be visible */
        text-overflow: clip; /* Don't cut off text */
    }

    .hero-feature-item .feature-check {
        flex-shrink: 0; /* Prevent checkmark from shrinking */
        margin-top: 0; /* Remove top margin */
        align-self: center; /* Center align */
        position: relative; /* Override absolute positioning */
        left: auto; /* Remove absolute left positioning */
        width: 36px; /* Larger width */
        height: 36px; /* Larger height */
        font-size: 1.4rem; /* Larger font size */
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255,255,255,0.25); /* More visible background */
        border-radius: 50%;
        box-shadow: 0 4px 12px rgba(0,0,0,0.25); /* Enhanced shadow */
        order: 2; /* Put bullet below text */
    }

    .hero-feature-item .feature-text {
        white-space: normal; /* Allow text wrapping */
        word-wrap: break-word; /* Enable word breaking */
        hyphens: auto; /* Enable hyphenation */
        overflow: visible; /* Allow text to be visible */
        text-overflow: clip; /* Don't cut off text */
        text-align: center; /* Center align text */
        flex: 1; /* Allow text to take remaining space */
        line-height: 1.4; /* Standard line height */
        margin: 0; /* Remove any default margins */
        padding: 0; /* Remove padding */
        font-size: 0.9rem; /* Smaller text for mobile screens */
        box-sizing: border-box;
        order: 1; /* Put text above bullet */
    }

    .hero-description {
        white-space: normal; /* Enable wrapping on mobile */
        word-wrap: break-word;
        hyphens: auto;
        overflow: visible;
        text-overflow: clip;
    }
}

/* Extra small screens (320px and below) */
@media (max-width: 360px) {
    .hero-content h1 {
        font-size: 1.6rem;
        margin-bottom: 0.8rem;
    }

    .hero-content p {
        font-size: 0.9rem;
        margin-bottom: 0.8rem;
    }

    .hero-content li {
        font-size: 0.85rem;
        padding-left: 1.6rem;
        margin-bottom: 0.5rem;
    }

    .hero-image {
        width: 220px;
        height: 220px;
    }

    .btn {
        max-width: 260px;
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .container {
        padding: 0 12px;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Form Validation Styles */
.form-group input:invalid,
.form-group textarea:invalid,
.form-group select:invalid {
    border-color: #ef4444;
}

.form-group input:valid,
.form-group textarea:valid,
.form-group select:valid {
    border-color: var(--success-color);
}

/* Success Message */
.success-message {
    background-color: var(--success-color);
    color: white;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: none;
}

.success-message.show {
    display: block;
    animation: fadeInUp 0.5s ease-out;
}

/* Error Message */
.error-message {
    background-color: #ef4444;
    color: white;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: none;
}

.error-message.show {
    display: block;
    animation: fadeInUp 0.5s ease-out;
}
