/* AI CAMBO - Modern CSS Styling */

/* Import Kantumruy Pro Font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Kantumruy+Pro:wght@300;400;500;600;700&display=swap');

/* CSS Variables - Dark Theme Colors (KHQR Style) */
:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #8b5cf6;
    --accent-color: #ec4899;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --success-color: #10b981;
    
    /* Dark Theme Colors */
    --bg-dark: #0f172a;
    --bg-dark-light: #1e293b;
    --bg-card: #1a1a2e;
    --bg-card-light: #16213e;
    --text-light: #e2e8f0;
    --text-muted: #94a3b8;
    --border-dark: rgba(255, 255, 255, 0.1);
    
    --dark-color: #0f172a;
    --light-color: #1e293b;
    --white: #ffffff;
    --border-radius: 16px;
    --box-shadow: 0 4px 20px rgba(99, 102, 241, 0.25);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Kantumruy Pro', 'Khmer OS Siemreap', 'Khmer OS', Arial, sans-serif;
    line-height: 1.8;
    color: var(--text-light);
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-dark-light) 100%);
    background-attachment: fixed;
    font-weight: 400;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Kantumruy Pro', 'Khmer OS Siemreap', 'Khmer OS', Arial, sans-serif;
    font-weight: 700;
    line-height: 1.3;
    color: var(--white);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: rgba(26, 26, 46, 0.95);
    border-bottom: 1px solid var(--border-dark);
    color: var(--white);
    padding: 1.2rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(20px);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    color: var(--white);
}

.logo img {
    height: 50px;
    width: auto;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.2));
    transition: var(--transition);
}

.logo:hover img {
    transform: scale(1.05);
}

.logo-text h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
    font-family: 'Kantumruy Pro', sans-serif;
}

.logo-text p {
    font-size: 0.75rem;
    opacity: 0.9;
    margin: 0;
    letter-spacing: 0.5px;
    font-weight: 400;
    font-family: 'Kantumruy Pro', sans-serif;
}

.nav {
    display: flex;
    gap: 20px;
}

.nav a {
    color: var(--white);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 5px;
}

.nav a:hover {
    background: rgba(255, 255, 255, 0.2);
}

.nav a.active {
    background: var(--primary-color);
    color: var(--white);
    font-weight: 600;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.2) 50%, rgba(168, 85, 247, 0.2) 100%);
    border-top: 1px solid var(--border-dark);
    border-bottom: 1px solid var(--border-dark);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="2" fill="white" opacity="0.1"/></svg>');
    animation: moveBackground 20s linear infinite;
}

@keyframes moveBackground {
    0% { transform: translate(0, 0); }
    100% { transform: translate(100px, 100px); }
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-content h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    text-shadow: 0 4px 12px rgba(0,0,0,0.2);
    animation: fadeInUp 0.8s ease;
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 700;
}

.hero-content .hero-description {
    font-size: 1.15rem;
    margin-bottom: 2rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.8;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.hero-features {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-top: 30px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.1);
    padding: 15px 30px;
    border-radius: 50px;
    border: 2px solid rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(10px);
    transition: var(--transition);
    font-family: 'Kantumruy Pro', sans-serif;
}

.feature-item:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(99, 102, 241, 0.4);
}

.feature-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.feature-item span {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--white);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    font-weight: 400;
}

.hero-price {
    margin-top: 20px;
    font-size: 1.5rem;
    font-weight: 500;
}

.price-tag {
    background: rgba(255, 255, 255, 0.15);
    color: var(--white);
    border: 2px solid var(--primary-color);
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 700;
    backdrop-filter: blur(10px);
    font-family: 'Kantumruy Pro', sans-serif;
}

/* Search Section */
.search-section {
    padding: 30px 0;
    background: rgba(26, 26, 46, 0.5);
    border-top: 1px solid var(--border-dark);
    border-bottom: 1px solid var(--border-dark);
    backdrop-filter: blur(10px);
}

