/* 
* WriteFlow Landing Page Styles
* Author: Manus AI
* Version: 1.0
*/

/* ===== Base Styles ===== */
:root {
    --primary-color: #4a6bff;
    --primary-dark: #3a56cc;
    --secondary-color: #ff6b4a;
    --text-color: #333333;
    --text-light: #666666;
    --bg-color: #ffffff;
    --bg-light: #f8f9fa;
    --bg-dark: #212529;
    --border-color: #e9ecef;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --border-radius: 8px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Cairo', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-color);
    direction: ltr; /* Changed from rtl to ltr */
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

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

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--text-color);
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.section-header p {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    outline: none;
    text-align: center;
}

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

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

.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-lg {
    padding: 14px 28px;
    font-size: 1.1rem;
}

.btn i {
    margin-right: 8px; /* Changed from margin-left */
    margin-left: 0; /* Added to reset */
}

.btn-download {
    background-color: var(--bg-dark);
    color: white;
    padding: 10px 20px;
    border-radius: var(--border-radius);
    display: inline-flex;
    align-items: center;
    transition: var(--transition);
}

.btn-download:hover {
    background-color: #000;
    color: white;
    transform: translateY(-3px);
}

.btn-download i {
    font-size: 2rem;
    margin-right: 15px; /* Changed from margin-left */
    margin-left: 0; /* Added to reset */
}

.btn-download .btn-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.2;
}

.btn-download .btn-text span {
    font-size: 0.8rem;
}

.btn-download .btn-text strong {
    font-size: 1.2rem;
}

/* ===== Header ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

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

.logo img {
    margin-right: 10px; /* Changed from margin-left */
    margin-left: 0; /* Added to reset */
}

.logo span {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
}

.nav-links li {
    margin: 0 15px;
}

