:root {
    /* Professional Color Palette */
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #60a5fa;
    --secondary: #1e293b;
    --secondary-light: #334155;
    --accent: #3b82f6;
    --accent-light: #93c5fd;
    
    /* Neutral Colors */
    --text: #0f172a;
    --text-light: #475569;
    --bg: #f8fafc;
    --bg-light: #ffffff;
    --surface: #ffffff;
    --border: rgba(0, 0, 0, 0.08);
    
    /* Functional Colors */
    --success: #059669;
    --error: #dc2626;
    --warning: #d97706;
    --info: #2563eb;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    
    /* Typography */
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-md: 1rem;
    --font-size-lg: 1.25rem;
    --font-size-xl: 1.5rem;
    --font-size-2xl: 2rem;
    --font-size-3xl: 3rem;
    
    /* Layout */
    --container-width: min(90%, 1200px);
    --border-radius: 0.5rem;
    --border-radius-lg: 1rem;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    
    /* Transitions */
    --transition-fast: 150ms;
    --transition-normal: 300ms;
    --transition-slow: 500ms;
}

/* Reset & Base Styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
    line-height: 1.5;
    color: var(--text);
    background-color: var(--bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    line-height: 1.2;
    font-weight: 700;
    margin-bottom: var(--space-md);
}

h1 { font-size: var(--font-size-3xl); }
h2 { font-size: var(--font-size-2xl); }
h3 { font-size: var(--font-size-xl); }
h4 { font-size: var(--font-size-lg); }
h5 { font-size: var(--font-size-md); }
h6 { font-size: var(--font-size-sm); }

p { margin-bottom: var(--space-md); }

/* Layout */
.container {
    max-width: 100%;
    margin: 2rem auto;
    padding: 2rem;
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-light) 100%);
}

/* Components */
.card {
    background: var(--surface);
    border-radius: 16px;
    box-shadow: 
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -2px rgba(0, 0, 0, 0.05),
        0 0 0 1px rgba(0, 0, 0, 0.05);
    padding: 2rem;
    margin-bottom: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 20px 25px -5px rgba(0, 0, 0, 0.1),
        0 8px 10px -6px rgba(0, 0, 0, 0.05);
}

.btn {
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    color: white;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.2);
}

.btn:focus {
    outline: none;
    box-shadow: 
        0 0 0 3px rgba(37, 99, 235, 0.3),
        0 4px 6px -1px rgba(37, 99, 235, 0.2);
}

/* Form Elements */
input, textarea, select {
    width: 100%;
    padding: var(--space-sm);
    border: 1px solid var(--border);
    border-radius: var(--border-radius);
    font-size: var(--font-size-md);
    transition: border-color var(--transition-normal) ease;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-light);
}

/* Utilities */
.text-center { text-align: center; }
.mt-1 { margin-top: var(--space-xs); }
.mt-2 { margin-top: var(--space-sm); }
.mt-3 { margin-top: var(--space-md); }
.mt-4 { margin-top: var(--space-lg); }
.mt-5 { margin-top: var(--space-xl); }

/* Responsive Design */
@media (max-width: 768px) {
    :root {
        --container-width: 95%;
        --font-size-3xl: 2.5rem;
        --font-size-2xl: 2rem;
    }
    
    .container {
        padding: var(--space-md);
    }
}

