/* ========================================
   Base Variables & Reset
   ======================================== */
:root {
    --ink: #0f172a;
    --ink-light: #334155;
    --muted: #64748b;
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    --surface: #f8fafc;
    --card: #ffffff;

    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #dbeafe;
    --primary-soft: #eff6ff;

    --green: #10b981;
    --green-light: #d1fae5;
    --purple: #8b5cf6;
    --purple-light: #ede9fe;
    --orange: #f59e0b;
    --orange-light: #fef3c7;
    --pink: #ec4899;
    --pink-light: #fce7f3;
    --teal: #06b6d4;
    --teal-light: #cffafe;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
}

html {
    position: relative;
    min-height: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    color: var(--ink);
    background: var(--surface);
    line-height: 1.6;
}

/* ========================================
   Homepage Layout
   ======================================== */
.homepage {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ========================================
   Navigation
   ======================================== */
.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    gap: 16px;
}

.brand {
    text-decoration: none;
    color: inherit;
}

.brand-logo {
    width: 160px;
    height: auto;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ========================================
   Buttons
   ======================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

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

.btn-ghost {
    background: transparent;
    color: var(--ink-light);
    border-color: var(--border);
}

.btn-ghost:hover {
    background: var(--surface);
    border-color: var(--ink-light);
    color: var(--ink);
}

/* Hero Buttons */
.btn-hero {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-hero--primary {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
}

.btn-hero--primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.5);
}

.btn-hero--secondary {
    background: var(--card);
    color: var(--ink);
    border: 1px solid var(--border);
}

.btn-hero--secondary:hover {
    background: var(--surface);
    border-color: var(--ink-light);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 60px;
    align-items: center;
    padding: 60px 0 80px;
}

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

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--primary-soft);
    color: var(--primary);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 24px;
}

.hero-badge__dot {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.1;
    margin: 0 0 20px;
    color: var(--ink);
    letter-spacing: -0.02em;
}

.hero-title__highlight {
    background: linear-gradient(135deg, var(--primary) 0%, var(--purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--muted);
    margin: 0 0 32px;
    line-height: 1.7;
}

.hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.hero-trust {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-trust__avatars {
    display: flex;
}

.hero-trust__avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--purple) 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 600;
    border: 2px solid var(--card);
    margin-left: -10px;
}

.hero-trust__avatar:first-child {
    margin-left: 0;
}

.hero-trust__text {
    font-size: 0.9rem;
    color: var(--muted);
}

/* Hero Visual */
.hero-visual {
    position: relative;
}

.hero-mockup {
    background: var(--card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl), 0 0 0 1px var(--border);
    overflow: hidden;
}

.hero-mockup__browser {
    padding: 12px 16px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

.hero-mockup__dots {
    display: flex;
    gap: 6px;
}

.hero-mockup__dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
}

.hero-mockup__dots span:first-child {
    background: #f87171;
}

.hero-mockup__dots span:nth-child(2) {
    background: #fbbf24;
}

.hero-mockup__dots span:last-child {
    background: #34d399;
}

.hero-mockup__image {
    width: 100%;
    height: auto;
    display: block;
}

/* Floating elements */
.hero-float {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px;
    background: var(--card);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--ink);
    animation: float 3s ease-in-out infinite;
}

.hero-float svg {
    color: var(--primary);
}

.hero-float--1 {
    top: 20%;
    left: -30px;
    animation-delay: 0s;
}

.hero-float--2 {
    bottom: 25%;
    right: -20px;
    animation-delay: 1.5s;
}

@keyframes float {

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

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

/* ========================================
   Section Headers
   ======================================== */
.section-header {
    margin-bottom: 48px;
}

.section-header--center {
    text-align: center;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.section-label {
    display: inline-block;
    padding: 6px 14px;
    background: var(--primary-soft);
    color: var(--primary);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 16px;
}

.section-title {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 800;
    color: var(--ink);
    margin: 0 0 12px;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--muted);
    margin: 0;
    line-height: 1.6;
}

/* ========================================
   Phone Showcase Section
   ======================================== */
.phone-showcase {
    padding: 40px 0;
    background: var(--card);
    margin: 0 -24px;
    padding-left: 24px;
    padding-right: 24px;
}

.phone-showcase__content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
}

.phone-showcase__text {
    max-width: 480px;
}

.phone-showcase__description {
    font-size: 1.1rem;
    color: var(--muted);
    line-height: 1.7;
    margin: 0;
}

