/* ============================================================
   /custom-software/ — the services landing page (paid traffic lands here).
   Builds on style.css tokens and components; only page-specific parts live here.
   ============================================================ */

/* ---------- hero ---------- */

.cs-hero { overflow: hidden; }

.cs-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: center;
  padding-top: 80px;
  padding-bottom: 96px;
}

.cs-hero h1 { font-size: clamp(2.2rem, 4.3vw, 3.15rem); }

.cs-trust {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  margin-top: 2rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--muted);
}

.cs-trust li::before { content: "✓"; color: var(--cyan); font-weight: 700; margin-right: 0.45rem; }

/* before → after: scattered tools become one system */
.cs-diagram {
  display: grid;
  grid-template-columns: 1fr auto 1.25fr;
  align-items: center;
  gap: 1.2rem;
}

.cs-mess { display: flex; flex-direction: column; align-items: flex-start; gap: 0.6rem; }

.cs-mess span {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--muted);
  background: #fff;
  border: 1.5px dashed #CDD3E0;
  border-radius: 8px;
  padding: 0.45rem 0.75rem;
  white-space: nowrap;
}
/* resting scatter uses the individual rotate/translate properties,
   so the entrance animation (transform) layers on top of it */
.cs-mess span:nth-child(odd)  { rotate: -2.5deg; translate: 6px 0; }
.cs-mess span:nth-child(3n)   { rotate: 2deg; translate: 18px 0; }
.cs-mess span:nth-child(4)    { rotate: -1deg; translate: -4px 0; }

.cs-arrow span {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--cyan);
  color: #fff;
  font-weight: 700;
  font-size: 1.2rem;
  box-shadow: 0 8px 22px rgba(24, 160, 224, 0.35);
}

.cs-system {
  background: var(--indigo);
  color: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(32, 41, 68, 0.25);
}

.cs-system-bar { display: flex; gap: 6px; padding: 12px 14px; background: rgba(255, 255, 255, 0.06); }
.cs-system-bar span { width: 9px; height: 9px; border-radius: 50%; background: rgba(255, 255, 255, 0.25); }

.cs-system-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #6FC8F0;
  padding: 1.1rem 1.3rem 0.4rem;
}

.cs-system ul { list-style: none; padding: 0.3rem 1.3rem 1.3rem; display: grid; gap: 0.55rem; }

.cs-system li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.07);
  font-weight: 600;
  font-size: 0.95rem;
}

.cs-system li i { width: 9px; height: 9px; border-radius: 50%; background: var(--cyan); flex: none; }

/* ---------- the load sequence: scattered tools drift in, then the system lights up ---------- */

.cs-system-title { display: flex; align-items: center; gap: 0.55rem; }
.cs-system-title::after {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ADE80;
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.6);
  animation: live 2.4s ease-out 2s infinite;
}

.cs-mess span { animation: chip-in 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.cs-mess span:nth-child(1) { animation-delay: 0.20s; }
.cs-mess span:nth-child(2) { animation-delay: 0.28s; }
.cs-mess span:nth-child(3) { animation-delay: 0.36s; }
.cs-mess span:nth-child(4) { animation-delay: 0.44s; }
.cs-mess span:nth-child(5) { animation-delay: 0.52s; }
.cs-mess span:nth-child(6) { animation-delay: 0.60s; }

.cs-arrow span { animation: arrow-in 0.6s cubic-bezier(0.3, 1.4, 0.5, 1) 0.75s both; }

.cs-system { animation: system-in 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) 0.85s both; }

.cs-system li { animation: row-on 0.5s ease both; }
.cs-system li:nth-child(1) { animation-delay: 1.15s; }
.cs-system li:nth-child(2) { animation-delay: 1.27s; }
.cs-system li:nth-child(3) { animation-delay: 1.39s; }
.cs-system li:nth-child(4) { animation-delay: 1.51s; }
.cs-system li:nth-child(5) { animation-delay: 1.63s; }

.cs-system li i { animation: dot-on 0.5s ease both; animation-delay: inherit; }

