/* --- Design System Variables --- */
:root {
    --bg-color: #f5f5f7;
    --surface-color: rgba(245, 245, 247, 0.82);
    --text-primary: #1d1d1f;
    --text-secondary: #6e6e73;
    --accent-color: #0071e3;
    --accent-hover: #0077ed;
    --border-color: rgba(0, 0, 0, 0.08);
    --card-bg: #ffffff;
    --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 8px 32px rgba(0, 0, 0, 0.06);
    --font-sans: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --font-mono: 'SF Mono', 'JetBrains Mono', Consolas, monospace;
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 20px;
}

html { scroll-behavior: smooth; }

/* Suppress all transitions during initial theme application to prevent flash */
html.no-transition * { transition: none !important; }

/* --- Dark Mode --- */
html.dark-mode:root {
    --bg-color: #000000;
    --surface-color: rgba(28, 28, 30, 0.85);
    --text-primary: #f5f5f7;
    --text-secondary: #98989d;
    --accent-color: #2997ff;
    --accent-hover: #3ea6ff;
    --border-color: rgba(255, 255, 255, 0.1);
    --card-bg: #1c1c1e;
    --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 8px 32px rgba(0, 0, 0, 0.4);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: var(--font-sans);
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

a { color: var(--accent-color); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--accent-hover); }

h1, h2, h3, h4 { color: var(--text-primary); font-weight: 700; line-height: 1.1; }
h1 { font-size: 5rem; letter-spacing: -0.04em; }
h2 { font-size: 3rem; letter-spacing: -0.03em; }
h3 { font-size: 1.4rem; letter-spacing: -0.02em; margin-bottom: 0.6rem; }
p { color: var(--text-secondary); line-height: 1.65; margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

code {
    font-family: var(--font-mono);
    background: var(--card-bg);
    padding: 0.2rem 0.4rem;
    border-radius: 5px;
    font-size: 0.875em;
    border: 1px solid var(--border-color);
}

/* --- Skip to content --- */
.skip-to-content {
    position: absolute;
    left: -9999px;
    top: 1rem;
    z-index: 9999;
    padding: 0.5rem 1.25rem;
    background: var(--accent-color);
    color: #fff;
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
}
.skip-to-content:focus { left: 1rem; }

/* --- Utilities --- */
.text-gradient {
    background: linear-gradient(135deg, #2997ff 0%, #eb54df 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.eyebrow {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent-color);
    margin-bottom: 1rem;
}

/* --- Layout --- */
.container {
    width: 100%;
    max-width: 980px;
    margin: 0 auto;
    padding: 0 2rem;
}

main { flex: 1; padding: 5rem 0; }

/* --- Navigation --- */
.site-header {
    border-bottom: 1px solid var(--border-color);
    background-color: var(--surface-color);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.site-header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 3.5rem;
}

.nav-brand {
    display: flex; align-items: center; gap: 0.5rem;
    font-weight: 700; font-size: 1.125rem;
    color: var(--accent-color); text-decoration: none;
    letter-spacing: 0.05em; text-transform: uppercase;
}
.nav-brand:hover { color: var(--accent-color); }
.nav-brand img { height: 1.5rem; width: auto; display: block; }

.nav-links { display: flex; align-items: center; gap: 0.125rem; }
.nav-links a {
    padding: 0.35rem 0.75rem;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 6px;
    transition: color 0.2s ease, background-color 0.2s ease;
}
.nav-links a:hover { color: var(--text-primary); background-color: var(--border-color); }
.nav-links a:focus-visible { outline: 2px solid var(--accent-color); outline-offset: 2px; border-radius: 6px; }
.nav-links a.active { color: var(--text-primary); }

.theme-toggle {
    background: none; border: none; cursor: pointer;
    padding: 0.35rem; margin-left: 0.25rem;
    color: var(--text-secondary); line-height: 0;
    border-radius: 6px;
    transition: color 0.2s ease, background-color 0.2s ease;
}
.theme-toggle svg { width: 1.125rem; height: 1.125rem; display: block; }
.theme-toggle:hover { color: var(--text-primary); background-color: var(--border-color); }
.theme-toggle:focus-visible { outline: 2px solid var(--accent-color); outline-offset: 2px; }

/* --- Icon Visibility --- */
html.dark-mode .theme-toggle .sun-icon { display: block; }
html.dark-mode .theme-toggle .moon-icon { display: none; }
html:not(.dark-mode) .theme-toggle .sun-icon { display: none; }
html:not(.dark-mode) .theme-toggle .moon-icon { display: block; }

/* --- Buttons --- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
    padding: 0.75rem 1.75rem;
    background: var(--accent-color); color: #fff;
    border: 1.5px solid transparent; border-radius: 980px;
    font-size: 0.9375rem; font-weight: 600; font-family: var(--font-sans);
    cursor: pointer; text-decoration: none; white-space: nowrap;
    transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
    -webkit-appearance: none; appearance: none;
}
.btn:hover { background: var(--accent-hover); color: #fff; box-shadow: 0 4px 16px rgba(41, 151, 255, 0.35); }
.btn:active { transform: scale(0.97); }
.btn:focus-visible { outline: 3px solid var(--accent-color); outline-offset: 3px; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }

.btn-outline {
    background: transparent;
    color: var(--accent-color);
    border-color: currentColor;
}
.btn-outline:hover { background: var(--accent-color); color: #fff; box-shadow: 0 4px 16px rgba(0, 113, 227, 0.2); }

.btn-full { width: 100%; }

.cta-group { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; justify-content: center; }

/* --- Hero --- */
.hero {
    text-align: center;
    padding: 6rem 0 5rem;
    position: relative;
    z-index: 1;
}
.hero::before {
    content: '';
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 100%; height: 100%;
    background: radial-gradient(ellipse 80% 60% at center, rgba(41, 151, 255, 0.1) 0%, rgba(235, 84, 223, 0.06) 50%, transparent 75%);
    z-index: -1; pointer-events: none;
}
.hero h1 { margin-bottom: 1.25rem; }
.hero .lead {
    font-size: 1.3rem; max-width: 560px; margin: 0 auto 2.5rem;
    font-weight: 400; line-height: 1.55; letter-spacing: -0.01em;
    color: var(--text-secondary);
}

/* --- Section --- */
.section-header { text-align: center; margin-bottom: 3rem; }
.section-header h2 { margin-bottom: 0.75rem; }
.section-header p { font-size: 1.1rem; max-width: 480px; margin: 0 auto; }

.section-divider {
    border: none;
    border-top: 1px solid var(--border-color);
    margin: 4rem 0;
}

/* --- Service Grid & Cards --- */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 4rem;
}

.service-card {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--card-shadow);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}
.service-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06), 0 24px 52px rgba(0, 0, 0, 0.1);
}
html.dark-mode .service-card:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3), 0 24px 52px rgba(0, 0, 0, 0.5);
}
.service-card p { font-size: 0.9375rem; margin-bottom: 0; }