.phone-showcase__image {
    display: flex;
    justify-content: center;
}

.phone-showcase__image img {
    max-width: 380px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.15));
    transition: transform 0.3s ease, filter 0.3s ease;
}

.phone-showcase__image img:hover {
    transform: scale(1.05) rotate(2deg);
    filter: drop-shadow(0 30px 50px rgba(0, 0, 0, 0.2));
}

@media (max-width: 768px) {
    .phone-showcase {
        margin: 0 -16px;
        padding-left: 16px;
        padding-right: 16px;
    }

    .phone-showcase__content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .phone-showcase__text {
        max-width: 100%;
    }

    .phone-showcase__image img {
        max-width: 280px;
    }
}

/* ========================================
   Home Wiki Section
   ======================================== */
.home-wiki {
    padding: 80px 0;
}

.home-wiki__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
    max-width: 900px;
    margin: 0 auto;
}

.wiki-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-sm);
}

.wiki-card__title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 16px;
    color: var(--ink);
}

.wiki-card__steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 12px;
    counter-reset: step;
}

.wiki-card__steps li {
    counter-increment: step;
    display: grid;
    grid-template-columns: 28px 1fr;
    gap: 12px;
    align-items: start;
    color: var(--muted);
    line-height: 1.6;
}

.wiki-card__steps li::before {
    content: counter(step);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--primary-soft);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
}

@media (max-width: 900px) {
    .home-wiki__grid {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   Dashboard Types Section
   ======================================== */
.dashboard-types {
    padding: 80px 0;
}

.dashboard-types__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.type-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: all 0.3s ease;
}

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

.type-card__icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.type-card__icon svg {
    width: 28px;
    height: 28px;
}

.type-card--spending .type-card__icon {
    background: var(--primary-light);
    color: var(--primary);
}

.type-card--income .type-card__icon {
    background: var(--green-light);
    color: var(--green);
}

.type-card--notes .type-card__icon {
    background: var(--orange-light);
    color: var(--orange);
}

.type-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 10px;
}

.type-card__description {
    font-size: 0.95rem;
    color: var(--muted);
    margin: 0;
    line-height: 1.6;
}

/* ========================================
   Features Section
   ======================================== */
.features {
    padding: 80px 0;
    background: var(--card);
    margin: 0 -24px;
    padding-left: 24px;
    padding-right: 24px;
}

.features__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    max-width: 1000px;
    margin: 0 auto;
}

.feature-item {
    text-align: center;
    padding: 24px;
    border-radius: var(--radius-lg);
    transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-6px);
    background: var(--surface);
    box-shadow: var(--shadow-md);
}

.feature-item__icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    transition: transform 0.3s ease;
}

.feature-item:hover .feature-item__icon {
    transform: scale(1.1);
}

.feature-item__icon svg {
    width: 26px;
    height: 26px;
}

.feature-item__icon--blue {
    background: var(--primary-light);
    color: var(--primary);
}

.feature-item__icon--green {
    background: var(--green-light);
    color: var(--green);
}

.feature-item__icon--purple {
    background: var(--purple-light);
    color: var(--purple);
}

.feature-item__icon--orange {
    background: var(--orange-light);
    color: var(--orange);
}

.feature-item__icon--pink {
    background: var(--pink-light);
    color: var(--pink);
}

.feature-item__icon--teal {
    background: var(--teal-light);
    color: var(--teal);
}

.feature-item__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 8px;
}

.feature-item__text {
    font-size: 0.9rem;
    color: var(--muted);
    margin: 0;
    line-height: 1.6;
}

/* ========================================
   Testimonials Section
   ======================================== */
.testimonials {
    padding: 80px 0;
}

.testimonials__marquee {
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.testimonials__track {
    display: flex;
    gap: 20px;
    width: max-content;
    animation: testimonials-marquee 40s linear infinite;
}

@keyframes testimonials-marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.testimonial-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    display: grid;
    gap: 16px;
    min-width: 260px;
    max-width: 320px;
}

.testimonial-card__quote {
    margin: 0;
    font-size: 0.98rem;
    color: var(--ink);
    line-height: 1.7;
}

.testimonial-card__meta {
    display: grid;
    gap: 4px;
}

.testimonial-card__name {
    font-weight: 700;
    color: var(--ink);
}

.testimonial-card__role {
    font-size: 0.9rem;
    color: var(--muted);
}

@media (max-width: 900px) {
    .testimonials {
        display: none;
    }
}