.search-filter {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.search-form {
    display: flex;
    justify-content: center;
}

.search-box {
    display: flex;
    max-width: 600px;
    width: 100%;
    box-shadow: var(--box-shadow);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.search-box input {
    flex: 1;
    padding: 15px 20px;
    border: none;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border: 1px solid var(--border-dark);
}

.search-box input::placeholder {
    color: var(--text-muted);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.15);
}

.search-box button {
    padding: 15px 30px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.search-box button:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.category-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.category-btn {
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    border: 1px solid var(--border-dark);
    border-radius: 25px;
    text-decoration: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
    font-family: 'Kantumruy Pro', sans-serif;
}

.category-btn:hover, .category-btn.active {
    background: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Applications Grid */
.applications {
    padding: 40px 0;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.app-card {
    background: rgba(26, 26, 46, 0.6);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    transition: var(--transition);
    border: 1px solid var(--border-dark);
    backdrop-filter: blur(10px);
}

.app-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.4);
    border-color: var(--primary-color);
    background: rgba(26, 26, 46, 0.8);
}

.app-icon {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    padding: 0;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.app-icon::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(30px, 30px); }
}

.app-icon i {
    font-size: 4rem;
    color: var(--white);
    position: relative;
    z-index: 1;
}

.app-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: relative;
    z-index: 1;
}

.app-info {
    padding: 20px;
}

.app-name {
    font-size: 1.3rem;
    margin-bottom: 5px;
    color: var(--white);
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 600;
}

.app-version {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 5px;
    font-weight: 400;
}

.app-category {
    color: var(--primary-color);
    font-size: 0.9rem;
    margin-bottom: 10px;
    font-weight: 500;
}

.app-description {
    color: var(--text-light);
    margin-bottom: 15px;
    min-height: 60px;
    font-weight: 400;
    line-height: 1.6;
    opacity: 0.9;
}

.app-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding: 10px 0;
    border-top: 1px solid var(--border-dark);
    border-bottom: 1px solid var(--border-dark);
    font-size: 0.9rem;
    color: var(--text-muted);
}

.app-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.app-actions {
    display: flex;
    gap: 8px;
    flex: 1;
}

.btn-preview {
    padding: 10px 15px !important;
    min-width: auto !important;
}

.app-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    font-family: 'Kantumruy Pro', sans-serif;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    transition: var(--transition);
    font-weight: 600;
    font-family: 'Kantumruy Pro', sans-serif;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background: #1976D2;
}

.btn-secondary {
    background: #757575;
    color: var(--white);
}

.btn-secondary:hover {
    background: #616161;
}

.btn-success {
    background: var(--success-color);
    color: var(--white);
}

.btn-success:hover {
    background: #27ae60;
}

.btn-danger {
    background: var(--danger-color);
    color: var(--white);
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-warning {
    background: #f39c12;
    color: var(--white);
    border: 1px solid #e67e22;
}

.btn-warning:hover {
    background: #e67e22;
}

.btn-large {
    padding: 15px 30px;
    font-size: 1.1rem;
}

.btn-small {
    padding: 5px 10px;
    font-size: 0.85rem;
}

/* Share Button */
.btn-share {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: var(--white);
    padding: 10px 12px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-share:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-preview {
    padding: 10px 12px;
}

/* Share Modal */
.share-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.share-modal-content {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-light) 100%);
    border: 1px solid var(--border-dark);
    padding: 40px;
    border-radius: 20px;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.share-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 32px;
    color: var(--text-muted);
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.share-modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    transform: rotate(90deg);
}

.share-modal-content h3 {
    color: var(--white);
    margin-bottom: 30px;
    font-size: 1.5rem;
    text-align: center;
}

.share-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px 20px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
    color: var(--white);
    font-family: 'Kantumruy Pro', sans-serif;
}

.share-facebook {
    background: linear-gradient(135deg, #1877f2 0%, #0c5cb8 100%);
}

.share-facebook:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(24, 119, 242, 0.4);
}

.share-telegram {
    background: linear-gradient(135deg, #0088cc 0%, #006699 100%);
}

.share-telegram:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 136, 204, 0.4);
}

.share-whatsapp {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
}

.share-whatsapp:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(37, 211, 102, 0.4);
}

.share-copy {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%);
    grid-column: 1 / -1;
}

.share-copy:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(108, 117, 125, 0.4);
}

.share-btn i {
    font-size: 1.2rem;
}

/* Payment Section */
.payment-section {
    padding: 40px 0;
}

