/* =========================================================
   IliasFX website
   Change the colors and font here and they update everywhere.
   ========================================================= */
:root {
  --accent: #184a85;      /* main accent color (dark blue, same family as #0B1318) */
  --bg: #000;             /* page background */
  --text: #fff;
  --muted: #aeaeae;       /* grey text */
  --body-text: rgba(255, 255, 255, 0.72);
  --glass: rgba(255, 255, 255, 0.1);
  --panel: rgba(255, 255, 255, 0.05);
  --line: rgba(255, 255, 255, 0.1);
  --font: 'Satoshi', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { display: block; }

.accent { color: var(--accent); font-weight: 700; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 8px 20px;
  border: 0;
  border-radius: 99px;
  font-family: inherit;
  font-weight: 700;
  font-size: 16px;
  line-height: 24px;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.2s, filter 0.2s;
}
.btn:hover { transform: translateY(-1px); filter: brightness(1.15); }
.btn.has-icon { padding-right: 8px; }
.btn-light   { background: #fff; color: #000; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-secondary {
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  color: #fff;
}

.icon-circle {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #fff;
  color: #000;
}
.icon-circle svg { width: 16px; height: 16px; }
.btn-light .icon-circle { background: #000; color: #fff; }

/* ---------- Navigation (fixed) ---------- */
.nav {
  position: fixed;
  z-index: 100;
  top: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: calc(100% - 160px);
  max-width: 1280px;
  height: 72px;
  padding: 12px;
  border-radius: 999px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  transition: background 0.3s, top 0.3s;
}
.nav.scrolled { background: rgba(20, 24, 30, 0.7); }
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  font-weight: 700;
  font-size: 20px;
  line-height: 28px;
}
.logo-img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--accent);
}
.nav-links {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  gap: 24px;
  list-style: none;
}
.nav-links a {
  display: block;
  padding: 4px 12px;
  border-radius: 99px;
  font-weight: 500;
  font-size: 16px;
  line-height: 24px;
  transition: background 0.2s;
}
.nav-links a:hover,
.nav-links a.is-current { background: var(--glass); }
.nav-actions { display: flex; align-items: center; gap: 16px; }

/* ---------- Background (fixed: it stays put while the page scrolls) ---------- */
.page-bg {
  position: fixed;
  z-index: -1;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.page-bg .texture {
  position: absolute;
  inset: 0;
  opacity: 0.72;
  background: url('../assets/texture.png') center / cover no-repeat;
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent);
          mask-image: linear-gradient(to bottom, #000, transparent);
}
/* Soft blue lights that drift very slowly, for a bit of life without looking "glowy" */
.blob {
  position: absolute;
  border-radius: 50%;
  background: var(--accent);
  filter: blur(110px);
  animation: drift 26s ease-in-out infinite alternate;
}
.blob-1 { left: 6%;   top: 12%; width: 440px; height: 480px; opacity: 0.4; }
.blob-2 { left: 55%;  top: 16%; width: 650px; height: 420px; opacity: 0.4; animation-duration: 32s; animation-delay: -10s; }
.blob-3 {
  left: 30%;
  bottom: -18%;
  width: 720px;
  height: 380px;
  opacity: 0.16;
  background: color-mix(in srgb, var(--accent) 75%, #6fb6ff);
  animation-duration: 38s;
  animation-delay: -20s;
}
@keyframes drift {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(60px, -40px) scale(1.08); }
  100% { transform: translate(-50px, 30px) scale(0.95); }
}

/* ---------- Home (fills exactly one screen, text centered) ---------- */
.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100svh;
  min-height: 620px;
  overflow: hidden;
}
.hero-content {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
}
.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  width: min(860px, 100%);
  text-align: center;
}
.hero-text { display: flex; flex-direction: column; gap: 32px; }
.hero h1 {
  font-weight: 500;
  font-size: clamp(38px, 5.6vw, 72px);
  line-height: 1.215;
  text-wrap: balance;
}
.hero-text p { font-weight: 500; font-size: clamp(16px, 1.4vw, 19px); line-height: 1.5; }
.hero-ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }

/* The planet is part of the fixed background, low enough that the Home text stays in the true center */
.planet {
  position: absolute;
  left: 50%;
  top: max(80%, calc(50% + 240px));
  width: max(104vw, 900px);
  aspect-ratio: 1;
  transform: translateX(-50%);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.01);
  box-shadow: inset 0 12px 36px color-mix(in srgb, var(--accent) 90%, transparent);
}

/* ---------- Shared section styles ---------- */
.section {
  position: relative;
  padding: 120px 24px;
  overflow-x: clip;
}
.container { max-width: 1200px; margin: 0 auto; }
.section-head {
  position: relative;
  margin-bottom: 56px;
  text-align: center;
}
.eyebrow {
  display: inline-block;
  margin-bottom: 16px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--glass);
  color: var(--muted);
  font-weight: 500;
  font-size: 14px;
  line-height: 20px;
}
h2 {
  font-weight: 500;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.2;
  text-wrap: balance;
}
.section-glow {
  position: absolute;
  left: 50%;
  top: 30%;
  width: 700px;
  height: 400px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.22;
  filter: blur(120px);
  pointer-events: none;
}
.section-glow.glow-right { left: 72%; }

