/*
Theme Name: NEFRIVO Modern Bathroom
Theme URI: https://www.shopagg.org/
Author: NexTrade Studio
Author URI: https://www.shopagg.org/
Description: Modern Bathroom Solutions for NEFRIVO — faucets, showers, accessories, valves and plumbing hardware.
Version: 1.0.0
License: MIT
Language: en
Text Direction: ltr
*/

/**
 * NexTrade B2B - Custom Styles for Tailwind CSS
 * 现代外贸企业官网主题
 * 主色来自后台「品牌颜色」区块（默认 teal / 青绿色系）
 */

/* ===== Base & Variables ===== */
:root {
  --brand-ink: #0f172a;
  --brand-muted: #475569;
  --brand-surface: #ffffff;
  --brand-border: #e2e8f0;
  --brand-accent: #0B1F33;
  --nex-accent: #0B1F33;
  --nex-accent-dark: #1B344A;
  --nex-ink: #0b1220;
  --nex-surface: #f6f8fb;
}

html,
body {
  max-width: 100%;
  overflow-x: clip;
}

body {
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  background-color: var(--nex-surface);
  color: var(--brand-ink);
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Plus Jakarta Sans", "Inter", "PingFang SC", system-ui, sans-serif;
  letter-spacing: -0.01em;
}

img,
video {
  max-width: 100%;
}

summary::-webkit-details-marker {
  display: none;
}

/* ===== NexTrade Utilities ===== */
.nex-container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  max-width: 80rem;
  padding-left: 1rem;
  padding-right: 1rem;
}

@media (min-width: 1024px) {
  .nex-container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

.nex-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--nex-accent);
}

.nex-section-title {
  font-size: 1.75rem;
  line-height: 1.2;
  font-weight: 800;
  color: var(--nex-ink);
}

@media (min-width: 1024px) {
  .nex-section-title {
    font-size: 2.25rem;
  }
}

.nex-divider {
  height: 4px;
  width: 3rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--nex-accent), var(--nex-accent-dark));
}

.nex-card {
  background: #ffffff;
  border: 1px solid var(--brand-border);
  border-radius: 1.25rem;
  box-shadow: 0 1px 2px rgba(11, 18, 32, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.nex-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(11, 18, 32, 0.1);
  border-color: color-mix(in srgb, var(--nex-accent) 40%, transparent);
}

.nex-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.75rem;
  padding: 0.8rem 1.6rem;
  background: linear-gradient(135deg, var(--nex-accent) 0%, var(--nex-accent-dark) 100%);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 10px 24px rgba(11, 31, 51, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.nex-btn-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);
  box-shadow: 0 16px 34px rgba(11, 31, 51, 0.32);
}

.nex-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.75rem;
  padding: 0.8rem 1.6rem;
  border: 1px solid var(--brand-border);
  color: var(--nex-ink);
  font-weight: 600;
  background: transparent;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.nex-btn-ghost:hover {
  border-color: var(--nex-accent);
  color: var(--nex-accent-dark);
  background: rgba(11, 31, 51, 0.05);
}

/* ===== NexTrade Header ===== */
.nex-topbar {
  background: var(--nex-ink);
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.82rem;
}

.nex-topbar a {
  color: rgba(255, 255, 255, 0.82);
  transition: color 0.2s ease;
}

.nex-topbar a:hover {
  color: #ffffff;
}

.nex-nav {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--brand-border);
}