.service-graphic {
    width: 100%; height: 188px;
    object-fit: cover;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    display: block;
    border: 1px solid var(--border-color);
}

/* .dynamic-box / .status-dot removed — unused */

/* --- About Page --- */
.about-hero { padding: 6rem 0 2rem; }
.about-lead {
    font-size: 1.5rem; font-weight: 400;
    color: var(--text-primary);
    max-width: 640px; line-height: 1.5;
    letter-spacing: -0.02em;
    margin-top: 1.5rem;
}

.about-mission {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: start;
    padding: 1rem 0;
}
.about-mission h2 { font-size: 2.25rem; margin-bottom: 1.25rem; }
.about-mission p { font-size: 1rem; line-height: 1.75; }

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin: 3rem 0;
}
.value-card {
    padding: 1.75rem 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--card-shadow);
}
.value-icon {
    display: block;
    width: 2.5rem; height: 2.5rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
}
.value-card h3 { font-size: 1.05rem; margin-bottom: 0.5rem; }
.value-card p { font-size: 0.875rem; margin-bottom: 0; }

/* --- Contact Page --- */
.contact-note {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: rgba(0, 113, 227, 0.06);
    border: 1px solid rgba(0, 113, 227, 0.2);
    border-radius: var(--radius-md);
    margin-bottom: 2rem;
    font-size: 0.875rem;
    color: var(--accent-color);
    line-height: 1.5;
}
html.dark-mode .contact-note {
    background: rgba(41, 151, 255, 0.08);
    border-color: rgba(41, 151, 255, 0.2);
    color: var(--accent-color);
}
.contact-note svg { flex-shrink: 0; margin-top: 0.1rem; }

