:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f9fafb;
    --bg-tertiary: #f3f4f6;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-tertiary: #64748b;
    --accent-primary: #22a9e0;
    --accent-secondary: #88c5de;
    --accent-hover: #31addf;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

[data-theme="dark"] {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-tertiary: #94a3b8;
    --border-color: #334155;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
}

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

html {
    scroll-behavior: smooth;
}

/* RTL Support */
[dir="rtl"] {
    direction: rtl;
    text-align: right;
}

[dir="rtl"] .hero-content {
    direction: rtl;
}

[dir="rtl"] .content-grid.reverse {
    direction: ltr;
}

[dir="rtl"] .content-grid.reverse > * {
    direction: rtl;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

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

/* Top Bar */
.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    backdrop-filter: blur(10px);
    background-color: rgba(255, 255, 255, 0.8);
    transition: background-color 0.3s ease;
}

[data-theme="dark"] .top-bar {
    background-color: rgba(15, 23, 42, 0.8);
}

.top-bar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* Logo image variants */
.logo-img {
    display: none; /* hide by default, show specific variant */
    height: 40px;
    width: auto;
    object-fit: contain;
}

/* Light theme shows light logo by default */
.logo-img.logo-light {
    display: block;
}

/* Dark theme switches to dark logo */
[data-theme="dark"] .logo-img.logo-light {
    display: none;
}

[data-theme="dark"] .logo-img.logo-dark {
    display: block;
}

.logo-text {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    font-size: 0.95rem;
}

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


[data-theme="dark"] .theme-toggle .sun-icon {
    display: none;
}

[data-theme="dark"] .theme-toggle .sun-icon {
    display: block;
}

[data-theme="dark"] .theme-toggle .moon-icon {
    display: none;
}

[data-theme="light"] .theme-toggle .sun-icon {
    display: none;
}

[data-theme="light"] .theme-toggle .moon-icon {
    display: block;
}

.download-btn {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: var(--shadow-md);
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 70px;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 0;
}

.background-pattern {
    width: 100%;
    height: 100%;
    opacity: 0.6;
}

.hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-left {
    animation: fadeInLeft 0.8s ease;
}

.hero-title {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    font-weight: 500;
    line-height: 1.4;
}

.hero-right {
    animation: fadeInRight 0.8s ease;
}

.tagline {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.tagline-desc {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.hero-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    padding: 1rem 2rem;
    border-radius: 0;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.125rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: var(--shadow-lg);
}

.hero-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.hero-download-btn svg {
    flex-shrink: 0;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.hero-ms-store-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: transparent;
    color: var(--text-secondary);
    padding: 1rem 2rem;
    border: 1px solid var(--border-color);
    border-radius: 0;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.125rem;
    transition: all 0.2s ease;
}

.hero-ms-store-btn:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

.hero-ms-store-btn svg {
    flex-shrink: 0;
}

.all-downloads-link {
    display: inline-block;
    margin-top: 1rem;
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    position: relative;
}

.all-downloads-link:hover {
    color: var(--accent-hover);
    transform: translateX(4px);
}

.all-downloads-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    transition: width 0.3s ease;
}

.all-downloads-link:hover::after {
    width: 100%;
}

/* Section Styles */
.section {
    padding: 6rem 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Content Grid */
.content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.content-grid.reverse {
    direction: rtl;
}

.content-grid.reverse > * {
    direction: ltr;
}

.content-text h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.content-text p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.8;
}

