/* ===== RAP-FIGHTERS Taekwondo Club ===== */
:root {
  --navy:        #16244A;   /* jangkar, dari logo */
  --navy-700:    #1E3160;
  --navy-050:    #EEF1F6;
  --ink:         #1F2632;   /* teks utama */
  --slate:       #5A6577;   /* teks sekunder */
  --line:        #E3E7EE;
  --bg:          #FFFFFF;
  --bg-alt:      #F7F8FA;   /* section selang-seling */
  --red:         #D0202F;   /* aksen aksi, dipakai tipis */
  --red-700:     #B01926;
  --blue:        #2F4FD8;
  --radius:      14px;
  --radius-sm:   10px;
  --shadow:      0 1px 2px rgba(22,36,74,.06), 0 8px 24px rgba(22,36,74,.08);
  --shadow-lg:   0 12px 40px rgba(22,36,74,.14);
  --maxw:        1140px;
  --ease:        cubic-bezier(.22,.61,.36,1);
}

*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 3px; }
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; }

h1, h2, h3 {
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  color: var(--navy);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2rem, 4.6vw, 3.1rem); font-weight: 800; }
h2 { font-size: clamp(1.55rem, 3.2vw, 2.25rem); font-weight: 700; }
h3 { font-size: 1.18rem; font-weight: 700; }
p { margin: 0 0 1rem; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 clamp(1rem, 4vw, 2rem); }
.container.narrow { max-width: 800px; }
.section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.section-alt { background: var(--bg-alt); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .78rem;
  font-weight: 700;
  color: var(--red);
  margin: 0 0 .7rem;
}
.section-head { max-width: 720px; margin: 0 0 2.75rem; }
.section-sub { color: var(--slate); font-size: 1.02rem; }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--navy); color: #fff; padding: .6rem 1rem; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: .5rem;
  padding: .8rem 1.4rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .96rem;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .18s var(--ease), background-color .18s, box-shadow .18s, border-color .18s;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 6px 18px rgba(208,32,47,.25); }
.btn-primary:hover { background: var(--red-700); }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy); background: #fff; }
.btn-lg { padding: 1rem 1.8rem; font-size: 1.05rem; }

/* ===== Header =====
   Sengaja TANPA backdrop-filter: properti itu membuat "containing block"
   untuk elemen position:fixed, sehingga drawer menu mobile jadi terjebak
   di dalam kotak header. Solid background lebih aman & tetap rapi. */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: .65rem; text-decoration: none; }
.brand img { width: 44px; height: 44px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-family: "Plus Jakarta Sans", sans-serif; color: var(--navy); font-size: 1.05rem; letter-spacing: .02em; }
.brand-text small { color: var(--slate); font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; }

