/* =========================================================
   Paris d'Automne EC styles — refactored v2.5 (design identical)
   目的：重複排除 / 変数集中管理 / TENJIKU対応を簡素化 / パンくず完全非表示
   ※ 数字は :root のトークンを変更するだけで安全に調整できます
   ========================================================= */

/* ---------- Tokens（全ページ共通トークン：ここだけ数字を変えればOK） ---------- */
:root{
  /* type scale（文字サイズ） */
  --ec-fs-base:16px;                     /* 既定文字サイズ（互換） */
  --ec-fs-small:13px;                    /* 説明文・補助テキスト */
  --ec-fs-item-title:20px;               /* 一覧：商品タイトル */
  --ec-fs-price-list:18px;               /* 一覧：価格 */
  --ec-fs-title:20px;                    /* 詳細：商品タイトル */
  --ec-fs-price-detail:22px;             /* 詳細：価格 */
  --ec-fs-tax:0.5em;                     /* 税表記（価格に対する相対） */

  /* color（色） */
  --ec-accent:#f7b500;                   /* 強調（見出し・タブ下線） */
  --ec-text:#111;                        /* 主要テキスト */
  --ec-muted:#666;                       /* 補助テキスト */
  --ec-line:#eee;                        /* 罫線 */
  --ec-chip:#f1f1f1;                     /* カテゴリラベル背景 */
  --ec-notice-bg:#fff9e6;                /* お知らせ背景 */
  --ec-notice-bd:#ffd571;                /* お知らせ枠線 */

  /* radius / spacing（角丸・間隔） */
  --ec-radius-card:14px;                 /* カード角丸 */
  --ec-radius-thumb:14px;                /* サムネ角丸 */
  --ec-radius-btn:10px;                  /* ボタン角丸 */
  --ec-gap:16px;                         /* 汎用グリッド間隔 */

  /* layout（レイアウト） */
  --ec-breakpoint:900px;                 /* PC判定幅 */
  --ec-content-max:720px;                /* 詳細本文の最大幅 */
  --ec-page-max:1100px;                  /* ページ全体の最大幅 */

  /* thumb / fluid title（一覧の流体調整） */
  --ec-thumb-w:clamp(74px,22vw,96px);    /* 一覧サムネ幅（流体） */
  --ec-fs-item-title-fluid:clamp(14px,4.4vw,var(--ec-fs-item-title)); /* タイトル可変 */

  /* tabs（固定タブ） */
  --ec-tabs-h:44px;                      /* タブの高さ（押し下げ量） */
  --ec-top-offset:0px;                   /* WP管理バーぶんの上オフセット */

  /* head/list spacing controls（カテゴリ見出し⇔リストの間） */
  --ec-first-item-top:0px;               /* リスト先頭カード上パディング */

    /* list text spacing */
  --ec-title-price-gap: 6px;   /* 商品名↔価格の間（px） */
  --ec-price-desc-gap:  6px;   /* 価格↔説明の間（px） */
  --ec-title-top: 10px;  /* 商品名（タイトル）の“上”に足す余白。例: 4px */
  --ec-desc-top:  4px;  /* 説明文の“上”に足す余白。例: 6px */
  --ec-meta-gap: 4px;  /* ← タイトル ↔ 価格 ↔ 説明 の等間隔（お好みで 6〜12px など） */

  --ec-head-gap: 12px;          /* 見出しの“下”→リスト頭の間（既存） */
  --ec-section-pad-top: 0px;   /* 見出しの“上”（タブ直下からの押し下げ） */
  /* ※ 真ん中に置きたい時は上と下を同じ値にする（例: 12px と 12px） */
  --ec-first-section-offset: 0px; /* 先頭セクションを少し下げる量（6〜12pxくらいで調整） */

  --ec-cat-gap-top-sp: 12px;   /* SP用：お好みで 8〜16px */
  --ec-cat-gap-top-pc: 16px;   /* PC用：お好みで 12〜24px */
  --ec-anchor-gap: 14px; /* ← タブ直下にさらに足すマージン（微調整用） */

  --ec-gal-arrow-nudge: -0px; /* 商品ページ矢印グレイの上下微調整。負で2px上げる／0ならぴったり */
  --ec-gal-icon-nudge: -2px; /* 白い「＞」だけの上下微調整（負=上/正=下） */

}

