/* INDIRECT SHINE — company landing page */

:root {
  --ink: #0e0e12;
  --paper: #e6e6ec;
  --muted: #a3a3b0;
  --faint: #8b8b98;
  --line: rgba(230, 230, 236, 0.14);
  --line-strong: rgba(230, 230, 236, 0.32);
  --light: #f4f1ea;
  --gutter: clamp(20px, 5.5vw, 88px);
  /* Latin faces first; Hangul falls through to the platform Korean font */
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Apple SD Gothic Neo",
    "Noto Sans KR", "Malgun Gothic", sans-serif;
  --word-break: keep-all;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
  background: var(--ink);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  overflow-x: clip;
}

/* Indirect light falling in from beyond the top-right corner */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 60% at 92% -8%, rgba(244, 241, 234, 0.11), transparent 70%),
    radial-gradient(ellipse 50% 40% at 100% 30%, rgba(230, 230, 236, 0.04), transparent 70%);
}

p,
h1,
h2 {
  margin: 0;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 6px;
  border-radius: 2px;
}

::selection {
  background: var(--paper);
  color: var(--ink);
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 10;
  padding: 10px 16px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 16px;
}

/* Layout */

.page {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100svh;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 var(--gutter);
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  padding-right: max(var(--gutter), env(safe-area-inset-right));
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Header */

.site-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: clamp(20px, 3vw, 36px) 0;
}

.brand {
  display: block;
  line-height: 0;
}

.brand img {
  display: block;
  width: auto;
  height: clamp(26px, 2.6vw, 34px);
}

.header-link {
  position: relative;
  padding: 10px 0;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
  text-decoration: none;
  transition: color 0.2s ease;
}

.header-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.header-link:hover {
  color: var(--paper);
}

.header-link:hover::after {
  transform: scaleX(1);
}

/* Hero */

.hero {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 5vw, 80px);
  padding: clamp(24px, 4vh, 72px) 0;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--line-strong);
}

h1 {
  margin-top: clamp(20px, 2.6vw, 32px);
  font-size: clamp(min(2.125rem, 8vw), 4.4vw, 4rem);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -0.035em;
  word-break: var(--word-break);
}

h1 .line {
  display: block;
  text-wrap: balance;
}

.lead {
  max-width: 34em;
  margin-top: clamp(20px, 2.4vw, 32px);
  font-size: clamp(1rem, 1.25vw, 1.125rem);
  line-height: 1.8;
  color: var(--muted);
  word-break: var(--word-break);
}


/* Logo symbol with soft light */

.hero-mark {
  position: relative;
  justify-self: end;
  pointer-events: none;
  width: min(100%, 400px);
  aspect-ratio: 270 / 312;
}

.hero-mark svg {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.mark-fill path {
  stroke: rgba(230, 230, 236, 0.4);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.glow {
  position: absolute;
  inset: -30%;
  background: radial-gradient(closest-side, rgba(244, 241, 234, 0.15), rgba(244, 241, 234, 0.05) 55%, transparent);
  transform: translate(16%, -14%);
  animation: breathe 9s ease-in-out infinite;
}

@keyframes breathe {
  0%, 100% { opacity: 0.65; }
  50% { opacity: 1; }
}

/* Contact */

.contact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 24px 48px;
  padding: clamp(28px, 4vw, 48px) 0;
  border-top: 1px solid var(--line);
}

.contact-text p {
  margin-top: 14px;
  color: var(--muted);
  word-break: var(--word-break);
}

.email {
  display: inline-flex;
  align-items: center;
  gap: clamp(14px, 1.6vw, 24px);
  padding: 6px 0 10px;
  border-bottom: 1px solid var(--line-strong);
  font-size: clamp(1.125rem, 1.8vw, 1.5rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  text-decoration: none;
  transition: border-color 0.25s ease;
}

.email-address {
  overflow-wrap: anywhere;
}

.email-arrow {
  flex: none;
  width: 0.9em;
  height: 0.9em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.25s ease;
}

.email:hover {
  border-color: var(--paper);
}

.email:hover .email-arrow {
  transform: translate(3px, -3px);
}

/* Footer */

.site-footer {
  padding: 24px 0 max(32px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  color: var(--faint);
}

/* Tablet */

@media (max-width: 960px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.7fr);
  }

  .contact {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .email {
    justify-self: start;
  }
}

/* Mobile */

@media (max-width: 640px) {
  .hero {
    position: relative;
    display: block;
    padding: 56px 0 64px;
  }

  .hero-copy {
    position: relative;
    z-index: 1;
  }

  .hero-mark {
    position: absolute;
    top: 16px;
    right: -30%;
    width: 70%;
    max-width: 300px;
    opacity: 0.35;
  }

  .eyebrow {
    font-size: 0.6875rem;
  }

  .lead {
    font-size: 1rem;
  }

  .email {
    font-size: 1.125rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* 404 */

.hero--single {
  grid-template-columns: minmax(0, 1fr);
}

.text-link {
  color: var(--paper);
  text-underline-offset: 0.3em;
  text-decoration-thickness: 1px;
}

/* Header navigation */

.header-actions,
.header-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.4vw, 32px);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Hero fills the first screen now that content continues below */

.hero {
  min-height: min(760px, calc(100svh - 140px));
}

/* HARMA */

.work {
  scroll-margin-top: 24px;
  padding: clamp(48px, 7vw, 104px) 0 clamp(56px, 7vw, 104px);
  border-top: 1px solid var(--line);
}

.work-visual {
  position: relative;
  margin-top: clamp(24px, 3vw, 40px);
  overflow: hidden;
  background: #15141c;
  aspect-ratio: 16 / 9;
}

.work-art {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  image-rendering: pixelated;
}

.work-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(14, 14, 18, 0.45) 0%, transparent 22%);
  pointer-events: none;
}

/* Placement follows the official key visual: left sky, about a third down */
.work-logo {
  position: absolute;
  z-index: 1;
  top: 33%;
  left: 6.5%;
  width: 32.5%;
  line-height: 0;
}

.work-logo img {
  display: block;
  width: 100%;
  height: auto;
  image-rendering: pixelated;
  filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.55));
}

