/* ===================================
   House Kurashiki Header / Drawer
   Final CSS (BG white from start)
=================================== */

/* ===== base ===== */
:root{
  --hk-brand:#1f6fb2;
  --hk-text:#1a1a1a;
  --hk-border: rgba(0,0,0,.12);

  /* initial (kept for compatibility) */
  --hk-initial-text:#fff;

  /* scrolled */
  --hk-scrolled-bg: rgba(255,255,255,.95);
  --hk-scrolled-text:#1a1a1a;

  /* drawer */
  --hk-drawer-bg:#6f7f93;
}

*{ box-sizing:border-box; }
html,body{ margin:0; }
body{ font-family: system-ui, -apple-system, "Noto Sans JP", sans-serif; }

/* ===================================
   Header (always white)
=================================== */
.hk-header{
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  width: 100%;

  /* ALWAYS white */
  background: var(--hk-scrolled-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--hk-scrolled-text);
  box-shadow: 0 10px 24px rgba(0,0,0,.08);

  transition: background-color .28s ease, color .28s ease, box-shadow .28s ease;
}
.hk-header a{ color: inherit; font-weight: 600;}

/* keep class for JS compatibility (no visual change) */
.hk-header.is-scrolled{
  background: var(--hk-scrolled-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--hk-scrolled-text);
  box-shadow: 0 10px 24px rgba(0,0,0,.08);
}

/* ===================================
   PC layout: left logo / right top+nav
=================================== */
.hk-header__pcGrid{
  width: min(1200px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 16px;
  padding: 10px 14px 10px;
  align-items: stretch;
}

.hk-header__brand{ display:flex; align-items:flex-start; }
.hk-header__logo{ height: 45px; width:auto; display:block; }

.hk-header__right{
  display:flex;
  flex-direction: column;
  gap: 10px;
}

/* top row (PC) */
.hk-header__topInner{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap: 14px;
}

.hk-header__tel a{
  font-weight: 800;
  text-decoration:none;
  display:flex;
  align-items: baseline;
  gap: 10px;
  white-space: nowrap;
}
.hk-header__telNum{ font-size: 18px; letter-spacing:.02em; }
.hk-header__hours{ font-size: 12px; opacity:.85; }

.hk-header__topLinks{
  display:flex;
  align-items:center;
  gap: 10px;
  white-space: nowrap;
}

/* pills (always for white header) */
.hk-header__topLink{
  text-decoration:none;
  font-size: 12px;
  line-height: 1;
  padding: .50em .95em;
  border-radius: 999px;
  border: 1px solid var(--hk-border);
}
.hk-header__topLink.is-strong{
  background: rgba(31,111,178,.10);
  border-color: rgba(31,111,178,.25);
}

/* actions (round buttons) */
.hk-header__actions{ display:none; } /* PC hidden */

.hk-roundBtn{
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display:grid;
  place-items:center;
  padding:0;
  text-decoration:none;
  cursor:pointer;

  /* always for white header */
  background: rgba(31,111,178,.10);
  border: 1px solid rgba(31,111,178,.25);
  color: var(--hk-brand);
}

/* burger icon */
.hk-burger span{
  display:block;
  width: 18px;
  height: 2px;
  background: currentColor;
  position: relative;
}
.hk-burger span::before,
.hk-burger span::after{
  content:"";
  position:absolute;
  left:0;
  width: 18px;
  height: 2px;
  background: currentColor;
}
.hk-burger span::before{ top:-6px; }
.hk-burger span::after{ top: 6px; }

/* bottom nav (PC) */
.hk-header__mainInner{
  display:flex;
  justify-content:flex-end;
}

.hk-menu{
  list-style: none;
  padding: 0;
  margin: 0;
  display:flex;
  align-items:center;
  gap: 22px;
}
.hk-menu li{ margin:0; }
.hk-menu a{
  text-decoration:none;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .08em;
}
.hk-menu a:hover{ opacity:.7; }

/* ===================================
   SP layout (hatta8-like, stable)
   1st row: TEL + pills
   2nd row: round buttons (tel/menu)
   (PC nav hidden, drawer used)
=================================== */
@media (max-width: 768px){

  .hk-header__pcGrid{
    grid-template-columns: 1fr;
    gap: 0;
    padding: 10px 12px 12px;
  }

  .hk-header__brand{ display:none; }
  .hk-header__right{ gap: 10px; }

  /* make top area grid */
  .hk-header__topInner{
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    grid-template-areas:
      "tel links"
      "act act";
    gap: 10px 10px;
    align-items: center;
    justify-content: initial;
  }

  .hk-header__tel{ grid-area: tel; min-width: 0; }
  .hk-header__telNum{ font-size: 13px; }
  .hk-header__hours{ display:none !important; }

  .hk-header__topLinks{
    grid-area: links;
    justify-content:flex-end;
    gap: 8px;
  }
  .hk-header__topLink{
    font-size: 12px;
    padding: .50em .85em;
  }

  .hk-header__actions{
    grid-area: act;
    display:flex;
    gap: 10px;
    justify-content:flex-start;
  }

  /* hide PC nav on SP */
  .hk-header__main{ display:none; }
  .hk-header__nav{ display:none !important; }
}

/* ===================================
   Drawer (full overlay like hatta8)
=================================== */
.drawer{
  position: fixed;
  inset: 0;
  z-index: 1200;
  display:none;
}
.drawer.is-open{ display:block; }

.drawer__scrim{
  position:absolute;
  inset:0;
  background: rgba(0,0,0,0); /* panel is full, keep for click-to-close */
}

.drawer__panel{
  position:absolute;
  inset:0;
  width: 100%;
  height: 100%;
  background: var(--hk-drawer-bg);
  color:#fff;
  padding: 18px 18px 28px;
  overflow:auto;
}

/* close button */
.drawer__close{
  position: fixed;
  right: 18px;
  top: 14px;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
}

/* quick links */
.drawer__quick{
  margin-top: 54px;
  display: grid;
  gap: 18px;
  padding-bottom: 14px;
}
.drawer__quickItem{
  display:flex;
  align-items:center;
  gap: 12px;
  color:#fff;
  text-decoration:none;
}
.drawer__icon{
  width: 26px;
  display:inline-grid;
  place-items:center;
  opacity: .95;
  font-size: 18px;
}
.drawer__quickText strong{
  display:block;
  font-size: 18px;
  letter-spacing: .02em;
}
.drawer__quickText small{
  display:block;
  margin-top: 4px;
  font-size: 12px;
  opacity: .9;
}

/* drawer menu */
.drawer-primary{ margin-top: 18px; }

.menu-primary{
  list-style: none;
  padding: 0;
  margin: 0;
}
.menu-primary > li{
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,.18);
}
.menu-primary a{
  color:#fff;
  text-decoration:none;
  font-weight: 700;
  letter-spacing: .06em;
}

