:root{
  --bg:#0a1026;
  --bg-soft:#0c1732;
  --card:#0f1a2e;
  --text:#e6e8ef;
  --muted:#a6afc3;
  --primary:#6D28D9;
  --accent:#1e3a8a;
  --border: rgba(255,255,255,0.08);
  --fc-header-height: 88px;
}

/* ===== Base ===== */
body{
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: var(--bg) !important;
  color: var(--text) !important;
  padding-top: var(--fc-header-height);
}
a{ color: inherit; }
.section{ padding: 80px 0; }
.bg-darker{ background: var(--bg-soft); }

/* ===== Main header ===== */
.header-dark.sticky-top{
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1100;
  background: rgba(10,16,38,0.96);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 12px 30px rgba(0,0,0,0.28);
  backdrop-filter: blur(10px);
}

@media (max-width: 767.98px){
  :root{
    --fc-header-height: 76px;
  }
}

.header-dark .nav-link{
  color: var(--text);
}

.header-dark .nav-link:hover,
.header-dark .nav-link:focus{
  color: #ffffff;
}

.header-dark button.nav-link{
  appearance: none;
  background: transparent;
  border: 0;
  font: inherit;
}

/* ===== Cards & Buttons ===== */
.card{
  border-radius: 1rem;
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-primary{ background-color: var(--primary); border: none; }
.btn-primary:hover{ filter: brightness(1.05); }
.btn-outline-light{ border-color: rgba(255,255,255,0.2); color: var(--text); }
.btn-outline-light:hover{ background: rgba(255,255,255,0.08); }

/* ===== Crafting utility classes ===== */
.gradient-rule{
  height:3px;
  background:linear-gradient(90deg,var(--primary),var(--accent));
  border-radius:9999px;
  margin-top:6px;
}

.fc-pillwrap{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.fc-mb-12{ margin-bottom:12px; }
.fc-subhead{
  font-weight:700;
  font-size:.82rem;
  margin-bottom:6px;
  opacity:.9;
}

.joblink{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:44px;
  height:36px;
  padding:0 10px;
  border-radius:9999px;
  text-decoration:none;
  border:1px solid var(--border);
  background:var(--card);
  color:inherit;
  font-size:.85rem;
}
.joblink:hover{ filter:brightness(1.1); }

.chip{
  text-decoration:none;
  color:inherit;
  border:1px solid var(--border);
  padding:6px 10px;
  border-radius:9999px;
  background:var(--card);
}
.chip:hover{ filter:brightness(1.06); }

/* ===== Shared class filter buttons ===== */
.fc-class-filter-wrap{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:.85rem;
  flex-wrap:wrap;
  margin:0 0 1rem;
}

.fc-class-filter{
  display:inline-flex;
  text-decoration:none;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:.32rem;
  min-width:88px;
  padding:.7rem .85rem;
  border-radius:18px;
  border:1px solid #2b3a53;
  background:#0f172a;
  color:#e2e8f0;
  box-shadow:0 10px 24px rgba(0,0,0,.18);
  transition:transform .15s ease, opacity .15s ease, border-color .15s ease, background .15s ease;
}

.fc-class-filter:hover{
  transform:translateY(-1px);
  border-color:#5b6f96;
}

.fc-class-filter.is-active{
  background:#172033;
  border-color:#6d28d9;
  box-shadow:0 0 0 3px rgba(109,40,217,.16);
}

.fc-class-filter:not(.is-active){
  opacity:.55;
}

.fc-class-filter-icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:30px;
  height:30px;
}

.fc-class-filter-text{
  font-size:.92rem;
  font-weight:800;
  letter-spacing:.04em;
}

.fc-class-filter-img{
  width:28px;
  height:28px;
  object-fit:contain;
  display:block;
}

.fc-class-filter-label{
  font-size:.76rem;
  font-weight:700;
  letter-spacing:.02em;
  line-height:1;
}

.fc-filter-empty{
  display:none;
  text-align:center;
  margin-top:1rem;
  color:var(--muted);
}

/* ===== Crafting table header layout ===== */
.fc-itemhead{
  display:flex;
  align-items:center;
  gap:0;
  width:100%;
  justify-content:flex-start;
}
.fc-itemfilter{
  flex:1;
  display:flex;
  justify-content:flex-start;
}
.fc-col-narrow{ width:120px; }
.fc-col-wide{ width:30%; }
.fc-col-select{ width:64px; }
.fc-col-select .form-check-input{ cursor:pointer; }

.fc-sort-link{
  color:inherit;
  text-decoration:none;
  white-space:nowrap;
}
.fc-sort-link:hover{ filter:brightness(1.08); }

/* ===== Item filter (underline + icon, left aligned) ===== */
.fc-filter-wrap{
  display:inline-flex;
  align-items:center;
  justify-content:flex-start;
  gap:10px;
  margin-left:10px;
}
.fc-item-filter-input{
  background: transparent !important;
  border: 0 !important;
  border-bottom: 2px solid rgba(232,236,242,0.88) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  color: rgba(240,244,248,0.96) !important;
  text-align: left;
  width: 220px;
  max-width: 100%;
  padding: 3px 5px;
}
.fc-item-filter-input::placeholder{
  color: rgba(232,236,242,0.72) !important;
  opacity: 1;
}
.fc-item-filter-input:focus{
  outline:none !important;
  border:0 !important;
  border-bottom: 2px solid rgba(245,247,250,0.98) !important;
  box-shadow:none !important;
}
.fc-filter-icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color: rgba(232,236,242,0.82);
  opacity:1;
}
.fc-filter-icon svg{ display:block; }

