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

/* Google Brand Colors */
:root {
    --google-blue: #4285F4;
    --google-red: #EA4335;
    --google-yellow: #FBBC05;
    --google-green: #34A853;
    --google-blue-dark: #3367D6;
    --google-gray: #5F6368;
    --google-gray-light: #E8EAED;

    /* Modern SaaS Dashboard Colors */
    --gradient-blue: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-green: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    --gradient-orange: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-red: linear-gradient(135deg, #eb3349 0%, #f45c43 100%);
    --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --card-shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* ========== PWA INSTALL BANNER ========== */

.pwa-install-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    z-index: 10000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.pwa-install-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.pwa-install-icon {
    flex-shrink: 0;
}

.pwa-install-text {
    font-size: 14px;
    font-weight: 500;
}

.pwa-install-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.pwa-install-banner .btn-primary {
    background: white;
    color: #667eea;
}

.pwa-install-banner .btn-primary:hover {
    background: #f0f0f0;
}

.pwa-install-banner .btn-secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: white;
}

.pwa-install-banner .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
}

@media (max-width: 480px) {
    .pwa-install-banner {
        flex-direction: column;
        text-align: center;
        padding: 16px;
    }

    .pwa-install-content {
        flex-direction: column;
        gap: 8px;
    }

    .pwa-install-text {
        font-size: 13px;
    }
}

/* ========== SKELETON LOADERS ========== */

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

.skeleton {
    background: linear-gradient(
        90deg,
        #f0f0f0 25%,
        #e0e0e0 50%,
        #f0f0f0 75%
    );
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: 4px;
}

.skeleton-text {
    height: 14px;
    margin-bottom: 8px;
    border-radius: 4px;
}

.skeleton-text-sm {
    height: 10px;
    width: 60%;
}

.skeleton-text-lg {
    height: 24px;
    width: 40%;
}

.skeleton-circle {
    border-radius: 50%;
}

.skeleton-card {
    background: white;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
}

/* Skeleton Stats Card */
.skeleton-stat-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.skeleton-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.skeleton-stat-info {
    flex: 1;
}

.skeleton-stat-value {
    height: 28px;
    width: 60px;
    margin-bottom: 6px;
    border-radius: 4px;
}

.skeleton-stat-label {
    height: 12px;
    width: 80px;
    border-radius: 4px;
}

/* Skeleton Chart Card */
.skeleton-chart-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
}

.skeleton-chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.skeleton-chart-title {
    height: 16px;
    width: 100px;
    border-radius: 4px;
}

.skeleton-chart-badge {
    height: 20px;
    width: 80px;
    border-radius: 4px;
}

.skeleton-chart-body {
    height: 200px;
    border-radius: 8px;
}

.skeleton-chart-body-sm {
    height: 180px;
}

/* Skeleton Invoice Card */
.skeleton-invoice-card {
    background: white;
    border-radius: 12px;
    padding: 1.25rem;
    box-shadow: var(--card-shadow);
}

.skeleton-invoice-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.skeleton-invoice-id {
    height: 14px;
    width: 70px;
    border-radius: 4px;
}

.skeleton-invoice-date {
    height: 12px;
    width: 80px;
    border-radius: 4px;
}

.skeleton-invoice-customer {
    height: 18px;
    width: 140px;
    margin-bottom: 0.5rem;
    border-radius: 4px;
}

.skeleton-invoice-amount {
    height: 24px;
    width: 90px;
    margin-bottom: 1rem;
    border-radius: 4px;
}

.skeleton-invoice-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #f1f3f4;
}

.skeleton-invoice-status {
    height: 24px;
    width: 60px;
    border-radius: 12px;
}

.skeleton-invoice-actions {
    display: flex;
    gap: 0.5rem;
}

.skeleton-invoice-action {
    width: 32px;
    height: 32px;
    border-radius: 6px;
}

/* Skeleton Table Row */
.skeleton-table-row td {
    padding: 1rem;
}

.skeleton-table-cell {
    height: 16px;
    border-radius: 4px;
}

.skeleton-table-cell-sm {
    width: 60%;
}

.skeleton-table-cell-lg {
    width: 80%;
}

.skeleton-table-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.skeleton-table-action {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

/* Skeleton Table Text Variations */
.skeleton-text-name {
    width: 120px;
}

.skeleton-text-email {
    width: 180px;
}

.skeleton-text-phone {
    width: 100px;
}

.skeleton-text-address {
    width: 200px;
}

.skeleton-text-rate {
    width: 50px;
}

.skeleton-text-bool {
    width: 40px;
}

.skeleton-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.skeleton-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
}

.skeleton-table {
    width: 100%;
    border-collapse: collapse;
}

.skeleton-table th {
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 2px solid var(--google-gray-light);
    color: var(--google-gray);
    font-weight: 500;
}

.skeleton-table td {
    padding: 1rem;
    border-bottom: 1px solid #f1f3f4;
}

/* Hide skeleton when content loaded */
.skeleton-container.loaded {
    display: none;
}

body {
    font-family: 'Google Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #202124;
    background-color: #f8f9fa;
}

/* Screen Management */
.screen {
    display: flex;
    width: 100vw;
    height: 100vh;
}

.screen.hidden {
    display: none;
}

/* Auth Screen */
.auth-container {
    max-width: 420px;
    margin: auto;
    padding: 50px 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    text-align: center;
}

.auth-logo {
    margin-bottom: 24px;
}

.auth-container h1 {
    color: #202124;
    margin-bottom: 12px;
    font-size: 24px;
    font-weight: 600;
}

.auth-container > p {
    color: var(--google-gray);
    margin-bottom: 32px;
    font-size: 15px;
}

.auth-form {
    margin-bottom: 40px;
}

.btn-google {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 14px 24px;
    background: white;
    color: #3c4043;
    border: 1px solid #dadce0;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.btn-google:hover {
    background: #f8f9fa;
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}

.btn-google:active {
    background: #f1f3f4;
}

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

.auth-features {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: left;
    padding-top: 24px;
    border-top: 1px solid #eee;
}

.feature {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--google-gray);
    font-size: 14px;
}

.feature-icon {
    font-size: 20px;
}

/* Legal Links */
.legal-links {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid #eee;
    font-size: 12px;
    color: var(--google-gray);
}

.legal-links a {
    color: var(--google-gray);
    text-decoration: none;
}

.legal-links a:hover {
    color: var(--google-blue);
    text-decoration: underline;
}

.legal-links .divider {
    margin: 0 8px;
}

/* ========== LANDING PAGE ========== */

.landing-page {
    display: block;
    width: 100%;
    height: 100vh;
    background: #fff;
    overflow-y: auto;
    overflow-x: hidden;
}

.landing-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Landing Navigation */
.landing-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #eee;
    z-index: 100;
    padding: 16px 0;
}

.landing-nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.landing-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    color: #202124;
}

