/*
  text.css — tipografi + komponen (bento, hero jalur, ledger kaunter,
  jalur bergerak, peta interaktif, kad, borang)
*/

/* ---- tipografi asas ---- */

h1,
h2,
h3,
h4 {
  font-family: var(--ff-head);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.01em;
}

h1 {
  font-size: clamp(2.4rem, 5.6vw + 1rem, 4.6rem);
}

h2 {
  font-size: clamp(1.85rem, 3vw + 1rem, 2.9rem);
}

h3 {
  font-size: clamp(1.3rem, 1.4vw + 0.9rem, 1.7rem);
}

h4 {
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

p {
  color: var(--text-dim);
  max-width: 60ch;
}

p + p {
  margin-top: 0.9rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mint);
}

.eyebrow::before {
  content: "";
  width: 1.5rem;
  height: 2px;
  background: var(--mint);
}

.lede {
  font-size: 1.1rem;
  max-width: 42rem;
}

a.inline-link {
  color: var(--mint);
  border-bottom: 1px solid var(--mint-dim);
  transition: border-color var(--dur-1) var(--ease);
}

a.inline-link:hover {
  border-color: var(--mint);
}

/* ---- butang ---- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.6rem;
  border-radius: 999px;
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.02em;
  border: 1px solid transparent;
  cursor: pointer;
  min-height: 48px;
  transition: transform var(--dur-1) var(--ease), background var(--dur-1) var(--ease), border-color var(--dur-1) var(--ease);
}

.btn:active {
  transform: scale(0.97);
}

.btn--mint {
  background: var(--mint);
  color: var(--mint-ink);
}

.btn--mint:hover {
  background: #5cf0c1;
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: var(--mint);
  color: var(--mint);
}

.btn--sm {
  padding: 0.6rem 1.1rem;
  font-size: 0.9rem;
  min-height: 40px;
}

/* ---- header ---- */

.brand-mark__glyph {
  background: var(--surface-2);
}

.primary-nav a {
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text-dim);
  padding-block: 0.4rem;
  position: relative;
}

.primary-nav a:hover,
.primary-nav a[aria-current="page"] {
  color: var(--text);
}

.primary-nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.35rem;
  height: 2px;
  background: var(--mint);
}

.menu-open {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.6rem;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 0.3rem;
  cursor: pointer;
}

.menu-open__bar {
  width: 1.3rem;
  height: 2px;
  background: var(--text);
  transition: transform var(--dur-1) var(--ease), opacity var(--dur-1) var(--ease);
}

.menu-open[aria-expanded="true"] .menu-open__bar:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}

.menu-open[aria-expanded="true"] .menu-open__bar:nth-child(2) {
  opacity: 0;
}

.menu-open[aria-expanded="true"] .menu-open__bar:nth-child(3) {
  transform: translateY(-5px) rotate(-45deg);
}

/* ---- menu mudah alih ---- */

.mobile-nav__list a {
  display: block;
  font-family: var(--ff-head);
  font-size: 1.9rem;
  font-weight: 700;
  padding-block: 0.6rem;
  border-bottom: 1px solid var(--border);
}

.mobile-nav__foot {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  color: var(--text-dim);
}

/* ---- hero: mekanik strip-intro ---- */

.stage {
  padding-block: 3rem 0;
  position: relative;
  overflow: hidden;
}

.stage__grid {
  display: grid;
  gap: 2rem;
}

.stage__kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.4rem;
}

.stage__badge {
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
  font-size: 0.82rem;
  color: var(--text-dim);
}

.stage__actions {
  margin-top: 1.8rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.stage__strip {
  margin-top: 2.5rem;
  display: flex;
  gap: 0.9rem;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--mint) transparent;
  padding-bottom: 1.1rem;
  scroll-snap-type: x proximity;
}

.stage__frame {
  flex: 0 0 auto;
  width: 15.5rem;
  height: 10.5rem;
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  scroll-snap-align: start;
  border: 1px solid var(--border);
}

.stage__frame:nth-child(even) {
  transform: translateY(0.9rem);
}

.stage__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.stage__frame figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.55rem 0.8rem;
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 0.85rem;
  background: linear-gradient(0deg, rgba(16, 17, 19, 0.88), transparent);
}

