/* =========================================
   K-Dental Header
   ========================================= */

/* ---------- Reset ---------- */
.kd-header *,
.kd-drawer * {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* =========================================
   Header Bar
   ========================================= */
.kd-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #fff !important;
  color: #282a30 !important;
  text-align: left !important;
  padding: 0 !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.kd-header::after,
.kd-header::before {
  content: none !important;
  display: none !important;
  height: 0 !important;
}

.kd-header {
  border-bottom: none !important;
  margin-bottom: 0 !important;
  line-height: normal;
  overflow: hidden;
}

.kd-header__inner {
  display: flex;
  align-items: center;
  max-width: 100%;
  margin: 0;
  padding: 0 0 0 32px;
  height: 80px;
}

/* ---------- Logo ---------- */
.kd-header__logo a {
  display: block;
  text-decoration: none;
  line-height: 0;
}

.kd-header__logo img {
  height: 50px;
  width: auto;
}

.kd-header__nav {
  margin-left: auto;
}

/* ---------- PC Navigation ---------- */

.kd-header__nav-list {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 0;
  margin: 0;
  padding: 0;
}

.kd-header__nav-item {
  position: relative;
}

.kd-header__nav-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #282a30;
  padding: 8px 28px;
  cursor: pointer;
  transition: color 0.2s;
  min-height: 50px;
}

.kd-header__nav-link:hover {
  color: #3b5db4;
}

.kd-header__nav-icon {
  width: 18px;
  height: 18px;
  fill: #9ba2b3;
  margin-bottom: 2px;
  transition: fill 0.2s;
}

.kd-header__nav-link:hover .kd-header__nav-icon {
  fill: #3b5db4;
}

.kd-header__nav-jp {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.08em;
  font-family: "Zen Old Mincho", serif;
  line-height: 1.3;
}

.kd-header__nav-arrow {
  font-size: 10px;
  margin-left: 4px;
  display: inline-block;
  transition: transform 0.25s;
}

.kd-header__nav-item--has-child:hover .kd-header__nav-arrow {
  transform: rotate(180deg);
}

.kd-header__nav-en {
  font-size: 0.5625rem;
  color: #95B0DB;
  letter-spacing: 0.14em;
  font-family: "Cinzel", serif;
  font-weight: 400;
  margin-top: 8px;
}

/* ---------- Dropdown ---------- */
.kd-header__dropdown {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  width: 54%;
  max-width: 780px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.10);
  padding: 44px 52px;
  display: flex;
  align-items: flex-start;
  gap: 48px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s, visibility 0.25s;
  z-index: 100;
}

.kd-header__nav-item--has-child:hover .kd-header__dropdown,
.kd-header__nav-item--has-child.is-open .kd-header__dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Heading (left column) */
.kd-header__dropdown-heading {
  flex-shrink: 0;
  padding-top: 4px;
}

.kd-header__dropdown-heading-jp {
  display: block;
  font-size: 1.375rem;
  font-weight: 700;
  color: #282a30;
  letter-spacing: 0.06em;
  font-family: "Zen Old Mincho", serif;
  line-height: 1.4;
}

.kd-header__dropdown-heading-en {
  display: block;
  font-size: 0.6875rem;
  color: #8b91a0;
  letter-spacing: 0.12em;
  font-family: "Cinzel", serif;
  font-weight: 400;
  margin-top: 4px;
}

/* Items (right column, 2-col grid) */
.kd-header__dropdown-list {
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px 48px;
  justify-items: start;
}

.kd-header__dropdown-list li a {
  display: block;
  padding: 12px 0;
  color: #282a30;
  text-decoration: none;
  font-size: 0.9375rem;
  font-family: "Zen Old Mincho", serif;
  transition: color 0.2s;
  white-space: nowrap;
  text-align: left;
}

.kd-header__dropdown-list li a::before {
  content: "＞";
  margin-right: 10px;
  color: #8b91a0;
  font-size: 0.8125rem;
}

.kd-header__dropdown-list li a:hover {
  color: #3b5db4;
}

/* ---------- CTA Button (PC) ---------- */
.kd-header__cta {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #3b5db4;
  color: #fff;
  text-decoration: none;
  padding: 0 36px;
  border-radius: 0;
  font-size: 0.9375rem;
  font-weight: 500;
  font-family: "Zen Old Mincho", serif;
  letter-spacing: 0.06em;
  transition: background 0.2s;
  white-space: nowrap;
  height: 80px;
  flex-shrink: 0;
}

.kd-header__cta:hover {
  background: #2e4a96;
  color: #fff;
}

.kd-header__cta-icon {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
}

/* ---------- Hamburger (SP) ---------- */
.kd-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 48px;
  height: 48px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1010;
  position: fixed;
  top: 10px;
  right: 16px;
}

.kd-hamburger__line {
  display: block;
  width: 26px;
  height: 2px;
  background: #282a30;
  border-radius: 1px;
  transition: transform 0.3s, opacity 0.3s;
}

/* Hamburger → X animation */
.kd-hamburger.is-active .kd-hamburger__line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}
.kd-hamburger.is-active .kd-hamburger__line:nth-child(2) {
  opacity: 0;
}
.kd-hamburger.is-active .kd-hamburger__line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* =========================================
   SP Drawer
   ========================================= */
.kd-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  height: 100dvh;
  background: #fff;
  z-index: 1005;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  visibility: hidden;
}

