/* Shared TyeLock background — matches the Etsy Tools portal. */
html,
body {
    background-color: #05070c !important;
    background-image: none !important;
}

#root {
    background-color: transparent !important;
    background-image: none !important;
}

body {
    position: relative;
    isolation: isolate;
}

body::before,
body::after {
    content: "";
    position: fixed;
    border-radius: 50%;
    filter: blur(140px);
    opacity: 0.15;
    pointer-events: none;
    z-index: -1;
}

body::before {
    width: 500px;
    height: 500px;
    top: -100px;
    left: -100px;
    background: radial-gradient(circle, #c084fc, transparent 70%);
    animation: tyelock-float-purple 15s ease-in-out infinite alternate;
}

body::after {
    width: 600px;
    height: 600px;
    right: -100px;
    bottom: -150px;
    background: radial-gradient(circle, #38bdf8, transparent 70%);
    animation: tyelock-float-blue 20s ease-in-out infinite alternate;
}

.glow-orb {
    display: none !important;
}

.noise,
.app::before,
.app::after {
    display: none !important;
}

/* One consistent back action across every tool page. */
body:not(.preserve-page-back) .back-link:not(.btn-map-link) {
    position: fixed !important;
    top: 1rem !important;
    right: 1rem !important;
    left: auto !important;
    z-index: 10000 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.5rem !important;
    width: auto !important;
    min-height: 2.35rem !important;
    margin: 0 !important;
    padding: 0.55rem 1rem !important;
    border: 1px solid rgba(255, 255, 255, 0.07) !important;
    border-radius: 999px !important;
    background: rgba(255, 255, 255, 0.025) !important;
    color: #94a3b8 !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    cursor: pointer !important;
    transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease !important;
}

body:not(.preserve-page-back) .back-link:not(.btn-map-link):hover {
    color: #f8fafc !important;
    border-color: #818cf8 !important;
    background: rgba(99, 102, 241, 0.1) !important;
    transform: translateY(-2px) !important;
}

body:not(.preserve-page-back) .back-link:not(.btn-map-link):focus-visible {
    outline: 2px solid #818cf8 !important;
    outline-offset: 3px !important;
}

.tyelock-back-placeholder {
    display: inline-block;
    flex: 0 0 auto;
    visibility: hidden;
    pointer-events: none;
}
.tyelock-global-version {
    display: inline-flex;
    align-items: center;
    margin-left: 0.35rem;
    padding: 0.18rem 0.45rem;
    border: 1px solid rgba(129, 140, 248, 0.3);
    border-radius: 999px;
    background: rgba(99, 102, 241, 0.1);
    color: #a5b4fc;
    font-family: 'Inter', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.02em;
    vertical-align: middle;
}

.tyelock-global-footer {
    position: fixed;
    left: 50%;
    bottom: 0.45rem;
    z-index: 9000;
    display: inline-flex;
    align-items: center;
    transform: translateX(-50%);
    padding: 0.3rem 0.55rem;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 999px;
    background: rgba(5, 7, 12, 0.72);
    color: #64748b;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font-family: 'Inter', sans-serif;
    font-size: 0.68rem;
    line-height: 1;
    white-space: nowrap;
}
@media (max-width: 640px) {
    body:not(.preserve-page-back) .back-link:not(.btn-map-link) {
        top: 0.65rem !important;
        right: 0.65rem !important;
        min-height: 2.1rem !important;
        padding: 0.45rem 0.75rem !important;
        font-size: 0.75rem !important;
    }
}
@keyframes tyelock-float-purple {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(80px, 50px) scale(1.1); }
}

@keyframes tyelock-float-blue {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(-100px, -60px) scale(0.9); }
}

@media (prefers-reduced-motion: reduce) {
    body::before,
    body::after {
        animation: none;
    }
}

@media print {
    body::before,
    body::after,
    body:not(.preserve-page-back) .back-link:not(.btn-map-link),
    .tyelock-global-footer,
    .tyelock-global-version {
        display: none !important;
    }
}