/* second level */
.menu-primary li ul{
  margin: 10px 0 0;
  padding: 0 0 0 18px;
  list-style: none;
}
.menu-primary li ul li{
  border: 0;
  padding: 10px 0 0;
}
.menu-primary li ul a{
  font-weight: 600;
  opacity: .95;
  letter-spacing: .02em;
  position: relative;
}
.menu-primary li ul a::before{
  content: "— ";
  position: absolute;
  left: -18px;
  opacity: .9;
}

/* optional CTA button in drawer */
.btn-contact{
  display:inline-block;
  padding:.9em 1.2em;
  border-radius:999px;
  background: var(--hk-brand);
  color:#fff;
  text-decoration:none;
  font-weight:800;
}

/* ===================================
   SP：ロゴ＋ハンバーガーだけ
=================================== */
@media (max-width: 768px){

  /* ヘッダー全体 */
  .hk-header{
    padding: 0;
  }

  /* グリッドを1行2列に */
  .hk-header__pcGrid{
    grid-template-columns: auto 1fr;
    align-items: center;
    padding: 8px 12px;
  }

  /* ロゴは表示（左） */
  .hk-header__brand{
    display: flex !important;
    align-items: center;
  }
  .hk-header__logo{
    height: 32px;
    width: auto;
  }

  /* 右カラムは横並びに */
  .hk-header__right{
    flex-direction: row;
    justify-content: flex-end;
    align-items: center;
    gap: 0;
  }

  /* 不要要素はすべて消す */
  .hk-header__tel,
  .hk-header__topLinks,
  .hk-header__hours{
    display: none !important;
  }

  /* topInnerは使わず、actionsだけ表示 */
  .hk-header__topInner{
    justify-content: flex-end;
    padding: 0;
  }

  /* ハンバーガーだけ表示 */
  .hk-header__actions{
    display: flex !important;
  }

  /* 丸ボタンサイズ */
  .hk-roundBtn{
    width: 44px;
    height: 44px;
  }

  /* SPではPCナビは完全に非表示 */
  .hk-header__main,
  .hk-header__nav{
    display: none !important;
  }
}