/* WP admin bar offset（管理バー時の上オフセット） */
body.admin-bar{ --ec-top-offset:32px; }        /* PC */
@media (max-width:782px){
  body.admin-bar{ --ec-top-offset:46px; }      /* SP */
}

/* base（初期化） */
*,*::before,*::after{ box-sizing:border-box; }  /* 安定したボックスモデル */
html{ -webkit-text-size-adjust:100%; text-size-adjust:100%; } /* iOS拡大防止 */
html,body{ overflow-x:hidden; }                  /* 横スクロール抑止 */

/* =========================================================
   Container / Notice / Breadcrumb
   ========================================================= */
:is(.ec-container,.paec-container){
  max-width:var(--ec-page-max);                 /* ページ横幅上限 */
  margin-inline:auto;                           /* 中央寄せ */
  padding-inline:max(8px,3vw,env(safe-area-inset-left),env(safe-area-inset-right)); /* 安全域配慮 */
  padding-block:16px;                           /* 上下余白 */
}
:is(.ec-notice,.paec-notice){
  background:var(--ec-notice-bg);               /* お知らせ背景 */
  border:1px solid var(--ec-notice-bd);         /* お知らせ枠線 */
  padding:10px 12px; border-radius:6px;         /* 角丸＋内余白 */
}
:is(.ec-breadcrumb,.paec-breadcrumb){
  margin:8px 0 12px; font-size:var(--ec-fs-small); color:var(--ec-muted); /* パンくず */
}

/* =========================================================
   Tabs (fixed)
   ========================================================= */
:is(.ec-tabs-wrapper,.paec-tabs-wrapper){
  position:fixed; top:var(--ec-top-offset); left:0; right:0; z-index:2147483646;
  background:#fff; border-bottom:1px solid var(--ec-line);          /* 上部固定タブ */
}
:is(.ec-tabs,.paec-tabs){
  display:flex; gap:16px; overflow-x:auto; padding:8px 12px;        /* タブ行 */
}
:is(.ec-tab,.paec-tab){
  white-space:nowrap; font-weight:700; color:#999; text-decoration:none;
  padding:6px 0; border-bottom:2px solid transparent;               /* 非アクティブ */
}
:is(.ec-tab,.paec-tab).is-active{ color:var(--ec-text); border-color:var(--ec-accent); } /* アクティブ */
:is(.ec-tabs-spacer,.paec-tabs-spacer){ height:var(--ec-tabs-h); }  /* タブ高さぶん押し下げ */
:is(.ec-store,.paec-store){ position:relative; }                     /* 基準位置 */
/* ロック中はタブの下線（= border-bottom）のトランジションを無効化して揺れを止める */
:is(.ec-tabs,.paec-tabs).is-locked :is(.ec-tab,.paec-tab){
  transition: none !important;
}

/* =========================================================
   Sections（カテゴリ上下の余白を一元管理）
   ========================================================= */
:is(.ec-section,.paec-section){
  padding:12px 12px 8px;
  scroll-margin-top:calc(var(--ec-tabs-h) + var(--ec-top-offset) + var(--ec-anchor-gap, 8px));
}

.category-section{ display:flow-root; --wp--style--block-gap:0; }   /* margin相殺防止＋gap無効化 */
.category-section > *{ margin-block:0; }                             /* 直下子の上下margin排除 */

