/* Import Fonts */
@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@300;400;500;600;700;800;900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&display=swap');

/* Custom Styles for Obsidian Theme */
body {
    background-color: #050505;
    color: #e5e5e5;
    overflow-x: hidden;
    font-family: 'Barlow', ui-sans-serif, system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: 'cv02' 1, 'cv03' 1, 'cv04' 1, 'cv11' 1;
    font-optical-sizing: auto;
}

/* Ambient Glow Background */
.ambient-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background:
        radial-gradient(circle at 15% 50%, rgba(139, 92, 246, 0.08), transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(59, 130, 246, 0.08), transparent 25%);
    z-index: -1;
    pointer-events: none;
}

/* Monospace Font Utility */
.font-mono,
code,
pre {
    font-family: 'JetBrains Mono', ui-monospace, 'Courier New', monospace;
    font-feature-settings: 'liga' 1, 'calt' 1;
    letter-spacing: -0.01em;
}

/* Glassmorphism Card - Acrylic Style */
.glass-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(24px) saturate(200%);
    -webkit-backdrop-filter: blur(24px) saturate(200%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);
}

.glass-card:hover {
    border-color: rgba(139, 92, 246, 0.3);
    background: rgba(255, 255, 255, 0.05);
    -webkit-backdrop-filter: blur(28px) saturate(200%);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 0 30px rgba(139, 92, 246, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

/* Button Glow */
.btn-glow {
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.4);
    transition: all 0.3s ease;
}

.btn-glow:hover {
    box-shadow: 0 0 40px rgba(139, 92, 246, 0.7), 0 0 60px rgba(99, 102, 241, 0.4);
}

/* Text Gradient */
.text-gradient {
    background: linear-gradient(to right, #fff, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #050505;
}

::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Video Modal Animation */
#video-modal {
    animation: fadeIn 0.3s ease-out;
}

#video-modal>div {
    animation: slideUp 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Marquee Banner Animation */
.marquee-banner {
    background: linear-gradient(90deg,
            rgba(139, 92, 246, 0.15) 0%,
            rgba(59, 130, 246, 0.25) 50%,
            rgba(139, 92, 246, 0.15) 100%);
    border-bottom: 1px solid rgba(139, 92, 246, 0.3);
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.1);
}

.marquee-content {
    display: flex;
    animation: marquee 30s linear infinite;
    white-space: nowrap;
}

.marquee-item {
    display: inline-block;
    padding: 0 0.75rem;
    font-weight: 400;
    font-size: 0.875rem;
    line-height: 1.5;
    letter-spacing: 0.01em;
    color: #f3e8ff;
    text-shadow: 0 0 10px rgba(139, 92, 246, 0.3);
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Pause animation on hover */
.marquee-banner:hover .marquee-content {
    animation-play-state: paused;
}

/* Service Card with Image Background */
.service-card {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1;
    width: 96px;
    height: 96px;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 0.5px solid rgba(255, 255, 255, 0.06);
}

@media (min-width: 640px) {
    .service-card {
        width: 112px;
        height: 112px;
    }
}

@media (min-width: 1024px) {
    .service-card {
        width: 120px;
        height: 120px;
    }
}

.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(168, 85, 247, 0.2) 50%,
            rgba(0, 0, 0, 0.6) 100%);
    opacity: 0.8;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.service-card:hover::before {
    opacity: 0.6;
}

.service-card-bg {
    position: absolute;
    inset: 0;
    object-fit: cover;
    width: 100%;
    height: 100%;
    transition: transform 0.5s ease;
}

.service-card-content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding: 0;
}

.service-card-name {
    font-size: 0.75rem;
    font-weight: 600;
    text-align: center;
    color: #f3e8ff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8), 0 0 20px rgba(168, 85, 247, 0.5);
    margin-top: 0;
    transition: all 0.3s ease;
    line-height: 1.3;
    letter-spacing: 0.02em;
    padding: 0.625rem 0.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85), transparent);
    width: 100%;
}

@media (min-width: 1024px) {
    .service-card-name {
        font-size: 0.8125rem;
        line-height: 1.35;
    }
}

.service-card:hover .service-card-name {
    color: #ffffff;
    text-shadow: 0 2px 15px rgba(0, 0, 0, 0.9), 0 0 30px rgba(168, 85, 247, 0.8);
}

/* Prevent navbar glass-card from having hover effect */
#navbar .glass-card:hover {
    transform: none;
}

/* Mobile Menu Styles */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

#mobile-menu.active {
    max-height: 80vh;
    overflow-y: auto;
}

/* Custom scrollbar for mobile menu */
#mobile-menu::-webkit-scrollbar {
    width: 4px;
}

#mobile-menu::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 2px;
}

#mobile-menu::-webkit-scrollbar-thumb {
    background: rgba(168, 85, 247, 0.5);
    border-radius: 2px;
}

