/* Critical CSS (above-the-fold) */
:root {
  --color-bg-surface: #ffffff;
  --color-bg-muted: #f5f6f8;
}

.ec-layoutRole {
  max-width: 100%;
  overflow-x: hidden;
}

.ec-layoutRole__contents,
.ec-layoutRole__main,
.ec-layoutRole__mainWithColumn,
.ec-layoutRole__mainBetweenColumn {
  max-width: 100%;
}

.ec-role {
  padding-left: 10px;
  padding-right: 10px;
}

.ec-layoutRole__header {
  position: static;
  background: var(--color-bg-surface);
  border-bottom: none;
}

.delivery-free-bar,
.delivery-free-bar__inner,
.delivery-free-bar__inner span,
.delivery-free-bar__inner strong,
.delivery-free-bar i {
  color: #fff;
}

.ec-layoutRole__header .ec-headerNaviRole {
  background: var(--color-bg-surface);
  border: 0;
  border-radius: 0;
  box-shadow: none;
  margin: 0 auto;
  padding: 8px 10%;
}

@media (min-width: 768px) {
  .ec-layoutRole__header {
    overflow: visible;
  }

  .ec-layoutRole__header .ec-headerNaviRole {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 130;
    width: 100vw;
    max-width: 100vw;
    background: var(--color-bg-surface);
    overflow: visible;
  }

  body:has(.ec-debugModeAlert) .ec-layoutRole__header .ec-headerNaviRole {
    top: 50px;
  }

  .ec-layoutRole__header .ec-headerRole {
    margin-top: 56px;
  }
}

.hero-slider-fullwidth {
  width: 100vw;
  max-width: 100vw;
  position: relative;
  left: 0;
  box-sizing: border-box;
}

@media (min-width: 768px) and (max-width: 1149px) {
  body.front_page .ec-layoutRole__mainWithColumn .hero-slider-fullwidth {
    margin-left: calc(-100vw + 100%);
    margin-right: calc(-100vw + 100%);
  }

  body.front_page .ec-layoutRole__mainBetweenColumn .hero-slider-fullwidth {
    margin-left: calc(25vw - 100vw + 100%);
    margin-right: calc(25vw - 100vw + 100%);
  }

  body.front_page .ec-layoutRole__main .hero-slider-fullwidth {
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
  }
}

@media (min-width: 1150px) {
  body.front_page .ec-layoutRole__mainWithColumn .hero-slider-fullwidth,
  body.front_page .ec-layoutRole__mainBetweenColumn .hero-slider-fullwidth {
    margin-left: calc((1150px - 100vw) / 2 - 1150px * 0.25);
    margin-right: calc((1150px - 100vw) / 2 - 1150px * 0.25);
  }

  body.front_page .ec-layoutRole__main .hero-slider-fullwidth {
    margin-left: calc((1150px - 100vw) / 2);
    margin-right: calc((1150px - 100vw) / 2);
  }
}

.hero-slider-fullwidth .ec-sliderRole.hero-slider {
  width: 100vw;
  max-width: 100vw;
  padding-left: 40px;
  padding-right: 40px;
  box-sizing: border-box;
}

.ec-sliderRole.hero-slider {
  position: relative;
  overflow: hidden;
  padding-bottom: 48px;
}

.ec-sliderRole.hero-slider .hero-slider__track {
  visibility: hidden;
}

.ec-sliderRole.hero-slider .hero-slider__track.slick-initialized {
  visibility: visible;
}

.ec-sliderRole.hero-slider .hero-slider__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ec-sliderRole.hero-slider .hero-slider__link {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--color-bg-muted, #f5f6f8);
  border-radius: 16px;
}

@media (min-width: 1600px) {
  .hero-slider-fullwidth {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
  }

  .hero-slider-fullwidth .ec-sliderRole.hero-slider {
    width: 100vw;
    max-width: 100vw;
    padding-left: 24px;
    padding-right: 24px;
  }

  .ec-sliderRole.hero-slider .hero-slider__link {
    max-height: 200px;
  }
}

.category-modern {
  margin: 32px 0 40px;
  padding: 36px 20px;
  border-radius: 24px;
}

.category-modern__header {
  text-align: center;
  margin-bottom: 32px;
}

.category-modern__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 680px;
  margin: 0 auto;
}

.coupon-band-wrap {
  margin: 32px 0;
  padding: 0 16px;
  box-sizing: border-box;
}