/* Dark Mode */
@media (prefers-color-scheme: dark) {
    :root {
        --text: #0f172a;
        --text-light: #94a3b8;
        --bg: #0f172a;
        --bg-light: #1e293b;
        --surface: #1e293b;
        --border: rgba(255, 255, 255, 0.05);
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Print Styles */
@media print {
    .container {
        width: 100%;
        padding: 0;
    }
    
    .btn, .card {
        box-shadow: none;
    }
    
    .no-print {
        display: none;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Loading States */
.loading {
    position: relative;
    opacity: 0.7;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1.5rem;
    height: 1.5rem;
    border: 2px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Recent QR Codes Section */
.recent-codes {
    margin: 4rem auto;
    padding: 3rem;
    border-radius: 16px;
    background: linear-gradient(to bottom right, rgba(255, 255, 255, 0.95), rgba(248, 250, 252, 0.95));
    box-shadow: 
        0 20px 40px -12px rgba(0, 0, 0, 0.1),
        0 10px 20px -8px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    max-width: 1200px;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.recent-codes h2 {
    font-size: 2.25rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 2.5rem;
    color: #1e293b;
    letter-spacing: -0.02em;
    position: relative;
    padding-bottom: 1rem;
}

.recent-codes h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(to right, #2563eb, #3b82f6);
    border-radius: 3px;
}

/* Table Container with Professional Scroll */
.table-container {
    overflow-x: auto;
    border-radius: 12px;
    background: #ffffff;
    margin: 2rem 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* Professional Table Styles */
#recentLinksTable {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 0;
}

/* Elegant Header Styles */
#recentLinksTable thead {
    background: #f8fafc;
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 2px solid rgba(37, 99, 235, 0.1);
}

#recentLinksTable th {
    color: #1e293b;
    font-weight: 600;
    text-align: left;
    padding: 1.25rem 1.5rem;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Professional Row Styles */
#recentLinksTable tbody tr {
    transition: all 0.2s ease;
    background: white;
}

#recentLinksTable tbody tr:hover {
    background: #f8fafc;
}

#recentLinksTable td {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    font-size: 0.95rem;
    color: #334155;
    vertical-align: middle;
}

/* Link Cell Styles */
.link-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    max-width: 400px;
}

.link-icon {
    color: #2563eb;
    opacity: 0.8;
    transition: all 0.2s ease;
}

.link-text {
    color: #334155;
    text-decoration: none;
    transition: all 0.2s ease;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-cell:hover .link-icon {
    opacity: 1;
    color: #1d4ed8;
}

.link-cell:hover .link-text {
    color: #1d4ed8;
}

/* QR Code Cell */
#recentLinksTable td img {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    padding: 4px;
    background: white;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

#recentLinksTable td img:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Show More Section */
.show-more-container {
    text-align: center;
    padding: 2.5rem 0 1rem;
    position: relative;
}

.show-more-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 1px;
    background: linear-gradient(to right, 
        transparent, 
        rgba(37, 99, 235, 0.2), 
        rgba(37, 99, 235, 0.2), 
        transparent
    );
}

.show-more-btn {
    position: relative;
    background: #ffffff;
    color: #2563eb;
    border: 1px solid #2563eb;
    padding: 0.875rem 2.5rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9375rem;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.show-more-btn::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 9px;
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.show-more-btn:hover {
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    border-color: transparent;
    transform: translateY(-1px);
    box-shadow: 
        0 4px 12px rgba(37, 99, 235, 0.15),
        0 2px 4px rgba(37, 99, 235, 0.1);
}

.show-more-btn:active {
    transform: translateY(0);
}

.btn-text {
    position: relative;
    z-index: 1;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: #64748b;
    font-size: 0.95rem;
}

/* Dark Mode Refinements */
@media (prefers-color-scheme: dark) {
    .recent-codes {
        background: linear-gradient(to bottom right, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
        border-color: rgba(255, 255, 255, 0.05);
    }

    .recent-codes h2 {
        color: #1d4ed8;
    }

    .table-container {
        background: rgba(30, 41, 59, 0.5);
        border-color: rgba(255, 255, 255, 0.05);
    }

    #recentLinksTable thead {
        background: rgba(30, 41, 59, 0.8);
        border-bottom-color: rgba(255, 255, 255, 0.1);
    }

    #recentLinksTable th {
        color: #f8fafc;
    }

    #recentLinksTable tbody tr {
        background: transparent;
    }

    #recentLinksTable tbody tr:hover {
        background: rgba(30, 41, 59, 0.8);
    }

    #recentLinksTable td {
        color: #e2e8f0;
        border-bottom-color: rgba(255, 255, 255, 0.05);
    }

    .link-text {
        color: #e2e8f0;
    }

    .empty-state {
        color: #94a3b8;
    }

    .show-more-container::before {
        background: linear-gradient(to right, 
            transparent, 
            rgba(59, 130, 246, 0.2), 
            rgba(59, 130, 246, 0.2), 
            transparent
        );
    }

    .show-more-btn {
        background: rgba(30, 41, 59, 0.8);
        color: #ffffff;
        border-color: #ffffff;
    }

    .show-more-btn:hover {
        background: linear-gradient(135deg, #3b82f6, #60a5fa);
        color: #ffffff;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .recent-codes {
        margin: 2rem 1rem;
        padding: 2rem 1rem;
    }

    .recent-codes h2 {
        font-size: 1.75rem;
        margin-bottom: 2rem;
    }

    #recentLinksTable th,
    #recentLinksTable td {
        padding: 1rem;
    }

    .link-cell {
        max-width: 250px;
    }

    #recentLinksTable td img {
        width: 60px;
        height: 60px;
    }

    .show-more-container {
        padding: 2rem 0 0.75rem;
    }

    .show-more-btn {
        padding: 0.75rem 2rem;
        font-size: 0.875rem;
    }
}