#mobile-menu::-webkit-scrollbar-thumb:hover {
    background: rgba(168, 85, 247, 0.7);
}

/* Mobile Language Dropdown */
.mobile-lang-menu {
    transition: all 0.3s ease-out;
}

.mobile-lang-menu.active {
    display: block !important;
}

.mobile-lang-icon {
    transition: transform 0.3s ease;
}

.mobile-lang-dropdown.active .mobile-lang-icon {
    transform: rotate(180deg);
}

/* Custom scrollbar for language dropdown */
.mobile-lang-menu::-webkit-scrollbar {
    width: 3px;
}

.mobile-lang-menu::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 2px;
}

.mobile-lang-menu::-webkit-scrollbar-thumb {
    background: rgba(168, 85, 247, 0.4);
    border-radius: 2px;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#mobile-menu.active .mobile-menu-content {
    animation: slideDown 0.3s ease-out;
}

/* Dashboard Member Styles */
.tab-button {
    color: #9ca3af;
    background: transparent;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 0.01em;
    border: 1px solid transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.tab-button:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
}

.tab-button.active {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.15) 0%, rgba(99, 102, 241, 0.15) 100%);
    border: 1px solid rgba(168, 85, 247, 0.25);
}

.tab-content {
    animation: fadeIn 0.3s ease-out;
}

/* Custom select dropdown */
select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%239ca3af' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

select option {
    background: #1a1a1a;
    color: #e5e5e5;
}

/* Input focus glow */
input:focus,
textarea:focus,
select:focus {
    outline: none;
}

/* Scrollbar for tables */
.overflow-x-auto::-webkit-scrollbar {
    height: 4px;
}

.overflow-x-auto::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 2px;
}

.overflow-x-auto::-webkit-scrollbar-thumb {
    background: rgba(168, 85, 247, 0.5);
    border-radius: 2px;
}

.overflow-x-auto::-webkit-scrollbar-thumb:hover {
    background: rgba(168, 85, 247, 0.7);
}

/* Sticky sidebar */
.sticky {
    position: sticky;
    top: 6rem;
}

/* Badge styles for transaction status */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.6875rem;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.02em;
}

.badge-success {
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.25);
}

.badge-warning {
    background: rgba(234, 179, 8, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(234, 179, 8, 0.25);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.badge-info {
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.25);
}

/* Loading overlay compatibility */
.js-loading-overlay-modal {
    backdrop-filter: blur(10px) !important;
}

/* Shadcn/UI inspired compact styles */
.glass-card {
    padding: 1rem;
}

@media (min-width: 768px) {
    .glass-card {
        padding: 1.25rem;
    }
}

/* Compact button styles */
button,
a.btn {
    font-size: 0.875rem;
    line-height: 1.5;
    font-weight: 500;
    letter-spacing: 0.01em;
}

/* Compact input styles */
input,
textarea,
select {
    font-size: 0.875rem;
    line-height: 1.5;
    letter-spacing: 0.005em;
}

/* Paragraph styles */
p {
    margin-bottom: 1em;
    line-height: 1.6;
}

p:last-child {
    margin-bottom: 0;
}

/* Small text */
small,
.text-sm {
    font-size: 0.875rem;
    line-height: 1.5;
}

.text-xs {
    font-size: 0.75rem;
    line-height: 1.5;
}

/* Base text */
.text-base {
    font-size: 1rem;
    line-height: 1.6;
}

/* Large text */
.text-lg {
    font-size: 1.125rem;
    line-height: 1.6;
}

.text-xl {
    font-size: 1.25rem;
    line-height: 1.5;
}

/* Compact heading styles with proper typography */
h1 {
    font-size: 1.875rem;
    line-height: 1.25;
    letter-spacing: -0.025em;
    font-weight: 700;
}

h2 {
    font-size: 1.5rem;
    line-height: 1.3;
    letter-spacing: -0.02em;
    font-weight: 600;
}

h3 {
    font-size: 1.125rem;
    line-height: 1.4;
    letter-spacing: -0.01em;
    font-weight: 600;
}

h4 {
    font-size: 1rem;
    line-height: 1.5;
    font-weight: 600;
}

h5 {
    font-size: 0.875rem;
    line-height: 1.5;
    font-weight: 600;
}

h6 {
    font-size: 0.75rem;
    line-height: 1.5;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

@media (min-width: 768px) {
    h1 {
        font-size: 2.25rem;
        line-height: 1.2;
        letter-spacing: -0.03em;
    }

    h2 {
        font-size: 1.875rem;
        line-height: 1.25;
        letter-spacing: -0.025em;
    }

    h3 {
        font-size: 1.25rem;
        line-height: 1.35;
        letter-spacing: -0.015em;
    }

    h4 {
        font-size: 1.125rem;
        line-height: 1.4;
    }
}

/* Auth Page Animations */
@keyframes gradient-x {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.animate-gradient-x {
    background-size: 200% 200%;
    animation: gradient-x 3s ease infinite;
}
