:root {
            --bg-primary: #fafafa;
            --bg-card: #ffffff;
            --bg-surface: #f5f5f5;
            --border: #e5e5e5;
            --border-subtle: #f0f0f0;
            --text-primary: #171717;
            --text-secondary: #737373;
            --text-muted: #a3a3a3;
            --primary: #166534;
            --primary-hover: #14532d;
            --accent: #4f46e5;
            --success-bg: #dcfce7;
            --success-text: #166534;
            --warning-bg: #fef3c7;
            --warning-text: #92400e;
            --error-bg: #fee2e2;
            --error-text: #991b1b;
        }

        [data-theme="dark"] {
            --bg-primary: #0a0a0a;
            --bg-card: #171717;
            --bg-surface: #262626;
            --border: #404040;
            --border-subtle: #262626;
            --text-primary: #fafafa;
            --text-secondary: #a3a3a3;
            --text-muted: #737373;
            --primary: #22c55e;
            --primary-hover: #4ade80;
            --accent: #6366f1;
            --success-bg: #14532d;
            --success-text: #22c55e;
            --warning-bg: #78350f;
            --warning-text: #fbbf24;
            --error-bg: #7f1d1d;
            --error-text: #f87171;
        }

        body {
            font-family: 'Inter', system-ui, sans-serif;
            background: var(--bg-primary);
            color: var(--text-primary);
            transition: background-color 0.2s ease, color 0.2s ease;
            overflow: hidden;
            height: 100vh;
            width: 100vw;
            touch-action: pan-y pinch-zoom;
            /* Accessibility: Base font size for better readability */
            font-size: 16px;
            line-height: 1.5;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
        }

        /* Prevent all scrolling */
        html, body {
            overflow: hidden !important;
            max-width: 100vw !important;
            max-height: 100vh !important;
        }

        #paymentPage {
            touch-action: pan-y pinch-zoom;
        }

        /* Subtle background pattern */
        body::before {
            content: '';
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23000000' fill-opacity='0.025'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
            pointer-events: none;
            z-index: 0;
        }

        [data-theme="dark"] body::before {
            background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
        }

        /* Touch-friendly targets (48px minimum for accessibility) */
        .touch-target {
            min-height: 48px;
            min-width: 48px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: all 0.15s ease;
        }

        .touch-target:hover,
        .touch-target:active {
            background: var(--bg-surface);
        }

        /* Base card styles */
        .card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
        }

        /* ========================================
           ENHANCED TOUCH STATES
           ======================================== */

        /* Button press feedback with ripple */
        .btn:active {
            transform: scale(0.96);
            transition: transform 0.08s ease;
        }

        .touch-target:active {
            transform: scale(0.94);
        }

        .card:active {
            transform: scale(0.98);
        }

        /* Press highlight effect */
        .press-highlight {
            transition: background-color 0.15s ease, transform 0.15s ease;
        }

        .press-highlight:active {
            background-color: var(--bg-surface);
            transform: scale(0.98);
        }

        /* ========================================
           SCROLL-RELATED ANIMATIONS
           ======================================== */

        /* Sticky header that shrinks on scroll */
        .sticky-header {
            position: sticky;
            top: 0;
            background: var(--bg-card);
            border-bottom: 1px solid var(--border);
            transition: all 0.3s ease;
            z-index: 10;
        }

        .sticky-header.scrolled {
            padding-top: 8px;
            padding-bottom: 8px;
            box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
        }

        .sticky-header .header-title {
            transition: font-size 0.3s ease;
        }

        .sticky-header.scrolled .header-title {
            font-size: 18px;
        }

        /* ========================================
           VIEW TRANSITION ENHANCEMENTS
           ======================================== */

        .view-enter {
            animation: viewEnter 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        }

        @keyframes viewEnter {
            from {
                opacity: 0;
                transform: scale(0.98) translateY(8px);
            }
            to {
                opacity: 1;
                transform: scale(1) translateY(0);
            }
        }

        .view-exit {
            animation: viewExit 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        }

        @keyframes viewExit {
            from {
                opacity: 1;
                transform: scale(1) translateY(0);
            }
            to {
                opacity: 0;
                transform: scale(1.02) translateY(-8px);
            }
        }

        /* Slide transition for navigation */
        .slide-left-enter {
            animation: slideLeftEnter 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        }

        @keyframes slideLeftEnter {
            from {
                opacity: 0;
                transform: translateX(100%);
            }
            to {
                opacity: 1;
                transform: translateX(0);
            }
        }

        .slide-left-exit {
            animation: slideLeftExit 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        }

        @keyframes slideLeftExit {
            from {
                opacity: 1;
                transform: translateX(0);
            }
            to {
                opacity: 0;
                transform: translateX(-30%);
            }
        }

        /* Clean, flat cards */
        .card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 12px;
            transition: all 0.2s ease;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
        }

        .card-hover:hover {
            border-color: var(--primary);
            transform: translateY(-2px);
            box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
        }

        /* Enhanced drop zone with dragover feedback */
        .upload-zone {
            border: 2px dashed var(--border);
            border-radius: 8px;
            text-align: center;
            transition: all 0.2s ease;
            cursor: pointer;
        }

        .upload-zone:hover,
        .upload-zone.dragover {
            border-color: var(--primary);
            background: rgba(34, 197, 94, 0.08);
            transform: scale(1.02);
        }

        .upload-zone:active {
            transform: scale(0.98);
        }

        /* Gradient amount text */
        .amount-gradient {
            font-weight: 700;
            font-family: 'JetBrains Mono', monospace;
            background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            text-fill-color: transparent;
            letter-spacing: -0.02em;
            line-height: 1.2;
        }

        /* Merchant logo placeholder */
        .merchant-logo {
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 700;
        }

        /* ========================================
           MERCHANT BRANDING STYLES
           ======================================== */

        /* Merchant logo image */
        .merchant-logo-img {
            object-fit: contain;
            display: block;
        }

        /* Merchant initials fallback */
        .merchant-initials {
            transition: background-color 0.2s ease;
        }

        /* Merchant name display */
        #merchantNameDisplay {
            transition: color 0.2s ease;
        }

        /* Merchant branding bar */
        .merchant-branding-bar {
            display: flex;
            align-items: center;
            gap: 12px;
            padding-bottom: 12px;
            margin-bottom: 12px;
            border-bottom: 1px solid var(--border-subtle);
            transition: border-color 0.2s ease;
        }

        /* Merchant powered by text */
        .merchant-powered-by {
            font-size: 11px;
            font-weight: 500;
            letter-spacing: 0.02em;
            text-transform: uppercase;
            opacity: 0.8;
        }

        /* Camera viewfinder */
        .camera-viewfinder {
            background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
            position: relative;
        }

        .viewfinder-corner {
            position: absolute;
            width: 24px;
            height: 24px;
            border-color: var(--primary);
            border-style: solid;
            border-width: 0;
        }

        .viewfinder-corner.top-left {
            top: 16px;
            left: 16px;
            border-top-width: 3px;
            border-left-width: 3px;
            border-top-left-radius: 8px;
        }

        .viewfinder-corner.top-right {
            top: 16px;
            right: 16px;
            border-top-width: 3px;
            border-right-width: 3px;
            border-top-right-radius: 8px;
        }

        .viewfinder-corner.bottom-left {
            bottom: 80px;
            left: 16px;
            border-bottom-width: 3px;
            border-left-width: 3px;
            border-bottom-left-radius: 8px;
        }

        .viewfinder-corner.bottom-right {
            bottom: 80px;
            right: 16px;
            border-bottom-width: 3px;
            border-right-width: 3px;
            border-bottom-right-radius: 8px;
        }

        /* Progress bar */
        .progress-bar {
            background: var(--bg-surface);
            border-radius: 4px;
            overflow: hidden;
        }

        .progress-bar-fill {
            height: 100%;
            background: var(--primary);
            border-radius: 4px;
            transition: width 0.3s ease;
        }

        /* Confetti canvas */
        .confetti-canvas {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            pointer-events: none;
            z-index: 1000;
        }

        /* Language toggle buttons */
        .lang-btn {
            padding: 6px 12px;
            font-size: 13px;
            font-weight: 600;
            color: var(--text-muted);
            background: transparent;
            border: none;
            cursor: pointer;
            transition: all 0.15s ease;
        }

        .lang-btn:hover {
            color: var(--text-primary);
        }

        .lang-btn.active {
            color: var(--primary);
            background: var(--bg-surface);
        }

        /* Copy to clipboard button */
        .copy-btn {
            opacity: 0;
            transition: all 0.2s ease;
            cursor: pointer;
            padding: 4px;
            border-radius: 4px;
        }

        .copy-btn:hover {
            opacity: 1;
        }

        .copy-btn:active {
            transform: scale(0.9);
        }

        /* Toast notification */
        .toast {
            position: fixed;
            bottom: 24px;
            left: 50%;
            transform: translateX(-50%) translateY(100px);
            background: var(--text-primary);
            color: var(--bg-primary);
            padding: 12px 24px;
            border-radius: 8px;
            font-size: 14px;
            font-weight: 500;
            opacity: 0;
            transition: all 0.3s ease;
            z-index: 1000;
        }

        .toast.show {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }

        /* Timeout warning */
        .timeout-warning {
            position: fixed;
            top: 80px;
            left: 50%;
            transform: translateX(-50%) translateY(-20px);
            background: var(--warning-bg);
            color: var(--warning-text);
            padding: 12px 20px;
            border-radius: 8px;
            font-size: 14px;
            font-weight: 500;
            opacity: 0;
            transition: all 0.3s ease;
            z-index: 100;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .timeout-warning.show {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }

        .timeout-warning .pulse {
            width: 8px;
            height: 8px;
            background: var(--warning-text);
            border-radius: 50%;
            animation: pulse 1s ease infinite;
        }

        @keyframes pulse {
            0%, 100% { opacity: 1; transform: scale(1); }
            50% { opacity: 0.5; transform: scale(1.2); }
        }

        /* Pull to refresh indicator */
        .pull-refresh {
            position: fixed;
            top: 60px;
            left: 50%;
            transform: translateX(-50%) translateY(-100%);
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 8px;
            color: var(--text-muted);
            font-size: 13px;
            opacity: 0;
            transition: all 0.3s ease;
            z-index: 99;
        }

        .pull-refresh.show {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }

        .pull-refresh .spinner {
            width: 24px;
            height: 24px;
            border: 2px solid var(--border);
            border-top-color: var(--primary);
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        /* ========================================
           RIPPLE EFFECT FOR TOUCH FEEDBACK
           ======================================== */

        .ripple {
            position: relative;
            overflow: hidden;
        }

        .ripple::after {
            content: '';
            position: absolute;
            width: 100%;
            height: 100%;
            top: 0;
            left: 0;
            pointer-events: none;
            background-image: radial-gradient(circle, rgba(255, 255, 255, 0.3) 10%, transparent 10.01%);
            background-repeat: no-repeat;
            background-position: 50%;
            transform: scale(10, 10);
            opacity: 0;
            transition: transform 0.4s ease-out, opacity 0.4s ease-out;
        }

        .ripple:active::after {
            transform: scale(0, 0);
            opacity: 1;
            transition: 0s;
        }

        /* ========================================
           STAGGERED ENTRANCE ANIMATIONS
           ======================================== */

        .stagger-in > *:not(.payment-method-badge) {
            opacity: 0;
            transform: translateY(12px);
            animation: staggerIn 0.4s ease forwards;
        }

        .stagger-in > *:not(.payment-method-badge):nth-child(1) { animation-delay: 0.05s; }
        .stagger-in > *:not(.payment-method-badge):nth-child(2) { animation-delay: 0.1s; }
        .stagger-in > *:not(.payment-method-badge):nth-child(3) { animation-delay: 0.15s; }
        .stagger-in > *:not(.payment-method-badge):nth-child(4) { animation-delay: 0.2s; }
        .stagger-in > *:not(.payment-method-badge):nth-child(5) { animation-delay: 0.25s; }
        .stagger-in > *:not(.payment-method-badge):nth-child(6) { animation-delay: 0.3s; }
        .stagger-in > *:not(.payment-method-badge):nth-child(n+7) { animation-delay: 0.35s; }

        @keyframes staggerIn {
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        /* ========================================
           SWIPE-BACK NAVIGATION
           ======================================== */

        .swipe-back {
            transform: translateX(0);
            transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        }

        .swipe-back.swiping-left {
            transform: translateX(15%);
            opacity: 0.8;
        }

        .swipe-back.swiping-right {
            transform: translateX(-15%);
            opacity: 0.8;
        }

        /* ========================================
           BOTTOM SHEET MODAL
           ======================================== */

        .bottom-sheet {
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            background: var(--bg-card);
            border-radius: 20px 20px 0 0;
            box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.15);
            padding-bottom: max(20px, env(safe-area-inset-bottom));
            transform: translateY(100%);
            transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            z-index: 100;
            max-height: 85vh;
            overflow-y: auto;
        }

        .bottom-sheet.open {
            transform: translateY(0);
        }

        .bottom-sheet-handle {
            width: 40px;
            height: 4px;
            background: var(--border);
            border-radius: 2px;
            margin: 12px auto;
            cursor: pointer;
            transition: background 0.2s ease;
        }

        .bottom-sheet-handle:active {
            background: var(--text-muted);
        }

        /* ========================================
           ENHANCED FORM INPUT FOCUS STATES
           ======================================== */

        input,
        textarea,
        select {
            transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.1s ease;
        }

        input:focus,
        textarea:focus,
        select:focus {
            border-color: var(--primary);
            box-shadow: 0 0 0 3px rgba(22, 163, 78, 0.15);
            outline: none;
        }

        input:active,
        textarea:active,
        select:active {
            transform: scale(0.99);
        }

        /* ========================================
           KEYBOARD AVOIDANCE
           ======================================== */

        .avoid-keyboard {
            transition: transform 0.3s ease;
        }

        @supports (padding-bottom: env(safe-area-inset-bottom)) {
            .safe-bottom {
                padding-bottom: env(safe-area-inset-bottom);
            }
        }

        /* ========================================
           PERFORMANCE: WILL-CHANGE HINTS
           ======================================== */

        .view-transition {
            will-change: transform, opacity;
        }

        .card-hover:hover {
            will-change: transform, box-shadow;
        }

        .btn-primary:active,
        .btn-secondary:active {
            will-change: transform;
        }

        .skeleton {
            will-change: background-position;
        }

        .progress-bar-fill {
            will-change: width;
        }

        /* ========================================
           BOTTOM NAVIGATION (MOBILE)
           ======================================== */

        .bottom-nav {
            display: none;
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            background: var(--bg-card);
            border-top: 1px solid var(--border);
            padding: 12px 16px;
            padding-bottom: max(12px, env(safe-area-inset-bottom));
            z-index: 50;
            gap: 12px;
            will-change: transform;
        }

        .bottom-nav .nav-btn {
            flex: 1;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 6px;
            padding: 16px 12px;
            border-radius: 12px;
            transition: all 0.2s ease;
            cursor: pointer;
            border: none;
            background: transparent;
        }

        .bottom-nav .nav-btn:active {
            transform: scale(0.95);
        }

        .bottom-nav .nav-btn.active {
            background: var(--primary);
            color: white;
        }

        .bottom-nav .nav-btn svg {
            width: 24px;
            height: 24px;
        }

        .bottom-nav .nav-btn span {
            font-size: 13px;
            font-weight: 600;
        }

        /* Responsive: Show bottom nav on mobile */
        @media (max-width: 768px) {
            .bottom-nav {
                display: flex;
            }
        }

        /* ========================================
           LOADING SKELETONS
           ======================================== */

        /* Skeleton base with enhanced shimmer animation */
        .skeleton {
            background: linear-gradient(
                90deg,
                var(--bg-surface) 0%,
                rgba(125, 125, 125, 0.1) 50%,
                var(--bg-surface) 100%
            );
            background-size: 200% 100%;
            animation: shimmer 1.8s ease-in-out infinite;
            border-radius: 4px;
            will-change: background-position;
        }

        @keyframes shimmer {
            0% { background-position: -200% 0; }
            100% { background-position: 200% 0; }
        }

        /* Skeleton variants */
        .skeleton-text {
            height: 16px;
            width: 100%;
            margin-bottom: 8px;
        }

        .skeleton-text-sm {
            height: 14px;
            width: 60%;
            margin-bottom: 6px;
        }

        .skeleton-title {
            height: 24px;
            width: 70%;
            margin-bottom: 12px;
        }

        .skeleton-card {
            height: 80px;
            width: 100%;
            border-radius: 8px;
        }

        .skeleton-avatar {
            height: 48px;
            width: 48px;
            border-radius: 50%;
            flex-shrink: 0;
        }

        .skeleton-icon {
            height: 40px;
            width: 40px;
            border-radius: 8px;
            flex-shrink: 0;
        }

        .skeleton-rect {
            width: 100%;
            height: 60px;
            border-radius: 8px;
        }

        .skeleton-rect-lg {
            width: 100%;
            height: 120px;
            border-radius: 12px;
        }

        .skeleton-pill {
            height: 24px;
            width: 80px;
            border-radius: 12px;
        }

        .skeleton-button {
            height: 48px;
            width: 100%;
            border-radius: 12px;
        }

        /* Skeleton container - handles content fade-in */
        .skeleton-wrapper {
            position: relative;
        }

        /* Skeleton overlay - disabled for now */
        .skeleton-overlay {
            display: none;
        }

        /* Content fade-in after skeleton */
        .skeleton-content {
            opacity: 1;
        }

        /* Skeleton grid layouts */
        .skeleton-grid-2 {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 12px;
        }

        .skeleton-grid-4 {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 12px;
        }

        @media (min-width: 768px) {
            .skeleton-grid-4 {
                grid-template-columns: repeat(4, 1fr);
            }
        }

        /* Accessibility: Hide skeletons from screen readers */
        .skeleton, .skeleton-overlay {
            aria-hidden: "true";
        }

        /* Clean, flat cards */
        .card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
            transition: border-color 0.15s ease, transform 0.15s ease;
        }

        .card-hover:hover {
            border-color: var(--primary);
        }

        /* Flat buttons - Larger and more accessible */
        .btn-primary {
            background: var(--primary);
            color: white;
            padding: 18px 36px;
            border-radius: 12px;
            font-weight: 700;
            font-size: 32px;
            border: none;
            cursor: pointer;
            transition: background-color 0.15s ease, transform 0.15s ease;
            box-shadow: 0 2px 8px rgba(22, 163, 78, 0.2);
        }

        .btn-primary:hover:not(:disabled) {
            background: var(--primary-hover);
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(22, 163, 78, 0.25);
        }

        .btn-primary:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        .btn-secondary {
            background: transparent;
            color: var(--text-primary);
            padding: 18px 36px;
            border-radius: 12px;
            font-weight: 600;
            font-size: 18px;
            border: 2px solid var(--border);
            cursor: pointer;
            transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
        }

        .btn-secondary:hover {
            background: var(--bg-surface);
            border-color: var(--text-secondary);
            transform: translateY(-1px);
        }

        /* Status badges */
        .badge {
            padding: 6px 14px;
            border-radius: 6px;
            font-size: 14px;
            font-weight: 600;
        }

        .badge-success {
            background: var(--success-bg);
            color: var(--success-text);
        }

        .badge-warning {
            background: var(--warning-bg);
            color: var(--warning-text);
        }

        .badge-error {
            background: var(--error-bg);
            color: var(--error-text);
        }

        /* Animations */
        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        @keyframes slideUp {
            from {
                opacity: 0;
                transform: translateY(12px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @keyframes slideLeft {
            from {
                opacity: 0;
                transform: translateX(12px);
            }
            to {
                opacity: 1;
                transform: translateX(0);
            }
        }

        @keyframes drawCheck {
            from { stroke-dashoffset: 100; }
            to { stroke-dashoffset: 0; }
        }

        @keyframes spin {
            from { transform: rotate(0deg); }
            to { transform: rotate(360deg); }
        }

        /* Enhanced spinner with pulse effect */
        .spinner-enhanced {
            position: relative;
        }

        .spinner-enhanced::before {
            content: '';
            position: absolute;
            inset: -4px;
            border-radius: 50%;
            background: var(--primary);
            opacity: 0.1;
            animation: pulse-ring 1.5s ease-out infinite;
        }

        @keyframes pulse-ring {
            0% { transform: scale(0.8); opacity: 0.3; }
            100% { transform: scale(1.5); opacity: 0; }
        }

        /* Animated checkmark */
        .animate-draw-check {
            animation: drawCheck 0.6s ease-out forwards;
        }

        /* Button press animation */
        .btn-press:active {
            transform: scale(0.96);
            transition: transform 0.1s ease;
        }

        /* View transitions */
        .view-transition {
            transition: opacity 0.3s ease, transform 0.3s ease;
        }

        .view-hidden {
            opacity: 0;
            transform: translateY(10px);
            pointer-events: none;
        }

        .view-visible {
            opacity: 1;
            transform: translateY(0);
        }

        /* Security badge */
        .security-badge {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            padding: 5px 11px;
            background: transparent;
            color: var(--text-secondary);
            border-radius: 4px;
            font-size: 12px;
            font-weight: 500;
            border: 1px solid var(--border);
            transition: all 0.2s ease;
        }

        /* Focus indicator for keyboard navigation */
        :focus-visible {
            outline: 2px solid var(--primary);
            outline-offset: 2px;
        }

        /* Skip to main content link for accessibility */
        .skip-to-main {
            position: absolute;
            top: -40px;
            left: 0;
            background: var(--primary);
            color: white;
            padding: 8px 16px;
            z-index: 100;
            transition: top 0.3s;
        }

        .skip-to-main:focus {
            top: 0;
        }

        /* Ensure sufficient color contrast (WCAG AA) */
        [data-theme="dark"] {
            --text-primary: #fafafa;    /* #0a0a0a background = 16.6:1 */
            --text-secondary: #a3a3a3;  /* 7:1 contrast */
            --text-muted: #737373;       /* 5.5:1 contrast */
        }

        [data-theme="light"] {
            --text-primary: #171717;    /* #fafafa background = 15.5:1 */
            --text-secondary: #525252;   /* 7:1 contrast */
            --text-muted: #737373;       /* 5.5:1 contrast */
        }

        /* Payment method badge */
        .payment-method-badge {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 6px 12px;
            background: var(--bg-surface);
            color: var(--text-secondary);
            border-radius: 6px;
            font-size: 13px;
            font-weight: 600;
            border: 1px solid var(--border);
        }

        /* Success View - Information Architecture Improvements */
        /* Visual section dividers for better information hierarchy */
        .success-section {
            padding-bottom: 16px;
            margin-bottom: 16px;
            border-bottom: 1px solid var(--border-subtle);
        }

        .success-section:last-child {
            border-bottom: none;
            margin-bottom: 0;
            padding-bottom: 0;
        }

        /* Checkmark backdrop enhancement */
        .checkmark-backdrop {
            position: absolute;
            inset: -20px;
            border-radius: 50%;
            background: radial-gradient(
                circle,
                var(--success-bg) 0%,
                transparent 70%
            );
            animation: pulse-backdrop 2s ease-in-out infinite;
            z-index: -1;
        }

        @keyframes pulse-backdrop {
            0% {
                transform: scale(1);
                opacity: 0.5;
            }
            50% {
                transform: scale(1.2);
                opacity: 0.8;
            }
            100% {
                transform: scale(1);
                opacity: 0.5;
            }
        }

        /* Enhanced receipt preview card */
        .receipt-preview-card {
            background: linear-gradient(
                145deg,
                var(--bg-surface) 0%,
                var(--bg-card) 100%
            );
            border: 1px solid var(--border);
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
            transition: all 0.2s ease;
        }

        .receipt-preview-card:hover {
            border-color: var(--primary-muted);
            box-shadow:
                inset 0 1px 0 rgba(255, 255, 255, 0.5),
                0 2px 8px rgba(22, 163, 78, 0.1);
        }

        /* Checkmark container for backdrop positioning */
        .checkmark-container {
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        /* Success view header section */
        .success-header-section {
            text-align: center;
            padding-bottom: 16px;
            margin-bottom: 16px;
            border-bottom: 1px solid var(--border-subtle);
        }

        /* Success details section */
        .success-details-section {
            padding-bottom: 16px;
            margin-bottom: 16px;
            border-bottom: 1px solid var(--border-subtle);
        }

        /* Success actions section */
        .success-actions-section {
            padding-top: 8px;
        }

        /* Typography & Spacing Improvements (2.2) */
        /* Enhanced line height for better readability */
        .detail-row {
            line-height: 1.6;
        }

        .detail-group {
            margin-bottom: 12px;
        }

        .detail-group:last-child {
            margin-bottom: 0;
        }

        /* Information group with vertical rhythm */
        .information-group {
            margin-bottom: 16px;
        }

        .information-group:last-child {
            margin-bottom: 0;
        }

        .information-label {
            margin-bottom: 4px;
            line-height: 1.4;
        }

        .information-value {
            line-height: 1.5;
        }

        /* Enhanced detail spacing in success view */
        #successView .space-y-2 > div {
            line-height: 1.7;
        }

        #successView .detail-row {
            line-height: 1.6;
        }

        #successView .detail-row > span {
            line-height: 1.5;
        }

        /* Better text spacing for card content */
        .card-content {
            line-height: 1.6;
        }

        .card-content p {
            margin-bottom: 8px;
        }

        .card-content p:last-child {
            margin-bottom: 0;
        }

        /* Form and label improvements */
        .form-row {
            margin-bottom: 12px;
        }

        .form-row:last-child {
            margin-bottom: 0;
        }

        /* Payment details row improvements - more accessible for elderly */
        .payment-detail-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 12px 0;
            line-height: 1.6;
        }

        .payment-detail-row:not(:last-child) {
            border-bottom: 1px solid var(--border-subtle);
        }

        .payment-detail-label {
            color: var(--text-muted);
            font-size: 16px;
            line-height: 1.5;
            font-weight: 500;
        }

        .payment-detail-value {
            color: var(--text-primary);
            font-size: 18px;
            font-weight: 600;
            line-height: 1.5;
        }

        /* Large amount display - critical for accessibility */
        .amount-display {
            font-size: 28px !important;
            font-weight: 700;
            line-height: 1.2;
            letter-spacing: -0.02em;
        }

        /* Payment summary card - more prominent styling */
        .payment-summary-card {
            background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-surface) 100%);
            border: 2px solid var(--primary);
            border-radius: 16px;
            padding: 24px;
            box-shadow: 0 4px 20px rgba(22, 163, 78, 0.15);
        }

        /* Success view detail improvements */
        .success-detail-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 6px 0;
            line-height: 1.6;
        }

        .success-detail-item:last-child {
            padding-bottom: 0;
        }

        .success-detail-item:first-child {
            padding-top: 0;
        }

        /* Copy Button Enhancement (4.3) */
        /* Always-visible indicator with subtle opacity */
        .copy-indicator {
            opacity: 0.4;
            transition: opacity 0.2s ease, transform 0.15s ease;
        }

        .copy-indicator:hover {
            opacity: 1;
        }

        .copy-indicator:focus {
            opacity: 1;
            outline: 2px solid var(--primary);
            outline-offset: 2px;
            border-radius: 4px;
        }

        .copy-indicator:active {
            transform: scale(0.9);
        }

        /* Success state animation */
        .copy-success {
            color: var(--success-text) !important;
            opacity: 1 !important;
            animation: copySuccessPulse 0.3s ease;
        }

        @keyframes copySuccessPulse {
            0% {
                transform: scale(1);
            }
            50% {
                transform: scale(1.3);
            }
            100% {
                transform: scale(1);
            }
        }

        /* Copy button container for better positioning */
        .copy-btn-container {
            display: inline-flex;
            align-items: center;
            gap: 6px;
        }

        .copy-btn-wrapper {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 2px;
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .copy-btn-wrapper:hover {
            background: var(--bg-surface);
        }

        .copy-btn-wrapper:focus-visible {
            outline: 2px solid var(--primary);
            outline-offset: 2px;
        }

        /* Toast notification improvements */
        .toast-success {
            background: var(--success-bg);
            color: var(--success-text);
            border-left: 4px solid var(--success-text);
        }

        .toast-success .toast-icon {
            margin-right: 8px;
            display: inline-flex;
            align-items: center;
        }

        /* Copy feedback indicator */
        .copy-feedback {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            background: var(--success-text);
            color: var(--bg-card);
            padding: 4px 8px;
            border-radius: 4px;
            font-size: 12px;
            font-weight: 600;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.2s ease;
            white-space: nowrap;
            z-index: 10;
        }

        .copy-feedback.show {
            opacity: 1;
        }

        /* Copied Tooltip - appears above copy buttons */
        .copied-tooltip {
            background: var(--success-text);
            color: var(--bg-card);
            padding: 6px 12px;
            border-radius: 6px;
            font-size: 13px;
            font-weight: 600;
            white-space: nowrap;
            pointer-events: none;
            opacity: 0;
            transform: translateX(-50%) translateY(5px);
            transition: opacity 0.2s ease, transform 0.2s ease;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
            z-index: 1000;
        }

        .copied-tooltip::before {
            content: '';
            position: absolute;
            bottom: -6px;
            left: 50%;
            transform: translateX(-50%);
            border-width: 6px 6px 0;
            border-style: solid;
            border-color: var(--success-text) transparent transparent;
        }

        .copied-tooltip.show {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }

        /* Animated checkmark for copy success */
        .copy-btn-animated {
            position: relative;
        }

        .copy-btn-animated svg {
            transition: all 0.2s ease;
        }

        .copy-btn-animated.success svg {
            color: var(--success-text) !important;
            transform: scale(1.1);
        }

        /* ========================================
           IMPROVEMENT #1: ENHANCED ORDER CARD
           ======================================== */
        
        .order-card-enhanced {
            border-radius: 12px;
            box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
        }

        .merchant-header {
            display: flex;
            flex-direction: column;
            align-items: center;
            margin-bottom: 16px;
        }

        .order-info-card {
            background: var(--bg-surface);
            border-radius: 12px;
            padding: 20px;
            margin-bottom: 12px;
            border: 1px solid var(--border);
        }

        /* ========================================
           IMPROVEMENT #2: ENHANCED CAMERA VIEW
           ======================================== */

        .camera-instruction {
            background: linear-gradient(180deg, rgba(0,0,0,0.7) 0%, transparent 100%);
            backdrop-filter: blur(4px);
            padding: 12px 16px;
        }

        .camera-tips {
            background: linear-gradient(0deg, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.6) 100%);
            backdrop-filter: blur(8px);
            border-top: 1px solid rgba(255,255,255,0.1);
            padding: 16px;
        }

        .camera-controls {
            background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.5) 100%);
            padding: 12px 24px;
            backdrop-filter: blur(8px);
        }

        /* Larger capture button */
        .camera-controls button[aria-label="Capture image"] {
            width: 64px;
            height: 64px;
            transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
        }

        .camera-controls button[aria-label="Capture image"]:hover {
            transform: scale(1.05);
            box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
        }

        .camera-controls button[aria-label="Capture image"]:active {
            transform: scale(0.95);
        }

        .camera-controls button[aria-label="Capture image"] > div {
            width: 48px;
            height: 48px;
            transition: all 0.2s ease;
        }

        /* Control buttons with hover lift */
        .camera-controls button:not([aria-label="Capture image"]):hover {
            transform: translateY(-2px);
            background: rgba(255,255,255,0.3) !important;
        }

        .camera-controls button:not([aria-label="Capture image"]):active {
            transform: translateY(0) scale(0.95);
        }

        /* ========================================
           IMPROVEMENT #6: ENHANCED SUCCESS SCREEN
           ======================================== */

        .celebration-icons {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 8px;
            margin-bottom: 12px;
        }

        .celebration-icons span:first-child {
            animation: celebrationFloat 2s ease-in-out infinite;
            animation-delay: 0s;
        }

        .celebration-icons span:nth-child(2) {
            animation: celebrationBounce 1.5s ease-in-out infinite;
            animation-delay: 0.2s;
        }

        .celebration-icons span:last-child {
            animation: celebrationFloat 2s ease-in-out infinite;
            animation-delay: 0.4s;
        }

        @keyframes celebrationFloat {
            0%, 100% {
                transform: translateY(0) rotate(0deg);
            }
            50% {
                transform: translateY(-8px) rotate(10deg);
            }
        }

        @keyframes celebrationBounce {
            0%, 100% {
                transform: scale(1);
            }
            50% {
                transform: scale(1.2);
            }
        }

        .success-badge {
            box-shadow: 0 4px 20px rgba(22, 163, 78, 0.25);
            animation: successBadgePulse 2s ease-in-out infinite;
        }

        @keyframes successBadgePulse {
            0%, 100% {
                box-shadow: 0 4px 20px rgba(22, 163, 78, 0.25);
            }
            50% {
                box-shadow: 0 4px 30px rgba(22, 163, 78, 0.4);
            }
        }

        /* ========================================
           IMPROVEMENT #12: MICRO-INTERACTIONS
           ======================================== */

        /* Enhanced button press feedback */
        .btn-press {
            transition: all 0.1s cubic-bezier(0.4, 0, 0.2, 1);
        }

        .btn-press:active {
            transform: scale(0.96);
        }

        .btn-press:hover {
            filter: brightness(1.05);
        }

        /* Icon bounce on hover */
        .card-hover svg {
            transition: transform 0.2s ease;
        }

        .card-hover:hover svg {
            transform: scale(1.05);
        }

        /* Focus ring animation */
        :focus-visible {
            animation: focusRing 0.2s ease;
        }

        @keyframes focusRing {
            0% {
                outline-offset: 1px;
                opacity: 0.5;
            }
            100% {
                outline-offset: 2px;
                opacity: 1;
            }
        }

        /* Card entry animation */
        @keyframes cardSlideIn {
            from {
                opacity: 0;
                transform: translateY(10px);
            }
            to {
                opacity:1;
                transform: translateY(0);
            }
        }

        .card {
            animation: cardSlideIn 0.3s ease;
        }

        /* Success checkmark bounce */
        .animate-draw-check {
            animation: drawCheck 0.5s ease-out forwards, checkmarkBounce 0.3s ease 0.5s;
        }

        @keyframes checkmarkBounce {
            0% {
                transform: scale(1);
            }
            50% {
                transform: scale(1.1);
            }
            100% {
                transform: scale(1);
            }
        }

        /* Processing state shimmer */
        .skeleton {
            background: linear-gradient(
                90deg,
                var(--bg-surface) 0%,
                var(--border) 50%,
                var(--bg-surface) 100%
            );
            background-size: 200% 100%;
            animation: shimmer 1.5s ease-in-out infinite;
        }

        @keyframes shimmer {
            0% {
                background-position: 200% 0;
            }
            100% {
                background-position: -200% 0;
            }
        }

        /* Progress bar smooth animation */
        .progress-bar-fill {
            transition: width 0.3s ease-out;
        }

        /* Error shake animation */
        @keyframes errorShake {
            0%, 100% {
                transform: translateX(0);
            }
            10%, 30%, 50%, 70%, 90% {
                transform: translateX(-5px);
            }
            20%, 40%, 60%, 80% {
                transform: translateX(5px);
            }
        }

        .error-shake {
            animation: errorShake 0.5s ease-in-out;
        }

        /* Status badge transitions */
        .badge {
            transition: all 0.2s ease;
        }

        .badge:hover {
            filter: brightness(1.1);
            transform: scale(1.02);
        }

        /* Tooltip fade in */
        .copied-tooltip {
            animation: tooltipFadeIn 0.2s ease;
        }

        @keyframes tooltipFadeIn {
            from {
                opacity: 0;
                transform: translateX(-50%) translateY(5px);
            }
            to {
                opacity: 1;
                transform: translateX(-50%) translateY(0);
            }
        }

        /* Notification badge pulse */
        .notification-badge {
            animation: badgePulse 2s ease-in-out infinite;
        }

        @keyframes badgePulse {
            0%, 100% {
                transform: scale(1);
            }
            50% {
                transform: scale(1.05);
            }
        }

        /* Smooth page transitions */
        .animate-fade-in {
            animation: fadeIn 0.3s ease;
        }

        .animate-slide-up {
            animation: slideUp 0.3s ease;
        }

        /* Card hover glow effect */
        .card-hover:hover {
            box-shadow:
                0 2px 8px rgba(0, 0, 0, 0.06),
                0 0 0 1px rgba(22, 163, 78, 0.1);
        }

        /* ========================================
           MODAL RESPONSIVE STYLES
           ======================================== */

        /* Modal overlay */
        .modal-overlay {
            background: rgba(0, 0, 0, 0.6);
            backdrop-filter: blur(4px);
            transition: opacity 0.3s ease;
        }

        /* Modal content */
        .modal-content {
            background: var(--bg-card);
            border-radius: 12px;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
            max-height: 90vh;
            overflow-y: auto;
        }

        /* Mobile modal */
        @media (max-width: 600px) {
            .modal-content {
                margin: 16px;
                max-width: calc(100% - 32px);
                border-radius: 16px;
            }

            #qrCodeModal .modal-content {
                max-width: calc(100% - 32px);
                padding: 16px;
            }

            #transactionModal .modal-content {
                padding: 16px;
            }

            /* QR code image */
            #qrCodeModal #qrCodeImage {
                width: 200px !important;
                height: 200px !important;
            }

            /* QR code button text */
            #qrCodeModal .text-sm,
            #qrCodeModal .text-lg {
                font-size: 14px;
            }
        }

        /* Tablet modal */
        @media (min-width: 601px) and (max-width: 1023px) {
            .modal-content {
                margin: 24px;
                max-width: 500px;
            }

            #qrCodeModal .modal-content {
                max-width: 480px;
                padding: 20px;
            }

            #qrCodeModal #qrCodeImage {
                width: 220px !important;
                height: 220px !important;
            }
        }

        /* Desktop modal */
        @media (min-width: 1024px) {
            .modal-content {
                max-width: 550px;
            }

            #qrCodeModal .modal-content {
                max-width: 520px;
                padding: 24px;
            }

            #qrCodeModal #qrCodeImage {
                width: 260px !important;
                height: 260px !important;
            }
        }

        /* Modal close button */
        .modal-content button[onclick*="close"] {
            min-width: 40px;
            min-height: 40px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 8px;
            transition: all 0.2s ease;
        }

        .modal-content button[onclick*="close"]:hover {
            background: var(--bg-surface);
            transform: rotate(90deg);
        }

        /* Modal action buttons */
        #qrCodeModal button,
        #transactionModal button {
            min-height: 44px;
            padding: 12px 20px;
            font-size: 15px;
            font-weight: 600;
            border-radius: 8px;
            transition: all 0.2s ease;
        }

        #qrCodeModal button:hover,
        #transactionModal button:hover {
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }

        /* Transaction timeline */
        #transactionModal .w-2 {
            min-width: 8px;
            min-height: 8px;
        }

        /* Timeline spacing */
        #transactionModal .space-y-4 > div {
            padding-bottom: 8px;
        }

        /* Mobile timeline adjustments */
        @media (max-width: 600px) {
            #transactionModal .space-y-4 {
                gap: 12px;
            }

            #transactionModal .space-y-4 > div {
                padding-bottom: 0;
            }

            #transactionModal .text-sm {
                font-size: 14px;
            }

            #transactionModal .text-xs {
                font-size: 12px;
            }
        }

        /* Focus indicators for modals */
        .modal-content button:focus-visible,
        .modal-content input:focus-visible {
            outline: 2px solid var(--primary);
            outline-offset: 2px;
        }

        /* Dark theme modal enhancements */
        [data-theme="dark"] .modal-overlay {
            background: rgba(0, 0, 0, 0.7);
        }