.payment-container {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.payment-app-info, .payment-form-container {
    background: rgba(26, 26, 46, 0.6);
    border: 1px solid var(--border-dark);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    backdrop-filter: blur(10px);
}

.payment-app-info h2, .payment-form-container h2 {
    margin-bottom: 20px;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 10px;
}

.app-icon-large {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3) 0%, rgba(25, 118, 210, 0.3) 100%);
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 20px;
    backdrop-filter: blur(10px);
    overflow: hidden;
}

.app-icon-large i {
    font-size: 3rem;
    color: var(--white);
}

.app-icon-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-details {
    text-align: center;
}

.app-details h3 {
    margin: 15px 0 5px;
    font-size: 1.5rem;
    color: var(--white);
}

.version {
    color: var(--text-muted);
    margin-bottom: 15px;
}

.description {
    color: var(--text-light);
    margin-bottom: 20px;
    line-height: 1.6;
}

.price-display {
    margin-top: 20px;
    padding: 20px;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    backdrop-filter: blur(10px);
}

.price-display .price {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
}

/* Forms */
.payment-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'Kantumruy Pro', sans-serif;
    color: var(--text-light);
}

.required {
    color: var(--danger-color);
}

.form-group input {
    padding: 12px 15px;
    border: 2px solid var(--border-dark);
    background: rgba(255, 255, 255, 0.05);
    color: var(--white);
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 400;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.08);
}

.payment-summary {
    background: rgba(26, 26, 46, 0.5);
    border: 1px solid var(--border-dark);
    padding: 20px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.payment-summary h3 {
    margin-bottom: 15px;
    color: var(--white);
}

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-dark);
    color: var(--text-light);
}

.summary-item.total {
    border-top: 2px solid var(--primary-color);
    border-bottom: none;
    font-weight: bold;
    font-size: 1.2rem;
    margin-top: 10px;
    color: var(--white);
}

.payment-note {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* QR Code */
.qr-code-container {
    text-align: center;
}

.qr-code {
    background: var(--white);
    padding: 20px;
    border-radius: var(--border-radius);
    display: inline-block;
    margin: 20px 0;
    box-shadow: var(--box-shadow);
}

.qr-code img {
    max-width: 300px;
    width: 100%;
}

.transaction-info {
    background: rgba(26, 26, 46, 0.5);
    border: 1px solid var(--border-dark);
    padding: 20px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
    margin: 20px 0;
}

.instructions {
    color: var(--text-light);
    margin-top: 15px;
    line-height: 1.8;
}

.payment-status {
    margin-top: 30px;
}

.loading {
    text-align: center;
    padding: 30px;
}

.loading i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert i {
    font-size: 1.5rem;
}

.alert-error {
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
    border-left: 4px solid var(--danger-color);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.alert-success {
    background: rgba(34, 197, 94, 0.15);
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-left: 4px solid var(--success-color);
}

.alert-warning {
    background: rgba(251, 191, 36, 0.15);
    color: #fcd34d;
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-left: 4px solid var(--warning-color);
}

/* Download Section */
.download-section {
    padding: 40px 0;
    min-height: 70vh;
}

.download-container {
    max-width: 800px;
    margin: 0 auto;
}

.download-error, .download-success {
    background: rgba(26, 26, 46, 0.6);
    border: 1px solid var(--border-dark);
    padding: 60px 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    text-align: center;
    backdrop-filter: blur(10px);
}

.download-error i {
    font-size: 5rem;
    color: var(--danger-color);
    margin-bottom: 20px;
}

.success-icon i {
    font-size: 5rem;
    color: var(--success-color);
    margin-bottom: 20px;
}

.download-app-info {
    margin: 30px 0;
    padding: 30px;
    background: rgba(26, 26, 46, 0.4);
    border: 1px solid var(--border-dark);
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
}

.download-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-light);
}

.download-notes {
    margin: 30px 0;
    text-align: left;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    padding: 20px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.download-notes h4 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

.download-notes ul {
    list-style-position: inside;
    color: var(--text-light);
}

.download-notes li {
    margin-bottom: 8px;
}

.action-buttons {
    margin-top: 30px;
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* Admin Section */
.admin-section {
    padding: 40px 0;
    min-height: calc(100vh - 200px);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: rgba(26, 26, 46, 0.6);
    border: 1px solid var(--border-dark);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    display: flex;
    align-items: center;
    gap: 20px;
    backdrop-filter: blur(10px);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--white);
    font-size: 2rem;
}

.stat-info h3 {
    font-size: 2rem;
    margin-bottom: 5px;
    color: var(--white);
}

.stat-info p {
    color: var(--text-muted);
}

.admin-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-light);
    border: 2px solid var(--border-dark);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
}

