/* =========================================================
   Akiyoshi K.K. — corporate site
   ========================================================= */

:root {
  --navy: #14233a;
  --navy-deep: #0e1828;
  --ink: #1d2026;
  --charcoal: #3a3e45;
  --muted: #6c7079;
  --paper: #fbfaf7;
  --stone: #f1eee8;
  --line: rgba(20, 35, 58, 0.14);
  --line-strong: rgba(20, 35, 58, 0.32);
  --accent: #9b7b4e;
  --accent-soft: rgba(155, 123, 78, 0.14);

  --font-sans: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", "Meiryo", sans-serif;
  --font-serif: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", "YuMincho", serif;
  --font-en: "Cormorant Garamond", "Times New Roman", serif;

  --gutter: clamp(20px, 5vw, 72px);
  --max: 1200px;
  --header-h: 84px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  color-scheme: light;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: var(--header-h);
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 2;
  letter-spacing: 0.04em;
  font-feature-settings: "palt" 0;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

@media (min-width: 768px) {
  body { font-size: 16px; }
}

h1, h2, h3, p, dl, dd, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
address { font-style: normal; }
img, svg { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

::selection { background: var(--navy); color: #fff; }

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

.skip-link {
  position: absolute;
  top: 8px; left: 8px;
  z-index: 100;
  padding: 8px 16px;
  background: var(--navy);
  color: #fff;
  font-size: 13px;
  transform: translateY(-150%);
  transition: transform 0.2s;
}
.skip-link:focus { transform: none; }

.pc-only { display: none; }
@media (min-width: 900px) { .pc-only { display: inline; } }

.container {
  width: 100%;
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  transition: background-color 0.4s var(--ease), box-shadow 0.4s var(--ease), height 0.4s var(--ease);
}
.site-header.is-scrolled {
  --header-h: 68px;
  background: rgba(251, 250, 247, 0.92);
  box-shadow: 0 1px 0 var(--line);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 var(--gutter);
}

.logo {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.logo__mark {
  font-family: var(--font-en);
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 0.34em;
  color: var(--navy);
}
.logo__sub {
  margin-top: 7px;
  font-size: 10px;
  letter-spacing: 0.32em;
  color: var(--muted);
}

.global-nav__list {
  display: flex;
  gap: clamp(28px, 3.4vw, 52px);
}
.global-nav__list a {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 0;
  line-height: 1;
}
.global-nav__list .en {
  font-family: var(--font-en);
  font-size: 17px;
  letter-spacing: 0.12em;
  color: var(--navy);
}
.global-nav__list .ja {
  margin-top: 6px;
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--muted);
}
.global-nav__list a::after {
  content: "";
  position: absolute;
  left: 50%; bottom: -6px;
  width: 0; height: 1px;
  background: var(--accent);
  transition: width 0.35s var(--ease), left 0.35s var(--ease);
}
.global-nav__list a:hover::after,
.global-nav__list a:focus-visible::after { left: 0; width: 100%; }

.menu-toggle { display: none; }

@media (max-width: 860px) {
  :root { --header-h: 68px; }

  .menu-toggle {
    position: relative;
    z-index: 2;
    display: grid;
    place-content: center;
    gap: 7px;
    width: 48px; height: 48px;
    margin-right: -10px;
    padding: 0;
    background: none;
    border: 0;
    cursor: pointer;
  }
  .menu-toggle__bar {
    display: block;
    width: 26px; height: 1px;
    background: var(--navy);
    transition: transform 0.4s var(--ease), background-color 0.4s;
  }
  .menu-open .menu-toggle__bar:nth-child(1) { transform: translateY(4px) rotate(30deg); }
  .menu-open .menu-toggle__bar:nth-child(2) { transform: translateY(-4px) rotate(-30deg); }

  .global-nav {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    padding: 96px var(--gutter) 48px;
    background: var(--paper);
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.4s var(--ease), visibility 0s 0.4s;
  }
  .menu-open .global-nav {
    visibility: visible;
    opacity: 1;
    transition: opacity 0.4s var(--ease), visibility 0s;
  }
  .global-nav__list {
    flex-direction: column;
    gap: 0;
    width: 100%;
  }
  .global-nav__list li { border-bottom: 1px solid var(--line); }
  .global-nav__list a {
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
    padding: 22px 0;
  }
  .global-nav__list .en { font-size: 30px; }
  .global-nav__list .ja { margin: 0; font-size: 12px; }
  .global-nav__list a::after { display: none; }

  .menu-open { overflow: hidden; }
  /* a backdrop-filter would make the header the containing block of the fixed nav */
  .menu-open .site-header {
    background: var(--paper);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 40px) 0 120px;
  overflow: hidden;
  isolation: isolate;
}

.hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px);
  background-size: calc((100% - var(--gutter) * 2) / 6) 100%;
  background-position: var(--gutter) 0;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 30%, #000 70%, transparent);
  mask-image: linear-gradient(to bottom, transparent, #000 30%, #000 70%, transparent);
  opacity: 0.55;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: 48px;
  width: 100%;
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
@media (min-width: 960px) {
  .hero__inner { grid-template-columns: 1.05fr 1fr; gap: 24px; }
}

.hero__eyebrow {
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--font-en);
  font-size: 15px;
  letter-spacing: 0.16em;
  color: var(--accent);
}
.hero__eyebrow::before {
  content: "";
  width: 40px; height: 1px;
  background: currentColor;
}
@media (max-width: 599px) {
  .hero__eyebrow { font-size: 12.5px; letter-spacing: 0.08em; }
  .hero__eyebrow::before { display: none; }
  .hero .hero__scroll { display: none; }
}

.hero__title {
  margin-top: 36px;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(30px, 9vw, 64px);
  line-height: 1.45;
  letter-spacing: 0.1em;
  color: var(--navy);
}
.hero__line {
  display: block;
  overflow: hidden;
  white-space: nowrap;
}
@media (min-width: 960px) {
  .hero__title { font-size: clamp(40px, 4.6vw, 66px); }
}
.hero__line > span { display: inline-block; }
.hero__line:nth-child(2) { padding-left: 1em; }

.hero__lead,
.about__text,
.biz__text,
.contact__text {
  word-break: auto-phrase;
}
.hero__lead {
  margin-top: 40px;
  max-width: 34em;
  font-size: 14px;
  line-height: 2.2;
  color: var(--charcoal);
}
@media (min-width: 768px) { .hero__lead { font-size: 15px; } }

.hero__visual {
  position: relative;
  justify-self: center;
  width: min(100%, 520px);
}
@media (max-width: 959px) {
  .hero__visual { order: -1; width: min(72%, 360px); margin-bottom: -8px; }
}

.frame { width: 100%; height: auto; overflow: visible; }
.frame line {
  fill: none;
  stroke: var(--navy);
  stroke-linecap: square;
  vector-effect: non-scaling-stroke;
}
.frame .g { stroke: var(--line-strong); stroke-width: 0.6; opacity: 0.6; }
.frame .c { stroke-width: 1; }
.frame .b { stroke-width: 0.7; opacity: 0.75; }
.frame .u { stroke: var(--accent); stroke-width: 1.4; }
.frame .slab { fill: var(--navy); opacity: 0.05; }
.frame .unit-fill { fill: var(--accent-soft); }

.hero__wordmark {
  position: absolute;
  right: calc(var(--gutter) * -0.2);
  bottom: 28px;
  z-index: -1;
  font-family: var(--font-en);
  font-size: clamp(64px, 15vw, 220px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.18em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(20, 35, 58, 0.09);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}

.hero__scroll {
  position: absolute;
  left: var(--gutter);
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  font-family: var(--font-en);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--navy);
}
.hero__scroll span { writing-mode: vertical-rl; }
.hero__scroll::after {
  content: "";
  width: 1px; height: 72px;
  background: linear-gradient(to bottom, var(--navy) 50%, var(--line) 50%);
  background-size: 1px 200%;
}

/* hero animation (motion allowed + JS only) */
@media (prefers-reduced-motion: no-preference) {
  .js .hero__line > span {
    transform: translateY(105%);
    animation: rise 1.3s var(--ease) forwards;
  }
  .js .hero__line:nth-child(2) > span { animation-delay: 0.18s; }
  .js .hero__eyebrow,
  .js .hero__lead {
    opacity: 0;
    animation: fade 1.2s var(--ease) forwards;
  }
  .js .hero__eyebrow { animation-delay: 0.1s; }
  .js .hero__lead { animation-delay: 0.7s; }

  .js .frame line {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw 1.4s var(--ease) forwards;
    animation-delay: var(--d, 0s);
  }
  .js .frame .slab,
  .js .frame .unit-fill {
    opacity: 0;
    animation: fade 1.2s var(--ease) 2s forwards;
  }
  .js .frame .slab { animation-name: fade-slab; }

  .hero__scroll::after { animation: scroll-line 2.4s var(--ease) infinite; }
}

@keyframes rise { to { transform: none; } }
@keyframes fade { to { opacity: 1; } }
@keyframes fade-slab { to { opacity: 0.05; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes scroll-line {
  0% { background-position: 0 100%; }
  100% { background-position: 0 -100%; }
}

/* ---------- Sections ---------- */

.section { padding: clamp(96px, 14vw, 180px) 0; }

.section-head__en {
  display: flex;
  align-items: baseline;
  gap: 18px;
  font-family: var(--font-en);
  font-size: clamp(40px, 6vw, 68px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.06em;
  color: var(--navy);
}
.section-head__en .num {
  font-size: 14px;
  letter-spacing: 0.14em;
  color: var(--accent);
  transform: translateY(-0.4em);
}
.section-head__ja {
  margin-top: 20px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--muted);
}

/* ---------- About ---------- */

.about { position: relative; }
.about::before {
  content: "";
  position: absolute;
  top: 0; left: var(--gutter); right: var(--gutter);
  height: 1px;
  background: var(--line);
}

.about__body {
  display: grid;
  gap: 40px;
  margin-top: clamp(56px, 8vw, 96px);
}
@media (min-width: 900px) {
  .about__body { grid-template-columns: 1fr 1.15fr; gap: 80px; }
}

.about__statement {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(24px, 3.2vw, 38px);
  line-height: 1.8;
  letter-spacing: 0.1em;
  color: var(--navy);
}
.about__text p + p { margin-top: 1.6em; }
.about__text { color: var(--charcoal); text-align: justify; }

.about__facts {
  display: grid;
  margin-top: clamp(56px, 8vw, 96px);
  border-top: 1px solid var(--line-strong);
}
@media (min-width: 768px) {
  .about__facts { grid-template-columns: repeat(3, 1fr); }
  .about__facts > div + div { border-left: 1px solid var(--line); }
}
.about__facts > div {
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
@media (min-width: 768px) {
  .about__facts > div { padding: 28px 32px; border-bottom: 0; }
  .about__facts > div:first-child { padding-left: 0; }
}
.about__facts dt {
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--accent);
}
.about__facts dd {
  margin-top: 6px;
  font-family: var(--font-serif);
  font-size: 17px;
  color: var(--navy);
}
.about__facts a { border-bottom: 1px solid var(--line-strong); transition: border-color 0.3s; }
.about__facts a:hover { border-color: var(--accent); }

/* ---------- Business ---------- */

.business { background: var(--stone); }

.biz {
  display: grid;
  gap: 36px;
  margin-top: clamp(56px, 8vw, 104px);
}
@media (min-width: 900px) {
  .biz { grid-template-columns: 1fr 1fr; gap: 96px; align-items: center; }
  .biz--reverse .biz__figure { order: 2; }
}
.biz + .biz { padding-top: clamp(56px, 8vw, 104px); border-top: 1px solid var(--line); }

.biz__figure {
  position: relative;
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  background: var(--paper);
  border: 1px solid var(--line);
}
.biz__figure svg { width: 72%; height: auto; }
.biz__figure .ln {
  fill: none;
  stroke: var(--navy);
  stroke-width: 1.2;
  vector-effect: non-scaling-stroke;
}
.biz__figure .thin { stroke-width: 0.7; opacity: 0.6; }
.biz__figure .dash { stroke-dasharray: 3 5; opacity: 0.5; stroke-width: 0.8; }
.biz__figure .acc { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 1.2; vector-effect: non-scaling-stroke; }

.biz__num {
  font-family: var(--font-en);
  font-size: 15px;
  letter-spacing: 0.16em;
  color: var(--accent);
}
.biz__num span { font-size: 22px; margin-left: 4px; }
.biz__title {
  margin-top: 14px;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.5;
  letter-spacing: 0.12em;
  color: var(--navy);
}
.biz__en {
  margin-top: 6px;
  font-family: var(--font-en);
  font-size: 16px;
  letter-spacing: 0.08em;
  color: var(--muted);
}
.biz__text {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  color: var(--charcoal);
  text-align: justify;
}

/* ---------- Company ---------- */

@media (min-width: 900px) {
  .company__inner { display: grid; grid-template-columns: 1fr 2.2fr; gap: 64px; align-items: start; }
}

.profile {
  width: 100%;
  margin-top: 56px;
  border-collapse: collapse;
  border-top: 1px solid var(--line-strong);
}
@media (min-width: 900px) { .profile { margin-top: 0; } }

.profile th,
.profile td {
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.profile th {
  width: 11em;
  padding-right: 24px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.profile td { color: var(--ink); }
.profile td a[href^="mailto"] { border-bottom: 1px solid var(--line-strong); transition: border-color 0.3s; }
.profile td a[href^="mailto"]:hover { border-color: var(--accent); }

@media (max-width: 599px) {
  .profile th,
  .profile td { display: block; width: auto; padding: 0; border: 0; }
  .profile tr { display: block; padding: 20px 0; border-bottom: 1px solid var(--line); }
  .profile th { margin-bottom: 4px; font-size: 12px; }
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  font-size: 13px;
  color: var(--accent);
}
.text-link::after {
  content: "";
  width: 9px; height: 9px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  transform: rotate(45deg) scale(0.8);
}
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Contact ---------- */

.contact {
  background: var(--navy);
  color: #e9ebef;
}
.section-head--light .section-head__en { color: #fff; }
.section-head--light .section-head__en .num { color: #c9a878; }
.section-head--light .section-head__ja { color: rgba(255, 255, 255, 0.6); }

.contact__body { margin-top: clamp(48px, 7vw, 80px); }
.contact__text { color: rgba(255, 255, 255, 0.8); }

.contact__mail {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 4px 24px;
  margin-top: 48px;
  padding: 36px 0 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.24);
  border-bottom: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
}
.contact__mail-label {
  grid-column: 1 / -1;
  font-family: var(--font-en);
  font-size: 14px;
  letter-spacing: 0.2em;
  color: #c9a878;
}
.contact__mail-address {
  font-family: var(--font-en);
  font-size: clamp(26px, 6.2vw, 64px);
  line-height: 1.2;
  letter-spacing: 0.04em;
  overflow-wrap: anywhere;
}
.contact__mail-arrow {
  position: relative;
  width: clamp(44px, 6vw, 64px);
  height: clamp(44px, 6vw, 64px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  transition: background-color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.contact__mail-arrow::before {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 10px; height: 10px;
  border-top: 1px solid #fff;
  border-right: 1px solid #fff;
  transform: translate(-70%, -50%) rotate(45deg);
}
.contact__mail:hover .contact__mail-arrow,
.contact__mail:focus-visible .contact__mail-arrow { background: #c9a878; border-color: #c9a878; }
.contact__mail-address {
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size 0.5s var(--ease);
}
.contact__mail:hover .contact__mail-address { background-size: 100% 1px; }

.contact__note {
  margin-top: 28px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}
.contact__note a { color: #fff; border-bottom: 1px solid rgba(255, 255, 255, 0.4); }

/* ---------- Footer ---------- */

.site-footer {
  padding: 80px 0 32px;
  background: var(--navy-deep);
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}
.site-footer__inner {
  display: grid;
  gap: 48px;
}
@media (min-width: 768px) {
  .site-footer__inner { grid-template-columns: 1fr auto; align-items: end; }
}
.site-footer__logo {
  font-family: var(--font-en);
  font-size: 28px;
  letter-spacing: 0.34em;
  color: #fff;
  line-height: 1;
}
.site-footer__name {
  margin-top: 20px;
  color: #fff;
}
.site-footer__name span {
  margin-left: 16px;
  font-family: var(--font-en);
  font-size: 15px;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
}
.site-footer__address { margin-top: 8px; line-height: 1.9; }
.site-footer__address a:hover { color: #fff; }

.site-footer__nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 32px;
}
.site-footer__nav a {
  font-family: var(--font-en);
  font-size: 15px;
  letter-spacing: 0.1em;
  transition: color 0.3s;
}
.site-footer__nav a:hover { color: #fff; }

.site-footer__bottom {
  margin-top: 64px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.copyright small {
  font-family: var(--font-en);
  font-size: 13px;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.5);
}

/* ---------- Subpage (privacy / 404) ---------- */

.page {
  padding: calc(var(--header-h) + clamp(64px, 10vw, 120px)) 0 clamp(96px, 12vw, 160px);
}
.page__body {
  max-width: 760px;
  margin-top: clamp(48px, 7vw, 80px);
  color: var(--charcoal);
}
.page__body h2 {
  margin-top: 56px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 20px;
  letter-spacing: 0.1em;
  color: var(--navy);
}
.page__body h2:first-child { margin-top: 0; }
.page__body p,
.page__body ul { margin-top: 16px; }
.page__body ul { padding-left: 1.2em; list-style: disc; }
.page__body a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.page__meta { margin-top: 56px; font-size: 13px; color: var(--muted); }

.button-link {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-top: 40px;
  padding: 16px 32px;
  border: 1px solid var(--navy);
  font-family: var(--font-en);
  letter-spacing: 0.14em;
  color: var(--navy);
  transition: background-color 0.3s, color 0.3s;
}
.button-link:hover { background: var(--navy); color: #fff; }

/* ---------- Reveal on scroll ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js .reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 1.1s var(--ease), transform 1.1s var(--ease);
  }
  .js .reveal.is-visible {
    opacity: 1;
    transform: none;
  }
}
