/* ============================================================
   HMAS splash screen — ThinkTac branded
   Design ported from Jigyaasa Teacher Corner, ThinkTac logo only.
   ============================================================ */

body ui-splash-screen,
body fuse-splash-screen,
body splash-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(160deg, #272B66 0%, #1a1c50 50%, #0f1035 100%);
    color: #F9FAFB;
    z-index: 999999;
    pointer-events: none;
    opacity: 1;
    visibility: visible;
    transition: opacity 400ms cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    font-family: 'Montserrat', 'Noto Sans', sans-serif;
}

/* Background decorative circles */
body ui-splash-screen .splash-circle,
body fuse-splash-screen .splash-circle {
    position: absolute;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}
body ui-splash-screen .splash-circle-lg,
body fuse-splash-screen .splash-circle-lg {
    width: 700px;
    height: 700px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}
body ui-splash-screen .splash-circle-md,
body fuse-splash-screen .splash-circle-md {
    width: 500px;
    height: 500px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}
body ui-splash-screen .splash-circle-sm,
body fuse-splash-screen .splash-circle-sm {
    width: 300px;
    height: 300px;
    border: 1px solid rgba(22, 156, 216, 0.18);
}

/* Gradient blobs */
body ui-splash-screen .splash-blob,
body fuse-splash-screen .splash-blob {
    position: absolute;
    border-radius: 50%;
}
body ui-splash-screen .splash-blob-blue,
body fuse-splash-screen .splash-blob-blue {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(22, 156, 216, 0.16) 0%, transparent 70%);
    top: -60px;
    right: 120px;
}
body ui-splash-screen .splash-blob-teal,
body fuse-splash-screen .splash-blob-teal {
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, rgba(4, 156, 216, 0.12) 0%, transparent 70%);
    bottom: -40px;
    left: 100px;
}

/* Dot grid overlay */
body ui-splash-screen .splash-dots,
body fuse-splash-screen .splash-dots {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
    background-size: 36px 36px;
}

/* Corner accents */
body ui-splash-screen .splash-corner,
body fuse-splash-screen .splash-corner {
    position: absolute;
    width: 64px;
    height: 64px;
}
body ui-splash-screen .splash-corner-tl,
body fuse-splash-screen .splash-corner-tl {
    top: 40px;
    left: 40px;
    border-top: 2px solid rgba(22, 156, 216, 0.4);
    border-left: 2px solid rgba(22, 156, 216, 0.4);
    border-radius: 4px 0 0 0;
}
body ui-splash-screen .splash-corner-tr,
body fuse-splash-screen .splash-corner-tr {
    top: 40px;
    right: 40px;
    border-top: 2px solid rgba(22, 156, 216, 0.4);
    border-right: 2px solid rgba(22, 156, 216, 0.4);
    border-radius: 0 4px 0 0;
}
body ui-splash-screen .splash-corner-bl,
body fuse-splash-screen .splash-corner-bl {
    bottom: 40px;
    left: 40px;
    border-bottom: 2px solid rgba(22, 156, 216, 0.4);
    border-left: 2px solid rgba(22, 156, 216, 0.4);
    border-radius: 0 0 0 4px;
}
body ui-splash-screen .splash-corner-br,
body fuse-splash-screen .splash-corner-br {
    bottom: 40px;
    right: 40px;
    border-bottom: 2px solid rgba(22, 156, 216, 0.4);
    border-right: 2px solid rgba(22, 156, 216, 0.4);
    border-radius: 0 0 4px 0;
}

/* Center content wrapper */
body ui-splash-screen .splash-content,
body fuse-splash-screen .splash-content {
    text-align: center;
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Logo (single ThinkTac mark) */
body ui-splash-screen .splash-logos,
body fuse-splash-screen .splash-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
}

/* Co-brand lockup — white ThinkTac + colour ISPF straight on the navy
   backdrop, no container (2026-06-04 trial — plaque version preserved
   in git history). */
body ui-splash-screen .splash-logo-pill,
body fuse-splash-screen .splash-logo-pill {
    background: transparent;
    border-radius: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 24px;
    box-shadow: none;
}