.coupon-band {
  background: linear-gradient(135deg, #b99874 0%, #c8a87e 50%, #b99874 100%);
  border-radius: 20px;
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  max-width: 960px;
  margin: 0 auto;
}

@media (max-width: 767px) {
  .hero-slider-fullwidth .ec-sliderRole.hero-slider {
    padding-top: 8px;
    padding-left: 8px;
    padding-right: 8px;
  }

  .ec-sliderRole.hero-slider {
    overflow: visible;
    padding-bottom: 18px;
  }

  .category-modern {
    margin: 24px 0 32px;
    padding: 24px 0;
  }

  .category-modern__grid {
    display: none;
  }

  .coupon-band-wrap {
    display: none;
  }
}

/* SP クイックナビ（ロゴ直下）— site-custom.css 非同期読込前も表示する */
.top-icon-nav {
  display: flex;
  justify-content: space-around;
  align-items: flex-start;
  gap: 4px;
  width: 100%;
  margin: 12px 0 8px;
  padding: 0 4px;
  box-sizing: border-box;
}

.top-icon-nav__item {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  max-width: 72px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 4px 2px;
  color: #8b6f47;
  text-decoration: none;
}

.top-icon-nav__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.top-icon-nav__icon svg {
  display: block;
  width: 32px;
  height: 32px;
}

.top-icon-nav__label {
  display: block;
  font-size: 10px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.02em;
  text-align: center;
  word-break: keep-all;
}

.top-icon-nav__badge {
  position: absolute;
  top: 0;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #b99874;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

@media (min-width: 768px) {
  .top-icon-nav {
    display: none !important;
  }

  /* トップページでもヘッダー右ナビ（会員登録・ログイン・カート）を表示 */
  body.front_page .ec-headerNaviRole__right {
    display: flex;
  }
}

/* ========================================
 * CTA ボタン（site-custom.css 遅延読込前の FOUC 防止）
 * style.min.css のグレー等デフォルトが一瞬出ないようにする
 * ======================================== */
:root {
  --color-brand-dark: #8b6f47;
  --color-brand-deeper: #6f5538;
  --cta-height: 48px;
  --cta-radius: 10px;
  --cta-font-size: 15px;
  --cta-font-weight: 700;
  --cta-primary-bg: var(--color-brand-dark);
  --cta-primary-bg-hover: var(--color-brand-deeper);
  --cta-primary-color: #ffffff;
  --cta-secondary-bg: #ffffff;
  --cta-secondary-color: #475569;
  --cta-secondary-border: #cbd5e1;
}

.ec-blockBtn,
.ec-blockBtn--action,
.ec-blockBtn--cancel,
.ec-blockBtn--primary,
.ec-blockBtn--top {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--cta-radius) !important;
  box-sizing: border-box;
  height: auto;
  line-height: 1.4;
  padding-top: 0;
  padding-bottom: 0;
}

.ec-blockBtn .fa-fw,
.ec-blockBtn--action .fa-fw,
.ec-blockBtn--cancel .fa-fw,
.ec-blockBtn--primary .fa-fw,
.ec-blockBtn--top .fa-fw {
  flex-shrink: 0;
}

.ec-blockBtn--action,
.ec-inlineBtn--action,
.ec-cartRole__checkoutBtn,
.ec-totalBox__btn .ec-blockBtn--action,
.ec-RegisterRole__actions .ec-blockBtn--action {
  min-height: var(--cta-height);
  border-radius: var(--cta-radius) !important;
  font-size: var(--cta-font-size);
  font-weight: var(--cta-font-weight);
  letter-spacing: 0.01em;
  background: var(--cta-primary-bg);
  border: 1px solid var(--cta-primary-bg);
  color: var(--cta-primary-color);
}

.ec-blockBtn--cancel,
.ec-inlineBtn--cancel,
.ec-totalBox__btn .ec-blockBtn--cancel,
.ec-cartRole__actions .ec-blockBtn--cancel {
  min-height: var(--cta-height);
  border-radius: var(--cta-radius) !important;
  font-size: var(--cta-font-size);
  font-weight: var(--cta-font-weight);
  background: var(--cta-secondary-bg);
  border: 1px solid var(--cta-secondary-border);
  color: var(--cta-secondary-color);
}

.ec-totalBox .ec-totalBox__btn > a.ec-blockBtn--cancel,
.ec-totalBox .ec-totalBox__btn a.ec-blockBtn--cancel {
  color: var(--cta-secondary-color);
}
