/* Shared design system for the Flask site */
:root {
    --bg: #050816;
    --bg-alt: #0b1020;
    --accent: #4f46e5;
    --accent-soft: rgba(79, 70, 229, 0.2);
    --accent-cyan: #06b6d4;
    --accent-green: #10b981;
    --accent-pink: #ec4899;
    --text: #e5e7eb;
    --muted: #9ca3af;
    --danger: #ef4444;
    --success: #22c55e;
    --radius: 12px;
    --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.45);
    --transition: 0.25s ease;
    --blue: #3b82f6;
    --purple: #a855f7;
    --amber: #f59e0b;
    --emerald: #10b981;
}

.service-item:nth-child(1) h3::before { content: '🎯'; }
.service-item:nth-child(2) h3::before { content: '🔍'; }
.service-item:nth-child(3) h3::before { content: '📊'; }
.service-item:nth-child(4) h3::before { content: '🛡️'; }

.service-item:nth-child(1) { animation-delay: 0.1s; }
.service-item:nth-child(2) { animation-delay: 0.2s; }
.service-item:nth-child(3) { animation-delay: 0.3s; }
.service-item:nth-child(4) { animation-delay: 0.4s; }

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: radial-gradient(circle at top, #111827 0, #020617 40%, #000 100%);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
}
main { display: flex; flex-direction: column; min-height: calc(100vh - 140px); }

.site-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 18px 40px; position: sticky; top: 0; z-index: 50;
    backdrop-filter: blur(16px); background: linear-gradient(to bottom, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.7));
}
.logo { font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.95rem; color: var(--text); text-decoration: none; }
.logo span { color: var(--accent); }
.nav a { margin-left: 18px; text-decoration: none; color: var(--muted); font-size: 0.9rem; transition: color var(--transition); }
.nav a:hover, .nav a:focus { color: var(--text); }
.nav-cta {
    padding: 8px 14px; border-radius: 999px; border: 1px solid var(--accent-soft);
    background: radial-gradient(circle at top left, var(--accent-soft), transparent);
}