/* ===== Gear sets list ===== */
.fc-ilvl-block{ margin-top: 6px; }
.fc-ilvl-title{ font-weight: 700; margin: 10px 0 8px; opacity: .95; }
.fc-ilvl-grid{ display:flex; flex-wrap:wrap; gap:10px; }
.fc-ilvl-pill{ opacity:.8; font-size: .9em; margin-left:6px; }

.gearset-link{
  display:inline-flex;
  align-items:center;
  padding:8px 12px;
  border-radius:9999px;
  border:1px solid var(--border);
  background:var(--card);
  text-decoration:none;
  color:inherit;
}
.gearset-link:hover{ filter:brightness(1.08); }

/* ===== Gear set list headers (expansion blocks) ===== */
.fc-exp-block{
  border:1px solid var(--border);
  background:var(--card);
  border-radius: 18px;
  padding: 14px 16px;
  margin-bottom: 14px;
}
.fc-exp-title{
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: .02em;
  margin-bottom: 4px;
}
.fc-exp-meta{
  color: var(--muted);
  font-size: .92rem;
}
.fc-exp-rule{
  height: 1px;
  margin: 10px 0 12px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  opacity: .35;
}
.fc-tier-list{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

/* ===== Gear set hover popup (weapon preview) ===== */
#fc-gearset-card{
  background: rgba(10,10,10,.95);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 14px;
  padding: 10px 12px;
  box-shadow: 0 10px 35px rgba(0,0,0,.6);
  max-width: 320px;
}
#fc-gearset-card .fc-gs-top{ display:flex; align-items:center; gap:10px; }
#fc-gearset-card .fc-gs-icon{ width:36px; height:36px; border-radius:8px; object-fit:cover; }
#fc-gearset-card .fc-gs-title{ font-weight:700; }
#fc-gearset-card .fc-gs-sub{ opacity:.8; font-size:.9em; margin-top:2px; }

/* ===== Collapsible Browse Panel ===== */
.fc-collapsible-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.fc-collapsible-toggle{
  appearance:none;
  background:transparent;
  border:1px solid var(--border);
  border-radius:9999px;
  width:38px;
  height:38px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:inherit;
  cursor:pointer;
}
.fc-collapsible-toggle:hover{ filter:brightness(1.1); }
.fc-arrow{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  transition: transform .15s ease;
}
.fc-collapsible.is-collapsed .fc-arrow{
  transform: rotate(-90deg);
}
.fc-collapsible-body{
  margin-top:10px;
}
.fc-collapsible.is-collapsed .fc-collapsible-body{
  display:none;
}

/* =========================================================
   FFXIV-Style Item Tooltip (#ff6-card)
   ========================================================= */
#ff6-card{
  position:fixed;
  z-index:10000;
  pointer-events:none;
  min-width:420px;
  max-width:560px;
  color:#e9e7e1;
  background:#2b2f35;
  border:3px solid rgba(0,0,0,.55);
  border-radius:10px;
  box-shadow:0 18px 48px rgba(0,0,0,.65), inset 0 0 0 1px rgba(255,255,255,.04);
  padding:12px 14px;
  transform: translateY(-6px);
  opacity:0;
  transition: opacity .12s ease, transform .12s ease;
  overflow:hidden;
}
#ff6-card.show{ opacity:1; transform: translateY(-10px); }

#ff6-card .ff6-top{
  display:flex !important;
  align-items: center;
  gap:10px;
  margin-bottom: 10px;
}
#ff6-card .ff6-icon{
  width:50px;
  height:50px;
  flex-shrink:0;
  object-fit:cover;
  image-rendering:pixelated;
  box-shadow:0 2px 10px rgba(0,0,0,.35);
}
#ff6-card .ff6-iconcol{
  width: 50px;
  min-width: 50px;
  flex: 0 0 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}
#ff6-card .ff6-uicat{
  margin-top: 6px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: rgba(230,232,239,0.85);
  text-align: center;
  max-width: 120px;
  line-height: 1.15;
  transform: translateX(4px);
}
#ff6-card .ff6-primary{
  margin-top: 8px;
  width: 100%;
}
#ff6-card .ff6-primary-wrap{
  position: relative;
  width: 100%;
  min-height: 28px;
}
#ff6-card .ff6-searchcat{
  position: absolute;
  left: 0;
  top: 0;
  width: 20%;
  padding-right: 10px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: rgba(230,232,239,0.85);
  text-align: left;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#ff6-card .ff6-primary-grid{
  display: grid;
  gap: 6px 8px;
  justify-items: end;
  align-items: start;
}
#ff6-card .ff6-primary-grid.cols-2{ grid-template-columns: repeat(2, auto); }
#ff6-card .ff6-primary-grid.cols-3{ grid-template-columns: repeat(3, auto); }
#ff6-card .ff6-stat{ text-align: right; }
#ff6-card .ff6-stat-label{
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: rgba(183,190,202,0.9);
  margin-bottom: 2px;
}
#ff6-card .ff6-stat-value{
  font-size: 13px;
  font-weight: 900;
  color: #ffffff;
}
#ff6-card .ffxiv-head{
  display:flex !important;
  flex-direction: column;
  justify-content: center;
  align-items:flex-start;
  height:auto;
  min-height:50px;
}
#ff6-card .ffxiv-name-row{
  display:flex !important;
  align-items:center;
  margin:0;
}
#ff6-card .ff6-title{
  font-weight:600;
  letter-spacing:.15px;
  font-size:18px;
  line-height:1.1;
  color:inherit;
  text-shadow:0 2px 0 rgba(0,0,0,.35), 0 0 10px rgba(0,0,0,.28);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