/* Hero Section */
.landing-hero {
    padding: 120px 0 80px;
    background: linear-gradient(180deg, #f8f9ff 0%, #fff 100%);
}

.landing-hero .landing-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-content h1 {
    font-size: 48px;
    font-weight: 700;
    line-height: 1.2;
    color: #202124;
    margin-bottom: 24px;
}

.hero-highlight {
    background: linear-gradient(135deg, #4285F4 0%, #34A853 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 18px;
    color: #5f6368;
    line-height: 1.6;
    margin-bottom: 32px;
}

.hero-cta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
}

.hero-cta .btn-large {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    font-size: 16px;
    width: auto;
}

.hero-note {
    font-size: 14px;
    color: #5f6368;
}

/* Hero Mockup */
.hero-visual {
    display: flex;
    justify-content: center;
}

.hero-mockup {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.mockup-header {
    background: #f1f3f4;
    padding: 12px 16px;
}

.mockup-dots {
    display: flex;
    gap: 6px;
}

.mockup-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ddd;
}

.mockup-dots span:first-child { background: #EA4335; }
.mockup-dots span:nth-child(2) { background: #FBBC05; }
.mockup-dots span:last-child { background: #34A853; }

.mockup-content {
    padding: 24px;
}

.mockup-invoice {
    background: #fafafa;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 20px;
}

.mockup-invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.mockup-logo-placeholder {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #4285F4, #34A853);
    border-radius: 8px;
}

.mockup-invoice-title {
    font-size: 18px;
    font-weight: 700;
    color: #202124;
}

.mockup-line {
    height: 10px;
    background: #e0e0e0;
    border-radius: 4px;
    margin-bottom: 8px;
}

.mockup-line.w-60 { width: 60%; }
.mockup-line.w-40 { width: 40%; }
.mockup-line.w-80 { width: 80%; }

.mockup-table {
    margin: 16px 0;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
}

.mockup-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    padding: 10px 12px;
    border-bottom: 1px solid #e0e0e0;
}

.mockup-row:last-child {
    border-bottom: none;
}

.mockup-row.header {
    background: #f5f5f5;
    font-size: 11px;
    font-weight: 600;
    color: #5f6368;
}

.mockup-row:not(.header) span {
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    margin: 4px 8px 4px 0;
}

.mockup-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 2px solid #202124;
    margin-top: 8px;
    font-weight: 600;
}

.mockup-amount {
    font-size: 18px;
    color: #34A853;
}

/* Features Section */
.landing-features {
    padding: 80px 0;
    background: #fff;
}

.section-title {
    font-size: 36px;
    font-weight: 700;
    text-align: center;
    color: #202124;
    margin-bottom: 12px;
}

.section-subtitle {
    font-size: 18px;
    color: #5f6368;
    text-align: center;
    margin-bottom: 48px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.feature-card {
    background: #fff;
    border: 1px solid #e8eaed;
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s ease;
}

.feature-card:hover {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
}

.feature-icon-wrapper {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 18px;
    font-weight: 600;
    color: #202124;
    margin-bottom: 12px;
}

.feature-card p {
    font-size: 15px;
    color: #5f6368;
    line-height: 1.6;
}

/* How It Works Section */
.landing-how-it-works {
    padding: 80px 0;
    background: #f8f9ff;
}

.steps-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
}

.step-card {
    background: #fff;
    border-radius: 16px;
    padding: 32px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    flex: 1;
    max-width: 280px;
}

.step-number {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #4285F4 0%, #34A853 100%);
    color: white;
    font-size: 24px;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.step-card h3 {
    font-size: 18px;
    font-weight: 600;
    color: #202124;
    margin-bottom: 12px;
}

.step-card p {
    font-size: 14px;
    color: #5f6368;
    line-height: 1.6;
}

.step-arrow {
    color: #dadce0;
    flex-shrink: 0;
}

/* Pricing Section */
.landing-pricing {
    padding: 80px 0;
    background: #fff;
}

.landing-plan-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    max-width: 800px;
    margin: 0 auto;
}

.landing-plan-options .plan-card {
    margin: 0;
}

@media (max-width: 768px) {
    .landing-plan-options {
        grid-template-columns: 1fr;
        max-width: 400px;
    }
}

.pricing-cards {
    display: flex;
    justify-content: center;
    gap: 32px;
    max-width: 700px;
    margin: 0 auto;
}

.pricing-card {
    background: #fff;
    border: 2px solid #e8eaed;
    border-radius: 20px;
    padding: 40px;
    flex: 1;
    max-width: 320px;
    text-align: center;
}

.pricing-card-featured {
    border-color: #4285F4;
    box-shadow: 0 10px 40px rgba(66, 133, 244, 0.2);
    position: relative;
}

.pricing-badge {
    display: inline-block;
    padding: 6px 16px;
    background: #e8eaed;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: #5f6368;
    margin-bottom: 20px;
}

.pricing-card-featured .pricing-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.pricing-price {
    font-size: 48px;
    font-weight: 700;
    color: #202124;
}

.pricing-period {
    font-size: 14px;
    color: #5f6368;
    margin-bottom: 24px;
}

.pricing-features {
    list-style: none;
    text-align: left;
}

.pricing-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    font-size: 14px;
    color: #5f6368;
}

.pricing-features svg {
    flex-shrink: 0;
}

/* FAQ Section */
.landing-faq {
    padding: 80px 0;
    background: #f8f9fa;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.faq-item h3 {
    font-size: 16px;
    font-weight: 600;
    color: #202124;
    margin-bottom: 12px;
}

.faq-item p {
    font-size: 14px;
    color: #5f6368;
    line-height: 1.6;
    margin: 0;
}

@media (max-width: 768px) {
    .faq-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .landing-faq {
        padding: 48px 0;
    }

    .faq-item {
        padding: 20px;
    }
}

/* CTA Section */
.landing-cta {
    padding: 80px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    text-align: center;
}

.landing-cta h2 {
    font-size: 36px;
    font-weight: 700;
    color: white;
    margin-bottom: 16px;
}

.landing-cta p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 32px;
}

.landing-cta .btn-large {
    background: white;
    color: #667eea;
    padding: 16px 32px;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: auto;
}

.landing-cta .btn-large:hover {
    background: #f0f0f0;
}

/* Landing Footer */
.landing-footer {
    padding: 32px 0;
    background: #f8f9fa;
    border-top: 1px solid #e8eaed;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 600;
    color: #5f6368;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: #5f6368;
    text-decoration: none;
    font-size: 14px;
}

.footer-links a:hover {
    color: #4285F4;
}

.footer-disclaimer {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid #e8eaed;
    font-size: 12px;
    color: #9aa0a6;
    text-align: center;
}

/* Sign In Screen */
#sign-in-screen {
    width: 100%;
    justify-content: center;
}

.sign-in-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    background: linear-gradient(135deg, #f8f9fa 0%, #e8eaed 100%);
    padding: 20px;
}

.sign-in-card {
    background: #fff;
    border-radius: 16px;
    padding: 48px;
    text-align: center;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 100%;
}

.sign-in-logo {
    margin-bottom: 24px;
}

.sign-in-title {
    font-size: 28px;
    font-weight: 600;
    color: #202124;
    margin-bottom: 12px;
}

.sign-in-text {
    color: #5f6368;
    margin-bottom: 32px;
    font-size: 15px;
    line-height: 1.5;
}

.sign-in-note {
    margin-top: 20px;
    font-size: 13px;
    color: #9aa0a6;
}

.auth-disabled-notice {
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: #fef3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 20px;
    color: #856404;
    font-size: 14px;
    text-align: left;
}

.auth-disabled-notice svg {
    flex-shrink: 0;
    stroke: #856404;
}

#back-to-landing-btn {
    margin-top: 24px;
    color: #5f6368;
}

#back-to-landing-btn:hover {
    color: #4285F4;
}

