/* ═══════════════════════════════════════════════════════
   BGrade UPI Receipt Maker — Modern Design System (Mobile-First)
   ═══════════════════════════════════════════════════════ */

:root {
    --bg: #f8fafc;
    --surface: rgba(255, 255, 255, 0.75);
    --surface-s: #ffffff;
    --muted-bg: #f1f5f9;
    --text: #0f172a;
    --muted: #64748b;
    --border: rgba(99, 102, 241, 0.15);
    
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-light: rgba(99, 102, 241, 0.08);
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    --r-sm: 8px;
    --r-md: 14px;
    --r-lg: 20px;
    --r-xl: 28px;
    
    --shadow: 0 8px 32px rgba(99, 102, 241, 0.06);
    --blur: blur(16px);
    --ease: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --bg: #0f172a;
    --surface: rgba(30, 41, 59, 0.75);
    --surface-s: #1e293b;
    --muted-bg: #1e293b;
    --text: #f1f5f9;
    --muted: #94a3b8;
    --border: rgba(129, 140, 248, 0.25);
    
    --primary: #818cf8;
    --primary-hover: #a5b4fc;
    --primary-light: rgba(129, 140, 248, 0.12);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.5;
    transition: background-color 0.3s, color 0.3s;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ── Animated Background Blobs ── */
.bg-blob {
    position: fixed;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    filter: blur(100px);
    animation: blobAnimation 25s infinite alternate;
}

.blob-1 {
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15), transparent 70%);
    top: -150px;
    right: -150px;
}

.blob-2 {
    background: radial-gradient(circle, rgba(168, 85, 247, 0.12), transparent 70%);
    bottom: -150px;
    left: -150px;
    animation-delay: -12s;
}

@keyframes blobAnimation {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(60px, 100px) scale(1.15); }
    100% { transform: translate(-40px, 40px) scale(0.9); }
}

/* ── Page Wrap & Layout ── */
.page-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 1rem 2rem 1rem; /* Top padding for global nav */
}

/* Hero Section */
.app-hero {
    text-align: center;
    margin-bottom: 2.5rem;
    animation: fadeInUp 0.8s ease;
}

.app-hero h1 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    margin-bottom: 0.5rem;
    color: var(--text);
}

.app-hero h1 span {
    background: linear-gradient(135deg, var(--primary), #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.badge-premium {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    margin-bottom: 0.75rem;
    border: 1px solid var(--border);
}

.subtitle {
    color: var(--muted);
    font-size: clamp(0.95rem, 2vw, 1.1rem);
    max-width: 680px;
    margin: 0 auto;
}

/* Container */
.app-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 3.5rem;
}

@media (min-width: 1024px) {
    .app-container {
        flex-direction: row;
        align-items: flex-start;
    }
}

/* Left Panel */
.panel-left {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

@media (min-width: 1024px) {
    .panel-left {
        width: 46%;
    }
}

/* Glass panel */
.glass-panel {
    background: var(--surface);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: var(--r-xl);
    box-shadow: var(--shadow);
    transition: var(--ease);
}

.glass-panel:hover {
    border-color: rgba(99, 102, 241, 0.3);
}

.card {
    padding: clamp(1.25rem, 3vw, 2rem);
}

.card h2 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.15rem, 2vw, 1.35rem);
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text);
}

.card h2 i {
    color: var(--primary);
}

.highlight-card {
    border-color: rgba(99, 102, 241, 0.4);
    background: linear-gradient(135deg, var(--surface), rgba(99, 102, 241, 0.05));
}

