/* ==========================================================================
   Company introduction page (/introduction)

   Loaded after industries.css and home.css (introduction/index.blade.php),
   which supply the navy hero, cards, buttons, section heads, the stats
   strip, the Japan-Vietnam visual, the article cards and the Japanese
   line-breaking rules. This file only adds what this page has and the
   others do not: the sticky in-page nav, the company profile cards, the
   vision and mission cards, the article grid with its pagination and the
   links to the careers page and social media. Plain CSS with a filemtime()
   query string - nothing may need building on the live box.

   Everything is scoped under .in-page.
   ========================================================================== */

/* .ind-page's overflow-x: hidden makes it a scroll container, which stops
   the in-page nav from sticking; clip hides the overflow without that. */
.in-page { overflow-x: clip; --in-nav-top: 72px; }

.in-page:lang(ja) dt, .in-page:lang(ja) dd, .in-page:lang(ja) a { word-break: auto-phrase; }

/* --- Hero ---------------------------------------------------------------- */
/* `.ind-page p { margin: 0 }` outranks .ind-eyebrow's own margin. */
.in-page .in-hero .ind-eyebrow { margin-bottom: 18px; }
.in-page .in-hero .ind-hero-lead { max-width: 40em; }
.in-page .in-hero .hp-hero-stats { margin-top: 44px !important; }
.in-page .in-hero .hp-bridge-role { text-wrap: balance; }

/* --- In-page nav --------------------------------------------------------- */
/* Sticks under the site header, which is fixed at every width; the page's
   script sets --in-nav-top to the header's height as it changes. */