.btn-text {
    background: none;
    border: none;
    padding: 8px 16px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Landing Page Responsive */
@media (max-width: 992px) {
    .landing-hero .landing-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 36px;
    }

    .hero-cta {
        align-items: center;
    }

    .hero-visual {
        order: -1;
    }

    .hero-mockup {
        max-width: 320px;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .steps-grid {
        flex-direction: column;
    }

    .step-arrow {
        transform: rotate(90deg);
    }

    .step-card {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .landing-nav-container {
        padding: 0 16px;
    }

    .landing-logo span {
        display: none;
    }

    .hero-content h1 {
        font-size: 28px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .section-title {
        font-size: 28px;
    }

    /* Tighter section padding on mobile */
    .landing-features,
    .landing-how-it-works,
    .landing-pricing {
        padding: 48px 0;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    /* Tighter feature card spacing */
    .feature-card {
        padding: 24px;
    }

    .feature-card h3 {
        margin-bottom: 8px;
    }

    .feature-icon-wrapper {
        width: 48px;
        height: 48px;
        margin-bottom: 16px;
    }

    /* Tighter step card spacing */
    .steps-grid {
        gap: 16px;
    }

    .step-card {
        padding: 24px;
    }

    .step-number {
        width: 40px;
        height: 40px;
        font-size: 18px;
        margin-bottom: 12px;
    }

    .step-card h3 {
        margin-bottom: 8px;
    }

    .step-arrow {
        display: none;
    }

    .pricing-cards {
        flex-direction: column;
        align-items: center;
    }

    .pricing-card {
        max-width: 100%;
    }

    .footer-content {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}

.legal-info {
    color: var(--google-gray);
    line-height: 1.6;
}

.legal-info p {
    margin-bottom: 15px;
}

/* Subscription Screen */
.subscription-container {
    max-width: 800px;
    margin: auto;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    text-align: center;
}

.subscription-header {
    position: relative;
}

.subscription-header h1 {
    color: #202124;
    margin-bottom: 8px;
    font-size: 28px;
}

.subscription-header p {
    color: var(--google-gray);
    margin-bottom: 30px;
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: 1px solid #dadce0;
    color: #5f6368;
    padding: 8px 16px;
    font-size: 14px;
    margin-bottom: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-back:hover {
    background: #f1f3f4;
    color: #202124;
}

.btn-disabled {
    background: #e0e0e0 !important;
    color: #9e9e9e !important;
    cursor: not-allowed !important;
    border-color: #e0e0e0 !important;
}

.btn-disabled:hover {
    background: #e0e0e0 !important;
    transform: none !important;
    box-shadow: none !important;
}

/* Plan Options Grid */
.plan-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.plan-card {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
}

.plan-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.plan-card-featured {
    background: linear-gradient(135deg, var(--google-blue) 0%, var(--google-blue-dark) 100%);
    color: white;
    border: 2px solid var(--google-blue);
}

.plan-recommended {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--google-yellow);
    color: #202124;
    padding: 4px 16px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.plan-badge {
    display: inline-block;
    padding: 4px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.plan-badge-free {
    background: #e0e0e0;
    color: #5f6368;
}

.plan-badge-pro {
    background: rgba(255,255,255,0.2);
    color: white;
}

/* Promotional Banner */
.promo-banner-container {
    width: 100%;
    max-width: 800px;
    margin: 0 auto 24px;
    padding: 0 20px;
}

.promo-banner {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 24px 24px 20px;
    margin-top: 16px;
    position: relative;
    overflow: visible;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
}

.promo-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.promo-banner-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a5a 100%);
    color: white;
    padding: 6px 20px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(238, 90, 90, 0.4);
    white-space: nowrap;
    z-index: 10;
}

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

.promo-banner-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    position: relative;
    z-index: 1;
}

.promo-banner-text {
    color: white;
}

.promo-banner-text h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.promo-banner-text p {
    font-size: 0.95rem;
    margin: 0;
    opacity: 0.95;
}

.promo-banner-text strong {
    font-weight: 700;
}

.promo-banner-btn {
    background: white !important;
    color: #667eea !important;
    border: none !important;
    padding: 12px 24px !important;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    transition: transform 0.2s, box-shadow 0.2s;
}

.promo-banner-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    background: white !important;
    color: #5a67d8 !important;
}

.promo-banner-btn svg {
    transition: transform 0.2s;
}

.promo-banner-btn:hover svg {
    transform: translateX(4px);
}

@media (max-width: 600px) {
    .promo-banner-content {
        flex-direction: column;
        text-align: center;
    }

    .promo-banner-text h3 {
        font-size: 1.25rem;
    }

    .promo-banner-btn {
        width: 100%;
        justify-content: center;
    }
}

.plan-card-pro {
    position: relative;
}

.plan-price {
    margin-bottom: 20px;
}

.plan-price .price {
    font-size: 42px;
    font-weight: 700;
}

.plan-price .currency {
    font-size: 14px;
    font-weight: 500;
    opacity: 0.7;
    margin-left: 4px;
}

.plan-price .period {
    font-size: 14px;
    opacity: 0.8;
}

.plan-features {
    list-style: none;
    text-align: left;
    padding: 0;
    margin: 0 0 24px 0;
}

.plan-features li {
    padding: 8px 0;
    padding-left: 28px;
    position: relative;
    font-size: 13px;
}

.plan-features li::before {
    content: "✓";
    position: absolute;
    left: 0;
    font-weight: bold;
}

.plan-card:not(.plan-card-featured) .plan-features li::before {
    color: var(--google-green);
}

.plan-card-featured .plan-features li::before {
    color: var(--google-yellow);
}

.plan-features .feature-limited {
    color: #9e9e9e;
}

.plan-features .feature-limited::before {
    content: "•";
    color: #9e9e9e;
}

.plan-features .feature-pro {
    color: #fff;
}

.plan-features .feature-pro::before {
    content: "★";
    color: var(--google-yellow);
}

.plan-card .btn-large {
    width: 100%;
}

.plan-card-featured .promo-code-section {
    text-align: left;
    margin-bottom: 16px;
}

.plan-card-featured .promo-code-section label {
    color: rgba(255,255,255,0.8);
}

.plan-card-featured .secure-payment-notice {
    color: rgba(255,255,255,0.7);
    margin-top: 12px;
}

@media (max-width: 768px) {
    .plan-options {
        grid-template-columns: 1fr;
    }

    .subscription-container {
        padding: 20px;
        margin: 10px;
    }
}

.subscription-notice {
    background: #FEF7E0;
    border-left: 4px solid var(--google-yellow);
    padding: 12px 16px;
    margin-bottom: 24px;
    border-radius: 4px;
    text-align: left;
}

.subscription-notice p {
    margin: 0;
    font-size: 13px;
    color: var(--google-gray);
}

.subscription-notice a {
    color: #E37400;
}

/* Stripe Checkout Container */
#stripe-checkout-container {
    margin-bottom: 24px;
}

.promo-code-section {
    margin-bottom: 20px;
    text-align: left;
}

.promo-code-section label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--google-gray);
}

.promo-code-input-group {
    display: flex;
    gap: 10px;
}

.promo-code-input-group input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.promo-code-input-group input:focus {
    outline: none;
    border-color: var(--google-blue);
}

.promo-status {
    margin-top: 8px;
    font-size: 13px;
    color: var(--google-gray);
}

.promo-status.success {
    color: var(--google-green);
}

.promo-status.error {
    color: var(--google-red);
}

.btn-large {
    width: 100%;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 600;
}

.secure-payment-notice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 13px;
    color: var(--google-gray);
}

.secure-payment-notice svg {
    color: var(--google-green);
}

.subscription-footer {
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.subscription-footer .btn {
    margin-bottom: 16px;
}

/* Mobile Header */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 56px;
    background: var(--google-blue);
    color: white;
    align-items: center;
    padding: 0 16px;
    gap: 12px;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.hamburger-btn {
    background: none;
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s;
}

.hamburger-btn:hover {
    background: rgba(255,255,255,0.1);
}

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

.mobile-header-title {
    font-size: 18px;
    font-weight: 600;
}

/* Sidebar Overlay */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1001;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

/* Sidebar */
.sidebar {
    width: 250px;
    background-color: var(--google-blue);
    color: white;
    display: flex;
    flex-direction: column;
    padding: 0;
    transition: width 0.3s ease, transform 0.3s ease;
    overflow: hidden;
}

.sidebar.collapsed {
    width: 70px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 15px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    overflow: hidden;
}

.logo-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.logo-text {
    font-size: 16px;
    font-weight: 600;
    white-space: nowrap;
    transition: opacity 0.2s, width 0.3s;
}

.sidebar.collapsed .logo-text {
    opacity: 0;
    width: 0;
}

.sidebar.collapsed .sidebar-header {
    justify-content: center;
    padding: 20px 0;
}

.sidebar.collapsed .logo {
    display: none;
}

.sidebar-toggle {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.3s;
    flex-shrink: 0;
}

.sidebar-toggle:hover {
    background: rgba(255,255,255,0.2);
}

.sidebar-toggle svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s;
}

.sidebar.collapsed .sidebar-toggle svg {
    transform: rotate(180deg);
}

.nav-menu {
    list-style: none;
    padding: 15px 0;
    flex: 1;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    transition: background 0.2s, color 0.2s, padding 0.3s;
}

.sidebar.collapsed .nav-link {
    padding: 12px 0;
    justify-content: center;
}

.nav-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

.nav-text {
    white-space: nowrap;
    transition: opacity 0.2s, width 0.3s;
}