#ff6-card .ffxiv-sub{
  font-size:12px;
  color:#78ff88;
  font-weight:800;
  margin-top:2px;
}
#ff6-card .ffxiv-blackrule{ height:1px; background:#111; opacity:.8; margin:10px 0 8px; }
#ff6-card .ff6-desc{ font-size:12px; line-height:1.4; color:#d7d3c9; }
#ff6-card .ff6-section{
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.7px;
  font-weight:900;
  color:#f0d9aa;
  opacity:.95;
  margin-top:10px;
}
#ff6-card .ffxiv-whitebar{ height:1px; background:#fff; opacity:.85; margin:6px 0 8px; }
#ff6-card .ff6-grid{ display:grid; grid-template-columns:auto 1fr; gap:6px 12px; font-size:12px; }
#ff6-card .ff6-label{ color:#b7beca; }
#ff6-card .ff6-value{ color:#ffffff; font-weight:700; }
#ff6-card.rarity-1 .ff6-title{ color:#fafafa; }
#ff6-card.rarity-2 .ff6-title{ color:#64e291; }
#ff6-card.rarity-3 .ff6-title{ color:#63a9ff; }
#ff6-card.rarity-4 .ff6-title{ color:#c38cff; }
#ff6-card.rarity-7 .ff6-title{ color:#ff77b7; }

html.fc-home,
html.fc-home body{
  height: auto !important;
  min-height: 100% !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}
html.fc-home body{ position: relative; }
html.fc-home .container,
html.fc-home .section{ overflow: visible; }

.scroll-banner{
  width: 100%;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.03);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}
.scroll-banner .scroller{
  display: flex;
  width: max-content;
  will-change: transform;
  animation: fc-marquee 48s linear infinite;
}
.scroll-banner .scroller__inner{
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px 12px 0;
}
.scroll-banner img{
  width: clamp(220px, 30vw, 420px);
  height: clamp(125px, 18vw, 240px);
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(0,0,0,0.25);
}
@media (hover:hover){
  .scroll-banner:hover .scroller{ animation-play-state: paused; }
}
@keyframes fc-marquee{
  from{ transform: translateX(0); }
  to{ transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce){
  .scroll-banner .scroller{
    animation: none;
    transform: none;
  }
}

.search-box{
  margin: 0 auto;
  max-width: 980px;
}
.search-box .search-wrap{
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 12px;
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
  box-shadow: 0 16px 40px rgba(0,0,0,0.35);
}
.search-box .search-inner{
  display: flex;
  align-items: center;
  gap: 10px;
}
.search-box .search-inner > span{
  opacity: 0.9;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.35));
}
.search-box input[type="search"]{
  flex: 1;
  min-width: 220px;
  appearance: none;
  -webkit-appearance: none;
  background: rgba(10,16,38,0.55);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  padding: 12px 14px;
  color: var(--text);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.22);
}
.search-box input[type="search"]::placeholder{ color: rgba(166,175,195,0.88); }
.search-box input[type="search"]:focus{
  outline: none;
  border-color: rgba(109,40,217,0.70);
  box-shadow: 0 0 0 4px rgba(109,40,217,0.22), inset 0 0 0 1px rgba(0,0,0,0.22);
  background: rgba(10,16,38,0.75);
}
.search-box .search-btn{
  border: 0;
  border-radius: 14px;
  padding: 12px 16px;
  font-weight: 800;
  letter-spacing: 0.2px;
  color: var(--text);
  background: linear-gradient(90deg, var(--primary), var(--accent));
  box-shadow: 0 14px 28px rgba(0,0,0,0.35);
  white-space: nowrap;
  transition: transform 120ms ease, filter 120ms ease, box-shadow 120ms ease;
}
.search-box .search-btn:hover{
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(0,0,0,0.42);
}
.search-box .search-btn:active{
  transform: translateY(0);
  box-shadow: 0 12px 22px rgba(0,0,0,0.35);
}
.search-box .muted{ color: var(--muted) !important; }
.search-box a{
  text-decoration: none;
  border-bottom: 1px dotted rgba(255,255,255,0.28);
}
.search-box a:hover{ border-bottom-style: solid; }
@media (max-width: 576px){
  .search-box .search-inner{ flex-wrap: wrap; }
  .search-box input[type="search"]{ width: 100%; min-width: 0; }
  .search-box .search-btn{ width: 100%; }
}

