/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background: #ffffff;
}

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

/* Accessibility: Skip to content link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #1a1a1a;
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
    font-weight: 600;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 6px;
    outline: 3px solid #3498DB;
    outline-offset: 2px;
}

/* Enhanced focus indicators */
a:focus,
button:focus,
[tabindex]:focus {
    outline: 3px solid #3498DB;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Remove default focus outline for mouse users */
a:focus:not(:focus-visible),
button:focus:not(:focus-visible),
[tabindex]:focus:not(:focus-visible) {
    outline: none;
}

/* Ensure focus indicators for keyboard users */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
    outline: 3px solid #3498DB;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Header */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
}

.logo-icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-image {
    height: 80px;
    width: auto;
    max-width: 400px;
}

/* Header logo specific sizing */
.header .logo-image {
    height: 64px;
}

.circle {
    width: 32px;
    height: 32px;
    background: #27AE60;
    border-radius: 50%;
    position: relative;
}

.crown {
    position: absolute;
    top: -8px;
    right: -4px;
    font-size: 16px;
    z-index: 2;
}

.logo-text {
    font-size: 20px;
    font-weight: 600;
    color: #1a1a1a;
    text-decoration: line-through;
    text-decoration-color: #E74C3C;
    text-decoration-thickness: 3px;
}

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

.nav-link {
    color: #666;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: #1a1a1a;
}

