/* AYNDA Tech — Coming Soon
   Brand colors come from the logo gradient (pink → coral → orange). */

@font-face {
  font-family: "Inter";
  src: url("fonts/inter.woff2") format("woff2");
  font-weight: 100 900; font-display: swap;
}
@font-face { font-family: "Vazirmatn"; src: url("fonts/vazirmatn-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("fonts/vazirmatn-700.woff2") format("woff2"); font-weight: 500 700; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("fonts/vazirmatn-900.woff2") format("woff2"); font-weight: 800 900; font-display: swap; }

:root {
  --bg: #0b0b0d;
  --card: rgba(245, 245, 242, .035);
  --text: #f5f5f2;
  --muted: rgba(245, 245, 242, .60);
  --faint: rgba(245, 245, 242, .32);
  --line: rgba(245, 245, 242, .12);
  --pink: #e2336f;
  --coral: #f0756a;
  --orange: #f6aa4f;
  --brand: linear-gradient(90deg, var(--pink), var(--coral) 50%, var(--orange));
  --font: "Inter", "Vazirmatn", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
html[dir="rtl"] { --font: "Vazirmatn", "Inter", ui-sans-serif, system-ui, sans-serif; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--bg); color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }

/* ---------- Background glow ---------- */
.bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.orb { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .30; }
.orb-1 { width: 520px; height: 520px; background: var(--pink); top: -180px; left: -160px; animation: drift 18s ease-in-out infinite alternate; }
.orb-2 { width: 560px; height: 560px; background: var(--orange); bottom: -220px; right: -180px; opacity: .22; animation: drift 22s ease-in-out infinite alternate-reverse; }
.grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(245,245,242,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(245,245,242,.035) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse at 50% 30%, #000 15%, transparent 65%);
          mask-image: radial-gradient(ellipse at 50% 30%, #000 15%, transparent 65%);
}

/* ---------- Layout ---------- */
.page {
  position: relative; z-index: 1;
  max-width: 1100px; margin: 0 auto;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column;
  padding: max(26px, env(safe-area-inset-top)) 42px max(24px, env(safe-area-inset-bottom));
}

/* ---------- Top bar ---------- */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: "Inter", sans-serif; font-size: 14px; font-weight: 800; letter-spacing: .18em; direction: ltr; }
.brand img { width: 28px; height: 28px; }
.brand b { opacity: .45; font-weight: 600; }
.top-right { display: flex; align-items: center; gap: 10px; }

.pill, .status, .lang {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px;
  background: rgba(245,245,242,.03);
  font-size: 12px; font-weight: 600; color: var(--muted);
}
.status { letter-spacing: .06em; }
html[dir="ltr"] .status { text-transform: uppercase; font-size: 11px; }
.status i { width: 7px; height: 7px; border-radius: 50%; background: var(--orange); animation: pulse 2s infinite; }

.lang { cursor: pointer; color: var(--text); transition: border-color .2s ease, background .2s ease; }
.lang:hover, .lang:focus-visible { border-color: rgba(240,117,106,.55); background: rgba(240,117,106,.08); outline: none; }
.lang svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; }
html[dir="ltr"] .lang span { font-family: "Vazirmatn", sans-serif; }
html[dir="rtl"] .lang span { font-family: "Inter", sans-serif; }

/* ---------- Hero ---------- */
.hero {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 30px 0 20px;
}
.logo-wrap { position: relative; width: clamp(130px, min(22vw, 20vh), 220px); margin: clamp(10px, 2vh, 24px) auto clamp(34px, 6vh, 56px); }
.logo-wrap::before { content: ""; position: absolute; inset: 12% 8%; background: var(--brand); filter: blur(46px); opacity: .45; border-radius: 50%; z-index: -1; }
.site-logo { position: relative; z-index: 2; width: 100%; height: auto; }

h1 {
  margin: 0;
  font-size: clamp(56px, min(11.5vw, 14.5vh), 150px);
  line-height: .84; letter-spacing: -.07em; font-weight: 900;
  background: linear-gradient(100deg, var(--text) 0%, var(--text) 42%, #ffd2b8 48%, var(--coral) 50%, #ffd2b8 52%, var(--text) 58%, var(--text) 100%);
  background-size: 300% 100%;
  padding: .06em .12em .02em;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: rise 1s cubic-bezier(.2,.7,.2,1) both .7s, sweep 7s ease-in-out infinite 2.2s;
}
html[dir="rtl"] h1 { letter-spacing: 0; line-height: 1.15; font-size: clamp(52px, min(11vw, 14vh), 132px); }
h1 span { display: inline-block; background: var(--brand); -webkit-background-clip: text; background-clip: text; color: transparent; animation: dot 2.4s ease-in-out infinite 2s; }

.subtitle { margin: 24px 0 0; color: var(--muted); font-size: clamp(15px, 1.7vw, 19px); letter-spacing: .03em; animation: rise 1s cubic-bezier(.2,.7,.2,1) both .95s; }
/* ---------- Section titles ---------- */
.eyebrow {
  margin: 0 0 22px; text-align: center;
  font-size: 12px; font-weight: 700; letter-spacing: .28em; text-transform: uppercase; color: var(--faint);
}
html[dir="rtl"] .eyebrow { letter-spacing: 0; font-size: 15px; }

/* ---------- Follow ---------- */
.follow { padding: 22px 0 26px; }
.socials { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; }
.social {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-width: 150px; padding: 13px 20px;
  border: 1px solid var(--line); border-radius: 999px; background: rgba(245,245,242,.03);
  text-decoration: none; font-size: 13px; font-weight: 650;
  transition: transform .2s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.social:hover, .social:focus-visible {
  transform: translateY(-2px); outline: none;
  border-color: rgba(240,117,106,.55); background: rgba(240,117,106,.08);
  box-shadow: 0 10px 30px -12px rgba(226,51,111,.55);
}
.social svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.social svg.filled { fill: currentColor; stroke: none; }

/* ---------- Footer ---------- */
footer { text-align: center; padding-top: 20px; border-top: 1px solid rgba(245,245,242,.06); }
.email-link { display: inline-block; color: var(--muted); text-decoration: none; font-size: 13px; transition: color .2s ease; }
.email-link:hover, .email-link:focus-visible { color: var(--text); }
footer p { margin: 8px 0 0; color: var(--faint); font-size: 11px; letter-spacing: .08em; }

/* ---------- Animations ---------- */
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes drift { from { transform: translate(0, 0); } to { transform: translate(80px, 60px); } }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(246,170,79,.6); }
  70% { box-shadow: 0 0 0 8px rgba(246,170,79,0); }
  100% { box-shadow: 0 0 0 0 rgba(246,170,79,0); }
}


/* =========================================================
   ANIMATIONS
   ========================================================= */

/* 1. Logo intro: comes out of a blur, then floats */
.logo-wrap { animation: logo-in 1.3s cubic-bezier(.2,.8,.2,1) both .1s, float 6s ease-in-out infinite 1.4s; }
.logo-wrap::before { animation: breathe 4s ease-in-out infinite; }

/* 2. Two thin rings spinning around the logo */
.ring {
  position: absolute; z-index: 0; left: 50%; top: 50%;
  width: 128%; aspect-ratio: 1; border-radius: 50%;
  translate: -50% -50%;
  background: conic-gradient(from 0deg, transparent 0 60%, rgba(226,51,111,.0) 60%, var(--pink) 78%, var(--orange) 92%, transparent 100%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 1.5px), #000 calc(100% - 1px));
          mask: radial-gradient(farthest-side, transparent calc(100% - 1.5px), #000 calc(100% - 1px));
  opacity: 0; animation: ring-in 1.2s ease both .6s, spin 9s linear infinite;
}
.ring::after { /* small glowing dot riding on the ring */
  content: ""; position: absolute; top: 50%; right: -3px; width: 7px; height: 7px; margin-top: -3.5px;
  border-radius: 50%; background: var(--orange); box-shadow: 0 0 12px 3px rgba(246,170,79,.7);
}
.ring-2 { width: 110%; animation: ring-in 1.2s ease both .8s, spin 14s linear infinite reverse; }
.ring-2::after { background: var(--pink); box-shadow: 0 0 12px 3px rgba(226,51,111,.7); right: auto; left: -3px; }

/* 3. Light shine that passes over the logo */
.shine {
  position: absolute; inset: 0; z-index: 3; pointer-events: none;
  background: linear-gradient(110deg, transparent 38%, rgba(255,255,255,.85) 50%, transparent 62%);
  background-size: 260% 100%; background-position: 130% 0;
  -webkit-mask: url("sitelogo.png?v=5") center / contain no-repeat;
          mask: url("sitelogo.png?v=5") center / contain no-repeat;
  mix-blend-mode: soft-light;
  animation: shine 5s ease-in-out infinite 1.6s;
}

/* 4. Follow section: title and buttons appear one by one */
.follow .eyebrow { animation: rise 1s cubic-bezier(.2,.7,.2,1) both 1.15s; }
.social { opacity: 0; animation: pop .7s cubic-bezier(.2,.9,.3,1.2) forwards; }
.social:nth-child(1) { animation-delay: 1.3s; }
.social:nth-child(2) { animation-delay: 1.42s; }
.social:nth-child(3) { animation-delay: 1.54s; }
footer { animation: fade 1.2s ease both 1.8s; }
.top { animation: fade 1s ease both .2s; }

/* 5. Little sparks rising in the background */
.spark {
  position: absolute; bottom: -20px; left: 50%;
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--coral); box-shadow: 0 0 8px 2px rgba(240,117,106,.6);
  opacity: 0; animation: rise-spark 12s linear infinite;
}
.spark:nth-of-type(3n)   { background: var(--orange); box-shadow: 0 0 8px 2px rgba(246,170,79,.6); }
.spark:nth-of-type(3n+1) { background: var(--pink);   box-shadow: 0 0 8px 2px rgba(226,51,111,.6); }
.spark:nth-of-type(4)  { left: 6%;  animation-duration: 14s; animation-delay: 0s; }
.spark:nth-of-type(5)  { left: 14%; animation-duration: 11s; animation-delay: 3s;  width: 3px; height: 3px; }
.spark:nth-of-type(6)  { left: 22%; animation-duration: 16s; animation-delay: 6s; }
.spark:nth-of-type(7)  { left: 30%; animation-duration: 12s; animation-delay: 1.5s; width: 2px; height: 2px; }
.spark:nth-of-type(8)  { left: 38%; animation-duration: 15s; animation-delay: 8s; }
.spark:nth-of-type(9)  { left: 46%; animation-duration: 10s; animation-delay: 4s;  width: 3px; height: 3px; }
.spark:nth-of-type(10) { left: 54%; animation-duration: 13s; animation-delay: 9s; }
.spark:nth-of-type(11) { left: 62%; animation-duration: 17s; animation-delay: 2s;  width: 2px; height: 2px; }
.spark:nth-of-type(12) { left: 70%; animation-duration: 12s; animation-delay: 7s; }
.spark:nth-of-type(13) { left: 78%; animation-duration: 14s; animation-delay: 5s;  width: 3px; height: 3px; }
.spark:nth-of-type(14) { left: 86%; animation-duration: 11s; animation-delay: 10s; }
.spark:nth-of-type(15) { left: 93%; animation-duration: 16s; animation-delay: 3.5s; width: 2px; height: 2px; }
.spark:nth-of-type(16) { left: 10%; animation-duration: 18s; animation-delay: 11s; }
.spark:nth-of-type(17) { left: 50%; animation-duration: 15s; animation-delay: 12s; width: 3px; height: 3px; }
.spark:nth-of-type(18) { left: 66%; animation-duration: 19s; animation-delay: 6.5s; }
.spark:nth-of-type(19) { left: 34%; animation-duration: 13s; animation-delay: 13s; width: 2px; height: 2px; }

/* 6. Soft light that follows the mouse (computers only) */
.spot {
  position: absolute; left: 0; top: 0; width: 520px; height: 520px; margin: -260px 0 0 -260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240,117,106,.13), transparent 65%);
  transform: translate(var(--mx, -999px), var(--my, -999px));
  transition: transform .25s ease-out, opacity .4s ease;
  opacity: 0;
}
.has-mouse .spot { opacity: 1; }