.tab-btn:hover, .tab-btn.active {
    background: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.admin-panel {
    background: rgba(26, 26, 46, 0.6);
    border: 1px solid var(--border-dark);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    backdrop-filter: blur(10px);
}

.admin-panel h2 {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--white);
}

.settings-section {
    background: rgba(255, 255, 255, 0.03);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid var(--border-dark);
    margin-bottom: 30px;
}

.settings-section h3 {
    color: var(--white);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--primary-color);
}

.table-responsive {
    overflow-x: auto;
    margin-top: 20px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background: rgba(99, 102, 241, 0.3);
    color: var(--white);
    padding: 12px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid var(--primary-color);
}

.data-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-dark);
    color: var(--text-light);
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

.status-badge {
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 500;
}

.status-completed, .status-active {
    background: rgba(34, 197, 94, 0.2);
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.status-pending {
    background: rgba(251, 191, 36, 0.2);
    color: #fcd34d;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.status-failed, .status-inactive {
    background: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-expired {
    background: rgba(100, 116, 139, 0.2);
    color: var(--text-muted);
    border: 1px solid rgba(100, 116, 139, 0.3);
}

.app-name-cell {
    display: flex;
    align-items: center;
}

/* Application Form */
.app-form {
    max-width: 1000px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    color: var(--white);
    font-weight: 500;
    font-size: 0.95rem;
}

.form-group label i {
    color: var(--primary-color);
    margin-right: 5px;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="email"],
.form-group input[type="file"],
.form-group select,
.form-group textarea {
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-dark);
    border-radius: 8px;
    color: var(--white);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="number"]:focus,
.form-group input[type="email"]:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-group input[type="file"] {
    padding: 10px;
    cursor: pointer;
}

.form-group small {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.form-group select {
    cursor: pointer;
}

.form-group select option {
    background: var(--bg-dark);
    color: var(--white);
}

.form-section-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
    margin: 30px 0;
    opacity: 0.3;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.form-actions .btn {
    padding: 12px 30px;
    font-size: 1rem;
}

.btn-secondary {
    background: rgba(100, 116, 139, 0.2);
    color: var(--white);
    border: 1px solid rgba(100, 116, 139, 0.3);
}

.btn-secondary:hover {
    background: rgba(100, 116, 139, 0.3);
    border-color: rgba(100, 116, 139, 0.5);
}

.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
}

.alert i {
    font-size: 1.2rem;
}

.alert-success {
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #86efac;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.alert-warning {
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.3);
    color: #fcd34d;
}

/* Login */
.login-container {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-dark-light) 100%);
    background-attachment: fixed;
}