body ui-splash-screen .splash-logo-pill img,
body fuse-splash-screen .splash-logo-pill img {
    height: 64px;
    width: auto;
    max-width: 280px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.4));
}

/* Co-brand · hairline divider — soft white on the navy backdrop */
body ui-splash-screen .splash-cobrand-divider,
body fuse-splash-screen .splash-cobrand-divider {
    width: 1px;
    height: 52px;
    flex: 0 0 auto;
    background: linear-gradient(180deg,
        transparent 0%,
        rgba(255, 255, 255, 0.40) 25%,
        rgba(255, 255, 255, 0.40) 75%,
        transparent 100%);
}

/* ISPF mark — ORIGINAL teal/amber colours, no recolouring, no glow.
   Same plain dark drop-shadow as the ThinkTac mark beside it. */
body ui-splash-screen .splash-logo-pill img.splash-ispf,
body fuse-splash-screen .splash-logo-pill img.splash-ispf {
    height: 76px;
    background: transparent;
    border-radius: 0;
    padding: 0;
    filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.4));
    box-shadow: none;
}

body ui-splash-screen .splash-logo-fallback,
body fuse-splash-screen .splash-logo-fallback {
    display: none;
    height: 48px;
    align-items: center;
    justify-content: center;
    color: #272B66;
    font-weight: 800;
    font-size: 18px;
    letter-spacing: 0.05em;
}

/* Text */
body ui-splash-screen .splash-welcome,
body fuse-splash-screen .splash-welcome {
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    margin: 0 0 10px;
    font-family: 'Montserrat', sans-serif;
}

body ui-splash-screen .splash-title,
body fuse-splash-screen .splash-title {
    color: #FFFFFF;
    font-size: 40px;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0;
    line-height: 1.1;
    font-family: 'Montserrat', sans-serif;
}

body ui-splash-screen .splash-subtitle,
body fuse-splash-screen .splash-subtitle {
    color: rgba(255, 255, 255, 0.55);
    font-size: 15px;
    font-weight: 400;
    margin: 10px 0 0;
    letter-spacing: 0.04em;
}

/* Sky-blue accent line */
body ui-splash-screen .splash-accent-line,
body fuse-splash-screen .splash-accent-line {
    width: 56px;
    height: 3px;
    background: linear-gradient(90deg, #2EAEE5, #169CD8);
    border-radius: 2px;
    margin: 26px auto;
    box-shadow: 0 0 12px rgba(22, 156, 216, 0.55);
}

/* Loading dots (bouncing) */
body ui-splash-screen .spinner,
body fuse-splash-screen .spinner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 8px;
}

body ui-splash-screen .spinner > div,
body fuse-splash-screen .spinner > div {
    width: 9px;
    height: 9px;
    background-color: #2EAEE5;
    box-shadow: 0 0 10px rgba(22, 156, 216, 0.5);
    border-radius: 50%;
    display: inline-block;
    animation: hmas-bouncedelay 1.4s ease-in-out infinite both;
}

body ui-splash-screen .spinner .bounce1,
body fuse-splash-screen .spinner .bounce1 { animation-delay: -0.32s; }

body ui-splash-screen .spinner .bounce2,
body fuse-splash-screen .spinner .bounce2 { animation-delay: -0.16s; }

body ui-splash-screen .splash-loading-text,
body fuse-splash-screen .splash-loading-text {
    color: rgba(255, 255, 255, 0.35);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    margin: 16px 0 0;
}

@keyframes hmas-bouncedelay {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
    40%           { transform: scale(1);   opacity: 1; }
}

/* Lock scroll while splash is visible */
body:not(.ui-splash-screen-hidden):not(.fuse-splash-screen-hidden) {
    overflow: hidden;
}

/* Hide once Angular signals ready */
body.ui-splash-screen-hidden ui-splash-screen,
body.fuse-splash-screen-hidden fuse-splash-screen {
    visibility: hidden;
    opacity: 0;
}