@keyframes testimonials-slider {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

@media (prefers-reduced-motion: reduce) {
    .testimonials__track {
        animation: none;
        flex-wrap: wrap;
        width: 100%;
        justify-content: center;
    }
}

/* ========================================
   Analytics Preview Section
   ======================================== */
.analytics-preview {
    padding: 80px 0;
    background: linear-gradient(180deg, var(--surface) 0%, var(--card) 100%);
    margin: 0 -24px;
    padding-left: 24px;
    padding-right: 24px;
}

.analytics-preview__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
    max-width: 1000px;
    margin: 0 auto;
}

.analytics-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 28px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
}

.analytics-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: transparent;
}

.analytics-card__glow {
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.analytics-card:hover .analytics-card__glow {
    opacity: 1;
}

.analytics-card__glow--blue {
    background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, transparent 70%);
}

.analytics-card__glow--purple {
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
}

.analytics-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    position: relative;
    z-index: 1;
}

.analytics-card__title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.analytics-card__icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

.analytics-card:hover .analytics-card__icon {
    transform: scale(1.1);
}

.analytics-card__icon--blue {
    background: var(--primary-light);
    color: var(--primary);
}

.analytics-card__icon--purple {
    background: var(--purple-light);
    color: var(--purple);
}

.analytics-card__header h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.analytics-card__badge {
    padding: 6px 14px;
    background: var(--primary-soft);
    color: var(--primary);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.analytics-card__badge--purple {
    background: var(--purple-light);
    color: var(--purple);
}

.analytics-card__body {
    position: relative;
    z-index: 1;
    margin-bottom: 20px;
}

.analytics-card__chart {
    width: 100%;
    height: auto;
    display: block;
}

.analytics-bar {
    transition: opacity 0.3s ease;
}

.analytics-card:hover .analytics-bar {
    opacity: 0.9;
}

.analytics-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
    position: relative;
    z-index: 1;
}

.analytics-card__stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.analytics-card__stat-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--ink);
    letter-spacing: -0.02em;
}

.analytics-card__stat-label {
    font-size: 0.8rem;
    color: var(--muted);
}

.analytics-card__stat--positive {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 6px;
    color: var(--green);
    font-size: 0.85rem;
    font-weight: 600;
}

.analytics-card__legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
    position: relative;
    z-index: 1;
}

.analytics-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--muted);
}

.analytics-legend-item i {
    width: 10px;
    height: 10px;
    border-radius: 3px;
    display: inline-block;
}

@media (max-width: 768px) {
    .analytics-preview {
        margin: 0 -16px;
        padding-left: 16px;
        padding-right: 16px;
    }

    .analytics-preview__grid {
        grid-template-columns: 1fr;
    }

    .analytics-card {
        padding: 20px;
    }

    .analytics-card__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .analytics-card__footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}

/* ========================================
   Pricing Section
   ======================================== */
.pricing {
    padding: 80px 0;
}

.pricing__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    max-width: 800px;
    margin: 0 auto;
}

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

.pricing-card--featured {
    border: 2px solid var(--primary);
    box-shadow: var(--shadow-lg);
}

.pricing-card__ribbon {
    position: absolute;
    top: -1px;
    right: 24px;
    background: var(--primary);
    color: #fff;
    padding: 8px 16px;
    font-size: 0.8rem;
    font-weight: 700;
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
}

.pricing-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.pricing-card__name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.pricing-card__tag {
    padding: 4px 12px;
    background: var(--surface);
    color: var(--muted);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.pricing-card__tag--accent {
    background: var(--primary-soft);
    color: var(--primary);
}

.pricing-card__price {
    margin-bottom: 24px;
}

.pricing-card__amount {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--ink);
}

.pricing-card__period {
    font-size: 1rem;
    color: var(--muted);
}

.pricing-card__features {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
    flex: 1;
}

.pricing-card__features li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-light);
    color: var(--ink-light);
    font-size: 0.95rem;
}

.pricing-card__features li:last-child {
    border-bottom: none;
}

