/* ================================================================
   FEF TABS WIDGET
   ================================================================ */
.fef-tabs{display:flex;flex-direction:column;width:100%;max-width:100%;overflow:hidden;box-sizing:border-box}
.fef-tabs-nav-container{display:flex;max-width:100%;overflow:hidden}
.fef-tabs-nav{display:flex;list-style:none;margin:0;padding:0;gap:0;position:relative;flex:1;min-width:0;max-width:100%}

/* ── Tab bar alignment (when width is restricted) ── */
.fef-tabs-bar-left .fef-tabs-nav-container{margin-right:auto}
.fef-tabs-bar-center .fef-tabs-nav-container{margin-left:auto;margin-right:auto}
.fef-tabs-bar-right .fef-tabs-nav-container{margin-left:auto}

/* ── Fixed/max width: contain tabs, enable scroll ── */
.fef-tabs-w-fixed .fef-tabs-nav-container,.fef-tabs-w-max .fef-tabs-nav-container{overflow:hidden}
.fef-tabs-w-fixed .fef-tabs-nav,.fef-tabs-w-max .fef-tabs-nav{overflow-x:auto;scrollbar-width:none;-ms-overflow-style:none;scroll-behavior:smooth}
.fef-tabs-w-fixed .fef-tabs-nav::-webkit-scrollbar,.fef-tabs-w-max .fef-tabs-nav::-webkit-scrollbar{display:none}
.fef-tabs-nav-item{display:flex;align-items:center;gap:8px;padding:12px 20px;cursor:pointer;transition:all 0.3s ease;position:relative;border:1px solid transparent;box-sizing:border-box;user-select:none}
.fef-tabs-width-auto-title .fef-tabs-nav-item{white-space:nowrap}
.fef-tabs-width-auto-full .fef-tabs-nav-item{white-space:normal}
.fef-tabs-width-fixed .fef-tabs-nav-item{white-space:normal;word-wrap:break-word;overflow-wrap:break-word}
.fef-tabs-width-stretch .fef-tabs-nav-item{flex:1;justify-content:center}
.fef-tabs-nav-item:hover{z-index:1}
.fef-tabs-nav-icon{display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:all 0.3s ease}
.fef-tabs-nav-icon img{object-fit:contain}
.fef-tabs-nav-text{display:flex;flex-direction:column;gap:2px}
.fef-tabs-nav-title{font-weight:500;transition:color 0.3s ease}
.fef-tabs-nav-desc{font-size:12px;color:#64748b;transition:color 0.3s ease}
.fef-tabs-body{position:relative;overflow:hidden;max-width:100%}
.fef-tabs-panel{display:none;padding:20px;max-width:100%;overflow:hidden;box-sizing:border-box}
.fef-tabs-panel.fef-tabs-active{display:block}

/* ── Description position ── */
.fef-tabs-desc-below .fef-tabs-nav-text{flex-direction:column}
.fef-tabs-desc-above .fef-tabs-nav-text{flex-direction:column}
.fef-tabs-desc-left .fef-tabs-nav-text{flex-direction:row;align-items:center;gap:8px}
.fef-tabs-desc-right .fef-tabs-nav-text{flex-direction:row;align-items:center;gap:8px}

/* ── Tab placement: top ── */
.fef-tabs-top{flex-direction:column}
.fef-tabs-top .fef-tabs-nav-container{border-bottom:1px solid #e2e8f0}
/* ── Tab placement: bottom ── */
.fef-tabs-bottom{flex-direction:column-reverse}
.fef-tabs-bottom .fef-tabs-nav-container{border-top:1px solid #e2e8f0}
/* ── Tab placement: left ── */
.fef-tabs-left{flex-direction:row}
.fef-tabs-left .fef-tabs-nav-container{flex-direction:column;border-right:1px solid #e2e8f0;min-width:160px;width:auto;flex:none}
.fef-tabs-left .fef-tabs-nav{flex-direction:column}
.fef-tabs-left .fef-tabs-body{flex:1;min-width:0}
/* ── Tab placement: right ── */
.fef-tabs-right{flex-direction:row-reverse}
.fef-tabs-right .fef-tabs-nav-container{flex-direction:column;border-left:1px solid #e2e8f0;min-width:160px;width:auto;flex:none}
.fef-tabs-right .fef-tabs-nav{flex-direction:column}
.fef-tabs-right .fef-tabs-body{flex:1;min-width:0}

/* ── Icon layout ── */
.fef-tabs-icon-top .fef-tabs-nav-item{flex-direction:column;text-align:center}
.fef-tabs-icon-top .fef-tabs-nav-text{align-items:center}
.fef-tabs-icon-left .fef-tabs-nav-item{flex-direction:row}
.fef-tabs-icon-right .fef-tabs-nav-item{flex-direction:row-reverse}
.fef-tabs-icon-bottom .fef-tabs-nav-item{flex-direction:column-reverse;text-align:center}
.fef-tabs-icon-bottom .fef-tabs-nav-text{align-items:center}

/* ── Tab alignment ── */
.fef-tabs-align-center .fef-tabs-nav{justify-content:center}
.fef-tabs-align-start .fef-tabs-nav{justify-content:flex-start}
.fef-tabs-align-end .fef-tabs-nav{justify-content:flex-end}
.fef-tabs-align-between .fef-tabs-nav{justify-content:space-between}
.fef-tabs-align-stretch .fef-tabs-nav-item{flex:1;justify-content:center}

/* ── Tab width modes ── */
/* fixed width is handled via inline selectors from the slider control */

/* ── Active tab height ── */
.fef-tabs-nav-item{--fef-tab-pt:12px;--fef-tab-pb:12px;transition:all 0.3s ease}
.fef-tabs-active-tab{z-index:2;position:relative}

/* ── Overlay mode: tabs float on top of content ── */
.fef-tabs-overlay-mode{position:relative}
.fef-tabs-overlay-mode .fef-tabs-nav-container.fef-tabs-nav-overlay{position:absolute;z-index:10;pointer-events:auto}
.fef-tabs-overlay-mode .fef-tabs-nav-overlay .fef-tabs-nav{pointer-events:auto}
.fef-tabs-overlay-mode .fef-tabs-nav-overlay .fef-tabs-nav-item{pointer-events:auto;cursor:pointer}
.fef-tabs-overlay-mode.fef-tabs-top .fef-tabs-nav-overlay{top:0;left:0;right:0}
.fef-tabs-overlay-mode.fef-tabs-bottom .fef-tabs-nav-overlay{top:auto;bottom:0;left:0;right:0}
.fef-tabs-overlay-mode.fef-tabs-left .fef-tabs-nav-overlay{left:0;top:0;bottom:0}
.fef-tabs-overlay-mode.fef-tabs-right .fef-tabs-nav-overlay{left:auto;right:0;top:0;bottom:0}
.fef-tabs-overlay-mode .fef-tabs-nav-container{border:none!important}
.fef-tabs-overlay-mode .fef-tabs-body{flex:1}

/* ── Scrollable tabs ── */
.fef-tabs-nav-wrap{display:flex;align-items:center;gap:4px;position:relative;max-width:100%;overflow:hidden}
.fef-tabs-scrollable .fef-tabs-nav{overflow-x:auto;overflow-y:hidden;scrollbar-width:none;-ms-overflow-style:none;scroll-behavior:smooth;flex:1;min-width:0;max-width:100%}
.fef-tabs-scrollable .fef-tabs-nav::-webkit-scrollbar{display:none}
.fef-tabs-arrow{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border:1px solid #e2e8f0;border-radius:16px;background:#fff;color:#475569;cursor:pointer;flex-shrink:0;transition:all 0.2s ease;font-size:14px;z-index:2;line-height:1;padding:0}
.fef-tabs-arrow:hover{background:#f1f5f9;color:#1e293b}
.fef-tabs-arrow.fef-tabs-arrow-hidden{opacity:0;pointer-events:none}
.fef-tabs-arrows-auto .fef-tabs-arrow{opacity:0;pointer-events:none}
.fef-tabs-arrows-auto.fef-tabs-has-overflow .fef-tabs-arrow{opacity:1;pointer-events:auto}
.fef-tabs-arrows-auto.fef-tabs-has-overflow .fef-tabs-arrow.fef-tabs-arrow-hidden{opacity:0.3;pointer-events:none}
.fef-tabs-arrows-always .fef-tabs-arrow.fef-tabs-arrow-hidden{opacity:0.3;pointer-events:none}
.fef-tabs-arrows-never .fef-tabs-arrow{display:none}
/* Vertical scroll */
.fef-tabs-left.fef-tabs-scrollable .fef-tabs-nav-wrap,.fef-tabs-right.fef-tabs-scrollable .fef-tabs-nav-wrap{flex-direction:column}
.fef-tabs-left.fef-tabs-scrollable .fef-tabs-nav,.fef-tabs-right.fef-tabs-scrollable .fef-tabs-nav{overflow-y:auto;overflow-x:hidden;max-height:400px}

/* ── Active tab indicator line ── */
.fef-tabs-top .fef-tabs-nav-item.fef-tabs-active-tab::after,.fef-tabs-bottom .fef-tabs-nav-item.fef-tabs-active-tab::after{content:'';position:absolute;left:0;right:0;height:2px;background:currentColor;transition:all 0.3s ease}
.fef-tabs-top .fef-tabs-nav-item.fef-tabs-active-tab::after{bottom:-1px}
.fef-tabs-bottom .fef-tabs-nav-item.fef-tabs-active-tab::after{top:-1px}
.fef-tabs-left .fef-tabs-nav-item.fef-tabs-active-tab::after,.fef-tabs-right .fef-tabs-nav-item.fef-tabs-active-tab::after{content:'';position:absolute;top:0;bottom:0;width:2px;background:currentColor;transition:all 0.3s ease}
.fef-tabs-left .fef-tabs-nav-item.fef-tabs-active-tab::after{right:-1px}
.fef-tabs-right .fef-tabs-nav-item.fef-tabs-active-tab::after{left:-1px}

/* ═══════════════════════════════════════
   CONTENT TRANSITION KEYFRAMES
   ═══════════════════════════════════════ */
@keyframes fefTabFade{from{opacity:0}to{opacity:1}}
@keyframes fefTabSlideLeft{from{opacity:0;transform:translateX(-30px)}to{opacity:1;transform:translateX(0)}}
@keyframes fefTabSlideRight{from{opacity:0;transform:translateX(30px)}to{opacity:1;transform:translateX(0)}}
@keyframes fefTabSlideDown{from{opacity:0;transform:translateY(-20px)}to{opacity:1;transform:translateY(0)}}
@keyframes fefTabSlideUp{from{opacity:0;transform:translateY(20px)}to{opacity:1;transform:translateY(0)}}
@keyframes fefTabBlur{from{opacity:0;filter:blur(8px)}to{opacity:1;filter:blur(0)}}
@keyframes fefTabOpacity{from{opacity:0}to{opacity:1}}
@keyframes fefTabBlinds{from{opacity:0;clip-path:inset(0 100% 0 0)}to{opacity:1;clip-path:inset(0 0 0 0)}}
@keyframes fefTabMask{from{opacity:0;clip-path:circle(0% at 50% 50%)}to{opacity:1;clip-path:circle(100% at 50% 50%)}}
@keyframes fefTabOverlay1{from{opacity:0;transform:scale(1.05)}50%{opacity:0.5}to{opacity:1;transform:scale(1)}}

/* ── Progress bar ── */
.fef-tabs-progress{width:100%;height:3px;background:rgba(0,0,0,0.05);overflow:hidden;position:relative}
.fef-tabs-progress-bar{height:100%;width:0%;background:#3b82f6;transition:none}
.fef-tabs-progress-bar.fef-tabs-progress-running{transition:width linear}
.fef-tabs-progress-top{position:absolute;top:0;left:0;right:0;z-index:5}
.fef-tabs-progress-bottom{position:absolute;bottom:0;left:0;right:0;z-index:5}

/* ── Active tab bar indicator (border side) ── */
.fef-tabs-bar-left-side .fef-tabs-nav-item{border-left:3px solid transparent;transition:all 0.3s ease}
.fef-tabs-bar-right-side .fef-tabs-nav-item{border-right:3px solid transparent;transition:all 0.3s ease}
.fef-tabs-bar-top-side .fef-tabs-nav-item{border-top:3px solid transparent;transition:all 0.3s ease}
.fef-tabs-bar-bottom-side .fef-tabs-nav-item{border-bottom:3px solid transparent;transition:all 0.3s ease}

/* ── Chain slide: panels stacked for simultaneous animation ── */
.fef-tabs-chain .fef-tabs-body{position:relative;overflow:hidden}
.fef-tabs-chain .fef-tabs-panel{position:absolute;top:0;left:0;width:100%;opacity:0;pointer-events:none}
.fef-tabs-chain .fef-tabs-panel.fef-tabs-active{position:relative;opacity:1;pointer-events:auto}
@keyframes fefChainInLeft{from{transform:translateX(-100%);opacity:0}to{transform:translateX(0);opacity:1}}
@keyframes fefChainOutRight{from{transform:translateX(0);opacity:1}to{transform:translateX(100%);opacity:0}}
@keyframes fefChainInRight{from{transform:translateX(100%);opacity:0}to{transform:translateX(0);opacity:1}}
@keyframes fefChainOutLeft{from{transform:translateX(0);opacity:1}to{transform:translateX(-100%);opacity:0}}
@keyframes fefChainInTop{from{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}
@keyframes fefChainOutBottom{from{transform:translateY(0);opacity:1}to{transform:translateY(100%);opacity:0}}
@keyframes fefChainInBottom{from{transform:translateY(100%);opacity:0}to{transform:translateY(0);opacity:1}}
@keyframes fefChainOutTop{from{transform:translateY(0);opacity:1}to{transform:translateY(-100%);opacity:0}}