/* =========================================================
   HARYSTA INTERNATIONAL — GROUP LANDING PAGE
   The centre emblem is the focus. Two straight gold branches
   unfold out of it, and a compact card appears at each end.
   CUSTOMISE: colours and fonts in :root; animation timing in
   the "Motion timeline" variables.
   ========================================================= */
:root {
  --navy: #13285a;
  --navy-deep: #0a1734;
  --ink: #0d1c3f;
  --gold: #a8803a;
  --gold-light: #d4b07a;
  --text: #c3cce0;
  --muted: #8f9bb6;
  --font-display: "Marcellus", "Times New Roman", Georgia, serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;

  /* Motion timeline */
  --t-core: 0.2s;     /* emblem appears */
  --t-lines: 1.05s;   /* branches start unfolding */
  --d-lines: 0.85s;   /* how long the branches take */
  --t-cards: 1.8s;    /* cards appear at the ends */

  --emblem: 190px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { min-height: 100%; }
body { font-family: var(--font-body); background: var(--navy-deep); color: var(--text); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.lp {
  position: relative; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center;
  padding: max(48px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) max(28px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
  overflow: hidden; isolation: isolate;
}

/* ---------- Background ---------- */
.lp__bg { position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(55% 45% at 50% 55%, rgba(212,176,122,0.17) 0%, rgba(212,176,122,0) 70%),
    radial-gradient(80% 70% at 50% 0%, #1b3570 0%, rgba(27,53,112,0) 60%),
    linear-gradient(180deg, #0c1b3f 0%, var(--navy-deep) 100%);
}
.lp__bg::before { content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,0.09) 1px, transparent 1.2px); background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(70% 60% at 50% 50%, #000 30%, transparent 85%); mask-image: radial-gradient(70% 60% at 50% 50%, #000 30%, transparent 85%);
}

/* ---------- Intro ---------- */
.lp__intro { text-align: center; max-width: 640px; animation: lp-fade 0.8s ease backwards; }
.lp__kicker { display: inline-flex; align-items: center; gap: 12px; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.26em; text-transform: uppercase; color: var(--gold-light); }
.lp__kicker::before, .lp__kicker::after { content: ""; width: 26px; height: 1px; background: currentColor; opacity: 0.7; }
.lp__title { font-family: var(--font-display); font-weight: 400; color: #fff; font-size: clamp(2rem, 4.6vw, 3.2rem); line-height: 1.1; margin-top: 14px; text-wrap: balance; }

/* ---------- Stage (desktop: card — line — emblem — line — card) ---------- */
.lp__stage {
  position: relative; width: 100%; max-width: 1040px; flex: 1; margin-top: 20px; padding-bottom: 96px;
  display: grid; align-items: center; align-content: center;
  grid-template-columns: auto minmax(56px, 1fr) auto minmax(56px, 1fr) auto;
}
.lp__branch--left { grid-column: 1; grid-row: 1; }
.lp__core { grid-column: 3; grid-row: 1; }
.lp__branch--right { grid-column: 5; grid-row: 1; }

/* Branch lines (drawn by js/landing.js) */
.lp__lines { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.lp__line {
  fill: none; stroke: rgba(212,176,122,0.55); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 1; stroke-dashoffset: 1;
  animation: lp-draw var(--d-lines) var(--t-lines) cubic-bezier(.6,0,.3,1) forwards;
  transition: stroke 0.3s ease, stroke-width 0.3s ease;
}
.lp__flow { fill: none; stroke: var(--gold-light); stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 3 14; opacity: 0; transition: opacity 0.3s ease; animation: lp-flow 1s linear infinite; }
.lp__node { fill: var(--gold-light); transform-box: fill-box; transform-origin: center; animation: lp-node 0.45s calc(var(--t-cards) - 0.1s) cubic-bezier(.2,.8,.2,1.4) backwards; }

/* ---------- Centre emblem (the focus) ---------- */
.lp__core { position: relative; z-index: 2; width: var(--emblem); height: var(--emblem); animation: lp-pop 0.9s var(--t-core) cubic-bezier(.2,.8,.2,1) backwards; }
.lp__emblem {
  position: relative; width: 100%; height: 100%; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #f3eee3 70%);
  box-shadow: 0 0 0 12px rgba(212,176,122,0.12), 0 0 80px rgba(212,176,122,0.4), 0 24px 50px rgba(0,0,0,0.35);
  transition: box-shadow 0.35s ease;
}
.lp__emblem img { width: 64%; height: auto; }
.lp__ring { position: absolute; left: 50%; top: 50%; border-radius: 50%; border: 1px dashed rgba(212,176,122,0.45); transform: translate(-50%, -50%); pointer-events: none; }
.lp__ring--1 { width: calc(var(--emblem) * 1.38); height: calc(var(--emblem) * 1.38); animation: lp-spin 40s linear infinite; }
.lp__ring--2 { width: calc(var(--emblem) * 1.75); height: calc(var(--emblem) * 1.75); border-style: solid; border-color: rgba(255,255,255,0.07); }
.lp__brand { position: absolute; left: 50%; top: calc(100% + 34px); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; line-height: 1; white-space: nowrap; animation: lp-fade 0.8s 0.7s ease backwards; }
.lp__brand-name { font-family: var(--font-display); font-size: 1.9rem; letter-spacing: 0.24em; color: #fff; padding-left: 0.24em; }
.lp__brand-sub { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.38em; text-transform: uppercase; color: var(--gold-light); margin-top: 9px; padding-left: 0.38em; }

/* ---------- Branch cards (compact) ---------- */
.lp__branch {
  position: relative; z-index: 2; width: 240px; min-height: 172px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 6px;
  padding: 24px 20px 22px; border-radius: 20px; border: 1px solid rgba(255,255,255,0.12);
  background: linear-gradient(160deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.03) 100%);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  transition: transform 0.35s cubic-bezier(.2,.8,.2,1), border-color 0.35s ease, box-shadow 0.35s ease, opacity 0.35s ease, background 0.35s ease;
  cursor: pointer; outline: none;
  animation: lp-card 0.7s var(--t-cards) cubic-bezier(.2,.8,.2,1) backwards;
}
.lp__branch--left { transform-origin: right center; }
.lp__branch--right { transform-origin: left center; }
.lp__icon { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 6px; color: var(--gold-light); background: rgba(212,176,122,0.12); border: 1px solid rgba(212,176,122,0.3); transition: all 0.35s ease; }
.lp__icon svg { width: 22px; height: 22px; }
.lp__label { font-size: 0.64rem; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); padding-left: 0.24em; }
.lp__name { font-family: var(--font-display); font-size: 1.35rem; color: #fff; line-height: 1.2; }
.lp__badge { position: absolute; top: -11px; right: 16px; padding: 4px 11px; border-radius: 999px; font-size: 0.66rem; font-weight: 600; letter-spacing: 0.06em; white-space: nowrap; color: var(--ink); background: var(--gold-light); }

/* Hover / focus: highlight one branch and its line */
.lp__branch:hover, .lp__branch:focus-visible {
  transform: translateY(-5px); border-color: rgba(212,176,122,0.75);
  background: linear-gradient(160deg, rgba(212,176,122,0.18) 0%, rgba(255,255,255,0.04) 100%);
  box-shadow: 0 0 0 1px rgba(212,176,122,0.35), 0 26px 50px rgba(0,0,0,0.35), 0 0 44px rgba(212,176,122,0.18);
}
.lp__branch:hover .lp__icon, .lp__branch:focus-visible .lp__icon { background: var(--gold-light); color: var(--ink); border-color: var(--gold-light); }
.lp__branch:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 4px; }
.lp__stage.hot-left .lp__branch--right, .lp__stage.hot-right .lp__branch--left { opacity: 0.5; }
.lp__stage.hot-left .lp__line--left, .lp__stage.hot-right .lp__line--right { stroke: var(--gold-light); stroke-width: 2; }
.lp__stage.hot-left .lp__flow--left, .lp__stage.hot-right .lp__flow--right { opacity: 1; }
.lp__stage.hot-left .lp__emblem, .lp__stage.hot-right .lp__emblem { box-shadow: 0 0 0 12px rgba(212,176,122,0.22), 0 0 100px rgba(212,176,122,0.55), 0 24px 50px rgba(0,0,0,0.35); }

/* "Coming soon" note */
.lp__toast {
  position: fixed; left: 50%; bottom: max(24px, env(safe-area-inset-bottom)); transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  padding: 12px 20px; border-radius: 999px; background: #fff; color: var(--ink); font-weight: 500; font-size: 0.95rem;
  box-shadow: 0 16px 40px rgba(0,0,0,0.35); transition: all 0.35s ease; z-index: 10; white-space: nowrap;
}
.lp__toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Footer ---------- */
.lp__foot { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 14px; margin-top: 30px; font-size: 0.85rem; color: var(--muted); animation: lp-fade 0.8s 2.3s ease backwards; }
.lp__foot a:hover { color: var(--gold-light); }
.lp__dot { width: 4px; height: 4px; border-radius: 50%; background: var(--muted); opacity: 0.6; }

/* ---------- Motion ---------- */
@keyframes lp-fade { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes lp-pop { from { opacity: 0; transform: scale(0.8); } to { opacity: 1; transform: none; } }
@keyframes lp-draw { to { stroke-dashoffset: 0; } }
@keyframes lp-flow { to { stroke-dashoffset: -17; } }
@keyframes lp-node { from { opacity: 0; transform: scale(0); } to { opacity: 1; transform: none; } }
@keyframes lp-card { from { opacity: 0; transform: scale(0.6); } to { opacity: 1; transform: none; } }
@keyframes lp-spin { to { transform: translate(-50%, -50%) rotate(360deg); } }
.lp__brand { animation-name: lp-brand; }
@keyframes lp-brand { from { opacity: 0; transform: translate(-50%, 10px); } to { opacity: 1; transform: translateX(-50%); } }
/* Phones with "Reduce motion" / power saving turned on still see the
   branches unfold and the cards fade in, just without zooming or spinning. */
@media (prefers-reduced-motion: reduce) {
  .lp__ring--1, .lp__flow { animation: none; }
  .lp__core { animation-name: lp-fade-only; }
  .lp__branch { animation-name: lp-fade-only; }
}
@keyframes lp-fade-only { from { opacity: 0; } to { opacity: 1; } }

/* =========================================================
   Tablet & phone: a "tree". The emblem sits on top; one
   straight stem drops down and splits into two branches,
   each ending at a card.
   ========================================================= */
@media (max-width: 900px) {
  :root { --emblem: 160px; }
  .lp__stage {
    max-width: 620px; margin-top: 54px; padding-bottom: 0;
    grid-template-columns: 1fr 1fr; grid-template-areas: "core core" "left right";
    column-gap: 20px; row-gap: 190px; justify-items: center;
  }
  .lp__core { grid-area: core; }
  .lp__branch--left { grid-area: left; }
  .lp__branch--right { grid-area: right; }
  .lp__branch { width: 100%; max-width: 240px; min-height: 0; align-self: stretch; transform-origin: center top !important; }
}
@media (max-width: 520px) {
  :root { --emblem: 128px; }
  .lp { padding-top: max(36px, env(safe-area-inset-top)); }
  .lp__kicker::before, .lp__kicker::after { display: none; }
  .lp__stage { margin-top: 44px; column-gap: 12px; row-gap: 160px; }
  .lp__brand { top: calc(100% + 26px); }
  .lp__brand-name { font-size: 1.5rem; }
  .lp__brand-sub { font-size: 0.62rem; }
  .lp__branch { padding: 20px 12px 18px; border-radius: 16px; gap: 4px; }
  .lp__icon { width: 38px; height: 38px; border-radius: 11px; margin-bottom: 4px; }
  .lp__icon svg { width: 18px; height: 18px; }
  .lp__label { font-size: 0.58rem; letter-spacing: 0.18em; }
  .lp__name { font-size: 1.05rem; }
  .lp__badge { position: static; order: -1; margin-bottom: 4px; font-size: 0.58rem; padding: 3px 9px; }
  .lp__toast { white-space: normal; text-align: center; width: calc(100% - 40px); border-radius: 16px; }
}