:is(.ec-section-head,.paec-section-head){
  display:flex; justify-content:space-between; align-items:center; gap:12px;
  margin-bottom:10px; min-height:36px; padding-block:8px;           /* 見出し行 */
}
:is(.ec-section-title,.paec-section-title){
  color:var(--ec-accent); font-size:16px; font-weight:800; margin:0; line-height:1; /* 見出し文言 */
}
:is(.ec-more,.paec-more){ color:#aaa; text-decoration:none; font-size:var(--ec-fs-small); line-height:1; } /* more */

/* 見出し（hタグ）の上下をゼロ化：カテゴリ帯の高さブレ防止 */
:is(.ec-container,.paec-container)
  :is(h1,h2,h3,h4,h5,h6):is(.category-title,.archive-title,.page-title,[class*="category"],[class*="archive"]){
  margin-block:0; padding-block:0; line-height:1;
}
/* 一般見出しの上だけ最小限 */
:is(.ec-container,.paec-container) :is(h1,h2,h3,h4,h5,h6){ margin-block-start:.25em; }

/* 見出し行の“次に来る最初のリスト”にだけギャップを付ける（間にブロックが入ってもOK） */
:is(.ec-section,.paec-section) :is(.ec-section-head,.paec-section-head)
  ~ :is(.ec-list,.paec-list):first-of-type{
  margin-top:var(--ec-head-gap) !important;
}


/* =========================================================
   List cards（一覧）
   ========================================================= */
:is(.ec-list,.paec-list){ display:grid; gap:14px; text-align:left; container-type:inline-size; } /* グリッド */

:is(.ec-item,.paec-item){
  display:flex; gap:12px; align-items:flex-start; min-width:0;      /* 行自体も縮小許容（ellipsis保険） */
  padding-right:8px; padding-block:8px; min-height:calc(var(--ec-thumb-w) + 8px);
}
:is(.ec-thumb,.paec-thumb){
  flex:0 0 var(--ec-thumb-w); width:var(--ec-thumb-w); height:var(--ec-thumb-w);
  border-radius:var(--ec-radius-thumb); overflow:hidden; border:1px solid var(--ec-line); background:#fafafa;
}
:is(.ec-thumb,.paec-thumb) img{ width:100%; height:100%; object-fit:cover; display:block; }

/* 右側テキストカラム：グリッドで縦に並べ、行間はトークンで統一 */
:is(.ec-meta,.paec-meta){
  flex:1 1 0%;
  min-width:0;
  display:grid;
  grid-auto-rows:max-content;      /* 各行は内容サイズで確定 */
  row-gap:var(--ec-meta-gap);      /* タイトル ↔ 価格 ↔ 説明 の等間隔 */
  /* ↓「テキスト束をサムネ高さに収めたい」見た目調整（不要なら消してOK） */
  /* min-height:var(--ec-thumb-w); */
  padding-top:var(--ec-title-top);/* ← 商品名の“上”の余白をここで調整 */
}

/* 子要素の外側余白はゼロにして、gap に一本化 */
:is(.ec-meta,.paec-meta) > *{ margin:0; }

/* タイトル（1行省略） */
:is(.ec-item,.paec-item) :is(.ec-meta,.paec-meta)
  :is(h1,h2,h3,h4,h5,h6,p,div).ec-item-title,
:is(.ec-item,.paec-item) :is(.ec-meta,.paec-meta)
  :is(h1,h2,h3,h4,h5,h6,p,div).paec-item-title{
  font-size:var(--ec-fs-item-title);
  line-height:1.4;
  margin:0;                         /* gap 管理なので余白はゼロ */
}
:is(.ec-item-title,.paec-item-title){ min-width:0; } /* ellipsis 保険 */
:is(.ec-item-title,.paec-item-title) *{ font-size:inherit; }
:is(.ec-item-title,.paec-item-title) a{
  display:block; max-width:100%; min-width:0;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
}

/* 価格（税表記を小さく寄せる）— 余白は margin:0 で固定（gap に任せる） */
:is(.ec-item,.paec-item) :is(.ec-meta,.paec-meta) :is(p,div,span).ec-price,
:is(.ec-item,.paec-item) :is(.ec-meta,.paec-meta) :is(p,div,span).paec-price{
  font-size:var(--ec-fs-price-list);
  line-height:1.2;
  margin:0;
}
:is(.ec-price,.paec-price) *{ font-size:inherit; }
:is(.ec-price,.paec-price) .ec-tax,
:is(.ec-price,.paec-price) .paec-tax{
  font-size:var(--ec-fs-tax);
  color:#8a8a8a;
  margin-left:-0.25em;
  white-space:nowrap;
  vertical-align:baseline;
}

/* 説明（2行固定・高さ不変）— 余白は gap に統一するので margin は 0 */
:is(.ec-list,.paec-list) :is(.ec-desc,.paec-desc){
  font-size:var(--ec-fs-small);
  line-height:1.25;
  margin-top:var(--ec-desc-top) !important; /* ← 説明の“上”の余白をトークンで調整 */
  margin-bottom:0 !important;               /* 下はゼロのまま（デザイン維持） */
  display:-webkit-box;
  -webkit-box-orient:vertical;
  -webkit-line-clamp:2; line-clamp:2;
  overflow:hidden;
  max-height:calc(1.25em * 2);
  min-height:calc(1.25em * 2);
  overflow-wrap:anywhere;
  word-break:break-word;
}

/* 自動整形/空段落対策（既存どおり） */
:is(.ec-meta,.paec-meta) > :is(.ec-item-title,.paec-item-title) + *{ margin-top:0; padding-top:0; }
:is(.ec-meta,.paec-meta) > p{ margin:0; }
:is(.ec-meta,.paec-meta) > p:empty, :is(.ec-meta,.paec-meta) > br{ display:none; }

/* 先頭カードの上だけ微調整（通常0） */
.ec-list > .ec-item:first-child,
.paec-list > .paec-item:first-child{
  padding-top:var(--ec-first-item-top) !important;
}

/* =========================================================
   Product page（商品詳細）
   ========================================================= */
:is(.ec-product,.paec-product){ display:grid; gap:var(--ec-gap); }             /* 縦間隔 */
:is(.ec-product-media,.paec-product-media) img{
  width:100%; height:auto; border:1px solid var(--ec-line); border-radius:var(--ec-radius-card);
}
:is(h1,h2,h3,h4,h5,h6,p,div).ec-product-name,
:is(h1,h2,h3,h4,h5,h6,p,div).paec-product-name{
  font-size:var(--ec-fs-title); line-height:1; margin:0;
}
:is(p,div,span).ec-product-price,
:is(p,div,span).paec-product-price{
  font-size:var(--ec-fs-price-detail); line-height:1; margin:0;
}
:is(.ec-product-price,.paec-product-price) .ec-tax,
:is(.ec-product-price,.paec-product-price) .paec-tax{ font-size:var(--ec-fs-tax); margin-left:-0.25em; }
:is(.ec-product-desc,.paec-product-desc){ color:#333; line-height:1.8; }
:is(.ec-buy-btn,.paec-buy-btn){
  display:inline-block; margin-top:12px; padding:14px 18px;
  border-radius:var(--ec-radius-btn); background:var(--ec-text); color:#fff; text-decoration:none; font-weight:700;
}

/* =========================================================
   PC layout
   ========================================================= */
@media (min-width:900px){
  :is(.ec-container,.paec-container){ max-width:900px; padding:24px; }         /* 横幅/余白 */
  :is(.ec-product,.paec-product){ gap:28px; grid-template-columns:1fr; }       /* 単列維持 */
  :is(.ec-gallery,.paec-gallery),
  :is(.ec-product-info,.paec-product-info),
  :is(.ec-product-desc,.paec-product-desc){
    max-width:var(--ec-content-max); margin-inline:auto;                       /* 本文幅 */
  }

  /* ←ここが書き換えポイント：PCも必ず“2行固定”になるよう強制 */
  :is(.ec-list,.paec-list) :is(.ec-desc,.paec-desc){
    -webkit-line-clamp:2 !important;
    line-clamp:2 !important;
    max-height:calc(1.25em * 2) !important;
  }

  :is(.ec-tabs-wrapper,.paec-tabs-wrapper){
    max-width:var(--ec-page-max); margin-inline:auto; left:0; right:0;         /* タブ幅合わせ */
  }
  :is(.ec-tabs,.paec-tabs){ padding-left:0; padding-right:0; }                 /* タブ左右余白 */
}

/* =========================================================
   Gallery（スライダー）
   ========================================================= */
:is(.ec-gallery,.paec-gallery){ position:relative; margin:8px 0 14px; }
:is(.ec-gal-viewport,.paec-gal-viewport){
  overflow:hidden; border:1px solid var(--ec-line); border-radius:var(--ec-radius-card);
}
:is(.ec-gal-track,.paec-gal-track){
  display:flex; scroll-snap-type:x mandatory; overflow-x:auto; -webkit-overflow-scrolling:touch; scrollbar-width:none;
}
:is(.ec-gal-track,.paec-gal-track)::-webkit-scrollbar{ display:none; }
:is(.ec-gal-slide,.paec-gal-slide){ flex:0 0 100%; scroll-snap-align:start; }
:is(.ec-gal-slide,.paec-gal-slide) img{ width:100%; height:auto; display:block; }
/* ギャラリー左右矢印：厳密中央＋微調整ノブ */
:is(.ec-gal-btn,.paec-gal-btn){
  position: absolute;
  top: 50%;
  transform: translateY(-50%);   /* ← 本体（丸）は常に厳密中央 */
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 0;
  background: rgba(17,17,17,.5);
  color: #fff;
  font-size: 0px;        /* ← 元テキスト“›”を非表示にする（擬似要素を表示） */
  display: flex;               /* ← line-height依存をやめて厳密中央に */
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 2;                  /* 画像より前面に */
}

/* 右矢印（次へ） */
:is(.ec-gal-next,.paec-gal-next)::before{
  content: "›";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, calc(-50% + var(--ec-gal-icon-nudge)));
  font-size: 22px;    /* ← ここで白い矢印のサイズを指定 */
  line-height: 1;
  color: #fff;
  pointer-events: none;
}

/* 左矢印（前へ） */
:is(.ec-gal-prev,.paec-gal-prev)::before{
  content: "‹";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, calc(-50% + var(--ec-gal-icon-nudge)));
  font-size: 22px;
  line-height: 1;
  color: #fff;
  pointer-events: none;
}


