/* 精准拦截 Language Dropdown 模块的下拉框样式 */
.block-languagedropdownswitcher select,
#block-corecas-theme-languagedropdownswitcher select,
.lang-dropdown-form select {
  display: block !important;
  width: 165px !important; /* 匹配你在后台设定的 165px 宽度 */
  padding: 0.5rem 1.5rem 0.5rem 1rem !important;
  font-family: monospace !important;
  font-size: 0.75rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.1em !important;
  color: #e5e7eb !important; /* 文字浅灰 */
  background-color: #1e1f22 !important; /* Carbon Slate 碳灰 */
  border: 1px solid #374151 !important; /* 边框深灰 */
  border-radius: 0px !important; /* 严格直角，去圆角化 */
  appearance: none !important; /* 抹平原生丑陋样式 */
  -webkit-appearance: none !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
}

/* 鼠标悬浮特效 */
.block-languagedropdownswitcher select:hover,
#block-corecas-theme-languagedropdownswitcher select:hover,
.lang-dropdown-form select:hover {
  border-color: #1A56DB !important; /* 信任蓝边框 */
  color: #00E5FF !important; /* 青色发光字 */
  box-shadow: 0 0 12px rgba(26, 86, 219, 0.3) !important;
}

/* 为该模块表单包裹器添加相对定位和自定义三角箭头 */
.lang-dropdown-form {
  position: relative !important;
  display: inline-block !important;
}
.lang-dropdown-form::after {
  content: '▼' !important;
  font-size: 8px !important;
  color: #1A56DB !important;
  position: absolute !important;
  right: 12px !important;
  top: 50 !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  pointer-events: none !important;
}

/* ==========================================================================
   CoreCAS 智库/合规Sandbox 图片节点高级滤镜抛光
   ========================================================================== */