/* ---------- Project carousel ---------- */
.carousel {
  --w: min(640px, 62vw);
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}
.track {
  position: relative;
  width: var(--w);
  aspect-ratio: 16 / 9;
  margin: 0 auto;
  touch-action: pan-y;
}
.slide {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #070b10;
  opacity: 0;
  transition: transform 0.55s cubic-bezier(0.22, 0.61, 0.36, 1), opacity 0.55s, box-shadow 0.55s;
}
.slide.is-active {
  z-index: 3;
  opacity: 1;
  transform: none;
  box-shadow: 0 30px 80px color-mix(in srgb, var(--accent) 40%, transparent);
}
.slide.is-prev,
.slide.is-next { z-index: 2; opacity: 0.45; cursor: pointer; }
.slide.is-prev { transform: translateX(-58%) scale(0.7); }
.slide.is-next { transform: translateX(58%) scale(0.7); }
.slide.is-prev:hover,
.slide.is-next:hover { opacity: 0.65; }
.slide:not(.is-active) > * { pointer-events: none; }
.slide iframe,
.slide video { width: 100%; height: 100%; border: 0; object-fit: contain; background: #000; }

.carousel-btn {
  position: absolute;
  z-index: 5;
  top: 50%;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  color: #fff;
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s;
}
.carousel-btn:hover { background: var(--accent); }
.carousel-btn svg { width: 22px; height: 22px; }
.carousel-btn.prev { left: calc(50% - var(--w) / 2 - 26px); }
.carousel-btn.next { right: calc(50% - var(--w) / 2 - 26px); }
.carousel-btn.next svg { transform: rotate(180deg); }

/* ---------- Reviews ---------- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.review-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--panel);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  overflow: hidden;
}
/* big soft quote mark in the corner */
.review-card::before {
  content: '“';
  position: absolute;
  top: -18px;
  right: 22px;
  color: var(--accent);
  font-size: 140px;
  font-weight: 700;
  line-height: 1;
  opacity: 0.35;
  pointer-events: none;
}
.review-top { display: flex; align-items: center; gap: 10px; }
.stars { color: #fff; font-size: 18px; letter-spacing: 3px; }
.review-score {
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--accent);
  font-weight: 700;
  font-size: 13px;
  line-height: 20px;
}
.review-card blockquote {
  flex: 1;
  font-weight: 500;
  font-size: clamp(18px, 1.8vw, 22px);
  line-height: 1.45;
}
.review-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}
.review-tags li {
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--glass);
  color: var(--muted);
  font-weight: 500;
  font-size: 13px;
  line-height: 20px;
}
.review-card figcaption {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 14px;
}
.review-card figcaption strong { font-weight: 700; }
.review-card figcaption span { color: var(--muted); }
.reviews-link { display: flex; justify-content: center; margin-top: 40px; }

/* ---------- About ---------- */
.about-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 72px;
  align-items: center;
}
.about-text p {
  margin-bottom: 20px;
  color: var(--body-text);
  font-size: 17px;
  line-height: 1.65;
}
.about-text .about-lead {
  color: var(--text);
  font-weight: 500;
  font-size: clamp(22px, 2.4vw, 28px);
  line-height: 1.4;
}
.about-text h3 {
  margin: 32px 0 10px;
  font-weight: 700;
  font-size: 20px;
  line-height: 28px;
}
.about-text .about-closing {
  margin: 32px 0 0;
  padding-left: 16px;
  border-left: 2px solid var(--accent);
  color: var(--text);
  font-weight: 500;
}

.about-photo {
  position: relative;
  justify-self: center;
  width: min(420px, 100%);
}
.about-photo img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 32px;
  box-shadow: 0 30px 90px color-mix(in srgb, var(--accent) 45%, transparent);
}
.tool {
  position: absolute;
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 18px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  animation: float 6s ease-in-out infinite;
}
.tool svg { width: 100%; height: 100%; }
.tool-img { display: block; width: 100%; height: 100%; border-radius: 9px; }
/* The Envato file has white margins: zoom in on just the green square */
.envato-img { background: url('../assets/envato%20logo.webp') 50% 50% / 144.3% 108.3% no-repeat; }
.tool-pr     { left: -30px;  top: 14%; }
.tool-ae     { right: -30px; top: 6%;  animation-delay: -1.5s; }
.tool-ps     { left: -30px;  bottom: 12%; animation-delay: -3s; }
.tool-envato { right: -30px; bottom: 20%; animation-delay: -4.5s; }
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

/* ---------- FAQ ---------- */
.faq-list {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 820px;
  margin: 0 auto;
}
.faq-item {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--panel);
  transition: border-color 0.2s, background 0.2s;
}
.faq-item[open] {
  border-color: color-mix(in srgb, var(--accent) 70%, transparent);
  background: rgba(255, 255, 255, 0.07);
}
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  font-weight: 500;
  font-size: 18px;
  line-height: 26px;
  list-style: none;
  cursor: pointer;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--glass);
  transition: transform 0.3s, background 0.3s;
}
.faq-icon svg { width: 16px; height: 16px; }
.faq-item[open] .faq-icon { transform: rotate(45deg); background: var(--accent); }
.faq-answer {
  padding: 0 24px 22px;
  color: var(--body-text);
  font-size: 16px;
  line-height: 1.65;
  animation: reveal 0.3s ease;
}
@keyframes reveal {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}