:is(.ec-gal-prev,.paec-gal-prev){ left:8px; }
:is(.ec-gal-next,.paec-gal-next){ right:8px; }
:is(.ec-gal-btn[disabled],.paec-gal-btn[disabled]){ opacity:.3; cursor:default; }

/* =========================================================
   WooCommerce（カテゴリ見出し帯の一本化）
   ========================================================= */
.woocommerce
  :is(.woocommerce-products-header,
      .woocommerce-products-header__title.page-title,
      .term-description){
  margin:0; padding:0; line-height:1;
}
.woocommerce .term-description > *{ margin:0; padding:0; line-height:inherit; }
.woocommerce .woocommerce-products-header__title.page-title + .term-description{ margin-top:0; }

/* =========================================================
   Responsive（Container Queries + Fallback）
   ========================================================= */
@container (max-width:360px){
  :is(.ec-list,.paec-list){ --ec-thumb-w:clamp(64px,24vw,76px); }
  :is(.ec-item,.paec-item){ gap:8px; padding-right:6px; }
  :is(.ec-item-title,.paec-item-title){ font-size:clamp(13px,4.2vw,var(--ec-fs-item-title)); line-height:1; }
  :is(.ec-desc,.paec-desc){ line-height:1.20; max-height:calc(1.20em * 2); min-height:calc(1.20em * 2); }
}
@container (min-width:361px) and (max-width:420px){
  :is(.ec-list,.paec-list){ --ec-thumb-w:clamp(70px,22vw,84px); }
  :is(.ec-item,.paec-item){ gap:10px; padding-right:6px; }
  :is(.ec-item-title,.paec-item-title){ font-size:clamp(14px,4.4vw,var(--ec-fs-item-title)); line-height:1; }
  :is(.ec-desc,.paec-desc){ line-height:1.22; max-height:calc(1.22em * 2); min-height:calc(1.22em * 2); }
}
@container (min-width:421px){
  :is(.ec-list,.paec-list){ --ec-thumb-w:clamp(80px,20vw,96px); }
  :is(.ec-item,.paec-item){ gap:12px; padding-right:8px; }
  :is(.ec-item-title,.paec-item-title){ font-size:var(--ec-fs-item-title-fluid); line-height:1.20; }
  :is(.ec-desc,.paec-desc){ line-height:1.25; max-height:calc(1.25em * 2); min-height:calc(1.25em * 2); }
}
/* Fallback MQ（非CQブラウザ） */
@media (max-width:375px){
  :root{ --ec-thumb-w:76px; }
  :is(.ec-item,.paec-item){ gap:8px; padding-right:6px; }
  :is(.ec-item-title,.paec-item-title){ font-size:clamp(13px,4.2vw,var(--ec-fs-item-title)); line-height:1; }
  :is(.ec-price,.paec-price){ font-size:calc(var(--ec-fs-price-list)*.95); }
  :is(.ec-desc,.paec-desc){ line-height:1.20; max-height:calc(1.20em * 2); min-height:calc(1.20em * 2); }
}
@media (min-width:376px) and (max-width:409px){
  :root{ --ec-thumb-w:84px; }
  :is(.ec-item,.paec-item){ gap:10px; padding-right:6px; }
  :is(.ec-item-title,.paec-item-title){ font-size:clamp(14px,4.4vw,var(--ec-fs-item-title)); line-height:1; }
}
@media (min-width:410px) and (max-width:427px){
  :root{ --ec-thumb-w:90px; }
  :is(.ec-item,.paec-item){ gap:12px; padding-right:8px; }
  :is(.ec-item-title,.paec-item-title){ font-size:var(--ec-fs-item-title-fluid); line-height:1; }
}
@media (min-width:428px){
  :root{ --ec-thumb-w:96px; }
  :is(.ec-item,.paec-item){ gap:12px; padding-right:8px; }
  :is(.ec-item-title,.paec-item-title){ font-size:var(--ec-fs-item-title-fluid); line-height:1; }
}