/* Message Container */
#message {
    margin: 1.5rem auto;
    max-width: 500px;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    font-weight: 500;
    text-align: center;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

/* Default Message Style */
#message.default-message {
    opacity: 1;
    transform: translateY(0);
    background: linear-gradient(to right, #f8fafc, #f1f5f9);
    color: var(--text);
    border: 1px solid #e2e8f0;
}

/* Error Message Style */
#message.error-message {
    opacity: 1;
    transform: translateY(0);
    background: linear-gradient(to right, #fef2f2, #fee2e2);
    color: var(--error);
    border: 1px solid #fecaca;
}

/* Success Message Style */
#message.success-message {
    opacity: 1;
    transform: translateY(0);
    background: linear-gradient(to right, #f0fdf4, #dcfce7);
    color: var(--success);
    border: 1px solid #bbf7d0;
}

/* Message Icon */
#message::before {
    content: '💡';
    margin-right: 0.5rem;
    font-size: 1.1rem;
}

#message.error-message::before {
    content: '⚠️';
}

#message.success-message::before {
    content: '✅';
}

/* Bold Text Style */
#message b {
    color: var(--color-17);
    font-weight: 700;
}

/* Mobile Optimization */
@media (max-width: 768px) {
    #message {
        margin-top: 1rem;
        padding: 0.875rem 1rem;
        font-size: 0.875rem;
    }
}

/* Loading States */
.loading-row {
    text-align: center;
}

.loading-animation {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid var(--primary-color-light);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s linear infinite;
    margin: 20px 0;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Empty and Error States */
.empty-state, .error-state {
    text-align: center;
    padding: 40px 20px;
}

.empty-state-content, .error-state-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.empty-state-icon, .error-state-icon {
    width: 48px;
    height: 48px;
    color: var(--text-muted);
}

.error-state-icon {
    color: var(--error-color);
}

/* Link Cell Styling */
.link-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: 300px;
}

.link-icon {
    flex-shrink: 0;
}

.link-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* QR Code Image */
.qr-code-cell img {
    transition: opacity 0.2s ease;
}

.qr-code-cell img.error {
    opacity: 0.5;
}

/* Show More Button States */
.show-more-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Message Animations */
.success-message, .error-message {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .link-wrapper {
        max-width: 200px;
    }
}