.sidebar.collapsed .nav-text {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.nav-link:hover {
    background-color: rgba(255,255,255,0.15);
    color: white;
}

.nav-link.active {
    background-color: var(--google-blue-dark);
    color: white;
    border-left: 3px solid white;
}

.sidebar.collapsed .nav-link.active {
    border-left: none;
    border-radius: 0;
}

/* Nav Pro Tag */
.nav-pro-tag {
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    color: #000;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: auto;
}

.sidebar.collapsed .nav-pro-tag {
    display: none;
}

/* Plan Status Badge */
.plan-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    background: rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.plan-status-badge {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 12px;
}

.plan-status-free {
    background: rgba(255,193,7,0.2);
    color: #ffc107;
}

.plan-status-pro {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.plan-upgrade-link {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-weight: 500;
}

.plan-upgrade-link:hover {
    color: #fff;
    text-decoration: underline;
}

.sidebar.collapsed .plan-status {
    justify-content: center;
    padding: 8px;
}

.sidebar.collapsed .plan-status-badge {
    padding: 4px 6px;
    font-size: 9px;
}

.sidebar.collapsed .plan-upgrade-link {
    display: none;
}

/* Sidebar Ad Banner */
.sidebar-ad {
    margin-top: auto;
    padding: 15px;
    background: rgba(255,255,255,0.1);
    border-top: 1px solid rgba(255,255,255,0.2);
}

.ad-label {
    font-size: 9px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.5);
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.ad-content {
    display: block;
    background: white;
    border-radius: 8px;
    padding: 12px;
    text-decoration: none;
    color: #202124;
    transition: transform 0.2s, box-shadow 0.2s;
}

.ad-content:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.ad-image {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    background: #f1f3f4;
    margin-bottom: 8px;
}

.ad-text {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #202124;
    text-align: center;
}

.upgrade-link {
    display: block;
    margin-top: 10px;
    font-size: 10px;
    color: rgba(255,255,255,0.7);
    text-align: center;
    text-decoration: none;
    transition: color 0.2s;
}

.upgrade-link:hover {
    color: white;
    text-decoration: underline;
}

.sidebar.collapsed .sidebar-ad {
    display: none !important;
}

/* Main Content */
.main-content {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
}

/* Views */
.view {
    display: none;
}

.view.active {
    display: block;
}

.view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.view-header h1 {
    color: #202124;
    font-size: 28px;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

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

.btn-primary {
    background-color: var(--google-blue);
    color: white;
}

.btn-primary:hover {
    background-color: var(--google-blue-dark);
}

#new-tax-btn {
    margin-bottom: 1rem;
}

.btn-success {
    background-color: var(--google-green);
    color: white;
}

.btn-success:hover {
    background-color: #2E9149;
}

.btn-secondary {
    background-color: var(--google-gray-light);
    color: var(--google-gray);
}

.btn-secondary:hover {
    background-color: #D2D5DB;
}

.btn-danger {
    background-color: var(--google-red);
    color: white;
}

.btn-danger:hover {
    background-color: #D33426;
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
}

.btn-whatsapp:hover {
    background-color: #1DA851;
}

.btn-whatsapp.disabled {
    background-color: #9ED8B3;
    cursor: not-allowed;
    position: relative;
}

.btn-whatsapp.disabled:hover {
    background-color: #9ED8B3;
}

.btn-whatsapp.disabled {
    position: relative;
}

.pro-pill-small {
    position: absolute;
    top: -6px;
    right: -6px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 8px;
    font-weight: 600;
    padding: 1px 4px;
    border-radius: 6px;
    text-transform: uppercase;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-icon {
    padding: 8px 12px;
    font-size: 12px;
}

/* Search Bar */
.search-bar {
    margin-bottom: 20px;
}

.search-bar input {
    width: 100%;
    max-width: 400px;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--google-blue);
}

/* Tables */
.table-container {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background-color: var(--google-blue);
    color: white;
}

thead th {
    padding: 15px;
    text-align: left;
    font-weight: 500;
    font-size: 13px;
    text-transform: uppercase;
}

tbody td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--google-gray-light);
}

tbody tr:hover {
    background-color: #F1F3F4;
}

tbody tr:last-child td {
    border-bottom: none;
}

/* Forms */
.invoice-form {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #202124;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--google-blue);
}

.form-group input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
}

/* Searchable Dropdown */
.searchable-dropdown {
    position: relative;
    width: 100%;
}

.searchable-dropdown input[type="text"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.searchable-dropdown input[type="text"]:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.2);
}

.searchable-dropdown .dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 200px;
    overflow-y: auto;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    list-style: none;
    z-index: 1000;
    display: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.searchable-dropdown.open .dropdown-list {
    display: block;
}

.searchable-dropdown .dropdown-list li {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
}

.searchable-dropdown .dropdown-list li:last-child {
    border-bottom: none;
}

.searchable-dropdown .dropdown-list li:hover,
.searchable-dropdown .dropdown-list li.highlighted {
    background-color: var(--google-gray-light);
}

.searchable-dropdown .dropdown-list li.no-results {
    color: var(--google-gray);
    font-style: italic;
    cursor: default;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px 12px;
}

.searchable-dropdown .dropdown-list li.no-results:hover {
    background-color: white;
}

.searchable-dropdown .dropdown-list li.no-results .add-customer-link {
    color: var(--google-blue);
    font-style: normal;
    font-weight: 500;
    text-decoration: none;
    font-size: 13px;
    cursor: pointer;
}

.searchable-dropdown .dropdown-list li.no-results .add-customer-link:hover {
    text-decoration: underline;
}

.searchable-dropdown .dropdown-list li .customer-name {
    display: block;
    font-weight: 500;
}

.searchable-dropdown .dropdown-list li .customer-subtitle {
    display: block;
    font-size: 12px;
    color: var(--google-gray);
    margin-top: 2px;
}

/* Items Table */
.items-container {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
    background: #f8f9fa;
}

.items-table {
    margin-bottom: 15px;
    background: white;
}

.items-table thead {
    background-color: var(--google-gray-light);
    color: #202124;
}

.items-table input {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 100%;
}

/* Tax Checkboxes */
#tax-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
}

#tax-checkboxes label {
    display: flex;
    align-items: center;
    font-weight: normal;
}

/* Totals Display */
.totals-display {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.total-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    font-size: 16px;
}

.total-row.grand {
    border-top: 2px solid var(--google-blue);
    margin-top: 10px;
    padding-top: 15px;
    font-size: 20px;
    font-weight: bold;
    color: #202124;
}

#tax-breakdown .total-row {
    font-size: 14px;
    color: var(--google-gray);
    padding: 5px 0;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e0e0e0;
}

.modal-header h2 {
    margin: 0;
    color: #202124;
    font-size: 20px;
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #5f6368;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s, color 0.2s;
}

.modal-close:hover {
    background: #f1f3f4;
    color: #202124;
}

.modal-content h2 {
    margin-bottom: 20px;
    color: #202124;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

/* Small Modal Variant */
.modal-content.modal-small {
    max-width: 400px;
    padding: 24px;
}

.modal-body {
    margin-top: 20px;
}

/* ========== LOGO UPLOAD STYLES ========== */

.logo-upload-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #e0e0e0;
}

.logo-upload-section > label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
}

.logo-subtitle {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #5f6368;
    margin-bottom: 12px;
}

.pro-pill {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    color: #000;
    padding: 2px 8px;
    border-radius: 10px;
}

/* Lock/Upload icon visibility */
.logo-actions .btn .lock-icon {
    display: none;
}

.logo-actions .btn .upload-icon {
    display: inline;
}

.logo-upload-section.disabled .logo-actions .btn .lock-icon {
    display: inline;
}

.logo-upload-section.disabled .logo-actions .btn .upload-icon {
    display: none;
}

.logo-upload-section .upgrade-link {
    display: inline-block;
    margin-top: 8px;
    font-size: 13px;
    color: var(--google-blue);
    text-decoration: none;
}

.logo-upload-section .upgrade-link:hover {
    color: var(--google-blue);
    text-decoration: underline;
}

.logo-preview-container {
    display: flex;
    align-items: center;
    gap: 16px;
}

.logo-preview {
    width: 80px;
    height: 80px;
    border: 2px dashed #d0d0d0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    overflow: hidden;
    flex-shrink: 0;
}

.logo-preview img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.logo-preview.has-logo {
    border-style: solid;
    border-color: var(--google-blue);
}

.logo-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.logo-actions .btn svg {
    margin-right: 6px;
}

.logo-upload-section.disabled {
    opacity: 0.6;
}

.logo-upload-section.disabled .logo-actions .btn {
    cursor: not-allowed;
}

/* Logo Crop Modal */
.modal-crop {
    max-width: 450px;
}

.crop-shape-options {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.crop-shape-options label {
    font-weight: 500;
    color: #5f6368;
}

.shape-buttons {
    display: flex;
    gap: 8px;
}

.shape-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: #5f6368;
    transition: all 0.2s;
}

.shape-btn:hover {
    border-color: #c0c0c0;
}