.login-box {
    background: rgba(26, 26, 46, 0.9);
    border: 1px solid var(--border-dark);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    max-width: 400px;
    width: 100%;
    backdrop-filter: blur(20px);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h2 {
    color: var(--white);
    margin-bottom: 10px;
}

.login-header p {
    color: var(--text-muted);
    margin: 0;
}

.login-header i {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-footer {
    margin-top: 20px;
    text-align: center;
    color: var(--text-muted);
}

.login-footer a {
    color: var(--primary-color);
    text-decoration: none;
}

/* Footer */
.footer {
    background: rgba(15, 23, 42, 0.95);
    border-top: 1px solid var(--border-dark);
    color: var(--white);
    padding: 40px 0 20px;
    margin-top: 60px;
    backdrop-filter: blur(10px);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h4 {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
}

.footer-section p {
    color: #bdbdbd;
    margin-bottom: 10px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #424242;
}

/* Advertisement Banner */
.ad-banner {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.2) 0%, rgba(245, 158, 11, 0.2) 100%);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: var(--border-radius);
    padding: 30px;
    margin: 30px 0;
    box-shadow: 0 8px 30px rgba(245, 158, 11, 0.2);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.ad-banner::before {
    content: '⭐';
    position: absolute;
    font-size: 150px;
    opacity: 0.1;
    right: -20px;
    top: -40px;
    animation: rotate 10s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.ad-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.ad-icon {
    font-size: 60px;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.ad-text h3 {
    color: var(--white);
    font-size: 1.8rem;
    margin-bottom: 10px;
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 700;
}

.ad-text p {
    color: var(--text-light);
    opacity: 0.9;
    font-size: 1.1rem;
    font-weight: 400;
}

.ad-cta {
    margin-left: auto;
}

.ad-cta .btn {
    background: var(--white);
    color: var(--dark-color);
    padding: 15px 30px;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.ad-cta .btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* Promotional Card */
.promo-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.2) 100%);
    color: var(--white);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--border-radius);
    padding: 40px;
    text-align: center;
    margin: 30px 0;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.promo-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.promo-content {
    position: relative;
    z-index: 1;
}

.promo-content h3 {
    font-size: 2rem;
    margin-bottom: 15px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.2);
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 700;
}

.promo-content p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    opacity: 0.9;
    font-weight: 400;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.fade-in {
    animation: fadeIn 0.6s ease;
}

.fade-in-up {
    animation: fadeInUp 0.8s ease;
}

.no-results {
    text-align: center;
    padding: 60px 20px;
    color: #757575;
}

.no-results i {
    font-size: 5rem;
    margin-bottom: 20px;
}

/* ========================================
   KHQR Modal Styles (Bakong Style)
   ======================================== */

/* Modal Overlay */
.khqr-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
    padding: 20px;
}