/* Glass Morphism Effects */
.container,
.recent-codes,
.table-container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}
.container{
    background: linear-gradient(135deg, #cbd5e1 0%, #cbd5e1 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* Enhanced Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.btn:hover,
.qr-code-cell img:hover {
    animation: float 2s ease-in-out infinite;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Enhanced Focus States */
#linkInput:focus,
.btn:focus,
.show-more-btn:focus {
    outline: none;
    box-shadow: 
        0 0 0 3px rgba(99, 102, 241, 0.2),
        var(--shadow-md);
}

/* Print Styles */
@media print {
    .container {
        box-shadow: none;
        margin: 0;
        padding: 1rem;
    }

    .btn,
    .show-more-btn {
        display: none;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    :root {
        --surface: rgba(30, 41, 59, 0.95);
        --surface-2: rgba(30, 41, 59, 0.8);
        --text-primary: #0f172a;
        --text-secondary: #cbd5e1;
        --border: rgba(99, 102, 241, 0.2);
    }

    body {
        background: linear-gradient(135deg, #cbd5e1 0%, #cbd5e1 100%);
    }

    #linkInput {
        background: rgba(30, 41, 59, 0.5);
        color: #fff;
    }

    .table-container {
        background: rgba(30, 41, 59, 0.5);
    }

    #recentLinksTable tbody tr {
        background: rgba(30, 41, 59, 0.7);
    }

    #recentLinksTable td {
        border-bottom-color: rgba(99, 102, 241, 0.2);
        color: #ffffff;
    }

    .link-text {
        color: #ffffff;
    }

    .date-cell {
        color: var(--text-secondary);
    }
}

/* Enhanced Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* Loading State Refinements */
.loading-animation {
    background: conic-gradient(
        from 0deg,
        var(--primary) 0%,
        var(--primary-light) 50%,
        transparent 100%
    );
    opacity: 0.8;
}

/* Empty State Refinements */
.empty-state-content {
    padding: clamp(2rem, 4vw, 3rem);
}

.empty-state-content p {
    color: var(--text-secondary);
    font-size: clamp(0.95rem, 1.5vw, 1.1rem);
    max-width: 24rem;
    margin: 0 auto;
    line-height: 1.6;
}

/* Error State Refinements */
.error-state-content {
    padding: clamp(1.5rem, 3vw, 2rem);
}

.error-state-content p {
    color: var(--error);
    font-size: clamp(0.95rem, 1.5vw, 1.1rem);
    font-weight: 500;
}

/* Input Group Enhancement */
.input-group {
    display: flex;
    gap: 1rem;
    align-items: center;
    background: var(--bg-light);
    border-radius: 12px;
    padding: 0.5rem;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

input[type="url"] {
    flex: 1;
    padding: 1rem 1.5rem;
    border: 2px solid transparent;
    border-radius: 8px;
    font-size: 1rem;
    color: var(--text);
    background: var(--bg-light);
    transition: all 0.3s ease;
}

input[type="url"]:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    outline: none;
}

input[type="url"]::placeholder {
    color: var(--text-light);
}

/* QR Code Preview Enhancement */
#qrCodePreview {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 250px;
    background: linear-gradient(135deg, var(--bg-light) 0%, var(--bg) 100%);
    border: 1px solid var(--border);
}

#qrCodePreview img {
    border-radius: 12px;
    box-shadow: 
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -2px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}

#qrCodePreview img:hover {
    transform: scale(1.02);
}

/* Download Button Styling */
#downloadBtn {
    margin: 1.5rem auto;
    display: block;
    background: linear-gradient(135deg, var(--success) 0%, var(--primary) 100%);
}

#downloadBtn:hover {
    background: linear-gradient(135deg, var(--primary) 0%, var(--success) 100%);
}

/* Loading Indicator Enhancement */
.loading-indicator {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
    display: none;
}

button:disabled .loading-indicator {
    display: inline-block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive Enhancements */
@media (max-width: 640px) {
    .container {
        padding: 1rem;
    }

    .input-group {
        flex-direction: column;
        gap: 0.75rem;
    }

    .btn {
        width: 100%;
    }

    header h1 {
        font-size: 2rem;
    }
}

/* Dark Mode Refinements */
@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0f172a;
        --bg-light: #1e293b;
        --surface: #1e293b;
        --text: #0f172a;
        --text-light: #94a3b8;
        --border: rgba(255, 255, 255, 0.05);
    }

    .card {
        background: rgba(30, 41, 59, 0.8);
        backdrop-filter: blur(12px);
    }

    input[type="url"] {
        background: rgba(15, 23, 42, 0.3);
        color: var(--text);
    }

    #qrCodePreview {
        background: linear-gradient(135deg, rgba(30, 41, 59, 0.8) 0%, rgba(15, 23, 42, 0.8) 100%);
    }
}

