/* Root Variables */
:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary-color: #64748b;
    --accent-color: #f59e0b;
    --success-color: #10b981;
    --text-dark: #1f2937;
    --text-medium: #4b5563;
    --text-light: #6b7280;
    --background-light: #f8fafc;
    --background-white: #ffffff;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --max-width: 1200px;
}

/* Reset and Base Styles */
* {
    box-sizing: border-box;
}

/* Ensure proper page flow */
body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background-white);
    min-height: 100vh;
}

#app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    margin: 0 0 1rem 0;
    line-height: 1.2;
    font-weight: 700;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.875rem); }
h4 { font-size: 1.25rem; }

p {
    margin: 0 0 1rem 0;
    color: var(--text-medium);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    min-height: 44px; /* Accessibility: minimum touch target */
}

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

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

/* Download Button Styles */
.download-btn {
    display: inline-block;
    text-decoration: none;
    transition: transform 0.2s ease, filter 0.2s ease;
    min-height: 44px; /* Accessibility: minimum touch target */
}

.download-btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.1);
}

.download-btn:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.download-button-image {
    height: 50px;
    width: auto;
    display: block;
}

.download-button-large {
    height: 60px;
    width: auto;
}

/* Section Headers */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-medium);
    max-width: 600px;
    margin: 0 auto;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--background-light) 0%, var(--background-white) 100%);
    padding: 0 0 6rem 0;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1rem;
}

/* Logo Styles */
.hero-logo {
    text-align: center;
    margin-bottom: 1rem;
    margin-top: -4rem;
}

.logo-download {
    text-align: center;
    margin-bottom: 2rem;
}

.main-logo {
    height: 400px;
    width: auto;
    max-width: 800px;
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    transition: transform 0.2s ease;
}

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

.hero-title {
    margin-bottom: 1.5rem;
    border: none;
    background: none;
    padding: 0;
}

.hero-title .highlight {
    color: var(--primary-color);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    border: none;
    padding: 0;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: var(--text-medium);
}

.hero-features {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.feature-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: var(--background-light);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-dark);
}

