/* ─────────────────────────────────────────
   HARMONY — Homepage
   Builds on the .sd-* components in css/service-detail.css.
   ───────────────────────────────────────── */

/* ══════════════ HERO ══════════════ */
.hh { position: relative; padding: 150px 0 0; overflow: hidden; border-bottom: 1px solid var(--sd-border); }
.hh-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hh-bg img, .hh-bg video {
  width: 100%; height: 100%; object-fit: cover; opacity: .55;
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
}
.hh-bg::after { content: ''; position: absolute; inset: 0; background: rgba(10,10,10,.45); }

.hh-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 64px; align-items: center; }
.hh-h1 { margin: 0; display: flex; flex-direction: column; }
.hh-kicker {
  display: inline-flex; align-self: flex-start; align-items: center; gap: 10px; margin-bottom: 28px;
  padding: 8px 16px; border-radius: 100px; background: rgba(17,17,17,.85); border: 1px solid var(--sd-border-h);
  font-size: 14px; font-weight: 600; line-height: 1.5; color: #fff;
}
.hh-kicker i { width: 8px; height: 8px; border-radius: 50%; background: var(--sd-green); flex-shrink: 0; }
.hh-l1, .hh-l2 { font-size: 62px; font-weight: 800; line-height: 1.2; letter-spacing: -0.02em; }
.hh-l2 { color: var(--sd-green); }
.hh-body { max-width: 560px; margin: 28px 0 0; font-size: 18px; line-height: 1.9; color: var(--sd-body); }