.nex-nav-link {
  position: relative;
  color: #334155;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nex-nav-link:hover,
.nex-nav-link.is-active {
  color: var(--nex-accent-dark);
}

.nex-nav-link::after {
  content: "";
  position: absolute;
  left: 0.75rem;
  right: 100%;
  bottom: 0.1rem;
  height: 2px;
  border-radius: 999px;
  background: var(--nex-accent);
  transition: right 0.25s ease;
}

.nex-nav-link:hover::after {
  right: 0.75rem;
}

/* ===== NexTrade Footer ===== */
.nex-footer {
  background: var(--nex-ink);
  color: rgba(255, 255, 255, 0.72);
}

.nex-footer h4 {
  color: #ffffff;
  font-weight: 700;
}

.nex-footer a {
  color: rgba(255, 255, 255, 0.72);
  transition: color 0.2s ease;
}

.nex-footer a:hover {
  color: #ffffff;
}

/* ===== Hero overlay (teal tint) ===== */
.nex-hero-overlay {
  background: linear-gradient(105deg, rgba(11, 18, 32, 0.86) 0%, rgba(11, 31, 51, 0.35) 60%, rgba(27, 52, 74, 0.15) 100%);
}

/* ===== Stat card ===== */
.nex-stat {
  border-left: 3px solid var(--nex-accent);
}

/* ===== Typography ===== */
.line-clamp-1 {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ===== Hero Swiper ===== */
.hero-banner {
  min-height: 520px;
  height: clamp(520px, 45.4545vw, 900px);
}

.hero-banner .swiper,
.hero-banner .swiper-wrapper,
.hero-banner .swiper-slide {
  height: 100%;
}

.hero-swiper .swiper-button-prev,
.hero-swiper .swiper-button-next {
  background: rgba(255, 255, 255, 0.2);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  transition: background 0.2s;
}

.hero-swiper .swiper-button-prev:hover,
.hero-swiper .swiper-button-next:hover {
  background: rgba(255, 255, 255, 0.35);
}

.hero-swiper .swiper-button-prev::after,
.hero-swiper .swiper-button-next::after {
  font-size: 1rem;
  font-weight: bold;
  color: #fff;
}

.hero-swiper .swiper-pagination-bullet {
  background: rgba(255, 255, 255, 0.4);
  opacity: 1;
}

.hero-swiper .swiper-pagination-bullet-active {
  background: #fff;
}

/* ===== Swiper Thumbs ===== */
.thumbs-swiper .swiper-slide {
  opacity: 0.6;
  transition: opacity 0.2s;
}

.thumbs-swiper .swiper-slide-thumb-active {
  opacity: 1;
  border-color: var(--brand-accent) !important;
}

/* ===== Product Detail ===== */
.product-gallery .swiper-button-next,
.product-gallery .swiper-button-prev {
  width: 2rem !important;
  height: 2rem !important;
  margin-top: -1rem !important;
  border: 1px solid rgba(226, 232, 240, 0.95) !important;
  border-radius: 0.5rem !important;
  background: rgba(255, 255, 255, 0.92) !important;
  color: #334155 !important;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08) !important;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, opacity 0.18s ease;
}

.product-gallery .swiper-button-next {
  right: 0.75rem !important;
}

.product-gallery .swiper-button-prev {
  left: 0.75rem !important;
}

.product-gallery .swiper-button-next:hover,
.product-gallery .swiper-button-prev:hover {
  border-color: color-mix(in srgb, var(--brand-accent) 35%, transparent) !important;
  background: #fff !important;
  color: var(--brand-accent) !important;
}

.product-gallery .swiper-button-next::after,
.product-gallery .swiper-button-prev::after {
  font-size: 0.75rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
}

.product-gallery .swiper-button-disabled {
  opacity: 0.35 !important;
}

.product-gallery__thumb {
  aspect-ratio: 1 / 1;
  border: 2px solid transparent;
  border-radius: 0.5rem;
  background: #f1f5f9;
  opacity: 0.68;
  transition: border-color 0.18s ease, opacity 0.18s ease;
}

.product-gallery__thumb:hover {
  border-color: color-mix(in srgb, var(--brand-accent) 35%, transparent);
  opacity: 1;
}

.product-gallery .thumbs-swiper .swiper-slide-thumb-active {
  border-color: var(--brand-accent) !important;
  opacity: 1;
}

.product-detail-info__card {
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 transparent;
}

@media (min-width: 1024px) {
  .product-detail-info {
    position: sticky;
    top: 6rem;
    align-self: flex-start;
  }

  .product-detail-info__card {
    max-height: calc(100vh - 7rem);
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }
}

@media (max-width: 639px) {
  .product-gallery .swiper-button-next,
  .product-gallery .swiper-button-prev {
    width: 1.75rem !important;
    height: 1.75rem !important;
    margin-top: -0.875rem !important;
  }

  .product-gallery .swiper-button-next {
    right: 0.5rem !important;
  }

  .product-gallery .swiper-button-prev {
    left: 0.5rem !important;
  }

  .product-gallery .swiper-button-next::after,
  .product-gallery .swiper-button-prev::after {
    font-size: 0.68rem !important;
  }
}

/* ===== Smooth Scroll ===== */
html {
  scroll-behavior: smooth;
}

/* ===== Focus States ===== */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(11, 31, 51, 0.32);
  outline-offset: 2px;
}

/* ===== Mobile Menu Animation ===== */
#mobile-menu {
  transition: all 0.3s ease;
}

/* ===== Floating Contact ===== */
.site-float-contact {
  position: fixed;
  right: 1rem;
  bottom: calc(1rem + env(safe-area-inset-bottom));
  z-index: 45;
  display: flex;
  align-items: flex-end;
  gap: 0.75rem;
}

