/* ==========================================================================
   HIKARI HOUSE Guest Guide — style.css
   カラー・フォント・余白は 04_ビジュアル設計.md に準拠
   ========================================================================== */

:root{
  --bg:            #F5F5F0;
  --bg-card:       #FFFFFF;
  --text-main:     #1A1A2E;
  --text-sub:      #4A4A5E;
  --navy:          #2C3E6B;
  --gold:          #C4A35A;
  --gold-dark:     #A6813E;
  --warn:          #A6241C;
  --warn-dark:     #7E1B15;
  --rule:          #C9C4B4;

  --radius: 8px;
  --header-h: 64px;

  /* asanoha (hemp-leaf) watermark tile — triangular grid, matches the logo/House Guide motif.
     Opacity is baked into the stroke itself (stroke-opacity) so it stays fixed at the
     04_ビジュアル設計.md-specified 8–12% regardless of where the tile is used. */
  --asanoha-pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='69.28' viewBox='0 0 40 69.28'%3E%3Cg fill='none' stroke='%231A1A2E' stroke-width='1.2' stroke-opacity='0.12'%3E%3Cpath d='M0 0H40'/%3E%3Cpath d='M0 34.64H40'/%3E%3Cpath d='M0 0L20 34.64'/%3E%3Cpath d='M40 0L20 34.64'/%3E%3Cpath d='M20 34.64L0 69.28'/%3E%3Cpath d='M20 34.64L40 69.28'/%3E%3C/g%3E%3C/svg%3E");

  --font-serif-ja: 'Noto Serif JP', serif;
  --font-sans-ja:  'Noto Sans JP', sans-serif;
  --font-serif-en: 'Noto Serif', serif;
  --font-sans-en:  'Inter', 'Noto Sans', sans-serif;
  --font-serif-zh: 'Noto Serif SC', serif;
  --font-sans-zh:  'Noto Sans SC', sans-serif;
  --font-serif-ko: 'Noto Serif KR', serif;
  --font-sans-ko:  'Noto Sans KR', sans-serif;

  --font-heading: var(--font-serif-en);
  --font-body: var(--font-sans-en);
}

html[data-lang="ja"]{ --font-heading: var(--font-serif-ja); --font-body: var(--font-sans-ja); }
html[data-lang="en"]{ --font-heading: var(--font-serif-en); --font-body: var(--font-sans-en); }
html[data-lang="zh"]{ --font-heading: var(--font-serif-zh); --font-body: var(--font-sans-zh); }
html[data-lang="ko"]{ --font-heading: var(--font-serif-ko); --font-body: var(--font-sans-ko); }

*{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin: 0;
  background: var(--bg);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  padding-top: var(--header-h);
  padding-bottom: calc(64px + env(safe-area-inset-bottom)); /* space for fixed emergency bar on mobile */
}

h1,h2,h3{ font-family: var(--font-heading); color: var(--text-main); margin: 0 0 .5em; }
h1{ font-size: 24px; font-weight: 700; }
h2{ font-size: 19px; font-weight: 700; }
p{ margin: 0 0 1em; }
a{ color: var(--navy); }
small, .note{ font-size: 13px; color: var(--text-sub); }

/* ---------- Header ---------- */
.site-header{
  position: fixed; top:0; left:0; right:0; z-index: 100;
  background: var(--text-main);
  height: var(--header-h);
}
.site-header::after{
  content:"";
  position:absolute; left:0; right:0; bottom:-3px; height:3px;
  background: linear-gradient(90deg, transparent, var(--gold) 15%, var(--gold) 85%, transparent);
}
.header-inner{
  max-width: 1100px; margin: 0 auto; height: 100%;
  display: flex; align-items: center; gap: 20px; padding: 0 16px;
}
.brand{ display:flex; align-items:center; gap:8px; text-decoration:none; color: var(--gold); flex-shrink:0; }
.brand-mark{ color: var(--gold); display:flex; align-items:center; }
.header-logo{ height: 40px; width: auto; display: block; }

/* brand wordmark (replaces plain-text property name; single-line horizontal lockup) */
.wordmark-header{ height: 24px; width: auto; max-width: 100%; vertical-align: middle; }
.wordmark-hero{ height: 36px; width: auto; max-width: 100%; vertical-align: middle; }
.wordmark-footer{ height: 20px; width: auto; max-width: 100%; vertical-align: middle; }