/* =========================================================
   TENJIKU adjustments — page-id-1383（整理版）
   ・ヘッダー/スペーサ等の残骸を完全無効化
   ・タブは常に最上部 / スペーサはタブ高に一致
   ・spacer が無い場合の保険で EC ルートに上padding
   ・パンくず（Home含む）は完全非表示＋直後の隙間除去
   ========================================================= */
body.page-id-1383 :is(
  #page_header,#page_header_space,#header,#header_space,#header_circle,
  .header_space,.page_header__space,.p-page-header,.c-page-header
){ display:none; height:0; margin:0; padding:0; border:0; background:none; }

body.page-id-1383 :is(
  #body,#main_col,#main,#main-contents,#content,
  .contents,.content,.entry,.entry-body,.entry-content,.post_content,
  .l-contents,.l-content,.l-container,.c-container,.p-entry__body,.wp-block-group
){ padding-top:0; margin-top:0; padding-bottom:0; margin-bottom:0; --wp--style--block-gap:0; }


/* タブ直下スペーサー＝タブ高さ（かぶり防止） */
body.page-id-1383
  :is(.ec-tabs-wrapper,.paec-tabs-wrapper) + :is(.ec-tabs-spacer,.paec-tabs-spacer){
  height: var(--ec-tabs-h) !important;
}

