/* =========================================================
   ช่างเก่งดีไซน์ — Website Styles
   ========================================================= */

:root {
  --ink: #1b2430;
  --ink-soft: #445168;
  --gold: #c9a227;
  --gold-light: #e4c65e;
  --steel: #2e4053;
  --bg: #f7f5f1;
  --bg-alt: #eeeae2;
  --white: #ffffff;
  --line: #06c755;
  --fb: #1877f2;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(27, 36, 48, 0.12);
  --shadow-sm: 0 4px 14px rgba(27, 36, 48, 0.08);
  --container: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Kanit', 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

a { color: inherit; text-decoration: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, opacity .15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: #22190a;
  box-shadow: 0 8px 20px rgba(201, 162, 39, 0.35);
}
.btn-line { background: var(--line); color: #fff; box-shadow: 0 8px 20px rgba(6,199,85,.3); }
.btn-fb { background: var(--fb); color: #fff; box-shadow: 0 8px 20px rgba(24,119,242,.3); }
.btn-ghost {
  background: transparent;
  border-color: rgba(255,255,255,.5);
  color: #fff;
}
.header-cta .btn-ghost { border-color: var(--ink); color: var(--ink); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(247, 245, 241, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(27,36,48,.08);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  gap: 20px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark {
  width: 42px; height: 42px;
  background: var(--ink);
  color: var(--gold);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 22px;
  flex-shrink: 0;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-size: 17px; }
.brand-text small { font-size: 11px; color: var(--ink-soft); }

.main-nav { display: flex; gap: 28px; }
.main-nav a { font-size: 15px; font-weight: 500; color: var(--ink-soft); }
.main-nav a:hover { color: var(--ink); }

.header-cta { display: flex; align-items: center; gap: 14px; }
.header-cta .btn-ghost { padding: 9px 18px; font-size: 14px; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--ink); border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15,20,28,.75) 0%, rgba(15,20,28,.55) 45%, rgba(15,20,28,.9) 100%);
}
.hero-content {
  position: relative;
  color: #fff;
  padding: 120px 24px 80px;
  max-width: 780px;
}
.eyebrow {
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: 13px;
  color: var(--gold-light);
  font-weight: 600;
  margin: 0 0 16px;
}
.hero h1 {
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.2;
  margin: 0 0 20px;
  font-weight: 700;
}
.hero-sub {
  font-size: 17px;
  color: rgba(255,255,255,.88);
  max-width: 560px;
  margin: 0 0 32px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 32px; }
.hero-points {
  display: flex; flex-wrap: wrap; gap: 12px 24px;
  list-style: none; padding: 0; margin: 0;
  font-size: 14px; color: rgba(255,255,255,.85);
}
.hero-points li { display: flex; align-items: center; gap: 8px; }
.hero-points li::before {
  content: "✓";
  color: var(--gold-light);
  font-weight: 700;
}

/* ---------- Trust strip ---------- */
.trust-strip {
  background: var(--ink);
  color: #fff;
  padding: 34px 0;
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.trust-item { display: flex; align-items: center; gap: 14px; }
.trust-icon {
  width: 48px; height: 48px;
  background: rgba(201,162,39,.15);
  color: var(--gold-light);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.trust-item p { margin: 0; display: flex; flex-direction: column; font-size: 13.5px; }
.trust-item strong { font-size: 14.5px; margin-bottom: 2px; }
.trust-item span { color: rgba(255,255,255,.65); }

/* ---------- Sections ---------- */
.section { padding: 90px 0; }
.section-alt { background: var(--bg-alt); }
.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: 13px;
  font-weight: 700;
  color: var(--gold);
  margin: 0 0 12px;
}
.section-title {
  font-size: clamp(26px, 3.4vw, 36px);
  margin: 0 0 16px;
  font-weight: 700;
  max-width: 640px;
}
.section-desc {
  color: var(--ink-soft);
  max-width: 560px;
  margin: 0 0 44px;
  font-size: 15.5px;
}

/* ---------- Services ---------- */
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.service-icon { font-size: 34px; margin-bottom: 14px; }
.service-card h3 { margin: 0 0 8px; font-size: 18px; }
.service-card p { margin: 0; color: var(--ink-soft); font-size: 14.5px; }

/* ---------- Portfolio ---------- */
.filter-bar { display: flex; gap: 10px; margin-bottom: 32px; flex-wrap: wrap; }
.filter-btn {
  padding: 9px 20px;
  border-radius: 999px;
  border: 1.5px solid rgba(27,36,48,.15);
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  color: var(--ink-soft);
  transition: all .15s ease;
}
.filter-btn:hover { border-color: var(--gold); color: var(--ink); }
.filter-btn.active { background: var(--ink); border-color: var(--ink); color: #fff; }

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.gallery-item {
  position: relative;
  border: none;
  padding: 0;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 4/3;
  box-shadow: var(--shadow-sm);
}
.gallery-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}
.gallery-item:hover img { transform: scale(1.08); }
.gallery-item span {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 14px 16px 12px;
  background: linear-gradient(0deg, rgba(15,20,28,.85), transparent);
  color: #fff;
  font-size: 13.5px;
  text-align: left;
  font-weight: 500;
}
.gallery-item.hidden { display: none; }

/* ---------- Video portfolio ---------- */
.video-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  padding: 6px 2px 14px;
}
.video-card {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background: #000;
  transition: transform .25s ease, box-shadow .25s ease;
}
.video-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
.video-card video {
  display: block;
  width: 100%;
  aspect-ratio: 9/16;
  max-height: 480px;
  margin: 0 auto;
  background: #000;
  object-fit: cover;
}
.video-card span {
  display: block;
  padding: 14px 16px 16px;
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  text-align: center;
}
.video-more {
  display: flex;
  justify-content: center;
  margin-top: 34px;
}

/* ---------- Why us ---------- */
.why-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: center;
}
.check-list {
  list-style: none;
  padding: 0;
  margin: 0 0 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.check-list li {
  position: relative;
  padding-left: 30px;
  font-size: 15px;
  color: var(--ink-soft);
}
.check-list li::before {
  content: "✓";
  position: absolute; left: 0; top: 0;
  width: 20px; height: 20px;
  background: var(--gold);
  color: #22190a;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.why-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* ---------- Promotion ---------- */
.promo-banner {
  background: linear-gradient(135deg, #1b2430, #2e4053);
  color: #fff;
  padding: 80px 0;
}
.promo-eyebrow { color: var(--gold-light); }
.promo-inner h2 {
  font-size: clamp(24px, 3vw, 32px);
  margin: 0 0 32px;
}
.promo-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 24px;
}
.promo-card {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: 26px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.promo-num {
  font-size: 30px;
  font-weight: 700;
  color: var(--gold-light);
}
.promo-card span:last-child { font-size: 13.5px; color: rgba(255,255,255,.75); }
.promo-note { font-size: 12.5px; color: rgba(255,255,255,.55); margin: 0 0 28px; }

/* ---------- Service area ---------- */
.area-chips {
  display: flex; flex-wrap: wrap; gap: 12px;
}
.area-chips span {
  padding: 10px 20px;
  background: var(--white);
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
  color: var(--ink-soft);
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: stretch;
}
.contact-list { list-style: none; padding: 0; margin: 0 0 32px; display: flex; flex-direction: column; gap: 20px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-icon { font-size: 20px; line-height: 1.4; }
.contact-list strong { display: block; margin-bottom: 2px; font-size: 15px; }
.contact-list p { margin: 0; color: var(--ink-soft); font-size: 14.5px; }
.contact-list a:hover { color: var(--gold); }
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.contact-actions .btn-ghost { border-color: var(--ink); color: var(--ink); }
.contact-map {
  min-height: 340px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: rgba(255,255,255,.75); padding: 40px 0; }
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
}
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand strong { color: #fff; display: block; margin-bottom: 2px; }
.footer-brand p { margin: 0; font-size: 12.5px; }
.footer-nav { display: flex; gap: 22px; }
.footer-nav a { font-size: 14px; }
.footer-nav a:hover { color: var(--gold-light); }
.footer-copy { margin: 0; font-size: 12.5px; }

/* ---------- Floating action buttons ---------- */
.fab-group {
  position: fixed;
  right: 20px;
  bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 90;
}
.fab {
  width: 54px; height: 54px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  box-shadow: 0 8px 22px rgba(0,0,0,.25);
  transition: transform .15s ease;
}
.fab:hover { transform: scale(1.08); }
.fab-line { background: var(--line); }
.fab-call { background: var(--gold); color: #22190a; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0;
  background: rgba(10,14,20,.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 40px;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 8px; }
.lightbox-close {
  position: absolute; top: 20px; right: 26px;
  background: none; border: none;
  color: #fff; font-size: 36px;
  cursor: pointer; line-height: 1;
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .why-grid, .contact-grid { grid-template-columns: 1fr; }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .promo-cards { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .video-row { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .why-media { order: -1; }
}

@media (max-width: 760px) {
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .header-cta .btn-ghost { display: none; }

  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--bg);
    padding: 20px 24px;
    gap: 16px;
    border-bottom: 1px solid rgba(27,36,48,.08);
    box-shadow: var(--shadow);
  }

  .hero-content { padding: 100px 20px 60px; }
  .service-grid { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; }
  .section { padding: 60px 0; }
}

@media (max-width: 520px) {
  .gallery { grid-template-columns: 1fr; }
  .trust-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1 1 auto; justify-content: center; }
  .video-row { grid-template-columns: 1fr; max-width: 320px; margin: 0 auto; }
}
