/* Patch 1266 — Homepage product-story upgrade: workflow, comparison and animated MedFam AI demo. */
.mfn-story-section{max-width:1180px;margin:96px auto 0;padding:0 24px;position:relative;min-width:0}
.mfn-story-head{display:grid;grid-template-columns:minmax(0,1fr) minmax(280px,.78fr);gap:64px;align-items:end;margin-bottom:34px}
.mfn-story-head>div>span{display:inline-block;color:#078b8d;font-size:12px;font-weight:700;margin-bottom:10px}
.mfn-story-head h2{margin:0;color:#092f4c;font-size:34px;line-height:1.62;font-weight:700;letter-spacing:-.02em}
.mfn-story-head>p{margin:0;color:#647989;font-size:13px;line-height:2.05}

/* MedFamNet in action */
.mfn-workflow{padding-top:10px}
.mfn-workflow-shell{position:relative;border:1px solid #dfeaed;border-radius:28px;background:linear-gradient(180deg,#fff,#f8fbfc);padding:42px 34px 34px;box-shadow:0 22px 60px #0a35450d;overflow:hidden}
.mfn-workflow-shell::before{content:"";position:absolute;width:390px;height:390px;border-radius:50%;background:radial-gradient(circle,#18b6ad13,transparent 67%);left:-170px;top:-180px;pointer-events:none}
.mfn-workflow-line{position:absolute;top:82px;right:9%;left:9%;height:3px;background:#e4ecef;border-radius:99px;overflow:hidden;z-index:0}
.mfn-workflow-line i{display:block;height:100%;width:0;background:linear-gradient(90deg,#16b9b2,#087d91,#1568aa);border-radius:99px;transition:width 1.15s cubic-bezier(.2,.8,.2,1)}
.mfn-workflow.is-visible .mfn-workflow-line i{width:100%}
.mfn-workflow-steps{position:relative;z-index:1;list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:11px}
.mfn-workflow-steps li{min-width:0;text-align:center;opacity:.38;transform:translateY(12px);transition:opacity .42s ease,transform .42s ease}
.mfn-workflow.is-visible .mfn-workflow-steps li{opacity:1;transform:none}
.mfn-workflow.is-visible .mfn-workflow-steps li:nth-child(2){transition-delay:.12s}.mfn-workflow.is-visible .mfn-workflow-steps li:nth-child(3){transition-delay:.24s}.mfn-workflow.is-visible .mfn-workflow-steps li:nth-child(4){transition-delay:.36s}.mfn-workflow.is-visible .mfn-workflow-steps li:nth-child(5){transition-delay:.48s}.mfn-workflow.is-visible .mfn-workflow-steps li:nth-child(6){transition-delay:.6s}
.mfn-workflow-steps li>b{position:relative;width:48px;height:48px;margin:0 auto 17px;border-radius:16px;display:grid;place-items:center;background:#fff;border:1px solid #cfe1e5;color:#0b8081;font-size:11px;box-shadow:0 9px 24px #0c596a13}
.mfn-workflow-steps li:nth-child(4)>b,.mfn-workflow-steps li:nth-child(6)>b{background:linear-gradient(135deg,#0ba9a5,#0b718b);border-color:transparent;color:#fff;box-shadow:0 13px 28px #0a8c9328}
.mfn-workflow-steps li>span{display:block;color:#143c56;font-size:12px;font-weight:700;margin-bottom:8px}
.mfn-workflow-steps li>p{margin:0;color:#718491;font-size:9.5px;line-height:1.95}
.mfn-workflow-note{margin:18px 12px 0;display:flex;align-items:center;gap:12px;justify-content:center;color:#56707f}
.mfn-workflow-note>i{font-style:normal;width:36px;height:36px;border-radius:12px;background:#e8f7f5;color:#07837f;display:grid;place-items:center;font-size:19px}
.mfn-workflow-note>div{display:flex;flex-direction:column;gap:2px}.mfn-workflow-note b{font-size:11px;color:#18475b}.mfn-workflow-note span{font-size:9px}

/* comparison */
.mfn-compare-story{padding:64px 44px 46px;border-radius:32px;background:linear-gradient(145deg,#0d1f30,#122d42 62%,#0d2836);color:#fff;overflow:hidden;box-shadow:0 24px 70px #09223420}
.mfn-compare-story::before{content:"";position:absolute;width:480px;height:480px;border-radius:50%;background:radial-gradient(circle,#13bcb51b,transparent 67%);right:-180px;top:-210px;pointer-events:none}
.mfn-compare-story .mfn-story-head{position:relative;z-index:1}.mfn-compare-story .mfn-story-head>div>span{color:#6bddd5}.mfn-compare-story .mfn-story-head h2{color:#fff}.mfn-compare-story .mfn-story-head>p{color:#b3c5d0}
.mfn-compare-table{position:relative;z-index:1;border:1px solid #ffffff18;border-radius:22px;overflow:hidden;background:#ffffff06;box-shadow:inset 0 1px #ffffff0a}
.mfn-compare-head,.mfn-compare-row{display:grid;grid-template-columns:1fr 1fr;min-width:0}
.mfn-compare-head{background:#ffffff0b;border-bottom:1px solid #ffffff16}.mfn-compare-head span,.mfn-compare-head b{padding:15px 20px;font-size:11px}.mfn-compare-head span{color:#96aab6;font-weight:500}.mfn-compare-head b{color:#69e0d7;border-right:1px solid #ffffff12}
.mfn-compare-row{border-bottom:1px solid #ffffff0e;opacity:.4;transform:translateY(8px);transition:opacity .4s ease,transform .4s ease}.mfn-compare-row:last-child{border-bottom:0}.mfn-compare-story.is-visible .mfn-compare-row{opacity:1;transform:none}.mfn-compare-story.is-visible .mfn-compare-row:nth-child(3){transition-delay:.1s}.mfn-compare-story.is-visible .mfn-compare-row:nth-child(4){transition-delay:.2s}.mfn-compare-story.is-visible .mfn-compare-row:nth-child(5){transition-delay:.3s}.mfn-compare-story.is-visible .mfn-compare-row:nth-child(6){transition-delay:.4s}
.mfn-compare-row span,.mfn-compare-row b{min-width:0;padding:17px 20px;display:flex;align-items:center;gap:10px;font-size:10.5px;line-height:1.9}
.mfn-compare-row span{color:#aabac4;font-weight:400}.mfn-compare-row b{color:#eefbfb;border-right:1px solid #ffffff0e;font-weight:600;background:linear-gradient(90deg,#0ab3aa08,transparent)}
.mfn-compare-row i{font-style:normal;width:25px;height:25px;flex:0 0 25px;border-radius:8px;display:grid;place-items:center;font-size:10px}.mfn-compare-row span i{background:#ffffff09;color:#8196a3}.mfn-compare-row b i{background:#10b8af18;border:1px solid #3dd6cd25;color:#69ddd5}

/* AI interactive demo */
.mfn-ai-live{margin-bottom:20px;padding:56px;border:1px solid #e0ebee;border-radius:32px;background:linear-gradient(145deg,#fbfdfd,#f4faf9);box-shadow:0 22px 65px #0b3e4b0c;overflow:hidden}
.mfn-ai-live::before{content:"";position:absolute;width:360px;height:360px;border-radius:50%;background:radial-gradient(circle,#0cb8ad13,transparent 68%);left:-130px;bottom:-180px;pointer-events:none}
.mfn-ai-live-shell{position:relative;z-index:1;display:grid;grid-template-columns:minmax(0,1.28fr) minmax(290px,.72fr);gap:20px;align-items:stretch}
.mfn-ai-live-presets{grid-column:1/-1;display:flex;gap:8px;flex-wrap:wrap}
.mfn-ai-live-presets button{border:1px solid #d8e7e9;background:#fff;color:#587180;border-radius:999px;padding:9px 14px;font:600 10px inherit;cursor:pointer;transition:background .2s ease,border-color .2s ease,color .2s ease,transform .2s ease}
.mfn-ai-live-presets button:hover{transform:translateY(-1px);border-color:#9fd5d1}.mfn-ai-live-presets button.active{background:#0b827f;color:#fff;border-color:#0b827f;box-shadow:0 9px 20px #0b827f24}
.mfn-ai-live-console{min-width:0;border-radius:23px;background:linear-gradient(150deg,#0d2032,#112b3e 60%,#103448);color:#fff;padding:20px;box-shadow:0 24px 48px #0b2c3b25;overflow:hidden}
.mfn-ai-live-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-bottom:14px;border-bottom:1px solid #ffffff12}.mfn-ai-live-bar>span{font-size:12px;font-weight:700;color:#75e1da}.mfn-ai-live-bar>i{font-style:normal;color:#8ea8b6;font-size:8px;border:1px solid #ffffff14;border-radius:999px;padding:5px 8px}
.mfn-ai-live-query{position:relative;margin-top:18px;background:#ffffff0a;border:1px solid #ffffff12;border-radius:16px;padding:14px 16px;min-height:82px}.mfn-ai-live-query small{display:block;color:#5ed5ce;font-size:8px;margin-bottom:6px}.mfn-ai-live-query p{margin:0!important;color:#f2f8fa!important;font-size:13px!important;line-height:1.95!important;min-height:25px}.mfn-ai-caret{display:inline-block;width:7px;height:15px;background:#67dcd4;margin-right:3px;vertical-align:-3px;animation:mfn1266Caret .8s steps(1) infinite}@keyframes mfn1266Caret{50%{opacity:0}}
.mfn-ai-live-answer{margin-top:11px;min-height:224px;border-radius:17px;background:#f8fbfc;color:#16374d;padding:16px;position:relative;overflow:hidden}
.mfn-ai-live-thinking{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;gap:5px;color:#66808f;font-size:9px;background:#f8fbfc;opacity:0;pointer-events:none;transition:opacity .18s ease;z-index:2}.mfn-ai-live-thinking.show{opacity:1}.mfn-ai-live-thinking i{width:6px;height:6px;border-radius:50%;background:#0ca59f;animation:mfn1266Dot 1s ease-in-out infinite}.mfn-ai-live-thinking i:nth-child(2){animation-delay:.15s}.mfn-ai-live-thinking i:nth-child(3){animation-delay:.3s}.mfn-ai-live-thinking span{margin-right:7px}@keyframes mfn1266Dot{0%,100%{transform:translateY(0);opacity:.35}50%{transform:translateY(-4px);opacity:1}}
.mfn-ai-live-result{opacity:1;transform:none;transition:opacity .2s ease,transform .2s ease}.mfn-ai-live-result.muted{opacity:.2;transform:translateY(6px)}.mfn-ai-live-result>small{display:block;color:#0a9089;font-size:8px;font-weight:700}.mfn-ai-live-result>strong{display:block;margin:7px 0 12px;color:#14384e;font-size:12px;line-height:1.8}.mfn-ai-live-result ul{list-style:none;margin:0;padding:0}.mfn-ai-live-result li{position:relative;margin:7px 0;padding:8px 34px 8px 10px;background:#fff;border:1px solid #e0eaed;border-radius:11px;color:#587080;font-size:9.5px;line-height:1.75;opacity:1;transform:none;transition:opacity .25s ease,transform .25s ease}.mfn-ai-live-result li::before{content:"✓";position:absolute;right:10px;top:8px;width:17px;height:17px;border-radius:6px;background:#e2f7f4;color:#087c77;display:grid;place-items:center;font-size:8px;font-weight:800}.mfn-ai-live-result li.enter{opacity:0;transform:translateY(5px)}
.mfn-ai-live-foot{display:flex;gap:6px;flex-wrap:wrap;margin-top:12px}.mfn-ai-live-foot span{border:1px solid #ffffff12;background:#ffffff08;color:#aac0cc;border-radius:999px;padding:5px 7px;font-size:7px;direction:ltr}
.mfn-ai-live-side{min-width:0;border-radius:23px;background:#fff;border:1px solid #dde9eb;padding:20px;display:flex;flex-direction:column;gap:9px}.mfn-ai-live-side>span{color:#0b8580;font-size:10px;font-weight:700;margin-bottom:3px}.mfn-ai-live-side article{display:flex;gap:11px;padding:13px 0;border-bottom:1px solid #edf2f3}.mfn-ai-live-side article:last-of-type{border-bottom:0}.mfn-ai-live-side article>i{font-style:normal;width:34px;height:34px;flex:0 0 34px;border-radius:11px;background:#e9f7f6;color:#087f7c;display:grid;place-items:center;font-size:9px;font-weight:800}.mfn-ai-live-side article b{display:block;color:#173e54;font-size:11px;margin-bottom:5px}.mfn-ai-live-side article p{margin:0;color:#6c818d;font-size:9px;line-height:1.9}.mfn-ai-live-side>.btn{margin-top:auto;box-shadow:none;min-height:45px;text-align:center}

[data-mfn-reveal]{opacity:.98}.mfn-story-section:not(.is-visible) .mfn-story-head{opacity:.6;transform:translateY(8px)}.mfn-story-head{transition:opacity .45s ease,transform .45s ease}.mfn-story-section.is-visible .mfn-story-head{opacity:1;transform:none}

@media(max-width:1050px){
  .mfn-story-head{grid-template-columns:1fr;gap:13px;text-align:center}.mfn-story-head h2{max-width:760px;margin-inline:auto}.mfn-story-head>p{max-width:760px;margin-inline:auto}
  .mfn-workflow-steps{grid-template-columns:repeat(3,minmax(0,1fr));row-gap:34px}.mfn-workflow-line{display:none}
  .mfn-ai-live-shell{grid-template-columns:1fr}.mfn-ai-live-side{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));align-items:start}.mfn-ai-live-side>span,.mfn-ai-live-side>.btn{grid-column:1/-1}.mfn-ai-live-side article{border-bottom:0;border-left:1px solid #edf2f3;padding:10px 12px}.mfn-ai-live-side article:nth-of-type(3){border-left:0}
}
@media(max-width:760px){
  .mfn-story-section{width:auto;max-width:none;margin:58px 12px 0;padding:0;min-width:0;overflow:hidden}
  .mfn-story-head{margin-bottom:22px;padding-inline:3px}.mfn-story-head>div>span{font-size:10px}.mfn-story-head h2{font-size:24px;line-height:1.7;overflow-wrap:anywhere}.mfn-story-head>p{font-size:10.5px;line-height:2}
  .mfn-workflow-shell{padding:22px 14px;border-radius:22px;overflow:hidden}.mfn-workflow-steps{grid-template-columns:1fr;gap:0;text-align:right}.mfn-workflow-steps li{position:relative;text-align:right;padding:0 54px 22px 0;min-height:76px}.mfn-workflow-steps li:last-child{padding-bottom:0}.mfn-workflow-steps li::before{content:"";position:absolute;right:20px;top:44px;bottom:-4px;width:2px;background:#dce9eb}.mfn-workflow-steps li:last-child::before{display:none}.mfn-workflow-steps li>b{position:absolute;right:0;top:0;width:41px;height:41px;margin:0;border-radius:13px}.mfn-workflow-steps li>span{font-size:11px;margin-bottom:4px}.mfn-workflow-steps li>p{font-size:9px;line-height:1.85}.mfn-workflow-note{margin:14px 0 0;align-items:flex-start;justify-content:flex-start;text-align:right}.mfn-workflow-note span{font-size:8.5px;line-height:1.8}
  .mfn-compare-story{padding:28px 13px 18px;border-radius:24px}.mfn-compare-table{border-radius:17px;background:transparent;border:0;overflow:visible}.mfn-compare-head{display:none}.mfn-compare-row{grid-template-columns:1fr;gap:6px;border:0;margin-bottom:12px}.mfn-compare-row span,.mfn-compare-row b{border:0!important;border-radius:13px;padding:11px 12px;font-size:9.5px;line-height:1.8}.mfn-compare-row span{background:#ffffff08}.mfn-compare-row b{background:#0baaa612;border:1px solid #3ecfc626!important}.mfn-compare-row span::before{content:"ساختار پراکنده";display:block;width:75px;flex:0 0 75px;color:#7f96a4;font-size:7px}.mfn-compare-row b::before{content:"MedFamNet";display:block;width:75px;flex:0 0 75px;color:#5dd9d1;font-size:7px}.mfn-compare-row i{width:21px;height:21px;flex-basis:21px}
  .mfn-ai-live{padding:28px 13px 14px;border-radius:24px;overflow:hidden}.mfn-ai-live-shell{min-width:0;gap:12px}.mfn-ai-live-presets{display:grid;grid-template-columns:1fr;gap:6px}.mfn-ai-live-presets button{width:100%;min-height:41px;font-size:9px}.mfn-ai-live-console{min-width:0;max-width:100%;padding:13px;border-radius:18px;overflow:hidden}.mfn-ai-live-bar{align-items:flex-start}.mfn-ai-live-bar>span{font-size:10px}.mfn-ai-live-bar>i{font-size:6.5px;max-width:48%;text-align:center;line-height:1.6}.mfn-ai-live-query{min-height:72px;padding:11px 12px}.mfn-ai-live-query p{font-size:10.5px!important;line-height:1.9!important;overflow-wrap:anywhere}.mfn-ai-live-answer{min-height:235px;padding:11px}.mfn-ai-live-result>strong{font-size:10px}.mfn-ai-live-result li{font-size:8.8px;padding:8px 31px 8px 8px}.mfn-ai-live-foot{gap:4px}.mfn-ai-live-foot span{font-size:6px;padding:4px 5px}.mfn-ai-live-side{display:flex;padding:14px;border-radius:18px}.mfn-ai-live-side article{border-left:0;border-bottom:1px solid #edf2f3;padding:11px 0}.mfn-ai-live-side article:nth-of-type(3){border-bottom:0}.mfn-ai-live-side>.btn{width:100%;font-size:11px}
}
@media(max-width:380px){.mfn-story-section{margin-inline:9px}.mfn-story-head h2{font-size:22px}.mfn-compare-row span::before,.mfn-compare-row b::before{width:64px;flex-basis:64px}.mfn-ai-live-bar>i{display:none}}
@media(prefers-reduced-motion:reduce){.mfn-workflow-line i,.mfn-workflow-steps li,.mfn-compare-row,.mfn-story-head,.mfn-ai-live-result,.mfn-ai-live-result li,.mfn-ai-caret,.mfn-ai-live-thinking i{transition:none!important;animation:none!important}.mfn-workflow-line i{width:100%!important}.mfn-workflow-steps li,.mfn-compare-row{opacity:1!important;transform:none!important}.mfn-ai-caret{opacity:1}}