/* Hero Section */
.hero {
    padding: 120px 0 80px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

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

.hero-title {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 24px;
    color: #1a1a1a;
}

.accent {
    color: #27AE60;
}

.hero-subtitle {
    font-size: 20px;
    color: #666;
    margin-bottom: 32px;
    font-weight: 400;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.btn-primary {
    background: #27AE60;
    color: white;
    padding: 16px 32px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 18px;
    display: inline-block;
    transition: all 0.2s ease;
    align-self: flex-start;
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.3);
}

.btn-primary:hover {
    background: #219A52;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(39, 174, 96, 0.4);
}

.platforms {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.platform-text {
    color: #666;
    font-size: 14px;
}

.platform-icons {
    display: flex;
    gap: 12px;
}

.platform {
    background: rgba(255, 255, 255, 0.8);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

/* App Demo */
.app-demo {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 450px;
    margin: 0 auto;
}

.demo-container {
    background: #FFFEF7;
    border-radius: 12px;
    padding: 25px 30px 20px 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    position: relative;
    width: 100%;
    font-family: 'Kalam', cursive;
    
    /* Paper texture */
    background-image: 
        repeating-linear-gradient(
            transparent,
            transparent 25px,
            #E8E8F0 25px,
            #E8E8F0 26px
        );
}

/* Red margin line */
.demo-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50px;
    bottom: 0;
    width: 2px;
    background: #FF6B6B;
    opacity: 0.4;
    pointer-events: none;
}

.demo-header {
    text-align: center;
    margin-bottom: 20px;
}

.demo-title {
    font-family: 'Caveat', cursive;
    font-size: 20px;
    color: #2C3E50;
    font-weight: 600;
    margin: 0;
}

.demo-input-section {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.demo-input {
    flex: 1;
    padding: 6px 10px;
    border: none;
    border-bottom: 2px dashed #BDC3C7;
    background: transparent;
    font-family: 'Kalam', cursive;
    font-size: 14px;
    color: #2C3E50;
    transition: border-bottom-color 0.3s ease;
}

.demo-input:focus {
    outline: none;
    border-bottom-color: #3498DB;
    border-bottom-style: solid;
}

.demo-input::placeholder {
    color: #5D6D7E;
    font-style: italic;
}

.demo-add-btn {
    background: transparent;
    color: #3498DB;
    border: 2px dashed #3498DB;
    padding: 6px 12px;
    border-radius: 15px;
    font-family: 'Kalam', cursive;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.demo-add-btn:hover {
    background: #3498DB;
    color: white;
    transform: translateY(-1px);
}

.demo-task-list {
    list-style: none;
    padding: 0;
    margin: 0 0 15px 0;
    max-height: 180px;
    overflow-y: auto;
}

.demo-task {
    display: flex;
    align-items: flex-start;
    padding: 6px 0;
    position: relative;
    margin-bottom: 3px;
    transition: transform 0.2s ease;
}

.demo-checkbox {
    margin-right: 12px;
    margin-top: 3px;
    width: 14px;
    height: 14px;
    cursor: pointer;
    opacity: 0;
    position: absolute;
    z-index: 2;
}

.demo-checkbox + label::before {
    content: '';
    width: 14px;
    height: 14px;
    border: 2px solid #34495E;
    border-radius: 3px;
    margin-right: 12px;
    margin-top: 3px;
    display: inline-block;
    background: #FFFEF7;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    vertical-align: top;
}

.demo-checkbox:checked + label::before {
    background: #27AE60;
    border-color: #27AE60;
    transform: scale(1.1);
}

.demo-checkbox:checked + label::after {
    content: '✓';
    position: absolute;
    left: 4px;
    top: 1px;
    color: white;
    font-weight: bold;
    font-size: 10px;
    pointer-events: none;
}

.demo-task-text {
    flex: 1;
    font-family: 'Kalam', cursive;
    font-size: 14px;
    color: #2C3E50;
    line-height: 1.3;
    position: relative;
    padding-top: 1px;
    padding-left: 26px;
    cursor: pointer;
    transition: color 0.3s ease;
    word-wrap: break-word;
}

.demo-task-text span {
    position: relative;
    display: inline-block;
}

.demo-delete {
    background: none;
    border: none;
    color: #E74C3C;
    cursor: pointer;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.2s ease;
    padding: 2px 6px;
    margin-left: 8px;
    border-radius: 3px;
}

.demo-task:hover .demo-delete {
    opacity: 1;
}

.demo-delete:hover {
    transform: scale(1.2);
    background: rgba(231, 76, 60, 0.1);
}

/* Completed task styling */
.demo-task.completed .demo-task-text {
    color: #7F8C8D;
}

.demo-task.completed .demo-task-text span::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: calc(100% + 4px);
    height: 2px;
    background: linear-gradient(
        90deg,
        #E74C3C 0%,
        #C0392B 50%,
        #E74C3C 100%
    );
    border-radius: 1px;
    opacity: 0.9;
    z-index: 1;
    transform: translateY(-50%) rotate(-1deg);
}

.demo-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: #7F8C8D;
    margin-top: 10px;
}

.demo-count {
    font-weight: 500;
}

.demo-clear {
    background: none;
    border: 1px dashed #BDC3C7;
    color: #7F8C8D;
    padding: 3px 6px;
    border-radius: 8px;
    font-family: 'Kalam', cursive;
    font-size: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.demo-clear:hover:not(:disabled) {
    border-color: #E74C3C;
    color: #E74C3C;
}

.demo-clear:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Animation for new tasks */
.demo-task.adding {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Animation for completing tasks */
.demo-task.celebrating {
    animation: celebrate 0.15s ease-out;
}

@keyframes celebrate {
    0% { transform: scale(1); }
    50% { transform: scale(1.01); }
    100% { transform: scale(1); }
}

/* Features Section */
.features {
    padding: 100px 0;
    background: white;
}

.section-title {
    text-align: center;
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 60px;
    color: #1a1a1a;
}

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

.feature {
    text-align: center;
    padding: 32px 24px;
    border-radius: 16px;
    background: #f8f9fa;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.feature-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 16px;
    color: #1a1a1a;
}

.feature-description {
    color: #666;
    font-size: 16px;
    line-height: 1.6;
}

/* Download Section */
.download {
    padding: 100px 0;
    background: linear-gradient(135deg, #27AE60 0%, #219A52 100%);
    color: white;
}

.download-content {
    text-align: center;
}

.download-title {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 20px;
}

.download-subtitle {
    font-size: 20px;
    margin-bottom: 48px;
    opacity: 0.9;
}

.download-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.download-btn {
    display: flex;
    align-items: center;
    gap: 16px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 20px 24px;
    text-decoration: none;
    color: white;
    transition: all 0.3s ease;
}

.download-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.download-icon {
    font-size: 32px;
}

.download-platform {
    font-weight: 600;
    font-size: 18px;
}

.download-version {
    font-size: 14px;
    opacity: 0.8;
}

.download-note {
    opacity: 0.8;
    font-size: 16px;
}

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

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

.footer-logo .logo-text {
    color: white;
}

.footer-text {
    opacity: 0.7;
    text-align: right;
}

.footer-text p {
    margin: 0;
}

.footer-text p:first-child {
    margin-bottom: 4px;
}

/* Footer logo specific sizing */
.footer .logo-image {
    height: 48px;
}

/* Footer link styling */
.footer-link {
    color: #60a5fa;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: #93c5fd;
    text-decoration: underline;
}

.footer-link:focus {
    outline: 2px solid #60a5fa;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
    
    .hero-text {
        order: 2;
    }
    
    .hero-image {
        order: 1;
    }
    
    .nav {
        display: none;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .download-buttons {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .footer-text {
        text-align: center;
    }
    
    .app-demo {
        max-width: 100%;
    }
    
    .demo-container {
        margin: 0 10px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .section-title {
        font-size: 32px;
    }
    
    .download-title {
        font-size: 32px;
    }
} 