:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --bg-dark: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.05);
    --accent: #10b981;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
}

.app-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    z-index: 1;
}

/* Background Glows */
.bg-glow {
    position: fixed;
    width: 50vw;
    height: 50vw;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.15;
    z-index: -1;
    pointer-events: none;
}

.bg-glow-1 {
    top: -10%;
    right: -10%;
    background: radial-gradient(circle, var(--primary), transparent);
}

.bg-glow-2 {
    bottom: -10%;
    left: -10%;
    background: radial-gradient(circle, var(--accent), transparent);
}

/* Header */
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    color: var(--primary);
    width: 32px;
    height: 32px;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo-text span {
    color: var(--primary);
}

.header-tag {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

/* Glass Cards */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* Search Section */
.search-card {
    padding: 3rem;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

.search-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.input-group {
    position: relative;
    flex: 1;
}

.input-icon {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    width: 20px;
    height: 20px;
}

input {
    width: 100%;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.25rem 1.25rem 1.25rem 3.5rem;
    color: #fff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.form-row {
    display: flex;
    gap: 1rem;
}

.qty-group {
    max-width: 120px;
}

.qty-group input {
    padding-left: 3rem;
}

.promo-group {
    max-width: 180px;
}

.promo-group input {
    padding-left: 3rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.btn-primary {
    flex: 1;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 16px;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(79, 70, 229, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Results Section */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 2rem;
    padding: 0 0.5rem;
}

.status-info h2 {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
}

.stats {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.glass-select {
    background: var(--card-bg);
    color: #fff;
    border: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    border-radius: 12px;
    outline: none;
    cursor: pointer;
}

/* Ticket Grid */
.ticket-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.ticket-card {
    position: relative;
    padding: 1.5rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.ticket-card:hover {
    transform: translateY(-8px);
    border-color: rgba(99, 102, 241, 0.3);
    background: rgba(30, 41, 59, 0.9);
}

.ticket-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--accent);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    text-transform: uppercase;
}

.ticket-header {
    display: flex;
    gap: 1.5rem;
}

.label {
    display: block;
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 0.25rem;
}

.value {
    font-size: 1.25rem;
    font-weight: 700;
}

.price-container {
    margin-bottom: 0.5rem;
}

.price-original {
    margin-bottom: 0.25rem;
}

.original-price {
    font-size: 1rem;
    font-weight: 500;
    color: #ef4444;
    text-decoration: line-through;
    opacity: 0.8;
}

.price-discounted {
    display: flex;
    align-items: baseline;
    gap: 0.15rem;
}

.currency {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--accent);
}

.price-val {
    font-size: 2.25rem;
    font-weight: 700;
    color: #fff;
}

.per-ticket {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.discount-badge {
    display: inline-block;
    margin-top: 0.4rem;
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    border: 1px solid rgba(16, 185, 129, 0.25);
    letter-spacing: 0.5px;
}

.delivery-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.delivery-info svg {
    width: 16px;
    height: 16px;
}

.btn-view {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    text-decoration: none;
    padding: 0.8rem;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-view:hover {
    background: #fff;
    color: var(--bg-dark);
}

/* Loader */
.loader-container {
    display: flex;
    justify-content: center;
    padding: 4rem;
}

.custom-loader {
    width: 48px;
    height: 48px;
    border: 4px solid var(--primary);
    border-bottom-color: transparent;
    border-radius: 50%;
    animation: rotation 1s linear infinite;
}

@keyframes rotation {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hidden {
    display: none !important;
}

/* Mobile Adjustments */
@media (max-width: 640px) {
    .app-container { padding: 1rem; }
    .search-card { padding: 1.5rem; }
    h1 { font-size: 1.75rem; }
    .form-row { flex-direction: column; }
    .qty-group { max-width: none; }
}