/* ---- jalur svg-path (penghubung seksyen) ---- */

.path-seam {
  display: block;
  width: 100%;
  height: 3.5rem;
}

.path-seam path {
  fill: none;
  stroke: var(--mint-dim);
  stroke-width: 2;
  stroke-linecap: round;
  transition: stroke-dashoffset 1.4s var(--ease), stroke var(--dur-2) var(--ease);
}

.path-seam[data-drawn="true"] path {
  stroke: var(--mint);
}

/* ---- ledger kaunter ---- */

.ledger {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  overflow: hidden;
}

.ledger__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.5rem;
  border-bottom: 1px dashed var(--border);
}

.ledger__row:last-child {
  border-bottom: none;
}

.ledger__label {
  font-family: var(--ff-head);
  font-size: 1rem;
  color: var(--text-dim);
  letter-spacing: 0.01em;
}

.ledger__value {
  font-family: var(--ff-head);
  font-weight: 700;
  font-size: 1.9rem;
  color: var(--mint);
  font-variant-numeric: tabular-nums;
}

.ledger__value small {
  font-size: 1rem;
  color: var(--silver);
  font-weight: 600;
  margin-left: 0.2rem;
}

/* ---- jalur bergerak (marquee-band) ---- */

.marquee {
  border-block: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  padding-block: 0.85rem;
}

.marquee__track {
  display: flex;
  gap: 3rem;
  width: max-content;
  animation: marquee-scroll 32s linear infinite;
}

.marquee__track span {
  font-family: var(--ff-head);
  font-weight: 600;
  letter-spacing: 0.04em;
  font-size: 0.95rem;
  color: var(--text-dim);
  white-space: nowrap;
}

.marquee__track span em {
  color: var(--mint);
  font-style: normal;
}

@keyframes marquee-scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .marquee__track {
    animation: none;
  }
}

/* ---- kad bento ---- */

.tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.6rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  height: 100%;
  position: relative;
}

.tile--media {
  padding: 0;
  overflow: hidden;
  justify-content: flex-end;
}

.tile--media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.tile--media .tile__body {
  position: relative;
  z-index: 1;
  padding: 1.4rem;
  background: linear-gradient(0deg, rgba(16, 18, 20, 0.92) 10%, transparent 82%);
}

.tile--media .tile__body h3,
.tile--media .tile__body p {
  color: var(--text);
}

.tile--mint {
  background: var(--mint);
  color: var(--mint-ink);
}

.tile--mint h3,
.tile--mint p,
.tile--mint .price-card__list {
  color: var(--mint-ink);
}

.tile--mint .price-card__list li::before {
  background: var(--mint-ink);
}

.tile__icon {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 0.7rem;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--mint);
}

.tile__foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding-top: 0.6rem;
}

/* ---- peta interaktif ---- */

.floorplan {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
}

.floorplan img {
  width: 100%;
  height: auto;
}

.floorplan__point {
  position: absolute;
  width: 2.1rem;
  height: 2.1rem;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: rgba(23, 25, 28, 0.82);
  border: 2px solid var(--mint);
  color: var(--mint);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--ff-head);
  font-weight: 700;
  cursor: pointer;
  min-width: 44px;
  min-height: 44px;
}

.floorplan__point::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid var(--mint-dim);
  opacity: 0.6;
}

.floorplan__point[aria-pressed="true"] {
  background: var(--mint);
  color: var(--mint-ink);
}

.floorplan__legend {
  margin-top: 1.4rem;
  display: grid;
  gap: 0.75rem;
}

@media (min-width: 40rem) {
  .floorplan__legend {
    grid-template-columns: repeat(3, 1fr);
  }
}

.floorplan__note {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem;
  background: var(--surface);
  display: none;
}

.floorplan__note[data-active="true"] {
  display: block;
}

.floorplan__note h4 {
  color: var(--mint);
  margin-bottom: 0.4rem;
}

/* ---- kad harga ---- */

.price-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.price-card--accent {
  border-color: var(--mint);
  background: linear-gradient(160deg, var(--surface-2), var(--surface));
}

.price-card__amount {
  font-family: var(--ff-head);
  font-weight: 700;
  font-size: 2.6rem;
  color: var(--mint);
}