.pricing-card__features--pro li {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pricing-card__features--pro svg {
    color: var(--green);
    flex-shrink: 0;
}

.btn-pricing {
    display: block;
    width: 100%;
    padding: 14px 24px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-pricing--primary {
    background: var(--primary);
    color: #fff;
}

.btn-pricing--primary:hover {
    background: var(--primary-dark);
}

.btn-pricing--secondary {
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--border);
}

.btn-pricing--secondary:hover {
    background: var(--border-light);
}

/* ========================================
   CTA Section
   ======================================== */
.cta-section {
    padding: 40px 0 80px;
}

.cta-box {
    background: linear-gradient(135deg, var(--ink) 0%, #1e293b 100%);
    border-radius: var(--radius-xl);
    padding: 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.cta-box__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 8px;
}

.cta-box__text {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

.cta-box .btn-hero--primary {
    flex-shrink: 0;
}

/* ========================================
   Footer
   ======================================== */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 40px 0 24px;
}

.site-footer__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

.site-footer__brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.site-footer__logo {
    width: 100px;
    height: auto;
}

.site-footer__tagline {
    color: var(--muted);
    font-size: 0.9rem;
    margin: 0;
}

.site-footer__link {
    color: var(--muted);
    font-size: 0.9rem;
    text-decoration: none;
    transition: color 0.2s ease;
}

.site-footer__link:hover {
    color: var(--primary);
}

.site-footer__lang {
    display: flex;
    gap: 8px;
}

.site-footer__lang-btn {
    padding: 8px 14px;
    background: var(--surface);
    color: var(--muted);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.site-footer__lang-btn:hover,
.site-footer__lang-btn.active {
    background: var(--primary-soft);
    color: var(--primary);
}

.site-footer__bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--border-light);
    color: var(--muted);
    font-size: 0.85rem;
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        gap: 48px;
        text-align: center;
    }

    .hero-content {
        max-width: 600px;
        margin: 0 auto;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-trust {
        justify-content: center;
    }

    .hero-float {
        display: none;
    }

    .dashboard-types__grid {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin: 0 auto;
    }

    .features__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

    .nav {
        flex-direction: column;
        gap: 16px;
        padding: 16px 0;
    }

    .nav-actions {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero {
        padding: 40px 0 60px;
    }

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

    .hero-cta {
        flex-direction: column;
    }

    .btn-hero {
        width: 100%;
    }

    .features__grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .features {
        margin: 0 -16px;
        padding-left: 16px;
        padding-right: 16px;
    }

    .analytics-preview__grid {
        grid-template-columns: 1fr;
    }

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

    .cta-box {
        flex-direction: column;
        text-align: center;
        padding: 32px 24px;
    }

    .cta-box .btn-hero--primary {
        width: 100%;
    }

    .site-footer__inner {
        flex-direction: column;
        text-align: center;
    }

    .site-footer__brand {
        flex-direction: column;
    }
}

/* ========================================
   Auth Pages
   ======================================== */
.auth-shell {
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
}

.auth-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 32px;
}

.auth-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 8px;
}

.auth-lead {
    color: var(--muted);
    margin: 0 0 24px;
}

.auth-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--ink);
    letter-spacing: 0.02em;
}

.auth-link {
    color: var(--muted);
    text-decoration: none;
}

.auth-link:hover {
    color: var(--primary);
    text-decoration: underline;
}

.auth-divider {
    height: 1px;
    background: var(--border-light);
    margin: 20px 0;
}

.auth-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.auth-actions .btn {
    min-width: 140px;
}

.auth-hero {
    padding: 20px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--primary-soft), var(--purple-light));
    margin-bottom: 20px;
}

.auth-hero-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 6px;
}

.auth-helper {
    color: var(--muted);
    font-size: 0.9rem;
}

.register-card {
    background: var(--primary-soft);
    border-color: var(--primary-light);
}

.register-card .auth-title {
    color: var(--primary-dark);
}

.mini-hint {
    color: var(--muted);
    font-size: 0.85rem;
}

/* ========================================
   Form Elements
   ======================================== */
.form-control,
.form-select {
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    padding: 12px 16px;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    outline: none;
}

.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-accent {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    font-weight: 600;
    border-radius: 999px;
    padding: 12px 24px;
}

.btn-accent:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
    transform: translateY(-1px);
}

.btn-accent--blue {
    background: var(--primary);
    border-color: var(--primary);
}

.btn-accent--blue:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}

/* ========================================
   Dashboard Pages
   ======================================== */
.dashboard-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 28px;
    margin-bottom: 20px;
}

.dashboard-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 8px;
}

.dashboard-title-icon {
    color: var(--primary);
}

.dashboard-label {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* Dashboard Map Header */
.dashboard-map-header {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
}

.dashboard-map-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 8px 16px rgba(37, 99, 235, 0.25);
}

.dashboard-map-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.dashboard-map-subtitle {
    color: var(--muted);
    font-size: 1rem;
}