[data-theme="dark"] .modal-content {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* ========================================
   UTILITY: RIPPLE ANIMATION KEYFRAME
   ======================================== */

@keyframes rippleEffect {
    from {
        transform: scale(0);
        opacity: 0.5;
    }
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* ========================================
   TRUST BADGE STYLES
   ======================================== */

.trust-badge-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: linear-gradient(135deg, var(--success-bg) 0%, rgba(34, 197, 94, 0.08) 100%);
    color: var(--success-text);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    border: 1px solid rgba(34, 197, 94, 0.2);
    transition: all 0.2s ease;
}

.trust-badge-inline:hover {
    border-color: rgba(34, 197, 94, 0.3);
    background: linear-gradient(135deg, var(--success-bg) 0%, rgba(34, 197, 94, 0.12) 100%);
    transform: translateY(-1px);
}

.trust-badge-inline svg {
    flex-shrink: 0;
}

.trust-badge-text {
    line-height: 1.3;
}

/* Dark theme trust badge */
[data-theme="dark"] .trust-badge-inline {
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.25);
}

[data-theme="dark"] .trust-badge-inline:hover {
    background: rgba(34, 197, 94, 0.16);
}


/* ========================================
   TRUST BADGES
   ======================================== */

/* Primary Trust Badge - Payment Instructions */
.trust-badge-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(135deg, var(--success-bg) 0%, rgba(22, 163, 78, 0.08) 100%);
    color: var(--success-text);
    border: 1px solid var(--success-text);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
    animation: trustBadgeFadeIn 0.5s ease-out;
}

