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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8fafc;
}

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

/* Header */
.header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icon {
    width: 32px;
    height: 32px;
}

.logo h1 {
    color: #2563eb;
    font-size: 24px;
    font-weight: bold;
}

.logo a {
    text-decoration: none;
    color: inherit;
}

.logo i {
    color: #2563eb;
    font-size: 24px;
}

.nav {
    display: flex;
    gap: 30px;
}

.nav a {
    text-decoration: none;
    color: #64748b;
    font-weight: 500;
    transition: color 0.3s;
}

.nav a:hover {
    color: #2563eb;
}

.lang-switch {
    background: #e2e8f0 !important;
    color: #64748b !important;
    padding: 6px 12px !important;
    border-radius: 20px !important;
    font-size: 14px !important;
    transition: all 0.3s !important;
}

.lang-switch:hover {
    background: #2563eb !important;
    color: white !important;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 120px 0 80px;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

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

.hero-content h2 {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.download-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, #4285f4 0%, #34a853 50%, #fbbc05 75%, #ea4335 100%);
    color: white;
    border: 2px solid #1a73e8;
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #5a95f5 0%, #42b883 50%, #fcc468 75%, #f56565 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(66, 133, 244, 0.4);
}

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

.btn-secondary {
    background: #1f2937;
    color: white;
}

.btn-secondary:hover {
    background: #111827;
    transform: translateY(-2px);
}

.btn-large {
    padding: 18px 32px;
    font-size: 16px;
    border-radius: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.btn-large div {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.btn-large small {
    font-size: 12px;
    opacity: 0.9;
    font-weight: 400;
}

.btn-primary .fab.fa-google-play {
    font-size: 24px;
    background: linear-gradient(45deg, #4285f4, #34a853, #fbbc05, #ea4335);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.btn-outline {
    background: transparent;
    color: #2563eb;
    border: 2px solid #2563eb;
}

.btn-outline:hover {
    background: #2563eb;
    color: white;
}

/* Phone Mockup */
.hero-image {
    display: flex;
    justify-content: center;
}

.phone-mockup {
    position: relative;
    width: 300px;
    height: 600px;
    background: #1f2937;
    border-radius: 30px;
    padding: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.screen {
    width: 100%;
    height: 100%;
    background: #f8fafc;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.screen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Sections */
section {
    padding: 80px 0;
}

section h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 50px;
    color: #1f2937;
}

/* Features Section */
.features {
    background: white;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.feature-card {
    padding: 30px;
    background: #f8fafc;
    border-radius: 12px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.feature-card i {
    font-size: 3rem;
    color: #2563eb;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: #1f2937;
}

.feature-card p {
    color: #64748b;
    line-height: 1.6;
}

/* Download Section */
.download {
    background: #1f2937;
    color: white;
    text-align: center;
}

.download h2 {
    color: white;
}

.download p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

/* Guide Section */
.guide {
    background: white;
}

.guide-steps {
    max-width: 800px;
    margin: 0 auto;
}

.step {
    display: flex;
    gap: 30px;
    margin-bottom: 60px;
    align-items: flex-start;
}

.step-number {
    width: 60px;
    height: 60px;
    background: #2563eb;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    flex-shrink: 0;
}

.step-content h3 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: #1f2937;
}

.step-content p {
    color: #64748b;
    margin-bottom: 20px;
}

.screenshot {
    width: 200px;
    height: 400px;
    background: #f1f5f9;
    border-radius: 20px;
    border: 2px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    font-style: italic;
}

.screenshot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 18px;
}

/* Legal Section */
.legal {
    background: #f8fafc;
}

.legal-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    max-width: 800px;
    margin: 0 auto;
}

.legal-card {
    background: white;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.legal-card h3 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: #1f2937;
}

.legal-card p {
    color: #64748b;
    margin-bottom: 20px;
}

/* Legal Pages */
.legal-page {
    padding-top: 100px;
    background: white;
    min-height: 100vh;
}

.legal-page h1 {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 30px;
    color: #1f2937;
    text-align: center;
}

.legal-info {
    text-align: center;
    margin-bottom: 40px;
    padding: 20px;
    background: #f8fafc;
    border-radius: 8px;
}

.legal-content section {
    margin-bottom: 40px;
    padding: 0;
}

.legal-content h2 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 20px;
    color: #1f2937;
    text-align: left;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 10px;
}

.legal-content h3 {
    font-size: 1.2rem;
    font-weight: bold;
    margin: 20px 0 10px;
    color: #374151;
}

.legal-content p {
    margin-bottom: 15px;
    line-height: 1.7;
    color: #4b5563;
}

.legal-content ul, .legal-content ol {
    margin: 15px 0;
    padding-left: 30px;
}

.legal-content li {
    margin-bottom: 8px;
    line-height: 1.6;
    color: #4b5563;
}

.contact-info {
    background: #f8fafc;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
}

/* Footer */
.footer {
    background: #1f2937;
    color: white;
    padding: 40px 0 20px;
}

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

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.2rem;
    font-weight: bold;
}

.footer-logo-icon {
    width: 24px;
    height: 24px;
}

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

.footer-links a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #374151;
    color: #9ca3af;
}

/* Mobile-optimized Legal Pages */
@media (max-width: 768px) {
    .legal-page .container {
        padding: 16px;
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
    }
    
    .legal-page h1 {
        font-size: 20px;
        margin-bottom: 20px;
        position: sticky;
        top: 0;
        background: white;
        z-index: 100;
        padding: 16px 0;
        margin-top: -16px;
    }
    
    .legal-content h2 {
        font-size: 18px;
        margin: 24px 0 12px;
        border-left: 3px solid #2563eb;
        padding-left: 12px;
        background: #f8fafc;
        padding: 12px;
        border-radius: 8px;
    }
    
    .legal-content h3 {
        font-size: 16px;
        margin: 16px 0 8px;
        color: #2563eb;
    }
    
    .legal-content p {
        font-size: 14px;
        line-height: 1.7;
        margin-bottom: 16px;
    }
    
    .legal-content ul,
    .legal-content ol {
        font-size: 14px;
        padding-left: 20px;
        margin: 12px 0;
    }
    
    .legal-content li {
        margin-bottom: 8px;
        line-height: 1.6;
    }
    
    .legal-info {
        font-size: 12px;
        padding: 12px;
        margin-bottom: 20px;
        border-radius: 6px;
    }
    
    .contact-info {
        font-size: 14px;
        padding: 16px;
        border-radius: 8px;
        margin: 20px 0;
        border: 1px solid #e2e8f0;
    }
    
    /* Mobile navigation improvements */
    .header {
        position: relative;
    }
    
    .legal-page .header {
        display: none; /* Hide header on mobile for legal pages */
    }
    
    /* Add back-to-app button for mobile */
    .legal-page::after {
        content: '';
        height: 80px;
        display: block;
    }
}

/* Mobile WebView specific optimizations */
@media (max-width: 768px) and (display-mode: standalone) {
    .legal-page {
        padding-top: 0;
    }
}

/* Add table of contents for mobile */
@media (max-width: 768px) {
    .mobile-toc {
        display: block;
        background: #f1f5f9;
        border: 1px solid #e2e8f0;
        border-radius: 8px;
        padding: 16px;
        margin: 20px 0;
        position: sticky;
        top: 80px;
        z-index: 50;
    }
    
    .mobile-toc h3 {
        margin: 0 0 12px 0;
        font-size: 14px;
        color: #374151;
    }
    
    .mobile-toc select {
        width: 100%;
        padding: 8px 12px;
        border: 1px solid #d1d5db;
        border-radius: 6px;
        background: white;
        font-size: 14px;
    }
}

/* Hide mobile-specific elements on desktop */
@media (min-width: 769px) {
    .mobile-toc {
        display: none;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .nav {
        gap: 20px;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }
    
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .phone-mockup {
        width: 250px;
        height: 500px;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .legal-content {
        grid-template-columns: 1fr;
    }
    
    .step {
        flex-direction: column;
        text-align: center;
    }
    
    .screenshot {
        align-self: center;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .download-buttons {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero-content h2 {
        font-size: 1.5rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    section h2 {
        font-size: 2rem;
    }
    
    .btn-large {
        width: 100%;
        justify-content: center;
    }
    
    .screenshot {
        width: 150px;
        height: 300px;
    }
}