"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5098],{72272:function(e,t,r){r.d(t,{Z:function(){return z}});var n=r(59499),i=r(4730),o=r(53575),a=r(37429),c=r(87379),l=(0,c.ZP)(o.kC).withConfig({displayName:"SocialLink__IconWrapper",componentId:"sc-1toayxk-0"})(["cursor:pointer;justify-content:center;width:24px;height:24px;transition:ease-out 0.2s;color:",";&:hover{color:",";}svg{width:100%;height:100%;}"],(function(e){return e.theme.colors.textTertiary}),(function(e){return e.hover})),s=(0,c.ZP)(l).attrs({as:"a",rel:"noopener noreferrer",target:"_blank"}).withConfig({displayName:"SocialLink",componentId:"sc-1toayxk-1"})([""]),d=r(85893),p=["encodedTitle","encodedUrl"];function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t0&&i<120?"translateY(0)":"translateY(-100px)"},children:[(0,h.jsx)(a.kC,{height:["auto","64px"],flexWrap:["wrap","nowrap"],px:[4,4,8],py:[2,0],sx:{boxShadow:"level2"},children:t}),(0,h.jsx)(f,{progress:i}),i>0&&i<120&&n]})},j=(0,p.ZP)(a.zx).withConfig({displayName:"SocialShareMobile__IconButton",componentId:"wlnyr9-0"})(["border-radius:8px;height:40px;padding:0;width:40px;"]),b=p.ZP.div.withConfig({displayName:"SocialShareMobile__Menu",componentId:"wlnyr9-1"})(["padding:16px;width:60px;"]),y=function(e){var t=e.title,r=e.articleId,n=e.canonicalUrl;return(0,h.jsx)(a.xu,{children:(0,h.jsx)(a.Lt,{position:"bottom-right",target:(0,h.jsx)(j,{variant:"defaultCard","aria-label":"Share this article on the social media of your choice",children:(0,h.jsx)(a.aA,{size:"24px"})}),children:(0,h.jsx)(b,{children:(0,h.jsx)(d.Z,{articleId:r,title:t,canonicalUrl:n,isVertical:!0})})})})};y.defaultProps={articleId:null,canonicalUrl:""};var v=y,w=p.ZP.div.withConfig({displayName:"StickyBar__ToC",componentId:"rk0m1f-0"})(["padding:16px;max-height:calc(100vh - 105px);max-width:320px;overflow-y:auto;width:100%;"]),O=p.ZP.div.withConfig({displayName:"StickyBar__ToCButton",componentId:"rk0m1f-1"})(["border-radius:8px;font-weight:300;line-height:1.45;padding:16px;&:hover{background-color:#f5f5f5;cursor:pointer;}"]),k=function(e){var t=e.attachTo,r=e.article,n=e.tableOfContent,i=e.canonicalUrl,c=(0,o.QT)().t;return(0,h.jsxs)(g,{attachTo:t,children:[(0,h.jsx)(a.xv,{order:1,flexGrow:1,flexBasis:["75%","auto"],fontWeight:"medium",sx:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},pr:2,children:r.title}),(0,h.jsx)(a.xu,{display:["none",null,"block"],order:[2,3],ml:[0,4],children:(0,h.jsx)(d.Z,{articleId:r.id,title:r.title,canonicalUrl:i})}),(0,h.jsx)(a.xu,{display:["flex",null,"none"],order:[3,3],ml:[0,4],justifyContent:"flex-end",flexGrow:[1,0],children:(0,h.jsx)(v,{articleId:r.id,title:r.title,canonicalUrl:i})}),n.length>0&&(0,h.jsx)(a.Lt,{order:[2,2],position:["bottom","bottom-right"],target:(0,h.jsxs)(a.kC,{color:"textSecondary",sx:{cursor:"pointer"},children:[(0,h.jsx)(a.xv,{fontSize:[0,2],children:c("Table of Contents")}),(0,h.jsx)(a.Bl,{width:"8px",ml:2})]}),children:(0,h.jsx)(w,{children:n.map((function(e){return(0,h.jsx)(O,{onClick:function(){return function(e){var t=document.getElementById(e);if(t){var r=t.getBoundingClientRect().top,n=84+(window.innerWidth<768?20:0);window.scrollTo({top:r+window.scrollY-n,behavior:"smooth"})}}(e.slug)},children:(0,h.jsx)(s.Z,{html:e.label})},e.slug)}))})})]})},P=r(69135),C=r(25675),_=r.n(C),S=(0,p.ZP)(a.xu).withConfig({displayName:"ArticleCover__CoverBox",componentId:"sc-9pmloj-0"})(["@media screen and (min-width:832px){margin:0 -40px;width:calc(100% + 80px);max-width:calc(100vw - 32px);> *{width:100%;}}"]),Z=function(e){var t,r,n=e.video,i=e.image,o=e.title,c=(0,P.useAmp)();if(!n&&(null===i||void 0===i||!i.optimized)&&(null===i||void 0===i||!i.original))return null;if(n){var l,s=function(e){return e.includes("wistia")?e:e.includes("www.youtube.com/watch")?"https://www.youtube.com/embed/".concat(e.split("?v=").pop(),"?enablejsapi=1"):"https://www.youtube.com/embed/".concat(e.split("/").pop(),"?enablejsapi=1")}(n);return c?(0,h.jsx)("amp-iframe",{src:s,width:"1600",height:"900",sandbox:"allow-scripts allow-same-origin",layout:"responsive",children:(0,h.jsx)("amp-img",{layout:"fill",src:null!==(l=i.optimized)&&void 0!==l&&l.startsWith("http")?i.optimized:"".concat("https://academy-public.coinmarketcap.com","/").concat(i.optimized),placeholder:!0})}):(0,h.jsx)(S,{pt:"56%",sx:{position:"relative"},children:(0,h.jsx)(a.xu,{as:"iframe",src:s,frameborder:"0",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture",allowfullscreen:!0,width:"100%",height:"100%",sx:{position:"absolute",top:0,left:0}})})}return c?(0,h.jsx)("amp-img",{alt:o,src:null!==(t=i.optimized)&&void 0!==t&&t.startsWith("http")?i.optimized:"".concat("https://academy-public.coinmarketcap.com","/").concat(i.optimized),width:"1600",height:"900",layout:"responsive",class:"coverImage"}):(0,h.jsx)(S,{children:(0,h.jsx)(_(),{loader:function(e){return e.src},src:null!==(r=i.optimized)&&void 0!==r&&r.startsWith("http")?i.optimized:"".concat("https://academy-public.coinmarketcap.com","/").concat(i.optimized||i.original),alt:o,width:"720",height:"405",priority:!0,quality:100,objectFit:"cover",className:"coverImage"})})},T=(r(94606),r(41664)),I=r.n(T),A=(0,p.ZP)(a.kC).withConfig({displayName:"AssetTag__AssetWrapper",componentId:"sc-1vyljsz-0"})(["border-radius:16px;display:inline-flex;img{height:24px;width:24px;}"]);function z(e){var t=e.asset;return(0,h.jsxs)(A,{as:"a",href:"https://coinmarketcap.com/currencies/".concat(t.slug,"/"),target:"_blank",py:1,px:2,mr:2,backgroundColor:"#EFF2F5",alignItems:"center",children:[(0,h.jsx)("img",{src:"https://s2.coinmarketcap.com/static/img/coins/64x64/".concat(t.id,".png"),alt:t.name}),(0,h.jsx)(a.xv,{ml:1,fontWeight:"bold",children:t.symbol})]})}var N=r(94184),B=r.n(N),D=r(43340),W=r(89039),U=(0,p.ZP)(a.W2).withConfig({displayName:"CoinPrices__StyledContainer",componentId:"sc-1otk6pe-0"})(["position:relative;"]),F=p.ZP.div.withConfig({displayName:"CoinPrices__Wrapper",componentId:"sc-1otk6pe-1"})(["position:sticky;top:100vh;height:0;@media screen and (max-width:1390px){display:none;}.assets{position:absolute;left:100%;bottom:100%;padding-left:48px;padding-bottom:64px;display:flex;flex-direction:column;width:300px;}.asset{display:flex;align-items:center;padding:12px 16px;border-radius:8px;box-shadow:0px 1px 2px 0px #58667E1F,0px 4px 24px 0px #58667E14;img{width:24px;height:24px;display:inline;}.price{padding-left:4px;flex:1;}.change{padding-left:4px;display:flex;align-items:center;&.positive{color:#16C784;}&.negative{color:#ea3943;}}}"]);function E(e){var t=e.assets,r=(0,i.useState)(null),n=r[0],o=r[1];return(0,i.useEffect)((function(){null!==t&&void 0!==t&&t.length&&fetch("https://api.coinmarketcap.com/data-api/v3/cryptocurrency/quote/latest?id=".concat(t.map((function(e){return e.id})).join(","))).then((function(e){return e.json()})).then((function(e){return o(e.data)})).catch(console.warn)}),[t]),n?(0,h.jsx)(F,{children:(0,h.jsx)(U,{maxWidth:"752px",children:(0,h.jsx)("div",{className:"assets",children:null===t||void 0===t?void 0:t.map((function(e){var t,r=n.find((function(t){return t.id===e.id}));if(null===r||void 0===r||null===(t=r.quotes)||void 0===t||!t.length)return null;var i,o=r.quotes[0].price,c=r.quotes[0].percentChange24h;return(0,h.jsxs)(a.xu,{as:"a",target:"_blank",href:"https://coinmarketcap.com/currencies/".concat(e.slug,"/"),className:"asset",mb:2,children:[(0,h.jsx)("img",{src:"https://s2.coinmarketcap.com/static/img/coins/64x64/".concat(e.id,".png"),alt:e.name}),(0,h.jsxs)("span",{className:"price",children:["$",L(o)]}),(0,h.jsxs)("span",{className:B()("change",{positive:c>0,negative:c<0}),children:[c>0&&(0,h.jsx)(D.Z,{}),c<0&&(0,h.jsx)(W.Z,{}),(i=c,Math.abs(Math.round(100*i)/100)),"%"]})]},e.id)}))})})}):null}function L(e){return e>1?Math.round(100*e)/100:parseFloat(e).toPrecision(3)}var H=i.memo(E,(function(e,t){var r,n;return(null===(r=e.assets)||void 0===r?void 0:r.length)===(null===(n=t.assets)||void 0===n?void 0:n.length)})),M=r(7131);function R(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function q(e){for(var t=1;t3e5&&n.content?n.content.slice(0,10)+n.content.slice(10).replace(/]*>[^<]+<\/h(2|3|4|5|6)>/,"$&"):n.content}),[n.content,n.reading_time]),O=f&&v?"/community/profile/".concat(v.username,"?guid=").concat(v.uid,"&type=Articles"):"";return(0,h.jsxs)("div",{children:[(0,h.jsx)("span",{children:!(0,M.Z)()&&window.innerWidth>=1200&&(0,h.jsx)(H,{assets:(n.assets||[]).slice(0,5)})}),(0,h.jsxs)(a.W2,{ref:m,maxWidth:"752px",minHeight:"calc(100vh - 208px)",children:[(0,h.jsx)(k,{attachTo:m,article:n,tableOfContent:d,canonicalUrl:u}),f&&Boolean(null===b||void 0===b?void 0:b.length)&&(0,h.jsx)(a.xv,{color:"#808A9D",pb:2,children:b.map((function(e){return e.title})).join(" / ")}),!f&&Boolean(null===b||void 0===b?void 0:b.length)&&(0,h.jsx)(I(),{href:"/categories/".concat(b[0].slug),passHref:!0,children:(0,h.jsx)(a.xv,{as:"a",color:"primary",children:b[0].title})}),f&&Boolean(null===(t=n.assets)||void 0===t?void 0:t.length)?(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(a.X6,{as:"h1",fontSize:[4,6],mb:3,lineHeight:1.3,children:n.title}),(0,h.jsx)(a.xu,{mb:5,children:null===(r=n.assets)||void 0===r?void 0:r.map((function(e,t){return(0,h.jsx)(z,{asset:e},t)}))})]}):(0,h.jsx)(a.X6,{as:"h1",fontSize:[4,6],mb:[3,5],lineHeight:1.3,children:n.title}),!f&&(0,h.jsx)(h.Fragment,{children:(0,h.jsxs)(a.kC,{mb:[4,7],flexWrap:"wrap",children:[Boolean(null===y||void 0===y?void 0:y.name)&&(0,h.jsx)(a.xv,{color:"textTertiary",fontSize:2,mr:3,children:(0,h.jsx)(I(),{href:"/author/".concat(null===y||void 0===y?void 0:y.slug),passHref:!0,children:(0,h.jsx)(X,{children:j("By {{author}}",{author:null===y||void 0===y?void 0:y.name})})})}),(0,h.jsx)(c.Z,{timeMs:n.reading_time,fontSize:2,mr:3}),(0,h.jsx)(l.Z,{createdAt:n.created_at,updatedAt:n.updated_at,mr:3})]})}),f&&(null===v||void 0===v?void 0:v.image_url)&&(0,h.jsxs)(a.kC,{mb:5,children:[Boolean(v)&&(0,h.jsx)(a.kC,{mr:2,style:{borderRadius:"100%",overflow:"hidden"},children:(0,h.jsx)("a",{target:"_blank",href:O,style:{display:"flex"},children:(0,h.jsx)(_(),{loader:function(e){return e.src},src:v.image_url,alt:v.nickname,objectFit:"cover",width:"56",height:"56",loading:"lazy"})})}),(0,h.jsxs)(a.xu,{children:[Boolean(null===v||void 0===v?void 0:v.nickname)&&(0,h.jsx)(a.xv,{color:"textTertiary",fontSize:2,mr:3,children:(0,h.jsxs)(X,{children:[j("By")," ",(0,h.jsx)("a",{href:O,target:"_blank",className:"name",children:null===v||void 0===v?void 0:v.nickname})]})}),Boolean(n.created_at||n.updated_at)&&(0,h.jsxs)(a.kC,{children:[(0,h.jsx)(l.Z,{createdAt:n.created_at,updatedAt:n.updated_at}),Boolean(n.reading_time)&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(a.xu,{mx:2,children:"\u2022"}),(0,h.jsx)(c.Z,{timeMs:n.reading_time,fontSize:2,mr:2,full:f})]})]})]})]}),!f&&(0,h.jsx)(G,{py:[4,6],px:5,my:[3,6],fontSize:2,children:(0,h.jsx)("p",{children:n.meta})}),(0,h.jsx)(Z,q({},n)),Boolean(null===d||void 0===d?void 0:d.length)&&(0,h.jsxs)(V,{bg:"backgroundAlt",py:[4,5],px:5,mt:4,children:[(0,h.jsx)(a.X6,{as:"h4",fontSize:4,mb:2,children:j("Table of Contents")}),(0,h.jsx)("ul",{children:d.map((function(e){return(0,h.jsx)("li",{children:(0,h.jsx)(a.xv,{className:"toc-link",color:"link",fontWeight:"600",as:"a",href:"#".concat(e.slug),onClick:function(t){t.preventDefault(),function(e){var t=document.getElementById(e);if(t){var r=t.getBoundingClientRect().top,n=84+(window.innerWidth<768?20:0);window.scrollTo({top:r+window.scrollY-n,behavior:"smooth"})}}(e.slug)},children:(0,h.jsx)(s.Z,{html:e.label})})},e.slug)}))})]}),(0,h.jsxs)(Q,{px:[0],py:[3,8],as:"article",children:[(0,h.jsx)(s.Z,{html:w}),!f&&Boolean(n.disclaimer)&&(0,h.jsx)("div",{className:"disclaimer",children:n.disclaimer})]})]})]})};Y.defaultProps={canonicalUrl:""};var J=Y},25479:function(e,t,r){var n=r(41664),i=r.n(n),o=r(53575),a=r(28309),c=(r(94606),r(5826)),l=r(85893);t.Z=function(e){var t=e.article,r=(0,c.QT)().t;return(0,l.jsxs)(o.xu,{bg:"backgroundAlt",py:6,mt:8,children:[(0,l.jsx)(o.W2,{children:(0,l.jsx)(o.X6,{as:"h3",fontSize:6,children:r("Related Articles")})}),t.related&&(0,l.jsx)(o.rj,{as:o.W2,gridGap:"16px",gridTemplateColumns:["1fr","1fr 1fr","1fr 1fr 1fr"],py:8,children:t.related.map((function(e){return(0,l.jsx)(a.Z,{article:e},e.slug)}))}),(0,l.jsx)(o.kC,{justifyContent:"center",children:(0,l.jsx)(i(),{href:"/article",as:"/article",passHref:!0,children:(0,l.jsx)(o.zx,{as:"a",variant:"alternate",scale:"lg",style:{height:"56px"},endIcon:(0,l.jsx)(o.LZ,{width:"24px"}),children:r("See all articles")})})})]})}},38658:function(e,t,r){var n=r(5826),i=r(53575),o=r(87379),a=r(98679),c=r(70399),l=r(85893),s=(0,o.ZP)(a.Z).withConfig({displayName:"Newsletter__NewsletterSection",componentId:"tgkqos-0"})(["padding-left:32px;padding-right:32px;p,h3{text-align:center;}.form{margin:24px auto 0;}"]);t.Z=function(){var e=(0,n.QT)().t;return(0,l.jsx)(i.W2,{maxWidth:"1200px",children:(0,l.jsxs)(s,{bg:"backgroundDeep",children:[(0,l.jsx)(i.xv,{as:"p",fontSize:[2,null,3],textAlign:["center","left"],color:"textPrimary",mb:4,children:e("Join the thousands already learning crypto!")}),(0,l.jsx)(i.X6,{as:"h3",fontSize:[4,null,6],mb:2,textAlign:["center","left"],lineHeight:1.2,children:e("Join our free newsletter for daily crypto updates!")}),(0,l.jsx)("div",{className:"form",children:(0,l.jsx)(c.Z,{})})]})})}}}]);