"use client";

import Image from "next/image";
import Link from "next/link";
import { FaArrowRight } from "react-icons/fa6";
import { LuGauge, LuZap, LuGitCompare, LuToggleRight, LuHistory, LuShieldCheck, LuExpand, LuNetwork } from "react-icons/lu";
import Breadcrumb from "@/components/Common/Breadcrumb";

export default function DualSourceMeterWl4040Detail() {
  const featureList = [
    {
      title: "Dual EB & DG Registers",
      desc: "Features isolated, independent internal registers designed to strictly separate utility grid consumption from standby Diesel Generator energy logs.",
      icon: <LuGitCompare className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "Intelligent Source Sensing",
      desc: "Equipped with a hardware sensing input loop that instantly triggers automatic display profile switching as soon as raw source selection changes.",
      icon: <LuToggleRight className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "Class 1 & 0.5 Revenue Grade",
      desc: "Delivers highly accurate cost allocation matching Class 1 (IEC 62053-21) and precision sub-billing Class 0.5 (IEC 62053-22) system profiles.",
      icon: <LuGauge className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "True RMS Measurement",
      desc: "Provides completely accurate calculations over highly distorted generator wave profiles using continuous True RMS math sampling cycles.",
      icon: <LuZap className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "Programmable Reverse Lock",
      desc: "Allows site supervisors to toggle positive-only energy accumulation modes or enable reverse lock constraints to eliminate tamper vulnerabilities.",
      icon: <LuShieldCheck className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "Smart Unit Auto-Scaling",
      desc: "Streamlines data visualization through automatic layout transitions scaling display ranges across Kilo, Mega, and Giga engineering metrics.",
      icon: <LuExpand className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "Historical Log Preservation",
      desc: "Retains an isolated 'Old Register' data space to safeguard previously cleared consumption data blocks for immediate manual audit validation.",
      icon: <LuHistory className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    },
    {
      title: "Optional RS485 Integration",
      desc: "Supports an optional, high-performance RS485 communication port structure to stream separate dual-source diagnostics to automation networks.",
      icon: <LuNetwork className="w-5 h-5 text-cyan-500 group-hover:text-white transition-colors duration-300" />
    }
  ];

  return (
    <>
      <Breadcrumb
        pageName="WL4040 Dual Source Meters"
        description="WL4040 Dual Source Meters are an elite dual-registry diagnostic platform engineered to simultaneously supervise, compute, and segregate energy consumption values between common Electricity Board (EB) infrastructure and standby Diesel Generator (DG) power units."
      />

      {/* 👑 Large Workstation Structural Engine: Locked with solid white canvas base */}
      <div className="bg-white text-slate-800 py-16 lg:py-24 xl:py-28 3xl:py-32 selection:bg-cyan-100 selection:text-cyan-900 w-full">
        <div className="container mx-auto px-4 max-w-7xl 2xl:max-w-[1440px] 3xl:max-w-[1560px]">

          {/* ─── HERO DESCRIPTION & ASSET SECTOR ────────────────────── */}
          <div className="grid grid-cols-1 lg:grid-cols-2 gap-12 xl:gap-16 items-center mb-24 3xl:mb-32">

            {/* Left Block: Core Product Technical Data */}
            <div className="space-y-6 order-2 lg:order-1">
              {/* <span className="inline-flex items-center gap-1.5 rounded-full bg-slate-50 px-4 py-1.5 text-xs font-bold tracking-wider text-slate-600 uppercase border border-slate-200/60">
                <span className="h-2 w-2 rounded-full bg-cyan-500 animate-pulse" />
                Automated Utility vs Generator Apportionment
              </span> */}

              <h1 className="text-3xl md:text-4xl xl:text-5xl 3xl:text-6xl font-black tracking-tight text-slate-900 leading-tight">
                WL4040 Dual Source Meters <br />
                <span className="text-cyan-500 font-extrabold text-xl md:text-2xl xl:text-3xl 3xl:text-4xl block mt-2">
                  Coordinated Grid &amp; Genset Consumption Analytics
                </span>
              </h1>

              <div className="space-y-4 text-slate-600 text-sm md:text-base xl:text-lg leading-relaxed font-semibold">
                <p>
                  The <strong className="text-slate-900 font-bold">WL4040 Series Dual Source Meter</strong> is an elite dual-registry diagnostic platform engineered to simultaneously supervise, compute, and segregate energy consumption values between common Electricity Board (EB) infrastructure and standby Diesel Generator (DG) power units.
                </p>
                <p>
                  Equipped with an integrated digital energy pulse LED indication system, this instrument eliminates subpanel data overlapping by continuously calculating raw Voltage (V), Current (A), Frequency (F), Active Power (kW), Apparent Power (kVA), Power Factor (PF), absolute system On-Hours, and isolated dual-source Active Energy (kWh) registers. The controller natively adjusts its firmware profiles to accommodate 3-Phase 4-Wire, 3-Phase 3-Wire, or 1-Phase load layouts on-site.
                </p>
              </div>
            </div>

            {/* Right Block: Pure White Image Frame with refined shadow projection */}
            <div className="order-1 lg:order-2 flex justify-center">
              <div className="relative w-full max-w-[440px] xl:max-w-[500px] 3xl:max-w-[540px] aspect-[4/3] rounded-3xl bg-white p-6 border border-slate-200/80 shadow-[0_8px_30px_rgba(0,0,0,0.015)] group hover:border-cyan-300 transition-all duration-300 flex items-center justify-center">
                <div className="relative w-full h-full min-h-[260px] xl:min-h-[300px]">
                  <Image
                    src="/images/Knudsen/dual-source-wl4040.jpg"
                    alt="WL4420 Advanced Digital LCD Multifunction Electrical Parameter Analyzer Face"
                    fill
                    priority
                    className="object-contain filter drop-shadow-[0_6px_16px_rgba(0,0,0,0.02)] group-hover:scale-102 transition-transform duration-500"
                    sizes="(max-width: 768px) 100vw, (max-width: 1440px) 500px, 540px"
                  />
                </div>
              </div>
            </div>
          </div>

          {/* ─── GRID BLOCK: COMPREHENSIVE ENGINE FEATURES (Clean White Matrix Layout) ─── */}
          <div className="mb-24 xl:mb-32">
            <h2 className="text-xl xl:text-2xl font-bold text-slate-900 mb-8 flex items-center gap-3 border-b border-slate-100 pb-4">
              <span className="h-5 w-1 rounded-full bg-cyan-500" />
              Core Engineering &amp; Architectural Features
            </h2>

            <div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-6 xl:gap-8">
              {featureList.map((feat, idx) => (
                <div
                  key={idx}
                  className="bg-white text-slate-800 rounded-2xl p-6 xl:p-8 transition-all duration-300 border border-slate-200/80 hover:border-cyan-300 hover:shadow-[0_15px_40px_rgba(6,182,212,0.03)] flex flex-col justify-between group"
                >
                  <div>
                    <div className="flex items-center justify-between mb-4">
                      <h3 className="text-sm xl:text-base font-black text-slate-900 tracking-tight">{feat.title}</h3>
                      {/* Micro-Vector vector transition link block mapping */}
                      <div className="p-2.5 bg-slate-50 border border-slate-200/60 shadow-2xs rounded-xl transition-all duration-300 group-hover:bg-cyan-500 group-hover:border-cyan-500 group-hover:text-white text-cyan-500">
                        {feat.icon}
                      </div>
                    </div>
                    <p className="text-xs xl:text-sm text-slate-500 leading-relaxed font-semibold">
                      {feat.desc}
                    </p>
                  </div>
                </div>
              ))}
            </div>
          </div>

          {/* ─── CALL TO ACTION FRAME: ENQUIRY CTA (Premium Uniform White Card) ─── */}
          <div className="flex justify-center">
            <Link href="/contact"
              className="inline-flex items-center gap-2 bg-cyan-500 hover:bg-cyan-600 text-white text-xs xl:text-sm font-bold px-10 py-4 rounded-full transition-all duration-200 active:scale-95 shadow-md shadow-cyan-500/10 w-full sm:w-auto justify-center uppercase tracking-wider"
            >
              Send Enquiry
              <FaArrowRight className="w-3.5 h-3.5" />
            </Link>
          </div>

        </div>
      </div>
    </>
  );
}