:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --bg-dark: #0f172a;
    --bg-card: #1e293b;
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --border: #334155;
    --success: #22c55e;
}

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

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

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    z-index: 100;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
}

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

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s;
}

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

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

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

.btn-outline:hover {
    background: var(--bg-card);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* Hero */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 6rem 2rem 4rem;
    background: radial-gradient(ellipse at top, #1e293b 0%, var(--bg-dark) 70%);
}

.hero-content {
    max-width: 800px;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--text) 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.hero-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.trial-note {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Features */
.features {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

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

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
}

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

/* Pricing */
.pricing {
    padding: 6rem 2rem;
    background: var(--bg-card);
}

.pricing h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.pricing-cards {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
    max-width: 900px;
    margin: 0 auto;
}

.pricing-card {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2.5rem;
    width: 320px;
    text-align: center;
    position: relative;
}

.pricing-card.featured {
    border-color: var(--primary);
    transform: scale(1.05);
}

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

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

.price {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.price span {
    font-size: 1rem;
    color: var(--text-muted);
}

.pricing-features {
    list-style: none;
    margin-bottom: 2rem;
    text-align: left;
}

.pricing-features li {
    padding: 0.5rem 0;
    color: var(--text-muted);
}

/* Footer */
.footer {
    padding: 2rem;
    text-align: center;
    color: var(--text-muted);
    border-top: 1px solid var(--border);
}

/* Auth Pages */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.auth-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 3rem;
    width: 100%;
    max-width: 420px;
}

.auth-card h1 {
    text-align: center;
    margin-bottom: 0.5rem;
}

.auth-subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 1rem;
}

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

.auth-card .btn {
    width: 100%;
    margin-top: 1rem;
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
}

.error-message {
    background: #7f1d1d;
    color: #fecaca;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: none;
}

.success-message {
    background: #14532d;
    color: #bbf7d0;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: none;
}

/* Dashboard */
.dashboard {
    padding: 6rem 2rem 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.dashboard-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.dashboard-card h2 {
    margin-bottom: 1rem;
}

.tier-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.tier-trial {
    background: #fef3c7;
    color: #92400e;
}

.tier-basic {
    background: #d1fae5;
    color: #065f46;
}

.usage-bar {
    background: var(--border);
    border-radius: 10px;
    height: 12px;
    margin: 1rem 0;
    overflow: hidden;
}

.usage-fill {
    background: var(--primary);
    height: 100%;
    border-radius: 10px;
    transition: width 0.3s;
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .nav-links {
        display: none;
    }

    .pricing-card.featured {
        transform: none;
    }
}

/* ===== ANIMATIONS ===== */

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
    }
}

@keyframes glow {

    0%,
    100% {
        box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
    }

    50% {
        box-shadow: 0 0 40px rgba(99, 102, 241, 0.6);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

/* Apply animations */
.hero-content {
    animation: fadeInUp 0.8s ease-out;
}

.hero h1 {
    animation: fadeInUp 0.8s ease-out;
}

.hero-subtitle {
    animation: fadeInUp 0.8s ease-out 0.1s both;
}

.hero-cta {
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.feature-card {
    animation: fadeInUp 0.6s ease-out both;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:nth-child(1) {
    animation-delay: 0.1s;
}

.feature-card:nth-child(2) {
    animation-delay: 0.2s;
}

.feature-card:nth-child(3) {
    animation-delay: 0.3s;
}

.feature-card:nth-child(4) {
    animation-delay: 0.4s;
}

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

.feature-icon {
    animation: float 3s ease-in-out infinite;
}

.pricing-card {
    animation: fadeInUp 0.6s ease-out both;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pricing-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4);
}

.pricing-card.featured {
    animation: glow 3s ease-in-out infinite;
}

.popular-badge {
    animation: pulse 2s ease-in-out infinite;
}

/* Button shine effect */
.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.4);
}

.logo {
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.auth-card {
    animation: fadeInUp 0.6s ease-out;
}

.dashboard-card {
    animation: fadeInUp 0.5s ease-out both;
    transition: transform 0.3s ease;
}

.dashboard-card:nth-child(1) {
    animation-delay: 0s;
}

.dashboard-card:nth-child(2) {
    animation-delay: 0.1s;
}

.dashboard-card:nth-child(3) {
    animation-delay: 0.2s;
}

.dashboard-card:hover {
    transform: translateY(-3px);
}

.usage-fill {
    background: linear-gradient(90deg, var(--primary), #818cf8, var(--primary));
    background-size: 200% 100%;
    animation: shimmer 2s linear infinite;
}

.form-group input {
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus {
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

html {
    scroll-behavior: smooth;
}

/* Hero Badge */
.hero-badge {
    display: inline-block;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #1f2937;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.02);
    }
}

/* Section Subtitle */
.section-subtitle {
    color: var(--text-muted);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto 3rem;
    text-align: center;
}

/* Feature Card Highlight */
.feature-card.highlight {
    border-color: var(--primary);
    background: linear-gradient(135deg, var(--bg-card), rgba(99, 102, 241, 0.1));
}

.feature-card.highlight::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), #818cf8);
    border-radius: 16px 16px 0 0;
}

/* Comparison Table */
.compare-section {
    padding: 5rem 2rem;
    background: var(--bg-card);
}

.compare-table-wrapper {
    max-width: 800px;
    margin: 0 auto;
    overflow-x: auto;
}

.compare-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-dark);
    border-radius: 16px;
    overflow: hidden;
}

.compare-table th,
.compare-table td {
    padding: 1rem 1.5rem;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.compare-table th {
    background: rgba(99, 102, 241, 0.1);
    font-weight: 600;
    color: var(--text);
}

.compare-table th:first-child,
.compare-table td:first-child {
    text-align: left;
}

.compare-table .highlight-col {
    background: rgba(99, 102, 241, 0.15);
    color: var(--text);
    font-weight: 500;
}

.compare-table th.highlight-col {
    background: var(--primary);
    color: white;
}

.compare-table tbody tr:hover {
    background: rgba(99, 102, 241, 0.05);
}

.compare-table tbody tr:last-child td {
    border-bottom: none;
}

/* Final CTA Section */
.final-cta {
    padding: 5rem 2rem;
    text-align: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(99, 102, 241, 0.05));
}

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

.final-cta p {
    color: var(--text-muted);
    font-size: 1.125rem;
    margin-bottom: 2rem;
}

/* Pricing list styling */
.pricing-features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pricing-features li strong {
    color: var(--primary);
}

/* Tier badges for dashboard */
.tier-badge {
    display: inline-block;
    padding: 0.35rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 20px;
}

.tier-free {
    background: linear-gradient(135deg, #a5b4fc, #818cf8);
    color: #3730a3;
}

.tier-pro {
    background: linear-gradient(135deg, #fbbf24, #d97706);
    color: #1f2937;
}