#ff6-card .ff6-badges{
  position: absolute;
  top: 6px;
  right: 10px;
  left: auto;
  display: flex;
  gap: 4px;
  align-items: center;
  padding: 2px 4px;
  border-radius: 9999px;
  background: rgba(0,0,0,0.25);
  border: 1px solid rgba(255,255,255,0.10);
  z-index: 2;
}
#ff6-card .ff6-badge{
  width: 12px;
  height: 12px;
  object-fit: contain;
  display: block;
}
#ff6-card .ff6-divider-light{
  height: 3px;
  background: rgba(255,255,255,0.22);
  border-radius: 9999px;
  margin: 10px 0 8px;
}
#ff6-card .ff6-ilvlbar{
  width: 100%;
  background: rgba(0,0,0,0.55);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 8px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.4px;
  color: rgba(255,255,255,0.92);
  text-transform: none;
  margin-bottom: 4px;
}
#ff6-card .ff6-equipclass{
  font-size: 12px;
  font-weight: 800;
  color: rgba(230,232,239,0.92);
  margin-bottom: 4px;
}
#ff6-card .ff6-equiplvl{
  font-size: 12px;
  font-weight: 900;
  color: #78ff88;
  margin-bottom: 10px;
}
#ff6-card .ff6-materia-dots{
  display: inline-flex;
  gap: 6px;
  align-items: center;
  flex-wrap: nowrap;
}
#ff6-card .ff6-dot{
  width: 12px;
  height: 12px;
  border-radius: 9999px;
  border: 2px solid rgba(47, 220, 98, 0.95);
  background: transparent;
}
#ff6-card .ff6-dot.mat-dark{ background: rgba(38, 42, 52, 0.95); }
#ff6-card .ff6-dot.mat-light{ background: rgba(190, 194, 201, 0.95); }
#ff6-card .ff6-repairline{
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .2px;
  color: rgba(233,231,225,.92);
}
#ff6-card .ff6-repair-icon{
  width: 18px;
  height: 18px;
  object-fit: contain;
  image-rendering: auto;
  filter: drop-shadow(0 2px 2px rgba(0,0,0,.45));
}
#ff6-card .ff6-repair-lvl{ opacity: .95; }
#ff6-card .ff6-repair-text{ opacity: .9; }
#ff6-card .ff6-repair-divider{ margin-top: 10px; }
#ff6-card .ff6-postrepair{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 10px;
}
#ff6-card .ff6-postrepair-left{ font-size: 12px; color: rgba(230,232,239,0.9); }
#ff6-card .ff6-postrepair-right{ font-size: 12px; }
#ff6-card .ff6-pr-row{
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0;
}
#ff6-card .ff6-pr-key{ color: rgba(166,175,195,0.95); font-weight: 800; }
#ff6-card .ff6-pr-val{ color: rgba(230,232,239,0.98); font-weight: 900; text-align: right; white-space: nowrap; }
#ff6-card .ff6-postrepair{
  grid-template-columns: 1fr !important;
  gap: 0 !important;
  justify-items: start !important;
}
#ff6-card .ff6-postrepair-left{ display: none !important; }
#ff6-card .ff6-postrepair-right{
  grid-column: 1 / -1 !important;
  width: 100% !important;
  text-align: left !important;
}
#ff6-card .ff6-postrepair-right .ff6-pr-row{ justify-content: flex-start !important; }
#ff6-card .ff6-postrepair-right .ff6-pr-val{ text-align: left !important; }
#ff6-card .ff6-mat-title{
  margin-top:10px;
  font-size:12px;
  font-weight:900;
  color:#f0d9aa;
  letter-spacing:.2px;
}
#ff6-card .ff6-mat-line{
  margin-top:6px;
  font-size:12px;
  color:#e9e7e1;
  line-height:1.35;
}
#ff6-card .ff6-mat-recast{ text-align:left; margin-top:4px; margin-bottom:4px; }
#ff6-card .ff6-recast-label{
  font-size:11px;
  font-weight:900;
  letter-spacing:.7px;
  text-transform:uppercase;
  color:rgba(183,190,202,.95);
  line-height:1.1;
}
#ff6-card .ff6-recast-value{
  font-size:16px;
  font-weight:900;
  color:#ffffff;
  line-height:1.25;
  margin-top:2px;
}
#ff6-card .ff6-mat-shortbar{
  width:82px;
  height:5px;
  border-radius:999px;
  background:rgba(255,255,255,.82);
  margin:7px 0 8px;
}
#ff6-card .ff6-mat-fullbar{
  width:100%;
  height:2px;
  border-radius:999px;
  background:rgba(255,255,255,.84);
  margin:8px 0 10px;
}
#ff6-card .ff6-mat-desc{ margin-top:0; margin-bottom:10px; color:#d7d3c9; }
#ff6-card .ff6-mat-key{ font-weight:900; color:rgba(230,232,239,.96); }

/* ============================================================
   Recipe tree / crystal bar (recipe.html)
   ============================================================ */