.shape-btn.active {
    border-color: var(--google-blue);
    background: #e8f0fe;
    color: var(--google-blue);
}

.shape-btn svg {
    stroke: currentColor;
}

.crop-instructions {
    text-align: center;
    color: #5f6368;
    font-size: 13px;
    margin-bottom: 12px;
}

.crop-container {
    display: flex;
    justify-content: center;
    align-items: center;
    background: #1a1a2e;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 16px;
}

.crop-area {
    position: relative;
    width: 200px;
    height: 200px;
    overflow: hidden;
    border: 2px solid white;
    border-radius: 4px;
    cursor: move;
    background: #2a2a4e;
}

.crop-area[data-ratio="2:1"] {
    width: 240px;
    height: 120px;
}

.crop-area img {
    position: absolute;
    max-width: none;
    user-select: none;
    -webkit-user-drag: none;
}

.crop-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.crop-controls label {
    font-weight: 500;
    color: #5f6368;
    font-size: 14px;
}

.crop-controls input[type="range"] {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #e0e0e0;
    outline: none;
    -webkit-appearance: none;
}

.crop-controls input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--google-blue);
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.crop-controls input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--google-blue);
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Logo Upload Modal Options */
.logo-upload-options {
    display: flex;
    gap: 16px;
}

.upload-option {
    flex: 1;
    padding: 24px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    background: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.upload-option:hover {
    border-color: var(--google-blue);
    background: #f0f7ff;
}

.upload-option svg {
    color: var(--google-gray);
    transition: color 0.2s;
}

.upload-option:hover svg {
    color: var(--google-blue);
}

.upload-option span {
    font-size: 14px;
    font-weight: 500;
    color: #202124;
}

.upload-option-full {
    flex: none;
    width: 100%;
}

/* Invoice Preview Logo */
.preview-logo {
    flex-shrink: 0;
}

.preview-logo:empty {
    display: none;
}

.preview-logo img {
    max-width: 60px;
    max-height: 60px;
    object-fit: contain;
    border-radius: 4px;
}

/* Update preview-business-header to accommodate logo */
.preview-business-header {
    display: flex;
    gap: 12px;
}

.preview-business-info {
    flex: 1;
}

/* Form Row for side-by-side fields */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 480px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Table Action Buttons */
.inventory-actions,
.customer-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.inventory-actions .btn-icon,
.customer-actions .btn-icon,
.data-table .btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    background: #fff;
    color: #5f6368;
    cursor: pointer;
    transition: all 0.2s ease;
}

.inventory-actions .btn-icon:hover,
.customer-actions .btn-icon:hover,
.data-table .btn-icon:hover {
    background: #f1f3f4;
    border-color: #dadce0;
    color: #202124;
}

.inventory-actions .btn-icon-danger,
.customer-actions .btn-icon-danger,
.data-table .btn-icon-danger {
    color: #d93025;
    border-color: #f5c6cb;
}

.inventory-actions .btn-icon-danger:hover,
.customer-actions .btn-icon-danger:hover,
.data-table .btn-icon-danger:hover {
    background: #fce8e6;
    border-color: #d93025;
    color: #a50e0e;
}

.inventory-actions .btn-icon svg,
.customer-actions .btn-icon svg,
.data-table .btn-icon svg {
    width: 16px;
    height: 16px;
}

/* View Header Actions */
.view-header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* CSV Import Section */
.csv-import-section {
    margin-bottom: 24px;
}

.csv-import-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: var(--card-shadow);
    border: 1px solid #e0e0e0;
}

.csv-import-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.csv-import-header h3 {
    margin: 0;
    color: #202124;
    font-size: 18px;
}

.btn-close-import {
    background: none;
    border: none;
    color: #5f6368;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.btn-close-import:hover {
    background: #f1f3f4;
    color: #202124;
}

.csv-import-description {
    color: #5f6368;
    margin-bottom: 16px;
    font-size: 14px;
}

.csv-import-actions {
    margin-bottom: 16px;
}

.btn-link {
    background: none;
    border: none;
    color: #1a73e8;
    cursor: pointer;
    padding: 8px 0;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    transition: color 0.2s;
}

.btn-link:hover {
    color: #1557b0;
    text-decoration: underline;
}

.csv-drop-zone {
    border: 2px dashed #dadce0;
    border-radius: 12px;
    padding: 40px 24px;
    text-align: center;
    background: #fafafa;
    transition: all 0.2s ease;
    cursor: pointer;
}

.csv-drop-zone:hover,
.csv-drop-zone.drag-over {
    border-color: #1a73e8;
    background: #e8f0fe;
}

.csv-drop-zone svg {
    color: #9aa0a6;
    margin-bottom: 12px;
}

.csv-drop-zone p {
    color: #5f6368;
    margin: 0 0 8px 0;
    font-size: 16px;
}

.csv-drop-zone span {
    color: #9aa0a6;
    font-size: 14px;
    display: block;
    margin-bottom: 12px;
}

.csv-preview {
    margin-top: 20px;
    border-top: 1px solid #e0e0e0;
    padding-top: 20px;
}

.csv-preview h4 {
    margin: 0 0 12px 0;
    color: #202124;
    font-size: 16px;
}

.csv-preview-table-wrapper {
    max-height: 300px;
    overflow: auto;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 16px;
}

.csv-preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.csv-preview-table th,
.csv-preview-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.csv-preview-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #5f6368;
    position: sticky;
    top: 0;
}

.csv-preview-table tr:last-child td {
    border-bottom: none;
}

.csv-preview-table tr:hover td {
    background: #f8f9fa;
}

.csv-import-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* Inventory Toolbar */
.inventory-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.inventory-toolbar .inventory-search {
    flex: 1;
    min-width: 200px;
}

.inventory-page-size {
    display: flex;
    align-items: center;
    gap: 8px;
}

.inventory-page-size label {
    color: #5f6368;
    font-size: 14px;
}

.inventory-page-size select {
    padding: 8px 12px;
    border: 1px solid #dadce0;
    border-radius: 6px;
    font-size: 14px;
    background: white;
    cursor: pointer;
}

/* Bulk Actions Bar */
.bulk-actions-bar {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    background: #e8f0fe;
    border-radius: 8px;
    margin-bottom: 16px;
}

.bulk-selected-count {
    font-weight: 500;
    color: #1a73e8;
}

/* Table Checkbox Column */
.th-checkbox {
    width: 40px;
    text-align: center;
}

.td-checkbox {
    text-align: center;
}

.td-checkbox input[type="checkbox"],
.th-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #1a73e8;
}

/* Pagination */
.pagination-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-top: 1px solid #e0e0e0;
    margin-top: 16px;
    flex-wrap: wrap;
    gap: 16px;
}

.pagination-info {
    color: #5f6368;
    font-size: 14px;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-pagination {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    background: white;
    border: 1px solid #dadce0;
    border-radius: 6px;
    color: #5f6368;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-pagination:hover:not(:disabled) {
    background: #f1f3f4;
    border-color: #c6c9cc;
    color: #202124;
}

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

.pagination-pages {
    display: flex;
    gap: 4px;
}

.pagination-page {
    min-width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #dadce0;
    border-radius: 6px;
    background: white;
    color: #5f6368;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.pagination-page:hover {
    background: #f1f3f4;
    border-color: #c6c9cc;
}

.pagination-page.active {
    background: #1a73e8;
    border-color: #1a73e8;
    color: white;
}

.pagination-ellipsis {
    min-width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #5f6368;
    font-size: 14px;
}

/* Row selection highlight */
.data-table tr.selected td {
    background: #e8f0fe;
}

@media (max-width: 768px) {
    .inventory-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .inventory-toolbar .inventory-search {
        width: 100%;
    }

    .inventory-page-size {
        justify-content: flex-end;
    }

    .pagination-container {
        flex-direction: column;
        text-align: center;
    }

    .pagination-controls {
        width: 100%;
        justify-content: center;
    }

    .bulk-actions-bar {
        flex-wrap: wrap;
    }
}

/* Settings Sections */
.settings-section {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.settings-section h2 {
    color: #202124;
    margin-bottom: 20px;
    font-size: 20px;
}

/* Loading Overlay */
#loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(66, 133, 244, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    color: white;
}

#loading-overlay.hidden {
    display: none;
}