/* --- Forms --- */
.form-group { margin-bottom: 1.25rem; }
.form-group-header { display: flex; justify-content: space-between; align-items: baseline; }
.form-group label {
    display: block; margin-bottom: 0.4rem;
    font-weight: 500; font-size: 0.875rem; color: var(--text-primary);
}
.form-control {
    width: 100%; padding: 0.8125rem 1rem;
    background: var(--card-bg); color: var(--text-primary);
    border: 1px solid var(--border-color); border-radius: var(--radius-sm);
    font-family: var(--font-sans); font-size: 0.9375rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    -webkit-appearance: none; appearance: none;
}
.form-control:focus {
    outline: none; border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.15);
}
.form-control:disabled {
    opacity: 0.45; cursor: not-allowed;
    background: var(--bg-color);
}
textarea.form-control { resize: vertical; min-height: 120px; }

/* --- Error Page --- */
.error-hero { text-align: center; padding-top: 8rem; }
.error-code {
    font-size: 7.5rem; margin-bottom: 0.25rem; line-height: 1;
    font-weight: 800; letter-spacing: -0.05em;
}
.error-title {
    font-size: 2rem; font-weight: 600;
    color: var(--text-primary); margin-bottom: 0.75rem;
    letter-spacing: -0.025em;
}
.error-hero > p { margin-bottom: 2.5rem; font-size: 1.1rem; }

/* --- Footer --- */
.site-footer {
    border-top: 1px solid var(--border-color);
    padding: 2.5rem 0;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.footer-links { display: flex; gap: 1.5rem; }
.footer-links a {
    color: var(--text-secondary);
    font-size: 0.8125rem;
    transition: color 0.2s ease;
}
.footer-links a:hover { color: var(--text-primary); }

/* --- Linked Service Cards --- */
a.service-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}
a.service-card-link:hover { color: inherit; }
.card-cta {
    display: block;
    margin-top: auto;
    padding-top: 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent-color);
    letter-spacing: -0.01em;
}

/* --- Services Page Jump Nav --- */
.services-nav {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 2rem 0 0;
}
.services-nav a {
    padding: 0.4rem 1rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 980px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}
.services-nav a:hover {
    color: var(--text-primary);
    border-color: var(--accent-color);
    background: var(--bg-color);
}
.services-nav a:focus-visible {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* --- Service Section --- */
.service-section { scroll-margin-top: 5rem; }
.service-section-header { margin-bottom: 2.5rem; }
.service-section-header h2 { margin-bottom: 0.5rem; }
.service-section-header p { font-size: 1.05rem; max-width: 540px; }

/* --- Portfolio Showcase (within Software section) --- */
.portfolio-showcase {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 3rem;
    align-items: start;
    margin-top: 2.5rem;
    padding: 2.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--card-shadow);
}
.portfolio-label { display: flex; flex-direction: column; gap: 0; }
.portfolio-label .eyebrow { margin-bottom: 0.5rem; }
.portfolio-label h3 { font-size: 1.75rem; margin-bottom: 0.75rem; }
.portfolio-label p { font-size: 0.9375rem; line-height: 1.7; margin-bottom: 1.25rem; }
.portfolio-tags {
    display: flex; flex-wrap: wrap; gap: 0.5rem;
    list-style: none; padding: 0; margin: 0 0 1.75rem;
}
.portfolio-tags li {
    padding: 0.3rem 0.75rem;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 980px;
    font-size: 0.75rem; font-weight: 600;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
}
.portfolio-actions { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }

.portfolio-visual { display: flex; flex-direction: column; gap: 1.25rem; }
.portfolio-icon {
    width: 5rem; height: 5rem;
    border-radius: 1.125rem;
    display: block;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}