#recipe-page .fc-crystal-bar{
  display:flex;
  align-items:center;
  gap:12px;
  flex-wrap:nowrap;
  overflow-x:auto;
  padding-bottom:4px;
}
#recipe-page .fc-selected-icons{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:nowrap;
  overflow-x:auto;
  padding-bottom:4px;
}
#recipe-page .fc-selected-icon{ display:inline-flex; align-items:center; text-decoration:none; }
#recipe-page .fc-selected-icon img{ width:34px; height:34px; border-radius:6px; }
#recipe-page .fc-crystal{ display:inline-flex; align-items:center; gap:6px; text-decoration:none; }
#recipe-page .fc-crystal img{ width:28px; height:28px; border-radius:6px; }
#recipe-page .fc-crystal-amt{ font-size:12px; opacity:.9; white-space:nowrap; }
#recipe-page .fc-tree-hidden{ display:none; }
#recipe-page #recipe-tree-table th,
#recipe-page #recipe-tree-table td{ padding-top: .35rem; padding-bottom: .35rem; }
#recipe-page tr.fc-have-checked{ background: rgba(122, 58, 237, 0.18) !important; }
#recipe-page tr.fc-have-checked:hover{ background: rgba(122, 58, 237, 0.24) !important; }
#recipe-page .fc-mat-cell{ display:flex; align-items:center; gap:6px; padding-left: calc(var(--depth, 0) * 16px); }
#recipe-page .fc-expand-btn{
  border:0;
  background:transparent;
  color:inherit;
  padding:0 2px;
  margin-left:4px;
  cursor:pointer;
  opacity:.9;
  line-height:1;
}
#recipe-page .fc-expand-btn::before{ content:'▸'; font-size: 28px; line-height:1; }
#recipe-page tr[data-expanded="1"] .fc-expand-btn::before,
#recipe-page .fc-expand-btn.is-expanded::before{ content:'▾'; }
#recipe-page .fc-expand-btn:focus{ outline:1px solid rgba(255,255,255,.35); border-radius:4px; }
#recipe-page .fc-node-icon{ width:34px; height:34px; border-radius:6px; }
#recipe-page .fc-col-usedin{ width: 104px; }
#recipe-page .fc-book-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:27px;
  height:27px;
  border-radius:8px;
  border:1px solid var(--border);
  background:rgba(255,255,255,0.04);
  color:var(--text);
  text-decoration:none;
  transition:filter 120ms ease, transform 120ms ease, background 120ms ease;
}
#recipe-page .fc-book-btn:hover{ background:rgba(255,255,255,0.09); filter:brightness(1.05); transform:translateY(-1px); }
#recipe-page .fc-book-btn svg{ width:25px; height:25px; display:block; }
#recipe-page .fc-item-static{ color:inherit; text-decoration:none; cursor:default; }

/* ===== Processing overlay (Craft Selected) ===== */
.fc-processing-overlay{
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(10,16,38,0.85);
  backdrop-filter: blur(2px);
}
.fc-processing-overlay.is-visible,
.fc-processing-overlay[aria-hidden="false"]{ display: flex; }
.fc-processing-box{
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px 20px;
  min-width: 240px;
  text-align: center;
  box-shadow: 0 12px 28px rgba(0,0,0,0.35);
}
.fc-spinner{
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 4px solid rgba(255,255,255,0.18);
  border-top-color: rgba(255,255,255,0.70);
  animation: fc-spin 0.9s linear infinite;
  margin: 0 auto 10px auto;
}
@keyframes fc-spin{ to { transform: rotate(360deg); } }
.fc-processing-text{ font-weight: 700; letter-spacing: 0.2px; color: var(--text); }

/* ===== Saved recipes modal ===== */
.fc-saved-dialog{ max-width: 900px; }
.fc-saved-content{
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--border);
}
.fc-saved-grid,
#fc-saved-list.fc-saved-grid,
#fc-saved-timers-list.fc-saved-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px 22px;
}
.fc-saved-grid.two-col,
#fc-saved-list.fc-saved-grid.two-col,
#fc-saved-timers-list.fc-saved-grid.two-col{ grid-template-columns: 1fr 1fr; }
.fc-saved-col{ display: flex; flex-direction: column; gap: 10px; }
.fc-saved-row{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}
a.fc-saved-link{
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
}
a.fc-saved-link:hover{ text-decoration: underline; }
button.fc-saved-del{
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.9);
  font-weight: 900;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
button.fc-saved-del:hover{ background: rgba(255,255,255,0.10); }
.fc-results-card{ position: relative; }
.fc-results-tools{
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 10px;
}
button.fc-icon-btn{
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.04);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
}
button.fc-icon-btn svg{
  width: 16px !important;
  height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
  display: block;
  fill: currentColor;
}
button.fc-icon-btn:hover{ background: rgba(255,255,255,0.08); }
button.fc-icon-btn:active{ transform: translateY(1px); }
button.fc-icon-btn[data-tooltip]{ position: relative; }
button.fc-icon-btn[data-tooltip]:hover::after{
  content: attr(data-tooltip);
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  background: var(--card);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 8px 10px;
  border-radius: 10px;
  white-space: nowrap;
  font-size: 12px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.35);
  z-index: 10;
}
button.fc-icon-btn[data-tooltip]:hover::before{
  content: "";
  position: absolute;
  right: 12px;
  top: calc(100% + 2px);
  width: 0;
  height: 0;
  border-left: 7px solid transparent;
  border-right: 7px solid transparent;
  border-bottom: 8px solid var(--card);
  filter: drop-shadow(0 -1px 0 var(--border));
  z-index: 10;
}
button.fc-save-btn[data-fc-tip]:hover::after{ content: attr(data-fc-tip); }
.fc-center-toast{
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%,-50%);
  z-index: 10000;
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
  min-width: 220px;
  text-align: center;
  box-shadow: 0 12px 28px rgba(0,0,0,0.35);
  opacity: 0;
  transition: opacity .15s ease;
  pointer-events: none;
}
.fc-center-toast.show{ opacity: 1; }
.fc-modal .modal-content{
  background: var(--card) !important;
  color: var(--text) !important;
  border: 1px solid var(--border) !important;
}
.fc-modal .modal-header,
.fc-modal .modal-footer{
  border-color: var(--border) !important;
  background: rgba(255,255,255,0.02) !important;
}
.fc-modal .modal-body{ background: var(--card) !important; }
.fc-modal .modal-title{ color: var(--text) !important; }
.fc-modal .btn-close{ filter: invert(1); opacity: 0.85; }
.fc-modal-dialog{ max-width: 1020px; }