@keyframes chip-in {
  from { opacity: 0; transform: translate(-28px, 10px) rotate(-10deg); filter: blur(4px); }
  to   { opacity: 1; transform: none; filter: none; }
}
@keyframes arrow-in {
  from { opacity: 0; transform: scale(0.4); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes system-in {
  from { opacity: 0; transform: translateY(22px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}
@keyframes row-on {
  from { opacity: 0.15; transform: translateX(-10px); background: rgba(255, 255, 255, 0.02); }
  to   { opacity: 1; transform: none; }
}
@keyframes dot-on {
  from { background: rgba(255, 255, 255, 0.25); box-shadow: none; }
  60%  { box-shadow: 0 0 0 6px rgba(24, 160, 224, 0.25); }
  to   { background: var(--cyan); box-shadow: 0 0 10px rgba(24, 160, 224, 0.6); }
}
@keyframes live {
  0%   { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.6); }
  70%  { box-shadow: 0 0 0 8px rgba(74, 222, 128, 0); }
  100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .cs-mess span, .cs-arrow span, .cs-system, .cs-system li, .cs-system li i,
  .cs-system-title::after { animation: none; }
}

/* ---------- shared section bits ---------- */

.cs-lede { color: var(--muted); font-size: 1.15rem; max-width: 40em; margin-top: 1.2rem; }

/* ---------- pain ---------- */

.cs-pain {
  padding: 90px 0;
  background: #fff;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.cs-pain-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-top: 2.4rem;
}

.cs-pain-grid li {
  padding: 1.2rem 1.4rem 1.2rem 3rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  font-weight: 600;
  position: relative;
}

.cs-pain-grid li::before {
  content: "";
  position: absolute;
  left: 1.3rem;
  top: 1.55rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid #E0A03A;
}

.cs-pain-answer { margin-top: 2.2rem; font-size: 1.15rem; color: var(--muted); max-width: 42em; }
.cs-pain-answer strong { color: var(--ink); }

/* ---------- what we build ---------- */

.cs-build { padding: 90px 0; }

.cs-build-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.3rem;
  margin-top: 2.8rem;
}

.cs-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.6rem;
}

.cs-card-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--cyan);
  margin-bottom: 0.7rem;
}

.cs-card h3 { font-size: 1.15rem; margin-bottom: 0.55rem; }
.cs-card p { color: var(--muted); font-size: 0.98rem; }

