/* ============================================================
   Kitt — Products page styles  (dark theme page)
   ============================================================ */

/* ---------- PAGE HERO (dark variant — row layout) ---------- */
.page-hero {
  padding: 180px 0 80px;
  border-bottom: 1px solid var(--line-dark);
  margin-bottom: 80px;
}
.page-hero .row {
  display: flex; justify-content: space-between; align-items: flex-end;
  flex-wrap: wrap; gap: 32px;
}
.page-hero h1 {
  font-weight: 900;
  font-size: clamp(56px, 10vw, 140px); line-height: 0.95;
  letter-spacing: -0.05em;
  opacity: 0;
  animation: fade-up 1s .2s cubic-bezier(.2, .7, .2, 1) forwards;
}
.page-hero h1 .light { font-weight: 300; color: var(--muted-2); }
.page-hero .desc {
  max-width: 480px;
  font-size: clamp(15px, 1.1vw, 17px);
  line-height: 1.7;
  color: var(--muted-2); word-break: keep-all;
  opacity: 0;
  animation: fade-up 1s .45s cubic-bezier(.2, .7, .2, 1) forwards;
}
.page-hero .count {
  font-family: var(--mono); font-size: 12px;
  color: var(--muted); letter-spacing: 0.1em;
  margin-bottom: 24px;
  display: flex; align-items: center; gap: 10px;
  opacity: 0;
  animation: fade-up .8s .05s cubic-bezier(.2, .7, .2, 1) forwards;
}
.page-hero .count::before {
  content: ""; width: 5px; height: 5px;
  border-radius: 50%; background: var(--accent);
}

section.portfolio { padding-bottom: 120px; overflow-x: clip; }

/* ---------- PRODUCT ROW (zigzag split layout) ---------- */
.product-row {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 64px; align-items: center;
  padding: 80px 0;
  border-top: 1px solid var(--line-dark);
}
.product-row:first-child { border-top: none; padding-top: 48px; }
.product-row.reverse .product-visual { order: 2; }
.product-row.reverse .product-info  { order: 1; }

.product-visual {
  position: relative; aspect-ratio: 4 / 3;
  border-radius: 24px; overflow: hidden;
  background: #0a0a0a;
}
.product-visual .bg {
  position: absolute; inset: 0;
  transition: transform .8s cubic-bezier(.2, .7, .2, 1);
}
.product-row:hover .product-visual .bg { transform: scale(1.04); }
.product-visual .grid-overlay {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 32px 32px;
}
.product-visual .mark {
  position: absolute; left: 32px; top: 32px;
  font-size: 42px; font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--paper); line-height: 1;
}
.product-visual .mark .light { font-weight: 300; color: var(--muted-2); }
.product-visual .index {
  position: absolute; left: 32px; bottom: 32px;
  font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--muted-2);
}
.product-visual .corner {
  position: absolute; right: 24px; top: 24px;
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: grid; place-items: center;
  transition: background .25s, border-color .25s, transform .3s;
}
.product-row:hover .product-visual .corner {
  background: var(--paper); border-color: var(--paper);
  transform: rotate(-45deg);
}
.product-row:hover .product-visual .corner svg { stroke: var(--ink); }

.product-info { padding: 8px 16px; }
.product-info .tag {
  font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.22em; color: var(--accent);
  margin-bottom: 24px; font-weight: 500;
}
.product-info h3 {
  font-size: clamp(36px, 4.5vw, 56px);
  font-weight: 800; letter-spacing: -0.045em;
  line-height: 1; margin-bottom: 24px;
  color: var(--paper);
}
.product-info .desc {
  font-size: 16px; line-height: 1.75;
  color: var(--muted-2);
  margin-bottom: 32px; word-break: keep-all;
  max-width: 480px;
}
.product-info .features {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-bottom: 32px;
}
.product-info .features span {
  font-family: var(--mono); font-size: 11px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 8px 14px;
  color: var(--muted-2); letter-spacing: 0.04em;
}
.product-info .link {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 600; color: var(--paper);
  padding-bottom: 6px; border-bottom: 1px solid var(--paper);
  transition: gap .2s, opacity .2s;
}
.product-info .link:hover { gap: 14px; opacity: .7; }

