/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Sarabun', Helvetica, Verdana, Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  color: #444;
  background: #fff;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: #1a6daa; transition: color .2s; }
a:hover { color: #0f4c7a; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid #f7941d;
  outline-offset: 2px;
}
h1, h2, h3, h4, h5, h6 {
  color: #222;
  font-weight: 600;
  line-height: 1.4;
}
.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

/* Skip to content link for keyboard accessibility */
.skip-link {
  position: absolute;
  top: -40px;
  left: 16px;
  background: #222;
  color: #fff;
  padding: 8px 16px;
  border-radius: 0 0 4px 4px;
  z-index: 2000;
  transition: top .2s;
}
.skip-link:focus { top: 0; color: #fff; }

/* ===== TOP BAR ===== */
.top-bar {
  background: #d97706; /* High contrast amber/orange for WCAG AA */
  color: #fff;
  text-align: center;
  padding: 8px 20px;
  font-size: 14px;
}
.top-bar a { color: #fff; margin: 0 6px; font-size: 16px; }
.top-bar a:hover { color: #222; }
.top-bar-text { margin-bottom: 4px; font-weight: 500; }
.top-bar-icons a { display: inline-block; margin: 0 6px; }

/* ===== HEADER / NAV ===== */
.site-header {
  background: rgba(255,255,255,0.97);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  position: sticky;
  top: 0;
  z-index: 999;
  transition: box-shadow .3s;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  max-width: 1200px;
  margin: 0 auto;
}
.logo img { height: 50px; width: auto; }
.nav-links { display: flex; list-style: none; gap: 4px; }
.nav-links li { position: relative; }
.nav-links li a {
  display: block;
  padding: 12px 14px;
  color: #222;
  font-size: 15px;
  font-weight: 500;
  border-radius: 4px;
  transition: color .2s, background .2s;
  white-space: nowrap;
}
.nav-links li a:hover { color: #c25e00; background: #fff7ed; }
.nav-links li a.active { color: #c25e00; font-weight: 700; background: #fff7ed; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
  padding: 10px;
  background: transparent;
  border: none;
  z-index: 1001;
}
.hamburger span {
  width: 28px; height: 3px;
  background: #222;
  border-radius: 3px;
  transition: transform .3s, opacity .3s;
}
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 6px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -6px); }

/* ===== HERO SECTION ===== */
.hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)),
              url('../images/IMG_0416-1024x765.jpg') center/cover no-repeat;
  color: #fff;
  padding: 60px 20px;
}
.hero-content { max-width: 900px; }
.hero h1 {
  font-size: 2.4rem;
  color: #fff;
  margin-bottom: 16px;
  font-weight: 700;
  text-shadow: 1px 2px 6px rgba(0,0,0,0.5);
}
.hero p {
  font-size: 1.15rem;
  line-height: 1.7;
  margin-bottom: 24px;
  color: #f3f4f6;
}
.hero .btn-primary {
  display: inline-block;
  background: #f7941d;
  color: #111;
  padding: 14px 36px;
  border-radius: 4px;
  font-size: 1.1rem;
  font-weight: 700;
  transition: background .3s, transform .2s;
}
.hero .btn-primary:hover { background: #ffa73b; transform: translateY(-2px); color: #000; }

/* ===== SECTION STYLES ===== */
.section { padding: 60px 0; }
.section-alt { background: #f8f9fa; }
.section-orange { background: #d97706; color: #fff; }
.section-dark { background: #222; color: #fff; }
.section-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 16px;
  color: #222;
}
.section-orange .section-title,
.section-dark .section-title { color: #fff; }
.section-subtitle {
  text-align: center;
  font-size: 1.05rem;
  color: #555;
  max-width: 800px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

/* ===== ABOUT / WHY US ===== */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
  margin-top: 30px;
}
.why-card {
  background: #fff;
  border-radius: 8px;
  padding: 30px 24px;
  text-align: center;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  transition: transform .3s, box-shadow .3s;
}
.why-card:hover { transform: translateY(-4px); box-shadow: 0 6px 20px rgba(0,0,0,0.1); }
.why-card i {
  font-size: 2.4rem;
  color: #d97706;
  margin-bottom: 16px;
}
.why-card h3 { font-size: 1.1rem; margin-bottom: 10px; color: #222; }
.why-card p { font-size: 0.95rem; color: #555; line-height: 1.6; }

/* ===== COURSES ===== */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
}
.course-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
  transition: transform .3s, box-shadow .3s;
  display: flex;
  flex-direction: column;
}
.course-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.12); }
.course-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.course-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.course-card-body h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
  color: #222;
}
.course-card-body p {
  font-size: 0.95rem;
  color: #555;
  margin-bottom: 16px;
  line-height: 1.6;
  flex-grow: 1;
}
.course-meta {
  display: flex;
  gap: 16px;
  font-size: 0.9rem;
  color: #444;
  font-weight: 500;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.course-meta span i { margin-right: 4px; color: #d97706; }
.btn-course {
  display: inline-block;
  align-self: flex-start;
  background: #f7941d;
  color: #111;
  padding: 10px 24px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: background .3s;
}
.btn-course:hover { background: #e0830f; color: #000; }

/* ===== COURSE DETAIL ===== */
.course-detail { padding: 45px 0; border-bottom: 1px solid #e5e7eb; }
.course-detail:last-of-type { border-bottom: none; }
.course-detail h2, .course-detail h3.course-heading {
  font-size: 1.6rem;
  color: #222;
  margin-bottom: 12px;
}
.course-detail .num {
  color: #d97706;
  font-weight: 700;
}
.course-detail .detail-desc {
  font-size: 1.05rem;
  color: #444;
  line-height: 1.8;
  margin-bottom: 16px;
}
.course-detail .detail-list {
  list-style: none;
  padding: 0;
}
.course-detail .detail-list li {
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.98rem;
  line-height: 1.7;
  color: #444;
}
.course-detail .detail-list li strong { color: #222; }
.course-detail .detail-list li i {
  color: #d97706;
  margin-right: 8px;
  width: 18px;
}
.price-tag {
  display: inline-block;
  background: #f7941d;
  color: #111;
  padding: 8px 20px;
  border-radius: 4px;
  font-size: 1.1rem;
  font-weight: 700;
  margin: 16px 0;
}
.bank-info {
  background: #f8f9fa;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 20px;
  margin: 16px 0;
}
.bank-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid #e5e7eb;
  flex-wrap: wrap;
}
.bank-row:last-child { border-bottom: none; }
.bank-row img { height: 32px; width: auto; }
.bank-row span { font-size: 0.95rem; color: #333; font-weight: 500; }
.phone-highlight { color: #b91c1c; font-weight: 700; margin-top: 8px; }

/* ===== CTA BANNER ===== */
.cta-banner {
  background: linear-gradient(135deg, #222 0%, #444 100%);
  color: #fff;
  text-align: center;
  padding: 50px 20px;
}
.cta-banner h2 { color: #fff; font-size: 2rem; margin-bottom: 12px; }
.cta-banner p { font-size: 1.1rem; margin-bottom: 24px; color: rgba(255,255,255,0.9); max-width: 700px; margin-left: auto; margin-right: auto; }
.btn-cta {
  display: inline-block;
  background: #f7941d;
  color: #111;
  padding: 14px 36px;
  border-radius: 4px;
  font-size: 1.1rem;
  font-weight: 700;
  transition: background .3s, transform .2s;
}
.btn-cta:hover { background: #ffa73b; transform: translateY(-2px); color: #000; }

/* ===== LINE CTA ===== */
.line-cta {
  text-align: center;
  padding: 30px 20px;
}
.line-cta img {
  max-width: 700px;
  width: 100%;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

/* ===== GALLERY ===== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}
.gallery-grid a {
  display: block;
  overflow: hidden;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: transform .3s;
}
.gallery-grid a:hover { transform: scale(1.02); }
.gallery-grid img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform .4s;
}
.gallery-grid a:hover img { transform: scale(1.06); }
.gallery-section-title {
  text-align: center;
  font-size: 1.6rem;
  margin-bottom: 24px;
  color: #222;
}

/* ===== KNOWLEDGE TABLES & CONTENT ===== */
.knowledge-box {
  background: #fff;
  border-radius: 8px;
  padding: 32px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  margin-bottom: 30px;
}
.knowledge-box h2, .knowledge-box h3 {
  margin: 20px 0 12px;
  color: #222;
}
.knowledge-box p, .knowledge-box li {
  margin-bottom: 12px;
  line-height: 1.8;
  color: #444;
}
.table-responsive {
  overflow-x: auto;
  margin: 20px 0;
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
.data-table th, .data-table td {
  border: 1px solid #e5e7eb;
  padding: 10px 14px;
  text-align: center;
}
.data-table th {
  background: #f7941d;
  color: #111;
  font-weight: 700;
}
.data-table tr:nth-child(even) { background: #f8f9fa; }

/* ===== CONTACT ===== */
.contact-section { background: #f8f9fa; }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.contact-info h3 { font-size: 1.4rem; color: #222; margin-bottom: 16px; }
.contact-info p { margin-bottom: 12px; color: #444; line-height: 1.7; }
.contact-info p i { color: #d97706; margin-right: 8px; width: 20px; }
.contact-form h3 { font-size: 1.4rem; color: #222; margin-bottom: 16px; }
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  color: #222;
  font-size: 0.95rem;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color .2s;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: #d97706;
  box-shadow: 0 0 0 3px rgba(247, 148, 29, 0.2);
}
.contact-form textarea { min-height: 120px; resize: vertical; }
.btn-submit {
  background: #f7941d;
  color: #111;
  border: none;
  padding: 12px 32px;
  border-radius: 4px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background .3s;
  font-family: inherit;
}
.btn-submit:hover { background: #e0830f; }
.form-notice {
  margin-top: 12px;
  padding: 12px;
  border-radius: 4px;
  font-size: 0.9rem;
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}

/* ===== MAP ===== */
.map-section { padding: 0; }
.map-section iframe {
  width: 100%;
  height: 360px;
  border: none;
  display: block;
}

/* ===== FOOTER ===== */
.site-footer {
  background: #1f2937;
  color: #d1d5db;
  text-align: center;
  padding: 36px 20px;
  font-size: 0.95rem;
}
.site-footer p { margin-bottom: 8px; }
.site-footer a { color: #fbbf24; }
.site-footer a:hover { color: #fde68a; }
.footer-links {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin: 14px 0;
}

/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 44px;
  height: 44px;
  background: #f7941d;
  color: #111;
  border: none;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0,0,0,0.25);
  transition: background .3s, transform .2s;
  z-index: 999;
}
.back-to-top:hover { background: #ffa73b; transform: translateY(-3px); }
.back-to-top.show { display: flex; }

/* ===== LIGHTBOX MODAL ===== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.lightbox.active { display: flex; }
.lightbox img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 6px;
  box-shadow: 0 4px 25px rgba(0,0,0,0.5);
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 28px;
  background: #fff;
  color: #111;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 22px;
  font-weight: 700;
  cursor: pointer;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
  .nav-links li a { padding: 10px 10px; font-size: 14px; }
}
@media (max-width: 768px) {
  .hamburger { display: flex; }
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: #fff;
    flex-direction: column;
    padding: 70px 0 20px;
    box-shadow: -4px 0 20px rgba(0,0,0,0.15);
    transition: right .35s ease;
    overflow-y: auto;
    z-index: 1000;
  }
  .nav-links.open { right: 0; }
  .nav-links li a {
    padding: 14px 24px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 15px;
    border-radius: 0;
  }
  .overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 998;
  }
  .overlay.show { display: block; }
  .hero h1 { font-size: 1.6rem; }
  .hero p { font-size: 1rem; }
  .section-title { font-size: 1.5rem; }
  .contact-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  .gallery-grid img { height: 140px; }
  .course-detail h2, .course-detail h3.course-heading { font-size: 1.35rem; }
}
@media (max-width: 480px) {
  .hero { min-height: 50vh; padding: 40px 16px; }
  .hero h1 { font-size: 1.35rem; }
  .section { padding: 40px 0; }
  .courses-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
}
