:root {
    --primary-color: #16a34a; /* Leaf/Emerald Green from Logo */
    --primary-dark: #0d5a2b; /* Dark Forest Green outline from Logo */
    --primary-light: #eafaf1; /* Soft Mint Green */
    --secondary-color: #f8fafc;
    --text-main: #0f172a;
    --text-light: #64748b;
    --bg-color: #ffffff;
    --bg-alt: #f1f5f9;
    --success: #10b981;
    --danger: #ef4444;
    --border-color: #e2e8f0;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

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

html, body {
    max-width: 100%;
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
}

h1, h2, h3, h4 {
    font-family: 'Outfit', sans-serif;
    color: var(--text-main);
}

a {
    text-decoration: none;
    color: inherit;
}

.text-primary { color: var(--primary-color); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.bg-success { background-color: rgba(16, 185, 129, 0.1); color: var(--success); }
.bg-danger { background-color: rgba(239, 68, 68, 0.1); color: var(--danger); }

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

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 4px 14px rgba(22, 163, 74, 0.3);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(22, 163, 74, 0.4);
}

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

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

.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
    border-radius: 12px;
}

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

/* Navbar */
.navbar {
    padding: 20px 0;
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

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

.logo {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    font-weight: 500;
}

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

.btn-login {
    background: var(--bg-alt);
    padding: 8px 20px;
    border-radius: 6px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-login:hover {
    background: var(--border-color);
}

/* Hero Section */
.hero {
    padding: 160px 0 100px 0;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    overflow: hidden;
}

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

.badge {
    display: inline-block;
    padding: 6px 16px;
    background: var(--primary-light);
    color: var(--primary-dark);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.hero-content h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero-content .highlight {
    background: linear-gradient(120deg, var(--primary-color), #10b981);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

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

.hero-cta {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
}

.guarantee {
    font-size: 0.85rem !important;
    color: var(--text-light) !important;
    margin-bottom: 0 !important;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Mockup Visual */
.hero-visual {
    position: relative;
    perspective: 1000px;
}

.dashboard-mockup {
    background: white;
    border-radius: 16px;
    box-shadow: var(--shadow-lg), 0 0 0 1px var(--border-color);
    overflow: hidden;
    transform: rotateY(-15deg) rotateX(5deg);
    transition: transform 0.5s ease;
    width: 130%; /* Make it intentionally large and clipped */
}

.dashboard-mockup:hover {
    transform: rotateY(-5deg) rotateX(2deg);
}

.mockup-header {
    background: var(--bg-alt);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

.dots {
    display: flex;
    gap: 6px;
}

.dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #cbd5e1;
}

.dots span:nth-child(1) { background: #ff5f56; }
.dots span:nth-child(2) { background: #ffbd2e; }
.dots span:nth-child(3) { background: #27c93f; }

.mockup-title {
    margin: 0 auto;
    font-size: 0.75rem;
    color: var(--text-light);
    background: white;
    padding: 4px 100px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
}

.mockup-body {
    height: 400px;
    position: relative;
    background: var(--secondary-color);
    padding: 40px;
}

/* Floating Panels */
.panel {
    background: white;
    padding: 16px;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    position: absolute;
    display: flex;
    align-items: center;
    gap: 16px;
    animation-timing-function: ease-in-out;
    animation-iteration-count: infinite;
    border: 1px solid rgba(0,0,0,0.02);
}

.panel-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.panel-info {
    display: flex;
    flex-direction: column;
}

.panel-label {
    font-size: 0.8rem;
    color: var(--text-light);
    font-weight: 500;
}

.panel-value {
    font-size: 1.25rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
}

/* Float Animations */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

@keyframes float-reverse {
    0% { transform: translateY(0px); }
    50% { transform: translateY(15px); }
    100% { transform: translateY(0px); }
}

.float-1 { top: 40px; left: 40px; animation: float 6s infinite; }
.float-2 { top: 140px; left: 120px; animation: float-reverse 7s infinite; }

.chart-panel {
    top: 60px;
    right: 40px;
    flex-direction: column;
    align-items: flex-start;
    animation: float 8s infinite;
}

.chart-panel h4 {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 12px;
}

.chart-bars {
    display: flex;
    gap: 12px;
    height: 60px;
    align-items: flex-end;
}

.bar-group {
    display: flex;
    gap: 4px;
    align-items: flex-end;
    height: 100%;
}

.bar {
    width: 8px;
    border-radius: 4px;
}

.bar-income { background: var(--success); }
.bar-expense { background: var(--danger); opacity: 0.6; }

.ai-panel {
    bottom: 40px;
    left: 80px;
    background: linear-gradient(135deg, var(--primary-color), #10b981);
    color: white;
    padding: 12px 20px;
    font-size: 0.9rem;
    border: none;
    animation: float-reverse 6.5s infinite;
}

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

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.section-title p {
    color: var(--text-light);
    font-size: 1.1rem;
}

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

.feature-card {
    background: white;
    padding: 30px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

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

.feature-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-light);
    color: var(--primary-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.feature-card h3 {
    margin-bottom: 12px;
    font-size: 1.2rem;
}

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

/* Pricing */
.pricing {
    padding: 100px 0;
    background: var(--bg-alt);
}

/* Period Selector Segmented Control */
.period-selector-container {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    width: 100%;
    padding: 0 16px;
}

.period-selector {
    display: inline-flex;
    background: var(--bg-color);
    padding: 4px;
    border-radius: 9999px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    max-width: 100%;
}

.period-btn {
    border: none;
    background: transparent;
    padding: 10px 20px;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-light);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    min-height: 44px; /* Ensure proper mobile touch target */
}

.period-btn:hover {
    color: var(--text-main);
}

.period-btn.active {
    background: var(--primary-color) !important;
    color: white !important;
}

.discount-tag {
    background: var(--primary-light);
    color: var(--primary-color);
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 9999px;
    font-weight: 700;
}

.period-btn.active .discount-tag {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    max-width: 900px;
    margin: 0 auto;
}

.pricing-card {
    background: white;
    padding: 40px;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    position: relative;
    display: flex;
    flex-direction: column;
}

.pricing-card.popular {
    border: 2px solid var(--primary-color);
    box-shadow: var(--shadow-lg);
    transform: scale(1.05);
}

.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: white;
    padding: 4px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
}

.pricing-card h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.price {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
}

.currency {
    font-size: 1.2rem;
    font-weight: 600;
    margin-top: 8px;
}

.amount {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
    font-family: 'Outfit', sans-serif;
}

.period {
    color: var(--text-light);
    align-self: flex-end;
    margin-bottom: 8px;
}

.plan-features {
    list-style: none;
    margin-bottom: 40px;
    flex-grow: 1;
}

.plan-features li {
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-main);
}

.plan-features li i.fa-check { color: var(--success); }
.plan-features li.disabled { color: var(--text-light); opacity: 0.6; }
.plan-features li.disabled i { color: var(--text-light); }

.pricing-card .btn {
    width: 100%;
}

/* Footer */
footer {
    background: white;
    padding: 60px 0 20px 0;
    border-top: 1px solid var(--border-color);
}

.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 40px;
}

.footer-logo {
    font-size: 1.25rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
}

.footer-logo p {
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 400;
    margin-top: 8px;
}

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

.footer-links a {
    color: var(--text-light);
    font-size: 0.95rem;
}

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

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    color: var(--text-light);
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar {
        padding: 12px 0;
    }

    .nav-links a:not(.btn-login) {
        display: none; /* Hide features/plans links on mobile to save space */
    }

    .nav-links {
        gap: 16px;
    }

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-cta {
        align-items: center;
        width: 100%;
    }

    .btn-large {
        width: 100%;
        max-width: 320px;
    }

    .hero-visual {
        display: none; /* Hide complex mockup on small screens for performance/layout */
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

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

    .section-title {
        margin-bottom: 40px;
    }

    .pricing-card {
        padding: 28px 24px;
    }

    .pricing-card.popular {
        transform: scale(1);
    }

    .footer-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 24px;
    }

    .footer-links {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }

    /* iOS Auto-Zoom prevention */
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    input[type="search"],
    input[type="number"],
    textarea,
    select {
        font-size: 16px !important;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-content p {
        font-size: 1rem;
        margin-bottom: 24px;
    }

    .period-selector {
        padding: 2px;
    }

    .period-btn {
        padding: 8px 12px;
        font-size: 0.8rem;
        gap: 4px;
        min-height: 40px;
    }

    .discount-tag {
        font-size: 0.7rem;
        padding: 1px 6px;
    }

    .pricing-card {
        padding: 20px;
    }
}