/* ===== Gathering page (vendor + gather integration) ===== */
#gather-page .fc-selected-icon img{ width:51px; height:51px; border-radius:8px; }
#gather-page .fc-selected-icons{ display:flex; flex-wrap:wrap; gap:10px; }
#gather-page .fc-selected-icon{
  display:inline-flex;
  width:72px;
  height:72px;
  border-radius:14px;
  overflow:hidden;
  border:1px solid var(--border);
  background:rgba(255,255,255,0.03);
  box-shadow:0 8px 20px rgba(0,0,0,.18);
}
#gather-page .fc-selected-icon:hover{ filter:brightness(1.08); }
#gather-page .fc-node-icon{ width:100%; height:100%; object-fit:cover; display:block; }
#gather-page .fc-gather-search-card,
#gather-page .fc-gather-card{ border:1px solid var(--border); background:var(--card); box-shadow:0 10px 30px rgba(0,0,0,.18); }
#gather-page .fc-gather-badge-row{ display:flex; gap:8px; flex-wrap:wrap; }
#gather-page .chip{ border:1px solid var(--border); background:rgba(255,255,255,.04); color:var(--text); border-radius:9999px; padding:6px 10px; font-weight:600; }
#gather-page .fc-gather-note{ border-color:var(--border); background:rgba(255,255,255,.04); color:var(--text); }
#gather-page .fc-gather-toolbar{ display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:14px; }
#gather-page .fc-gather-btn{ min-width:96px; font-weight:700; }
#gather-page .fc-gather-btn.is-added{ box-shadow:0 0 0 3px rgba(109,40,217,.25); }
#gather-page .fc-gather-section{ margin-top:4px; }
#gather-page .fc-gather-section-title{ font-weight:800; letter-spacing:.02em; margin-bottom:10px; }
#gather-page .fc-gather-table{
  --bs-table-bg: transparent;
  --bs-table-striped-bg: rgba(255,255,255,.02);
  --bs-table-hover-bg: rgba(255,255,255,.04);
  --bs-table-border-color: rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
  overflow:hidden;
}
#gather-page .fc-gather-table th,
#gather-page .fc-gather-table td{ vertical-align:middle; }
#gather-page .fc-vendor-pager-meta{ color:var(--muted); font-size:.92rem; }
#gather-page .fc-vendor-nav-col,
#gather-page .fc-vendor-check-col{ width:48px; text-align:center; }
#gather-page .fc-vendor-nav{ min-width:34px; padding:2px 0; }
#gather-page .fc-vendor-check-col .form-check-input{ margin:0; width:18px; height:18px; cursor:pointer; }
#gather-page .fc-vendor-chipwrap{ display:flex; flex-wrap:wrap; gap:8px; }
#gather-page .fc-vendor-chip{
  display:inline-flex;
  align-items:center;
  border:1px solid rgba(255,255,255,.1);
  background:rgba(255,255,255,.04);
  color:var(--text);
  border-radius:9999px;
  padding:5px 10px;
  font-size:.9rem;
  line-height:1.2;
}
#gather-page .fc-vendor-chip.is-gil{ border-color:rgba(34,197,94,.35); }
#gather-page .fc-vendor-chip.is-tomestone{ border-color:rgba(59,130,246,.35); }
#gather-page .fc-map-link{ color:#c7d2fe; text-decoration:underline; text-underline-offset:2px; }
#gather-page .fc-map-link:hover{ color:#e0e7ff; }
@media (max-width: 767.98px){
  #gather-page .fc-gather-toolbar{ flex-direction:column; align-items:stretch; }
  #gather-page .fc-gather-btn{ width:100%; }
}

html.fc-home .fc-home-links-card,
html.fc-home .fc-home-links-card *{ pointer-events: none; }
html.fc-home .fc-home-links-card a,
html.fc-home .fc-home-links-card a *{ pointer-events: auto; }


/* =========================================================
   Extracted page styles from crafting.html
   ========================================================= */