.page-shell { max-width: 1100px; margin: 0 auto; padding: 60px 24px 120px; position: relative; }
.section-title { font-size: clamp(2.3rem, 4.6vw, 3.4rem); font-weight: 800; letter-spacing: -0.03em; margin-bottom: 16px; background: linear-gradient(135deg, #fff 0%, var(--accent) 45%, var(--accent-cyan) 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.section-intro, .section-subtitle { font-size: clamp(1.04rem, 2vw, 1.28rem); color: var(--muted); line-height: 1.7; max-width: 760px; margin-bottom: 40px; }
.section-subtitle { margin-bottom: 32px; color: #d1d5db; }

.hero-header {
    position: relative; width: 100%; min-height: 78vh; display: flex; align-items: center; justify-content: center; overflow: hidden; padding: 2rem; margin-bottom: 2rem;
}
.bg-grid { position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px); background-size: 60px 60px; mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%); -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%); z-index: 1; }
.bg-orbs { position: absolute; inset: 0; z-index: 0; filter: blur(80px); opacity: 0.5; }
.orb { position: absolute; border-radius: 50%; }
.orb-1 { width: 600px; height: 600px; background: radial-gradient(circle, var(--accent) 0%, transparent 70%); top: -10%; left: -10%; animation: float1 15s infinite alternate ease-in-out; }
.orb-2 { width: 500px; height: 500px; background: radial-gradient(circle, var(--accent-cyan) 0%, transparent 70%); bottom: -15%; right: -5%; animation: float2 18s infinite alternate ease-in-out; }
.orb-3 { width: 400px; height: 400px; background: radial-gradient(circle, var(--accent-green) 0%, transparent 70%); top: 40%; left: 50%; opacity: 0.3; animation: float3 20s infinite alternate ease-in-out; }
.noise { position: absolute; inset: 0; z-index: 2; opacity: 0.04; pointer-events: none; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E"); }
.content { position: relative; z-index: 10; max-width: 1000px; text-align: center; }
.badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px; border-radius: 999px; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1); font-size: 0.85rem; color: var(--muted); margin-bottom: 2rem; backdrop-filter: blur(10px); }
.badge-dot { width: 6px; height: 6px; background: var(--accent-green); border-radius: 50%; box-shadow: 0 0 10px var(--accent-green); animation: pulse 2s infinite; }
.hero-title-animated { font-size: clamp(2.3rem, 6vw, 4.8rem); font-weight: 800; line-height: 1.1; letter-spacing: -0.03em; margin-bottom: 1.5rem; }
.line { display: block; overflow: hidden; }
.word { display: inline-block; opacity: 0; transform: translateY(100%) rotateX(-45deg); transform-origin: bottom; animation: wordReveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards; margin-right: 0.25em; }
.line-1 .word:nth-child(1) { animation-delay: 0.4s; } .line-1 .word:nth-child(2) { animation-delay: 0.5s; } .line-1 .word:nth-child(3) { animation-delay: 0.6s; } .line-1 .word:nth-child(4) { animation-delay: 0.7s; } .line-1 .word:nth-child(5) { animation-delay: 0.8s; }
.line-2 .word:nth-child(1) { animation-delay: 1.0s; } .line-2 .word:nth-child(2) { animation-delay: 1.1s; } .line-2 .word:nth-child(3) { animation-delay: 1.2s; } .line-2 .word:nth-child(4) { animation-delay: 1.3s; }
.highlight-ai { background: linear-gradient(135deg, var(--accent-cyan), var(--accent)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.highlight-approve { position: relative; color: var(--text); }
.highlight-approve::after { content: ''; position: absolute; bottom: 5px; left: 0; width: 100%; height: 6px; background: var(--accent-green); border-radius: 4px; transform: scaleX(0); transform-origin: left; box-shadow: 0 0 15px var(--accent-green); animation: drawLine 0.8s cubic-bezier(0.16, 1, 0.3, 1) 1.8s forwards; }
.subtitle { font-size: clamp(1rem, 2vw, 1.25rem); color: var(--muted); max-width: 680px; margin: 0 auto 2.5rem; line-height: 1.6; }

.cards, .service-grid, .about-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 20px; }
.card, .service-item, .interactive-card, .detail-card, .contact-form {
    position: relative; padding: 24px; border-radius: var(--radius); background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); box-shadow: var(--shadow-soft); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.card:hover, .service-item:hover, .interactive-card:hover, .detail-card:hover, .contact-form:hover { transform: translateY(-3px); border-color: rgba(79, 70, 229, 0.5); box-shadow: 0 22px 60px -20px rgba(79, 70, 229, 0.35); }
.card h3, .service-item h3, .interactive-card h3, .detail-card h3 { font-size: 1.15rem; margin-bottom: 8px; color: #fff; }
.card p, .service-item p, .interactive-card p, .detail-card p { color: var(--muted); line-height: 1.7; }

.timeline { position: relative; margin-top: 20px; padding-left: 28px; }
.timeline::before { content: ''; position: absolute; left: 8px; top: 0; bottom: 0; width: 2px; background: linear-gradient(to bottom, var(--accent), var(--accent-cyan), var(--accent-pink)); opacity: 0.6; }
.timeline-item { margin-bottom: 20px; padding: 22px 24px; }
.timeline-item::after { content: ''; position: absolute; left: -20px; top: 24px; width: 14px; height: 14px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); box-shadow: 0 0 0 4px rgba(79,70,229,0.14); }
.timeline-item:nth-child(2)::after { border-color: var(--accent-cyan); box-shadow: 0 0 0 4px rgba(6,182,212,0.14); }
.timeline-item:nth-child(3)::after { border-color: var(--accent-pink); box-shadow: 0 0 0 4px rgba(236,72,153,0.14); }

.page-view { margin-top: 48px; }
.page-view h2 { font-size: clamp(1.35rem, 2.3vw, 1.8rem); color: #fff; margin-bottom: 12px; }
.page-view > p { color: var(--muted); margin-bottom: 20px; }
.detail-card { margin-bottom: 16px; }

#p-healthcare .detail-card:nth-child(4) { border-left: 4px solid #3b82f6; }
#p-healthcare .detail-card:nth-child(3) { border-left: 4px solid #a855f7; }
#p-finance .detail-card:nth-child(4) { border-left: 4px solid #f59e0b; }
#p-finance .detail-card:nth-child(3) { border-left: 4px solid #10b981; }

#p-healthcare .detail-card:nth-child(4) h3 { color: var(--blue); }
#p-healthcare .detail-card:nth-child(3) h3 { color: var(--purple); }
#p-finance .detail-card:nth-child(4) h3 {  color: var(--amber); }
#p-finance .detail-card:nth-child(3) h3 { color: var(--emerald); }

.form-row { margin-bottom: 16px; }
.form-row label { display: block; margin-bottom: 8px; color: var(--muted); font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.05em; }
.form-row input, .form-row textarea { width: 100%; padding: 12px 14px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.1); background: rgba(255,255,255,0.03); color: var(--text); font: inherit; }
.form-row input:focus, .form-row textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(79,70,229,0.15); }
.form-row textarea { min-height: 140px; resize: vertical; }
.btn-primary { display: inline-flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 999px; border: none; background: linear-gradient(135deg, var(--accent), var(--accent-cyan)); color: white; font-weight: 600; cursor: pointer; box-shadow: var(--shadow-soft); transition: transform var(--transition), box-shadow var(--transition); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 22px 50px rgba(0,0,0,0.5); }
.btn-primary .arrow { transition: transform 0.3s ease; }
.btn-primary:hover .arrow { transform: translateX(4px); }

