/**
 * Landing Page CSS
 * Styles specific to the landing page
 */

/* Hero Section */
.hero,
.hero-section {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-700) 100%);
    color: var(--color-text-on-primary);
    padding: 8rem 0 6rem;
    position: relative;
    overflow: hidden;
    transition: background 0.2s ease;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

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

.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.video-container #youtubePlayer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 20px;
}

@media (max-width: 992px) {
    .hero .container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .video-container {
        max-width: 800px;
        margin: 0 auto;
    }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(45deg, #ffffff, #f0f9ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    line-height: 1.6;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 4rem;
    flex-wrap: wrap;
}

.hero-stat {
    text-align: center;
}

.hero-stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.hero-stat-label {
    font-size: 0.875rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Features Section */
.features,
.features-section {
    padding: 6rem 0 3rem;
    background: var(--color-surface);
}

.features-header,
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.features-title,
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.features-subtitle,
.section-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

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

.feature-card {
    background: var(--color-surface-elevated);
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid var(--color-border);
    text-align: center;
    cursor: pointer;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
    background: var(--color-surface-hover, var(--color-surface-elevated));
}

.feature-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.5rem;
    color: var(--color-text-on-primary);
    transition: transform 0.3s ease;
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--color-text) !important;
    transition: color 0.3s ease;
}

/* Ensure feature titles have proper contrast in both themes */
.feature-card .feature-title {
    color: var(--color-text) !important;
}

.feature-description {
    color: var(--color-text-secondary);
    line-height: 1.6;
}

/* How It Works Section */
.how-it-works,
.how-it-works-section {
    padding: 6rem 0;
    background: var(--color-bg);
}

.how-it-works-header {
    text-align: center;
    margin-bottom: 4rem;
}

.how-it-works-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.how-it-works-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
    position: relative;
}

.step {
    text-align: center;
    position: relative;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--color-primary);
    color: var(--color-text-on-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1.5rem;
    position: relative;
    z-index: 2;
}

.step-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.step-description {
    color: var(--color-text-secondary);
    line-height: 1.6;
}

/* CTA Section */
.cta,
.cta-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: var(--color-text-on-primary);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.1)"/></svg>');
    opacity: 0.5;
}

.cta-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    margin: 0 auto;
}

.cta-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.cta-subtitle {
    font-size: 1.125rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    line-height: 1.6;
}

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

/* Timer Demo Section */
.timer-demo {
    padding: 6rem 0;
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
}

.timer-demo-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-top: 3rem;
}

.timer-demo-info h3 {
    font-size: 2rem;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timer-features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
}

.timer-features li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timer-features li:before {
    content: "✅";
    color: var(--color-success);
    font-weight: bold;
}

.timer-demo-widget {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}

.timer-demo-widget .global-pomodoro-widget {
    max-width: 400px;
    width: 100%;
}

.demo-cta {
    margin-top: 2rem;
}

.demo-note {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    font-style: italic;
    text-align: center;
}

@media (max-width: 768px) {
    .timer-demo-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .timer-demo-info h3 {
        justify-content: center;
    }
}

/* Contact Section */
.contact {
    padding: 6rem 0;
    background: var(--color-background);
}

.contact-content {
    margin: 0 auto;
}

.contact-header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.contact-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.contact-form-container {
    background: var(--color-background);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
}

.contact-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.contact-form .form-group {
    margin-bottom: 1.5rem;
}

.contact-form .form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--color-text);
}

.contact-form .form-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-background);
    color: var(--color-text);
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form .form-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-alpha);
}

.contact-form textarea.form-input {
    resize: vertical;
    min-height: 120px;
}

.contact-form .form-actions {
    text-align: center;
    margin-top: 2rem;
}

.contact-form .btn {
    min-width: 150px;
}

/* Newsletter Section */
.newsletter-section {
    padding: 4rem 0;
    background: var(--color-surface);
    text-align: center;
}

.newsletter-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

.newsletter-subtitle {
    color: var(--color-text-secondary);
    margin-bottom: 2rem;
}

.newsletter-form {
    display: flex;
    max-width: 400px;
    margin: 0 auto;
    gap: 0.5rem;
}

.newsletter-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    background: var(--color-surface-elevated);
    color: var(--color-text);
}

.newsletter-input:focus {
    outline: none;
    border-color: var(--color-primary);
}

.newsletter-button {
    padding: 0.75rem 1.5rem;
    background: var(--color-primary);
    color: var(--color-text-on-primary);
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.newsletter-button:hover {
    background: var(--color-primary-dark);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.125rem;
    }
    
    .hero-cta {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-stats {
        gap: 2rem;
    }
    
    .features-title,
    .how-it-works-title,
    .cta-title {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .steps-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .contact-title {
        font-size: 2rem;
    }

    .contact-form-container {
        padding: 1.5rem;
    }

    .contact-form .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .newsletter-form {
        flex-direction: column;
        max-width: 300px;
    }

    .newsletter-input,
    .newsletter-button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .hero-section {
        padding: 6rem 0 4rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .features-section,
    .how-it-works-section,
    .cta-section {
        padding: 4rem 0;
    }
    
    .features-title,
    .how-it-works-title,
    .cta-title {
        font-size: 1.75rem;
    }
    
    .feature-card {
        padding: 1.25rem;
    }
    
    .feature-icon {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
    }
    
    .step-number {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
    }
}

/* Animation Classes */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.animate-on-scroll.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

.fade-in-left {
    animation: fadeInLeft 0.6s ease-out forwards;
}

.fade-in-right {
    animation: fadeInRight 0.6s ease-out forwards;
}

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

@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);
    }
}