.spinner {
    border: 4px solid rgba(255,255,255,0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Status Badges */
.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-draft {
    background-color: var(--google-gray-light);
    color: var(--google-gray);
}

.status-sent {
    background-color: var(--google-blue);
    color: white;
}

.status-paid {
    background-color: var(--google-green);
    color: white;
}

.status-overdue {
    background-color: var(--google-red);
    color: white;
}

/* Action Buttons in Tables */
.action-buttons {
    display: flex;
    gap: 5px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--google-gray);
}

.empty-state-large {
    padding: 60px 40px;
    background: white;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    grid-column: 1 / -1;
}

.empty-state-table {
    padding: 48px 20px;
}

.empty-state-illustration {
    margin-bottom: 1.5rem;
}

.empty-state-illustration svg {
    width: 180px;
    height: 140px;
    margin: 0 auto;
    display: block;
}

.empty-state-large .empty-state-illustration svg {
    width: 220px;
    height: 170px;
}

.empty-state h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a2e;
}

.empty-state-large h3 {
    font-size: 1.5rem;
}

.empty-state p {
    margin: 0 0 1.5rem 0;
    font-size: 0.95rem;
    color: var(--google-gray);
    max-width: 360px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

.empty-state-action {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.empty-state-action svg {
    width: 18px;
    height: 18px;
}

/* ========== MODERN DASHBOARD STYLES ========== */

/* Dashboard Header */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.dashboard-header h1 {
    font-size: 1.75rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 0.25rem;
}

.dashboard-header .subtitle {
    color: var(--google-gray);
    font-size: 0.9rem;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--card-shadow-hover);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
}

.stat-icon-total {
    background: var(--gradient-blue);
}

.stat-icon-pending {
    background: var(--gradient-orange);
}

.stat-icon-paid {
    background: var(--gradient-green);
}

.stat-icon-overdue {
    background: var(--gradient-red);
}

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

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a2e;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--google-gray);
}

/* Charts Section */
.charts-section {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.chart-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
}

.chart-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.chart-card-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0;
}

.chart-period {
    font-size: 0.75rem;
    color: var(--google-gray);
    background: var(--google-gray-light);
    padding: 4px 8px;
    border-radius: 4px;
}

.chart-container {
    position: relative;
    height: 250px;
}

.chart-container-doughnut {
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Search Section */
/* ========== FILTER SECTION ========== */

.filter-section {
    margin-bottom: 1.5rem;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
    background: white;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
}

.filter-item {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.filter-item.filter-search {
    flex: 1;
    min-width: 200px;
}

.filter-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--google-gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-select {
    padding: 0.6rem 2rem 0.6rem 0.75rem;
    border: 1px solid var(--google-gray-light);
    border-radius: 8px;
    font-size: 0.875rem;
    background: white;
    cursor: pointer;
    min-width: 140px;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235F6368' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-select:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.filter-input,
.filter-date {
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--google-gray-light);
    border-radius: 8px;
    font-size: 0.875rem;
    background: white;
    min-width: 140px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-date {
    cursor: pointer;
}

.filter-input:focus,
.filter-date:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.filter-input::placeholder {
    color: #9ca3af;
}

.filter-item.filter-actions {
    justify-content: flex-end;
}

.btn-ghost {
    background: transparent;
    color: var(--google-gray);
    border: none;
    padding: 0.6rem 1rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
}

.btn-ghost:hover {
    background: #f1f3f4;
    color: var(--google-red);
}

.btn-ghost svg {
    width: 16px;
    height: 16px;
}

/* Active Filters Chips */
.active-filters {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
    padding: 0.5rem 0;
}

.active-filters-label {
    font-size: 0.8rem;
    color: var(--google-gray);
}

.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.5rem 0.35rem 0.75rem;
    background: #e8f0fe;
    color: var(--google-blue);
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 500;
}

.filter-chip-remove {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border: none;
    background: transparent;
    color: var(--google-blue);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.2s;
}

.filter-chip-remove:hover {
    background: rgba(66, 133, 244, 0.2);
}

.filter-chip-remove svg {
    width: 12px;
    height: 12px;
}

/* Search Input */
.search-input-wrapper {
    position: relative;
    width: 100%;
}

.search-input-wrapper .search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: var(--google-gray);
}

.search-input-wrapper input {
    width: 100%;
    padding: 0.6rem 1rem 0.6rem 2.75rem;
    border: 1px solid var(--google-gray-light);
    border-radius: 8px;
    font-size: 0.875rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.search-input-wrapper input:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Invoice Cards Grid */
.invoices-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.invoice-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.invoice-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--card-shadow-hover);
}

.invoice-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.invoice-id {
    font-weight: 600;
    color: var(--google-blue);
    font-size: 0.95rem;
}

.invoice-date {
    font-size: 0.8rem;
    color: var(--google-gray);
}

.invoice-customer {
    font-size: 1.1rem;
    font-weight: 500;
    color: #1a1a2e;
    margin-bottom: 0.5rem;
}

.invoice-amount {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 1rem;
}

.invoice-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--google-gray-light);
    gap: 1rem;
}

.invoice-card .status-badge {
    font-size: 0.75rem;
    padding: 0.35rem 0.75rem;
    flex-shrink: 0;
}

.invoice-card .action-buttons {
    gap: 0.5rem;
    flex-shrink: 0;
}

.invoice-card .action-buttons .btn {
    padding: 0.4rem 0.75rem;
    font-size: 0.75rem;
}

.invoice-card .action-buttons .btn-icon-only {
    padding: 0.4rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.invoice-card .action-buttons .btn-icon-only svg {
    width: 14px;
    height: 14px;
}

/* Empty State for Cards */
.invoices-grid .empty-state {
    grid-column: 1 / -1;
    background: white;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
}

/* Responsive Design for Dashboard */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .charts-section {
        grid-template-columns: 1fr;
    }

    .invoices-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

    /* Hide sidebar by default */
    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        z-index: 1002;
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    /* Hide sidebar toggle on mobile (use hamburger instead) */
    .sidebar-toggle {
        display: none;
    }

    /* Adjust main content for mobile header */
    .main-content {
        margin-left: 0;
        padding-top: 56px;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .stat-card {
        padding: 1rem;
    }

    .stat-icon {
        width: 40px;
        height: 40px;
    }

    .stat-value {
        font-size: 1.25rem;
    }

    .charts-section {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .chart-card {
        padding: 1rem;
    }

    .chart-container {
        height: 200px;
    }

    .invoices-grid {
        grid-template-columns: 1fr;
    }

    .filter-bar {
        padding: 1rem;
    }

    .filter-item {
        width: 100%;
    }

    .filter-item.filter-search {
        order: -1;
    }

    .filter-select,
    .filter-input,
    .filter-date {
        width: 100%;
    }

    .filter-item.filter-actions {
        width: 100%;
    }

    .filter-item.filter-actions .btn-ghost {
        width: 100%;
        justify-content: center;
    }

    .search-input-wrapper {
        max-width: 100%;
    }
}

/* ========== CONFIRMATION MODAL ========== */

.confirm-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.confirm-modal.hidden {
    display: none;
}

.confirm-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.confirm-modal-content {
    position: relative;
    background: white;
    border-radius: 16px;
    padding: 2rem;
    max-width: 360px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    animation: modalSlideIn 0.2s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.confirm-modal-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    background: var(--gradient-red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.confirm-modal-icon svg {
    width: 32px;
    height: 32px;
    color: white;
}

.confirm-modal-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 0.5rem;
}

.confirm-modal-content p {
    color: var(--google-gray);
    margin-bottom: 1.5rem;
}

.confirm-modal-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.confirm-modal-actions .btn {
    flex: 1;
    max-width: 140px;
}

/* ========== MODERN INVOICE EDITOR ========== */

.invoice-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.invoice-editor-header h1 {
    font-size: 1.75rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 0.25rem;
}

.invoice-editor-header .subtitle {
    color: var(--google-gray);
    font-size: 0.9rem;
}

.invoice-editor-header .btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.editor-header-actions {
    display: flex;
    gap: 0.75rem;
}

/* Split View Layout */
.invoice-editor-split {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 1.5rem;
    align-items: start;
}

.invoice-form-panel {
    min-width: 0;
}

/* Preview Panel */
.invoice-preview-panel {
    position: sticky;
    top: 1rem;
    background: white;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    max-height: calc(100vh - 2rem);
    display: flex;
    flex-direction: column;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, #1a1a2e 0%, #2d2d44 100%);
    color: white;
}

.preview-header h3 {
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0;
}

.btn-ghost {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s;
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.preview-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem;
    background: #f8f9fa;
}

/* Invoice Preview Styles */
.invoice-preview {
    background: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    font-size: 0.8rem;
}

.preview-business-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
}

.preview-business-info h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 0.25rem 0;
}

.preview-business-info p {
    margin: 0;
    color: var(--google-gray);
    font-size: 0.75rem;
    line-height: 1.4;
}

.preview-invoice-title {
    text-align: right;
}

.preview-invoice-title h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--google-blue);
    margin: 0;
    letter-spacing: 2px;
}