.badge-ai {
    font-size: 0.7rem;
    background: linear-gradient(135deg, #a855f7, #6366f1);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    margin-left: auto;
}

.subtext {
    font-size: 0.85rem;
    color: var(--muted);
    margin-bottom: 1rem;
    margin-top: -0.75rem;
}

/* Upload Zone */
.upload-zone {
    border: 2px dashed var(--border);
    border-radius: var(--r-md);
    padding: 2rem 1rem;
    text-align: center;
    cursor: pointer;
    transition: var(--ease);
    background: var(--muted-bg);
}

.upload-zone:hover {
    border-color: var(--primary);
    background: var(--primary-light);
}

.upload-zone i {
    font-size: 2.25rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.upload-zone .text-sm {
    font-size: 0.8rem;
    color: var(--muted);
    margin-top: 0.5rem;
}

.status-banner {
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    border-radius: var(--r-sm);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.status-banner.hidden {
    display: none;
}

.status-loading {
    background: var(--primary-light);
    color: var(--primary);
    border: 1px solid var(--border);
}

.status-success {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.status-error {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Form Elements */
.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 640px) {
    .form-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.form-group input, 
.form-group select, 
.form-group textarea {
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--border);
    border-radius: var(--r-sm);
    font-family: inherit;
    font-size: 0.95rem;
    transition: var(--ease);
    background: var(--surface-s);
    color: var(--text);
}

.form-group input:focus, 
.form-group select:focus, 
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.checkbox-group {
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.checkbox-group input[type="checkbox"] {
    width: 1.15rem;
    height: 1.15rem;
    accent-color: var(--primary);
    cursor: pointer;
}

.checkbox-group label {
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
}

.tooltip {
    color: var(--muted);
    cursor: help;
}

/* Template Selector */
.template-selector {
    display: flex;
    gap: 1.25rem;
    background: var(--muted-bg);
    padding: 0.5rem 1rem;
    border-radius: var(--r-sm);
    border: 1px solid var(--border);
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.9rem;
    cursor: pointer;
    font-weight: 500;
}

.radio-label input[type="radio"] {
    accent-color: var(--primary);
    cursor: pointer;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--r-md);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: none;
    transition: var(--ease);
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--surface-s);
    color: var(--text);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--muted-bg);
}

.btn-success {
    background: #25D366; /* WhatsApp Green */
    color: white;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.2);
}

.btn-success:hover {
    background: #128C7E;
    transform: translateY(-1px);
}

/* Right Panel / Preview */
.panel-right {
    width: 100%;
}

@media (min-width: 1024px) {
    .panel-right {
        width: 54%;
        position: sticky;
        top: 90px; /* offset for global-navbar */
    }
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
}

.preview-header h2 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.15rem, 2vw, 1.35rem);
}

.desktop-actions {
    display: none;
}

@media (min-width: 1024px) {
    .desktop-actions {
        display: flex;
        gap: 0.5rem;
    }
}

/* Receipt Wrapper */
.receipt-wrapper {
    display: flex;
    justify-content: center;
    padding: 2rem;
    background: var(--muted-bg);
    border-radius: var(--r-xl);
    border: 1px solid var(--border);
    overflow-x: auto;
    margin-bottom: 1.5rem;
    transition: var(--ease);
}

/* ── ACTUAL PHYSICAL RECEIPT STYLES ── */
.receipt {
    width: 100%;
    max-width: 380px;
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    color: #1e293b;
    font-family: 'Inter', sans-serif;
    transition: var(--ease);
}

.receipt .watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-30deg);
    font-size: 7.5rem;
    font-weight: 900;
    color: rgba(16, 185, 129, 0.05); /* very faint green */
    pointer-events: none;
    user-select: none;
    z-index: 0;
    white-space: nowrap;
    display: none;
}

.receipt.is-paid .watermark {
    display: block;
}

.receipt * {
    position: relative;
    z-index: 1;
}

.receipt-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.receipt-business h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.4rem;
    margin-bottom: 0.25rem;
    color: #4f46e5;
}

.receipt-title {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-bottom: 1rem;
    text-transform: uppercase;
    color: #475569;
}

.receipt-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #64748b;
    background: #f8fafc;
    padding: 0.5rem;
    border-radius: 6px;
    border: 1px solid #f1f5f9;
}

.divider {
    border: none;
    border-top: 1px dashed #cbd5e1;
    margin: 1.25rem 0;
}

.receipt-amount-section {
    text-align: center;
}