/* --- crafting.html style block 1 (id="fc-crafting-loading-fallback-style") --- */
#fc-processing-overlay{position:fixed;inset:0;z-index:10050;display:none;align-items:center;justify-content:center;background:rgba(10,16,38,.82);backdrop-filter:blur(2px)}
#fc-processing-overlay[aria-hidden="false"],#fc-processing-overlay.is-visible{display:flex}
#fc-processing-overlay[aria-hidden="true"]{display:none!important}
#fc-processing-overlay .fc-processing-box{min-width:230px;padding:18px 20px;border-radius:14px;border:1px solid rgba(255,255,255,.10);background:var(--card,#0f1a2e);color:var(--text,#e6e8ef);box-shadow:0 18px 40px rgba(0,0,0,.35);text-align:center}
#fc-processing-overlay .fc-spinner{width:42px;height:42px;margin:0 auto 10px;border-radius:50%;border:4px solid rgba(255,255,255,.18);border-top-color:rgba(255,255,255,.78);animation:fc-crafting-spin .85s linear infinite}
#fc-processing-overlay .fc-processing-text{font-weight:800;letter-spacing:.02em}
@keyframes fc-crafting-spin{to{transform:rotate(360deg)}}


/* =========================================================
   Extracted page styles from indexxx.html
   ========================================================= */

/* --- indexxx.html style block 1 --- */
#fc-lodestone-news-banner{
  --fc-news-card-width:clamp(265px, 21vw, 330px);
  --fc-news-gap:16px;
  width:100%;
  max-width:calc((var(--fc-news-card-width) * 4) + (var(--fc-news-gap) * 3) + 24px);
  margin:0 auto;
  padding:12px;
  background:
    radial-gradient(circle at 12% 20%, rgba(109,40,217,.28), transparent 34%),
    radial-gradient(circle at 88% 78%, rgba(30,58,138,.34), transparent 42%),
    rgba(255,255,255,.03);
}
#fc-lodestone-news-banner .fc-lodestone-banner-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  padding:4px 6px 10px;
  color:var(--text,#e6e8ef);
}
#fc-lodestone-news-banner .fc-lodestone-banner-head>div:first-child{
  display:flex;
  flex-direction:column;
  gap:2px;
}
#fc-lodestone-news-banner .fc-lodestone-kicker{
  color:#bfdbfe;
  font-size:.78rem;
  font-weight:900;
  letter-spacing:.08em;
  text-transform:uppercase;
}
#fc-lodestone-news-banner .fc-lodestone-banner-head strong{
  font-size:1.02rem;
  letter-spacing:.02em;
}
#fc-lodestone-news-banner .fc-lodestone-head-actions{
  display:inline-flex;
  align-items:center;
  justify-content:flex-end;
  gap:.45rem;
  flex-wrap:nowrap;
}
#fc-lodestone-news-banner .fc-lodestone-banner-head a{
  color:#facc15;
  font-size:.82rem;
  font-weight:900;
  text-decoration:none;
  white-space:nowrap;
}
#fc-lodestone-news-banner .fc-lodestone-nav-btn{
  width:34px;
  height:34px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:11px;
  border:1px solid rgba(250,204,21,.45);
  background:rgba(15,23,42,.86);
  color:#facc15;
  font-size:1.05rem;
  font-weight:900;
  line-height:1;
  cursor:pointer;
  box-shadow:0 8px 18px rgba(0,0,0,.22);
  transition:background .15s ease,border-color .15s ease,filter .15s ease,transform .15s ease,opacity .15s ease;
}
#fc-lodestone-news-banner .fc-lodestone-nav-btn:hover:not(:disabled),
#fc-lodestone-news-banner .fc-lodestone-nav-btn:focus:not(:disabled){
  background:rgba(250,204,21,.14);
  border-color:rgba(250,204,21,.82);
  filter:brightness(1.08);
  outline:none;
  transform:translateY(-1px);
}
#fc-lodestone-news-banner .fc-lodestone-nav-btn:disabled{
  opacity:.38;
  cursor:not-allowed;
}
#fc-lodestone-news-banner .scroller{
  display:block !important;
  width:100% !important;
  min-width:0 !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  scroll-behavior:smooth;
  scroll-snap-type:x mandatory;
  overscroll-behavior-x:contain;
  -webkit-overflow-scrolling:touch;
  scrollbar-width:none;
  -ms-overflow-style:none;
  padding-bottom:0;
  animation:none !important;
  transform:none !important;
  will-change:auto !important;
}
#fc-lodestone-news-banner .scroller::-webkit-scrollbar{
  width:0;
  height:0;
  display:none;
}
#fc-lodestone-news-banner .scroller::-webkit-scrollbar-track,
#fc-lodestone-news-banner .scroller::-webkit-scrollbar-thumb{
  display:none;
}
#fc-lodestone-news-banner .scroller__inner{
  width:max-content;
  min-width:max-content;
  display:flex;
  align-items:stretch;
  gap:var(--fc-news-gap);
  padding:0 2px 2px 0;
}
@media (hover:hover){
  #fc-lodestone-news-banner:hover .scroller{
    animation:none !important;
  }
}
@media (prefers-reduced-motion: reduce){
  #fc-lodestone-news-banner .scroller{
    scroll-behavior:auto;
    animation:none !important;
  }
}
#fc-lodestone-news-banner .fc-lodestone-news-card{
  position:relative;
  display:flex;
  flex:0 0 var(--fc-news-card-width);
  flex-direction:column;
  width:var(--fc-news-card-width);
  min-height:clamp(162px, 18vw, 220px);
  overflow:hidden;
  scroll-snap-align:start;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.12);
  background:
    linear-gradient(135deg, rgba(15,23,42,.94), rgba(12,17,27,.98)),
    linear-gradient(90deg, rgba(109,40,217,.24), rgba(30,58,138,.24));
  box-shadow:0 16px 32px rgba(0,0,0,.34);
  color:var(--text,#e6e8ef);
  text-decoration:none;
  transition:transform .15s ease, border-color .15s ease, filter .15s ease;
}
#fc-lodestone-news-banner .fc-lodestone-news-card:hover,
#fc-lodestone-news-banner .fc-lodestone-news-card:focus{
  transform:translateY(-2px);
  border-color:rgba(250,204,21,.48);
  color:#fff;
  filter:brightness(1.05);
  outline:none;
}
#fc-lodestone-news-banner .fc-lodestone-browser{
  display:flex;
  align-items:center;
  gap:6px;
  min-height:30px;
  padding:7px 10px;
  border-bottom:1px solid rgba(255,255,255,.10);
  background:rgba(2,6,23,.48);
  color:#94a3b8;
  font-size:.68rem;
}
#fc-lodestone-news-banner .fc-lodestone-browser span{
  width:8px;
  height:8px;
  border-radius:999px;
  background:rgba(148,163,184,.55);
}
#fc-lodestone-news-banner .fc-lodestone-browser span:nth-child(1){background:rgba(248,113,113,.72)}
#fc-lodestone-news-banner .fc-lodestone-browser span:nth-child(2){background:rgba(250,204,21,.72)}
#fc-lodestone-news-banner .fc-lodestone-browser span:nth-child(3){background:rgba(74,222,128,.72)}
#fc-lodestone-news-banner .fc-lodestone-browser em{
  margin-left:4px;
  font-style:normal;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
