/* ============================================
   Next-Gen QR Code Master - Styles
   ============================================ */

* {
    font-family: 'Inter', sans-serif;
}

body {
    background: #0a0919;
    min-height: 100vh;
}

/* ========== Hero Section ========== */
.hero-section {
    position: relative;
    height: 400px;
    margin-bottom: -120px;
    border-radius: 20px;
    overflow: hidden;
    z-index: 0;
    margin-top: -80px;
}

.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('img/Qreative-03.jpg');
    background-size: cover;
    background-position: bottom;
    background-blend-mode: overlay;
    filter: blur(30px);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 4;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    animation: fadeIn 0.6s ease-out;
}

/* ========== Glassmorphic Cards ========== */
.glass-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

.glass-card:hover {
    border-color: rgba(139, 92, 246, 0.3);
    transition: all 0.3s ease;
}

/* ========== Custom Scrollbar ========== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

::-webkit-scrollbar-thumb {
    background: rgba(139, 92, 246, 0.5);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(139, 92, 246, 0.7);
}

/* ========== QR Code Container ========== */
#qrcode {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    padding: 32px;
    background: #f3f4f6;
    border-radius: 12px;
}

#qrcode canvas,
#qrcode img {
    box-shadow: none;
    max-width: 100%;
    height: auto;
}

/* ========== Gradient Backgrounds ========== */
.gradient-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* ========== Animations ========== */
@keyframes successPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

.success-animation {
    animation: successPulse 0.6s ease-in-out;
}

.toast {
    border: 1px solid rgba(139, 92, 246, 0.35);
    background: rgba(15, 23, 42, 0.92);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
    animation: fadeIn 0.25s ease-out;
}

.toast-success {
    border-color: rgba(16, 185, 129, 0.5);
}

.toast-warning {
    border-color: rgba(245, 158, 11, 0.6);
}

.toast-info {
    border-color: rgba(56, 189, 248, 0.6);
}

.toast-icon {
    font-size: 22px;
    color: #34d399;
}

.toast-warning .toast-icon {
    color: #fbbf24;
}

.toast-info .toast-icon {
    color: #38bdf8;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease-out;
}

/* ========== Input Styles ========== */
input[type="text"],
input[type="url"],
input[type="tel"],
textarea {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    transition: all 0.3s ease;
}

select {
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e2e8f0;
    transition: all 0.3s ease;
}

select option {
    background: #1e293b;
    color: #e2e8f0;
}

input[type="text"]:focus,
input[type="url"]:focus,
input[type="tel"]:focus,
textarea:focus,
select:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(139, 92, 246, 0.5);
    outline: none;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

select:focus {
    background: rgba(30, 41, 59, 0.95);
}

/* ========== Button Styles ========== */
.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(139, 92, 246, 0.4);
}

/* ========== Modal Backdrop ========== */
.modal-backdrop {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
}

.confirm-card {
    border: 1px solid rgba(139, 92, 246, 0.35);
    background: rgba(15, 23, 42, 0.95);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}

.confirm-card.info {
    border-color: rgba(56, 189, 248, 0.6);
}

.confirm-card.warning {
    border-color: rgba(245, 158, 11, 0.6);
}

.confirm-card .fa-info-circle {
    color: #38bdf8;
}

.confirm-card .fa-exclamation-circle {
    color: #fbbf24;
}

/* ========== History Grid ========== */
.history-item {
    cursor: pointer;
    transition: all 0.3s ease;
}

.history-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(139, 92, 246, 0.4);
}

.history-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    max-height: 360px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 4px;
}

.history-thumb {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 10px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.06);
}

.history-meta {
    min-width: 0;
}

/* ========== Toggle Switch ========== */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    transition: .4s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

/* ========== Tooltip ========== */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 200px;
    background-color: rgba(30, 41, 59, 0.95);
    color: #e2e8f0;
    text-align: center;
    border-radius: 6px;
    padding: 8px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 12px;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* ========== Bulk Generation Grid ========== */
.bulk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 16px;
}

.bulk-qr-item canvas,
.bulk-qr-item img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

