/*
  TAG Solutions — HUB-only styles.
  NEW in Stage A; wired into portfolio/index.html by Stage D (the hub rework).
  Loaded AFTER /main_style.css and /portfolio/portfolio.css. Everything here is
  hub-specific; shared components (process-row, trust generic, .pro-flow, motion
  utilities, lane themes) come from portfolio.css.

  NOTE: until Stage D swaps the hub markup, the live hub still reads these same
  rules from the LEGACY block in portfolio.css. Keep the two in sync if edited.
*/

/* ---------- Hub hero ---------- */
.hub-hero { max-width: 980px; margin: 0 auto; text-align: center; }

.logo-stage.compact {
  width: min(300px, 68vw);
  height: min(300px, 68vw);
  margin: 0 auto 0.9rem;
}

.hub-hero .studio-name { margin: 0 auto; }

.hub-hero .tagline { margin: 0.6rem auto 0; }
.hub-hero .tagline > span { display: block; }

.tagline-strong {
  margin-top: 0.55rem;
  font-weight: 750;
  color: color-mix(in srgb, var(--accent) 62%, var(--text));
}

.hub-hero .hero-actions { margin-top: 1.8rem; justify-content: center; }

.services-head { margin: 1rem auto 2rem; }

/* ---------- Category grid (lane link cards) ---------- */
.solutions-grid { margin-bottom: 3rem; }