/* spacer が無いテーマ構成でも重ならない保険（押し下げ） */
body.page-id-1383 :is(.ec-store,.paec-store):not(:has(.ec-tabs-spacer,.paec-tabs-spacer)){
  padding-top: var(--ec-tabs-h) !important; /* ←既存に !important を足すだけでもOK */
}

/* ★先頭セクションをタブ高さぶん引き上げ＋微戻し */
body.page-id-1383 :is(.ec-section,.paec-section):first-of-type{
  margin-top: calc(-1 * var(--ec-tabs-h) + var(--ec-first-section-offset)) !important;
  padding-top: max(var(--ec-section-pad-top), 4px) !important;
}


/* --- Breadcrumb remover（統合） --- */
body.page-id-1383 :is(
  [itemscope][itemtype*="Breadcrumb" i], [itemtype*="Breadcrumb" i],       /* Microdataの容器 */
  nav[aria-label*="breadcrumb" i],                                          /* ARIA */
  .ec-breadcrumb,.paec-breadcrumb,.woocommerce-breadcrumb,                  /* 本EC/Woo */
  .p-breadcrumb,.c-breadcrumb,.breadcrumb,.breadcrumbs,                     /* 汎用/TCD */
  [class*="breadcrumb" i],[id*="breadcrumb" i]                              /* その他 */
){
  display:none !important; height:0 !important; margin:0 !important; padding:0 !important;
  border:0 !important; background:none !important; visibility:hidden !important;
}
/* Homeリンク（itemprop="item"）を含む未知の器も親ごと潰す */
body.page-id-1383 :is(nav,div,section,header,ol,ul,li,p)
  :has(a[itemprop="item"][href*="paris-dautomne.com"]){
  display:none !important; height:0 !important; margin:0 !important; padding:0 !important; border:0 !important; visibility:hidden !important;
}
/* パンくず削除後の“直後要素の上マージン/罫線”も除去 */
body.page-id-1383 :is(
  [itemscope][itemtype*="Breadcrumb" i],[itemtype*="Breadcrumb" i],
  nav[aria-label*="breadcrumb" i],
  .ec-breadcrumb,.paec-breadcrumb,.woocommerce-breadcrumb,
  .p-breadcrumb,.c-breadcrumb,.breadcrumb,.breadcrumbs,
  [class*="breadcrumb" i],[id*="breadcrumb" i],
  nav,div,section,header,ol,ul,li,p
)+*{ margin-top:0 !important; border-top:0 !important; }