.qr-preview-section {
    display: none;
    margin-top: 2rem;
    transition: opacity 0.3s ease;
}

.qr-preview-section.active {
    display: block;
    animation: fadeIn 0.3s ease-out;
}

#qrCodePreview {
    background: #ffffff;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -2px rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 250px;
    margin: 0 auto;
    max-width: 300px;
}

#qrCodePreview img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

#qrCodePreview.generating {
    position: relative;
}

#qrCodePreview.generating::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 40px;
    border: 3px solid rgba(37, 99, 235, 0.3);
    border-radius: 50%;
    border-top-color: #2563eb;
    animation: spin 1s linear infinite;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    #qrCodePreview {
        background: rgba(30, 41, 59, 0.8);
        border: 1px solid rgba(255, 255, 255, 0.05);
    }
}

/* Message styles */
.generate-message {
    text-align: center;
    padding: 2rem;
    color: var(--text-light);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.generate-message svg {
    width: 20px;
    height: 20px;
    color: var(--primary);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #qrCodePreview {
        min-height: 200px;
        padding: 1.5rem;
    }
}

/* Pagination Controls */
.pagination-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 2.5rem 0 1rem;
    position: relative;
}

.pagination-controls::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 1px;
    background: linear-gradient(to right, 
        transparent, 
        rgba(37, 99, 235, 0.2), 
        rgba(37, 99, 235, 0.2), 
        transparent
    );
}

.pagination-btn {
    background: #ffffff;
    color: #2563eb;
    border: 1px solid #2563eb;
    padding: 0.875rem 2rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9375rem;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 140px;
    justify-content: center;
}

.pagination-btn svg {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
}

.pagination-btn:hover {
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    border-color: transparent;
    transform: translateY(-1px);
    box-shadow: 
        0 4px 12px rgba(37, 99, 235, 0.15),
        0 2px 4px rgba(37, 99, 235, 0.1);
}

.pagination-btn:hover svg {
    transform: translateY(2px);
}

.pagination-btn.show-less:hover svg {
    transform: translateY(-2px);
}

.pagination-btn:active {
    transform: translateY(0);
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .pagination-controls::before {
        background: linear-gradient(to right, 
            transparent, 
            rgba(59, 130, 246, 0.2), 
            rgba(59, 130, 246, 0.2), 
            transparent
        );
    }

    .pagination-btn {
        background: rgba(30, 41, 59, 0.8);
        color: #3b82f6;
        border-color: #3b82f6;
    }

    .pagination-btn:hover {
        background: linear-gradient(135deg, #3b82f6, #60a5fa);
        color: #ffffff;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .pagination-controls {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
        padding: 2rem 0 0.75rem;
    }

    .pagination-btn {
        width: 100%;
        max-width: 200px;
        padding: 0.75rem 1.5rem;
        font-size: 0.875rem;
    }
}

[aria-labelledby="generate-section"] {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding-bottom: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    margin-bottom: 2rem;
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    [aria-labelledby="generate-section"] {
        background: rgba(255, 255, 255, 0.95);
    }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    [aria-labelledby="generate-section"] {
        border-radius: 12px;
        margin-bottom: 1.5rem;
    }
}

header {
    text-align: center;
    padding: 2rem 1rem;
    margin-bottom: 2rem;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text);
    margin: 0;
    line-height: 1.2;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    header {
        padding: 1.5rem 1rem;
        margin-bottom: 1.5rem;
    }

    header h1 {
        font-size: 2rem;
    }
}