/* 7. Logo tilts a little toward the mouse (set by main.js) */
.hero .logo-wrap img, .hero .shine { transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .3s ease-out; }
.logo-wrap { perspective: 800px; }

@keyframes logo-in { from { opacity: 0; transform: scale(.7); filter: blur(14px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes ring-in { from { opacity: 0; } to { opacity: .9; } }
@keyframes spin { to { rotate: 360deg; } }
@keyframes breathe { 0%, 100% { opacity: .38; transform: scale(1); } 50% { opacity: .6; transform: scale(1.08); } }
@keyframes shine { 0%, 55% { background-position: 130% 0; } 85%, 100% { background-position: -30% 0; } }
@keyframes sweep { 0%, 40% { background-position: 100% 0; } 70%, 100% { background-position: 0% 0; } }
@keyframes dot { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.25); } }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise-spark {
  0%   { opacity: 0; transform: translate(0, 0); }
  10%  { opacity: .9; }
  50%  { transform: translate(18px, -50vh); }
  85%  { opacity: .6; }
  100% { opacity: 0; transform: translate(-12px, -105vh); }
}

/* ---------- Tablet / phone ---------- */
@media (max-width: 600px) {
  .page { padding-left: 18px; padding-right: 18px; }
  .status { display: none; }
  .socials { flex-direction: column; align-items: center; }
  .social { width: min(100%, 260px); }
  .orb-1 { width: 340px; height: 340px; }
  .orb-2 { width: 360px; height: 360px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .social { opacity: 1; }
  .ring { opacity: .9; }
  .spark, .shine, .spot { display: none; }
}