/* =========================================================
   HOTFIX（最優先）— page-id-1383：カテゴリ内の垂直余白を全ゼロ固定
   ※ デザイン骨格は保ちつつ、のちの“見出し→リストの可変ギャップ”で上書きします
   ========================================================= */
.page-id-1383 .ec-section,
.page-id-1383 .paec-section{
  padding-top:0 !important; padding-bottom:0 !important;
  margin-top:0 !important; margin-bottom:0 !important;
}
.page-id-1383 .ec-section-head,
.page-id-1383 .paec-section-head{
  padding-top:0 !important; padding-bottom:0 !important;
  margin-top:0 !important; margin-bottom:0 !important; min-height:0 !important;
}
.page-id-1383 .ec-section-title,
.page-id-1383 .paec-section-title,
.page-id-1383 .ec-section :is(h1,h2,h3,h4,h5,h6),
.page-id-1383 .paec-section :is(h1,h2,h3,h4,h5,h6){
  margin:0 !important; padding:0 !important; line-height:1 !important;
}
.page-id-1383 .ec-section-head + *{
  margin-top:0 !important; padding-top:0 !important; min-height:0 !important;
}
.page-id-1383 .ec-list,
.page-id-1383 .paec-list{
  margin-top:0 !important; padding-top:0 !important; gap:10px !important;
}
.page-id-1383 .ec-list > .ec-item:first-child,
.page-id-1383 .paec-list > .paec-item:first-child{
  padding-top:0 !important; margin-top:0 !important;
}

/* =========================================================
   Spacing overrides（HOTFIXの上から“安全に”足す可変調整）
   目的：カテゴリ見出し（タイトル＋もっと見る）を
        タブと商品リストの中間寄りに配置できるようにする
   使い方：下の :root の数値だけ調整してください
   ========================================================= */


/* 見出しの“上”：セクション上パディングを HOTFIX より強く上書き */
body.page-id-1383 :is(.ec-section,.paec-section){
  padding-top: var(--ec-section-pad-top) !important;
}

/* 見出しの“下”：直後がリストなら上マージンをトークンで調整（中央寄せ用） */
body.page-id-1383
  :is(.ec-section-head,.paec-section-head) + :is(.ec-list,.paec-list){
  margin-top: var(--ec-head-gap) !important;
}

/* =========================================================
   Misc（安全系）
   ========================================================= */
:is(.ec-list,.paec-list),
:is(.ec-item,.paec-item),
:is(.ec-meta,.paec-meta),
:is(.ec-section,.paec-section){ text-align:left; }

@media (prefers-reduced-motion:reduce){
  :is(.ec-gal-track,.paec-gal-track){ scroll-behavior:auto; }
}



body.page-id-1383
  :is(.entry-content,.post_content,.contents,.content,.l-contents,.l-content){
  margin-top:0 !important;
  padding-top:0 !important;
}


/* === FINAL OVERRIDE: 先頭セクションの押し下げ（SP/PCで値を変える） === */

/* SP（〜899px）：少し下げる */
@media (max-width: 899.98px){
  :root{ --ec-first-section-offset-sp: 0px; } /* 4〜10pxでお好み */
  .page-id-1383 .paec-store > .paec-section:first-of-type{
    margin-top: var(--ec-first-section-offset-sp) !important;
  }
}

/* PC（900px〜）：少し上げる（負の値） */
@media (min-width: 900px){
  :root{ --ec-first-section-offset-pc: 8px; } /* 今の設定。4〜-12pxが目安 */
  .page-id-1383 .paec-store > .paec-section:first-of-type{
    margin-top: var(--ec-first-section-offset-pc) !important;
  }
}

