/* AlgoGrid public homepage integration. Existing account/admin CSS is retained. */
.ag-language{display:flex;align-items:center;gap:5px;margin:0;color:#c6e4ff;font-size:14px;flex:none}.ag-language select{width:104px;margin:0;border:1px solid #315982;border-radius:8px;padding:7px 8px;background:#081c38;color:#fff;font:inherit;font-size:12px}.ag-mobile-toggle{display:none;background:none;color:#fff;border:0;font-size:25px;cursor:pointer;padding:6px;margin-inline-start:auto}.ag-language-list{font-size:11px;line-height:1.8;color:#91b5d6;padding-top:15px}.ag-market-strip #ag-ticker-widget{min-height:48px;direction:ltr}.ag-feed-note{font-size:9px;color:#91aac4;display:flex;justify-content:space-between;gap:15px;padding-bottom:7px}.ag-feed-note a{color:#5bcfff;white-space:nowrap}.ag-widget-attribution{font-size:9px;color:#80a6c8;padding:4px 10px;text-align:end}.ag-widget-fallback{font-size:12px;padding:10px;margin:0}.ag-news-widget{min-height:330px;background:white;border:1px solid #cbe0f2;border-radius:10px;overflow:hidden;direction:ltr}.ag-home .ref-hero .hero-grid{min-height:520px;grid-template-columns:1.05fr 1fr;gap:25px}.ag-home .ref-hero .hero-copy h1{font-size:clamp(46px,5vw,70px);line-height:1.06;white-space:pre-line}.ag-home .reference-visual .gold-art{width:116%;border-radius:20px;max-height:490px;object-fit:cover;mask-image:linear-gradient(90deg,transparent 0,#000 16%,#000 90%,transparent)}.ag-home .reference-visual .control-panel{top:165px;transform:rotate(-3deg)}.ag-home .backtest-section{padding:50px 0}.ag-video-card{background:#061931}.ag-video-card video{width:100%;display:block;aspect-ratio:1598/732}.ag-video-note{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:13px 16px;font-size:10px;color:#89c5ed}.ag-video-card .ag-small{font-size:11px;color:#9fc0dc;padding:0 16px;margin:0 0 10px}.ag-text-link{display:inline-block;color:#5bcfff;font-size:12px;padding:0 16px 15px}.ag-home .controls-section{padding:40px 0 28px}.ag-home .controls-section h2,.ag-home .products-section h2,.ag-home .learn-section h2{font-size:36px;line-height:1.15}.ag-home .section-intro{font-size:15px;line-height:1.5}.ag-home .reference-features{gap:16px;margin-top:22px}.ag-home .reference-features .feature-card{min-height:132px;padding:20px;gap:14px}.ag-home .reference-features .feature-card h3{font-size:17px;line-height:1.3}.ag-home .reference-features .feature-card p{font-size:13px;line-height:1.5;max-width:360px}.ag-home .reference-features .feature-card>div:nth-child(2){flex:1;min-width:0}.ag-home .reference-features .feature-card:after{pointer-events:none}.ag-home .feature-card:hover{transform:translateY(-2px);color:inherit}.ag-home .feature-card:hover p{color:var(--muted)}.ag-home .ag-switch{padding:0;cursor:pointer;border:0;flex:none;background:#92b3d1;position:relative}.ag-home .ag-switch[aria-checked=true]{background:#087dff}.ag-home .ag-switch[aria-checked=true]:after{left:19px}.ag-home .ag-switch[aria-checked=false]:after{left:3px}.ag-home .select-pill{max-width:86px;margin:0 0 0 auto;flex:none;cursor:pointer;background:#fff;color:#0072e5;border:1px solid #bddbf3}.ag-home button.arrow{border:0;cursor:pointer;flex:none;font-size:25px}.ag-demo-status{font-size:12px;text-align:center;color:#416b96;line-height:1.7;margin:18px 0 6px}.ag-home .section-note{font-size:11px}.ag-home .products-section{padding:35px 0}.ag-home .reference-products{gap:15px;margin-top:22px}.ag-home .reference-products .product-card{min-height:220px}.ag-home .reference-products .product-body{padding:18px}.ag-home .reference-products .product-body h3{font-size:20px}.ag-home .reference-products .product-body p{font-size:13px;line-height:1.5}.ag-home .reference-products .product-body>span{font-size:10px}.ag-home .reference-products .product-cta{font-size:12px;padding:11px}.ag-home .product-thumb img{height:100%;width:100%;object-fit:cover;border-radius:8px}.ag-home .news-section{padding:25px 0}.ag-home .news-section .micro-head p{font-size:12px}.ag-home .ag-small{font-size:12px;color:#71859a;line-height:1.6}.ag-home .learn-section{padding:35px 0}.ag-home .reference-articles{gap:18px;margin-top:22px}.ag-home .reference-articles article{display:block;padding:16px}.ag-home .reference-articles img{height:125px;width:100%;margin-bottom:16px}.ag-home .reference-articles h3{font-size:18px;line-height:1.4;margin:10px 0}.ag-home .reference-articles p{font-size:13px;line-height:1.5}.ag-read-guide{font:inherit;background:transparent;color:#0072e5;border:0;font-size:13px;padding:15px 0 0;cursor:pointer;font-weight:700}.footer button[data-ag-dialog]{display:block;border:0;background:none;color:#c2d4e7;font-size:11px;padding:0;margin:8px 0;cursor:pointer;text-align:start}.footer .footer-grid p,.footer .footer-grid a{font-size:12px}.footer .footer-grid h4{font-size:13px}#ag-guide-dialog{width:min(660px,calc(100% - 30px));max-height:85vh;border:1px solid #aacfe9;border-radius:16px;padding:34px;background:#f6fbff;color:#10213a;z-index:2147483647;box-shadow:0 20px 70px #001d4566}#ag-guide-dialog::backdrop{background:#03142dcc;backdrop-filter:blur(5px)}#ag-guide-dialog h2{font-size:27px;line-height:1.3;padding-inline-end:20px}#ag-guide-dialog p{font-size:16px;line-height:1.7;color:#4a617a;white-space:pre-line}.ag-dialog-close{position:absolute;top:8px;inset-inline-end:12px;border:0;background:none;font-size:32px;color:#1763a5;cursor:pointer}button:focus-visible,select:focus-visible,a:focus-visible{outline:3px solid #43cfff;outline-offset:4px}[hidden]{display:none!important}.ag-home h1,.ag-home h2,.ag-home h3,.ag-home .btn{overflow-wrap:anywhere}html[dir=rtl] .ag-home h1,html[dir=rtl] .ag-home h2{letter-spacing:0}html[dir=rtl] .main-nav{margin-right:auto;margin-left:0}html[dir=rtl] .ag-home .reference-visual .control-panel{left:0;right:auto;transform:rotate(3deg)}html[dir=rtl] .ag-home .feature-card .toggle,html[dir=rtl] .ag-home .feature-card .select-pill,html[dir=rtl] .ag-home .feature-card .arrow{margin-left:0;margin-right:auto}
@media(max-width:1180px){.site-header .topbar{gap:14px!important}.site-header .main-nav{gap:16px}.header-actions .btn{padding:7px 8px!important;font-size:11px!important}}
@media(max-width:980px){.ag-mobile-toggle{display:block}.site-header .main-nav.open{display:flex!important;top:100%;margin:0;max-height:65vh;overflow-y:auto}.site-header .header-actions{display:none}.ag-home .ref-hero .hero-grid{grid-template-columns:1fr;min-height:0}.ag-home .ref-hero .hero-copy{padding-bottom:10px}.ag-home .reference-visual{min-height:390px}.ag-home .reference-visual .gold-art{width:100%;max-width:700px}.ag-home .reference-visual .control-panel{right:5%;top:140px}.ag-home .reference-backtest{grid-template-columns:1fr}}
@media(max-width:680px){.ag-language{margin-inline-start:auto}.ag-language select{width:100px}.ag-mobile-toggle{margin-inline-start:0}.ag-feed-note{font-size:8px}.ag-home .ref-hero .hero-copy h1{font-size:43px}.ag-home .reference-visual{min-height:320px}.ag-home .reference-visual .control-panel{position:absolute;right:2%;top:115px;margin:0;width:250px}.ag-home .reference-features .feature-card{min-height:145px;padding:16px;gap:10px}.ag-home .reference-features .feature-card .icon{width:35px;height:35px}.ag-home .reference-features .feature-card h3{font-size:16px}.ag-home .reference-features .feature-card p{font-size:12px}.ag-home .controls-section h2,.ag-home .products-section h2,.ag-home .learn-section h2{font-size:30px}.ag-home .reference-coming{display:flex}.ag-home .reference-products .product-body{padding:16px}.ag-home .reference-products .product-thumb{min-width:94px}.ag-home .backtest-section{padding:30px 0}.ag-home .reference-backtest .backtest-copy p{font-size:16px}.ag-home .reference-articles{grid-template-columns:1fr}.ag-language-list{font-size:10px}#ag-guide-dialog{padding:26px}html[dir=rtl] .ag-home .reference-visual .control-panel{right:auto;left:2%;transform:none}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}.ag-home *{transition:none!important;animation:none!important}}