.trust-badge-inline:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(22, 163, 78, 0.15);
}

.trust-badge-text {
    line-height: 1.3;
}

@keyframes trustBadgeFadeIn {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* AI Verification Badge - Processing View */
.ai-verification-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: var(--bg-surface);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.ai-verification-badge.processing {
    border-color: var(--primary);
    background: rgba(22, 163, 78, 0.05);
}

.ai-verification-badge.verified {
    border-color: var(--success-text);
    background: var(--success-bg);
    color: var(--success-text);
}

.ai-badge-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.ai-badge-text {
    line-height: 1.3;
}

.ai-verification-badge.processing .ai-badge-icon svg {
    color: var(--primary);
    animation: aiPulse 1.5s ease-in-out infinite;
}

.ai-verification-badge.verified .ai-badge-icon svg {
    color: var(--success-text);
    animation: none;
}

@keyframes aiPulse {
    0%, 100% {
        opacity: 0.6;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

/* Confidence Score */
.ai-confidence {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    background: var(--bg-card);
    color: var(--success-text);
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    margin-left: 4px;
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
}

.ai-confidence.show {
    opacity: 1;
    transform: translateX(0);
}

/* Verified Seal - Success View */
.verified-seal {
    display: inline-flex;
    justify-content: center;
    padding: 8px;
    position: relative;
    animation: sealStamp 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.seal-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 8px 16px;
    background: linear-gradient(135deg, var(--success-bg) 0%, rgba(22, 163, 78, 0.15) 100%);
    border: 2px solid var(--success-text);
    border-radius: 8px;
    transform: rotate(-3deg);
    box-shadow: 0 2px 8px rgba(22, 163, 78, 0.2);
    transition: all 0.3s ease;
}

.seal-inner:hover {
    transform: rotate(0deg) scale(1.02);
    box-shadow: 0 4px 16px rgba(22, 163, 78, 0.3);
}

.seal-inner svg {
    color: var(--success-text);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.seal-text {
    font-size: 11px;
    font-weight: 700;
    color: var(--success-text);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

@keyframes sealStamp {
    0% {
        opacity: 0;
        transform: scale(0.5) rotate(-15deg);
    }
    50% {
        transform: scale(1.1) rotate(-2deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(-3deg);
    }
}

/* Trust Badge Animations */
.trust-badge-pulse {
    animation: trustPulse 2s ease-in-out infinite;
}

@keyframes trustPulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(22, 163, 78, 0.2);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(22, 163, 78, 0);
    }
}

/* Security Statement Badge */
.security-statement {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 500;
}

/* Accessibility: Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .trust-badge-inline,
    .ai-verification-badge.processing .ai-badge-icon svg,
    .verified-seal,
    .ai-confidence {
        animation: none !important;
        transition: none !important;
    }

    .trust-badge-inline:hover,
    .seal-inner:hover {
        transform: none !important;
    }
}

/* Dark mode trust badge enhancements */
[data-theme="dark"] .trust-badge-inline {
    background: linear-gradient(135deg, rgba(20, 83, 45, 0.4) 0%, rgba(20, 83, 45, 0.2) 100%);
}

[data-theme="dark"] .ai-verification-badge.processing {
    background: rgba(34, 197, 94, 0.1);
}

[data-theme="dark"] .seal-inner {
    background: linear-gradient(135deg, rgba(20, 83, 45, 0.5) 0%, rgba(20, 83, 45, 0.3) 100%);
}