.in-page .in-subnav { position: sticky; top: var(--in-nav-top); z-index: 20; box-shadow: 0 6px 16px rgba(26, 42, 108, .05); }
.in-page .in-subnav ul { justify-content: center; }
.in-page .in-subnav a[aria-current] { color: #fff; background: var(--ind-navy); }
/* Header + nav, so a jump to a section is not hidden under them. */
.in-page .ind-section { scroll-margin-top: calc(var(--in-nav-top) + 24px); }

/* --- Company profile ----------------------------------------------------- */
.in-offices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.in-office { padding: 0; overflow: hidden; }
.in-office-head {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 28px;
  background: var(--ind-bg);
  border-bottom: 1px solid var(--ind-line);
}
.in-office-head .ind-icon { margin: 0; background: #fff; }
.in-page .in-office-place { font-size: .82rem; font-weight: 700; color: var(--ind-accent); line-height: 1.5; }
.in-office-head h3 { margin: 0; font-size: 1.2rem; }
.in-profile { margin: 0; padding: 6px 28px 18px; }
.in-profile-row {
  display: grid;
  grid-template-columns: 9.5em minmax(0, 1fr);
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--ind-line);
}
.in-profile-row:last-child { border-bottom: 0; }
.in-profile dt { font-size: .86rem; font-weight: 800; line-height: 1.7; color: var(--ind-navy); }
.in-profile dd { margin: 0; font-size: .95rem; line-height: 1.75; color: var(--ind-ink); overflow-wrap: anywhere; }
.in-profile dd a { color: var(--ind-blue); font-weight: 700; }
.in-profile .in-map-link { display: flex; align-items: center; gap: 6px; width: fit-content; margin-top: 4px; font-size: .85rem; text-decoration: none; }
.in-profile .in-map-link:hover { color: var(--ind-navy); text-decoration: underline; }

/* --- Vision and mission -------------------------------------------------- */
.in-value { padding: 32px 34px 36px; border-top: 4px solid var(--ind-blue); }
.in-value h3 {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
  font-size: 1rem;
  letter-spacing: .08em;
  color: var(--ind-accent);
}
.in-value h3 .ind-icon { margin: 0; }
.in-page .in-value p { font-size: 1.14rem; font-weight: 700; line-height: 1.9; color: var(--ind-ink); }

/* --- Articles ------------------------------------------------------------ */
/* Three across on six grid columns. A last row of one or two cards would
   leave a gap, so those cards share the row between them and lay out
   sideways (image left, text right). Two across on tablets, where a lone
   last card takes the row the same way; one on phones. */
.in-articles { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 24px; }
.in-articles > li { grid-column: span 2; }

@media (min-width: 992px) {
  .in-articles > li:last-child:nth-child(3n+1) { grid-column: 1 / -1; }
  .in-articles > li:nth-last-child(2):nth-child(3n+1),
  .in-articles > li:last-child:nth-child(3n+2) { grid-column: span 3; }
  .in-articles > li:last-child:nth-child(3n+1) .hp-article,
  .in-articles > li:nth-last-child(2):nth-child(3n+1) .hp-article,
  .in-articles > li:last-child:nth-child(3n+2) .hp-article { flex-direction: row; }
  .in-articles > li:last-child:nth-child(3n+1) .hp-article img,
  .in-articles > li:nth-last-child(2):nth-child(3n+1) .hp-article img,
  .in-articles > li:last-child:nth-child(3n+2) .hp-article img { width: 44%; flex-shrink: 0; align-self: flex-start; }
  .in-articles > li:last-child:nth-child(3n+1) .hp-article img { width: 38%; }
  .in-articles > li:last-child:nth-child(3n+1) .hp-article-body { justify-content: center; padding: 26px 32px; }
}

.in-empty { color: var(--ind-muted); }

/* --- Pagination ---------------------------------------------------------- */
.in-pagination { margin-top: 40px; }
.in-pagination ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.in-page-num, .in-page-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--ind-line);
  background: #fff;
  font-weight: 700;
  color: var(--ind-navy);
  text-decoration: none;
  transition: border-color .15s ease;
}
a.in-page-num:hover, a.in-page-step:hover { border-color: var(--ind-blue); color: var(--ind-navy); text-decoration: none; }
.in-page-num.is-current { background: var(--ind-navy); border-color: var(--ind-navy); color: #fff; }
.in-page-step.is-disabled { opacity: .45; }
.in-page-gap { display: inline-flex; align-items: center; height: 44px; padding: 0 4px; color: var(--ind-muted); }
.in-page a:focus-visible { outline: 3px solid var(--ind-blue); outline-offset: 3px; }

/* --- Careers and social media -------------------------------------------- */
.in-links > li { display: flex; }
.in-link { width: 100%; }
.in-link h3 { display: flex; align-items: center; gap: 14px; }
.in-link .ind-icon { margin: 0; }

/* --- Responsive ---------------------------------------------------------- */
@media (min-width: 768px) and (max-width: 991.98px) {
  .in-articles > li:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .in-articles > li:last-child:nth-child(odd) .hp-article { flex-direction: row; }
  .in-articles > li:last-child:nth-child(odd) .hp-article img { width: 46%; flex-shrink: 0; align-self: flex-start; }
}
@media (max-width: 991.98px) {
  .in-articles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .in-articles > li { grid-column: auto; }
  .in-offices { grid-template-columns: 1fr; max-width: 820px; margin: 0 auto; }
  .in-page .in-subnav ul { justify-content: flex-start; }
}
@media (max-width: 767.98px) {
  .in-articles { grid-template-columns: 1fr; gap: 16px; }
  .in-office-head { padding: 18px 20px; }
  .in-profile { padding: 4px 20px 14px; }
  .in-profile-row { grid-template-columns: 1fr; gap: 2px; padding: 12px 0; }
  .in-value { padding: 24px 22px 26px; }
  .in-page .in-value p { font-size: 1.04rem; }
  .in-page-step { padding: 0 12px; }
}

/* --- Print --------------------------------------------------------------- */
@media print {
  .in-pagination, .in-map-link { display: none !important; }
  .in-offices { grid-template-columns: 1fr 1fr; }
  .in-office-head { background: none; }
}
