:root {
    --app-loading-panel-bg: rgba(15, 23, 42, 0.9);
    --app-loading-panel-border: rgba(148, 163, 184, 0.35);
    --app-loading-text: #f8fafc;
    --app-loading-subtext: rgba(248, 250, 252, 0.75);
    --app-loading-accent: #38bdf8;
}

html, body {
    font-family: "Kanit", sans-serif;
    font-weight: 400;
    font-style: normal;
}

.orbitron-regular {
  font-family: "Orbitron", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

.orbitron-medium {
  font-family: "Orbitron", sans-serif;
  font-optical-sizing: auto;
  font-weight: 500;
  font-style: normal;
}

.orbitron-semibold {
  font-family: "Orbitron", sans-serif;
  font-optical-sizing: auto;
  font-weight: 600;
  font-style: normal;
}

.orbitron-bold {
  font-family: "Orbitron", sans-serif;
  font-optical-sizing: auto;
  font-weight: 700;
  font-style: normal;
}

.orbitron-extrabold {
  font-family: "Orbitron", sans-serif;
  font-optical-sizing: auto;
  font-weight: 800;
  font-style: normal;
}

.orbitron-black {
  font-family: "Orbitron", sans-serif;
  font-optical-sizing: auto;
  font-weight: 900;
  font-style: normal;
}

.kanit-thin {
  font-family: "Kanit", sans-serif;
  font-weight: 100;
  font-style: normal;
}

.kanit-extralight {
  font-family: "Kanit", sans-serif;
  font-weight: 200;
  font-style: normal;
}

.kanit-light {
  font-family: "Kanit", sans-serif;
  font-weight: 300;
  font-style: normal;
}

.kanit-regular {
  font-family: "Kanit", sans-serif;
  font-weight: 400;
  font-style: normal;
}

.kanit-medium {
  font-family: "Kanit", sans-serif;
  font-weight: 500;
  font-style: normal;
}

.kanit-semibold {
  font-family: "Kanit", sans-serif;
  font-weight: 600;
  font-style: normal;
}

.kanit-bold {
  font-family: "Kanit", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.kanit-extrabold {
  font-family: "Kanit", sans-serif;
  font-weight: 800;
  font-style: normal;
}

.kanit-black {
  font-family: "Kanit", sans-serif;
  font-weight: 900;
  font-style: normal;
}

.kanit-thin-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 100;
  font-style: italic;
}

.kanit-extralight-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 200;
  font-style: italic;
}

.kanit-light-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 300;
  font-style: italic;
}

.kanit-regular-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 400;
  font-style: italic;
}

.kanit-medium-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 500;
  font-style: italic;
}

.kanit-semibold-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 600;
  font-style: italic;
}

.kanit-bold-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 700;
  font-style: italic;
}

.kanit-extrabold-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 800;
  font-style: italic;
}

.kanit-black-italic {
  font-family: "Kanit", sans-serif;
  font-weight: 900;
  font-style: italic;
}

.b-bar-end ul {
    padding-top: 4px !important;
    padding-bottom: 4px !important;
}

.b-bar-start ul {
    padding-top: 4px !important;
    padding-bottom: 4px !important;
}

.app-loading-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(2, 6, 23, 0.8);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    z-index: 2147483647;
}

.app-loading-panel {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.75rem 2rem;
    border-radius: 1.5rem;
    border: 1px solid var(--app-loading-panel-border);
    background: var(--app-loading-panel-bg);
    box-shadow: 0 25px 60px -30px rgba(15, 23, 42, 0.85);
}

.app-loading-spinner {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 999px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--app-loading-accent);
    animation: app-loading-spin 0.9s linear infinite;
}

.app-loading-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.app-loading-text .title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--app-loading-text);
    letter-spacing: 0.02em;
}

.app-loading-text .subtitle {
    font-size: 0.9rem;
    color: var(--app-loading-subtext);
}

@keyframes app-loading-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.app-loading-panel--error {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
}

.app-loading-icon-error {
    color: #f87171;
}

.app-loading-button {
    margin-top: 0.5rem;
    padding: 0.625rem 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--app-loading-panel-border);
    background: rgba(56, 189, 248, 0.15);
    color: var(--app-loading-accent);
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
}

.app-loading-button:hover {
    background: rgba(56, 189, 248, 0.25);
}

.app-loading-button:active {
    transform: scale(0.97);
}

/* Remove padding from fullscreen modals to prevent overflow issues */
.b-modal {
    padding: 0 !important;
}

/* Hero editor tab styling */
.hero-tabs li a {
    border-radius: 0.375rem 0.375rem 0 0;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.hero-tabs li a:hover {
    background-color: rgba(13, 110, 253, 0.15);
}

.hero-tabs li a.border-primary-600,
.hero-tabs li a.border-primary-500 {
    background-color: #0d6efd !important;
    color: #ffffff !important;
    border-color: transparent !important;
    border-radius: 0.375rem 0.375rem 0 0;
}

/* Message dialog styling - right align buttons and improve appearance */
.modal-footer {
    justify-content: flex-end !important;
    gap: 0.5rem;
}

.modal-footer .btn + .btn {
    margin-left: 0.5rem;
}

#1p-live-region {
    display: none !important;
}

/* Blazor reconnection modal states */
.components-reconnect-hide > div {
    display: none;
}

#components-reconnect-modal.components-reconnect-show > div,
#components-reconnect-failed.components-reconnect-failed > div,
#components-reconnect-rejected.components-reconnect-rejected > div {
    display: flex;
}

/* Toast animations */
@keyframes toast-slide-in {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-slide-in {
    animation: toast-slide-in 0.3s ease-out;
}

/* Prefab ability tooltip styling */
.b-tooltip.prefab-ability-tooltip {
    max-width: 400px !important;
}

.b-tooltip.prefab-ability-tooltip .tooltip-inner {
    max-width: 400px !important;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    line-height: 1.5;
    text-align: left;
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3), 0 8px 10px -6px rgba(0, 0, 0, 0.2);
}