.price-card__amount span {
  font-size: 1rem;
  color: var(--text-dim);
  font-weight: 600;
  margin-left: 0.3rem;
}

.price-card__list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  color: var(--text-dim);
}

.price-card__list li {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
}

.price-card__list li::before {
  content: "";
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--mint);
  margin-top: 0.55rem;
  flex-shrink: 0;
}

/* ---- jadual perbandingan ---- */

.table-wrap {
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--mint) transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 34rem;
}

caption {
  text-align: left;
  padding: 1rem 1.25rem 0.4rem;
  color: var(--text-dim);
  font-size: 0.9rem;
}

th,
td {
  text-align: left;
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}

th {
  font-family: var(--ff-head);
  color: var(--silver);
  font-weight: 700;
  background: var(--surface-2);
}

tbody tr:last-child td {
  border-bottom: none;
}

/* ---- borang ---- */

.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.15rem;
}

.field label {
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--silver);
}

.field input[type="text"],
.field input[type="tel"] {
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  min-height: 48px;
}

.field input:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 2px;
}

.field--consent {
  flex-direction: row;
  align-items: flex-start;
  gap: 0.7rem;
}

.field--consent input {
  margin-top: 0.25rem;
  width: 1.2rem;
  height: 1.2rem;
  accent-color: var(--mint);
}

.field--consent label {
  color: var(--text-dim);
  font-weight: 400;
  font-family: var(--ff-body);
  font-size: 0.92rem;
}

.field--trap {
  position: absolute;
  left: -999px;
  top: -999px;
  opacity: 0;
  pointer-events: none;
}

.form-msg {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  display: none;
}

.form-msg[data-state="ok"] {
  display: block;
  background: rgba(70, 224, 177, 0.14);
  border: 1px solid var(--mint-dim);
  color: var(--mint);
}

.form-msg[data-state="error"] {
  display: block;
  background: rgba(224, 104, 95, 0.14);
  border: 1px solid var(--danger);
  color: var(--danger);
}

/* ---- blok legal ---- */

.legal-block {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.8rem;
  background: var(--surface);
  display: grid;
  gap: 0.5rem;
  color: var(--text-dim);
  font-size: 0.92rem;
}

.legal-block dt {
  font-family: var(--ff-head);
  color: var(--silver);
  font-weight: 600;
  margin-top: 0.6rem;
}

.legal-block dd {
  margin: 0;
}

/* ---- kad ahli pasukan ---- */

.crew-card {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.crew-card__portrait {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 2 / 3;
}

.crew-card__portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---- reben cookie ---- */

.gdpr-tray {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: var(--z-consent);
  max-width: 34rem;
  margin-inline: auto;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.4rem;
  box-shadow: var(--shadow-1);
  display: none;
  gap: 0.9rem;
  flex-direction: column;
}

.gdpr-tray[data-visible="true"] {
  display: flex;
}

.gdpr-tray p {
  color: var(--text-dim);
  font-size: 0.88rem;
}

.gdpr-tray__actions {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
}

/* ---- footer ---- */

.site-footer h4 {
  color: var(--silver);
  margin-bottom: 0.9rem;
}

.site-footer a,
.site-footer address {
  color: var(--text-dim);
  font-style: normal;
  font-size: 0.92rem;
  display: block;
  margin-bottom: 0.5rem;
}

.site-footer a:hover {
  color: var(--mint);
}

.site-footer__bottom {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  justify-content: space-between;
  color: var(--text-dim);
  font-size: 0.82rem;
}

/* ---- reveal (kandungan sentiasa nampak, JS tambah kelas ini) ---- */

.is-hidden-until-seen {
  opacity: 1;
  transform: none;
}

[data-motion="ready"] .is-hidden-until-seen {
  opacity: 0;
  transform: translateY(1.1rem);
  transition: opacity var(--dur-2) var(--ease), transform var(--dur-2) var(--ease);
}

[data-motion="ready"] .is-hidden-until-seen[data-seen="true"] {
  opacity: 1;
  transform: none;
}

@media (min-width: 1600px) {
  /* skrin desktop besar: nilai lede tidak berubah, dikekalkan sengaja */
  .lede {
    max-width: 42rem;
  }
}
