@charset "UTF-8";
/* ====================
  Breakpoints
  960px~ : PC
  600–959px : Tablet
  ~599px : SP
==================== */

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar { width: 15px; }
::-webkit-scrollbar-track { background: #222; }
::-webkit-scrollbar-thumb {
  background-color: #555;
  border-radius: 10px;
  border: 4px solid #222;
}
::-webkit-scrollbar-thumb:hover { background-color: #888; }

/* ---------- Base ---------- */
html, body {
  font-family: var(--font-japanese);
  line-height: 1.6;
  color: var(--font-color-main);
}
html { font-size: 62.5%; scroll-behavior: smooth; }
body { font-size: clamp(14px, 2vw, 18px); }
section { scroll-margin-top: var(--header-h); }
html.no_opening .loader { display: none !important; }

.flex { display: flex; }
.grid { display: grid; }
.flex_ali_c { align-items: center; }

.content {
  position: relative;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 var(--gutter-lg);
}

.textC { text-align: center; }
.textR { text-align: right; }
.textL { text-align: left; }

h2 {
  font-size: clamp(3rem, 4vw, 5rem);
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  flex: 0 0 auto;
  margin: 0;
}

/* ---------- Layer ---------- */
.loader       { z-index: 9999; }
.loader_white { z-index: 20; }
.loader_pink  { z-index: 30; }
.loader_logo  { z-index: 40; }
header.Menu   { z-index: 200; }

/* ---------- Section spacing ---------- */
section#company,
section#contact { margin: var(--gutter-xlg); }

/* ---------- Button ---------- */
.btn {
  display: inline-block;
  border-radius: 50px;
  border: 1px #222 solid;
  padding: var(--gutter-xxs) var(--gutter-lg);
  margin: var(--gutter-xs) 0;
  text-align: center;
  cursor: pointer;
  transition: .2s cubic-bezier(0.45, 0, 0.55, 1);
}

/* ---------- Opening ---------- */
.loader {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
}
.loader_white,
.loader_pink {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.loader_white { background: #fff; }
.loader_pink  { background: pink; top: -100%; }
.loader_logo {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, 50%);
  opacity: 0;
  font-size: clamp(5rem, 7vw, 9rem);
  font-weight: 900;
  color: var(--font-color-w);
}

/* ---------- Header ---------- */
header.Menu {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: var(--header-h);
  background: rgba(255,255,255,0.6);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(0,0,0,.06);
}
.HeaderContainer {
  max-width: 1600px;
  margin: 0 auto;
  padding: 20px var(--gutter-lg);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  white-space: nowrap;
}
.Logo {
  font-weight: 700;
  font-size: clamp(1.6rem, 2vw, 2rem);
  color: var(--font-color-main);
  letter-spacing: .02em;
}
.btn_contact { font-size: 1.4rem; text-align: center; }
.btn, .btn_contact a {
  display: inline-block;
  border-radius: 50px;
  border: 1px #222 solid;
  padding: 5px var(--gutter-md);
  margin: var(--gutter-xs) 0;
  text-align: center;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: .2s cubic-bezier(0.45, 0, 0.55, 1);
}
.btn:focus-visible,
.btn_contact a:focus-visible {
  outline: 3px solid rgba(0,0,0,.3);
  outline-offset: 2px;
}
.btn:hover,
.btn_contact a:hover {
  background: #222;
  color: #fff;
}

/* ---------- Philosophy (Apple風の基礎) ---------- */
#philosophy { 
  position: relative; 
  margin-top: var(--gutter-philosophy);
  overflow: clip;                 /* マスク用にオーバーフローを隠す */
}
#philosophy h1 {
  font-size: clamp(5rem, 7vw, 9rem);
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: clamp(12px, 2vw, 20px);
}
#philosophy .philosophy_copy {
  font-weight: 500;
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  margin-bottom: var(--gutter-md);
  line-height: 1.9;
}

