/* components.css — class reusable yang dipakai semua section. Di-load setelah tokens.css.
   2026-10-20: gaya dasar butterfly.html (editorial navy-emas). Serif butterfly (Georgia) dipetakan ke --font-heading
   (Playfair Display, B104: satu-satunya font heading ekosistem). */

/* ── Dasar halaman ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 92px; }
body {
  margin: 0; min-width: 320px; overflow-x: hidden;
  background: var(--bg); color: var(--ink);
}
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse at 55% 5%, #18366470, transparent 52%), radial-gradient(ellipse at 92% 57%, #70533320, transparent 40%);
}
:root[data-theme="light"] body::before { background: radial-gradient(ellipse at 60% 10%, #bcd1e6, transparent 50%); }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: var(--focus-ring); outline-offset: 3px; }
[hidden] { display: none !important; }
:root.pe-no-scroll { overflow: hidden; } /* menu/drawer terbuka */

.skip { position: fixed; inset-block-start: -100px; inset-inline-start: 10px; z-index: 1000; padding: 10px; background: var(--goldBright); color: #121824; }
.skip:focus { inset-block-start: 10px; }
.container { width: min(var(--container-max), calc(100% - 48px)); margin-inline: auto; }
.overline { font-size: 10px; font-weight: 800; letter-spacing: .24em; text-transform: uppercase; color: var(--gold); line-height: 1.5; }
.muted { color: var(--muted); }
.section-heading {
  font-family: var(--font-heading); font-weight: 400; font-size: clamp(42px, 5vw, 75px);
  line-height: 1.05; letter-spacing: -.048em; margin: 14px 0 25px; overflow-wrap: anywhere;
}
.story-intro { color: var(--soft); font-size: 15px; line-height: 1.8; max-width: 470px; }
.section-top { display: flex; justify-content: space-between; align-items: end; gap: 25px; }
.section-top p { max-width: 380px; color: var(--muted); font-size: 14px; line-height: 1.65; }
.section-note { color: var(--muted); font-size: 12px; line-height: 1.8; max-width: 1040px; margin: 22px 0 0; }

/* ── Blok section bersama butterfly: Utility / Protocol Docs / Team ── */
.docs-section { padding: 90px 0; border-top: 1px solid var(--line); }
.docs-panel { padding: 45px; display: grid; grid-template-columns: .75fr 1.25fr; gap: 45px; }
.docs-panel p { font-size: 14px; line-height: 1.76; color: var(--soft); margin: 0 0 18px; }
.docs-panel p:last-child { margin-bottom: 0; }
/* Judul section + tempat hinggap kupu-kupu di sampingnya (Journey, Team) */
.bf-heading { display: grid; grid-template-columns: 1fr; gap: 10px; }
.bf-heading .story-intro { max-width: 62ch; }
.bf-heading-perch { height: 270px; }
@media (min-width: 701px) { .bf-heading { grid-template-columns: 1.25fr .75fr; gap: 36px; align-items: center; } .bf-heading-perch { height: 340px; } }
@media (max-width: 900px) { .docs-panel { grid-template-columns: 1fr; gap: 20px; } }
@media (max-width: 700px) { .docs-section { padding: 64px 0; } .docs-panel { padding: 28px; } .bf-heading { gap: 0; } }

/* ── Kartu (nama lama .glass-card / .clay-card tetap = kartu butterfly) ── */
.card, .glass-card, .clay-card {
  background: linear-gradient(148deg, #ffffff0b, transparent 38%), var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--corner);
  box-shadow: 0 20px 43px var(--shadow), inset 0 1px #fff1;
}

/* ── Tombol (nama lama .btn-primary / .btn-outline = .button / .button.secondary butterfly) ── */
.button, .btn-primary, .btn-outline {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 44px; padding: 14px 20px; border-radius: 999px;
  border: 1px solid var(--gold); background: var(--gold-gradient); color: var(--gold-ink);
  font-family: var(--font-body); font-size: 10px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase;
  white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.button:hover, .btn-primary:hover, .btn-outline:hover { transform: translateY(-2px); box-shadow: 0 0 20px #d9a65c5e; }
.button.secondary, .btn-outline { background: transparent; color: var(--ink); border-color: var(--line); }
.button.secondary:hover, .btn-outline:hover { border-color: var(--gold); box-shadow: none; }
.button[disabled], .btn-primary[disabled], .btn-outline[disabled] { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }

.icon {
  inline-size: 43px; block-size: 43px; min-inline-size: 44px; min-block-size: 44px; flex: none;
  display: inline-grid; place-items: center; padding: 0;
  background: var(--glass); border: 1px solid var(--line); border-radius: 50%; color: var(--ink);
}
.icon:hover { border-color: var(--gold); color: var(--goldBright); }

/* ── Micro card (kartu kecil statistik/ikon) ── */
.micro-card { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-radius: var(--radius-md); background: var(--panel); border: 1px solid var(--line); }
.magnetic-btn { will-change: transform; }

/* ── Social floating buttons (hero.html: #btn-social-twitter/discord/youtube) ── */
.social-float-wrapper {
  position: fixed;
  bottom: var(--social-float-bottom);
  inset-inline-end: var(--social-float-right); /* B133: logis — floating ikut bercermin saat RTL */
  display: flex; flex-direction: column; gap: var(--social-btn-gap);
  z-index: var(--z-float);
}
.social-float-btn {
  width: var(--social-btn-size); height: var(--social-btn-size); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--glass); border: 1px solid var(--line); color: var(--ink);
  text-decoration: none; transition: color var(--dur-fast), border-color var(--dur-fast);
}
.social-float-btn[hidden] { display: none; } /* display:flex di atas mengalahkan atribut hidden bawaan */
.social-float-btn:hover, .social-float-btn:focus-visible { color: var(--gold); border-color: var(--gold); }
.social-float-btn img, .social-float-btn svg { width: 18px; height: 18px; }

/* ── Social requirements (allowlist) ── */
.social-requirements { background: var(--panel); border: 1px solid var(--color-border-gold); border-radius: var(--radius-md); padding: 20px; margin-bottom: 16px; }
.social-requirements-item { display: flex; gap: 12px; margin: 8px 0; }
.social-check-link { color: var(--gold); text-decoration: underline; }
.social-check-link:hover, .social-check-link:focus-visible { color: var(--goldBright); }
.btn-submit-wl[disabled] { opacity: 0.4; }
.btn-submit-wl:not([disabled]) { background: var(--gold); color: var(--bg); }

/* ── Honeypot: tersembunyi dari manusia, terlihat oleh bot scraper ── */
.honeypot-field { position: absolute; inset-inline-start: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ── Toast (HolderBroadcastToast.js memakai class ini agar konsisten) — gaya .toast butterfly ── */
.pe-toast {
  position: fixed; z-index: var(--z-toast);
  inset-inline-end: 20px; inset-block-end: 144px;
  max-width: min(380px, calc(100vw - 40px)); padding: 14px 17px; border-radius: 12px;
  background: var(--panel2); border: 1px solid var(--gold); color: var(--ink);
  box-shadow: 0 15px 28px var(--shadow); font-size: 12px;
}
.pe-toast--success { border-color: var(--color-success); }
.pe-toast--error { border-color: var(--color-error); }

/* ── Badge / pill ── */
.pill { display: inline-flex; align-items: center; padding: 6px 10px; border-radius: var(--radius-pill); border: 1px solid var(--color-border-gold); color: var(--gold); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }

/* ── Aksesibilitas ── */
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ── Section lama yang dipertahankan (NFT Supply, Comparison, FAQ, Connect Wallet, Mint): pola BEM __inner/__eyebrow/__title
      dipetakan ke tata letak butterfly (container, overline, judul serif besar, garis pemisah atas) ── */
/* 2026-10-23: section bergaya Varian 2 (kelas v4-*) punya jarak sendiri — dikecualikan. Di Varian 1 & 2 (html[data-variant], 2026-10-26)
   __inner/__eyebrow/__title section lama diberi kelas container/overline/section-heading oleh engines/variant-2.js → gaya Varian 2. */
#app > section:not(#hero):not([class*="v4-"]) { padding-block: 90px; padding-inline: 0; border-top: 1px solid var(--line); background: none; }
html:not([data-variant]) #app > section:not(#hero) > [class$="__inner"] { width: min(var(--container-max), calc(100% - 48px)); max-width: none; margin-inline: auto; padding-inline: 0; }
html:not([data-variant]) #app > section:not(#hero) [class$="__eyebrow"] { font-size: 10px; font-weight: 800; letter-spacing: .24em; text-transform: uppercase; color: var(--gold); line-height: 1.5; margin: 0; }
html:not([data-variant]) #app > section:not(#hero) h2[class$="__title"] {
  font-family: var(--font-heading); font-weight: 400; font-size: clamp(42px, 5vw, 75px);
  line-height: 1.05; letter-spacing: -.048em; margin: 14px 0 25px; color: var(--ink); overflow-wrap: anywhere;
}
#app > section:not(#hero) [class$="__sub"] { color: var(--soft); font-size: 15px; line-height: 1.8; max-width: 620px; }

/* ── Footer bersama (slot-11 / slot-11b) — tata letak footer butterfly: sosial | copyright | nilai, lalu tautan legal ── */
#footer-legal {
  width: min(var(--container-max), calc(100% - 48px)); max-width: none; margin-inline: auto;
  padding: 30px 0 155px !important; color: var(--muted); font-size: 11px; text-align: center;
  border-top: 1px solid var(--line);
}
#footer-legal #footer-row { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 24px; margin-bottom: 18px; }
#footer-legal #footer-row [data-col="left"] { justify-self: start; }
#footer-legal #footer-row [data-col="right"] { justify-self: end; }
#footer-social { display: flex; gap: 12px; }
#footer-social a {
  inline-size: 44px; block-size: 44px; border-radius: 50%; display: grid !important; place-items: center;
  border: 1px solid var(--line); color: var(--ink) !important; transition: color .2s, border-color .2s;
}
#footer-social a:hover, #footer-social a:focus-visible { color: var(--gold) !important; border-color: var(--gold); }
#footer-legal .pe-footer-copyright { direction: ltr; unicode-bidi: isolate; line-height: 1.7; }
#footer-legal nav a { color: var(--soft); text-decoration: none; padding-inline: 10px; }
#footer-legal nav a:hover { color: var(--goldBright); }
#footer-legal .footer-extra-safe { line-height: 1.7; color: var(--muted); }
@media (max-width: 700px) {
  #footer-legal { padding-bottom: 170px !important; }
  #footer-legal #footer-row { grid-template-columns: 1fr; justify-items: center; }
  #footer-legal #footer-row [data-col] { justify-self: center; }
}

/* ── Animasi muncul saat scroll (butterfly .bf-reveal) ── */
.bf-reveal { opacity: 1; transform: none; }
.bf-motion .bf-reveal { transition: opacity .85s cubic-bezier(.2,.8,.15,1), transform 1s cubic-bezier(.2,.8,.15,1); transition-delay: var(--bf-delay, 0ms); }
.bf-motion .bf-reveal:not(.bf-shown) { opacity: 0; transform: translate3d(0, 30px, 0); }
.bf-motion .bf-reveal.bf-shown { opacity: 1; transform: none; }

/* ── Aksara non-Latin: tracking lebar memisahkan huruf; serif Latin tak punya glif → tinggi baris dilonggarkan ── */
:root:is([lang^="th"], [lang^="zh"], [lang^="ja"], [lang^="ko"], [lang^="hi"], [lang^="ar"], [lang^="ur"]) body * { letter-spacing: 0 !important; }
:root:is([lang^="th"], [lang^="zh"], [lang^="ja"], [lang^="ko"], [lang^="hi"], [lang^="ar"], [lang^="ur"]) :is(.section-heading, h1, h2) { line-height: 1.25; }

@media (max-width: 700px) {
  .container, html:not([data-variant]) #app > section:not(#hero) > [class$="__inner"] { width: calc(100% - 28px); }
  #app > section:not(#hero):not([class*="v4-"]) { padding-block: 64px; }
  .section-top { display: block; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