.portfolio-screenshot {
    width: 100%; display: block;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    transition: box-shadow 0.3s ease;
}
.portfolio-screenshot:hover {
    box-shadow: 0 8px 40px rgba(0,0,0,0.14);
}
html.dark-mode .portfolio-screenshot:hover {
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

/* --- App Store Badge --- */
.appstore-badge {
    display: inline-block;
    line-height: 0;
    transition: opacity 0.2s ease, transform 0.15s ease;
}
.appstore-badge:hover { opacity: 0.85; transform: scale(1.02); }
.appstore-badge img { height: 2.75rem; width: auto; display: block; }

/* --- App Screenshot --- */
.app-screenshot-wrap {
    margin: 3rem 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px rgba(0,0,0,0.10), 0 32px 80px rgba(0,0,0,0.08);
}
html.dark-mode .app-screenshot-wrap {
    box-shadow: 0 8px 32px rgba(0,0,0,0.4), 0 32px 80px rgba(0,0,0,0.5);
}
.app-screenshot-wrap img {
    width: 100%; display: block;
}

/* --- Product Hero with icon --- */
.product-icon-img {
    width: 6.5rem; height: 6.5rem;
    border-radius: 1.5rem;
    display: block;
    margin: 0 auto 1.75rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
}

/* --- Applications Page --- */
.apps-hero {
    text-align: center;
    padding: 5rem 0 3rem;
}
.apps-hero h1 { margin-bottom: 1rem; }
.apps-hero .lead {
    font-size: 1.2rem; max-width: 520px; margin: 0 auto;
    color: var(--text-secondary); line-height: 1.55;
}

.app-card {
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 4rem;
    align-items: start;
    padding: 3rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--card-shadow);
    margin-bottom: 2rem;
}
.app-card-info { display: flex; flex-direction: column; gap: 1.25rem; }
.app-card-icon {
    width: 5rem; height: 5rem;
    border-radius: 1.125rem;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #2997ff 0%, #eb54df 100%);
    color: #fff;
    flex-shrink: 0;
}
.app-card-icon svg { width: 2.75rem; height: 2.75rem; }
.app-card-title { margin: 0; }
.app-card-tagline { margin: 0; font-size: 0.9375rem; }
.app-card-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 0.5rem; }

.app-features-preview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.app-feature-item {
    padding: 1.25rem;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}
.app-feature-item h4 {
    font-size: 0.875rem; font-weight: 600;
    color: var(--text-primary); margin-bottom: 0.35rem;
}
.app-feature-item p { font-size: 0.8125rem; margin: 0; }

.coming-soon-card {
    text-align: center;
    padding: 3rem 2rem;
    background: var(--card-bg);
    border: 1px dashed var(--border-color);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
}
.coming-soon-card h3 { font-size: 1.1rem; color: var(--text-secondary); margin-bottom: 0.5rem; }
.coming-soon-card p { font-size: 0.9rem; margin: 0; }

/* --- Product Page (TextMerger) --- */
.product-hero {
    text-align: center;
    padding: 5rem 0 4rem;
    position: relative;
    z-index: 1;
}
.product-hero::before {
    content: '';
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 100%; height: 100%;
    background: radial-gradient(ellipse 70% 60% at center, rgba(41, 151, 255, 0.08) 0%, rgba(235, 84, 223, 0.05) 50%, transparent 75%);
    z-index: -1; pointer-events: none;
}
.product-icon {
    width: 6.5rem; height: 6.5rem;
    border-radius: 1.5rem;
    display: inline-flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #2997ff 0%, #eb54df 100%);
    color: #fff;
    margin: 0 auto 2rem;
    box-shadow: 0 8px 32px rgba(41, 151, 255, 0.25);
}
.product-icon svg { width: 3.5rem; height: 3.5rem; }
.product-hero h1 { margin-bottom: 1rem; }
.product-hero .tagline {
    font-size: 1.25rem; max-width: 560px; margin: 0 auto 2.5rem;
    color: var(--text-secondary); line-height: 1.55;
}
.product-badges {
    display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; margin-bottom: 0.5rem;
}
.badge {
    display: inline-flex; align-items: center; gap: 0.4rem;
    padding: 0.35rem 0.875rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 980px;
    font-size: 0.8125rem; font-weight: 500;
    color: var(--text-secondary);
}
.badge svg { width: 0.9rem; height: 0.9rem; color: var(--accent-color); }