.main-nav { display: flex; align-items: center; gap: 1.6rem; }
.main-nav a { text-decoration: none; font-weight: 500; font-size: .95rem; color: var(--ink); transition: color .15s; }
.main-nav a:hover { color: var(--red); }
.main-nav .nav-cta { color: #fff; }
.main-nav .nav-cta:hover { color: #fff; }
.nav-close { display: none; }

.nav-open { display: none; background: none; border: 0; cursor: pointer; width: 42px; height: 42px; padding: 9px; }
.nav-open span { display: block; height: 2px; background: var(--navy); border-radius: 2px; margin: 5px 0; transition: .25s; }

/* ===== Hero ===== */
.hero { background: linear-gradient(180deg, #fff 0%, var(--bg-alt) 100%); overflow: hidden; }
.hero-inner {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem; align-items: center;
  padding: clamp(3rem, 7vw, 5.5rem) 0;
}
.hero h1 { margin-bottom: .6rem; }
.lead { font-size: 1.12rem; color: var(--slate); max-width: 44ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .9rem; margin: 1.6rem 0 1.4rem; }
.hero-badges { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .6rem 1.3rem; }
.hero-badges li { position: relative; padding-left: 1.4rem; font-size: .9rem; color: var(--navy); font-weight: 500; }
.hero-badges li::before {
  content: ""; position: absolute; left: 0; top: .35em;
  width: .9rem; height: .9rem; border-radius: 50%;
  background: var(--blue); opacity: .18;
}
.hero-badges li::after {
  content: "✓"; position: absolute; left: .17rem; top: -.05em; font-size: .72rem; color: var(--blue); font-weight: 700;
}
.hero-logo { text-align: center; }
.hero-logo img {
  width: min(100%, 420px); margin: 0 auto;
  filter: drop-shadow(0 20px 40px rgba(22,36,74,.18));
  animation: float 6s ease-in-out infinite;
}
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

/* ===== Stats ===== */
.stats { background: var(--navy); color: #fff; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; padding: 2.4rem 0; text-align: center; }
.stat strong { display: block; font-family: "Plus Jakarta Sans", sans-serif; font-size: 1.7rem; font-weight: 800; color: #fff; }
.stat span { font-size: .86rem; color: rgba(255,255,255,.7); }

/* ===== Grid helpers ===== */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.about-media img { border-radius: var(--radius); box-shadow: var(--shadow); }
.cards-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; }
.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; max-width: 900px; margin: 0 auto; }

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), border-color .22s;
}
.card.feature:hover, .card.klass:hover, .card.coach:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: #d5dbe6;
}
.card p { color: var(--slate); font-size: .95rem; margin-bottom: 0; }
.card.feature h3 { position: relative; padding-top: .9rem; }
.card.feature h3::before {
  content: ""; position: absolute; top: 0; left: 0; width: 34px; height: 4px; border-radius: 2px;
  background: var(--red);
}

.card.klass { display: flex; flex-direction: column; }
.card.klass p { flex: 1; margin-bottom: 1rem; }
.link-wa { color: var(--red); font-weight: 600; text-decoration: none; font-size: .92rem; }
.link-wa:hover { color: var(--red-700); }

/* ===== Coaches ===== */
.card.coach { text-align: center; padding: 1.5rem 1rem; }
.card.coach img {
  width: 116px; height: 116px; border-radius: 50%; object-fit: cover;
  object-position: center top;
  margin: 0 auto .9rem; border: 3px solid var(--navy-050);
  background: var(--navy-050);
}
.card.coach h3 { margin-bottom: .35rem; }
.coach-pre {
  text-transform: uppercase; letter-spacing: .12em;
  font-size: .72rem !important; font-weight: 700;
  color: var(--red) !important; margin: 0 0 .15rem !important;
}
.coach-role { color: var(--navy) !important; font-weight: 600; font-size: .9rem !important; margin-bottom: .15rem !important; }
.coach-cred { color: var(--slate) !important; font-size: .82rem !important; }

/* ===== Location ===== */
.location-wrap { display: grid; grid-template-columns: 1fr 1.15fr; gap: 1.6rem; align-items: stretch; }
.card.location { display: flex; flex-direction: column; }
.loc-addr { color: var(--navy) !important; font-weight: 600; margin-bottom: .6rem !important; }
.card.location p:not(.loc-addr) { flex: 1; }
.loc-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1rem; }
.map-card { padding: 0; overflow: hidden; min-height: 320px; }
.map-card iframe { width: 100%; height: 100%; min-height: 320px; border: 0; display: block; }

/* ===== Gallery ===== */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.gallery-item { border-radius: var(--radius-sm); overflow: hidden; display: block; box-shadow: var(--shadow); }
.gallery-item img { width: 100%; aspect-ratio: 4/3; object-fit: cover; transition: transform .35s var(--ease); }
.gallery-item:hover img { transform: scale(1.05); }

.lightbox {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(15,22,42,.94);
  display: none; align-items: center; justify-content: center; padding: 4vw;
  transform: translateZ(0); /* ponytail: paksa layer sendiri, hindari bug kompositing header backdrop-filter */
}
.lightbox:target { display: flex; }
/* Sembunyikan header & tombol WA saat lightbox terbuka */
body:has(.lightbox:target) .site-header,
body:has(.lightbox:target) .wa-float { visibility: hidden; }
.lightbox img { max-width: 92vw; max-height: 88vh; border-radius: 10px; }
.lb-close {
  position: absolute; top: max(3vw, 12px); right: max(4vw, 12px);
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 2.2rem; text-decoration: none; line-height: 1;
}

/* ===== FAQ ===== */
.faq-list { display: flex; flex-direction: column; gap: .75rem; }
.faq-list details {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 0 1.2rem;
  transition: border-color .2s, box-shadow .2s;
}
.faq-list details[open] { border-color: #d5dbe6; box-shadow: var(--shadow); }
.faq-list summary {
  list-style: none; cursor: pointer; font-weight: 600; color: var(--navy);
  padding: 1.1rem 2rem 1.1rem 0; position: relative;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  font-size: 1.4rem; color: var(--red); font-weight: 400; transition: transform .2s;
}
.faq-list details[open] summary::after { content: "–"; }
.faq-list details p { color: var(--slate); font-size: .96rem; padding-bottom: 1.1rem; margin: 0; }

/* ===== Coba Latihan Gratis (#mulai) ===== */
.section-mulai { background: var(--bg); }
.section-mulai .section-head { text-align: center; margin-inline: auto; }

.schedule-card {
  display: flex; gap: 1.1rem; align-items: center;
  max-width: 520px; margin: 0 auto;
  background: var(--navy); color: #fff;
  border-radius: var(--radius); padding: 1.35rem 1.5rem;
  box-shadow: var(--shadow-lg);
}
.sched-icon {
  flex-shrink: 0; width: 48px; height: 48px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.12); border-radius: 12px; color: #fff;
}
.sched-label {
  text-transform: uppercase; letter-spacing: .1em;
  font-size: .7rem; font-weight: 700; color: rgba(255,255,255,.6);
  margin: 0 0 .25rem;
}
.sched-time {
  font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700;
  font-size: 1.12rem; color: #fff; margin: 0 0 .15rem;
}
.sched-loc { font-size: .86rem; color: rgba(255,255,255,.72); margin: 0; }
.sched-note { text-align: center; color: var(--slate); font-size: .9rem; margin: .9rem 0 2.5rem; }