.hh-proof { display: flex; align-items: center; gap: 18px; margin-top: 40px; }
.hh-avatars { display: flex; }
.hh-avatars span { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--sd-surface); border: 2px solid var(--sd-bg); }
.hh-avatars span + span { margin-right: -12px; }
.hh-avatars img { width: 26px; height: 26px; object-fit: contain; opacity: .85; }
.hh-proof p { margin: 0; font-size: 14px; line-height: 1.7; color: var(--sd-muted); }
.hh-proof b { color: #fff; }
.hh-proof p span { font-size: 13px; color: var(--sd-green); }

.hh-ch-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px;
  border-radius: 10px; background: var(--sd-green-t); border: 1px solid var(--sd-green-b); color: #fff; text-decoration: none;
}
.hh-ch-foot b { display: block; font-size: 14.5px; font-weight: 700; }
.hh-ch-foot small { display: block; font-size: 12.5px; color: var(--sd-muted); }
.hh-ch-foot:hover .sd-arrow { background: var(--sd-green); border-color: var(--sd-green); color: #0A0A0A; }

/* Stats */
.hh-stats { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 88px; border-top: 1px solid var(--sd-border); }
.hh-stat { padding: 36px 24px; text-align: center; }
.hh-stat + .hh-stat { border-right: 1px solid var(--sd-border); }
.hh-stat b { display: block; font-size: 44px; font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; }
.hh-stat em { font-style: normal; color: var(--sd-green); }
.hh-stat small { display: block; margin-top: 8px; font-size: 14px; color: var(--sd-muted); }

/* ══════════════ TRUST STRIP ══════════════ */
.hh-trust { border-bottom: 1px solid var(--sd-border); }
.hh-trust-inner { display: flex; align-items: center; gap: 32px; padding-top: 28px; padding-bottom: 28px; }
.hh-trust-label { flex-shrink: 0; max-width: 170px; margin: 0; font-size: 13.5px; line-height: 1.7; color: var(--sd-muted); }
.hh-trust .sd-link { flex-shrink: 0; }

/* ══════════════ PROBLEM ══════════════ */
.hp-mark { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: #1A1A1A; color: var(--sd-muted); }
.hp-mark svg { width: 16px; height: 16px; }
.hp-answer { display: flex; align-items: center; gap: 20px; margin-top: 24px; padding: 24px 28px; border-radius: 14px; background: var(--sd-surface); border: 1px solid var(--sd-green-b); }
.hp-answer p { flex: 1; margin: 0; font-size: 16px; line-height: 1.8; color: var(--sd-body); }
.hp-answer b { color: #fff; }
.hp-answer .sd-link { flex-shrink: 0; }

/* ══════════════ SERVICES ══════════════ */
.hs-groups { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.hs-group { background: var(--sd-bg); border: 1px solid var(--sd-border); border-radius: 14px; padding: 24px; }
.hs-group-head { display: flex; align-items: center; gap: 10px; padding-bottom: 16px; margin-bottom: 8px; border-bottom: 1px solid var(--sd-border); }
.hs-group-head span { font: 600 12px 'Inter', sans-serif; color: var(--sd-green); }
.hs-group-head h3 { margin: 0; font-size: 17px; font-weight: 700; }
.hs-group ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.hs-group a { display: flex; align-items: center; gap: 12px; margin: 0 -8px; padding: 10px 8px; border-radius: 10px; color: #fff; text-decoration: none; transition: background .15s ease; }
.hs-group a:hover { background: var(--sd-surface); }
.hs-ic { width: 36px; height: 36px; border-radius: 10px; flex-shrink: 0; display: grid; place-items: center; background: var(--sd-green-t); color: var(--sd-green); }
.hs-ic svg { width: 17px; height: 17px; }
.hs-txt { flex: 1; min-width: 0; }
.hs-txt b { display: block; font-size: 14.5px; font-weight: 600; line-height: 1.5; }
.hs-txt small { display: block; font-size: 12.5px; line-height: 1.6; color: var(--sd-muted); }
.hs-group a > svg { width: 14px; height: 14px; flex-shrink: 0; color: #444; transition: color .15s; }
.hs-group a:hover > svg { color: var(--sd-green); }
.hs-more { margin-top: 40px; text-align: center; }

/* ══════════════ SOCIAL ADS ══════════════ */
.hso-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.hso-card {
  display: flex; flex-direction: column; gap: 14px; padding: 28px; border-radius: 14px;
  background: var(--sd-surface); border: 1px solid var(--sd-border); color: #fff; text-decoration: none;
  transition: border-color .2s ease;
}
.hso-card:hover { border-color: color-mix(in srgb, var(--pc, #24C76A) 50%, transparent); }
.hso-card h3 { margin: 0; font-size: 18px; font-weight: 700; line-height: 1.5; }
.hso-card p { flex: 1; margin: 0; font-size: 14px; line-height: 1.8; color: var(--sd-muted); }
.hso-more { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; color: #fff; }
.hso-more svg { width: 14px; height: 14px; color: var(--pc, #24C76A); }
.hso-card--all { background: var(--sd-green-t); border-color: var(--sd-green-b); }
.hso-card--all .hso-more { color: var(--sd-green); }

/* ══════════════ WHY ══════════════ */
.hw-h2 span { color: var(--sd-green); }

/* ══════════════ ABOUT (SEO) ══════════════ */
.ha-grid { display: grid; grid-template-columns: 1fr 360px; gap: 64px; align-items: start; }
.ha-prose { max-width: none; }
.ha-prose .sd-h2 { margin-bottom: 28px; }
.ha-prose a { font-weight: 600; }
.ha-facts { position: sticky; top: 110px; background: var(--sd-surface); border: 1px solid var(--sd-border); border-radius: 14px; padding: 28px; }
.ha-facts-title { margin: 0 0 8px; font-size: 16px; font-weight: 700; }
.ha-facts ul { list-style: none; margin: 0 0 24px; padding: 0; }
.ha-facts li { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--sd-border); }
.ha-facts li:first-child { border-top: 0; }
.ha-facts small { display: block; font-size: 12px; color: var(--sd-muted); }
.ha-facts b { display: block; font-size: 14.5px; font-weight: 600; line-height: 1.6; }

/* ══════════════ BLOG ══════════════ */
.hb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.hb-card { display: flex; flex-direction: column; background: var(--sd-bg); border: 1px solid var(--sd-border); border-radius: 14px; overflow: hidden; color: #fff; text-decoration: none; transition: border-color .2s ease; }
.hb-card:hover { border-color: var(--sd-border-h); }
.hb-img { aspect-ratio: 16 / 10; background: #151515; overflow: hidden; border-bottom: 1px solid var(--sd-border); }
.hb-img img { width: 100%; height: 100%; object-fit: cover; }
.hb-body { flex: 1; display: flex; flex-direction: column; gap: 10px; padding: 24px; }
.hb-body time { font-size: 12.5px; font-weight: 600; color: var(--sd-green); }
.hb-body h3 { margin: 0; font-size: 17px; font-weight: 700; line-height: 1.65; }
.hb-body p { margin: 0; font-size: 14px; line-height: 1.8; color: var(--sd-muted); }
.hb-more { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 8px; font-size: 13.5px; font-weight: 600; color: var(--sd-green); }
.hb-more svg { width: 14px; height: 14px; }

/* ══════════════ RESPONSIVE ══════════════ */
@media (max-width: 1100px) {
  .hs-groups { grid-template-columns: repeat(2, 1fr); }
  .hso-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
  .hh-grid { grid-template-columns: 1fr; gap: 56px; }
  .hh-trust-inner { flex-wrap: wrap; gap: 20px; }
  .hh-trust-label { max-width: none; flex-basis: 100%; }
  .hso-grid { grid-template-columns: repeat(2, 1fr); }
  .ha-grid { grid-template-columns: 1fr; gap: 40px; }
  .ha-facts { position: static; }
  .hb-grid { grid-template-columns: repeat(2, 1fr); }
  .hb-grid .hb-card:nth-child(3) { display: none; }
}

@media (max-width: 767px) {
  .hh { padding-top: 112px; }
  .hh-kicker { font-size: 12.5px; padding: 7px 14px; margin-bottom: 20px; }
  .hh-l1, .hh-l2 { font-size: 38px; }
  .hh-body { font-size: 16px; margin-top: 20px; }
  .hh-proof { margin-top: 32px; }
  .hh-stats { grid-template-columns: repeat(2, 1fr); margin-top: 56px; }
  .hh-stat:nth-child(3) { border-right: 0; }
  .hh-stat:nth-child(n+3) { border-top: 1px solid var(--sd-border); }
  .hh-stat b { font-size: 32px; }
  .hp-answer { flex-direction: column; align-items: flex-start; padding: 22px; }
  .hs-groups { grid-template-columns: 1fr; }
  .hso-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .hso-card { padding: 18px; gap: 10px; }
  .hso-card h3 { font-size: 15px; }
  .hso-card p { font-size: 12.5px; }
  .hso-card .plat-ic--lg { width: 40px; height: 40px; }
  .hb-grid { grid-template-columns: 1fr; }
  .hb-grid .hb-card:nth-child(3) { display: flex; }
}


/* ══════════════ MOTION & ICONIC LAYER ══════════════ */

/* Headline: each line slides up from behind a mask */
.hh-line { display: block; overflow: hidden; padding-bottom: .12em; margin-bottom: -.12em; }
.hh-line > span { display: inline-block; animation: hhLineUp .9s var(--sd-ease) both; animation-delay: var(--d, 0ms); }
@keyframes hhLineUp { from { transform: translateY(105%); } to { transform: none; } }

/* Kicker: live dot */
.hh-kicker i { position: relative; }
.hh-kicker i::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: var(--sd-green); animation: hhPing 1.8s ease-out infinite; }
@keyframes hhPing { from { transform: scale(1); opacity: .7; } to { transform: scale(2.8); opacity: 0; } }

.hh-proof p span { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; }
.hh-proof .yk-logo { height: 16px; }

/* ── Channel orbit ── */
.hh-orbit { width: 100%; max-width: 520px; margin: 0 auto; }
.orb-stage { position: relative; width: 100%; aspect-ratio: 1; container-type: inline-size; }
.orb-ring {
  position: absolute; top: 50%; left: 50%; border-radius: 50%; transform: translate(-50%, -50%);
  border: 1px dashed #3A3A3A; animation: orbRingIn 1s var(--sd-ease) both;
}
.orb-ring--1 { width: 54%; height: 54%; animation-delay: .25s; }
.orb-ring--2 { width: 88%; height: 88%; animation-delay: .4s; }
.orb-ring--3 { width: 100%; height: 100%; border: 1px solid #151515; animation-delay: .55s; }
@keyframes orbRingIn { from { opacity: 0; transform: translate(-50%, -50%) scale(.82); } to { opacity: 1; transform: translate(-50%, -50%); } }

.orb-core {
  position: absolute; top: 50%; left: 50%; z-index: 2; width: 22%; aspect-ratio: 1; transform: translate(-50%, -50%);
  display: grid; place-items: center; border-radius: 50%; background: var(--sd-surface); border: 1px solid var(--sd-green-b);
}
.orb-core img { width: 56%; height: auto; animation: orbSpin 24s linear infinite; }
.orb-pulse { position: absolute; inset: -1px; border-radius: 50%; border: 1px solid var(--sd-green); animation: orbPulse 3.2s ease-out infinite; pointer-events: none; }
.orb-pulse--2 { animation-delay: 1.6s; }
@keyframes orbPulse { from { transform: scale(1); opacity: .55; } to { transform: scale(2.3); opacity: 0; } }

.orb-track { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; animation: orbSpin 48s linear infinite; }
.orb-track--2 { animation-duration: 72s; animation-direction: reverse; }
.orb-track li { position: absolute; top: 50%; left: 50%; width: 0; height: 0; transform: rotate(var(--a)) translateX(var(--r)) rotate(calc(-1 * var(--a))); }
.orb-track--1 li { --r: 27cqw; }
.orb-track--2 li { --r: 44cqw; }
.orb-item { position: absolute; left: 0; top: 0; display: block; transform: translate(-50%, -50%); z-index: 3; }
.orb-inner { position: relative; display: block; animation: orbSpin 48s linear infinite reverse; }
.orb-track--2 .orb-inner { animation-duration: 72s; animation-direction: normal; }
@keyframes orbSpin { to { transform: rotate(360deg); } }

.orb-item .plat-ic {
  width: max(44px, 11.5cqw); height: max(44px, 11.5cqw); border-radius: 14px;
  background: #111; background: color-mix(in srgb, var(--pc) 14%, #111);
  animation: orbPop .7s var(--sd-ease) backwards; animation-delay: calc(var(--i) * 90ms + 500ms);
  transition: transform .3s var(--sd-ease), border-color .3s ease;
}
.orb-item .plat-ic svg { width: 44%; height: 44%; color: var(--sd-green); }
.orb-item:hover .plat-ic, .orb-item:focus-visible .plat-ic { transform: translateY(-4px); border-color: var(--pc); }
@keyframes orbPop { from { opacity: 0; transform: scale(.3); } to { opacity: 1; transform: none; } }
.orb-tip {
  position: absolute; top: calc(100% + 8px); left: 50%; transform: translate(-50%, 4px);
  padding: 4px 10px; border-radius: 100px; background: var(--sd-bg); border: 1px solid var(--sd-border-h);
  font-size: 12px; font-weight: 600; color: #fff; white-space: nowrap; opacity: 0; pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
}
.orb-item:hover .orb-tip, .orb-item:focus-visible .orb-tip { opacity: 1; transform: translate(-50%, 0); }
.orb-stage:hover .orb-track, .orb-stage:hover .orb-inner, .orb-stage:focus-within .orb-track, .orb-stage:focus-within .orb-inner { animation-play-state: paused; }
.hh-orbit .hh-ch-foot { margin-top: 8px; }

/* ── Client logo marquee ── */
.hh-marquee {
  flex: 1; min-width: 0; overflow: hidden;
  -webkit-mask-image: linear-gradient(to left, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(to left, transparent, #000 8%, #000 92%, transparent);
}
.hh-marquee-track { display: flex; width: max-content; direction: ltr; animation: hhMarquee 45s linear infinite; }
.hh-marquee:hover .hh-marquee-track { animation-play-state: paused; }
.hh-trust-logos { display: flex; align-items: center; gap: 56px; margin: 0; padding: 0 56px 0 0; list-style: none; flex-shrink: 0; }
.hh-trust-logos img { display: block; width: auto; height: auto; max-width: 104px; max-height: 44px; object-fit: contain; opacity: .5; transition: opacity .2s ease; }
.hh-trust-logos li:hover img { opacity: 1; }
@keyframes hhMarquee { to { transform: translateX(-50%); } }

/* Loops scroll leftward, so anchor them to the left edge (content inside stays RTL). */
.hh-marquee, .hk-row { direction: ltr; }
.hh-trust-logos { direction: rtl; }

/* ── Keyword + platform ticker ── */
.hk { overflow: hidden; padding: 56px 0; border-bottom: 1px solid var(--sd-border); display: flex; flex-direction: column; gap: 28px; }
.hk-row {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to left, transparent, #000 6%, #000 94%, transparent);
          mask-image: linear-gradient(to left, transparent, #000 6%, #000 94%, transparent);
}
.hk-track { display: flex; width: max-content; direction: ltr; animation: hhMarquee 60s linear infinite; }
.hk-row--b .hk-track { animation-duration: 50s; animation-direction: reverse; }
.hk-row:hover .hk-track { animation-play-state: paused; }
.hk-track ul { display: flex; align-items: center; gap: 36px; margin: 0; padding: 0 36px 0 0; list-style: none; flex-shrink: 0; direction: rtl; }
.hk-row--a li { font-size: 60px; font-weight: 800; line-height: 1.3; letter-spacing: -0.02em; white-space: nowrap; color: #fff; }
.hk-row--a li.is-outline { color: transparent; -webkit-text-stroke: 1.2px #4a4a4a; }
.hk-sep img { width: 36px; height: 36px; display: block; animation: orbSpin 10s linear infinite; }
.hk-row--b a {
  display: inline-flex; align-items: center; gap: 12px; padding: 10px 20px 10px 12px; border-radius: 100px;
  background: var(--sd-surface); border: 1px solid var(--sd-border); color: #fff; font-size: 16px; font-weight: 600;
  white-space: nowrap; text-decoration: none; transition: border-color .2s ease;
}
.hk-row--b a:hover { border-color: color-mix(in srgb, var(--pc) 60%, transparent); }
.hk-row--b .plat-ic { border-radius: 50%; }

/* ── Hover motion on cards (after the entrance) ── */
.home .sd-card, .home .hso-card, .home .hb-card, .home .sd-work, .home .hs-group, .home .hp-answer {
  transition-property: opacity, transform, border-color; transition-duration: .5s, .35s, .2s;
}
.home .sd-card.is-in:hover, .home .hso-card.is-in:hover, .home .hb-card.is-in:hover, .home .sd-work.is-in:hover { transform: translateY(-6px); }
.home .sd-card .sd-icon, .hso-card .plat-ic, .hs-ic { transition: transform .35s var(--sd-ease); }
.home .sd-card:hover .sd-icon { transform: translateY(-2px) rotate(-8deg); }
.hso-card:hover .plat-ic { transform: translateY(-3px) rotate(-8deg); }
.hs-group a:hover .hs-ic { transform: rotate(-8deg); }
.home .sd-work-img img, .hb-img img { transition: transform .6s var(--sd-ease); }
.home .sd-work:hover .sd-work-img img, .hb-card:hover .hb-img img { transform: scale(1.05); }
.hso-more svg, .hb-more svg, .home .sd-link svg { transition: transform .25s var(--sd-ease); }
.hso-card:hover .hso-more svg, .hb-card:hover .hb-more svg, .home .sd-link:hover svg { transform: translateX(-4px); }

/* Problem marks spin in when revealed */
.sd-js .home .hp-card .hp-mark { transform: rotate(-90deg) scale(.4); opacity: 0; transition: transform .6s var(--sd-ease) .25s, opacity .4s ease .25s; }
.sd-js .home .hp-card.is-in .hp-mark { transform: none; opacity: 1; }

/* Process: connecting line draws in */
.sd-js .home .sd-steps::before { transform: scaleX(0); transform-origin: right; transition: transform 1.4s var(--sd-ease) .2s; }
.sd-js .home .sd-steps.is-drawn::before { transform: scaleX(1); }

/* Yektanet mark inside an icon tile */
.yk-ic { width: 76px; background: #161616; }
.yk-ic .yk-ic-img { height: 20px; width: auto; }

@media (max-width: 767px) {
  .hh-orbit { max-width: 380px; }
  .orb-tip { display: none; }
  .hk { padding: 40px 0; gap: 20px; }
  .hk-row--a li { font-size: 36px; }
  .hk-sep img { width: 26px; height: 26px; }
  .hk-row--b a { font-size: 14px; padding: 8px 16px 8px 10px; }
  .hh-trust-logos { gap: 36px; padding-right: 36px; }
  .hh-trust-logos img { max-width: 84px; max-height: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .hh-line > span, .orb-ring, .orb-item .plat-ic { animation: none; }
  .orb-track, .orb-inner, .orb-core img, .orb-pulse, .hh-kicker i::after, .hk-sep img { animation: none; }
  .hh-marquee-track, .hk-track { animation: none; }
  .hh-marquee, .hk-row { overflow-x: auto; }
}

/* ══════════════ TESTIMONIALS ══════════════ */
.tm-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.tm-card {
  margin: 0; padding: 28px; display: flex; flex-direction: column; gap: 18px;
  background: var(--sd-surface); border: 1px solid var(--sd-border); border-radius: 14px;
}
.tm-stars { display: flex; gap: 4px; }
.tm-stars svg { width: 16px; height: 16px; color: #333; }
.tm-stars svg.is-on { color: var(--sd-green); }
.tm-card blockquote { margin: 0; flex: 1; font-size: 15.5px; line-height: 2; color: var(--sd-body); }
.tm-card figcaption { display: flex; align-items: center; gap: 12px; }
.tm-card figcaption img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.tm-avatar-fallback {
  width: 44px; height: 44px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center;
  background: var(--sd-green-t); color: var(--sd-green); font-size: 16px; font-weight: 700;
}
.tm-card figcaption span:last-child { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tm-card figcaption b { font-size: 14.5px; font-weight: 700; }
.tm-card figcaption small { font-size: 12.5px; color: var(--sd-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

@media (max-width: 1024px) { .tm-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 767px) { .tm-grid { grid-template-columns: 1fr; } }