.corecas-article-banner img,
.field--name-field-article-media-image img {
  width: 100% !important;
  height: auto !important;
  max-height: 420px !important;
  object-fit: cover !important;
  /* 降低30%饱和度，拉高对比度，营造冷峻的学术风控感 */
  filter: grayscale(30%) contrast(110%) !important; 
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* 鼠标移入左轨头图区时，图片色彩丝滑复原并微微放大，拉满视觉交互 */
.corecas-article-banner:hover img {
  filter: grayscale(0%) contrast(100%) !important;
  transform: scale(1.015) !important;
}

/* 强制修正 Media 模块自带的段落间距干扰 */
.field--name-field-article-media-image {
  margin-bottom: 0 !important;
}
/* ==========================================================================
   CoreCAS Webform 工业级高转化线索表单重构样式
   ========================================================================== */

/* 1. 表单外层容器限宽与居中，防止大屏下横向无限拉伸 */
.webform-submission-inquiry-rfq-gateway-form {
  max-w-3xl;
  margin: 2rem auto;
  padding: 2.5rem;
  background-color: #050505;
  border: 1px solid #111111;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

@media (min-width: 768px) {
  .webform-submission-inquiry-rfq-gateway-form {
    margin: 4rem auto;
  }
}

/* 2. 表单字段组间距优化 */
.webform-submission-inquiry-rfq-gateway-form .form-item {
  display: flex;
  flex-direction: column;
  margin-bottom: 1.75rem;
}

/* 3. 标签（Labels）重塑：变更为严谨的微字重门禁风格 */
.webform-submission-inquiry-rfq-gateway-form label {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.75rem !important;
  font-weight: 700;
  text-transform: uppercase;
  tracking: 0.15em;
  color: #9ca3af; /* gray-400 */
  margin-bottom: 0.5rem;
}

/* 必填项红星标记微调 */
.webform-submission-inquiry-rfq-gateway-form label.form-required::after {
  content: " *";
  color: #0095ff; /* trust-blue */
  margin-left: 0.25rem;
}

/* 4. 输入框（Input & Textarea）核心图层重构：彻底告别刺眼白底 */
.webform-submission-inquiry-rfq-gateway-form input[type="text"],
.webform-submission-inquiry-rfq-gateway-form input[type="email"],
.webform-submission-inquiry-rfq-gateway-form textarea {
  width: 100%;
  background-color: #0a0a0a !important;
  border: 1px solid #262626 !important; /* gray-800 */
  color: #ffffff !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875rem;
  padding: 0.75rem 1rem;
  border-radius: 0px !important; /* 维持硬核直角 */
  transition: all 0.2s ease-in-out;
}

/* 只读状态控制（如自动锁定的 Target Product / CAS 字段） */
.webform-submission-inquiry-rfq-gateway-form input[readonly] {
  background-color: #111111 !important;
  border-color: #1f2937 !important;
  color: #00f3ff !important; /* cyan-glow 荧光激活色 */
  cursor: not-allowed;
  font-weight: 600;
}

/* 聚焦交互：注入深海微光（Focus Effects） */
.webform-submission-inquiry-rfq-gateway-form input:focus,
.webform-submission-inquiry-rfq-gateway-form textarea:focus {
  outline: none !important;
  border-color: #00f3ff !important; /* cyan-glow */
  box-shadow: 0 0 12px rgba(0, 243, 255, 0.25);
}

/* 5. 提交按钮（Submit Button）史诗级视觉强化 */
.webform-submission-inquiry-rfq-gateway-form .form-actions {
  margin-top: 2.5rem;
  border-top: 1px solid #111111;
  padding-top: 1.5rem;
}

.webform-submission-inquiry-rfq-gateway-form input[type="submit"] {
  width: 100%;
  background-color: #0095ff !important; /* trust-blue */
  color: #ffffff !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  padding: 1rem 2rem;
  border: 1px solid transparent !important;
  border-radius: 0px !important;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  box-shadow: 0 4px 20px rgba(0, 149, 255, 0.3);
}

.webform-submission-inquiry-rfq-gateway-form input[type="submit"]:hover {
  background-color: #1d4ed8 !important; /* 蓝调加深 */
  border-color: #00f3ff !important; /* 边缘闪烁亮青微光 */
  box-shadow: 0 4px 25px rgba(0, 243, 255, 0.4);
}
/* ==========================================================================
   CoreCAS /user/login 系统表单与本地化 Tabs 导航硬核重构
   ========================================================================== */

/* 1. 登录页面表单外层全局限宽、块级包裹 */
#user-login-form,
.user-register-form,
.user-pass-form {
  max-width: 28rem; /* max-w-md */
  margin: 4rem auto;
  padding: 2.5rem;
  background-color: #050505;
  border: 1px solid #111111;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* 2. 登录/注册/密码找回本地化 Tabs 导航重构（从垂直变为冷峻的水平直角页签） */
.tabs {
  max-width: 28rem;
  margin: 2rem auto -4rem auto; /* 锁定与下方表单的间距 */
  padding: 0;
  display: flex;
  list-style: none;
  border-bottom: 1px solid #111111;
}

.tabs li {
  margin-right: 0.25rem;
}

.tabs li a {
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.75rem 1rem;
  color: #4b5563; /* gray-600 */
  border: 1px solid transparent;
  border-bottom: none;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
}

/* 鼠标悬浮与当前激活状态（is-active）的高亮逻辑 */
.tabs li a:hover {
  color: #9ca3af; /* gray-400 */
}

.tabs li a.is-active {
  color: #00f3ff !important; /* cyan-glow */
  background-color: #050505;
  border-color: #111111;
  border-bottom: 1px solid #050505; /* 破开底线融合 */
  position: relative;
}

/* 3. 核心输入框（Username / Password）样式深度清洗，告别白底 */
#user-login-form .form-item,
.user-register-form .form-item,
.user-pass-form .form-item {
  display: flex;
  flex-direction: column;
  margin-bottom: 1.5rem;
}

#user-login-form label,
.user-register-form label,
.user-pass-form label {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #9ca3af;
  margin-bottom: 0.5rem;
}

#user-login-form input[type="text"],
#user-login-form input[type="password"],
.user-register-form input[type="text"],
.user-register-form input[type="email"],
.user-pass-form input[type="text"] {
  width: 100%;
  background-color: #0a0a0a !important;
  border: 1px solid #262626 !important;
  color: #ffffff !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875rem;
  padding: 0.75rem 1rem;
  border-radius: 0px !important; /* 保持硬核直角 */
  transition: all 0.2s ease-in-out;
}

#user-login-form input:focus,
#user-login-form input:focus,
.user-register-form input:focus {
  outline: none !important;
  border-color: #00f3ff !important;
  box-shadow: 0 0 12px rgba(0, 243, 255, 0.25);
}

/* 描述性文字（如密码强度、提示等）微调 */
#user-login-form .description,
.user-pass-form .description {
  font-size: 0.7rem;
  color: #4b5563;
  margin-top: 0.25rem;
}

/* 4. 登录按钮（Log in Submit）高强度科技蓝视觉对齐 */
#user-login-form .form-actions,
.user-register-form .form-actions,
.user-pass-form .form-actions {
  margin-top: 2rem;
}

#user-login-form input[type="submit"],
.user-register-form input[type="submit"],
.user-pass-form input[type="submit"] {
  width: 100%;
  background-color: #0095ff !important; /* trust-blue */
  color: #ffffff !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  padding: 0.875rem 2rem;
  border: 1px solid transparent !important;
  border-radius: 0px !important;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  box-shadow: 0 4px 20px rgba(0, 149, 255, 0.3);
}

#user-login-form input[type="submit"]:hover,
.user-register-form input[type="submit"]:hover,
.user-pass-form input[type="submit"]:hover {
  background-color: #1d4ed8 !important;
  border-color: #00f3ff !important;
  box-shadow: 0 4px 25px rgba(0, 243, 255, 0.4);
}


/* ==========================================================================
   CoreCAS 独立区块面包屑导航 (Primary Menu 区域专用抛光)
   ========================================================================== */

/* 1. 强行击穿 Primary Menu 的区域压制，将其完全平铺展开 */
#block-corecas-theme-breadcrumbs {
  display: block !important;
  width: 100% !important;
  clear: both !important; /* 斩断可能存在的浮动干扰 */
  margin: 1.5rem 0 1.5rem 0 !important; /* 给标题留出呼吸空间 */
  padding: 0 !important;
  background: transparent !important;
}

/* 2. 重塑底层 HTML 结构的弹性对齐 */
#block-corecas-theme-breadcrumbs nav[role="navigation"] ol {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* 3. 层级链接文本规范（微字号、等宽德系工业风） */
#block-corecas-theme-breadcrumbs nav[role="navigation"] li {
  display: inline-flex !important;
  align-items: center !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  font-size: 0.7rem !important;
  font-weight: 500 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
  color: #4b5563 !important; /* 当前页（未激活状态）：深灰 gray-600 */
}

/* 4. 历史层级超链接过渡 */
#block-corecas-theme-breadcrumbs nav[role="navigation"] li a {
  color: #9ca3af !important; /* 历史级：gray-400 */
  text-decoration: none !important;
  transition: color 0.2s ease-in-out !important;
}