@media (max-width: 900px) {
  .product-row { grid-template-columns: 1fr; gap: 32px; padding: 56px 0; }
  .product-info { padding: 0; }
}

/* Visual variants */
.v-workkitt .bg { background: linear-gradient(135deg, #2c2c2c 0%, #0a0a0a 100%); }
.v-sellkitt .bg { background: linear-gradient(135deg, #252525 0%, #0a0a0a 60%, #1a1a1a 100%); }
.v-kitt     .bg { background: linear-gradient(135deg, #3a3a3a 0%, #1a1a1a 50%, #0a0a0a 100%); }

/* ---------- CTA ---------- */
.cta-section {
  text-align: center; padding: 120px 0;
  border-top: 1px solid var(--line-dark);
}
.cta-section h2 {
  font-weight: 900;
  font-size: clamp(40px, 7vw, 88px); letter-spacing: -0.05em;
  line-height: 0.95; margin-bottom: 32px;
}
.cta-section h2 .fade { color: var(--muted); }
.cta-section p {
  font-size: 15px; color: var(--muted-2);
  max-width: 560px; margin: 0 auto 48px;
  line-height: 1.7; word-break: keep-all;
}
.cta-primary {
  display: inline-flex; align-items: center; gap: 16px;
  background: var(--paper); color: var(--ink);
  padding: 20px 14px 20px 40px;
  border-radius: 999px;
  font-size: 16px; font-weight: 600; letter-spacing: -0.01em;
  transition: transform .25s cubic-bezier(.2, .7, .2, 1);
  will-change: transform;
}
.cta-primary .arrow {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--ink); color: var(--paper);
  display: grid; place-items: center;
  transition: transform .3s;
}
.cta-primary:hover .arrow { transform: rotate(-45deg); }

/* ---------- Product-row reveal animation ---------- */
.product-row.reveal .product-visual {
  transform: translateX(-24px); opacity: 0;
  transition: opacity 1s cubic-bezier(.2, .7, .2, 1),
              transform 1s cubic-bezier(.2, .7, .2, 1);
}
.product-row.reveal .product-info {
  transform: translateX(24px); opacity: 0;
  transition: opacity 1s .15s cubic-bezier(.2, .7, .2, 1),
              transform 1s .15s cubic-bezier(.2, .7, .2, 1);
}
.product-row.reverse.reveal .product-visual { transform: translateX(24px); }
.product-row.reverse.reveal .product-info   { transform: translateX(-24px); }
.product-row.reveal.in .product-visual,
.product-row.reveal.in .product-info {
  transform: none; opacity: 1;
}
.product-row.reveal { opacity: 1; transform: none; }

/* ============================================================
   MOBILE PASS — products
   ============================================================ */
@media (max-width: 768px) {
  .page-hero { padding: 120px 0 48px; margin-bottom: 48px; }
  .page-hero .row { flex-direction: column; align-items: flex-start; gap: 20px; }
  .page-hero h1 { font-size: clamp(48px, 14vw, 80px); }
  .page-hero .desc { max-width: 100%; }

  section.portfolio { padding-bottom: 80px; }

  .product-row { padding: 48px 0; }
  .product-row:first-child { padding-top: 24px; }
  .product-visual .mark { font-size: 30px; left: 24px; top: 24px; }
  .product-visual .index { left: 24px; bottom: 24px; }
  .product-visual .corner { width: 36px; height: 36px; right: 18px; top: 18px; }
  .product-info { padding: 0; }
  .product-info h3 { font-size: clamp(32px, 9vw, 48px); margin-bottom: 18px; }
  .product-info .tag { margin-bottom: 16px; }
  .product-info .desc { font-size: 15px; margin-bottom: 24px; }
  .product-info .features { margin-bottom: 24px; }

  .cta-section { padding: 80px 0; }
  .cta-section h2 { font-size: clamp(32px, 9vw, 56px); margin-bottom: 20px; }
  .cta-section p { margin-bottom: 32px; }
  .cta-primary { padding: 16px 12px 16px 28px; font-size: 14px; gap: 12px; }
  .cta-primary .arrow { width: 36px; height: 36px; }
}
