/* ==========================================================================
   Home: floating, draggable Gateway circle (27 Nov 2026).
   The same gold-ringed logo circle as the hero's "Click me", always on screen. Drag it anywhere; a tap opens the same
   "What is Gateway Educonnect?" popup as the hero circle. Markup: home-partitions/section1.blade.php (.gw-fab).
   Behaviour: public/user/js/gw-fab.js. Colours only from gateway-theme.css variables.
   ========================================================================== */
.gw-fab {
    position: fixed;
    left: 18px;
    top: 0;
    z-index: 9000;
    width: 68px;
    height: 68px;
    padding: 0;
    border-radius: 50%;
    border: 4px solid var(--gw-gold);
    background: radial-gradient(circle at 35% 30%, var(--gw-navy-light), var(--gw-navy) 70%);
    display: grid;
    place-items: center;
    cursor: grab;
    touch-action: none;                 /* lets a finger drag it instead of scrolling the page */
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    box-shadow: 0 0 0 5px rgba(var(--gw-gold-rgb), .22), 0 0 30px 4px rgba(var(--gw-gold-rgb), .6), 0 12px 28px rgba(0, 0, 0, .35);
    animation: gwFabGlow 2.6s ease-in-out infinite;
    transition: transform .2s ease, opacity .3s ease;
}
.gw-fab:not(.is-ready) { opacity: 0; pointer-events: none; }   /* shown by the script once it has placed the circle */
.gw-fab img { width: 36px; height: auto; display: block; pointer-events: none; -webkit-user-drag: none; }
.gw-fab::before {                        /* ripple ring */
    content: "";
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    border: 2px solid var(--gw-gold);
    animation: gwFabRing 2.4s ease-out infinite;
    pointer-events: none;
}
@keyframes gwFabGlow {
    0%, 100% { box-shadow: 0 0 0 5px rgba(var(--gw-gold-rgb), .2), 0 0 26px 3px rgba(var(--gw-gold-rgb), .55), 0 12px 28px rgba(0, 0, 0, .35); }
    50%      { box-shadow: 0 0 0 10px rgba(var(--gw-gold-rgb), .3), 0 0 56px 12px rgba(var(--gw-gold-rgb), .85), 0 12px 28px rgba(0, 0, 0, .35); }
}
@keyframes gwFabRing {
    0%   { transform: scale(1); opacity: .9; }
    100% { transform: scale(1.5); opacity: 0; }
}
.gw-fab:hover { transform: scale(1.07); }
.gw-fab:focus-visible { outline: 3px solid var(--gw-white); outline-offset: 5px; }
.gw-fab.is-dragging { cursor: grabbing; transform: scale(1.12); animation: none; transition: none;
    box-shadow: 0 0 0 10px rgba(var(--gw-gold-rgb), .32), 0 0 70px 16px rgba(var(--gw-gold-rgb), .9), 0 18px 34px rgba(0, 0, 0, .4); }
.gw-fab.is-dragging::before { display: none; }

/* little hint: first visit, and on hover / keyboard focus */
.gw-fab-tip {
    position: absolute;
    left: calc(100% + 12px);
    top: 50%;
    transform: translateY(-50%) translateX(-4px);
    padding: 8px 14px 7px;
    border-radius: 999px;
    background: var(--gw-navy);
    border: 1px solid rgba(var(--gw-gold-rgb), .6);
    box-shadow: 0 10px 22px rgba(0, 0, 0, .3);
    font: 600 13px/1.2 var(--gw-font);
    color: var(--gw-white);
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease, transform .25s ease;
}
.gw-fab.tip-left .gw-fab-tip { left: auto; right: calc(100% + 12px); transform: translateY(-50%) translateX(4px); }
.gw-fab:hover .gw-fab-tip, .gw-fab:focus-visible .gw-fab-tip, .gw-fab.show-tip .gw-fab-tip { opacity: 1; transform: translateY(-50%) translateX(0); }
.gw-fab.is-dragging .gw-fab-tip { opacity: 0; }

@media (max-width: 767.98px) {
    .gw-fab { width: 58px; height: 58px; border-width: 3px; }
    .gw-fab img { width: 30px; }
    .gw-fab-tip { font-size: 12px; padding: 7px 12px 6px; }
}
@media (prefers-reduced-motion: reduce) {
    .gw-fab, .gw-fab::before { animation: none; }
    .gw-fab { transition: none; }
}
@media print { .gw-fab { display: none; } }

.gw-fab-icon { display: block; width: 34px; height: 30px; overflow: hidden; }   /* the logo PNG: top part = the icon only */
.gw-fab-icon img { width: 34px; height: auto; display: block; pointer-events: none; -webkit-user-drag: none; }
@media (max-width: 767.98px) { .gw-fab-icon { width: 30px; height: 27px; } .gw-fab-icon img { width: 30px; } }

/* v2: bigger circle with the full lockup (icon + "Gateway Educonnect" as real text), like the header logo. */
.gw-fab { width: 104px; height: 104px; border-width: 5px; }
.gw-fab-icon { display: none; }
.gw-fab .gw-fab-brand { pointer-events: none; }
.gw-fab .gw-brand-icon { width: 50px; height: 44px; }
.gw-fab .gw-brand-icon img { width: 50px; }
.gw-fab .gw-brand-name { font-size: 12.5px; }
@media (max-width: 767.98px) {
    .gw-fab { width: 88px; height: 88px; border-width: 4px; }
    .gw-fab .gw-brand-icon { width: 42px; height: 37px; }
    .gw-fab .gw-brand-icon img { width: 42px; }
    .gw-fab .gw-brand-name { font-size: 10.5px; }
}
/* the lockup sits a touch higher and the name a touch smaller, so "Educonnect" clears the curve of the ring */
.gw-fab { padding-bottom: 8px; }
.gw-fab .gw-brand-icon { width: 46px; height: 41px; }
.gw-fab .gw-brand-icon img { width: 46px; }
.gw-fab .gw-brand-name { font-size: 11px; }
@media (max-width: 767.98px) {
    .gw-fab { padding-bottom: 6px; }
    .gw-fab .gw-brand-icon { width: 38px; height: 34px; }
    .gw-fab .gw-brand-icon img { width: 38px; }
    .gw-fab .gw-brand-name { font-size: 9.5px; }
}