.feature-icon-large {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Privacy Section */
.privacy-section {
    background-color: var(--bg-secondary);
}

/* Formats Section - Word Cloud */
.formats-section {
    background-color: var(--bg-secondary);
}

.formats-header {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.formats-tagline {
    font-size: 1.25rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

.word-cloud-container {
    margin-top: 3.5rem;
    min-height: 600px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 2rem;
}

.word-cloud-item {
    display: inline-block;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0.5rem 1rem;
    border-radius: 0;
    text-decoration: none;
    user-select: none;
    line-height: 1.2;
    position: relative;
}

.word-cloud-item:hover {
    transform: scale(1.3) translateY(-5px);
    z-index: 10;
    filter: brightness(1.2);
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.3);
}

/* Alternatives Section */
.alternatives-section {
    background-color: var(--bg-primary);
}

.alternatives-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.alternative-card {
    background-color: var(--bg-secondary);
    border-radius: 0;
    padding: 2.5rem;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.alternative-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.alternative-card p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.alternative-link {
    display: inline-block;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: var(--shadow-md);
}

.alternative-link:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

@media (max-width: 968px) {
    .word-cloud-container {
        min-height: 500px;
        padding: 1.5rem;
    }
}

@media (max-width: 640px) {
    .formats-tagline {
        font-size: 1.1rem;
    }

    .word-cloud-container {
        margin-top: 2.5rem;
        min-height: 400px;
        padding: 1rem;
    }

    .word-cloud-item {
        padding: 0.35rem 0.75rem;
    }
}

/* Industry Section */
.industry-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.industry-content p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

/* Testimonials Section */
.testimonials-section {
    background-color: var(--bg-secondary);
}

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

.testimonial-card {
    background-color: var(--bg-primary);
    border-radius: 0;
    padding: 2rem;
    box-shadow: var(--shadow-lg);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.testimonial-content {
    margin-bottom: 1.5rem;
}

.testimonial-content p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    font-style: italic;
    line-height: 1.6;
}

.testimonial-author strong {
    display: block;
    color: var(--text-primary);
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.testimonial-author span {
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* Support Section */
.support-intro {
    text-align: center;
    font-size: 1.5rem;
    font-style: italic;
    color: var(--accent-primary);
    margin-bottom: 1rem;
}

.support-description {
    max-width: 800px;
    margin: 0 auto 3rem;
    text-align: center;
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

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

.support-card {
    background-color: var(--bg-secondary);
    border-radius: 0;
    padding: 2.5rem;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.support-card svg {
    margin-bottom: 1.5rem;
}

.support-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.support-card a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.support-card a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

/* Footer */
.footer {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer p {
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

.footer a {
    color: var(--text-tertiary);
    text-decoration: none;
    transition: color 0.2s ease;
}

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

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    color: var(--text-tertiary);
    transition: color 0.2s ease;
}

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

/* Animations */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive Design */
@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .hero-right {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .content-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .nav-links {
        gap: 1rem;
    }
    
    .nav-links a {
        font-size: 0.85rem;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero-title {
        font-size: 1.25rem;
    }
    
    .hero-subtitle {
        font-size: 1.125rem;
    }
    
    .tagline {
        font-size: 1rem;
    }
    
    .tagline-desc {
        font-size: 1rem;
    }
    
    .hero-download-btn {
        font-size: 1rem;
        padding: 0.875rem 1.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .section {
        padding: 3rem 0;
    }
    
    .top-bar .container {
        height: 60px;
    }
    
    .logo {
        font-size: 1.25rem;
    }
    
    .logo-img {
        height: 30px;
        width: auto;
    }
    
    .nav-links {
        display: none;
    }
}

/* Download Links Section */
.other-downloads {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
}

.other-downloads h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.other-download-link {
    color: var(--text-tertiary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.other-download-link:hover {
    color: var(--accent-primary);
    text-decoration: underline;
}

/* Hero image light/dark mode switching */
.hero-image-dark {
    display: none;
}

.hero-image-light {
    display: block;
}

@media (prefers-color-scheme: dark) {
    .hero-image-dark {
        display: block;
    }
    
    .hero-image-light {
        display: none;
    }
}

[data-theme="dark"] .hero-image-dark {
    display: block;
}

[data-theme="dark"] .hero-image-light {
    display: none;
}

[data-theme="light"] .hero-image-dark {
    display: none;
}

[data-theme="light"] .hero-image-light {
    display: block;
}
