:root {
    --fm-blue-900: #103b73;
    --fm-blue-700: #1b5fbf;
    --fm-blue-600: #2274d4;
    --fm-blue-100: #eaf3ff;
    --fm-ink: #17243a;
    --fm-muted: #5f6f83;
    --fm-border: #dce7f4;
    --fm-surface: #ffffff;
    --fm-bg: #f5f8fc;
    --fm-green: #16835b;
    --fm-shadow: 0 18px 50px rgba(19, 57, 104, 0.10);
    --fm-radius: 20px;
}

html { scroll-behavior: smooth; }
.sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}
body {
    color: var(--fm-ink);
    background: var(--fm-bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
body.nav-open { overflow: hidden; }
a, button, input, select, textarea { font: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
    outline: 3px solid rgba(34, 116, 212, 0.34);
    outline-offset: 3px;
}
.skip-link {
    position: fixed;
    left: 16px;
    top: -80px;
    z-index: 10000;
    padding: 11px 16px;
    color: #fff;
    background: var(--fm-blue-900);
    border-radius: 10px;
    text-decoration: none;
    font-weight: 800;
}
.skip-link:focus { top: 12px; }

.navbar {
    border-bottom: 1px solid rgba(27, 95, 191, 0.08);
    box-shadow: 0 8px 28px rgba(19, 57, 104, 0.07);
}
.nav-container { max-width: 1180px; min-height: 68px; }
.brand a { display: inline-flex; align-items: center; }
.logo-img { height: 54px; max-width: 190px; object-fit: contain; }
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a {
    margin-left: 0;
    padding: 9px 11px;
    border-radius: 10px;
    white-space: nowrap;
}
.nav-links a:hover, .nav-links a[aria-current="page"] {
    color: var(--fm-blue-900) !important;
    background: var(--fm-blue-100);
}
.nav-links .lang-switch { margin-left: 6px; }
.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--fm-border);
    border-radius: 12px;
    background: #fff;
    color: var(--fm-blue-900);
    cursor: pointer;
    align-items: center;
    justify-content: center;
}
.nav-toggle-lines, .nav-toggle-lines::before, .nav-toggle-lines::after {
    display: block;
    width: 21px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    content: "";
    transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle-lines { position: relative; }
.nav-toggle-lines::before { position: absolute; top: -7px; }
.nav-toggle-lines::after { position: absolute; top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-lines { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-lines::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-lines::after { transform: translateY(-7px) rotate(-45deg); }

.hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 44px;
    padding: clamp(64px, 8vw, 108px) 20px;
    border-radius: 0 0 56px 56px;
    background:
        radial-gradient(circle at 88% 20%, rgba(255,255,255,.18), transparent 24%),
        radial-gradient(circle at 12% 90%, rgba(255,255,255,.12), transparent 22%),
        linear-gradient(135deg, #164f9e 0%, #2d89ef 100%);
}
.hero-content { max-width: 900px; margin: 0 auto; }
.hero h1 {
    margin: 0;
    font-size: clamp(2.15rem, 5.4vw, 4.4rem);
    line-height: 1.06;
    letter-spacing: -0.035em;
}
.hero p { max-width: 760px; margin: 20px auto 0; font-size: clamp(1rem, 2vw, 1.18rem); opacity: .94; }
.hero-eyebrow {
    display: inline-flex;
    margin-bottom: 18px;
    padding: 7px 12px;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 999px;
    background: rgba(255,255,255,.12);
    font-size: .77rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 30px; }
.hero-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 12px 20px;
    border: 2px solid #fff;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 800;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.hero-button:hover { transform: translateY(-2px); }
.hero-button.primary { color: var(--fm-blue-900); background: #fff; box-shadow: 0 12px 25px rgba(0,0,0,.15); }
.hero-button.secondary { color: #fff; background: rgba(255,255,255,.08); }
.hero-trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; margin-top: 24px; }
.hero-trust span { padding: 7px 11px; border-radius: 999px; background: rgba(9,38,75,.22); font-size: .82rem; font-weight: 700; }

.value-strip, .trust-section, .conversion-section {
    max-width: 1120px;
    margin: 0 auto 42px;
    padding: 0 20px;
}
.value-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.value-card, .trust-card, .conversion-card {
    background: #fff;
    border: 1px solid var(--fm-border);
    border-radius: var(--fm-radius);
    box-shadow: var(--fm-shadow);
}
.value-card { padding: 24px; }
.value-number {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    margin-bottom: 16px;
    border-radius: 12px;
    color: #fff;
    background: var(--fm-blue-700);
    font-weight: 900;
}
.value-card h2, .value-card h3 { margin: 0 0 8px; color: var(--fm-blue-900); font-size: 1.1rem; }
.value-card p { margin: 0; color: var(--fm-muted); }

.dashboard-shell { margin-top: 10px; }
.dashboard-header { max-width: 760px; }
.dashboard-header h2 { color: var(--fm-blue-900); font-size: clamp(1.8rem, 3.6vw, 2.5rem); }
.dashboard-panel { border-color: var(--fm-border); box-shadow: var(--fm-shadow); }
.dashboard-panel input, .dashboard-panel select,
.modal-content input, .modal-content select, textarea {
    min-height: 46px;
    color: var(--fm-ink);
    background: #fff;
    border-color: #cbd9e9;
}
.dashboard-panel input:focus, .dashboard-panel select:focus,
.modal-content input:focus, .modal-content select:focus, textarea:focus {
    border-color: var(--fm-blue-600);
    box-shadow: 0 0 0 4px rgba(34, 116, 212, .10);
    outline: none;
}
.privacy-inline { display: flex; gap: 9px; align-items: flex-start; margin: 12px 0 0; color: var(--fm-muted); font-size: .83rem; }
.privacy-inline::before { content: "✓"; color: var(--fm-green); font-weight: 900; }
.dashboard-actions button, .open-btn { min-height: 46px; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.dashboard-actions button:hover, .open-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(27,95,191,.18); }

.tools-intro { margin-top: 58px; }
.tools-intro h2 { color: var(--fm-blue-900); font-size: clamp(1.8rem, 3.4vw, 2.45rem); }
.tool-search-wrap { max-width: 620px; margin: 20px auto 0; position: relative; }
.tool-search-wrap label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
#toolSearch { padding: 14px 18px; border-radius: 14px; border: 1px solid var(--fm-border); box-shadow: 0 8px 24px rgba(19,57,104,.07); }
.tool-search-status { margin: 10px 0 0; min-height: 22px; text-align: center; color: var(--fm-muted); font-size: .88rem; }
.card-gallery { max-width: 1120px; margin: 0 auto; padding: 0 20px; gap: 22px; }
.web-card { min-width: 260px; max-width: none; flex: 1 1 300px; border-color: var(--fm-border); box-shadow: 0 10px 32px rgba(19,57,104,.07); }
.web-card[hidden] { display: none !important; }
.web-card p { min-height: 0; color: var(--fm-muted); }
.web-card h3 { color: var(--fm-blue-900); }
.card-icon i { color: var(--fm-blue-900); background: var(--fm-blue-100); }
.open-btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }

.modal-overlay { padding: 18px; z-index: 3000; }
.modal-content { max-height: min(760px, calc(100vh - 36px)); overflow-y: auto; padding: 36px; border-radius: 22px; }
.close-modal, .close-btn {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: var(--fm-ink);
    background: #eef3f9;
    line-height: 1;
}
.modal-safety {
    margin: 18px 0 0;
    padding: 12px 14px;
    border-radius: 12px;
    color: var(--fm-muted);
    background: #f5f8fc;
    font-size: .78rem;
    line-height: 1.5;
}
.modal-safety a { color: var(--fm-blue-700); font-weight: 700; }
body.modal-open { overflow: hidden; }

.health-notice {
    max-width: 960px;
    margin: 22px auto 32px;
    padding: 18px 20px;
    border: 1px solid #d9e6f5;
    border-left: 5px solid var(--fm-blue-700);
    border-radius: 16px;
    color: #435267;
    background: #f8fbff;
}
.health-notice strong { display: block; margin-bottom: 4px; color: var(--fm-blue-900); }
.health-notice p { margin: 0; }
.editorial-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin: 0 0 24px;
    padding: 14px 16px;
    border: 1px solid var(--fm-border);
    border-radius: 14px;
    color: var(--fm-muted);
    background: #f8fbff;
    font-size: .86rem;
}
.editorial-meta strong { color: var(--fm-ink); }

.trust-section { margin-top: 60px; }
.section-heading { max-width: 720px; margin: 0 auto 24px; text-align: center; }
.section-heading h2 { margin: 0 0 8px; color: var(--fm-blue-900); font-size: clamp(1.8rem, 3.4vw, 2.4rem); }
.section-heading p { margin: 0; color: var(--fm-muted); }
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.trust-card { padding: 22px; }
.trust-card h3 { margin: 0 0 8px; color: var(--fm-blue-900); }
.trust-card p { margin: 0; color: var(--fm-muted); }
.text-link { color: var(--fm-blue-700); font-weight: 800; }

.conversion-card {
    display: grid;
    grid-template-columns: 1.35fr auto;
    gap: 24px;
    align-items: center;
    padding: clamp(24px, 4vw, 40px);
    background: linear-gradient(135deg, #fff 0%, #eef6ff 100%);
}
.conversion-card h2 { margin: 0 0 8px; color: var(--fm-blue-900); font-size: clamp(1.65rem, 3vw, 2.2rem); }
.conversion-card p { margin: 0; color: var(--fm-muted); }
.conversion-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.conversion-actions a { padding: 12px 17px; border-radius: 999px; text-decoration: none; font-weight: 800; }
.conversion-actions .primary { color: #fff; background: var(--fm-blue-700); }
.conversion-actions .secondary { color: var(--fm-blue-900); background: #fff; border: 1px solid var(--fm-border); }

.blog-section { padding: 0 20px; }
.blog-container { max-width: 1080px; margin-left: auto; margin-right: auto; }
.blog-card { border-color: var(--fm-blue-700); box-shadow: 0 10px 30px rgba(19,57,104,.07); }
.banner-container { display: none; }

.main-container { width: 100%; }
.intro-box { max-width: 900px; margin-left: auto; margin-right: auto; }
.article-content, article.page { box-shadow: var(--fm-shadow); border: 1px solid var(--fm-border); border-radius: 20px; }
.article-content img, article.page img { max-width: 100%; height: auto; border-radius: 14px; }
.article-content p, .article-content li { line-height: 1.75; }
.article-content a { color: var(--fm-blue-700); }

footer { border-top: 1px solid var(--fm-border); padding: 40px 20px; }
.footer-inner { max-width: 1080px; margin: 0 auto; display: grid; gap: 14px; }
.footer-brand { margin: 0; color: var(--fm-blue-900); font-weight: 900; }
.footer-note { max-width: 760px; margin: 0 auto; color: var(--fm-muted); font-size: .88rem; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 16px; }
.footer-links a { margin: 0; }
.back-to-top {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 900;
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    color: #fff;
    background: var(--fm-blue-700);
    box-shadow: 0 10px 28px rgba(27,95,191,.28);
    cursor: pointer;
}
.back-to-top.visible { display: grid; place-items: center; }
.support-button {
    position: fixed;
    left: 18px;
    bottom: 18px;
    z-index: 900;
    min-height: 44px;
    padding: 10px 15px;
    border: 1px solid rgba(255,255,255,.32);
    border-radius: 999px;
    color: #fff;
    background: var(--fm-blue-900);
    box-shadow: 0 10px 28px rgba(16,59,115,.25);
    cursor: pointer;
    font-weight: 800;
}
.support-button[disabled] { opacity: .7; cursor: wait; }

@media (max-width: 900px) {
    .nav-container { min-height: 64px; flex-direction: row; gap: 12px; }
    .nav-toggle { display: inline-flex; }
    .nav-links {
        position: fixed;
        inset: 65px 0 auto 0;
        z-index: 2500;
        display: grid;
        gap: 4px;
        max-height: calc(100vh - 65px);
        padding: 14px 20px 24px;
        overflow-y: auto;
        background: #fff;
        border-top: 1px solid var(--fm-border);
        box-shadow: 0 18px 34px rgba(19,57,104,.12);
        transform: translateY(-120%);
        visibility: hidden;
        transition: transform .22s ease, visibility .22s ease;
    }
    .nav-links.is-open { transform: translateY(0); visibility: visible; }
    .nav-links a { padding: 12px 14px; font-size: 1rem; }
    .nav-links .lang-switch { margin: 6px 0 0; text-align: center; }
    .value-grid, .trust-grid { grid-template-columns: 1fr; }
    .conversion-card { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    .logo-img { height: 46px; max-width: 165px; }
    .hero { padding: 58px 18px 68px; border-radius: 0 0 38px 38px; }
    .hero h1 { font-size: clamp(2rem, 11vw, 3rem); }
    .hero-actions { flex-direction: column; }
    .hero-button { width: 100%; }
    .dashboard-shell, .tools-intro { padding-left: 15px; padding-right: 15px; }
    .dashboard-panel { padding: 16px; border-radius: 16px; }
    .card-gallery { padding: 0 15px; }
    .web-card { min-width: 100%; padding: 24px 18px; }
    .modal-overlay { padding: 8px; align-items: flex-end; }
    .modal-content { width: 100%; max-height: calc(100vh - 16px); padding: 30px 18px 22px; border-radius: 20px 20px 12px 12px; }
    .modal-btns { flex-direction: column; }
    .modal-btns button { width: 100%; }
    .conversion-actions { flex-direction: column; }
    .conversion-actions a { text-align: center; }
    .support-button { left: 12px; bottom: 12px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