.stepper {
  list-style: none; padding: 0; margin: 0 0 2.25rem;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem;
}
.step {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.5rem 1.4rem; text-align: left;
}
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  background: var(--red); color: #fff; font-weight: 700;
  font-family: "Plus Jakarta Sans", sans-serif; font-size: 1rem;
  margin-bottom: .85rem;
}
.step h3 { margin-bottom: .3rem; font-size: 1.05rem; }
.step p { color: var(--slate); font-size: .92rem; margin: 0; }

.mulai-cta { text-align: center; }
.mulai-note { color: var(--slate); font-size: .85rem; margin: .8rem 0 0; }

/* ===== CTA ===== */
.section-cta { background: var(--navy); color: #fff; text-align: center; }
.section-cta h2 { color: #fff; }
.cta-inner { max-width: 640px; margin: 0 auto; }
.cta-inner > p { color: rgba(255,255,255,.78); font-size: 1.08rem; }
.cta-actions { margin: 1.8rem 0 2rem; }
.contact-meta { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; text-align: left; max-width: 460px; margin-inline: auto; }
.contact-meta li { font-size: .92rem; color: rgba(255,255,255,.8); border-top: 1px solid rgba(255,255,255,.14); padding-top: .6rem; }
.contact-meta strong { display: block; color: #fff; font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .1rem; }

/* ===== Footer ===== */
.site-footer { background: #101a35; color: rgba(255,255,255,.72); font-size: .92rem; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; padding: 3rem 0 2rem; }
.footer-brand { display: flex; gap: 1rem; align-items: flex-start; }
.footer-brand > img { flex-shrink: 0; }
.footer-brand strong { color: #fff; font-family: "Plus Jakarta Sans", sans-serif; display: block; font-size: 1rem; margin-bottom: .5rem; }
.footer-brand .fb-tag { margin: 0 0 .9rem; max-width: 42ch; }
.footer-brand .fb-addr {
  font-style: normal; line-height: 1.7; font-size: .88rem;
  color: rgba(255,255,255,.6);
}
.footer-brand .fb-addr a { color: rgba(255,255,255,.85); text-decoration: none; }
.footer-brand .fb-addr a:hover { color: #fff; }
.footer-nav, .footer-social { display: flex; flex-direction: column; gap: .55rem; }
.footer-nav a, .footer-social a { text-decoration: none; transition: color .15s; }
.footer-nav a:hover, .footer-social a:hover { color: #fff; }
.footer-bottom {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: .4rem;
  border-top: 1px solid rgba(255,255,255,.1); padding: 1.2rem 0; font-size: .82rem; color: rgba(255,255,255,.5);
}

/* ===== WhatsApp float ===== */
.wa-float {
  position: fixed; z-index: 90;
  right: calc(16px + env(safe-area-inset-right));
  bottom: calc(16px + env(safe-area-inset-bottom));
  width: 54px; height: 54px; border-radius: 50%;
  background: #25D366; color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(37,211,102,.4);
  transition: transform .2s var(--ease);
}
.wa-float:hover { transform: scale(1.08); }

/* ===== Reveal animation =====
   Default: terlihat. JS hanya menyembunyikan elemen di bawah lipatan
   lalu melepasnya saat masuk viewport. Tanpa JS -> semua tetap tampil. */
.reveal { transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.pending { opacity: 0; transform: translateY(24px); }

/* ===== Responsive =====
   Breakpoint tablet & bawah = 960px (iPad portrait dapat menu drawer) */
@media (max-width: 960px) {
  .cards-4 { grid-template-columns: repeat(2, 1fr); }
  .cards-3 { grid-template-columns: repeat(3, 1fr); max-width: 760px; }
  .hero-inner { grid-template-columns: 1fr; text-align: center; gap: 2rem; }
  .hero-copy { order: 2; }
  .hero-logo { order: 1; }
  .hero-logo img { width: min(62%, 280px); }
  .lead, .hero-badges { margin-inline: auto; justify-content: center; }
  .hero-actions { justify-content: center; }
  .grid-2, .location-wrap { grid-template-columns: 1fr; gap: 2rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 1.6rem; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }

  /* nav → drawer geser dari kanan, tinggi penuh layar */
  .nav-open { display: block; }
  .main-nav {
    position: fixed; top: 0; right: 0; bottom: 0; left: auto;
    width: min(84vw, 320px);
    height: 100vh; height: 100dvh;
    background: #fff; flex-direction: column; align-items: stretch;
    padding: 4.75rem 1.5rem calc(2rem + env(safe-area-inset-bottom)) 1.5rem;
    gap: 0;
    transform: translateX(100%); transition: transform .3s var(--ease);
    box-shadow: -20px 0 60px rgba(22,36,74,.18);
    overflow-y: auto; -webkit-overflow-scrolling: touch;
  }
  .main-nav.open { transform: translateX(0); }
  .main-nav a {
    display: block; width: 100%;
    padding: .95rem .25rem; font-size: 1.05rem;
    border-bottom: 1px solid var(--line);
  }
  .nav-close {
    display: flex; align-items: center; justify-content: center;
    position: absolute; top: .6rem; right: .6rem;
    width: 44px; height: 44px; background: none; border: 0;
    font-size: 2.1rem; color: var(--navy); cursor: pointer; line-height: 1;
  }
  .main-nav a.nav-cta {
    width: 100%; margin-top: 1.1rem; border-bottom: 0;
    padding: .95rem 1rem; text-align: center;
  }
  body.nav-lock { overflow: hidden; }
}

/* HP & tablet kecil: lebih banyak ruang bernapas */
@media (max-width: 760px) {
  .cards-3 { grid-template-columns: 1fr; max-width: 420px; }
  .section { padding: 3.25rem 0; }
  h1 { line-height: 1.22; }
  h2 { line-height: 1.28; }
  .lead { font-size: 1.06rem; line-height: 1.75; }
  .section-head { margin-bottom: 2.25rem; }
  .section-sub { line-height: 1.7; }
  p { margin-bottom: 1.1rem; }
  .card { padding: 1.4rem; }
  .hero-badges { gap: .55rem 1.1rem; row-gap: .7rem; }
  .stepper { grid-template-columns: 1fr; gap: .8rem; }
  .step { padding: 1.25rem 1.3rem; }
  .schedule-card { padding: 1.2rem 1.25rem; gap: .9rem; }
  .sched-time { font-size: 1.05rem; }
}

@media (max-width: 600px) {
  .cards-4 { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: .7rem; }
  .cta-actions .btn { width: 100%; }
  h1 { font-size: 1.95rem; }
  h2 { font-size: 1.5rem; }
  .eyebrow { font-size: .74rem; letter-spacing: .1em; }

  /* Footer mobile: rata tengah & ringkas — link disusun mendatar (chip),
     bukan menurun panjang ke bawah */
  .footer-inner {
    grid-template-columns: 1fr; gap: 1.6rem;
    padding: 2.5rem 0 1.5rem; text-align: center;
  }
  .footer-brand { flex-direction: column; align-items: center; gap: .7rem; }
  .footer-brand > img { width: 52px; height: 52px; }
  .footer-brand > div { max-width: 34ch; }
  .footer-brand .fb-tag { margin-bottom: .6rem; max-width: none; }
  .footer-brand .fb-addr { font-size: .84rem; line-height: 1.7; }

  .footer-nav, .footer-social {
    flex-direction: row; flex-wrap: wrap; justify-content: center;
    gap: .5rem;
  }
  .footer-nav a, .footer-social a {
    line-height: 1; text-align: center;
    border: 1px solid rgba(255,255,255,.16); border-radius: 999px;
  }
  .footer-nav a:hover, .footer-social a:hover {
    background: rgba(255,255,255,.08); color: #fff;
  }
  /* nav: paksa 4 chip di baris atas, 3 di baris bawah (rata tengah) */
  .footer-nav a {
    flex: 0 0 calc((100% - 1.5rem) / 4);
    padding: .42rem .3rem; font-size: .8rem;
  }
  /* sosial: bungkus alami */
  .footer-social a {
    padding: .4rem .85rem; font-size: .84rem;
    background: rgba(255,255,255,.06);
  }

  .footer-bottom {
    flex-direction: column; align-items: center; gap: .3rem;
    text-align: center; padding: 1.1rem 0;
  }
}

@media (max-width: 380px) {
  .stats-grid { gap: 1rem; }
  .stat strong { font-size: 1.5rem; }
  .hero-actions, .loc-actions { flex-direction: column; align-items: stretch; }
  .container { padding-left: 1.1rem; padding-right: 1.1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal.pending { opacity: 1; transform: none; transition: none; }
  .hero-logo img { animation: none; }
  .btn:hover, .card:hover, .wa-float:hover, .gallery-item:hover img { transform: none; }
}