.nav-links a {
    color: var(--text-color);
    font-weight: 600;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

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

.nav-links a:hover::after {
    width: 100%;
}

.download-btn-small {
    display: none;
}

.menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

/* ===== Hero Section ===== */
.hero {
    padding: 150px 0 100px;
    background: linear-gradient(135deg, #f5f7ff 0%, #e8ecff 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50px;
    left: -50px; /* Changed from right */
    right: auto; /* Added to reset */
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background-color: rgba(74, 107, 255, 0.1);
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -100px;
    right: -100px; /* Changed from left */
    left: auto; /* Added to reset */
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background-color: rgba(255, 107, 74, 0.1);
}

.hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.hero-content h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    color: var(--text-color);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: var(--text-light);
}

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

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.app-screenshot {
    max-width: 300px;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    border: 10px solid white;
    transform: rotate(3deg);
}

/* ===== Features Section ===== */
.features {
    padding: 100px 0;
    background-color: var(--bg-color);
}

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

.feature-card {
    background-color: var(--bg-light);
    border-radius: var(--border-radius);
    padding: 30px;
    text-align: center;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

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

.feature-icon {
    width: 70px;
    height: 70px;
    background-color: rgba(74, 107, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.feature-icon i {
    font-size: 1.8rem;
    color: var(--primary-color);
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--text-color);
}

.feature-card p {
    color: var(--text-light);
}

/* ===== Screenshots Section ===== */
.screenshots {
    padding: 100px 0;
    background-color: var(--bg-light);
}

.screenshots-slider {
    display: flex;
    overflow: hidden;
    width: 100%;
    position: relative;
    justify-content: center;
    align-items: center;
    min-height: 400px;
}

.screenshot {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s;
    z-index: 1;
}

.screenshot.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 2;
}

.screenshot-img {
    max-width: 100%;
    max-height: 90%;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.slider-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
}

.prev-btn, .next-btn {
    background-color: var(--primary-color);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.prev-btn:hover, .next-btn:hover {
    background-color: var(--primary-dark);
}

.slider-dots {
    display: flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #ccc;
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background-color: var(--primary-color);
    transform: scale(1.2);
}

/* ===== Languages Section ===== */
.languages {
    padding: 100px 0;
    background-color: var(--bg-color);
}

.languages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
}

.language-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
    background-color: var(--bg-light);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.language-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.language-flag {
    font-size: 2rem;
    margin-bottom: 10px;
}

.language-item span {
    font-weight: 600;
    text-align: center;
}

/* ===== Writing Modes Section ===== */
.writing-modes {
    padding: 100px 0;
    background-color: var(--bg-light);
}

.modes-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.mode-card {
    background-color: var(--bg-color);
    border-radius: var(--border-radius);
    padding: 20px;
    text-align: center;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.mode-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.mode-icon {
    width: 50px;
    height: 50px;
    background-color: rgba(74, 107, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
}

.mode-icon i {
    font-size: 1.3rem;
    color: var(--primary-color);
}

.mode-card h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--text-color);
}

.mode-card p {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* ===== Testimonials Section ===== */
.testimonials {
    padding: 100px 0;
    background-color: var(--bg-color);
}

.testimonials-slider {
    display: flex;
    overflow: hidden;
    width: 100%;
    position: relative;
    justify-content: center;
    align-items: center;
    min-height: 350px;
}

.testimonial {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s;
    z-index: 1;
    padding: 0 20px;
}

.testimonial.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 2;
}

.testimonial-content {
    background-color: var(--bg-light);
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--box-shadow);
    max-width: 600px;
    position: relative;
}

.testimonial-content::before {
    content: '\201C';
    position: absolute;
    top: 20px;
    left: 20px; /* Changed from right */
    right: auto; /* Added to reset */
    font-size: 4rem;
    color: rgba(74, 107, 255, 0.1);
    font-family: serif;
    line-height: 1;
}

.rating {
    margin-bottom: 15px;
}

.rating i {
    color: #ffc107;
    margin-right: 2px; /* Changed from margin-left */
    margin-left: 0; /* Added to reset */
}

.testimonial-content p {
    font-style: italic;
    margin-bottom: 20px;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
}

.testimonial-author h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

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

.testimonial-controls {
    margin-top: 20px;
}

/* ===== FAQ Section ===== */
.faq {
    padding: 100px 0;
    background-color: var(--bg-light);
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 20px;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    background-color: var(--bg-color);
}

.faq-question {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: var(--transition);
}

.faq-question:hover {
    background-color: rgba(74, 107, 255, 0.05);
}

.faq-question h3 {
    font-size: 1.1rem;
    color: var(--text-color);
}

.faq-toggle {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: var(--transition);
}

.faq-item.active .faq-answer {
    padding: 0 20px 20px;
    max-height: 1000px;
}

.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

/* ===== Download Section ===== */
.download {
    padding: 100px 0;
    background: linear-gradient(135deg, #f5f7ff 0%, #e8ecff 100%);
    color: var(--text-color);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.download::before {
    content: '';
    position: absolute;
    top: -50px;
    left: -50px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background-color: rgba(74, 107, 255, 0.1);
    z-index: 0;
}

.download::after {
    content: '';
    position: absolute;
    bottom: -100px;
    right: -100px;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background-color: rgba(255, 107, 74, 0.1);
    z-index: 0;
}

.download > .container, .download-buttons, .qr-code {
    position: relative;
    z-index: 1;
}

.download-content h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.download-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.download-buttons {
    margin-bottom: 30px;
}

.qr-code {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.qr-code img {
    margin-bottom: 10px;
    background-color: white;
    padding: 10px;
    border-radius: var(--border-radius);
}

.qr-code p {
    font-size: 0.9rem;
    margin-bottom: 0;
}

/* ===== Footer ===== */
.footer {
    background-color: var(--bg-dark);
    color: white;
    padding: 70px 0 20px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 50px;
}

.footer-logo {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.footer-logo img {
    margin-right: 10px; /* Changed from margin-left */
    margin-left: 0; /* Added to reset */
}

.footer-logo span {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
}

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

.footer-column h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    position: relative;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0; /* Changed from right */
    right: auto; /* Added to reset */
    width: 40px;
    height: 3px;
    background-color: var(--primary-color);
}

.footer-column ul li {
    margin-bottom: 10px;
}

.footer-column ul li a {
    color: #adb5bd;
    transition: var(--transition);
}

.footer-column ul li a:hover {
    color: white;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: #adb5bd;
    font-size: 0.9rem;
}

/* ===== Responsive Styles ===== */
@media (max-width: 992px) {
    .hero .container {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-content {
        margin-bottom: 50px;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .features-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .footer-content {
        flex-direction: column;
    }
    
    .footer-links {
        margin-top: 30px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 70px;
        left: -100%; /* Changed from right */
        right: auto; /* Added to reset */
        width: 100%;
        height: calc(100vh - 70px);
        background-color: var(--bg-color);
        flex-direction: column;
        align-items: center;
        padding: 50px 0;
        transition: var(--transition);
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    }
    
    .nav-links.active {
        left: 0; /* Changed from right */
        right: auto; /* Added to reset */
    }
    
    .nav-links li {
        margin: 15px 0;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .download-btn-small {
        display: block;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-content h2 {
        font-size: 1.5rem;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .modes-container {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    
    .footer-links {
        flex-direction: column;
        gap: 30px;
    }
}

@media (max-width: 576px) {
    .hero-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-lg {
        width: 100%;
    }
    
    .download-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-download {
        margin-bottom: 15px;
    }
}

