/* 
   Qylos - Premium Ticketing Platform 
   Design System: Dark Mode, Glassmorphism, Neon Accents
*/

:root {
    /* Color Palette */
    --bg-dark: #050511;
    /* Deepest Navy/Black */
    --bg-card: rgba(20, 20, 35, 0.6);
    --bg-glass: rgba(255, 255, 255, 0.03);

    --primary: #472470;
    /* Cadbury-style Purple */
    --primary-glow: #5e3194;
    --accent: #00DBDE;
    /* Cyan/Teal */
    --accent-glow: #22d3ee;

    --text-main: #ffffff;
    --text-muted: #94a3b8;

    --border-glass: rgba(255, 255, 255, 0.08);
    --shadow-glow: 0 0 20px rgba(109, 40, 217, 0.3);

    /* Typography */
    --font-main: 'Outfit', 'Inter', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;

    /* Radius */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Background Gradients/Orbs */
body::before {
    content: '';
    position: fixed;
    top: -20%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(109, 40, 217, 0.15) 0%, transparent 70%);
    filter: blur(80px);
    z-index: -1;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: -20%;
    right: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(0, 219, 222, 0.1) 0%, transparent 70%);
    filter: blur(80px);
    z-index: -1;
    pointer-events: none;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Typography Utilities */
.h1,
.h2,
.h3,
h1,
h2,
h3 {
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.h1 {
    font-size: 4rem;
}

.h2 {
    font-size: 2.5rem;
}

.h3 {
    font-size: 1.75rem;
}

.text-gradient {
    background: linear-gradient(135deg, var(--text-main), var(--text-muted));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-primary {
    background: linear-gradient(135deg, var(--accent), var(--primary));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Layout Utilities */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

.section {
    padding: var(--spacing-xl) 0;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section.revealed {
    opacity: 1;
    transform: translateY(0);
}

.flex {
    display: flex;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.flex-col {
    flex-direction: column;
}

.justify-between {
    justify-content: space-between;
}

.justify-center {
    justify-content: center;
}

.items-center {
    align-items: center;
}

.items-start {
    align-items: flex-start;
}

.flex-1 {
    flex: 1;
}

.flex-wrap {
    flex-wrap: wrap;
}

.gap-sm {
    gap: var(--spacing-sm);
}

.gap-md {
    gap: var(--spacing-md);
}

.grid {
    display: grid;
}

.grid-2 {
    grid-template-columns: 1fr 1fr;
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

/* Components */

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    border: 1px solid transparent;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-glow));
    color: white;
    box-shadow: 0 4px 15px rgba(109, 40, 217, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 30px rgba(109, 40, 217, 0.6);
}

.btn-primary:active {
    transform: translateY(-1px) scale(0.98);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-main);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--text-main);
    transform: translateY(-2px);
}

/* Glass Card */
.glass-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
    transform: rotate(30deg);
    transition: transform 0.6s ease;
    pointer-events: none;
}

.glass-card:hover::before {
    transform: rotate(30deg) translate(20%, 20%);
}

.glass-card:hover {
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(109, 40, 217, 0.2);
}

/* Tilt Card Effect */
.tilt-card {
    transition: transform 0.1s ease, box-shadow 0.1s ease;
    transform-style: preserve-3d;
    background: rgba(20, 20, 35, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.absolute-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
    opacity: 0.2;
    filter: blur(40px);
    z-index: -1;
    animation: pulse-glow 3s infinite alternate;
}

@keyframes pulse-glow {
    0% {
        opacity: 0.2;
        transform: translate(-50%, -50%) scale(1);
    }

    100% {
        opacity: 0.4;
        transform: translate(-50%, -50%) scale(1.2);
    }
}

.mock-notification {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    animation: float-y 4s ease-in-out infinite;
}

@keyframes float-y {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* Marquee */
.marquee-section {
    padding: var(--spacing-lg) 0;
    overflow: hidden;
    position: relative;
    background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.2), transparent);
}

.marquee-container {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
}

.marquee-container::before,
.marquee-container::after {
    content: '';
    position: absolute;
    top: 0;
    width: 150px;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.marquee-container::before {
    left: 0;
    background: linear-gradient(to right, var(--bg-dark), transparent);
}

.marquee-container::after {
    right: 0;
    background: linear-gradient(to left, var(--bg-dark), transparent);
}

.marquee-track {
    display: inline-block;
    animation: scroll 30s linear infinite;
}

.marquee-logo {
    display: inline-block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-muted);
    margin: 0 3rem;
    opacity: 0.5;
    transition: opacity 0.3s;
    letter-spacing: 2px;
}

.marquee-logo:hover {
    opacity: 1;
    color: var(--text-main);
    text-shadow: 0 0 10px var(--accent);
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Footer Extended */
.footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--text-main);
    text-decoration: underline;
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    /* Hidden on desktop */
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-toggle span {
    display: block;
    width: 100%;
    height: 3px;
    background: var(--text-main);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -8px);
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(5, 5, 17, 0.98);
    backdrop-filter: blur(20px);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    width: 80%;
}

