"use client";
import type { CSSProperties } from "react";
import "./loader.css";
export type BrandLoaderProps = { loading:boolean; fullscreen?:boolean; logoSrc:string; label?:string; className?:string };
/** Three campus nodes light in turn before the gateway opens. Uses actual application readiness. */
export function BrandLoader({loading,fullscreen=true,logoSrc,label="Loading AcadNexus",className=""}:BrandLoaderProps){
 if(!loading)return null;
 const style={"--brand-loader-primary":"#007F77","--brand-loader-secondary":"#E5B64D","--brand-loader-ink":"#082F50","--brand-loader-paper":"#F5FAFA","--brand-loader-mark-size":"70px","--brand-loader-mark-pos":"65.0px"} as CSSProperties;
 return <div className={["brand-loader",fullscreen?"brand-loader--fullscreen":"brand-loader--inline",className].join(" ")} style={style} role="status" aria-live="polite" aria-busy="true" data-brand={"AcadNexus"}>
 <span className="brand-loader__stage" aria-hidden="true"><span className="brand-loader__scene" dangerouslySetInnerHTML={{__html:"<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"200\" height=\"200\" viewBox=\"0 0 1000 1000\" data-motion-profile=\"acadnexus\" aria-hidden=\"true\"><defs><clipPath id=\"clear-acadnexus\"><path clip-rule=\"evenodd\" d=\"M0 0H1000V1000H0Z M275 275V725H725V275Z\"/></clipPath></defs><g clip-path=\"url(#clear-acadnexus)\"><g class=\"identity-grammar\"><circle cx=\"170\" cy=\"750\" r=\"34\" stroke=\"#E5B64D\" fill=\"none\" stroke-width=\"16\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"campus\" class=\"identity-stroke\" style=\"--phase:0.000s\"/><circle cx=\"400\" cy=\"750\" r=\"34\" stroke=\"#E5B64D\" fill=\"none\" stroke-width=\"16\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"expert\" class=\"identity-stroke\" style=\"--phase:0.095s\"/><circle cx=\"640\" cy=\"750\" r=\"34\" stroke=\"#E5B64D\" fill=\"none\" stroke-width=\"16\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"employer\" class=\"identity-stroke\" style=\"--phase:0.190s\"/><path d=\"M170 750V420Q170 230 360 230H760\" stroke=\"#007F77\" fill=\"none\" stroke-width=\"18\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"campus-bridge\" class=\"identity-stroke\" style=\"--phase:0.285s\"/><path d=\"M400 750V530Q400 360 570 360H760\" stroke=\"#E5B64D\" fill=\"none\" stroke-width=\"18\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"expert-bridge\" class=\"identity-stroke\" style=\"--phase:0.380s\"/><path d=\"M640 750V640Q640 500 780 500H890\" stroke=\"#007F77\" fill=\"none\" stroke-width=\"18\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"employer-bridge\" class=\"identity-stroke\" style=\"--phase:0.475s\"/><path d=\"M110 790H890\" stroke=\"#082F50\" fill=\"none\" stroke-width=\"12\" stroke-linecap=\"round\" stroke-linejoin=\"round\" pathLength=\"1\" data-motif-key=\"shared-ground\" class=\"identity-stroke\" style=\"--phase:0.570s\"/><circle class=\"identity-traveller\" r=\"19\" fill=\"#E5B64D\" stroke=\"#F5FAFA\" stroke-width=\"6\"><animateMotion dur=\"1.46s\" repeatCount=\"indefinite\" path=\"M170 750V420Q170 230 360 230H760\" calcMode=\"paced\"/></circle></g></g></svg>"}}/><img className="brand-loader__mark" src={logoSrc} width={70} height={70} alt=""/></span><span className="brand-loader__label">{label}</span></div>;
}
export default BrandLoader;