.flash-container { padding: 10px 40px 0; }
.flash { padding: 10px 14px; border-radius: 8px; margin-bottom: 8px; font-size: 0.9rem; }
.flash-success { background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.6); }
.flash-danger { background: rgba(239, 68, 68, 0.12); border: 1px solid rgba(239, 68, 68, 0.6); }
.site-footer { padding: 18px 40px; font-size: 0.8rem; color: var(--muted); border-top: 1px solid rgba(31, 41, 55, 0.8); margin-top: 20px; }

 .timeline-link { display: block; text-decoration: none; color: inherit; }
 .timeline-link:hover .timeline-item { transform: translateY(-3px); border-color: rgba(79, 70, 229, 0.5); }
 .case-detail { max-width: 900px; }
 .case-back-link { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); text-decoration: none; font-weight: 600; margin-bottom: 32px; transition: color var(--transition), transform var(--transition); }
 .case-back-link:hover { color: var(--text); transform: translateX(-4px); }
 .case-header { margin-bottom: 56px; }
 .case-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
 .case-pill { padding: 8px 14px; border-radius: 999px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1); color: var(--muted); font-size: 0.85rem; font-weight: 600; }
 .case-pill-primary { background: rgba(79, 70, 229, 0.12); border-color: rgba(79, 70, 229, 0.3); color: #c7d2fe; }
 .case-section { margin-bottom: 40px; padding: 28px; border-radius: 20px; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
 .case-section h2 { font-size: 1.3rem; margin-bottom: 16px; color: #fff; }
 .case-section p, .case-section li { color: var(--muted); }
 .case-section ul { list-style: none; display: grid; gap: 10px; margin-top: 14px; }
 .case-section li { position: relative; padding-left: 24px; line-height: 1.7; }
 .case-section li::before { content: '→'; position: absolute; left: 0; color: var(--accent-cyan); }
 .results-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin: 24px 0; }
 .result-card { padding: 20px; border-radius: 16px; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08); }
 .result-card .metric { font-size: 2rem; font-weight: 800; color: #fff; margin-bottom: 8px; }
 .result-card .label { color: var(--muted); font-size: 0.92rem; }
 .tech-stack { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
 .tech-tag { padding: 8px 12px; border-radius: 999px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); color: var(--text); font-size: 0.9rem; }
 .case-cta { margin-top: 56px; padding: 32px; border-radius: 24px; background: linear-gradient(135deg, rgba(79,70,229,0.16), rgba(6,182,212,0.1)); border: 1px solid rgba(255,255,255,0.08); text-align: center; }
 .case-cta h3 { font-size: 1.5rem; color: #fff; margin-bottom: 12px; }
 .case-cta p { color: var(--muted); margin-bottom: 24px; }

@keyframes float1 { 0% { transform: translate(0, 0); } 100% { transform: translate(100px, 50px); } }
@keyframes float2 { 0% { transform: translate(0, 0); } 100% { transform: translate(-80px, -60px); } }
@keyframes float3 { 0% { transform: translate(0, 0); } 100% { transform: translate(-50px, 80px); } }
@keyframes wordReveal { 0% { opacity: 0; transform: translateY(100%) rotateX(-45deg); filter: blur(4px); } 100% { opacity: 1; transform: translateY(0) rotateX(0); filter: blur(0); } }
@keyframes drawLine { 0% { transform: scaleX(0); } 100% { transform: scaleX(1); } }
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.5); } }