/* Modal Container */
.khqr-modal {
    background: linear-gradient(180deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 20px;
    max-width: 380px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
}

/* Custom Scrollbar */
.khqr-modal::-webkit-scrollbar {
    width: 6px;
}

.khqr-modal::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.khqr-modal::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.khqr-modal::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Modal Header */
.khqr-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.khqr-logo img {
    filter: brightness(0) invert(1);
    height: 30px;
}

.timer-badge {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 6px 12px;
    border-radius: 16px;
    color: white;
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.timer-badge i {
    font-size: 0.8rem;
}

.modal-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

/* Modal Title */
.khqr-modal-title {
    padding: 12px 20px 8px;
    text-align: center;
}

.khqr-modal-title h2 {
    color: white;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Kantumruy Pro', sans-serif;
    line-height: 1.4;
}

/* KHQR Card */
.khqr-card {
    background: white;
    margin: 0 20px 16px;
    border-radius: 14px;
    padding: 16px 14px 14px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    position: relative;
}

.khqr-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 8px;
    background: linear-gradient(90deg, 
        #e74c3c 0%, 
        #e74c3c 33.33%, 
        white 33.33%, 
        white 66.66%, 
        #3498db 66.66%, 
        #3498db 100%
    );
    border-radius: 16px 16px 0 0;
}

.khqr-card-header {
    display: flex;
    justify-content: center;
    margin-bottom: 12px;
}

.khqr-brand img {
    height: 24px;
}

/* Merchant Info */
.merchant-info {
    text-align: center;
    margin-bottom: 12px;
}

.merchant-name {
    font-family: 'Kantumruy Pro', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 6px;
}

.merchant-amount {
    font-family: 'Kantumruy Pro', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #1a1a2e;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 3px;
}

.merchant-amount .currency {
    font-size: 1.3rem;
    margin-top: 6px;
}

/* QR Code Wrapper */
.qr-code-wrapper {
    position: relative;
    margin: 0 auto 10px;
    width: 200px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-scan-frame {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.corner {
    position: absolute;
    width: 40px;
    height: 40px;
    border: 3px solid #e74c3c;
}

.corner-tl {
    top: 0;
    left: 0;
    border-right: none;
    border-bottom: none;
    border-radius: 12px 0 0 0;
}

.corner-tr {
    top: 0;
    right: 0;
    border-left: none;
    border-bottom: none;
    border-radius: 0 12px 0 0;
}

.corner-bl {
    bottom: 0;
    left: 0;
    border-right: none;
    border-top: none;
    border-radius: 0 0 0 12px;
}

.corner-br {
    bottom: 0;
    right: 0;
    border-left: none;
    border-top: none;
    border-radius: 0 0 12px 0;
}

.qr-code-img {
    width: 180px;
    height: 180px;
    border-radius: 6px;
    position: relative;
    z-index: 1;
}

/* Transaction ID */
.transaction-id {
    text-align: center;
    font-family: 'Courier New', monospace;
    font-size: 0.7rem;
    color: #666;
    letter-spacing: 0.3px;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 6px;
}

/* Instructions */
.khqr-instructions {
    padding: 12px 20px 14px;
    text-align: center;
    color: white;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.khqr-instructions p {
    font-family: 'Kantumruy Pro', sans-serif;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.khqr-instructions p:first-child {
    font-size: 0.9rem;
    font-weight: 600;
}

.khqr-instructions .sub-text {
    font-size: 0.75rem;
    opacity: 0.8;
    font-weight: 400;
}

.khqr-instructions .footer-text {
    font-size: 0.65rem;
    opacity: 0.6;
    margin-top: 6px;
}

/* Payment Status Checking (Inline with KHQR) */
.payment-status-checking {
    padding: 12px 20px;
    background: rgba(52, 152, 219, 0.08);
    border-radius: 8px;
    margin: 16px 24px 24px;
    border: 1px solid rgba(52, 152, 219, 0.2);
}

.status-checking-inline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: white;
}

.status-checking-inline i {
    font-size: 1rem;
    color: #3498db;
}

.status-checking-inline p {
    font-family: 'Kantumruy Pro', sans-serif;
    font-size: 0.8rem;
    font-weight: 400;
    margin: 0;
    color: #94a3b8;
    opacity: 0.9;
}

/* Status Modal Overlay (Separate) */
.status-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.status-modal {
    background: var(--bg-card);
    border-radius: 20px;
    padding: 40px;
    max-width: 450px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Status Success in Modal */
.status-modal .status-success {
    background: transparent;
    padding: 0;
    margin: 0;
}

.status-modal .status-success i {
    font-size: 5rem;
    color: var(--success-color);
    margin-bottom: 20px;
    animation: successPop 0.6s ease;
}

@keyframes successPop {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.status-modal .status-success h3 {
    color: var(--text-light);
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.status-modal .status-success p {
    color: var(--text-muted);
    margin-bottom: 25px;
}

.status-modal .btn-success {
    background: linear-gradient(135deg, var(--success-color), #059669);
    color: white;
    border: none;
    padding: 14px 35px;
    font-size: 1.1rem;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.status-modal .btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

/* Status Timeout */
.status-timeout {
    padding: 20px 0;
}

.status-timeout i {
    font-size: 4rem;
    color: var(--warning-color);
    margin-bottom: 20px;
    display: block;
}

.status-timeout h3 {
    color: var(--text-light);
    font-size: 1.6rem;
    margin-bottom: 15px;
    font-family: 'Kantumruy Pro', sans-serif;
}

.status-timeout p {
    color: var(--text-muted);
    margin-bottom: 25px;
    font-family: 'Kantumruy Pro', sans-serif;
    font-size: 1rem;
}

.status-modal .btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    padding: 14px 35px;
    font-size: 1.1rem;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Kantumruy Pro', sans-serif;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
    text-decoration: none;
}

.status-modal .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* Modal Countdown Timer */
@keyframes countdown-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.timer-badge.warning {
    background: rgba(239, 68, 68, 0.2);
    border: 2px solid #ef4444;
    animation: countdown-blink 1s infinite;
}

/* Responsive */
@media (max-width: 768px) {
    .payment-container {
        grid-template-columns: 1fr;
    }
    
    .app-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .header-content {
        flex-direction: column;
        gap: 15px;
    }
    
    .hero {
        padding: 50px 0;
    }
    
    .hero-content h2 {
        font-size: 1.8rem;
    }
    
    .hero-content .hero-description {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-features {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .feature-item {
        padding: 12px 20px;
        justify-content: center;
    }
    
    .feature-item i {
        font-size: 1.2rem;
    }
    
    .feature-item span {
        font-size: 0.95rem;
    }
    
    .data-table {
        font-size: 0.85rem;
    }
    
    .data-table th, .data-table td {
        padding: 8px;
    }
    
    /* KHQR Modal Responsive */
    .khqr-modal {
        max-width: 95%;
        margin: 10px;
    }
    
    .khqr-modal-title h2 {
        font-size: 1.1rem;
    }
    
    .merchant-amount {
        font-size: 2rem;
    }
    
    .qr-code-wrapper {
        width: 220px;
        height: 220px;
    }
    
    .qr-code-img {
        width: 200px;
        height: 200px;
    }
    
    .corner {
        width: 40px;
        height: 40px;
    }
    
    .khqr-modal-header {
        padding: 16px 20px;
    }
    
    .timer-badge {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
    
    .modal-close {
        width: 32px;
        height: 32px;
        font-size: 1rem;
    }
    
    .payment-status-checking {
        margin: 12px 15px 15px;
        padding: 10px 15px;
    }
    
    .status-checking-inline {
        gap: 8px;
    }
    
    .status-checking-inline i {
        font-size: 0.9rem;
    }
    
    .status-checking-inline p {
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .khqr-modal-overlay {
        padding: 10px;
    }
    
    .qr-code-wrapper {
        width: 200px;
        height: 200px;
    }
    
    .qr-code-img {
        width: 180px;
        height: 180px;
    }
    
    .khqr-instructions p:first-child {
        font-size: 0.95rem;
    }
    
    .khqr-instructions .sub-text {
        font-size: 0.85rem;
    }
}

/* Notification Modal Styles */
.notification-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 20px;
}

.notification-modal-content {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-light) 100%);
    border-radius: 20px;
    padding: 40px 30px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    border: 2px solid var(--border-dark);
    position: relative;
    animation: slideDown 0.4s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notification-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--text-light);
    font-size: 28px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    line-height: 1;
}

.notification-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

.notification-icon {
    font-size: 64px;
    margin-bottom: 20px;
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.notification-modal-content h2 {
    color: var(--white);
    margin-bottom: 15px;
    font-size: 28px;
}

.notification-modal-content p {
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 25px;
    font-size: 16px;
}

.notification-modal-content .btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-block;
}

.notification-modal-content .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.4);
}

.notification-modal-content.info { border-top: 4px solid #3b82f6; }
.notification-modal-content.warning { border-top: 4px solid #f59e0b; }
.notification-modal-content.success { border-top: 4px solid #10b981; }
.notification-modal-content.announcement { border-top: 4px solid var(--primary-color); }

@media (max-width: 768px) {
    .notification-modal-content {
        padding: 30px 20px;
        max-width: 90%;
    }
    .notification-icon { font-size: 48px; }
    .notification-modal-content h2 { font-size: 22px; }
    .notification-modal-content p { font-size: 14px; }
}

.notification-image {
    width: 100%;
    max-width: 400px;
    margin: 0 auto 20px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.notification-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* ===================================
   APP PREVIEW MODAL STYLES
   =================================== */

.preview-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.preview-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
}

.preview-modal-content {
    position: relative;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    margin: 5vh auto;
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-light) 100%);
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    animation: slideUp 0.3s ease;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.preview-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: var(--text-light);
    font-size: 20px;
    cursor: pointer;
    transition: var(--transition);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-close:hover {
    background: var(--danger-color);
    transform: rotate(90deg);
}

.preview-body {
    padding: 40px;
    max-height: calc(90vh - 80px);
    overflow-y: auto;
}

/* Custom Scrollbar */
.preview-body::-webkit-scrollbar {
    width: 8px;
}

.preview-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.preview-body::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

.preview-body::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Loading State */
.preview-loading {
    text-align: center;
    padding: 60px 20px;
}

.preview-loading i {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.preview-loading p {
    color: var(--text-muted);
    font-size: 16px;
}

/* Error State */
.preview-error {
    text-align: center;
    padding: 60px 20px;
}

.preview-error i {
    font-size: 48px;
    color: var(--danger-color);
    margin-bottom: 20px;
}

.preview-error p {
    color: var(--text-muted);
    font-size: 16px;
}

/* Preview Header */
.preview-header {
    display: flex;
    gap: 25px;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.preview-icon {
    width: 100px;
    height: 100px;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3);
    flex-shrink: 0;
}

.preview-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.preview-icon i {
    font-size: 48px;
    color: white;
}

.preview-title {
    flex: 1;
}

.preview-title h2 {
    font-size: 28px;
    color: var(--text-light);
    margin-bottom: 10px;
    font-weight: 700;
}

.preview-version {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 5px;
}

.preview-category {
    color: var(--primary-color);
    font-size: 14px;
    font-weight: 600;
}

/* Preview Details */
.preview-details {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.preview-section h3 {
    font-size: 20px;
    color: var(--text-light);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.preview-section h3 i {
    color: var(--primary-color);
}

.preview-section p {
    color: var(--text-muted);
    line-height: 1.8;
    font-size: 15px;
}

/* Preview Stats */
.preview-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
}

.stat-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.stat-item:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.stat-item i {
    font-size: 28px;
    color: var(--primary-color);
}

.stat-item div {
    display: flex;
    flex-direction: column;
}

.stat-label {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.stat-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-light);
}

/* Preview Footer */
.preview-footer {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.preview-footer .btn {
    padding: 12px 30px;
    font-size: 16px;
}

/* Screenshots Slider */
.screenshots-slider {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.3);
    margin-top: 15px;
}

.slider-container {
    position: relative;
    width: 100%;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide.active {
    opacity: 1;
    z-index: 1;
}

.slide img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(99, 102, 241, 0.8);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.slider-btn:hover {
    background: var(--primary-color);
    transform: translateY(-50%) scale(1.1);
}

.slider-btn.prev {
    left: 15px;
}

.slider-btn.next {
    right: 15px;
}

.slider-dots {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: var(--transition);
}

.dot.active,
.dot:hover {
    background: var(--primary-color);
    width: 12px;
    height: 12px;
}

/* Video Container */
.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.3);
    margin-top: 15px;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 12px;
}

/* Instructions Content */
.instructions-content {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: 12px;
    border-left: 3px solid var(--primary-color);
    margin-top: 15px;
}

.instruction-step {
    padding: 12px 0;
    color: var(--text-light);
    line-height: 1.8;
    font-size: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.instruction-step:last-child,
.instruction-bullet:last-child,
.instruction-text:last-child {
    border-bottom: none;
}

.instruction-bullet {
    padding: 10px 0;
    padding-left: 20px;
    color: var(--text-muted);
    line-height: 1.8;
    font-size: 14px;
    position: relative;
}

.instruction-bullet::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    background: var(--primary-color);
    border-radius: 50%;
}

.instruction-text {
    padding: 10px 0;
    color: var(--text-muted);
    line-height: 1.8;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .preview-modal-content {
        width: 95%;
        max-height: 95vh;
        margin: 2.5vh auto;
    }
    
    .preview-body {
        padding: 30px 20px;
    }
    
    .preview-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .preview-icon {
        width: 80px;
        height: 80px;
    }
    
    .preview-title h2 {
        font-size: 22px;
    }
    
    .preview-stats {
        grid-template-columns: 1fr;
    }
    
    .preview-footer {
        flex-direction: column;
    }
    
    .preview-footer .btn {
        width: 100%;
        justify-content: center;
    }
    
    /* Mobile Slider Adjustments */
    .slider-container {
        height: 300px;
    }
    
    .slider-btn {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .slider-btn.prev {
        left: 10px;
    }
    
    .slider-btn.next {
        right: 10px;
    }
    
    .slider-dots {
        bottom: 10px;
    }
    
    .dot {
        width: 8px;
        height: 8px;
    }
    
    .dot.active {
        width: 10px;
        height: 10px;
    }
    
    /* Mobile Video Container */
    .video-container {
        padding-bottom: 75%; /* Taller aspect ratio for mobile */
    }
    
    /* Mobile Instructions */
    .instructions-content {
        padding: 15px;
    }
    
    .instruction-step,
    .instruction-bullet,
    .instruction-text {
        font-size: 13px;
    }
    
    .app-footer {
        flex-direction: column;
        gap: 15px;
    }
    
    .app-actions {
        width: 100%;
    }
    
    .app-actions .btn {
        flex: 1;
    }
    
    /* Share Modal Mobile */
    .share-modal-content {
        width: 95%;
        padding: 30px 20px;
    }
    
    .share-options {
        grid-template-columns: 1fr;
    }
    
    .share-btn {
        padding: 12px 15px;
        font-size: 0.95rem;
    }
    
    .share-modal-content h3 {
        font-size: 1.3rem;
    }
}


.notification-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* Adjust modal content when there's an image */
.notification-modal-content:has(.notification-image) {
    max-width: 550px;
}