@media (min-width: 620px) and (max-width: 819px) {
  .solutions-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/*
  Stage D: each category card becomes
  <a class="option-card lane-card {lane}" href="/portfolio/{lane}/"> with a
  locally-scoped accent so the grid previews all six hues, and a pure-CSS mini
  preview strip. Scope accents like main_style's .option-card.animation trick:
*/
.lane-card.web    { --accent: #38b6ff; --accent2: #66c2ff; }
.lane-card.dash   { --accent: #46e6a8; --accent2: #7df2c8; }
.lane-card.auto   { --accent: #ffd17d; --accent2: #ffe3a8; }
.lane-card.sheets { --accent: #7bdff2; --accent2: #a8dadc; }
.lane-card.ai     { --accent: #b18cff; --accent2: #cdb4ff; }
.lane-card.games  { --accent: #ff5e8a; --accent2: #ff8fb0; }

.lane-card { text-decoration: none; color: var(--text); display: flex; flex-direction: column; }
.lane-card h3 { margin: 0.9rem 0 0.4rem; }
.lane-card p { flex: 1 1 auto; }
.lane-card .option-cta { margin-top: 1rem; }

.lane-card .lane-preview {
  position: relative;
  margin-top: 1.1rem;
  height: 64px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, rgba(255,255,255,0.08));
  background: color-mix(in srgb, var(--accent) 8%, rgba(0,0,0,0.25));
  overflow: hidden;
}

/* Preview strips: static by default; animate only for users who allow motion,
   and only once the card has revealed (play-state gated on .reveal.in). */

/* web — skeleton loading bars */
.lp-web { display: flex; flex-direction: column; justify-content: center; gap: 7px; padding: 0 14px; }
.lp-web .lp-bar {
  height: 7px;
  border-radius: 999px;
  background:
    linear-gradient(90deg,
      color-mix(in srgb, var(--accent) 22%, rgba(255,255,255,0.06)) 0%,
      color-mix(in srgb, var(--accent) 60%, #fff) 50%,
      color-mix(in srgb, var(--accent) 22%, rgba(255,255,255,0.06)) 100%);
  background-size: 220% 100%;
  background-position: 120% 0;
}
.lp-web .lp-bar:nth-child(1) { width: 82%; }
.lp-web .lp-bar:nth-child(2) { width: 64%; }
.lp-web .lp-bar:nth-child(3) { width: 90%; }
.lp-web .lp-bar:nth-child(4) { width: 48%; }

/* dashboards — rising bars */
.lp-dash { display: flex; align-items: flex-end; justify-content: center; gap: 6px; padding: 10px 14px; }
.lp-dash .lp-col {
  width: 12px;
  border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent2) 85%, #fff), color-mix(in srgb, var(--accent) 70%, transparent));
  transform-origin: bottom;
  transform: scaleY(0.25);
}
.lp-dash .lp-col:nth-child(1) { height: 70%; }
.lp-dash .lp-col:nth-child(2) { height: 44%; }
.lp-dash .lp-col:nth-child(3) { height: 88%; }
.lp-dash .lp-col:nth-child(4) { height: 56%; }
.lp-dash .lp-col:nth-child(5) { height: 78%; }
.lp-dash .lp-col:nth-child(6) { height: 38%; }

/* automation — pulsing dots along a line */
.lp-auto { display: flex; align-items: center; justify-content: space-between; padding: 0 16px; }
.lp-auto .lp-line {
  position: absolute;
  left: 16px; right: 16px; top: 50%;
  height: 2px;
  transform: translateY(-50%);
  background: color-mix(in srgb, var(--accent) 30%, rgba(255,255,255,0.1));
}
.lp-auto .lp-dot {
  position: relative;
  width: 10px; height: 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 80%, #fff);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent);
}

/* spreadsheets — 3x3 cells tinting in sequence */
.lp-sheets { display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(3, 1fr); gap: 4px; padding: 8px 14px; }
.lp-sheets .lp-cell {
  border-radius: 4px;
  background: rgba(255,255,255,0.06);
  border: 1px solid color-mix(in srgb, var(--accent) 14%, rgba(255,255,255,0.06));
}

/* ai — alternating chat bubbles */
.lp-ai { display: flex; flex-direction: column; justify-content: center; gap: 6px; padding: 0 14px; }
.lp-ai .lp-bubble {
  height: 12px;
  border-radius: 8px;
  opacity: 0;
}
.lp-ai .lp-bubble.in  { width: 58%; align-self: flex-start; background: rgba(255,255,255,0.14); }
.lp-ai .lp-bubble.out { width: 44%; align-self: flex-end;   background: color-mix(in srgb, var(--accent) 55%, transparent); }

/* games — bouncing ball + paddle */
.lp-games .lp-ball {
  position: absolute;
  left: 50%; top: 12px;
  width: 12px; height: 12px;
  margin-left: -6px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 80%, #fff);
  box-shadow: 0 0 12px color-mix(in srgb, var(--accent) 60%, transparent);
}
.lp-games .lp-paddle {
  position: absolute;
  left: 50%; bottom: 8px;
  width: 34px; height: 6px;
  margin-left: -17px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent2) 85%, #fff);
}

@media (prefers-reduced-motion: no-preference) {
  .lp-web .lp-bar { animation: lpSkeleton 1.8s linear infinite; animation-play-state: paused; }
  .lp-web .lp-bar:nth-child(2) { animation-delay: 0.15s; }
  .lp-web .lp-bar:nth-child(3) { animation-delay: 0.3s; }
  .lp-web .lp-bar:nth-child(4) { animation-delay: 0.45s; }

  .lp-dash .lp-col { animation: lpRise 1.9s ease-in-out infinite alternate; animation-play-state: paused; }
  .lp-dash .lp-col:nth-child(2) { animation-delay: 0.12s; }
  .lp-dash .lp-col:nth-child(3) { animation-delay: 0.24s; }
  .lp-dash .lp-col:nth-child(4) { animation-delay: 0.36s; }
  .lp-dash .lp-col:nth-child(5) { animation-delay: 0.48s; }
  .lp-dash .lp-col:nth-child(6) { animation-delay: 0.6s; }

  .lp-auto .lp-dot { animation: lpPulse 1.8s ease-in-out infinite; animation-play-state: paused; }
  .lp-auto .lp-dot:nth-child(3) { animation-delay: 0.3s; }
  .lp-auto .lp-dot:nth-child(4) { animation-delay: 0.6s; }
  .lp-auto .lp-dot:nth-child(5) { animation-delay: 0.9s; }

  .lp-sheets .lp-cell { animation: lpTint 3.6s ease-in-out infinite; animation-play-state: paused; }
  .lp-sheets .lp-cell:nth-child(1) { animation-delay: 0s; }
  .lp-sheets .lp-cell:nth-child(2) { animation-delay: 0.2s; }
  .lp-sheets .lp-cell:nth-child(3) { animation-delay: 0.4s; }
  .lp-sheets .lp-cell:nth-child(4) { animation-delay: 0.6s; }
  .lp-sheets .lp-cell:nth-child(5) { animation-delay: 0.8s; }
  .lp-sheets .lp-cell:nth-child(6) { animation-delay: 1.0s; }
  .lp-sheets .lp-cell:nth-child(7) { animation-delay: 1.2s; }
  .lp-sheets .lp-cell:nth-child(8) { animation-delay: 1.4s; }
  .lp-sheets .lp-cell:nth-child(9) { animation-delay: 1.6s; }

  .lp-ai .lp-bubble { animation: lpBubble 3s ease-in-out infinite; animation-play-state: paused; }
  .lp-ai .lp-bubble:nth-child(2) { animation-delay: 0.5s; }
  .lp-ai .lp-bubble:nth-child(3) { animation-delay: 1.0s; }

  .lp-games .lp-ball { animation: lpBall 1.4s ease-in-out infinite; animation-play-state: paused; }
  .lp-games .lp-paddle { animation: lpPaddle 1.4s ease-in-out infinite; animation-play-state: paused; }

  .lane-card.reveal.in .lane-preview .lp-bar,
  .lane-card.reveal.in .lane-preview .lp-col,
  .lane-card.reveal.in .lane-preview .lp-dot,
  .lane-card.reveal.in .lane-preview .lp-cell,
  .lane-card.reveal.in .lane-preview .lp-bubble,
  .lane-card.reveal.in .lane-preview .lp-ball,
  .lane-card.reveal.in .lane-preview .lp-paddle {
    animation-play-state: running;
  }
}

@keyframes lpSkeleton { to { background-position: -120% 0; } }
@keyframes lpRise { from { transform: scaleY(0.22); } to { transform: scaleY(1); } }
@keyframes lpPulse {
  0%, 100% { transform: scale(0.85); box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 45%, transparent); }
  40% { transform: scale(1.25); box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 0%, transparent); }
}
@keyframes lpTint {
  0%, 70%, 100% { background: rgba(255,255,255,0.06); }
  20%, 45% { background: color-mix(in srgb, var(--accent) 55%, transparent); }
}
@keyframes lpBubble {
  0%, 12% { opacity: 0; transform: translateY(4px); }
  22%, 88% { opacity: 1; transform: none; }
  100% { opacity: 0; transform: translateY(-4px); }
}
@keyframes lpBall {
  0%   { top: 12px; left: 42%; }
  50%  { top: 40px; left: 58%; }
  100% { top: 12px; left: 42%; }
}
@keyframes lpPaddle {
  0%   { left: 42%; }
  50%  { left: 58%; }
  100% { left: 42%; }
}

/* ---------- Trust strip ---------- */
.trust-strip {
  width: 100%;
  max-width: 1050px;
  margin: 0 auto 3.2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.trust-card {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.9rem 1.25rem;
  border-radius: var(--radius);
  background: var(--card-strong);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 18px 60px rgba(0,0,0,0.34);
  color: var(--text);
  text-decoration: none;
  transition: transform 200ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.trust-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 55%, rgba(255,255,255,0.16));
  box-shadow: 0 22px 80px rgba(0,0,0,0.42), 0 0 34px color-mix(in srgb, var(--accent) 16%, transparent);
}

.trust-card > i.fa-upwork {
  font-size: 1.9rem;
  color: color-mix(in srgb, var(--accent) 85%, #fff);
  filter: drop-shadow(0 0 14px color-mix(in srgb, var(--accent) 30%, transparent));
}

.trust-card strong { display: block; font-size: 1.02rem; }
.trust-card span { display: block; color: var(--muted); font-size: 0.85rem; margin-top: 0.1rem; }
.trust-ext { font-size: 0.8rem; color: var(--muted); }

.trust-pills { display: inline-flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
.trust-pills .pill { gap: 0.45rem; padding: 0.42rem 0.85rem; font-size: 0.88rem; }
.trust-pills .pill i { font-size: 0.8rem; }

/* ---------- Case studies ---------- */
.item-card.blue { border-left: 4px solid var(--blue); }

.casestudies { margin-bottom: 3.2rem; }

.casestudy-art {
  display: grid;
  place-items: center;
  min-height: 140px;
  font-size: 3rem;
  color: color-mix(in srgb, var(--accent) 55%, rgba(255,255,255,0.4));
  background:
    radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 60%),
    rgba(0,0,0,0.28);
}

@media (min-width: 900px) {
  .casestudies .item-card { grid-template-columns: 190px 1fr; }
  .casestudy-art { min-height: 100%; }
}

/* ---------- Reviews (hidden until real reviews exist) ---------- */
#reviews-block[data-reviews="pending"] { display: none; }

.reviews-grid {
  width: 100%;
  max-width: 1050px;
  margin: 0 auto 3rem;
  display: grid;
  gap: 1.2rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* ---------- Hub footer ---------- */
.hub-foot { text-align: center; margin: 1rem auto 0; max-width: 980px; }
.hub-foot .section-title { font-size: clamp(1.7rem, 3.4vw, 2.2rem); }
.hub-foot .micro { display: block; margin-top: 2.4rem; font-size: 0.85rem; }