@media (max-width: 900px) { .hero-header { min-height: 68vh; } }
@media (max-width: 640px) { .site-header { padding: 16px 20px; flex-direction: column; gap: 12px; } .nav a { margin: 0 8px; } .page-shell { padding: 40px 20px 80px; } .contact-form { padding: 20px; } }

.section .leading-relaxed {
    line-height: 1.625;
}

.section .leading-tight {
    line-height: 1.25;
}

.section .mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.section .max-w-xl {
    max-width: 36rem;
}

.section .max-w-2xl {
    max-width: 42rem;
}

.section .max-w-4xl {
    max-width: 56rem;
}

.section .w-full {
    width: 100%;
}

.section .pt-12 {
    padding-top: 3rem;
}

.section .pt-4 {
    padding-top: 1rem;
}

.section .p-6 {
    padding: 1.5rem;
}

.section .px-3 {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.section .py-1 {
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

.section .px-6 {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.section .py-3 {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.section .rounded-full {
    border-radius: 9999px;
}

.section .rounded-xl {
    border-radius: 0.75rem;
}

.section .rounded-lg {
    border-radius: 0.5rem;
}

.section .border {
    border: 1px solid;
}

.section .border-slate-800 {
    border-color: #1e293b;
}

.section .border-blue-500\/30 {
    border-color: rgba(59, 130, 246, 0.3);
}

.section .border-l-4 {
    border-left-width: 4px;
}

.section .border-l-blue-500 {
    border-left-color: #3b82f6;
}

.section .border-l-purple-500 {
    border-left-color: #a855f7;
}

.section .border-l-amber-500 {
    border-left-color: #f59e0b;
}

.section .border-l-emerald-500 {
    border-left-color: #10b981;
}

.section .bg-blue-500\/10 {
    background-color: rgba(59, 130, 246, 0.1);
}

.section .bg-slate-900 {
    background-color: #111827;
}

.section .bg-slate-900\/60 {
    background-color: rgba(17, 24, 39, 0.6);
}

.section .bg-slate-950 {
    background-color: #020617;
}

.section .bg-blue-600 {
    background-color: #2563eb;
}

.section .bg-blue-600:hover,
.section .hover\:bg-blue-500:hover {
    background-color: #3b82f6;
}

.section .bg-slate-900:hover,
.section .hover\:bg-slate-800:hover {
    background-color: #1e293b;
}

.section .text-blue-400 {
    color: #60a5fa;
}

.section .text-purple-400 {
    color: #c084fc;
}

.section .text-amber-400 {
    color: #fbbf24;
}

.section .text-emerald-400 {
    color: #34d399;
}

.section .shadow-lg {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}

.section .shadow-blue-600\/20 {
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.2);
}

.section .transition-colors {
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.section .transition-all {
    transition: all 0.2s ease;
}

.section .hover\:text-blue-400:hover {
    color: #60a5fa;
}

.section .flex {
    display: flex;
}

.section .justify-center {
    justify-content: center;
}

.section .items-center {
    align-items: center;
}

.section .gap-4 {
    gap: 1rem;
}

.section .mb-1 {
    margin-bottom: 0.25rem;
}

.section .mt-1 {
    margin-top: 0.25rem;
}

.section .block {
    display: block;
}

.section .outline-none {
    outline: none;
}

.section .focus\:border-blue-500:focus {
    border-color: #3b82f6;
}

.section .absolute {
    position: absolute;
}

.section .inset-0 {
    inset: 0;
}


.section .relative {
    position: relative;
}

.section .p-2\.5 {
    padding: 0.625rem;
}

.section .rounded {
    border-radius: 0.25rem;
}

.section .w-full {
    width: 100%;
}

.section .text-slate-100 {
    color: #f8fafc;
}

.section .font-semibold {
    font-weight: 600;
}

.section .font-mono {
    font-family: ui-monospace, SFMono-Regular, monospace;
}

.section .uppercase {
    text-transform: uppercase;
}

.section .shadow {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
}

.section .border-emerald-500\/30 {
    border-color: rgba(16, 185, 129, 0.3);
}

.section .bg-slate-950 {
    background-color: #020617;
}

.section .flex-col {
    flex-direction: column;
}

.section .items-center {
    align-items: center;
}

.section .justify-center {
    justify-content: center;
}

.section .p-6 {
    padding: 1.5rem;
}

.section .text-center {
    text-align: center;
}

.section .border-t {
    border-top-width: 1px;
}

.section .border-slate-900 {
    border-color: #0f172a;
}

.section .py-6 {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

.section .mt-auto {
    margin-top: auto;
}

.section .font-mono {
    font-family: ui-monospace, SFMono-Regular, monospace;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.card {
    padding: 18px;
    border-radius: var(--radius);
    background: linear-gradient(to bottom right, #0b1120, #020617);
    border: 1px solid rgba(148, 163, 184, 0.25);
    box-shadow: var(--shadow-soft);
    transition: transform var(--transition), border-color var(--transition);
}
.card:hover {
    transform: translateY(-3px);
    border-color: var(--accent);
}

.service-grid,
.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.timeline {
    border-left: 2px solid rgba(148, 163, 184, 0.4);
    margin-top: 20px;
    padding-left: 20px;
}
.timeline-item {
    margin-bottom: 20px;
    position: relative;
}
.timeline-item::before {
    content: "";
    position: absolute;
    left: -11px;
    top: 4px;
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: var(--accent);
}

.contact-form {
    max-width: 480px;
    margin-top: 20px;
}
.form-row {
    margin-bottom: 16px;
}
label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.9rem;
}
input,
textarea {
    width: 100%;
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid rgba(148, 163, 184, 0.5);
    background: #020617;
    color: var(--text);
}
input:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.flash-container {
    padding: 10px 40px 0;
}
.flash {
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 8px;
    font-size: 0.9rem;
}
.flash-success {
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(34, 197, 94, 0.6);
}
.flash-danger {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.6);
}

.site-footer {
    padding: 18px 40px;
    font-size: 0.8rem;
    color: var(--muted);
    border-top: 1px solid rgba(31, 41, 55, 0.8);
    margin-top: 20px;
}

@media (max-width: 900px) {
    .hero {
        grid-template-columns: minmax(0, 1fr);
    }
    .hero-visual {
        margin-top: 20px;
    }
}