.features-section {
    padding: 2rem 0 3rem;
}
.features-section > .section-header { margin-bottom: 2.5rem; }

.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
    margin-bottom: 3rem;
}
.feature-card {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--card-shadow);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06), 0 24px 52px rgba(0, 0, 0, 0.1);
}
html.dark-mode .feature-card:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3), 0 24px 52px rgba(0, 0, 0, 0.5);
}
.feature-icon-wrap {
    width: 2.75rem; height: 2.75rem;
    background: rgba(41, 151, 255, 0.1);
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 1.25rem;
    color: var(--accent-color);
}
html.dark-mode .feature-icon-wrap {
    background: rgba(41, 151, 255, 0.15);
}
.feature-icon-wrap svg { width: 1.375rem; height: 1.375rem; }
.feature-card h3 { font-size: 1.05rem; margin-bottom: 0.75rem; }
.feature-card ul {
    list-style: none; padding: 0; margin: 0;
    display: flex; flex-direction: column; gap: 0.4rem;
}
.feature-card ul li {
    font-size: 0.875rem; color: var(--text-secondary);
    padding-left: 1rem; position: relative; line-height: 1.5;
}
.feature-card ul li::before {
    content: '·'; position: absolute; left: 0;
    color: var(--accent-color); font-weight: 700;
}

.spec-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 3rem;
}
.spec-card {
    padding: 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
}
.spec-card .spec-value {
    font-size: 1.75rem; font-weight: 700;
    color: var(--accent-color); letter-spacing: -0.03em;
    display: block; margin-bottom: 0.25rem;
}
.spec-card .spec-label {
    font-size: 0.8125rem; color: var(--text-secondary);
}

.product-cta {
    text-align: center;
    padding: 3.5rem 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    margin-bottom: 1rem;
}
.product-cta h2 { margin-bottom: 0.75rem; font-size: 2rem; }
.product-cta p { max-width: 420px; margin: 0 auto 2rem; }

/* --- Legal / Privacy Page --- */
.legal-hero {
    padding: 4rem 0 2.5rem;
}
.legal-hero h1 { font-size: 3rem; margin-bottom: 0.75rem; }
.legal-meta {
    font-size: 0.875rem; color: var(--text-secondary);
    margin: 0;
}

.legal-content {
    max-width: 700px;
    padding-bottom: 4rem;
}
.legal-content h2 {
    font-size: 1.35rem; margin: 2.5rem 0 0.75rem;
    color: var(--text-primary);
}
.legal-content h3 {
    font-size: 1.05rem; margin: 1.75rem 0 0.5rem;
    color: var(--text-primary);
}
.legal-content p {
    font-size: 0.9375rem; line-height: 1.75;
    color: var(--text-secondary);
}
.legal-content ul {
    margin: 0.5rem 0 1rem 1.5rem;
}
.legal-content ul li {
    font-size: 0.9375rem; color: var(--text-secondary);
    line-height: 1.65; margin-bottom: 0.35rem;
}
.legal-highlight {
    padding: 1.25rem 1.5rem;
    background: rgba(41, 151, 255, 0.06);
    border: 1px solid rgba(41, 151, 255, 0.18);
    border-radius: var(--radius-md);
    margin: 1.5rem 0;
}
html.dark-mode .legal-highlight {
    background: rgba(41, 151, 255, 0.08);
}
.legal-highlight p {
    margin: 0; font-size: 0.9375rem;
    color: var(--accent-color); font-weight: 500;
}

.compliance-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin: 1rem 0 1.5rem;
}
.compliance-badge {
    padding: 0.75rem 1rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.8125rem; font-weight: 600;
    color: var(--text-primary); text-align: center;
}