.mobile-link {
    font-size: 1.5rem;
    font-weight: 600;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: var(--spacing-sm) 0;
    background: rgba(5, 5, 17, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-glass);
}

/* Ratings & Social Proof */
.rating-stars {
    color: #fbbf24;
    /* Amber/Gold */
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    border: 1px solid var(--border-glass);
    margin-top: 1rem;
    backdrop-filter: blur(10px);
}

.logo {
    font-family: 'Playball', cursive;
    font-size: 2.2rem;
    color: var(--text-main);
    text-shadow: 0 0 15px rgba(109, 40, 217, 0.5);
    display: flex;
    align-items: center;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--spacing-lg);
}

.hero-content {
    max-width: 600px;
}

.hero-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(109, 40, 217, 0.2);
    border: 1px solid rgba(109, 40, 217, 0.4);
    border-radius: 100px;
    color: var(--primary-glow);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.form-input {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-sm);
    color: var(--text-main);
    font-family: var(--font-main);
    transition: var(--transition-fast);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}

/* Utilities */
.w-full {
    width: 100%;
}

.text-center {
    text-align: center;
}

.mb-sm {
    margin-bottom: var(--spacing-sm);
}

.mb-md {
    margin-bottom: var(--spacing-md);
}

.mb-lg {
    margin-bottom: var(--spacing-lg);
}


/* Floating Details & Animations */
.floating-detail {
    position: absolute;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 8px 16px;
    border-radius: 50px;
    color: white;
    z-index: 5;
    white-space: nowrap;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 10px #10b981;
    animation: pulse-ring 2s infinite;
}

@keyframes pulse-ring {
    0% {
        transform: scale(0.8);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }

    100% {
        transform: scale(0.8);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

.animate-float {
    animation: float-y 4s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float-y 5s ease-in-out 1s infinite;
}

@keyframes float-y {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }
}

/* Event Card Polish */
.event-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.event-image-container img {
    transition: transform 0.8s ease;
}

.event-card:hover .event-image-container img {
    transform: scale(1.1);
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 900px) {
    .h1 {
        font-size: 3rem;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-md);
    }
}