.dashboard-map-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--ink);
    display: flex;
    align-items: center;
}

.dashboard-map-create-form {
    margin-top: 24px;
}

.dashboard-map-input-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.dashboard-map-input {
    flex: 1 1 200px;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.dashboard-map-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.dashboard-map-select {
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    background-color: var(--card);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dashboard-map-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.dashboard-map-currency {
    width: 80px;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    text-align: center;
    transition: all 0.2s ease;
}

.dashboard-map-currency:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.dashboard-map-btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.dashboard-map-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.4);
}

.dashboard-map-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Dashboard Tiles */
.dashboard-map-tile {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 24px;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 16px;
    border: 1px solid var(--border);
    transition: all 0.2s ease;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.dashboard-map-tile:hover:not(.dashboard-map-tile--locked) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: #dadce0;
}

.dashboard-map-tile--locked {
    opacity: 0.6;
    filter: grayscale(0.3);
    cursor: not-allowed;
}

.dashboard-map-tile__header {
    flex: 0 0 auto;
}

.dashboard-map-tile__title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.dashboard-map-tile__title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
    line-height: 1.3;
}

.dashboard-map-tile__currency {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    background: var(--primary-soft);
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
}

.dashboard-map-tile__badges {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.dashboard-map-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.dashboard-map-badge--spending {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.dashboard-map-badge--income {
    background: var(--green-light);
    color: #065f46;
}

.dashboard-map-badge--note {
    background: var(--orange-light);
    color: #92400e;
}

.dashboard-map-badge--locked {
    background: var(--surface);
    color: var(--muted);
}

.dashboard-map-tile__stats {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary-soft), rgba(255, 255, 255, 0.4));
    border-radius: var(--radius-md);
    border: 1px solid rgba(191, 219, 254, 0.5);
}

.dashboard-map-stat {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dashboard-map-stat svg {
    color: var(--primary);
    flex-shrink: 0;
}

.dashboard-map-stat__value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ink);
}

.dashboard-map-stat__label {
    font-size: 0.85rem;
    color: var(--muted);
}

.dashboard-map-tile__features {
    display: flex;
    gap: 8px;
}

.dashboard-map-feature-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    background: var(--primary-soft);
    color: var(--primary);
    transition: all 0.2s ease;
}

.dashboard-map-feature-icon:hover {
    background: var(--primary-light);
    transform: scale(1.1);
}

.dashboard-map-feature-icon--disabled {
    opacity: 0.5;
    background: var(--surface);
    color: var(--muted);
}

.dashboard-map-tile__actions {
    flex: 0 0 auto;
    display: flex;
    gap: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border-light);
}

.dashboard-map-tile__action {
    flex: 1;
    padding: 10px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--card);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.dashboard-map-tile__action--edit {
    color: var(--green);
    border-color: var(--green-light);
}

.dashboard-map-tile__action--edit:hover:not(:disabled) {
    background: var(--green-light);
    border-color: var(--green);
    transform: translateY(-1px);
}

.dashboard-map-tile__action--delete {
    color: #dc2626;
    border-color: #fecaca;
}

.dashboard-map-tile__action--delete:hover:not(:disabled) {
    background: #fecaca;
    border-color: #dc2626;
    transform: translateY(-1px);
}

.dashboard-map-tile__action:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.dashboard-map-tile__delete-form {
    flex: 1;
    margin: 0;
}

.plan-locked {
    opacity: 0.6;
}

/* ========================================
   Profile Page
   ======================================== */
.profile-header {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
}

.profile-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 8px 16px rgba(37, 99, 235, 0.25);
}

.profile-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.profile-subtitle {
    color: var(--muted);
    font-size: 1rem;
}

.profile-subscription-card {
    padding: 20px 24px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    border: 2px solid;
}

.profile-subscription-card--pro {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(16, 185, 129, 0.05));
    border-color: rgba(34, 197, 94, 0.3);
}

.profile-subscription-card--trial {
    background: linear-gradient(135deg, var(--primary-soft), rgba(37, 99, 235, 0.05));
    border-color: rgba(59, 130, 246, 0.3);
}

.profile-subscription-card--expired {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.1), rgba(239, 68, 68, 0.05));
    border-color: rgba(220, 38, 38, 0.3);
}

.profile-subscription-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.profile-subscription-badge {
    font-size: 0.9rem;
    font-weight: 600;
    padding: 4px 0;
}