/* --- Mobile --- */
@media (max-width: 768px) {
    h1 { font-size: 2.75rem; }
    h2 { font-size: 2rem; }

    main { padding: 3rem 0; }
    .container { padding: 0 1.25rem; }

    .hero { padding: 4rem 0 3rem; }
    .hero .lead { font-size: 1.1rem; }

    .grid { grid-template-columns: 1fr; gap: 1rem; }
    .values-grid { grid-template-columns: 1fr; }
    .about-mission { grid-template-columns: 1fr; gap: 2rem; }
    .cta-group { flex-direction: column; align-items: stretch; }
    .cta-group .btn { text-align: center; }

    .dynamic-box { flex-direction: column; align-items: flex-start; gap: 0.5rem; }

    .footer-inner { flex-direction: column; align-items: flex-start; }

    .error-hero { padding-top: 4rem; }
    .error-code { font-size: 5rem; }
    .error-title { font-size: 1.5rem; }

    .portfolio-showcase { grid-template-columns: 1fr; gap: 2rem; padding: 1.75rem; }
    .portfolio-visual { flex-direction: row; align-items: center; flex-wrap: wrap; }
    .portfolio-icon { width: 4rem; height: 4rem; }
    .appstore-badge img { height: 2.25rem; }
    .product-icon-img { width: 5rem; height: 5rem; }
    .app-card { grid-template-columns: 1fr; gap: 2rem; padding: 1.75rem; }
    .app-features-preview { grid-template-columns: 1fr; }

    .feature-grid { grid-template-columns: 1fr; }
    .spec-grid { grid-template-columns: 1fr 1fr; }

    .legal-hero h1 { font-size: 2rem; }
    .compliance-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   DESIGN ENHANCEMENTS — Animations, Trust Strip, Form States
   ============================================================ */

/* --- Scroll Reveal Animations --- */
.animate-in {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 0.65s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}
.animate-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger grid children */
.grid.animate-stagger .service-card:nth-child(1) { transition-delay: 0s; }
.grid.animate-stagger .service-card:nth-child(2) { transition-delay: 0.1s; }
.grid.animate-stagger .service-card:nth-child(3) { transition-delay: 0.2s; }
.grid.animate-stagger .service-card:nth-child(4) { transition-delay: 0.3s; }

/* .trust-strip / .trust-item removed — unused */

/* --- Enhanced Hero Background --- */
.hero {
    overflow: hidden;
}
.hero::after {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 55%;
    height: 130%;
    background: radial-gradient(ellipse 60% 55% at 70% 40%,
        rgba(235, 84, 223, 0.09) 0%,
        rgba(41, 151, 255, 0.05) 50%,
        transparent 75%);
    z-index: -1;
    pointer-events: none;
}

/* --- Service Card — gradient top accent on hover --- */
a.service-card-link {
    border-top: 2px solid transparent;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                border-top-color 0.3s ease;
}
a.service-card-link:hover {
    border-top-color: var(--accent-color);
}

/* --- Button Shimmer Effect --- */
.btn {
    position: relative;
    overflow: hidden;
}
.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.16), transparent);
    transform: skewX(-20deg);
    transition: left 0.55s ease;
    pointer-events: none;
}
.btn:hover::after { left: 160%; }

/* --- Product CTA subtle gradient fill --- */
.product-cta {
    position: relative;
    overflow: hidden;
}
.product-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,
        rgba(41, 151, 255, 0.03) 0%,
        rgba(235, 84, 223, 0.03) 100%);
    pointer-events: none;
}

/* --- Form Validation States --- */
.form-group.has-error .form-control {
    border-color: #ff3b30;
    box-shadow: 0 0 0 3px rgba(255, 59, 48, 0.12);
}
.form-group.has-success .form-control {
    border-color: #34c759;
    box-shadow: 0 0 0 3px rgba(52, 199, 89, 0.12);
}