/* ---------- Contact ---------- */
.contact-card {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 48px 48px;
  border: 1px solid var(--line);
  border-radius: 32px;
  background: var(--panel);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
}
.contact-card .section-head { margin-bottom: 40px; }
.contact-form { display: flex; flex-direction: column; gap: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--muted);
  font-weight: 500;
  font-size: 14px;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  outline: none;
  background: rgba(0, 0, 0, 0.35);
  color: var(--text);
  font-family: inherit;
  font-size: 16px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form ::placeholder { color: rgba(255, 255, 255, 0.35); }
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 35%, transparent);
}
.contact-form .is-invalid { border-color: #c0504d; }
.contact-form .btn { align-self: center; margin-top: 8px; }
.form-status { min-height: 24px; color: var(--muted); font-size: 14px; text-align: center; }
.form-status a { color: var(--text); text-decoration: underline; }
.contact-form.is-error .form-status { color: #e07a77; }
.contact-form .btn:disabled { opacity: 0.6; cursor: wait; transform: none; }

/* ---------- Text reveal animations ----------
   Only active when <html> has .reveal-on (set by the small script in index.html),
   so text is never hidden if JavaScript is off or motion is reduced.
   js/main.js splits text into words; each word slides up from behind a mask. */
:root {
  --ease-reveal: cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-on [data-reveal="words"]:not(.is-split),
.reveal-on [data-reveal="lines"]:not(.is-split) { opacity: 0; }

/* Words / lines: each word sits in a clipping mask and rises into view */
.rw {
  display: inline-block;
  overflow: hidden;
  /* room for descenders (g, y, p) so they are not clipped */
  padding-bottom: 0.12em;
  margin-bottom: -0.12em;
  vertical-align: top;
}
.rw-inner {
  display: inline-block;
  will-change: transform;
}
.reveal-on .is-split .rw-inner {
  opacity: 0;
  transform: translate3d(0, 110%, 0);
  transition:
    transform 0.9s var(--ease-reveal),
    opacity 0.6s var(--ease-reveal);
  transition-delay: calc(var(--base, 0ms) + var(--i, 0) * var(--step, 40ms));
}
.reveal-on .is-split[data-reveal="lines"] .rw-inner { --step: 90ms; }
.reveal-on .is-split.is-revealed .rw-inner {
  opacity: 1;
  transform: none;
}

/* Blocks (buttons, photo, cards): soft fade with a small rise */
.reveal-on [data-reveal="fade"],
.reveal-on [data-reveal-group] > * {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition:
    opacity 0.8s var(--ease-reveal),
    transform 0.9s var(--ease-reveal);
  transition-delay: var(--base, 0ms);
}
.reveal-on [data-reveal="fade"].is-revealed {
  opacity: 1;
  transform: none;
}

/* ---------- Footer ---------- */
.footer {
  padding: 32px 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

/* ---------- Smaller screens ---------- */
@media (max-width: 960px) {
  .nav { top: 16px; width: calc(100% - 32px); }
  .nav-links { position: static; transform: none; gap: 4px; }
  .about-grid { grid-template-columns: 1fr; gap: 56px; }
  .reviews-grid { grid-template-columns: 1fr; max-width: 560px; }
  .about-photo { order: -1; width: min(360px, 80%); }
}
@media (max-width: 820px) {
  .logo span { display: none; }
}
@media (max-width: 640px) {
  .nav { height: 60px; padding: 8px; }
  .nav-actions { display: none; }
  .logo { flex: none; padding: 0 4px; }
  .logo span { display: none; }
  .nav-links { gap: 0; }
  .nav-links a { padding: 4px 7px; font-size: 14px; }
  .section { padding: 96px 16px; }
  .carousel { --w: 80vw; }
  .slide.is-prev { transform: translateX(-46%) scale(0.72); }
  .slide.is-next { transform: translateX(46%) scale(0.72); }
  .carousel-btn { width: 42px; height: 42px; }
  .carousel-btn.prev { left: 4px; }
  .carousel-btn.next { right: 4px; }
  .tool { width: 48px; height: 48px; padding: 8px; border-radius: 14px; }
  .tool-pr, .tool-ps { left: -18px; }
  .tool-ae, .tool-envato { right: -18px; }
  .review-card { padding: 24px; border-radius: 24px; }
  .faq-item summary { padding: 18px; font-size: 16px; }
  .faq-answer { padding: 0 18px 18px; }
  .contact-card { padding: 40px 20px 28px; border-radius: 24px; }
  .form-row { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .tool, .blob { animation: none; }
  .rw-inner, [data-reveal] { transition: none !important; opacity: 1 !important; transform: none !important; }
  .slide { transition: none; }
}