/* things we can build */
.cs-examples-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-top: 2.6rem;
}
.cs-examples { margin-top: 0.9rem; }
.cs-examples li { background: #fff; border: 1px solid var(--line); }

.btn-cyan { background: var(--cyan); color: #fff; }
.btn-cyan:hover { background: #0F86BF; box-shadow: 0 8px 24px rgba(24, 160, 224, 0.35); }

/* ---------- who we build for ---------- */

.cs-case {
  background: var(--indigo);
  color: #fff;
  padding: 96px 0;
  overflow: hidden;
}

.cs-case-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: center;
}

.cs-case h2 { color: #fff; font-size: clamp(1.8rem, 3.4vw, 2.5rem); }

.cs-case-copy > p { color: #C4CBDA; margin-top: 1.1rem; }

.cs-industries {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.7rem;
}

.cs-industries li {
  padding: 0.85rem 1rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #E4E8F1;
  font-weight: 600;
  font-size: 0.95rem;
}

.cs-case-link { margin-top: 2rem; }

/* ---------- process (light take on the home page's dark steps) ---------- */

.cs-process { padding: 96px 0; background: #fff; border-bottom: 1px solid var(--line); }

.cs-process .steps { margin-top: 3rem; }
.cs-process .step h3 { color: var(--ink); }
.cs-process .step p { color: var(--muted); }
.cs-process .step-num { border-bottom-color: var(--line); }

.cs-quote {
  margin-top: 3.5rem;
  padding: 2rem 2.2rem;
  border-radius: 18px;
  background: var(--sky);
  border: 1px solid #CFE7F7;
  display: flex;
  gap: 2rem;
  align-items: center;
  justify-content: space-between;
}

.cs-quote h3 { font-size: 1.45rem; }
.cs-quote p { color: var(--muted); margin-top: 0.4rem; max-width: 36em; }
.cs-quote .btn { flex: none; }

/* ---------- FAQ ---------- */

.cs-faq { padding: 96px 0; }

.faq-list { max-width: 52rem; margin-top: 2.2rem; border-top: 1px solid var(--line); }

.faq-list details { border-bottom: 1px solid var(--line); }

.faq-list summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.15rem 0;
  font-weight: 700;
  font-size: 1.08rem;
}

.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-family: var(--font-mono); color: var(--cyan); font-size: 1.2rem; line-height: 1.3; }
.faq-list details[open] summary::after { content: "–"; }
.faq-list summary:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; }

.faq-list details p { color: var(--muted); padding: 0 0 1.3rem; max-width: 46em; }

/* the form section sits on white here so it separates from the FAQ */
.cs-contact { background: #fff; border-top: 1px solid var(--line); }
.cs-contact .contact-form { background: var(--paper); }

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .cs-hero-grid { grid-template-columns: 1fr; gap: 3rem; padding-top: 56px; padding-bottom: 64px; }
  .cs-build-grid { grid-template-columns: 1fr 1fr; }
  .cs-case-grid { grid-template-columns: 1fr; gap: 2.8rem; }
  .cs-quote { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 640px) {
  .cs-pain, .cs-build, .cs-case, .cs-process, .cs-faq { padding: 64px 0; }
  .cs-pain-grid, .cs-build-grid { grid-template-columns: 1fr; }
  .cs-diagram { grid-template-columns: 1fr; justify-items: stretch; }
  .cs-mess { flex-direction: row; flex-wrap: wrap; justify-content: center; }
  .cs-mess span { rotate: none; translate: none; }
  .cs-arrow { justify-self: center; }
  .cs-arrow { rotate: 90deg; }
  .cs-industries li { font-size: 0.88rem; padding: 0.75rem 0.85rem; }
  .cs-quote { padding: 1.6rem; }
}

/* ============================================================
   Service detail pages (/ai-automation/, /custom-software/<service>/)
   reuse everything above; only these parts are their own.
   ============================================================ */

.sv-hero-grid { grid-template-columns: 1.15fr 0.85fr; }

.sv-crumb a { color: inherit; text-decoration: none; border-bottom: 1px solid currentColor; }
.sv-crumb a:hover { color: var(--cyan); }

/* the short, plain answer: what it is, who it's for, how it's priced */
.sv-facts {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 0.6rem 1.8rem;
  box-shadow: 0 12px 32px rgba(32, 41, 68, 0.08);
}
.sv-facts > div { padding: 1.15rem 0; border-bottom: 1px solid var(--line); }
.sv-facts > div:last-child { border-bottom: 0; }
.sv-facts dt {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--cyan);
  margin-bottom: 0.35rem;
}
.sv-facts dd { font-weight: 600; line-height: 1.45; }

/* linked cards and card titles */
.cs-card h3 a { color: inherit; text-decoration: none; }
.cs-card h3 a:hover, .cs-examples a:hover { color: var(--cyan); }
.cs-card h3 a:focus-visible, a.sv-link:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; }
.cs-examples a { color: inherit; text-decoration: none; }

.sv-related { padding: 90px 0; border-top: 1px solid var(--line); }
a.sv-link { display: block; color: var(--ink); text-decoration: none; transition: border-color 0.2s ease, transform 0.2s ease; }
a.sv-link:hover { border-color: var(--cyan); transform: translateY(-2px); }
a.sv-link h3 span { color: var(--cyan); }

@media (max-width: 900px) {
  .sv-hero-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .sv-related { padding: 64px 0; }
}
@media (prefers-reduced-motion: reduce) {
  a.sv-link { transition: none; }
  a.sv-link:hover { transform: none; }
}

/* ---------- pricing (hub + service pages) ---------- */

.sv-pricing { padding: 90px 0; border-bottom: 1px solid var(--line); }
.cs-card .sv-price-fig {
  color: var(--ink);
  font-size: 1.7rem;
  font-weight: 800;
  font-stretch: 115%;
  letter-spacing: -0.01em;
  line-height: 1.1;
  margin-bottom: 0.9rem;
  white-space: nowrap;
}
.sv-price h3 { font-size: 1.05rem; }
.sv-pricing .cs-quote { margin-top: 2.2rem; }

/* ---------- case study (/work/flyte/) ---------- */

.cw-shots { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem 1.3rem; margin-top: 3rem; }
.cw-shot img {
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(32, 41, 68, 0.1);
}
.cw-shot figcaption { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); margin-top: 0.7rem; }
.cw-services { background: #fff; }
.cw-services .cs-card { background: var(--paper); }

@media (max-width: 640px) {
  .sv-pricing { padding: 64px 0; }
  .cw-shots { grid-template-columns: 1fr; }
}