/* Per-field inline error messages */
.field-error {
    display: flex;
    align-items: flex-start;
    gap: 0.45rem;
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.45;
    margin-top: 0.5rem;
    border-radius: 8px;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.22s ease, max-height 0.28s ease, padding 0.22s ease;
}
.field-error.visible {
    max-height: 5rem;
    opacity: 1;
    padding: 0.5rem 0.75rem;
    /* Solid pink-red background — unmistakably an alert, not a text style */
    color: #991b1b;
    background: #fef2f2;
    border: 1px solid #fca5a5;
}
/* Red "!" badge — CSS-only, no extra markup */
.field-error::before {
    content: '!';
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background: #dc2626;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 800;
    line-height: 1;
    margin-top: 0.1rem;
}
/* Dark mode */
html.dark-mode .field-error.visible {
    color: #fca5a5;
    background: rgba(127, 29, 29, 0.35);
    border-color: rgba(239, 68, 68, 0.45);
}
html.dark-mode .field-error::before { background: #ef4444; }

/* Required field asterisk */
span.req {
    text-decoration: none !important;
    color: #dc2626 !important;
    font-weight: 700;
    margin-left: 0.2rem;
}
html.dark-mode span.req { color: #f87171 !important; }

.form-required-note {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin: 0 0 1.5rem;
}

/* --- Character Counter States --- */
.char-counter {
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: color 0.2s ease;
    font-variant-numeric: tabular-nums;
}
.char-counter.warning { color: #ff9500; }
.char-counter.danger  { color: #ff3b30; font-weight: 600; }

/* --- Honeypot (invisible to real users) --- */
.hp-field {
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    opacity: 0 !important;
    overflow: hidden !important;
    pointer-events: none !important;
    visibility: hidden !important;
    tab-size: 0;
}

/* --- Form Success State --- */
.form-success-state {
    padding: 2.5rem 2rem;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.form-success-state.visible {
    opacity: 1;
    transform: translateY(0);
}
.success-heading {
    font-size: 2.25rem;
    margin: 0.5rem 0 1rem;
    letter-spacing: -0.03em;
    line-height: 1.1;
}
.success-body {
    font-size: 1rem;
    margin: 0;
    max-width: 340px;
}

/* --- Mobile Trust Strip --- */
@media (max-width: 768px) {
    .trust-strip { gap: 0.5rem 1.25rem; justify-content: center; }
}

/* --- Cart nav icon --- */
.nav-cart {
    position: relative; display: inline-flex; align-items: center;
    color: var(--text-secondary); transition: color 0.2s;
}
.nav-cart:hover { color: var(--accent-color); }
.cart-badge {
    position: absolute; top: -6px; right: -8px;
    background: var(--accent-color); color: #fff;
    font-size: 0.65rem; font-weight: 700; line-height: 1;
    min-width: 16px; height: 16px; border-radius: 8px;
    display: none; align-items: center; justify-content: center;
    padding: 0 4px;
}

/* ── Fade-in for dynamically rendered content (skeleton → live data) ── */
@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: none; }
}
.fade-in { animation: fadeSlideIn 0.32s cubic-bezier(0.16, 1, 0.3, 1) both; }
.fade-in-stagger > * { animation: fadeSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) both; }
.fade-in-stagger > *:nth-child(1)  { animation-delay: 0ms; }
.fade-in-stagger > *:nth-child(2)  { animation-delay: 30ms; }
.fade-in-stagger > *:nth-child(3)  { animation-delay: 60ms; }
.fade-in-stagger > *:nth-child(4)  { animation-delay: 90ms; }
.fade-in-stagger > *:nth-child(5)  { animation-delay: 120ms; }
.fade-in-stagger > *:nth-child(6)  { animation-delay: 150ms; }
.fade-in-stagger > *:nth-child(7)  { animation-delay: 180ms; }
.fade-in-stagger > *:nth-child(8)  { animation-delay: 210ms; }
.fade-in-stagger > *:nth-child(n+9)  { animation-delay: 240ms; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .fade-in, .fade-in-stagger > * { animation: none; }
    .topbar { display: none !important; }
}

/* ── Top progress bar (global loading indicator) ── */
.topbar {
    position: fixed;
    top: 0; left: 0;
    height: 2px; width: 0;
    background: linear-gradient(90deg, var(--accent-color), #eb54df);
    z-index: 10000; pointer-events: none;
    opacity: 1;
    box-shadow: 0 0 10px rgba(41,151,255,0.5);
    transition: width 0.25s ease-out, opacity 0.3s ease-out;
}
.topbar.creep { animation: topbarCreep 12s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
.topbar.done { width: 100%; opacity: 0; }
@keyframes topbarCreep {
    0%   { width: 0; }
    20%  { width: 35%; }
    50%  { width: 65%; }
    80%  { width: 82%; }
    100% { width: 88%; }
}