.site-float-contact__toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #0f172a 0%, #1B344A 100%);
  color: #fff;
  padding: 0.9rem 1.1rem;
  font-weight: 700;
  box-shadow: 0 22px 40px rgba(11, 31, 51, 0.28);
}

.site-float-contact__panel {
  width: min(320px, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  overflow-y: auto;
  border-radius: 1.5rem;
  padding: 1rem;
  background:
    radial-gradient(circle at top right, rgba(125, 211, 252, 0.3), transparent 36%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.98));
  border: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 28px 60px rgba(15, 23, 42, 0.18);
  backdrop-filter: blur(14px);
}

.site-float-contact__eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #1B344A;
  margin-bottom: 0.45rem;
}

.site-float-contact__title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  color: #0f172a;
}

.site-float-contact__desc {
  margin: 0.45rem 0 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: #475569;
}

.site-float-contact__group {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  margin-top: 1rem;
}

.site-float-contact__item {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.85rem 0.9rem;
  border-radius: 1rem;
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.site-float-contact__item:hover {
  transform: translateY(-1px);
  border-color: rgba(11, 31, 51, 0.45);
  box-shadow: 0 16px 32px rgba(11, 31, 51, 0.12);
}

.site-float-contact__icon {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e0f2fe 0%, #f8fafc 100%);
  color: #1B344A;
  flex-shrink: 0;
}

.site-float-contact__item--phone .site-float-contact__icon {
  background: linear-gradient(135deg, #0B1F33 0%, #1B344A 100%);
  color: #fff;
}

.site-float-contact__item--email .site-float-contact__icon {
  background: linear-gradient(135deg, #1B344A 0%, #A7ADB3 100%);
  color: #fff;
}

.site-float-contact__item--whatsapp .site-float-contact__icon {
  background: #1B344A;
  color: #fff;
}

.site-float-contact__item--address .site-float-contact__icon {
  background: linear-gradient(135deg, #ea580c 0%, #fb923c 100%);
  color: #fff;
}

.site-float-contact__item--telegram .site-float-contact__icon {
  background: #229ed9;
  color: #fff;
}

.site-float-contact__item--line .site-float-contact__icon {
  background: #06c755;
  color: #fff;
}

.site-float-contact__item--vk .site-float-contact__icon {
  background: #0077ff;
  color: #fff;
}

.site-float-contact__meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.site-float-contact__label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
}

.site-float-contact__value {
  color: #0f172a;
  font-size: 0.94rem;
  line-height: 1.45;
  word-break: break-word;
}

.site-float-contact__social {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1rem;
}

.site-float-contact__social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 2.75rem;
  padding: 0.35rem;
  border-radius: 999px;
  background: #fff;
  color: #0f172a;
  border: 1px solid rgba(226, 232, 240, 0.95);
  text-decoration: none;
  transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.site-float-contact__social-link:hover {
  transform: translateY(-1px);
  border-color: rgba(11, 31, 51, 0.45);
  color: #1B344A;
}

.site-float-contact__social-icon {
  width: 2.05rem;
  height: 2.05rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
}

.site-float-contact__social-text {
  font-size: 0.84rem;
  font-weight: 700;
  white-space: nowrap;
}

.site-float-contact__social-link {
  background-color: #ffffff;
}

.site-float-contact__social-link--facebook .site-float-contact__social-icon {
  background: linear-gradient(135deg, #1877f2 0%, #60a5fa 100%);
}

.site-float-contact__social-link--instagram .site-float-contact__social-icon {
  background: linear-gradient(135deg, #f97316 0%, #e4405f 55%, #8b5cf6 100%);
}

.site-float-contact__social-link--twitter .site-float-contact__social-icon {
  background: linear-gradient(135deg, #0f172a 0%, #1da1f2 100%);
}

.site-float-contact__social-link--linkedin .site-float-contact__social-icon {
  background: linear-gradient(135deg, #0a66c2 0%, #A7ADB3 100%);
}

.site-float-contact__social-link--youtube .site-float-contact__social-icon {
  background: linear-gradient(135deg, #dc2626 0%, #ff0000 100%);
}

.site-float-contact__social-link--tiktok .site-float-contact__social-icon {
  background: #0f172a;
}

.site-float-contact__social-link--pinterest .site-float-contact__social-icon {
  background: #bd081c;
}

.site-float-contact__social-link--reddit .site-float-contact__social-icon {
  background: #ff4500;
}

.site-float-contact__social-link--telegram .site-float-contact__social-icon {
  background: #229ed9;
}

.site-float-contact__social-link--discord .site-float-contact__social-icon {
  background: #5865f2;
}

.site-float-contact__social-link--quora .site-float-contact__social-icon {
  background: #b92b27;
}

.site-float-contact__cta {
  margin-top: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border-radius: 999px;
  padding: 0.9rem 1rem;
  background: linear-gradient(135deg, #1B344A 0%, #0f172a 100%);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 16px 32px rgba(11, 31, 51, 0.18);
}

@media (min-width: 1024px) {
  .site-float-contact {
    left: 0;
    right: auto;
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
    align-items: flex-start;
  }

  .site-float-contact__toggle {
    display: none;
  }

  .site-float-contact__panel {
    width: auto;
    max-width: none;
    max-height: none;
    overflow: visible;
    padding: 0.75rem 0.55rem;
    border-radius: 0 1.4rem 1.4rem 0;
    background:
      radial-gradient(circle at top right, rgba(56, 189, 248, 0.22), transparent 36%),
      linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.94));
    border-color: rgba(148, 163, 184, 0.18);
    box-shadow: 0 22px 50px rgba(15, 23, 42, 0.28);
  }

  .site-float-contact__eyebrow,
  .site-float-contact__title,
  .site-float-contact__desc,
  .site-float-contact__cta {
    display: none;
  }

  .site-float-contact__group {
    margin-top: 0;
    gap: 0.55rem;
  }

  .site-float-contact__item {
    width: 3.35rem;
    min-height: 3.35rem;
    padding: 0.38rem;
    border-radius: 999px;
    border-color: rgba(148, 163, 184, 0.16);
    box-shadow: none;
    overflow: hidden;
    white-space: nowrap;
  }

  .site-float-contact__item:hover {
    width: min(17rem, calc(100vw - 3rem));
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
  }

  .site-float-contact__icon {
    width: 2.6rem;
    height: 2.6rem;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.18);
  }

  .site-float-contact__item:hover .site-float-contact__icon {
    transform: scale(1.02);
  }

  .site-float-contact__meta {
    max-width: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-width 0.22s ease, opacity 0.18s ease;
  }

  .site-float-contact__item:hover .site-float-contact__meta {
    max-width: 11rem;
    opacity: 1;
  }

  .site-float-contact__label {
    color: #64748b;
  }

  .site-float-contact__value {
    max-width: 10.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .site-float-contact__social {
    margin-top: 0.55rem;
    flex-direction: column;
    gap: 0.55rem;
  }

  .site-float-contact__social-link {
    width: 3.15rem;
    min-height: 3.15rem;
    padding: 0.32rem;
    border-color: rgba(148, 163, 184, 0.14);
    overflow: hidden;
    box-shadow: none;
  }

  .site-float-contact__social-link:hover {
    width: min(13rem, calc(100vw - 3rem));
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
  }

  .site-float-contact__social-icon {
    width: 2.5rem;
    height: 2.5rem;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.18);
  }

  .site-float-contact__social-text {
    max-width: 0;
    opacity: 0;
    overflow: hidden;
    color: #0f172a;
    transition: max-width 0.22s ease, opacity 0.18s ease;
  }

  .site-float-contact__social-link:hover .site-float-contact__social-text {
    max-width: 7rem;
    opacity: 1;
  }
}

@media (max-width: 1023px) {
  .site-float-contact {
    right: 0.75rem;
    align-items: flex-end;
  }

  .site-float-contact__panel {
    position: absolute;
    right: 0;
    bottom: calc(100% + 0.75rem);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(0.75rem);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
  }

  .site-float-contact__social-link {
    padding-right: 0.9rem;
  }

  .site-float-contact.is-open .site-float-contact__panel {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }
}

@media (max-width: 767px) {
  .hero-banner {
    min-height: 430px;
    height: min(560px, calc(100svh - 4rem));
  }

  .hero-swiper .swiper-button-prev,
  .hero-swiper .swiper-button-next {
    display: none;
  }

  .site-float-contact__toggle {
    width: 3.25rem;
    height: 3.25rem;
    justify-content: center;
    padding: 0;
    box-shadow: 0 16px 32px rgba(11, 31, 51, 0.22);
  }

  .site-float-contact__toggle span {
    display: none;
  }

  .site-float-contact__panel {
    width: calc(100vw - 1.5rem);
    max-height: min(72vh, 32rem);
  }
}

/* ===== Print Styles ===== */
@media print {
  nav, footer, .no-print, .site-float-contact {
    display: none !important;
  }
  
  body {
    background: white;
  }
  
  .container {
    max-width: 100%;
  }
}

/* ===== High Contrast Mode Support ===== */
@media (prefers-contrast: high) {
  .bg-gradient-to-r {
    background: #1e293b !important;
  }
}

/* ===== Reduced Motion Support ===== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