/* 鼠标悬浮反馈 */
#block-corecas-theme-breadcrumbs nav[role="navigation"] li a:hover {
  color: #00e5ff !important; /* 亮青微光 */
}

/* 5. 利用伪元素，强行在物理节点间塞入工业级斜杠（/）分隔符 */
#block-corecas-theme-breadcrumbs nav[role="navigation"] li:not(:last-child)::after {
  content: "/" !important;
  font-size: 0.65rem !important;
  color: #262626 !important; /* 极暗灰隔离线 */
  margin: 0 0.75rem !important;
  font-weight: normal !important;
}

/* ==========================================================================
   5. Chemical Product (PDP) 专属组件分离与原生标签清洗
   ========================================================================== */

/* 强制隐藏 Drupal 原生渲染的字段标题 (彻底消灭 "Product Image" 等字眼) */
.corecas-chemical-node .field__label {
  display: none !important;
}

/* 清除 Drupal 原生 field__item 带来的多余间距 */
.corecas-chemical-node .field__item {
  margin: 0 !important;
  padding: 0 !important;
}

/* 右侧 CAS 高亮舱卡片样式 */
.chem-cas-card {
  background: linear-gradient(135deg, #111827 0%, #000000 100%);
  border: 1px solid #1f2937;
  padding: 1.5rem 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  position: relative;
  overflow: hidden;
  min-width: 250px;
}
.chem-cas-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 100%; height: 2px;
  background: #00f3ff;
}

