/* =========================================================
   JWL — system.html page specific styles
   ========================================================= */

/* ---------- Hero: dual image stack ---------- */
.page-system .sys-hero::before {
  background-image: url("../../img/jigyo05-005.jpg");
  opacity: 0.18;
}

.sys-hero-inner .jp-hero-content { max-width: 760px; }
.sys-hero-visual {
  position: relative;
  display: grid !important;
  grid-template-columns: 1fr;
  gap: 18px !important;
  width: min(100%, 520px);
  justify-self: end;
}
.sys-hero-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.14);
  background: #0a0e1a;
  box-shadow: 0 30px 80px -45px rgba(59,130,246,0.55);
  aspect-ratio: 16/9;
}
.sys-hero-card img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: brightness(0.78) saturate(0.95) contrast(1.05);
}
.sys-hero-card::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, transparent 40%, rgba(5,7,13,0.75) 100%),
    radial-gradient(ellipse 60% 50% at 80% 20%, rgba(59,130,246,0.15), transparent 70%);
}
.sys-hero-card-offset { transform: translateX(-32px); }
.sys-hero-tag {
  position: absolute;
  left: 16px; bottom: 14px;
  z-index: 1;
  font-family: var(--font-en);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.22em;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(5,7,13,0.65);
  border: 1px solid rgba(255,255,255,0.22);
  color: var(--text);
  backdrop-filter: blur(6px);
}

/* ---------- Pillar grid: 4 cards fit ---------- */
.sys-pillar-grid {
  grid-template-columns: repeat(4, 1fr);
}

/* ---------- Tech Stack ---------- */
.stack-lead {
  max-width: 780px;
  color: var(--text-2);
  line-height: 1.95;
  margin-bottom: 42px;
  font-size: clamp(14px, 1vw, 15.5px);
}
.stack-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.stack-card {
  position: relative;
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  transition: transform .3s, border-color .3s;
}
.stack-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
}
.stack-img {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
}
.stack-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: brightness(0.85) saturate(0.95);
  transition: transform .6s ease;
}
.stack-card:hover .stack-img img { transform: scale(1.04); }
.stack-img::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(5,7,13,0.7) 100%);
}
.stack-body {
  padding: 22px 24px 26px;
  display: flex; flex-direction: column;
  gap: 8px;
}
.stack-tag {
  align-self: flex-start;
  font-family: var(--font-en);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(59,130,246,0.12);
  color: var(--accent-2);
  border: 1px solid rgba(59,130,246,0.25);
  margin-bottom: 4px;
}
.stack-card h4 {
  font-family: var(--font-jp);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
  margin: 0;
}
.stack-techs {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-3);
  margin: 2px 0 8px;
  line-height: 1.6;
}
.stack-body p:last-child {
  color: var(--text-2);
  font-size: 13.5px;
  line-height: 1.85;
}
.stack-body strong { color: var(--text); font-weight: 600; }

.stack-chips-block {
  margin-top: 56px;
  padding: 30px 32px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: 18px;
}
.stack-chips-block h3 {
  font-family: var(--font-jp);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0;
  margin-bottom: 16px;
  color: var(--text);
}

/* ---------- Works grid ---------- */
.works-lead {
  max-width: 780px;
  color: var(--text-2);
  line-height: 1.95;
  margin-bottom: 40px;
  font-size: clamp(14px, 1vw, 15.5px);
}
.works-lead strong { color: var(--text); font-weight: 600; }
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.work-card {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  transition: transform .3s, border-color .3s;
}
.work-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34,211,238,0.32);
}
.work-img {
  position: relative;
  margin: 0;
  aspect-ratio: 16/10;
  overflow: hidden;
}
.work-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
  filter: brightness(0.88) saturate(1.02);
}
.work-card:hover .work-img img { transform: scale(1.05); }
.work-img::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(5,7,13,0.72) 100%);
}
.work-badge {
  position: absolute;
  left: 16px; top: 16px;
  z-index: 1;
  font-family: var(--font-en);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(5,7,13,0.7);
  border: 1px solid rgba(255,255,255,0.22);
  color: var(--accent-3);
  backdrop-filter: blur(6px);
}
.work-body {
  padding: 22px 24px 26px;
  display: flex; flex-direction: column;
  gap: 10px;
  flex: 1;
}
.work-industry {
  font-family: var(--font-en);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-3);
}
.work-card h3 {
  font-family: var(--font-jp);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
  margin: 0;
  line-height: 1.4;
}
.work-body > p {
  color: var(--text-2);
  font-size: 13.5px;
  line-height: 1.85;
  flex: 1;
}
.work-body > p strong { color: var(--text); font-weight: 600; }

.work-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.work-stats > div {
  display: flex; flex-direction: column;
  gap: 2px;
}
.work-stats strong {
  font-family: var(--font-en);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.work-stats span {
  font-size: 11.5px;
  color: var(--text-3);
  letter-spacing: 0.05em;
}

/* ---------- 2026 capabilities grid ---------- */
.new-lead {
  max-width: 760px;
  color: var(--text-2);
  line-height: 1.95;
  margin-bottom: 40px;
  font-size: clamp(14px, 1vw, 15.5px);
}
.new-lead strong { color: var(--text); font-weight: 600; }
.new-grid {
  grid-template-columns: repeat(4, 1fr);
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .sys-pillar-grid { grid-template-columns: repeat(2, 1fr); }
  .stack-grid { grid-template-columns: repeat(2, 1fr); }
  .works-grid { grid-template-columns: repeat(2, 1fr); }
  .new-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 820px) {
  .sys-hero-visual { width: 100%; justify-self: stretch; }
  .sys-hero-card-offset { transform: none; }
}
@media (max-width: 640px) {
  .sys-pillar-grid { grid-template-columns: 1fr; }
  .stack-grid { grid-template-columns: 1fr; }
  .works-grid { grid-template-columns: 1fr; }
  .new-grid { grid-template-columns: 1fr; }
  .work-stats { grid-template-columns: 1fr 1fr; }
  .stack-chips-block { padding: 22px 20px; }
}