.profile-subscription-badge--pro {
    color: #15803d;
}

.profile-subscription-badge--trial {
    color: var(--primary-dark);
}

.profile-subscription-badge--expired {
    color: #dc2626;
}

.profile-subscription-cancel {
    padding: 6px 14px;
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
    border: 1px solid rgba(220, 38, 38, 0.3);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.profile-subscription-cancel:hover {
    background: rgba(220, 38, 38, 0.2);
    border-color: #dc2626;
}

.profile-subscription-upgrade {
    padding: 6px 14px;
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.profile-subscription-upgrade:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    transform: translateY(-1px);
    color: #fff;
}

.profile-subscription-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 0.9rem;
}

.profile-subscription-info svg {
    flex-shrink: 0;
    opacity: 0.7;
}

.profile-card {
    background: var(--card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.profile-card--danger {
    border: 2px solid rgba(220, 38, 38, 0.2);
}

.profile-card__header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    background: var(--surface);
}

.profile-card--danger .profile-card__header {
    background: #fef7f7;
}

.profile-card__title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.profile-card__body {
    padding: 24px;
    flex: 1;
}

.profile-card__footer {
    padding: 20px 24px;
    border-top: 1px solid var(--border-light);
    background: #fafbfc;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.profile-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--ink);
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.profile-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.profile-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.profile-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border), transparent);
    margin: 24px 0;
}

.profile-section-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 6px;
}

.profile-section-hint {
    font-size: 0.85rem;
    color: var(--muted);
    margin: 0;
}

.profile-btn {
    padding: 12px 20px;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    border: 2px solid transparent;
}

.profile-btn--save {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: #fff;
    border: none;
}

.profile-btn--save:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(22, 163, 74, 0.3);
}

.profile-btn--upgrade {
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    color: #fff;
    border: none;
}

.profile-btn--upgrade:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
    color: #fff;
}

.profile-btn--danger {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
    border-color: rgba(220, 38, 38, 0.3);
    width: 100%;
    justify-content: center;
}

.profile-btn--danger:hover {
    background: #dc2626;
    color: #fff;
    border-color: #dc2626;
    transform: translateY(-1px);
}

.profile-danger-text {
    color: #991b1b;
    font-size: 0.9rem;
    margin-bottom: 16px;
    line-height: 1.6;
}

/* ========================================
   Responsive - Auth & Profile
   ======================================== */
@media (max-width: 991px) {
    .auth-card {
        padding: 24px;
    }

    .profile-header {
        padding: 24px;
    }

    .profile-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 767px) {
    .auth-shell {
        padding: 16px 0 28px;
        min-height: auto;
    }

    .auth-card {
        padding: 20px;
        border-radius: var(--radius-lg);
    }

    .auth-actions .btn {
        width: 100%;
    }

    .auth-title {
        font-size: 1.6rem;
    }

    .profile-header {
        padding: 20px;
    }

    .profile-title {
        font-size: 1.4rem;
    }

    .profile-subscription-card__header {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-card__footer {
        flex-direction: column;
    }

    .profile-btn {
        width: 100%;
        justify-content: center;
    }

    .dashboard-map-header {
        padding: 24px;
    }

    .dashboard-map-title {
        font-size: 1.5rem;
    }

    .dashboard-map-input-group {
        flex-direction: column;
    }

    .dashboard-map-input {
        width: 100%;
        flex: 1 1 auto;
        max-width: 100%;
    }

    .dashboard-map-select,
    .dashboard-map-currency {
        width: 100%;
    }

    .dashboard-map-tile__stats {
        flex-direction: column;
        align-items: flex-start;
    }

    .dashboard-map-tile__actions {
        flex-direction: column;
    }

    .dashboard-map-tile__action {
        width: 100%;
    }
}

/* ========================================
   Animations
   ======================================== */
@media (prefers-reduced-motion: no-preference) {
    .hero-mockup {
        animation: fadeInUp 0.8s ease-out;
    }

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

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

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

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

    .feature-item {
        animation: fadeInUp 0.6s ease-out both;
    }

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

    .feature-item:nth-child(2) {
        animation-delay: 0.15s;
    }

    .feature-item:nth-child(3) {
        animation-delay: 0.2s;
    }

    .feature-item:nth-child(4) {
        animation-delay: 0.25s;
    }

    .feature-item:nth-child(5) {
        animation-delay: 0.3s;
    }

    .feature-item:nth-child(6) {
        animation-delay: 0.35s;
    }
}

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

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

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