#fc-lodestone-news-banner .fc-lodestone-card-body{
  display:flex;
  flex:1;
  flex-direction:column;
  padding:14px;
}
#fc-lodestone-news-banner .fc-lodestone-tag{
  display:inline-flex;
  width:max-content;
  max-width:100%;
  align-items:center;
  gap:.35rem;
  margin-bottom:10px;
  padding:.26rem .64rem;
  border-radius:999px;
  background:rgba(59,130,246,.16);
  border:1px solid rgba(96,165,250,.38);
  color:#bfdbfe;
  font-size:.72rem;
  font-weight:900;
  letter-spacing:.04em;
  text-transform:uppercase;
}
#fc-lodestone-news-banner .fc-lodestone-tag.is-maintenance{
  background:rgba(245,158,11,.16);
  border-color:rgba(251,191,36,.44);
  color:#fde68a;
}
#fc-lodestone-news-banner .fc-lodestone-tag.is-update{
  background:rgba(34,197,94,.14);
  border-color:rgba(74,222,128,.34);
  color:#bbf7d0;
}
#fc-lodestone-news-banner .fc-lodestone-title{
  display:-webkit-box;
  -webkit-box-orient:vertical;
  -webkit-line-clamp:3;
  overflow:hidden;
  min-height:3.6em;
  color:#f8fafc;
  font-size:1rem;
  font-weight:900;
  line-height:1.2;
}
#fc-lodestone-news-banner .fc-lodestone-date,
#fc-lodestone-news-banner .fc-lodestone-window{
  display:block;
  margin-top:8px;
  color:#cbd5e1;
  font-size:.78rem;
  line-height:1.3;
}
#fc-lodestone-news-banner .fc-lodestone-window{
  color:#fde68a;
  font-weight:800;
}
#fc-lodestone-news-banner .fc-lodestone-cta{
  display:block;
  margin-top:auto;
  padding-top:12px;
  color:#facc15;
  font-size:.78rem;
  font-weight:900;
}
#fc-lodestone-news-banner .is-placeholder .fc-lodestone-title,
#fc-lodestone-news-banner .is-placeholder .fc-lodestone-date,
#fc-lodestone-news-banner .is-placeholder .fc-lodestone-cta{
  opacity:.72;
}
#features.fc-home-search-section{
  padding-top:.35rem!important;
  padding-bottom:.75rem!important;
  margin-top:0!important;
  margin-bottom:0!important;
}
#features.fc-home-search-section .container{
  padding-top:0!important;
  padding-bottom:0!important;
}
#features.fc-home-search-section .search-box{
  margin-top:0!important;
  margin-bottom:0!important;
}
#features.fc-home-search-section .search-box .search-wrap{
  padding:8px!important;
}
#features.fc-home-search-section .search-box input[type="search"]{
  padding-top:10px!important;
  padding-bottom:10px!important;
}
#features.fc-home-search-section .search-box .search-btn{
  padding-top:10px!important;
  padding-bottom:10px!important;
}
#features.fc-home-search-section .fc-home-card-row{
  margin-top:.65rem!important;
}
@media (max-width:1200px){
  #fc-lodestone-news-banner{
    --fc-news-card-width:clamp(245px, 28vw, 315px);
  }
}
@media (max-width:576px){
  #fc-lodestone-news-banner{
    --fc-news-card-width:min(82vw, 330px);
  }
  #fc-lodestone-news-banner .fc-lodestone-banner-head{
    align-items:flex-start;
    flex-direction:column;
  }
  #fc-lodestone-news-banner .fc-lodestone-head-actions{
    width:100%;
    justify-content:flex-start;
  }
}