.preview-invoice-title p {
    margin: 0.25rem 0 0 0;
    color: var(--google-gray);
    font-size: 0.85rem;
}

.preview-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.preview-bill-to h4 {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--google-gray);
    margin: 0 0 0.5rem 0;
    letter-spacing: 0.5px;
}

.preview-bill-to p {
    margin: 0;
    color: #1a1a2e;
    font-weight: 500;
}

.preview-bill-to p:last-child {
    font-weight: 400;
    color: var(--google-gray);
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.preview-dates {
    text-align: right;
}

.preview-date-row {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-bottom: 0.35rem;
    font-size: 0.75rem;
}

.preview-date-row span:first-child {
    color: var(--google-gray);
}

.preview-date-row span:last-child {
    font-weight: 500;
    color: #1a1a2e;
    min-width: 70px;
}

.preview-status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    background: #e9ecef;
    color: #6c757d;
}

.preview-status-badge.draft { background: #e9ecef; color: #6c757d; }
.preview-status-badge.sent { background: #cce5ff; color: #004085; }
.preview-status-badge.paid { background: #d4edda; color: #155724; }
.preview-status-badge.overdue { background: #f8d7da; color: #721c24; }

/* Preview Items Table */
.preview-items {
    margin-bottom: 1rem;
}

.preview-items table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.75rem;
}

.preview-items th {
    background: #f8f9fa;
    padding: 0.5rem 0.75rem;
    text-align: left;
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--google-gray);
    border-bottom: 2px solid #e9ecef;
}

.preview-items th:last-child,
.preview-items td:last-child {
    text-align: right;
}

.preview-items td {
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid #f1f3f4;
    color: #1a1a2e;
}

.preview-empty-row td {
    text-align: center !important;
    color: var(--google-gray);
    font-style: italic;
    padding: 1rem;
}

/* Preview Totals */
.preview-totals {
    margin-left: auto;
    width: 200px;
    padding-top: 0.5rem;
}

.preview-total-row {
    display: flex;
    justify-content: space-between;
    padding: 0.35rem 0;
    font-size: 0.75rem;
}

.preview-total-row span:first-child {
    color: var(--google-gray);
}

.preview-total-row span:last-child {
    font-weight: 500;
    color: #1a1a2e;
}

.preview-grand-total {
    border-top: 2px solid #1a1a2e;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
}

.preview-grand-total span {
    font-weight: 700 !important;
    font-size: 0.9rem !important;
    color: #1a1a2e !important;
}

/* Preview Notes */
.preview-notes {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.preview-notes h4 {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--google-gray);
    margin: 0 0 0.5rem 0;
}

.preview-notes p {
    margin: 0;
    color: #1a1a2e;
    font-size: 0.75rem;
    line-height: 1.5;
    white-space: pre-wrap;
}

/* Preview Toggle Button (for mobile) */
#toggle-preview-btn {
    display: none;
}

#close-preview-btn {
    display: none;
}

.invoice-form-modern {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Form Cards */
.form-card {
    background: white;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
}

.form-card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom: 1px solid var(--google-gray-light);
}

.form-card-header svg {
    color: var(--google-blue);
}

.form-card-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0;
}

.form-card-body {
    padding: 1.5rem;
}

/* Form Grid */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.form-grid .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #1a1a2e;
    font-size: 0.875rem;
}

.form-grid .form-group input,
.form-grid .form-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--google-gray-light);
    border-radius: 8px;
    font-size: 0.9rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-grid .form-group input:focus,
.form-grid .form-group select:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Line Items Container */
.line-items-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Line Item Card */
.line-item-card {
    background: #f8f9fa;
    border: 1px solid var(--google-gray-light);
    border-radius: 10px;
    padding: 1rem;
    position: relative;
}

.line-item-card:hover {
    border-color: var(--google-blue);
}

.line-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.line-item-number {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--google-blue);
    background: rgba(66, 133, 244, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.line-item-remove {
    background: none;
    border: none;
    color: var(--google-red);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: background 0.2s;
}

.line-item-remove:hover {
    background: rgba(234, 67, 53, 0.1);
}

.line-item-remove svg {
    width: 18px;
    height: 18px;
}

.line-item-fields {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.line-item-field label {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--google-gray);
    margin-bottom: 0.25rem;
}

.line-item-field input {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--google-gray-light);
    border-radius: 6px;
    font-size: 0.9rem;
    background: white;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.line-item-field input:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.1);
}

.line-item-field input[readonly] {
    background: #e9ecef;
    color: #1a1a2e;
    font-weight: 600;
}

.line-item-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

/* Add Item Button */
.btn-add-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.875rem;
    background: transparent;
    border: 2px dashed var(--google-gray-light);
    border-radius: 10px;
    color: var(--google-blue);
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.btn-add-item:hover {
    border-color: var(--google-blue);
    background: rgba(66, 133, 244, 0.05);
}

/* Taxes Section */
.taxes-section {
    margin-bottom: 1.5rem;
}

.taxes-section > label {
    display: block;
    font-weight: 500;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
}

.tax-checkboxes-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.tax-checkboxes-grid label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: #f8f9fa;
    border: 1px solid var(--google-gray-light);
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.tax-checkboxes-grid label:hover {
    border-color: var(--google-blue);
}

.tax-checkboxes-grid input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--google-blue);
}

/* Totals Display Modern */
.totals-display-modern {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    padding: 1rem 1.25rem;
}

.totals-display-modern .total-row {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    font-size: 0.95rem;
}

.totals-display-modern .total-row.grand {
    border-top: 2px solid var(--google-gray-light);
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--google-blue);
}

/* Notes Textarea */
.form-card-body textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--google-gray-light);
    border-radius: 8px;
    font-size: 0.9rem;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-card-body textarea:focus {
    outline: none;
    border-color: var(--google-blue);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Form Actions */
.form-actions-modern {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.btn-lg {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    font-size: 1rem;
}

/* Responsive Invoice Editor - Tablet */
@media (max-width: 1200px) {
    .invoice-editor-split {
        grid-template-columns: 1fr 350px;
    }
}

@media (max-width: 1024px) {
    .invoice-editor-split {
        grid-template-columns: 1fr;
    }

    .invoice-preview-panel {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1000;
        border-radius: 0;
        max-height: none;
    }

    .invoice-preview-panel.active {
        display: flex;
    }

    #toggle-preview-btn {
        display: flex;
    }

    #close-preview-btn {
        display: block;
    }

    .preview-content {
        padding: 1rem;
    }
}

/* Responsive Invoice Editor - Mobile */
@media (max-width: 768px) {
    .invoice-editor-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .editor-header-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .invoice-editor-header .btn span {
        display: none;
    }

    #toggle-preview-btn span {
        display: inline;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .line-item-row {
        grid-template-columns: 1fr 1fr;
    }

    .line-item-row .line-item-field:first-child {
        grid-column: 1 / -1;
    }

    .form-actions-modern {
        flex-direction: column;
    }

    .form-actions-modern .btn {
        width: 100%;
        justify-content: center;
    }

    .form-card-body {
        padding: 1rem;
    }

    .form-card-header {
        padding: 0.875rem 1rem;
    }
}

@media (max-width: 480px) {
    .line-item-row {
        grid-template-columns: 1fr;
    }

    .line-item-row .line-item-field:first-child {
        grid-column: auto;
    }
}

/* ========== TOAST NOTIFICATIONS ========== */

#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-width: 300px;
    max-width: 450px;
    padding: 1rem 1.25rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.15), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    pointer-events: auto;
    animation: toastSlideIn 0.3s ease-out;
    border-left: 4px solid;
}

.toast.toast-success {
    border-left-color: var(--google-green);
}