/* 管理バー時はタブそのものを下げる（置き換え後の正解） */
body.admin-bar :is(.ec-tabs-wrapper,.paec-tabs-wrapper,.paec-tabs-wrapper--fixed){
  top: var(--ec-top-offset) !important;
}

/* SPだけ：adminバーがある時はタブを最上部に固定（上に戻す） */
@media (max-width: 899.98px){
  body.admin-bar.page-id-1383
    :is(.ec-tabs-wrapper,.paec-tabs-wrapper,.paec-tabs-wrapper--fixed){
    top: 0 !important;   /* ← ここで adminBar 分の下げを打ち消す */
  }
}


/* SP（〜899px）：2個目以降のセクションだけ上マージンを付与 */
@media (max-width: 899.98px){
  body.page-id-1383 :is(.ec-section,.paec-section):not(:first-of-type){
    margin-top: var(--ec-cat-gap-top-sp) !important;
  }
}

/* PC（900px〜）：2個目以降のセクションだけ上マージンを付与 */
@media (min-width: 900px){
  body.page-id-1383 :is(.ec-section,.paec-section):not(:first-of-type){
    margin-top: var(--ec-cat-gap-top-pc) !important;
  }
}

/*  タブ直下のスペーサーを白で塗る（にじみ防止） */
:is(.ec-tabs-spacer,.paec-tabs-spacer){
  background:#fff;
}



/* スペーサーは白でOK（共通） */
:is(.ec-tabs-spacer,.paec-tabs-spacer){ background:#fff; }

/* ===== SP（〜899px）：全幅白＋左右を -3px オーバースキャン ===== */
@media (max-width: 899.98px){
  :is(.ec-tabs-wrapper,.paec-tabs-wrapper,.paec-tabs-wrapper--fixed){
    background:#fff;
    overflow:visible;
    position:fixed;
  }
  :is(.ec-tabs-wrapper,.paec-tabs-wrapper,.paec-tabs-wrapper--fixed)::before{
    content:"";
    position:absolute;
    top:0; bottom:0;
    left:-3px;           /* ← ここが効いてた値 */
    right:-3px;          /* ← 同上 */
    background:#fff;
    pointer-events:none;
    z-index:-1;
  }
}

/* ===== PC（900px〜）：本文幅だけ白帯＋左右を +6px（±3px）オーバースキャン ===== */
@media (min-width: 900px){
  /* 本体は透明。中央の疑似要素で本文幅だけ白くする */
  :is(.ec-tabs-wrapper,.paec-tabs-wrapper,.paec-tabs-wrapper--fixed){
    background: transparent;
    overflow: visible;
    position: fixed;
  }
  :is(.ec-tabs-wrapper,.paec-tabs-wrapper,.paec-tabs-wrapper--fixed)::before{
    content:"";
    position:absolute;
    top:0; bottom:0;
    left:50%;
    width: calc(var(--ec-page-max) + 6px); /* ← 本文幅 + 左右3pxずつ（SPの -3px 相当） */
    max-width: calc(100vw + 6px);          /* 画面端でも同じだけオーバースキャン */
    transform: translateX(-50%);
    background:#fff;
    pointer-events:none;
    z-index:-1;
  }

  /* スペーサーも本文幅だけ白＋±3pxオーバースキャン */
  :is(.ec-tabs-spacer,.paec-tabs-spacer){
    background: transparent !important;
    position: relative;
  }
  :is(.ec-tabs-spacer,.paec-tabs-spacer)::before{
    content:"";
    position:absolute;
    inset:0;
    left:50%;
    width: calc(var(--ec-page-max) + 6px);
    max-width: calc(100vw + 6px);
    transform: translateX(-50%);
    background:#fff;
    pointer-events:none;
    z-index:0;
  }
}


/* クリック拡張：説明文/価格のマウスカーソルだけ“pointer” */
.paec-item .paec-desc,
.paec-item .paec-price,
.paec-item .paec-product-price,
.ec-item  .ec-desc,
.ec-item  .ec-price,
.ec-item  .ec-product-price { cursor: pointer; }