.work-body {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 96px);
  margin-top: clamp(32px, 4vw, 56px);
}

.work-intro p {
  max-width: 36em;
  color: var(--muted);
  line-height: 1.8;
  word-break: var(--word-break);
}

.work-intro p + p {
  margin-top: 14px;
}

.work-intro .work-lead {
  color: var(--paper);
  font-size: clamp(1.125rem, 1.7vw, 1.375rem);
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: -0.015em;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.button:hover {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
}

.work-facts {
  margin: 0;
  border-top: 1px solid var(--line);
}

.work-facts div {
  display: grid;
  grid-template-columns: 5.5em minmax(0, 1fr);
  gap: 16px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.9375rem;
}

.work-facts dt {
  color: var(--faint);
}

.work-facts dd {
  margin: 0;
  word-break: var(--word-break);
}

@media (max-width: 960px) {
  .work-body {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .hero {
    min-height: 0;
  }

  .header-nav {
    gap: 16px;
  }

  .work-visual {
    margin-left: calc(var(--gutter) * -1);
    margin-right: calc(var(--gutter) * -1);
  }

  .work-logo {
    top: 30%;
    left: 5.5%;
    width: 38%;
  }
}

/* Tablet: shorter first screen, larger heading */

@media (min-width: 641px) and (max-width: 960px) {
  .hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: min(600px, calc(100svh - 140px));
  }

  .hero-copy {
    position: relative;
    z-index: 1;
  }

  .hero-mark {
    position: absolute;
    top: 50%;
    right: -6%;
    width: 44%;
    transform: translateY(-50%);
    opacity: 0.5;
  }

  h1 {
    font-size: 6vw;
  }
}

/* Windows high-contrast themes: keep the light logo on its dark plate */

@media (forced-colors: active) {
  .brand {
    forced-color-adjust: none;
    padding: 6px 8px;
    background: #0e0e12;
  }
}

/* Per-language fonts and line breaking (CJK glyph forms differ by language) */

:lang(ja) {
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Yu Gothic", Meiryo, "Noto Sans JP", sans-serif;
  --word-break: normal;
  line-break: strict;
}

:lang(zh-Hans) {
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --word-break: normal;
}

:lang(zh-Hant) {
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang TC",
    "Microsoft JhengHei UI", "Microsoft JhengHei", "Noto Sans TC", sans-serif;
  --word-break: normal;
}

[lang] {
  font-family: var(--font);
}

/* Language menu (details/summary, no script) */

.lang-menu {
  position: relative;
}

.lang-menu summary {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
  list-style: none;
  cursor: pointer;
  transition: color 0.2s ease;
}

.lang-menu summary::-webkit-details-marker {
  display: none;
}

.lang-menu summary:hover,
.lang-menu[open] summary {
  color: var(--paper);
}

.lang-menu summary svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

.lang-list {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 5;
  min-width: 160px;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: #17171e;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}

.lang-list a {
  position: relative;
  display: block;
  padding: 10px 12px 10px 26px;
  border-radius: 4px;
  font-size: 0.9375rem;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
}

.lang-list a:hover {
  background: rgba(230, 230, 236, 0.08);
  color: var(--paper);
}

.lang-list a[aria-current="page"] {
  color: var(--paper);
  font-weight: 600;
}

.lang-list a[aria-current="page"]::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 12px;
  width: 5px;
  height: 5px;
  margin-top: -2.5px;
  border-radius: 50%;
  background: currentColor;
  forced-color-adjust: none;
}

.nf-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

@media (max-width: 640px) {
  .site-header {
    gap: 12px;
  }

  .header-actions,
  .header-nav {
    gap: 14px;
  }
}

@media (max-width: 400px) {
  .lang-code {
    display: none;
  }
}

/* CJK headings: full-width glyphs need a smaller scale and phrase-aware breaks */

:lang(ja) h1,
:lang(zh) h1 {
  font-size: clamp(min(1.875rem, 8vw), 3.6vw, 3.25rem);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

/* Phrase-aware breaks only on short display lines; long katakana compounds in body text
   would otherwise become unbreakable and overflow narrow screens. */
:lang(ja) h1 {
  word-break: auto-phrase;
}

:lang(ja) .work-facts div {
  grid-template-columns: 8.5em minmax(0, 1fr);
}

@media (min-width: 641px) and (max-width: 960px) {
  :lang(ja) h1,
  :lang(zh) h1 {
    font-size: 4.8vw;
  }
}

@media (max-width: 360px) {
  .brand img {
    height: 22px;
  }

  .site-header {
    gap: 8px;
  }

  .header-actions,
  .header-nav {
    gap: 10px;
  }
}

/* HARMA external links */

.work-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button .icon-brand {
  width: 16px;
  height: 16px;
  fill: currentColor;
  stroke: none;
}

/* Final review polish */

.work-intro p,
.contact-text p {
  text-wrap: pretty;
}

.work-facts dd span[lang] {
  white-space: nowrap;
}

.hero--single {
  min-height: 0;
}

@media (max-width: 640px) {
  .work-links .button {
    flex: 1 1 auto;
    justify-content: center;
  }
}

@media (max-width: 300px) {
  .header-link[href^="#"] {
    display: none;
  }

  .email {
    font-size: 1rem;
  }
}