/* Stagger delays for animations */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }

/* About Section */
.about {
    padding: 5rem 0;
    background: var(--color-surface);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    margin-top: 2rem;
    color: var(--color-text);
}

.about-text h3:first-child {
    margin-top: 0;
}

.about-text p {
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.about-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.about-list li {
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 0.75rem;
    padding-left: 1.5rem;
    position: relative;
}

.about-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--color-primary);
    font-weight: bold;
}

/* Detailed About Section */
.detailed-about {
    padding: 6rem 0;
    background: var(--color-bg);
    position: relative;
}

.detailed-about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.03) 0%, rgba(147, 51, 234, 0.03) 100%);
    pointer-events: none;
}

.detailed-about-content {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.about-section {
    background: var(--color-surface);
    padding: 3rem;
    margin-bottom: 2rem;
    border-radius: 16px;
    border: 1px solid var(--color-border);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.about-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border-color: var(--color-primary-alpha);
}

.about-section h3 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--color-text);
    position: relative;
    padding-bottom: 0.75rem;
}

.about-section h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
    border-radius: 2px;
}

.about-section p {
    color: var(--color-text-secondary);
    line-height: 1.7;
    margin-bottom: 1.25rem;
    font-size: 1.0625rem;
}

.about-section p:last-child {
    margin-bottom: 0;
}

.about-section ul {
    margin: 1.5rem 0;
    padding-left: 1.5rem;
}

.about-section li {
    color: var(--color-text-secondary);
    line-height: 1.7;
    margin-bottom: 0.75rem;
    position: relative;
    padding-left: 1rem;
}

.about-section li::before {
    content: '→';
    position: absolute;
    left: -1.5rem;
    color: var(--color-primary);
    font-weight: bold;
    font-size: 0.875rem;
}

.about-section ol {
    counter-reset: section-counter;
    margin: 1.5rem 0;
    padding-left: 1.5rem;
}

.about-section ol li {
    counter-increment: section-counter;
    color: var(--color-text-secondary);
    line-height: 1.7;
    margin-bottom: 1rem;
    position: relative;
    padding-left: 2rem;
}

.about-section ol li::before {
    content: counter(section-counter) '.';
    position: absolute;
    left: -1.5rem;
    top: 0;
    color: var(--color-primary);
    font-weight: 700;
    font-size: 1rem;
    background: var(--color-surface);
    padding: 0.25rem 0.5rem;
    border-radius: 50%;
    border: 2px solid var(--color-primary);
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

.about-section strong {
    color: var(--color-text);
    font-weight: 600;
}

.cta-text {
    text-align: center;
    margin-top: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    border-radius: 12px;
    color: var(--color-text-on-primary);
}

.cta-text strong {
    display: block;
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: inherit;
}

.cta-text p {
    margin-bottom: 1.5rem;
    opacity: 0.9;
    color: inherit;
}

.cta-text .btn {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    font-weight: 600;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
}

.cta-text .btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-1px);
}

/* Footer */
.footer {
    background-color: var(--color-surface);
    border-top: 1px solid var(--color-border);
    padding: 3rem 0 1rem;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

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

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-logo {
    width: 120px;
    height: auto;
}

[data-theme="dark"] .footer-logo {
    filter: invert(1);
}

[data-theme="dark"] .brand-logo {
    filter: invert(1);
}


.footer-description {
    color: var(--color-text-secondary);
    line-height: 1.6;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.footer-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--color-text);
}

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

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

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

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

.footer-bottom {
    border-top: 1px solid var(--color-border);
    padding-top: 1rem;
}

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

.footer-version-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.footer-version {
    background: var(--color-primary);
    color: var(--color-text-on-primary);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-weight: 500;
    font-size: 0.75rem;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
}

.footer-copyright {
    color: var(--color-text-muted);
    margin: 0;
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    .about {
        padding: 3rem 0;
    }

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

    /* Detailed About Section Mobile */
    .detailed-about {
        padding: 4rem 0;
    }

    .about-section {
        padding: 2rem;
        margin-bottom: 1.5rem;
    }

    .about-section h3 {
        font-size: 1.5rem;
        margin-bottom: 1.25rem;
    }

    .about-section h3::after {
        width: 50px;
        height: 2px;
    }

    .about-section p {
        font-size: 1rem;
        line-height: 1.6;
    }

    .about-section ol {
        padding-left: 1rem;
    }

    .about-section ol li {
        padding-left: 1.5rem;
        margin-bottom: 0.75rem;
    }

    .about-section ol li::before {
        left: -1rem;
        width: 1.25rem;
        height: 1.25rem;
        font-size: 0.875rem;
    }

    .cta-text {
        padding: 1.5rem;
        margin-top: 1.5rem;
    }

    .cta-text strong {
        font-size: 1.125rem;
    }

    .cta-text .btn {
        padding: 0.625rem 1.5rem;
        font-size: 0.875rem;
    }

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

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

    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }
}
