:root {
    --primary-color: #3B82F6;
    --secondary-color: #22D3EE;
    --accent-color: #10B981;
    --dark-color: #1f2937;
    --light-color: #f3f4f6;
    --text-color: #374151;
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

* {
    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: var(--text-color);
    background: #ffffff;
}

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

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark-color);
    text-decoration: none;
}

.nav-brand a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: inherit;
    text-decoration: none;
}

.logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--dark-color);
    transition: var(--transition);
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

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

.nav-link {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

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

.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
}

.nav-cta {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white !important;
    padding: 8px 20px;
    border-radius: 20px;
}

.nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(16, 185, 129, 0.3);
}

/* Hero Section */
.hero {
    margin-top: 80px;
    padding: 80px 20px;
    min-height: 600px;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #dbeafe 0%, #cffafe 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    top: -250px;
    right: -250px;
}

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

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-color);
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.btn-primary, .btn-secondary {
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.btn-secondary {
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

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

.btn-large {
    padding: 15px 40px;
    font-size: 1.1rem;
}

.apple-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInUp 0.8s ease 0.6s both;
}

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

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

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

.demo-app {
    width: 90%;
    text-align: center;
}

.demo-header {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 2rem;
}

.demo-stat {
    display: flex;
    flex-direction: column;
    margin-bottom: 2rem;
}

.demo-number {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.demo-label {
    color: var(--text-color);
    font-size: 0.9rem;
}

.demo-macros {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.macro-item {
    flex: 1;
    text-align: center;
}

.macro-bar {
    height: 80px;
    border-radius: 10px;
    margin-bottom: 5px;
}

.macro-bar.protein {
    background: linear-gradient(135deg, #3B82F6, #60A5FA);
}

.macro-bar.carbs {
    background: linear-gradient(135deg, #22D3EE, #67E8F9);
}

.macro-bar.fats {
    background: linear-gradient(135deg, #10B981, #34D399);
}

.macro-item span {
    font-size: 0.8rem;
    color: var(--text-color);
}

/* Features Section */
.features {
    padding: 80px 20px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.section-subtitle {
    text-align: center;
    color: var(--text-color);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

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

.feature-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: var(--transition);
    border: 1px solid #e5e7eb;
}

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

.feature-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.feature-icon svg {
    width: 30px;
    height: 30px;
    fill: white;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.feature-card p {
    color: var(--text-color);
    line-height: 1.6;
}

/* Benefits Section */
.benefits {
    padding: 80px 20px;
    background: linear-gradient(135deg, #dbeafe 0%, #cffafe 100%);
}

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

.benefit-item {
    text-align: center;
}

.benefit-number {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.benefit-item h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.benefit-item p {
    color: var(--text-color);
}

/* App Showcase Section */
.app-showcase {
    padding: 80px 20px;
    background: #ffffff;
}

.showcase-carousel {
    max-width: 400px;
    margin: 0 auto 3rem;
    display: block;
}

.carousel-container {
    position: relative;
    background: #000;
    border-radius: 40px;
    padding: 10px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.carousel-track {
    position: relative;
    height: 700px;
    border-radius: 30px;
    overflow: hidden;
    background: white;
}

.carousel-slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 30px;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    transition: var(--transition);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.carousel-btn:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.carousel-btn svg {
    width: 24px;
    height: 24px;
    fill: var(--dark-color);
}

.carousel-prev {
    left: -20px;
}

.carousel-next {
    right: -20px;
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: #d1d5db;
    cursor: pointer;
    transition: var(--transition);
}

.carousel-dot.active {
    width: 24px;
    border-radius: 4px;
    background: var(--primary-color);
}

.showcase-grid {
    display: none;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.showcase-item {
    background: #000;
    border-radius: 20px;
    padding: 5px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.showcase-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.showcase-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 15px;
}

@media (min-width: 1024px) {
    .showcase-carousel {
        display: none;
    }

    .showcase-grid {
        display: grid;
    }
}

/* CTA Section */
.cta {
    padding: 100px 20px;
    text-align: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.cta-buttons {
    margin-bottom: 1rem;
}

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

.cta .btn-primary:hover {
    background: var(--light-color);
}

.cta-note {
    font-size: 0.9rem;
    opacity: 0.8;
}

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

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

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
}

.footer-links {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
    transition: var(--transition);
}

.footer-links a:hover {
    opacity: 1;
}

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

/* Legal Pages */
.legal-container {
    max-width: 1200px;
    margin: 100px auto 50px;
    display: flex;
    gap: 2rem;
    padding: 0 20px;
}

.toc-sidebar {
    flex: 0 0 250px;
    position: sticky;
    top: 100px;
    height: fit-content;
}

.toc-sidebar h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.toc-list {
    list-style: none;
}

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

.toc-list a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.95rem;
    transition: var(--transition);
    display: block;
    padding: 5px 0;
}

.toc-list a:hover {
    color: var(--primary-color);
    padding-left: 10px;
}

.legal-content {
    flex: 1;
    max-width: 800px;
}

.legal-content h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.legal-content h2 {
    font-size: 1.8rem;
    margin: 2rem 0 1rem;
    color: var(--dark-color);
    padding-top: 20px;
}

.legal-content h3 {
    font-size: 1.3rem;
    margin: 1.5rem 0 1rem;
    color: var(--dark-color);
}

.legal-content h4 {
    font-size: 1.1rem;
    margin: 1rem 0 0.5rem;
    color: var(--dark-color);
}

.legal-content p {
    margin-bottom: 1rem;
    line-height: 1.8;
}

.legal-content ul, .legal-content ol {
    margin: 1rem 0 1.5rem 2rem;
}

.legal-content li {
    margin-bottom: 0.5rem;
    line-height: 1.8;
}

.legal-date {
    color: var(--text-color);
    font-style: italic;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--light-color);
}

.highlight-box {
    background: #dbeafe;
    border-left: 4px solid var(--primary-color);
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 8px;
}

.highlight-box.warning {
    background: #fef3c7;
    border-left-color: #f59e0b;
}

.highlight-box.success {
    background: #dbeafe;
    border-left-color: var(--primary-color);
}

.contact-info {
    background: var(--light-color);
    padding: 1.5rem;
    border-radius: 8px;
    margin: 1rem 0;
}

.legal-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid var(--light-color);
    font-style: italic;
    color: var(--text-color);
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        right: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: white;
        flex-direction: column;
        padding: 2rem;
        transition: var(--transition);
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    }

    .nav-menu.active {
        right: 0;
    }

    .hero {
        flex-direction: column;
        text-align: center;
        padding: 40px 20px;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-image {
        margin-top: 3rem;
    }

    .phone-mockup {
        width: 250px;
        height: 500px;
    }

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

    .benefits-grid {
        grid-template-columns: 1fr;
    }

    .legal-container {
        flex-direction: column;
    }

    .toc-sidebar {
        position: static;
        flex: none;
        margin-bottom: 2rem;
        padding: 1.5rem;
        background: var(--light-color);
        border-radius: 8px;
    }

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

    .footer-links {
        justify-content: center;
    }

    .cta-title {
        font-size: 2rem;
    }

    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .btn-primary, .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }
}