/* 行マスク用のラッパ */
.ph-line, .ph-copy-line { display: block; overflow: hidden; }
.ph-mask { 
  display: inline-block; 
  will-change: transform, opacity, filter; 
  backface-visibility: hidden; 
  transform: translateZ(0);
}

/* Opening 中は見せない（チラつき防止） */
html:not(.opening-done) #philosophy .content,
html:not(.opening-done) .philosophy_img {
  opacity: 0;
  visibility: hidden;
}

/* Opening 後は通常表示 */
html.opening-done #philosophy .content,
html.opening-done .philosophy_img {
  opacity: 1;
  visibility: visible;
}

/* 画像パネル（既存） */
.philosophy_img {
  position: relative;
  overflow: hidden;
  height: min(60vh, 700px);
}
.philosophy_img img {
  width: 100%;
  height: 120%;
  object-fit: cover;
  display: block;
  will-change: transform;
}

/* ---------- Company ---------- */
#company dl{
  display: grid;
  grid-template-columns: 20ch 1fr;
  column-gap: 0;
  row-gap: 0;
  border-top: 1px solid rgba(var(--border-color-main), .15);
  flex: 1 1 0;
  min-width: 0;
}
#company dt,
#company dd{
  padding: 2rem 1rem;
  border-bottom: 1px solid rgba(var(--border-color-main), .15);
}

/* ---------- Shared layout (company / contact) ---------- */
#company .content,
#contact .content{
  display: flex;
  align-items: flex-start;
  column-gap: clamp(2rem, 6vw, 8rem);
}
#company h2,
#contact h2{
  flex: 0 0 var(--left-col-w);
  white-space: nowrap;
  margin: 0;
}
#company .content > dl,
#contact .content > form{
  flex: 1 1 0;
  min-width: 0;
  max-width: var(--right-col-max);
}

/* ---------- Contact (table) ---------- */
#contact .table_form { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 0; }
#contact .table_form th {
  text-align: left;
  font-weight: 700;
  padding: 12px 16px;
  background: rgba(0,0,0,.04);
  border-top: 1px solid rgba(var(--border-color-main), .12);
  border-bottom: 1px solid rgba(var(--border-color-main), .12);
}
#contact .table_form td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(var(--border-color-main), .12);
  vertical-align: top;
  word-break: break-word;
}
#contact .table_form tr:last-child td { border-bottom: none; }

/* inputs */
#contact input[type="text"],
#contact input[type="email"],
#contact input[type="tel"],
#contact input[type="url"],
#contact textarea {
  appearance: none;
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid rgba(var(--border-color-main), .25);
  border-radius: 8px;
  background: #fff;
  font: inherit;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
#contact textarea { min-height: 140px; resize: vertical; }
#contact input:focus-visible,
#contact textarea:focus-visible {
  border-color: rgba(var(--border-color-main), .6);
  box-shadow: 0 0 0 3px rgba(0,0,0,.06);
}

/* 2-col name fields */
#contact .form-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* iframe (policy) */
#contact .table_form iframe {
  border: 1px solid rgba(var(--border-color-main), .15);
  border-radius: 8px;
}

/* agree / submit */
#contact .agree, #contact .submit-cell { text-align: center; }
#contact input[type="checkbox"]{
  appearance: auto; -webkit-appearance: auto;
  width: 1.1em; height: 1.1em;
  vertical-align: -2px; margin-right: .5em;
  accent-color: #333;
}
#contact .agree label{ display: inline-flex; align-items: center; gap: .5em; cursor: pointer; }

/* table columns */
#contact .table_form th:first-child,
#contact .table_form td:first-child {
  width: var(--contact-label-col);
  white-space: nowrap;
  vertical-align: top;
}
#contact .table_form th:last-child,
#contact .table_form td:last-child { width: auto; }

::placeholder{ opacity: .7; }