/* 理化指标小卡片样式 */
.chem-spec-card {
  background-color: #050505;
  border: 1px solid #1f2937;
  padding: 1rem 1.25rem;
  transition: all 0.3s ease;
}
.chem-spec-card:hover {
  border-color: #4b5563;
  background-color: #0a0a0a;
}

/* ==========================================
   图片画廊重构 (完美处理单图/多图) 
   ========================================== */
.chem-product-gallery {
  width: 100%;
}
.chem-product-gallery .field__items {
  display: grid;
  /* 自动感应图片数量：单图时满宽，多图时自动切分为等宽网格 */
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.chem-product-gallery img {
  width: 100% !important;
  height: auto !important;
  object-fit: contain !important;
  border: 1px solid #1f2937;
  background-color: #050505;
  padding: 0.25rem;
}

/* 包装运输区图片容器 */
.chem-pkg-img-wrapper img {
  width: 100% !important;
  height: auto !important;
  object-fit: cover !important;
  filter: grayscale(15%) contrast(110%);
}

/* ==========================================================================
   6. Sourcing Router & CTA Buttons (询盘网关与转化按钮组)
   ========================================================================== */

/* 网关主容器 */
.chem-sourcing-router {
  border: 1px solid #1f2937;
  background-color: #050505;
  padding: 1.25rem 1.5rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
  z-index: 10;
}
/* 仅桌面端悬浮固钉效果 */
@media (min-width: 1024px) {
  .chem-sourcing-router.is-sticky {
    position: sticky;
    top: 1.5rem;
  }
}
/* 顶部发光蓝条 */
.chem-sourcing-router::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 100%; height: 2px;
  background-color: #0095ff;
}

/* 按钮布局排版 */
.chem-cta-group {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.chem-cta-subgroup {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

/* 按钮基础类 */
.chem-btn {
  display: block;
  width: 100%;
  text-align: center;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-weight: 700;
  text-transform: uppercase;
  transition: all 0.3s ease;
  cursor: pointer;
  box-sizing: border-box;
}

/* 高级意图：核心主推按钮 (Request Quote) */
.chem-btn--primary {
  background-color: #0095ff;
  color: #ffffff;
  padding: 0.875rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  box-shadow: 0 4px 15px rgba(0, 149, 255, 0.3);
  border: 1px solid transparent;
}
.chem-btn--primary:hover {
  background-color: #2563eb;
  box-shadow: 0 6px 20px rgba(0, 149, 255, 0.4);
}

/* 中低意图：幽灵次级按钮 (Request Sample / Request Info) */
.chem-btn--ghost {
  background-color: #0a0a0a;
  border: 1px solid #1f2937;
  color: #9ca3af;
  padding: 0.625rem;
  font-size: 0.625rem;
  letter-spacing: 0.05em;
}
.chem-btn--ghost:hover {
  border-color: #0095ff;
  color: #ffffff;
  background-color: #111;
}