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

:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary-color: #ec4899;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -1px rgb(0 0 0 / 0.06);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -2px rgb(0 0 0 / 0.05);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 10px 10px -5px rgb(0 0 0 / 0.04);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --gradient-accent: linear-gradient(135deg, #6366f1 0%, #ec4899 100%);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--gradient-accent);
    min-height: 100vh;
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: 'kern' 1;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
    /* Better mobile touch handling */
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    -webkit-touch-callout: none;
    touch-action: manipulation;
}

.container {
    width: 100%;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

.page {
    display: none;
    animation: fadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.page.active {
    display: block;
}

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

/* Landing Page */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.hero-content {
    max-width: 750px;
    text-align: center;
    animation: floatIn 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.logo {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3.75rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1rem;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    letter-spacing: -0.02em;
}

.tagline {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 3rem;
    font-weight: 400;
    letter-spacing: -0.01em;
    line-height: 1.5;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.stats {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.75rem 2rem;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    min-width: 160px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.stat:hover {
    transform: translateY(-4px) scale(1.02);
    background: rgba(255, 255, 255, 0.22);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.stat-number {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: white;
    letter-spacing: -0.02em;
}

.stat-label {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 0.5rem;
    font-weight: 500;
}

.auth-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
    width: 100%;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.btn-oauth {
    font-family: 'Inter', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    background: white;
    color: #1e293b;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(0, 0, 0, 0.06);
    /* Better mobile touch */
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
    min-height: 48px; /* iOS recommended minimum touch target */
}

.btn-oauth:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15), 0 4px 8px rgba(0, 0, 0, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-oauth:active {
    transform: translateY(-1px);
}

.btn-oauth svg {
    flex-shrink: 0;
}

.btn-oauth.loading {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-google:hover {
    background: #f8f9fa;
}

.btn-microsoft:hover {
    background: #f8f9fa;
}

.btn-primary {
    font-family: 'Inter', sans-serif;
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: white;
    background: var(--primary-color);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.btn-primary:active {
    transform: translateY(-1px);
}

.btn-primary:disabled,
.btn-primary.loading {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.privacy-note {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.lock-icon {
    stroke: rgba(255, 255, 255, 0.9);
}

.features {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 3rem;
}

.feature {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    color: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    padding: 1rem 1.5rem;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 14px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.feature:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.feature-icon {
    stroke: rgba(255, 255, 255, 0.95);
    flex-shrink: 0;
}

.powered-by-landing {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    margin-top: 3rem;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9375rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.powered-by-landing:hover {
    color: white;
}

.powered-logo-landing {
    height: 36px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
    opacity: 0.9;
    transition: all 0.3s ease;
}

.powered-by-landing:hover .powered-logo-landing {
    opacity: 1;
    transform: scale(1.05);
}


/* Loading Page */
.loading-content {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.spinner {
    width: 80px;
    height: 80px;
    border: 6px solid rgba(255, 255, 255, 0.2);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 2.5rem;
}

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

.loading-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2rem;
    color: white;
    margin-bottom: 1rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.loading-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.125rem;
    font-weight: 400;
    margin-bottom: 2rem;
}

.progress-bar {
    width: 100%;
    max-width: 500px;
    height: 10px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, white, rgba(255, 255, 255, 0.9));
    width: 0%;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Results Page */
.results-header {
    background: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border-color);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 2rem;
}

.logo-small {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
    transition: transform 0.2s ease;
    cursor: pointer;
}

.logo-small:hover {
    transform: scale(1.02);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: var(--bg-secondary);
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.user-email {
    color: var(--text-primary);
    font-size: 0.9375rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-email::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--success-color);
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

.powered-by {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.powered-by:hover {
    color: var(--text-primary);
}

.powered-logo {
    height: 32px;
    width: auto;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.powered-by:hover .powered-logo {
    transform: scale(1.05);
}

.btn-logout {
    font-family: 'Inter', sans-serif;
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    color: white;
    background: var(--primary-color);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
    white-space: nowrap;
}

.btn-logout:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.btn-logout:active {
    transform: translateY(0);
}

.results-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem;
    background: var(--bg-secondary);
    min-height: calc(100vh - 100px);
}

.summary {
    margin-bottom: 2rem;
}

.summary h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.875rem;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: white;
    padding: 2rem;
    border-radius: 18px;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06), 0 2px 4px rgba(0, 0, 0, 0.04);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border-left: 5px solid var(--primary-color);
    position: relative;
    overflow: hidden;
}

.summary-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.03) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.summary-card:hover::before {
    opacity: 1;
}

.summary-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08), 0 4px 8px rgba(124, 58, 237, 0.05);
    transform: translateY(-4px) scale(1.01);
    border-left-width: 6px;
}

.summary-icon {
    stroke: var(--primary-color);
    flex-shrink: 0;
}

.summary-info {
    display: flex;
    flex-direction: column;
}

.summary-number {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.summary-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    font-weight: 500;
}

.filters {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.filter-btn {
    font-family: 'Inter', sans-serif;
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
    border: 2px solid transparent;
    background: white;
    color: var(--text-secondary);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, rgba(167, 139, 250, 0.08) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.filter-btn:hover::before {
    opacity: 1;
}

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

.filter-btn.active {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-color: var(--primary-color);
    color: white;
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.3);
}

.filter-btn.active::before {
    opacity: 0;
}

.deals-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.btn-load-more {
    font-family: 'Inter', sans-serif;
    display: block;
    margin: 2rem auto;
    padding: 1rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
    min-height: 48px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.btn-load-more:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.btn-load-more:active {
    transform: translateY(0) scale(0.98);
}

.deal-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.deal-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light), #f093fb);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.deal-card:hover::before {
    opacity: 1;
}

.deal-card:hover {
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12), 0 8px 16px rgba(124, 58, 237, 0.1);
    transform: translateY(-6px);
    border-color: rgba(124, 58, 237, 0.1);
}

.deal-card.expiring-soon {
    border: 2px solid rgba(245, 158, 11, 0.3);
    background: linear-gradient(to bottom, rgba(254, 243, 199, 0.3) 0%, white 20%);
}

.deal-header {
    padding: 1.75rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.deal-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-10%, -10%); }
}

.deal-merchant {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.deal-category {
    font-size: 0.875rem;
    opacity: 0.9;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: rgba(255, 255, 255, 0.2);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
}

.category-icon {
    stroke: currentColor;
    flex-shrink: 0;
}

.deal-body {
    padding: 1.5rem;
}

.deal-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    letter-spacing: -0.01em;
}

.deal-description {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.5;
    font-weight: 400;
}

.deal-details {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.deal-detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.deal-detail-icon {
    stroke: var(--primary-color);
    flex-shrink: 0;
}

.deal-code {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.05) 0%, rgba(167, 139, 250, 0.05) 100%);
    padding: 1rem 1.25rem;
    border-radius: 12px;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Mono', 'Droid Sans Mono', 'Source Code Pro', 'Courier New', monospace;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
    margin-top: 1.25rem;
    border: 2px dashed rgba(124, 58, 237, 0.3);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    letter-spacing: 0.08em;
    font-size: 1rem;
    position: relative;
    overflow: hidden;
}

.deal-code::before {
    content: 'Click to copy';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(124, 58, 237, 0.95);
    color: white;
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    font-family: 'Inter', sans-serif;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
    white-space: nowrap;
}

.deal-code:hover::before {
    opacity: 1;
}

.deal-code:hover {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border-color: var(--primary-color);
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.25);
}

.deal-code:active {
    transform: scale(0.98);
}

.deal-code:hover .code-icon {
    stroke: white;
}

.code-icon {
    stroke: var(--primary-color);
    transition: stroke 0.3s ease;
}

.deal-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9375rem;
    margin-top: 1rem;
    transition: all 0.2s ease;
    justify-content: center;
}

.deal-cta:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.deal-cta svg {
    stroke: white;
}

.deal-footer {
    padding: 1rem 1.5rem;
    background: var(--bg-secondary);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.deal-expiry {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.deal-expiry.warning {
    color: var(--secondary-color);
    font-weight: 600;
}

.deal-expiry.danger {
    color: var(--danger-color);
    font-weight: 600;
}

.deal-value {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--success-color);
}

.expiring-badge {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    background: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
    color: white;
    padding: 0.5rem 0.875rem;
    border-radius: 24px;
    font-size: 0.75rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 0.375rem;
    animation: pulse 2s ease-in-out infinite;
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
    }
    50% {
        box-shadow: 0 6px 16px rgba(245, 158, 11, 0.6), 0 3px 6px rgba(0, 0, 0, 0.15);
    }
}

.expiring-badge svg {
    stroke: white;
    animation: rotate 2s linear infinite;
}

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

.no-deals {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
}

.no-deals-icon {
    stroke: var(--text-secondary);
    margin: 0 auto 2rem;
    opacity: 0.5;
}

.no-deals h3 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.no-deals p {
    color: var(--text-secondary);
}

/* Disable hover effects on touch devices */
@media (hover: none) and (pointer: coarse) {
    .btn-oauth:hover {
        transform: none;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(0, 0, 0, 0.06);
        border-color: rgba(255, 255, 255, 0.3);
    }
    
    .btn-oauth:active {
        transform: scale(0.98);
        opacity: 0.9;
    }
    
    .btn-primary:hover {
        transform: none;
        box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
    }
    
    .btn-primary:active {
        transform: scale(0.98);
        opacity: 0.9;
    }
    
    .deal-card:hover {
        transform: none;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.06);
    }
    
    .stat:hover {
        transform: none;
    }
    
    .feature:hover {
        transform: none;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .logo {
        font-size: 2.5rem;
    }

    .logo-small {
        font-size: 1.5rem;
    }

    .tagline {
        font-size: 1.25rem;
    }

    .auth-buttons {
        max-width: 100%;
    }

    .btn-oauth {
        width: 100%;
        padding: 1.125rem 2rem; /* Slightly larger for easier tapping */
    }

    .btn-primary {
        width: 100%;
        justify-content: center;
        padding: 1.125rem 2.5rem;
    }

    .stats {
        gap: 1rem;
    }

    .stat {
        min-width: 120px;
        padding: 1rem;
    }

    .deals-container {
        grid-template-columns: 1fr;
    }

    .summary-cards {
        grid-template-columns: 1fr;
    }

    .header-content {
        padding: 1.25rem 1.5rem;
        gap: 1rem;
    }

    .header-right {
        width: 100%;
        flex-direction: column;
        gap: 1rem;
    }

    .user-info {
        width: 100%;
        justify-content: space-between;
        padding: 0.625rem 1rem;
    }

    .user-email {
        font-size: 0.875rem;
    }

    .btn-logout {
        padding: 0.75rem 1.25rem; /* Better touch target */
        font-size: 0.875rem;
        min-height: 44px; /* iOS minimum */
    }

    .powered-by {
        justify-content: center;
        width: 100%;
    }

    .results-content {
        padding: 2rem 1.5rem;
    }
    
    /* Ensure filter buttons are touch-friendly */
    .filter-btn {
        padding: 0.875rem 1.5rem;
        min-height: 44px;
    }
    
    /* Make Load More button full width on mobile */
    .btn-load-more {
        width: calc(100% - 3rem);
        margin-left: 1.5rem;
        margin-right: 1.5rem;
    }
}

/* Copied notification */
.copied-notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: linear-gradient(135deg, var(--success-color) 0%, #059669 100%);
    color: white;
    padding: 1.125rem 1.75rem;
    border-radius: 14px;
    box-shadow: 0 12px 32px rgba(16, 185, 129, 0.3), 0 6px 12px rgba(0, 0, 0, 0.15);
    animation: slideInBounce 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1000;
    font-weight: 600;
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.copied-notification::before {
    content: '✓';
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    font-weight: 700;
}

/* New deals notification */
.new-deals-notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 1.125rem 1.75rem;
    border-radius: 14px;
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.4), 0 6px 12px rgba(0, 0, 0, 0.15);
    animation: slideInBounce 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1000;
    font-weight: 600;
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.new-deals-notification svg {
    stroke: white;
    flex-shrink: 0;
}

@keyframes slideInBounce {
    from {
        transform: translateY(100px) scale(0.8);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* Error message */
.error-message {
    position: fixed;
    top: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--danger-color);
    color: white;
    padding: 1rem 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow-xl);
    animation: slideDown 0.3s ease;
    z-index: 1000;
    font-weight: 500;
}

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

/* Connection error page */
.connection-error {
    text-align: center;
    padding: 4rem 2rem;
    max-width: 500px;
    margin: 0 auto;
}

.connection-error h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2rem;
    color: white;
    margin-bottom: 1rem;
    font-weight: 800;
}

.connection-error p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.125rem;
    margin-bottom: 2rem;
}