.toast.toast-error {
    border-left-color: var(--google-red);
}

.toast.toast-warning {
    border-left-color: var(--google-yellow);
}

.toast.toast-info {
    border-left-color: var(--google-blue);
}

.toast.toast-hiding {
    animation: toastSlideOut 0.3s ease-in forwards;
}

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

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

.toast-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toast-success .toast-icon {
    color: var(--google-green);
}

.toast-error .toast-icon {
    color: var(--google-red);
}

.toast-warning .toast-icon {
    color: var(--google-yellow);
}

.toast-info .toast-icon {
    color: var(--google-blue);
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: #1a1a2e;
    margin-bottom: 2px;
}

.toast-message {
    font-size: 0.875rem;
    color: var(--google-gray);
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: var(--google-gray);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s, color 0.2s;
    flex-shrink: 0;
}

.toast-close:hover {
    background: var(--google-gray-light);
    color: #1a1a2e;
}

.toast-close svg {
    width: 16px;
    height: 16px;
}

.toast-action {
    display: inline-block;
    margin-top: 8px;
    padding: 6px 12px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--google-blue);
    background: rgba(66, 133, 244, 0.1);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}

.toast-action:hover {
    background: rgba(66, 133, 244, 0.2);
}

@media (max-width: 480px) {
    #toast-container {
        top: auto;
        bottom: 20px;
        left: 20px;
        right: 20px;
    }

    .toast {
        min-width: auto;
        max-width: none;
    }
}

/* Upgrade Prompt */
.upgrade-prompt-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    padding: 40px 20px;
}

.upgrade-prompt-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 48px;
    max-width: 480px;
    text-align: center;
}

.upgrade-prompt-icon {
    margin-bottom: 24px;
    color: var(--google-blue);
}

.upgrade-prompt-card h2 {
    font-size: 24px;
    color: #202124;
    margin-bottom: 12px;
}

.upgrade-prompt-description {
    color: #5f6368;
    font-size: 15px;
    margin-bottom: 24px;
    line-height: 1.5;
}

.upgrade-prompt-features {
    list-style: none;
    padding: 0;
    margin: 0 0 32px 0;
    text-align: left;
}

.upgrade-prompt-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    color: #202124;
    font-size: 14px;
    border-bottom: 1px solid #f1f3f4;
}

.upgrade-prompt-features li:last-child {
    border-bottom: none;
}

.upgrade-prompt-features li svg {
    color: #34a853;
    flex-shrink: 0;
}

/* General Search Container */
.search-container {
    margin-bottom: 20px;
}

.search-container .search-input-wrapper {
    max-width: 400px;
}

/* Inventory Search */
.inventory-search {
    margin-bottom: 24px;
}

.inventory-search .search-input-wrapper {
    max-width: 400px;
}

/* Inventory Table Styles */
#inventory-table-container .data-table th:nth-child(3),
#inventory-table-container .data-table td:nth-child(3),
#inventory-table-container .data-table th:nth-child(4),
#inventory-table-container .data-table td:nth-child(4) {
    text-align: right;
    width: 120px;
}

#inventory-table-container .data-table th:nth-child(5),
#inventory-table-container .data-table td:nth-child(5) {
    width: 100px;
    text-align: center;
}

.inventory-quantity {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.inventory-quantity.low-stock {
    color: #ea4335;
}

.inventory-quantity.in-stock {
    color: #34a853;
}

.low-stock-badge {
    font-size: 10px;
    background: #fce8e6;
    color: #c5221f;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
}

/* Inventory Search Dropdown in Invoice */
.inventory-search-dropdown {
    position: relative;
}

.inventory-dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #dadce0;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    list-style: none;
    padding: 0;
    margin: 4px 0 0 0;
}

.inventory-dropdown-list li {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f1f3f4;
    transition: background 0.15s;
}

.inventory-dropdown-list li:last-child {
    border-bottom: none;
}

.inventory-dropdown-list li:hover {
    background: #f8f9fa;
}

.inventory-dropdown-list li.no-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #5f6368;
    cursor: default;
}

.inventory-dropdown-list li.no-results:hover {
    background: white;
}

.inventory-dropdown-list .add-item-link {
    color: var(--google-blue);
    font-weight: 500;
    text-decoration: none;
    font-size: 13px;
}

.inventory-dropdown-list .add-item-link:hover {
    text-decoration: underline;
}

.inventory-item-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2px;
}

.inventory-item-name {
    font-weight: 500;
    color: #202124;
}

.inventory-item-price {
    color: #5f6368;
    font-size: 13px;
}

.inventory-item-stock {
    font-size: 12px;
}

.inventory-item-stock.in-stock {
    color: #34a853;
}

.inventory-item-stock.low-stock {
    color: #ea4335;
}

.item-stock-info {
    display: block;
    font-size: 11px;
    margin-top: 4px;
}

.item-stock-info.in-stock {
    color: #34a853;
}

.item-stock-info.low-stock {
    color: #ea4335;
}

.item-search-field {
    position: relative;
}

/* ========== DRIVE PERMISSION PROMPT ========== */

.permission-prompt-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 20px;
}

.permission-prompt-overlay.active {
    display: flex;
}

.permission-prompt {
    background: white;
    border-radius: 16px;
    padding: 40px;
    max-width: 480px;
    width: 100%;
    text-align: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: permissionModalIn 0.3s ease-out;
}

@keyframes permissionModalIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.permission-prompt .permission-icon {
    margin-bottom: 20px;
}

.permission-prompt .permission-icon svg {
    display: inline-block;
}

.permission-prompt h2 {
    font-size: 24px;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 16px;
}

.permission-prompt p {
    color: #5f6368;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 12px;
}

.permission-prompt .permission-details {
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
    padding: 16px;
    margin: 20px 0;
    font-size: 14px;
    color: #856404;
}

.permission-prompt .permission-details strong {
    display: block;
    margin-top: 8px;
    color: #664d03;
}

.permission-prompt .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 180px;
    margin: 8px;
    padding: 14px 28px;
    font-size: 15px;
    font-weight: 500;
}

.permission-prompt .btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
}

.permission-prompt .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.permission-prompt .btn-secondary {
    background: #f5f5f5;
    color: #5f6368;
    border: 1px solid #e0e0e0;
}

.permission-prompt .btn-secondary:hover {
    background: #eeeeee;
}

@media (max-width: 480px) {
    .permission-prompt {
        padding: 30px 24px;
    }

    .permission-prompt h2 {
        font-size: 20px;
    }

    .permission-prompt .btn {
        display: flex;
        width: 100%;
        margin: 8px 0;
    }
}

/* ========== GMAIL EMAIL STYLES ========== */

.btn-gmail {
    background-color: #fff;
    color: #333;
    border: 1px solid #dadce0;
}

.btn-gmail:hover {
    background-color: #f8f9fa;
    border-color: #c6c6c6;
}

.btn-gmail.btn-icon-only {
    background-color: #fff;
    border: 1px solid #dadce0;
}

.btn-gmail.btn-icon-only:hover {
    background-color: #f1f3f4;
}

.btn-gmail.btn-icon-only svg {
    width: 18px;
    height: 18px;
}

/* Gmail Auth Modal */
.gmail-auth-icon {
    text-align: center;
    margin-bottom: 16px;
}

.gmail-auth-hint {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 12px;
    font-size: 13px;
    color: #5f6368;
    margin-top: 12px;
}

/* Email Compose Modal */
.modal-medium {
    max-width: 560px;
}

#email-compose-modal .form-group {
    margin-bottom: 16px;
}

#email-compose-modal label {
    display: block;
    font-weight: 500;
    margin-bottom: 6px;
    color: #333;
}

#email-compose-modal input[type="text"],
#email-compose-modal input[type="email"],
#email-compose-modal textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
}

#email-compose-modal textarea {
    resize: vertical;
    min-height: 120px;
}

#email-compose-modal input:focus,
#email-compose-modal textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.readonly-input {
    background-color: #f5f5f5;
    color: #666;
    cursor: not-allowed;
}

.checkbox-group label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: normal;
}

.checkbox-group input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.email-footer-notice {
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 12px;
    color: #856404;
    margin-top: 8px;
}

#email-compose-modal .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid #e0e0e0;
    margin-top: 8px;
}

#email-compose-modal .btn-gmail {
    display: inline-flex;
    align-items: center;
}