/* required highlight */
.requiredIpt,
#contact input:required,
#contact textarea:required { background: rgba(255, 0, 0, .06); }
.requiredIpt,
#contact input:required:focus,
#contact textarea:required:focus { border-color: rgba(255, 0, 0, .45); }

/* ---------- Footer ---------- */
footer { background: var(--bg-color-footer); }
.footer_link_block { display: flex; align-items: flex-start; gap: 5rem; }
.footer_company_name { margin-left: auto; }
.footer_copyright {
  border-top: 1px solid rgb(var(--border-color-main), 0.2);
  padding: var(--gutter-sm) 0;
  margin-top: var(--gutter-md);
}

/* ---------- A11y / Misc ---------- */
html.menu-open, body.menu-open { overflow: hidden; touch-action: none; }
.MenuWrap :focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
html.reduce-motion .scroll-indicator { display: none; }

/* ============================================
  SP (<= 1000px)
============================================ */
@media (max-width: 1000px) {
  /* Header */
  header.Menu { height: var(--header-h_sp); }
  .HeaderContainer { justify-content: center; padding: 6px var(--gutter-sm); }
  .Logo { margin: 0; text-align: center; font-size: clamp(1.4rem, 5vw, 1.6rem); }

  /* Global paddings */
  .content { padding-left: 12px; padding-right: 12px; }
  section { scroll-margin-top: var(--header-h_sp); }

  /* Visual */
  .philosophy_img { height: 40vh; }

  /* Company */
  #company dl { grid-template-columns: 1fr; }
  #company dt { border-bottom: none; padding: 1rem 0 0.2rem; }
  #company dd { padding: 0 0 1rem; border-bottom: 1px solid rgba(var(--border-color-main), .15); }

  /* Shared layout → stack */
  #company .content, #contact .content { flex-direction: column; gap: 1.2rem; }
  #company h2, #contact h2 { flex: 0 0 auto; white-space: normal; }
  #company .content > dl, #contact .content > form { max-width: none; width: 100%; }

  /* Section margin tighten */
  section#company, section#contact { margin-inline: 0; margin-block: var(--gutter-lg); }

  /* Contact table: vertical layout */
  #contact .table_form { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: auto; }
  #contact .table_form col { width: auto !important; }

  #contact .table_form tr {
    display: block;
    position: relative;
    padding: 12px 0;
  }
  #contact .table_form th,
  #contact .table_form td {
    display: block;
    width: 100%;
    box-sizing: border-box;
    border-bottom: none;
    padding: 0;
  }

  /* Left label → top */
  #contact .table_form th:first-child,
  #contact .table_form td:first-child {
    font-weight: 700;
    opacity: .9;
    margin-bottom: 6px;
    background: none;
    white-space: normal;
  }

  /* Row divider */
  #contact .table_form tr::after {
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 1px;
    background: rgba(var(--border-color-main), .12);
  }
  #contact .table_form tr:last-child::after { display: none; }

  /* Section headers (colspan=2) unify */
  #contact .table_form th[colspan="2"]{
    display: block;
    width: 100%;
    padding: 8px 12px;
    background: rgba(0,0,0,.04);
    border-top: 1px solid rgba(var(--border-color-main), .12);
    border-bottom: 1px solid rgba(var(--border-color-main), .12);
    margin: 0;
    font-weight: 700;
  }
  #contact .table_form tr:has(> th[colspan="2"]) { padding: 6px 0 8px; }
  #contact .table_form tr:has(> th[colspan="2"])::after { display: none; }

  /* Tighten first row after each header */
  #contact .table_form tr:has(> th[colspan="2"]) + tr { padding-top: 8px; }

  /* Inner paddings */
  #contact .table_form th,
  #contact .table_form td { padding-left: 12px; padding-right: 12px; }

  /* Philosophy：SPはアニメ無効（常時表示） */
 /* #philosophy h1 .ph-mask,
  #philosophy .philosophy_copy {
    transform: none !important;
    opacity: 1 !important;
    filter: none !important;
  }*/
}