.connection-error .btn-primary {
    margin: 0 auto;
}

/* Privacy Notice */
.privacy-notice {
    margin-top: 4rem;
    padding: 0;
    text-align: center;
}

.privacy-notice p {
    font-size: 0.75rem;
    line-height: 1.5;
    color: rgba(15, 23, 42, 0.6);
    margin: 0;
    font-weight: 400;
}

.privacy-notice a {
    color: rgba(15, 23, 42, 0.7);
    text-decoration: underline;
    text-decoration-color: rgba(15, 23, 42, 0.3);
    transition: all 0.2s ease;
}

.privacy-notice a:hover {
    color: rgba(15, 23, 42, 0.9);
    text-decoration-color: rgba(15, 23, 42, 0.5);
}

.opt-out-btn {
    display: inline;
    padding: 0;
    font-size: 0.75rem;
    background: none;
    color: rgba(15, 23, 42, 0.7);
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 400;
    text-decoration: underline;
    text-decoration-color: rgba(15, 23, 42, 0.3);
}

.opt-out-btn:hover {
    color: rgba(15, 23, 42, 0.9);
    text-decoration-color: rgba(15, 23, 42, 0.5);
}

.opt-out-btn:disabled {
    cursor: not-allowed;
    opacity: 0.4;
    text-decoration: none;
}