.feature-badge .icon {
    font-size: 1rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Image Styles */
.hero-screenshot,
.feature-screenshot,
.solution-comparison,
.privacy-illustration,
.accessibility-illustration {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-screenshot {
    max-width: 400px;
    margin: 0 auto;
    display: block;
}

.feature-screenshot {
    max-width: 300px;
    height: auto;
    object-fit: contain;
    margin: 0 auto;
    display: block;
}

.solution-comparison {
    max-width: 350px;
    height: auto;
    object-fit: contain;
    margin: 0 auto;
    display: block;
}

.privacy-illustration,
.accessibility-illustration {
    max-width: 400px;
    margin: 0 auto;
    display: block;
}

.hero-screenshot:hover,
.feature-screenshot:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Download badges */
.download-badges {
    display: flex;
    gap: 2rem;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin: 2rem 0;
}

.app-store-badge {
    height: 60px;
    width: auto;
    transition: transform 0.2s ease;
}

.app-store-badge:hover {
    transform: scale(1.05);
}

.qr-code {
    height: 80px;
    width: 80px;
    border-radius: var(--border-radius);
    background-color: white;
    padding: 0.5rem;
    box-shadow: var(--shadow-sm);
}

/* Image Placeholders */
.image-placeholder {
    background: linear-gradient(45deg, #f3f4f6, #e5e7eb);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    text-align: center;
    border: 2px dashed var(--border-color);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.image-placeholder p {
    margin: 0 0 0.5rem 0;
    font-weight: 600;
    color: var(--text-medium);
}

.image-placeholder small {
    color: var(--text-light);
    font-size: 0.875rem;
}

/* Problem/Solution Section */
.problem-solution {
    padding: 6rem 0;
    background-color: var(--background-light);
}

.solution-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.solution-item {
    text-align: center;
}

.solution-image {
    margin-bottom: 1.5rem;
}

.solution-content h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Features Section */
.features {
    padding: 6rem 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card {
    background-color: var(--background-white);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-image {
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    color: var(--text-dark);
    margin-bottom: 1rem;
}

/* Privacy Section */
.privacy {
    padding: 6rem 0;
    background-color: var(--background-light);
}

.privacy-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.privacy-subtitle {
    font-size: 1.125rem;
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 2rem;
}

.privacy-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.privacy-features li {
    display: flex;
    flex-direction: column;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background-color: var(--background-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
}

.privacy-features li strong {
    color: var(--text-dark);
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.privacy-features li span {
    color: var(--text-medium);
    font-size: 0.875rem;
}

/* Use Cases Section */
.use-cases {
    padding: 6rem 0;
}

.use-cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.use-case {
    text-align: center;
    padding: 2rem 1rem;
    border-radius: var(--border-radius-lg);
    transition: transform 0.2s ease;
}

.use-case:hover {
    transform: translateY(-2px);
}

.use-case-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.use-case h3 {
    color: var(--text-dark);
    margin-bottom: 1rem;
}

/* Accessibility Section */
.accessibility {
    padding: 6rem 0;
    background-color: var(--background-light);
}

.accessibility-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.accessibility-subtitle {
    font-size: 1.125rem;
    color: var(--text-medium);
    margin-bottom: 2rem;
}

.accessibility-benefits {
    display: grid;
    gap: 1.5rem;
}

.benefit {
    padding: 1.5rem;
    background-color: var(--background-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
}

.benefit h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.benefit p {
    margin: 0;
    font-size: 0.875rem;
}

/* Final CTA Section */
.final-cta {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: white;
    text-align: center;
}

.final-cta h2 {
    color: white;
    margin-bottom: 1rem;
}

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

.final-cta .cta-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2rem 0;
}

.cta-image {
    margin: 2rem 0;
}

.final-cta .image-placeholder {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.8);
}

.cta-note {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 1rem;
}

/* Footer */
.footer {
    background-color: #ffffff;
    color: #000000;
    padding: 4rem 0 2rem 0;
    position: relative;
    z-index: 1;
    margin-top: 0;
    clear: both;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin-bottom: 2rem;
}

.footer-brand h3 {
    color: #000000;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.footer-brand p {
    color: #333333;
}

.footer-links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.footer-column h4 {
    color: #000000;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 600;
}

.footer-column p {
    color: #333333;
    font-weight: 500;
}

.footer-column p a {
    color: #1f2937;
    text-decoration: underline;
    transition: color 0.2s ease;
    font-weight: 600;
}

.footer-column p a:hover {
    color: #000000;
}

.footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-column ul li {
    margin-bottom: 0.5rem;
}

.footer-column ul li a {
    color: #333333;
    text-decoration: none;
    transition: color 0.2s ease;
    font-weight: 500;
}

.footer-column ul li a:hover {
    color: #000000;
    text-decoration: underline;
}

.footer-bottom {
    border-top: 2px solid #cccccc;
    padding-top: 2rem;
    text-align: center;
}

.footer-bottom p {
    color: #333333;
    margin: 0;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-content,
    .solution-grid,
    .privacy-content,
    .accessibility-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .hero {
        padding: 0 0 4rem 0;
        text-align: center;
    }
    
    .hero-features {
        justify-content: center;
    }
    
    .cta-buttons {
        justify-content: center;
        flex-direction: column;
        align-items: center;
    }
    
    .final-cta .cta-buttons {
        justify-content: center;
        align-items: center;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-links {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .features-grid,
    .use-cases-grid {
        grid-template-columns: 1fr;
    }
    
    .download-badges {
        flex-direction: column;
        gap: 1rem;
    }
    
    .hero-screenshot {
        max-width: 300px;
    }
    
    .feature-screenshot {
        max-width: 250px;
    }
    
    .solution-comparison {
        max-width: 280px;
    }
    
    /* Logo responsive styles */
    .main-logo {
        height: 320px;
        max-width: 700px;
    }
    
    .hero-logo {
        margin-top: -3rem;
        margin-bottom: 0.5rem;
    }
    
    .logo-download {
        margin-bottom: 1.5rem;
    }
    
    /* Download button tablet styles */
    .download-button-image {
        height: 48px;
    }
    
    .download-button-large {
        height: 58px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero {
        padding: 0 0 3rem 0;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .final-cta .cta-buttons {
        justify-content: center;
        align-items: center;
    }
    
    .btn {
        width: 100%;
    }
    
    .feature-badge {
        font-size: 0.75rem;
        padding: 0.375rem 0.75rem;
    }
    
    .hero-screenshot {
        max-width: 250px;
    }
    
    .feature-screenshot {
        max-width: 200px;
    }
    
    .solution-comparison {
        max-width: 220px;
    }
    
    /* Logo mobile styles */
    .main-logo {
        height: 240px;
        max-width: 600px;
    }
    
    .hero-logo {
        margin-bottom: 0.5rem;
        margin-top: -2rem;
    }
    
    .logo-download {
        margin-bottom: 1rem;
    }
    
    /* Download button responsive styles */
    .download-button-image {
        height: 45px;
    }
    
    .download-button-large {
        height: 55px;
    }
}

/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

.btn:focus,
a:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --text-dark: #000000;
        --text-medium: #333333;
        --border-color: #666666;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    :root {
        --text-dark: #f9fafb;
        --text-medium: #d1d5db;
        --text-light: #9ca3af;
        --background-light: #1f2937;
        --background-white: #111827;
        --border-color: #374151;
    }
    
    .feature-card,
    .privacy-features li,
    .benefit {
        background-color: var(--background-light);
    }
}

/* Existing Blazor styles */
.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}