.main-nav{ display:none; flex:1; gap: 18px; align-items:center; }
.main-nav a{ text-decoration:none; color: var(--bg); font-size: 14px; font-weight: 500; white-space:nowrap; padding-bottom: 3px; }
.main-nav a:hover{ color: var(--gold); }
.main-nav a.nav-emergency{ color: var(--warn); font-weight: 700; }
.main-nav a.active{ box-shadow: 0 2px 0 var(--gold); }
.main-nav a.active:not(.nav-emergency){ color: var(--gold); }

.lang-switch{ display:none; gap:6px; }
.lang-btn{
  border: 1.5px solid var(--text-main);
  background: var(--bg);
  color: var(--text-main);
  font-family: var(--font-body);
  font-weight: 700; font-size: 13px;
  padding: 6px 10px; border-radius: 6px;
  cursor: pointer; min-height: 32px;
}
.lang-btn.active{ background: var(--gold); border-color: var(--gold); color: #fff; }

.hamburger{
  margin-left: auto; width: 40px; height: 40px; border:none; background:none; cursor:pointer;
  display:flex; flex-direction:column; align-items:center; justify-content:center; gap:5px;
}
.hamburger span{ width: 22px; height: 2px; background: var(--gold); display:block; }

.mobile-menu{
  display:none; flex-direction:column; gap: 14px;
  background: var(--bg-card); border-bottom: 1px solid var(--rule);
  padding: 16px;
}
.mobile-menu.open{ display:flex; }
.mobile-nav{ display:flex; flex-direction:column; gap: 14px; }
.mobile-nav a{ text-decoration:none; color: var(--text-main); font-size: 16px; font-weight:500; padding-left: 4px; }
.mobile-nav a.nav-emergency{ color: var(--warn); font-weight: 700; }
.mobile-nav a.active{ box-shadow: inset 3px 0 0 var(--gold); padding-left: 10px; font-weight: 700; }
.mobile-nav a.active:not(.nav-emergency){ color: var(--gold-dark); }
.lang-switch-mobile{ display:flex; gap:8px; }
.lang-switch-mobile .lang-btn{ flex:1; }

@media (min-width: 900px){
  .main-nav{ display:flex; }
  .lang-switch{ display:flex; }
  .hamburger{ display:none; }
  .mobile-menu{ display:none !important; }
  body{ padding-bottom: 0; }
}

/* ---------- Layout / page sections ---------- */
main{ max-width: 900px; margin: 0 auto; padding: 24px 16px 64px; }
.page{ display:none; scroll-margin-top: calc(var(--header-h) + 16px); }
.page.page-active{ display:block; }

.section-block{ margin-bottom: 40px; }
.section-block:last-child{ margin-bottom: 0; }

#checkin-checkout{ scroll-margin-top: calc(var(--header-h) + 16px); }

/* asanoha watermark — beside each page heading, doubling as the section-break line
   under it (04_ビジュアル設計.md 3節・6-1〜6-9で各ページ見出し脇に指定) */
.page h1{ position: relative; padding-bottom: 20px; }
.page h1::after{
  content:"";
  position:absolute; left:0; right:0; bottom:0; height:20px;
  background-image: var(--asanoha-pattern);
  background-repeat: repeat-x;
  background-position: left top;
  border-bottom: 1px solid var(--rule);
}

/* ---------- Cards ---------- */
.card{
  background: var(--bg-card);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 16px;
}
.card h3{ font-size: 16px; margin-bottom: 6px; display:flex; align-items:center; gap:8px; }
.card-icon{ color: var(--gold-dark); flex-shrink:0; }

/* shortcut cards (home) */
.shortcut-grid{ display:grid; grid-template-columns: 1fr; gap: 12px; margin-bottom: 24px; }
@media (min-width: 640px){ .shortcut-grid{ grid-template-columns: repeat(3,1fr); } }
.shortcut-card{
  display:block; text-decoration:none;
  background: var(--bg-card); border: 1.5px solid var(--gold); border-radius: var(--radius);
  padding: 20px 16px; text-align:center; color: var(--text-main);
}
.shortcut-card .shortcut-label{ font-family: var(--font-heading); font-weight:700; font-size: 17px; }

/* category grid (home) */
.category-grid{ display:grid; grid-template-columns: repeat(2,1fr); gap: 12px; }
@media (min-width: 640px){ .category-grid{ grid-template-columns: repeat(3,1fr); } }
.category-card{
  display:flex; flex-direction:column; align-items:center; gap:8px; text-align:center;
  text-decoration:none; color: var(--text-main);
  background: var(--bg-card); border:1px solid var(--rule); border-radius: var(--radius);
  padding: 18px 10px;
}
.category-card svg{ color: var(--gold-dark); }
.category-card span{ font-size: 13px; font-weight:500; }

/* emergency banner (red) */
.warn-banner{
  background: var(--warn); color:#fff; border-radius: var(--radius);
  padding: 16px; display:flex; align-items:center; gap:12px; margin-bottom: 20px;
}
.warn-banner svg{ flex-shrink:0; }
.warn-banner a{ color:#fff; text-decoration: underline; font-weight:700; }
.warn-banner .warn-title{ font-weight:700; margin:0 0 2px; }
.warn-banner p{ margin:0; }

/* amount-emphasis card (key loss fee / penalties) — same visual grammar as emergency */
.amount-card{
  background: var(--warn); color:#fff; border-radius: var(--radius);
  padding: 18px 16px; margin-bottom: 16px;
}
.amount-card .amount-head{ display:flex; align-items:center; gap:8px; font-weight:700; margin-bottom:8px; }
.amount-card p{ margin: 0 0 10px; color:#fff; }
.amount-card .amount-big{
  display:inline-block; font-size: 34px; font-weight:700; line-height:1;
  background: var(--warn-dark); border-radius: 6px; padding: 6px 14px;
}
.amount-card .amount-sub{ font-size: 13px; opacity:.9; }

/* code cards (keybox / smart lock) */
.code-grid{ display:grid; grid-template-columns: 1fr; gap: 12px; margin-bottom: 16px; }
@media (min-width: 640px){ .code-grid{ grid-template-columns: 1fr 1fr; } }
.code-grid.single{ grid-template-columns: 1fr; max-width: 260px; }
.code-card{
  background: var(--bg-card); border: 2px solid var(--gold); border-radius: var(--radius);
  padding: 16px; text-align:center;
}
.code-card .code-label{ font-size: 13px; color: var(--text-sub); margin-bottom:4px; }
.code-card .code-value{ font-size: 28px; font-weight:700; letter-spacing: .05em; color: var(--text-main); }

/* wifi card */
.wifi-card{
  background: var(--bg-card); border: 2px solid var(--gold); border-radius: var(--radius);
  padding: 16px; margin-bottom: 16px;
}
.wifi-row{ display:flex; align-items:center; justify-content:space-between; gap:8px; padding:6px 0; }
.wifi-row + .wifi-row{ border-top: 1px solid var(--rule); }
.wifi-row .wifi-label{ font-size:13px; color: var(--text-sub); }
.wifi-row .wifi-value{ font-weight:700; font-size:16px; }
.copy-btn{
  border:1px solid var(--gold-dark); background:var(--bg); color:var(--text-main);
  border-radius:6px; padding:6px 10px; font-size:12px; cursor:pointer; font-family: var(--font-body);
}
.copy-btn.copied{ background: var(--gold); color:#fff; border-color:var(--gold); }

/* ordered steps */
.step-list{ list-style:none; margin:0 0 16px; padding:0; counter-reset: step; }
.step-list li{
  counter-increment: step; position:relative; padding-left: 40px; margin-bottom: 14px;
}
.step-list li::before{
  content: counter(step);
  position:absolute; left:0; top:0;
  width:28px; height:28px; border-radius:50%;
  background: var(--gold); color:#fff; font-weight:700;
  display:flex; align-items:center; justify-content:center; font-size:14px;
}

/* photo frame (room layout) */
.photo-frame{
  border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 10px; background:#fff; margin-bottom: 16px;
}
.photo-frame img{ display:block; width:100%; height:auto; border-radius: 4px; }
.photo-frame figcaption{ text-align:center; font-size:13px; color:var(--text-sub); margin-top:8px; }

/* brand logo shown on the Home page, above the welcome heading (extracted from the
   property's official House Guide PDF — see dist/assets/hikari-logo.png) */
.home-logo{ display:flex; justify-content:center; margin: 4px 0 12px; }
.home-logo-img{ height: 88px; width:auto; }
@media (min-width: 640px){ .home-logo-img{ height: 112px; } }

/* ---------- Guest photos (Airbnb) ---------- */
.hero-slideshow{
  position: relative;
  width: 100%;
  height: 300px;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 24px;
  background: var(--bg-card);
}
@media (max-width: 480px){ .hero-slideshow{ height: 220px; } }
.hero-slide{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1s ease;
}
.hero-slide.active{ opacity: 1; }
.hero-dots{
  position: absolute;
  left: 0; right: 0; bottom: 12px;
  display: flex; justify-content: center; gap: 8px;
  z-index: 2;
}
.hero-dot{
  width: 9px; height: 9px; border-radius: 50%;
  background: rgba(255,255,255,.5);
  border: 1.5px solid rgba(255,255,255,.85);
  padding: 0; cursor: pointer;
}
.hero-dot.active{ background: var(--gold); border-color: var(--gold); }

.section-photo{
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 16px;
}

.facility-photo{
  width: 100%;
  max-width: 360px;
  height: auto;
  border-radius: 8px;
  margin: 8px auto;
  display: block;
  box-shadow: 0 2px 6px rgba(0,0,0,.1);
}

/* appliance icon badge (04_ビジュアル設計.md 金アクセント準拠) */
.appliance-icon{
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--bg); border: 1.5px solid var(--gold);
  display:flex; align-items:center; justify-content:center;
  color: var(--gold-dark); margin-bottom: 12px;
}

/* area guide list (still used by the check-out fee table) */
.area-list{ list-style:none; margin:0; padding:0; }
.area-list li{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding: 12px 4px; border-bottom: 1px solid var(--rule);
}
.area-list li:last-child{ border-bottom:none; }
.area-name{ display:flex; align-items:center; gap:10px; font-weight:500; }
.area-time{ color: var(--gold-dark); font-weight:700; white-space:nowrap; font-size:13px; }

/* area guide cards (nearby attractions, photo grid) */
.area-grid{
  display:grid; grid-template-columns: repeat(2,1fr); gap: 12px; margin-bottom: 16px;
}
@media (min-width: 900px){ .area-grid{ grid-template-columns: repeat(3,1fr); } }
.area-card{
  background: var(--bg-card); border: 1px solid var(--rule); border-radius: var(--radius);
  overflow: hidden; box-shadow: 0 2px 6px rgba(26,26,46,.08);
  transition: transform .2s, box-shadow .2s;
  cursor: pointer;
}
.area-card:hover{ transform: translateY(-2px); box-shadow: 0 4px 12px rgba(26,26,46,.15); }
.area-card:active{ transform: translateY(0); box-shadow: 0 1px 4px rgba(26,26,46,.12); }
.area-card-body{ padding: 12px; }
.area-card-body .area-name{ display:block; font-weight:700; color: var(--navy); font-size:14px; margin-bottom:4px; }
.area-card-body .area-time{ display:block; color: var(--text-sub); font-weight:500; font-size:12px; white-space:normal; }

/* area card slideshow (4 photos per card, auto-fade — see initAreaSlideshows() in script.js) */
.area-slideshow{
  position: relative;
  width: 100%;
  height: 150px;
  overflow: hidden;
}
.area-slide{
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.8s ease;
}
.area-slide.active{ opacity: 1; }
@media (min-width: 900px){ .area-slideshow{ height: 180px; } }

/* address card (access page) — tappable, opens Google Maps */
.address-card{ cursor: pointer; }

/* access map link button (Google Drive host map, opens in a new tab) */
.map-link-btn{
  display:inline-flex; align-items:center; gap:6px;
  background: var(--navy); color:#fff; text-decoration:none;
  font-weight:700; font-size:14px; padding:10px 16px; border-radius: var(--radius);
  margin-bottom: 4px;
}
.map-link-btn:hover{ background: var(--gold-dark); }

/* airport → property route cards (access page) */
.route-card{
  background: var(--bg-card); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 16px; margin-bottom: 16px;
}
.route-card h3{ font-size: 16px; margin-bottom: 4px; }
.route-line{ font-size: 13px; color: var(--text-sub); font-weight:500; margin: 0 0 10px; }
.route-steps{ margin-bottom: 8px; }
.station-badge{
  display: inline-block;
  background: var(--navy);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 4px;
  vertical-align: middle;
  white-space: nowrap;
}
.route-step{
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 0;
  border-left: 3px solid var(--gold);
  padding-left: 12px;
  margin-left: 8px;
}
.route-arrow{
  color: var(--gold);
  font-weight: 700;
}
.route-transfer{
  font-size: .85rem;
  color: var(--text-sub);
  font-style: italic;
}
.route-time{ margin: 8px 0 0; font-weight:700; color: var(--gold-dark); font-size: 14px; }
.route-note{ margin-top: -4px; }

/* ---------- Access modal (Google Maps / Jorudan World route choice) ---------- */
.access-modal-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,.5); z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
}
.access-modal {
  position: relative;
  background: #fff; border-radius: 14px; padding: 24px;
  max-width: 320px; width: 90%; text-align: center;
  box-shadow: 0 8px 32px rgba(0,0,0,.2);
}
.access-modal h3 { margin: 0 0 16px; color: #2C3E6B; font-size: 1.1rem; }
.access-modal-btn {
  display: block; width: 100%; padding: 14px; margin: 8px 0;
  border: none; border-radius: 10px; font-size: 1rem;
  cursor: pointer; text-decoration: none; color: #fff;
  font-weight: 600; box-sizing: border-box;
}
.access-modal-btn.map { background: #4285F4; }
.access-modal-btn.route { background: #2C3E6B; }
.access-modal-close {
  position: absolute; top: 8px; right: 12px;
  font-size: 1.5rem; background: none; border: none;
  cursor: pointer; color: #999; line-height: 1;
}

/* FAQ */
.faq-search{
  width:100%; padding: 12px 14px; border:1px solid var(--rule); border-radius: var(--radius);
  font-size:15px; font-family: var(--font-body); margin-bottom: 16px; background: var(--bg-card); color:var(--text-main);
}
.faq-item{ border-bottom: 1px solid var(--rule); }
.faq-q{
  width:100%; text-align:left; background:none; border:none; cursor:pointer;
  padding: 14px 28px 14px 0; font-family: var(--font-body); font-weight:700; font-size:15px;
  color: var(--text-main); position:relative;
}
.faq-q::after{
  content:"+"; position:absolute; right:0; top:50%; transform:translateY(-50%);
  font-size:20px; color: var(--gold-dark);
}
.faq-item.open .faq-q::after{ content:"−"; }
.faq-a{ display:none; padding: 0 0 16px; color: var(--text-sub); }
.faq-item.open .faq-a{ display:block; }
.faq-empty{ color: var(--text-sub); padding: 20px 0; text-align:center; }

/* fixed emergency call bar (mobile) */
.emergency-fixed{
  position: fixed; left:0; right:0; bottom:0; z-index: 90;
  background: var(--warn); color:#fff; text-decoration:none;
  display:flex; align-items:center; justify-content:center; gap:8px;
  padding: 14px 16px calc(14px + env(safe-area-inset-bottom)); min-height: 48px; font-weight:700; font-size:15px;
}
@media (min-width: 900px){ .emergency-fixed{ display:none; } }

/* footer */
.site-footer{
  background: var(--text-main); color: var(--bg); padding: 28px 16px;
  position: relative;
}
.site-footer::before{
  content:"";
  position:absolute; top:0; left:0; right:0; height:2px;
  background: linear-gradient(90deg, transparent, var(--gold) 15%, var(--gold) 85%, transparent);
}
.footer-inner{ max-width: 900px; margin:0 auto; display:flex; flex-direction:column; gap:12px; align-items:flex-start; }
.footer-brand{ font-family:'Caveat', cursive; font-size:22px; }
.footer-contact{ display:flex; flex-direction:column; gap:4px; font-size:13px; }
.footer-phone{ color: var(--gold); font-weight:700; text-decoration:none; }
.footer-address{ color: var(--rule); }
.lang-switch-footer{ display:flex; gap:6px; }
.lang-switch-footer .lang-btn{ background:transparent; border-color:var(--rule); color:var(--rule); }
.lang-switch-footer .lang-btn.active{ background: var(--gold); border-color:var(--gold); color:#fff; }

/* noscript fallback */
.noscript-msg{
  max-width: 640px; margin: 80px auto; padding: 16px 20px;
  text-align:center; color: var(--text-main); line-height: 1.9;
}

/* misc */
.mt-related{ margin-top: 32px; padding-top: 16px; border-top:1px solid var(--rule); font-size:13px; }
.mt-related a{ font-weight:700; }
