/*
Theme Name: WINNER Academy
Theme URI: https://winneracademy.online/
Author: WINNER Academy
Description: ธีมเว็บไซต์และระบบจัดการคอร์ส ราคา โปรโมชั่น ผลงาน วิดีโอ และรีวิวสำหรับ WINNER Academy
Version: 1.0.33
Text Domain: winner-academy
*/

:root {
  --purple: #6a11cb;
  --purple-dark: #230544;
  --gold: #f3c969;
  --surface: #fff;
  --surface-alt: #f8f4fc;
  --page-bg: #f8f4fc;
  --text: #17131a;
  --muted: #69616e;
  --line: #e7ddef;
  --container: 1180px;
  --base-font-size: 16px;
  --hero-title-size: 88px;
  --section-title-size: 64px;
  --card-title-size: 22px;
  --teacher-title-size: 32px;
  --button-text-size: 16px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--text); background: var(--page-bg); font-family: "Prompt", sans-serif; font-size: var(--base-font-size); line-height: 1.65; }
body.admin-bar .site-header { top: 32px; }
img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
.container { width: min(calc(100% - 2.5rem), var(--container)); margin-inline: auto; }
.section { padding: clamp(4rem,8vw,7.5rem) 0; }
.section, .section-alt { background: var(--page-bg); }
.section-head { max-width: 720px; margin-bottom: 2.2rem; }
.kicker { margin: 0 0 .7rem; color: var(--purple); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.heading { margin: 0; font-size: clamp(2rem,5vw,var(--section-title-size)); line-height: 1.15; }
.copy { margin: 1rem 0 0; color: var(--muted); font-size: 1.05rem; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .7rem 1.25rem; border: 1px solid transparent; border-radius: 999px; font-size: var(--button-text-size); font-weight: 700; cursor: pointer; }
.btn-primary { color: #fff; background: var(--purple); box-shadow: 0 12px 28px color-mix(in srgb,var(--purple) 30%,transparent); }
.btn-light { color: var(--purple-dark); background: var(--surface); }

.site-header { position: sticky; top: 0; z-index: 50; color: #fff; background: color-mix(in srgb,var(--purple-dark) 94%,transparent); backdrop-filter: blur(14px); }
.nav-inner { width: min(calc(100% - 2.5rem),1500px); min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: flex; min-width: 0; align-items: center; gap: .9rem; font-weight: 800; }
.brand span { max-width: 470px; line-height: 1.35; }
.brand img, .brand .custom-logo { display: block; flex: 0 0 auto; width: auto; max-width: 158px; height: 62px; border-radius: 0; object-fit: contain; object-position: left center; }
.main-menu { display: flex; flex: 0 0 auto; align-items: center; gap: clamp(.65rem,1.25vw,1.2rem); margin: 0; padding: 0; list-style: none; }
.main-menu a { color: rgba(255,255,255,.88); font-size: clamp(.84rem,1vw,1rem); font-weight: 500; white-space: nowrap; }
.main-menu a:hover { color: #fff; }
.menu-toggle { display: none; width: 44px; height: 44px; border: 0; border-radius: 50%; color: #fff; background: rgba(255,255,255,.12); }
.language-switcher { position: relative; flex: 0 0 auto; }
.language-switcher summary { display: flex; align-items: center; gap: .35rem; min-height: 42px; padding: .5rem .75rem; border: 1px solid rgba(255,255,255,.25); border-radius: 999px; color: #fff; font-weight: 700; cursor: pointer; list-style: none; }
.language-switcher summary::-webkit-details-marker { display: none; }
.language-menu { position: absolute; z-index: 70; top: calc(100% + .55rem); right: 0; display: grid; width: 190px; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: var(--surface); box-shadow: 0 16px 45px rgba(35,5,68,.2); }
.language-option { display: flex; align-items: center; gap: .7rem; width: 100%; padding: .62rem .8rem; border: 0; color: var(--text); background: transparent; text-align: left; cursor: pointer; }
.language-option:hover, .language-option:focus-visible { color: #fff; background: var(--purple); outline: none; }
.language-flag { display: inline-grid; flex: 0 0 30px; width: 30px; height: 30px; place-items: center; overflow: hidden; border: 2px solid rgba(106,17,203,.12); border-radius: 50%; background: #fff; font-size: 21px; line-height: 1; box-shadow: 0 3px 9px rgba(35,5,68,.13); }
.language-globe { line-height: 1; }
.language-option[aria-current="true"] { color: #fff; background: var(--purple); }
html, body { top: 0 !important; }
.goog-te-banner-frame,
.goog-te-banner-frame.skiptranslate,
.VIpgJd-ZVi9od-ORHb-OEVmcd,
iframe.goog-te-banner-frame,
#goog-gt-tt,
.goog-te-balloon-frame { display: none !important; visibility: hidden !important; }
body { top: 0 !important; }

.hero { min-height: calc(100svh - 76px); display: grid; align-items: center; color: #fff; background-position: center; background-size: cover; position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg,rgba(35,5,68,.96) 0%,rgba(35,5,68,.78) 47%,rgba(35,5,68,.18) 100%); }
.hero-content { position: relative; z-index: 1; width: 100%; max-width: none; padding-block: 7rem; }
.hero-logo { display: block; width: min(64vw,760px); max-height: 32vh; margin: 0 0 1.35rem; object-fit: contain; object-position: left center; filter: drop-shadow(0 16px 30px rgba(0,0,0,.3)); }
.hero h1 { max-width: 100%; margin: 0; font-size: clamp(3.6rem,4.65vw,var(--hero-title-size)); line-height: 1.06; letter-spacing: -.035em; text-wrap: balance; }
.hero p { max-width: 620px; margin: 1.3rem 0 0; color: rgba(255,255,255,.85); font-size: clamp(1rem,2vw,1.2rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }

.course-grid, .promo-grid, .work-grid, .archive-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.2rem; }
.content-card { overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); box-shadow: 0 16px 45px rgba(35,5,68,.08); }
.content-card-media { position: relative; display: block; flex: 0 0 auto; width: 100%; aspect-ratio: 1/1; overflow: hidden; background: #f4eef9; }
.content-card-media img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: contain; object-position: center; }
.content-card-body { display: flex; flex: 1; flex-direction: column; padding: 1.35rem; }
.content-card h3 { margin: 0; font-size: var(--card-title-size); line-height: 1.35; }
.content-card p { color: var(--muted); }
.badge { align-self: flex-start; margin-bottom: .8rem; padding: .28rem .65rem; border-radius: 999px; color: #fff; background: var(--purple); font-size: .82rem; font-weight: 700; }
.price { margin-top: auto; padding-top: 1rem; color: var(--purple); font-size: 1.35rem; font-weight: 800; }
.old-price { margin-left: .45rem; color: #958a9a; font-size: .92rem; text-decoration: line-through; }
.card-action { margin-top: 1rem; }
.empty-state { padding: 2rem; border: 1px dashed #cdb8dc; border-radius: 20px; color: var(--muted); text-align: center; }

.teachers { background: var(--page-bg); }
.teacher-stage { position: relative; min-height: 560px; overflow: hidden; border: 1px solid var(--line); border-radius: 34px; background: radial-gradient(circle at 50% 18%,#fff 0 10%,transparent 44%),linear-gradient(145deg,#f3eaff,#d8b4fe); }
.teacher-logo-panel { position: absolute; z-index: 2; top: 2rem; left: 50%; width: min(36%,420px); translate: -50% 0; pointer-events: none; }
.teacher-logo { display: block; width: 100%; height: 140px; object-fit: contain; opacity: 1; filter: drop-shadow(0 7px 14px rgba(35,5,68,.24)); }
.teacher-person { position: absolute; bottom: 0; height: 93%; filter: drop-shadow(0 20px 28px rgba(35,5,68,.2)); }
.teacher-person.winner { left: 7%; }
.teacher-person.golf { right: 7%; }
.teacher-cards { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1.2rem; margin-top: 1.2rem; }
.teacher-card { padding: clamp(1.5rem,3vw,2.4rem); border-top: 4px solid var(--purple); background: var(--surface); box-shadow: 0 18px 52px rgba(35,5,68,.08); }
.teacher-card h3 { margin: 0; font-size: var(--teacher-title-size); }
.teacher-role { color: var(--purple); font-weight: 700; }

.work-card { position: relative; overflow: hidden; border-radius: 20px; background: var(--purple-dark); aspect-ratio: 1/1; }
.work-grid > article { min-width: 0; }
.work-grid .work-card { display: block; }
.work-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.work-card:hover img { transform: scale(1.04); }
.work-card-overlay { position: absolute; inset: auto 0 0; padding: 3rem 1.1rem 1rem; color: #fff; background: linear-gradient(transparent,rgba(20,2,36,.9)); }
.video-frame { aspect-ratio: 16/9; overflow: hidden; border-radius: 20px; background: #000; }
.video-frame iframe, .video-frame video { width: 100%; height: 100%; border: 0; }

.reviews-head { display: flex; align-items: end; justify-content: space-between; gap: 1.5rem; }
.google-score { flex: 0 0 auto; padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.google-score strong { color: var(--purple); font-size: 2.1rem; }
.review-carousel { width: min(100%,940px); margin-inline: auto; }
.review-viewport { overflow-x: auto; border: 1px solid var(--line); border-radius: 30px; background: linear-gradient(145deg,#f8f4fc,#eee3f8); box-shadow: 0 24px 70px rgba(35,5,68,.13); scroll-snap-type: x mandatory; scrollbar-width: none; touch-action: pan-y; }
.review-carousel.is-ready .review-viewport { overflow: hidden; }
.review-track { display: flex; transition: transform .42s cubic-bezier(.22,.8,.28,1); }
.review-slide { flex: 0 0 100%; min-height: clamp(430px,66vw,760px); margin: 0; padding: 1.2rem; display: grid; place-items: center; scroll-snap-align: center; }
.review-slide img { display: block; width: auto; max-width: 100%; max-height: 730px; border-radius: 18px; box-shadow: 0 12px 34px rgba(35,5,68,.12); }
.review-controls { display: grid; grid-template-columns: 48px 1fr 48px; gap: .8rem; align-items: center; margin-top: 1rem; }
.review-arrow { width: 48px; height: 48px; border: 0; border-radius: 50%; color: #fff; background: var(--purple); cursor: pointer; }
.review-dots { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; }
.review-dot { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 999px; background: #cdb9dd; cursor: pointer; }
.review-dot[aria-current="true"] { width: 28px; background: var(--purple); }
.review-meta { margin-top: .75rem; color: var(--muted); text-align: center; }

.site-footer { padding: 3rem 0 1.5rem; color: rgba(255,255,255,.75); background: var(--purple-dark); }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 2rem; }
.footer-grid h2, .footer-grid h3 { color: #fff; }
.footer-logo-wrap { display: flex; min-height: 120px; align-items: center; margin-bottom: 1rem; }
.footer-logo { display: block; width: min(100%,280px); height: auto; max-height: 160px; object-fit: contain; object-position: left center; }
.footer-brand p { max-width: 420px; }
.footer-links { display: grid; gap: .55rem; }
.footer-bottom { margin-top: 2rem; padding-top: 1.2rem; border-top: 1px solid rgba(255,255,255,.13); font-size: .9rem; }
.cookie-settings-link { padding: 0; border: 0; color: inherit; background: transparent; text-decoration: underline; cursor: pointer; }
.cookie-consent { position: fixed; z-index: 1000; right: 1rem; bottom: 1rem; left: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1.25rem; width: min(calc(100% - 2rem),960px); margin-inline: auto; padding: 1.1rem 1.25rem; border: 1px solid color-mix(in srgb,var(--purple) 30%,#fff); border-radius: 20px; color: var(--text); background: rgba(255,255,255,.97); box-shadow: 0 20px 65px rgba(35,5,68,.25); backdrop-filter: blur(18px); }
.cookie-consent[hidden] { display: none; }
.cookie-consent-copy { max-width: 620px; }
.cookie-consent-copy strong { font-size: 1.1rem; }
.cookie-consent-copy p { margin: .35rem 0 0; color: var(--muted); font-size: .92rem; line-height: 1.55; }
.cookie-consent-copy a { color: var(--purple); text-decoration: underline; }
.cookie-consent-actions { display: grid; flex: 0 0 min(100%,390px); grid-template-columns: repeat(2,minmax(0,1fr)); gap: .65rem; }
.cookie-consent-actions .btn { width: 100%; padding-inline: 1rem; text-align: center; }
.cookie-reject { border: 2px solid var(--purple); color: var(--purple-dark); background: #fff; }
.archive-hero { padding: 7rem 0 3.5rem; color: #fff; background: linear-gradient(135deg,var(--purple-dark),var(--purple)); }
.archive-content { padding: 3rem 0 6rem; }
.entry-content { max-width: 840px; margin-inline: auto; }

@media (max-width: 900px) {
  .main-menu { display: none; position: absolute; top: 76px; left: 0; right: 0; padding: 1rem 1.25rem 1.4rem; flex-direction: column; align-items: stretch; background: var(--purple-dark); }
  .main-menu.open { display: flex; }
  .menu-toggle { display: grid; place-items: center; }
  .language-switcher { margin-left: auto; }
  .course-grid, .promo-grid, .archive-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .teacher-cards, .footer-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: clamp(2.9rem,8vw,4.8rem); letter-spacing: -.025em; }
}

@media (min-width: 901px) and (max-width: 1280px) {
  .brand span { display: none; }
}

@media (max-width: 640px) {
  body.admin-bar .site-header { top: 46px; }
  .container { width: min(calc(100% - 1.25rem),var(--container)); }
  .brand span { display: none; }
  .brand img, .brand .custom-logo { max-width: 132px; height: 56px; }
  .hero { min-height: 760px; align-items: end; background-position: 62% top; background-size: auto 62%; background-repeat: no-repeat; background-color: var(--purple-dark); }
  .hero::before { background: linear-gradient(0deg,rgba(35,5,68,.99) 12%,rgba(35,5,68,.78) 68%,rgba(35,5,68,.2)); }
  .hero-content { padding: clamp(18rem,58vw,27rem) 0 4rem; }
  .hero-logo { width: 100%; max-height: 30vh; margin: 0 auto 1.15rem; object-position: center; }
  .course-grid, .promo-grid, .work-grid, .archive-grid { grid-template-columns: 1fr; }
  .teacher-stage { min-height: 520px; }
  .teacher-logo-panel { top: 1.15rem; width: min(48%,250px); }
  .teacher-logo { height: 96px; }
  .teacher-person { height: 79%; }
  .teacher-person.winner { left: -16%; }
  .teacher-person.golf { right: -16%; }
  .reviews-head { align-items: stretch; flex-direction: column; }
  .google-score { width: max-content; }
  .review-viewport { border-radius: 20px; }
  .review-slide { min-height: 480px; padding: .5rem; }
  .review-slide img { max-height: 68vh; border-radius: 13px; }
  .review-controls { grid-template-columns: 44px 1fr 44px; }
  .review-arrow { width: 44px; height: 44px; }
  .cookie-consent { align-items: stretch; flex-direction: column; padding: 1rem; }
  .cookie-consent-actions { display: grid; grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