.kd-drawer.is-open {
  transform: translateX(0);
  visibility: visible;
}

.kd-drawer__inner {
  padding: 28px 24px 40px;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

/* Drawer Close */
.kd-drawer__close {
  position: absolute;
  top: 24px;
  right: 20px;
  background: none;
  border: none;
  color: #656c7d;
  cursor: pointer;
  padding: 8px;
}

/* Drawer Logo */
.kd-drawer__logo {
  margin-bottom: 32px;
}

.kd-drawer__logo img {
  height: 48px;
  width: auto;
}

/* Drawer Nav */
.kd-drawer__nav {
  flex: 1;
}

.kd-drawer__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.kd-drawer__item {
  border-bottom: 1px solid #d1d5de;
}

.kd-drawer__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 4px;
  color: #282a30;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 600;
  font-family: "Zen Old Mincho", serif;
  background: none;
  border: none;
  width: 100%;
  cursor: pointer;
  text-align: left;
}

.kd-drawer__home-icon {
  width: 18px;
  height: 18px;
  fill: #8b91a0;
  margin-right: 8px;
}

.kd-drawer__link-jp {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: #282a30;
}

.kd-drawer__link-en {
  display: block;
  font-size: 0.625rem;
  color: #95B0DB;
  letter-spacing: 0.1em;
  font-family: "Cinzel", serif;
  font-weight: 400;
  margin-top: 2px;
}

/* Accordion Icon (+/−) */
.kd-drawer__accordion-icon {
  position: relative;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.kd-drawer__accordion-icon::before,
.kd-drawer__accordion-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  background: #282a30;
  transition: transform 0.3s;
}

.kd-drawer__accordion-icon::before {
  width: 16px;
  height: 2px;
  transform: translate(-50%, -50%);
}

.kd-drawer__accordion-icon::after {
  width: 2px;
  height: 16px;
  transform: translate(-50%, -50%);
}

.kd-drawer__accordion-btn[aria-expanded="true"] .kd-drawer__accordion-icon::after {
  transform: translate(-50%, -50%) rotate(90deg);
  opacity: 0;
}

/* Sub List */
.kd-drawer__sub-list {
  list-style: none;
  margin: 0;
  padding: 0 0 24px 8px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.kd-drawer__sub-list.is-open {
  max-height: 500px;
}

.kd-drawer__sub-list li a {
  display: block;
  padding: 12px 8px;
  color: #282a30;
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 400;
  font-family: "Zen Old Mincho", serif;
  transition: color 0.2s;
}

.kd-drawer__sub-list li a::before {
  content: "＞";
  margin-right: 10px;
  color: #8b91a0;
  font-size: 0.75rem;
}

.kd-drawer__sub-list li a:hover {
  color: #3b5db4;
}

/* Drawer CTA */
.kd-drawer__cta {
  margin-top: auto;
  padding-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.kd-drawer__cta-tel,
.kd-drawer__cta-mail {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  border-radius: 8px;
  padding: 14px 16px;
  transition: opacity 0.2s;
}

.kd-drawer__cta-tel:hover,
.kd-drawer__cta-mail:hover {
  opacity: 0.85;
}

.kd-drawer__cta-tel {
  background: #e07830;
  color: #fff;
  border: 2px solid #e07830;
}

.kd-drawer__cta-mail {
  background: #e07830;
  color: #fff;
  border: 2px solid #e07830;
}

.kd-drawer__cta-label {
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  font-family: "Zen Old Mincho", serif;
}

.kd-drawer__cta-number,
.kd-drawer__cta-contact {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.5rem;
  font-weight: 700;
  font-family: "Zen Old Mincho", serif;
  letter-spacing: 0.04em;
}

.kd-drawer__cta-number svg,
.kd-drawer__cta-contact svg {
  flex-shrink: 0;
}

/* =========================================
   body offset for fixed header
   ========================================= */
body {
  padding-top: 0;
}

/* =========================================
   FV - adjust for fixed header
   ========================================= */

/* =========================================
   Hide MV scroll arrow (green triangle)
   ========================================= */
.mv .scroll,
.mv .scroll-down,
.mv_arrow,
.mv .arrow,
.scrollDown,
.scroll-arrow,
#mv .scroll,
.mv__scroll,
.fv::after,
.fv::before,
.fv .scroll,
.fv .arrow,
.fv .scroll-down,
section.fv > *:not(.txt):not(.medal):not(picture):not(.img) {
  display: none !important;
}

/* Also hide if it's a pseudo-element triangle */
.fv::after {
  content: none !important;
  display: none !important;
}

.fv::before {
  content: none !important;
  display: none !important;
}

/* =========================================
   Responsive
   ========================================= */
@media (max-width: 1200px) {
  .kd-header__nav-link {
    padding: 8px 18px;
  }
  .kd-header__cta {
    padding: 0 24px;
  }
  .kd-header__dropdown {
    width: 64%;
    padding: 36px 40px;
    gap: 36px;
  }
}

@media (max-width: 960px) {
  .kd-header__inner {
    height: 60px;
    padding: 0 0 0 16px;
  }

  body {
    padding-top: 0;
  }

  /* Hide PC nav & CTA */
  .kd-header__nav,
  .kd-header__cta {
    display: none;
  }

  /* Show hamburger */
  .kd-hamburger {
    display: flex;
  }

  .kd-header__logo img {
    height: 44px;
  }
}