@media (max-width: 768px) {
    .h1 {
        font-size: 2.5rem;
    }

    .h2 {
        font-size: 2rem;
    }

    .container {
        width: 92%;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    /* Hero Responsive: Image below text */
    .hero .grid-2 {
        display: flex;
        flex-direction: column;
        gap: 2rem;
    }

    .hero-content {
        order: 1;
        text-align: center;
    }

    .hero-visual {
        order: 2;
        width: 100%;
    }

    .hero .flex {
        justify-content: center;
    }

    .floating-detail {
        display: none;
        /* Hide on small mobile to stay clean */
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* Hero Responsive */
.hero {
    text-align: center;
    padding-top: 100px;
    /* More space for fixed nav */
    flex-direction: column;
    justify-content: center;
    /* Center content vertically if needed */
    min-height: auto;
    /* Allow flexible height on mobile */
    padding-bottom: var(--spacing-lg);
}

.hero .container.grid-2 {
    display: flex;
    flex-direction: column;
}

/* Move hero visual below content on mobile */
.hero-visual {
    order: 2;
    width: 100%;
    margin-top: var(--spacing-md);
}

.hero-content {
    order: 1;
    margin: 0 auto;
    padding: 0;
    margin-bottom: var(--spacing-md);
    max-width: 100%;
}

.flex-between {
    /* Keep logo and toggle aligned */
    display: flex;
    align-items: center;
    width: 100%;
}

/* Navbar Mobile Logic */
.desktop-only {
    display: none !important;
}

.mobile-menu-toggle {
    display: flex;
}

/* Adjust buttons in hero layout */
.hero .flex.gap-sm {
    justify-content: center;
    flex-wrap: wrap;
}

/* Dashboard Mobile */
@media (max-width: 768px) {
    .dashboard-container {
        flex-direction: column;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    min-width: 600px;
}

/* Chatbot Mobile */
.chatbot-window {
    width: 100%;
    height: 100vh;
    bottom: 0;
    right: 0;
    border-radius: 0;
    z-index: 10000;
}

.chatbot-toggle {
    bottom: 20px;
    right: 20px;
}

/* Chatbot Widget Styles */
.chatbot-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    font-family: var(--font-main);
}

.chatbot-toggle {
    width: 60px;
    height: 60px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(109, 40, 217, 0.5);
    transition: transform 0.3s ease;
}

.chatbot-toggle:hover {
    transform: scale(1.1);
}

.chatbot-toggle .icon {
    font-size: 24px;
    color: white;
}

.chatbot-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 450px;
    background: rgba(20, 20, 35, 0.95);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    display: none;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.chatbot-window.open {
    display: flex;
    opacity: 1;
    transform: translateY(0);
}

.chatbot-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-glow));
    padding: 15px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chatbot-header h4 {
    margin: 0;
    font-size: 1rem;
}

.chatbot-header .close-btn {
    cursor: pointer;
    font-size: 1.2rem;
}

.chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.9rem;
    line-height: 1.5;
    word-wrap: break-word;
}

.message.bot {
    background: rgba(255, 255, 255, 0.05);
    align-self: flex-start;
    color: var(--text-main);
    border-bottom-left-radius: 2px;
}

.message.user {
    background: var(--primary);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
    box-shadow: 0 2px 10px rgba(109, 40, 217, 0.2);
}

.message.typing {
    font-style: italic;
    opacity: 0.6;
    animation: chatbot-pulse 1s infinite alternate;
}

@keyframes chatbot-pulse {
    from {
        opacity: 0.4;
    }

    to {
        opacity: 0.8;
    }
}

.chatbot-input {
    padding: 15px;
    border-top: 1px solid var(--border-glass);
    display: flex;
    gap: 10px;
}

.chatbot-input input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    padding: 8px 12px;
    border-radius: 20px;
    color: white;
    outline: none;
}

.chatbot-input button {
    background: var(--accent);
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    color: black;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Dashboard Sidebar & Layout */
:root {
    --sidebar-width: 280px;
    --sidebar-collapsed-width: 80px;
}

.dashboard-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: var(--sidebar-width);
    background: rgba(15, 23, 42, 0.95);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    padding: 2rem 1rem;
    display: flex;
    flex-direction: column;
    transition: width 0.3s ease;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.sidebar.collapsed {
    width: var(--sidebar-collapsed-width);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 3rem;
    padding: 0 0.5rem;
}

.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    flex-grow: 1;
}

.nav-item {
    margin-bottom: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    color: #94a3b8;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(109, 40, 217, 0.1);
    color: #fff;
}

.nav-link.active {
    background: var(--primary);
    color: #fff;
}

.nav-link.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pro-badge {
    background: linear-gradient(135deg, #fbbf24, #d97706);
    color: #000;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: auto;
}

.main-content {
    flex-grow: 1;
    margin-left: var(--sidebar-width);
    padding: 2rem;
    transition: margin-left 0.3s ease;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 1rem;
}

@media (max-width: 768px) {
    .sidebar {
        width: var(--sidebar-collapsed-width);
    }

    .main-content {
        margin-left: var(--sidebar-collapsed-width);
    }

    .sidebar-logo span,
    .nav-link span,
    .pro-badge {
        display: none;
    }

    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .header-actions {
        width: 100%;
        justify-content: space-between;
        flex-wrap: wrap;
    }
}