.amount-wrap {
    font-family: 'Outfit', sans-serif;
    font-size: 2.85rem;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.currency {
    font-size: 1.85rem;
    margin-right: 0.15rem;
    color: #64748b;
}

.amount-words {
    font-size: 0.8rem;
    color: #475569;
    margin-top: 0.4rem;
    text-transform: capitalize;
    font-weight: 600;
}

.status-badge {
    display: inline-block;
    margin-top: 0.85rem;
    padding: 0.35rem 0.85rem;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.status-badge.status-success { background: #d1fae5; color: #065f46; }
.status-badge.status-pending { background: #fef3c7; color: #92400e; }
.status-badge.status-failed { background: #fee2e2; color: #991b1b; }

.receipt-txn-info {
    text-align: center;
    margin-top: 0.85rem;
    font-size: 0.8rem;
    color: #475569;
}

.receipt-txn-info p { margin-bottom: 0.25rem; }
.receipt-txn-info strong { color: #0f172a; font-family: monospace; font-size: 0.85rem; }
.app-via strong { font-family: 'Inter', sans-serif; }

.receipt-parties {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.party-label {
    font-size: 0.72rem;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
    font-weight: 500;
}

.party-val {
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.15rem;
    color: #0f172a;
}

.party-sub {
    font-size: 0.78rem;
    color: #64748b;
    word-break: break-all;
}

.receipt-description {
    margin-bottom: 0.5rem;
}

.desc-label {
    font-size: 0.72rem;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
    font-weight: 500;
}

.desc-val {
    font-weight: 500;
    font-size: 0.88rem;
    color: #334155;
}

.receipt-gst {
    background: #f8fafc;
    padding: 0.85rem;
    border-radius: 8px;
    margin-top: 0.85rem;
    border: 1px solid #f1f5f9;
}

.gst-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    margin-bottom: 0.35rem;
    color: #475569;
}

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

.gst-row.total {
    margin-top: 0.4rem;
    padding-top: 0.4rem;
    border-top: 1px solid #e2e8f0;
    font-weight: 700;
    color: #0f172a;
}

.receipt-footer {
    text-align: center;
    margin-top: 1.75rem;
}

.thank-you {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.35rem;
    color: #1e293b;
}

.address {
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 1.25rem;
    white-space: pre-wrap;
    line-height: 1.4;
}

.branding {
    font-size: 0.65rem;
    color: #94a3b8;
}

/* Template Variations */
.template-classic {
    border-top: 8px solid #6366f1;
}

.template-minimal {
    border: 1px solid #e2e8f0;
    box-shadow: none;
}
.template-minimal .receipt-business h2 {
    color: #0f172a;
}

.template-bold {
    background: #0f172a;
    color: #f8fafc;
}
.template-bold .receipt-business h2 { color: white; }
.template-bold .receipt-title { color: #cbd5e1; }
.template-bold .amount-wrap { color: white; }
.template-bold .party-val, .template-bold .desc-val, .template-bold .gst-row.total { color: white; }
.template-bold .divider { border-color: #334155; }
.template-bold .receipt-meta, .template-bold .receipt-gst { background: #1e293b; border-color: #334155; }
.template-bold .status-badge.status-success { background: #10b981; color: white; }
.template-bold .watermark { color: rgba(255,255,255,0.03); }


/* Mobile Bottom Action Bar */
.mobile-actions-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface-s);
    padding: 0.85rem;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 0.5rem;
    z-index: 100;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.05);
}

.mobile-actions-bar .btn {
    flex: 1;
    font-size: 0.82rem;
    padding: 0.65rem;
}

@media (min-width: 1024px) {
    .mobile-actions-bar {
        position: relative;
        border-top: none;
        box-shadow: none;
        padding: 1rem 0 0 0;
        background: transparent;
    }
    .mobile-actions-bar .btn {
        font-size: 0.95rem;
        padding: 0.75rem 1.5rem;
    }
}

/* ── SEO content-section ── */
.content-section {
    padding: clamp(2rem, 5vw, 4rem) 0;
    border-top: 1px solid var(--border);
    animation: fadeInUp 0.8s ease;
}

.section-title {
    text-align: center;
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    font-weight: 800;
    margin-bottom: 2rem;
    font-family: 'Outfit', sans-serif;
}

.section-title span {
    background: linear-gradient(135deg, var(--primary), #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(1rem, 3vw, 1.5rem);
}

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

.feature-card {
    padding: clamp(1.5rem, 3vw, 2rem);
    border-radius: var(--r-xl);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.feature-card h3 {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    font-weight: 700;
}

.feature-card p {
    font-size: clamp(0.85rem, 2vw, 0.9rem);
    color: var(--muted);
    line-height: 1.6;
}

/* FAQ accordion */
.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    max-width: 760px;
    margin: 0 auto;
}

.faq-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    overflow: hidden;
    transition: var(--ease);
}

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

.faq-question {
    padding: 1rem 1.25rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    transition: var(--ease);
    font-size: clamp(0.9rem, 2vw, 1rem);
    font-family: 'Outfit', sans-serif;
    color: var(--text);
}

.faq-question i {
    transition: var(--ease);
    color: var(--muted);
}

.faq-item.active .faq-question {
    color: var(--primary);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
    color: var(--primary);
}

.faq-answer {
    padding: 0 1.25rem 1rem 1.25rem;
    color: var(--muted);
    font-size: clamp(0.85rem, 2vw, 0.9rem);
    line-height: 1.65;
    display: none;
}

.faq-item.active .faq-answer {
    display: block;
}

/* Testimonials / Feedback Grid */
.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(1rem, 3vw, 1.5rem);
}

@media (min-width:640px) {
    .testimonials-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

.testimonial-card {
    padding: clamp(1.25rem, 3vw, 1.75rem);
    border-radius: var(--r-xl);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.testimonial-quote {
    font-style: italic;
    line-height: 1.7;
    font-size: clamp(0.85rem, 2vw, 0.95rem);
}

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

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1rem;
}

.user-info h4 {
    font-size: 0.9rem;
    font-weight: 700;
}

.user-info p {
    font-size: 0.75rem;
    color: var(--muted);
}

/* Feedback form */
.feedback-form-wrap {
    max-width: 580px;
    margin: 0 auto;
    padding: clamp(1.5rem, 3vw, 2.5rem);
    text-align: center;
}

.feedback-form-wrap h3 {
    font-size: clamp(1.25rem, 4vw, 1.6rem);
    margin-bottom: 0.5rem;
    font-family: 'Outfit', sans-serif;
}

.feedback-form-wrap h3 span {
    background: linear-gradient(135deg, var(--primary), #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.feedback-form-wrap > p {
    color: var(--muted);
    margin-bottom: 1.5rem;
    font-size: clamp(0.85rem, 2vw, 0.95rem);
}

.form-fields {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.form-fields input,
.form-fields textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border-radius: var(--r-md);
    border: 1px solid var(--border);
    background: var(--surface-s);
    color: var(--text);
    font-family: inherit;
    font-size: 0.95rem;
    transition: var(--ease);
}

.form-fields textarea {
    min-height: 100px;
    resize: vertical;
}

.form-fields input:focus,
.form-fields textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.star-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--muted);
    flex-wrap: wrap;
}

.stars {
    display: flex;
    gap: 4px;
    font-size: 1.5rem;
    color: #fbbf24;
    cursor: pointer;
}

/* Footer styling */
.footer {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    margin-top: 2rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--ease);
}

.footer-links a:hover {
    color: var(--primary);
}

.copyright {
    font-size: 0.8rem;
    color: var(--muted);
}

/* Toast Notification */
.toast-container {
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toast {
    padding: 0.85rem 1.25rem;
    border-radius: var(--r-md);
    font-size: 0.9rem;
    font-weight: 600;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    animation: slideIn 0.3s ease forwards;
    border: 1px solid transparent;
}

.toast.success {
    background: #d1fae5;
    color: #065f46;
    border-color: rgba(16, 185, 129, 0.2);
}

.toast.error {
    background: #fee2e2;
    color: #991b1b;
    border-color: rgba(239, 68, 68, 0.2);
}

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

/* Loading Spinner for AI loader */
.ai-loader {
    width: 36px;
    height: 36px;
    border: 3px solid var(--border);
    border-radius: 50%;
    border-top-color: var(--primary);
    animation: spin 1s ease-in-out infinite;
    margin: 2rem auto;
    grid-column: 1 / -1;
}

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

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

/* Spacer for mobile fixed bar */
.app-footer-spacer {
    height: 70px;
}

@media (min-width: 1024px) {
    .app-footer-spacer {
        display: none;
    }
}

/* Feedback Filters */
.feedback-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 2rem;
    width: 100%;
}
.feedback-filter {
    background: var(--surface-s);
    border: 1px solid var(--border);
    padding: 0.5rem 1.1rem;
    border-radius: 99px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--muted);
    cursor: pointer;
    transition: var(--ease);
}
.feedback-filter.active,
.feedback-filter:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 6px 15px -4px rgba(99, 102, 241, 0.4);
}

