/* ProfitAlgos Strategy Library — förstasida. Identitet: marinblå bakgrund, ProfitAlgos-grönt, avrundad Comfortaa i rubriker. */
@font-face { font-family: "Comfortaa"; src: url("/static/fonts/comfortaa-latin.woff2") format("woff2"); font-weight: 500 700; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/static/fonts/inter-latin.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
:root { --bg: #0d1326; --bg2: #11182e; --card: #151d36; --line: #243052; --ink: #e8ecf8; --mut: #9aa7c7; --g: #00c972; --g2: #00e083; --gd: #003d22; --b: #8b97b5; --red: #ff6b6b; }
* { box-sizing: border-box; } html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.6 Inter, system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--g2); } img { max-width: 100%; height: auto; }
h1, h2, h3, .btn, .eyebrow, .tab, .stat b, .kpi b, .price { font-family: Comfortaa, Inter, system-ui, sans-serif; }
.wrap { max-width: 74rem; margin: 0 auto; padding: 0 20px; } .c { text-align: center; } .muted { color: var(--mut); } .fine { font-size: .82rem; } .sr { position: absolute; left: -9999px; }
/* meny */
.nav { position: sticky; top: 0; z-index: 30; background: rgba(13, 19, 38, .86); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.navin { display: flex; align-items: center; gap: 1.4rem; height: 66px; }
.logo { display: inline-flex; flex-direction: column; text-decoration: none; line-height: 1; gap: 3px; } .logo span { font-size: .62rem; letter-spacing: .22em; text-transform: uppercase; color: var(--mut); padding-left: 2px; }
.links { display: flex; gap: 1.4rem; margin-left: auto; } .links a { color: var(--mut); text-decoration: none; font-size: .92rem; } .links a:hover { color: var(--g2); }
.navbtns { display: flex; align-items: center; gap: .6rem; } .lang { color: var(--mut); text-decoration: none; font-size: .82rem; padding: 0 .3rem; } .lang:hover { color: var(--g2); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; padding: .62rem 1.15rem; border-radius: 12px; font-weight: 700; font-size: .93rem; text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: transform .12s, background .15s, border-color .15s; }
.btn.primary { background: var(--g); color: #04210f; } .btn.primary:hover { background: var(--g2); transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); } .btn.ghost:hover { border-color: var(--g); color: var(--g2); }
.btn.big { padding: .9rem 1.6rem; font-size: 1.02rem; border-radius: 14px; } .btn.wide { width: 100%; }
/* hero */
.hero { position: relative; overflow: hidden; padding: 3.6rem 0 4rem; background: radial-gradient(900px 480px at 85% 0%, rgba(0, 201, 114, .14), transparent 60%), radial-gradient(700px 400px at 0% 100%, rgba(80, 120, 255, .12), transparent 60%), var(--bg); }
.hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 64px 64px; opacity: .22; mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%); }
.herogrid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 2.6rem; align-items: center; }
.eyebrow { display: inline-block; font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--g2); border: 1px solid rgba(0, 201, 114, .4); background: rgba(0, 201, 114, .08); border-radius: 999px; padding: .3rem .85rem; }
h1 { font-size: clamp(2rem, 4.2vw, 3.3rem); line-height: 1.1; letter-spacing: -.02em; margin: 1rem 0 1rem; font-weight: 700; }
.lead { font-size: 1.1rem; color: #c3cde6; max-width: 34rem; } .lead2 { font-size: 1.08rem; color: #c3cde6; }
.cta { display: flex; gap: .8rem; flex-wrap: wrap; margin: 1.6rem 0 .8rem; } .cta.c { justify-content: center; } .alt { margin: 0 0 1.2rem; font-size: .92rem; } .alt a { color: var(--mut); } .alt a:hover { color: var(--g2); }
.trust { list-style: none; padding: 0; margin: 0; display: grid; gap: .45rem; color: #c3cde6; font-size: .93rem; } .trust li::before { content: "✓"; color: var(--g); font-weight: 700; margin-right: .6rem; }
/* demo */
.card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; } .demo { padding: 1.2rem 1.3rem 1.3rem; box-shadow: 0 30px 80px rgba(0, 0, 0, .4); }
.demo h2 { font-size: 1.02rem; margin: 0 0 .8rem; font-weight: 700; }
.tabs { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .6rem; }
.tab { border: 1px solid var(--line); background: transparent; color: var(--mut); border-radius: 10px; padding: .4rem .8rem; font-weight: 700; font-size: .85rem; cursor: pointer; } .tab small { font-weight: 500; opacity: .75; }
.tab.on { background: var(--g); color: #04210f; border-color: var(--g); } .tab:hover:not(.on) { border-color: var(--g); color: var(--ink); }
.chartbox svg { width: 100%; height: auto; display: block; } .legend { display: flex; gap: 1.1rem; font-size: .78rem; color: var(--mut); margin-top: .2rem; } .dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: .4rem; } .dot.g { background: var(--g); } .dot.b { background: var(--b); }
.pane { display: none; } .pane.on { display: block; } .chips { display: flex; gap: .4rem; flex-wrap: wrap; margin: .7rem 0 .3rem; }
.chip { font-size: .72rem; border: 1px solid var(--line); color: var(--mut); border-radius: 999px; padding: .12rem .6rem; } .chip.ok { color: var(--g2); border-color: rgba(0, 201, 114, .5); background: rgba(0, 201, 114, .08); } .chip.free { color: #04210f; background: var(--g); border-color: var(--g); font-weight: 700; }
.sname { font-weight: 600; margin-bottom: .6rem; font-size: .95rem; word-break: break-word; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; } .kpi { background: rgba(255, 255, 255, .04); border: 1px solid var(--line); border-radius: 12px; padding: .6rem .5rem; text-align: center; }
.kpi b { display: block; font-size: 1.12rem; color: #fff; } .kpi span { font-size: .7rem; color: var(--mut); line-height: 1.25; display: block; } .kpi i { font-style: normal; display: block; opacity: .85; }
.kpis.big .kpi b { font-size: 1.5rem; } .note { font-size: .76rem; color: var(--mut); margin: .9rem 0 0; line-height: 1.5; }
/* statistik */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; margin-top: -2rem; position: relative; z-index: 2; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 1.1rem .6rem; text-align: center; } .stat b { display: block; font-size: 1.75rem; color: var(--g2); letter-spacing: -.02em; } .stat span { font-size: .8rem; color: var(--mut); }
/* sektioner */
.sec { padding-top: 4.2rem; } .sec h2 { font-size: clamp(1.45rem, 2.6vw, 2.1rem); margin: 0 0 1.4rem; letter-spacing: -.02em; } .narrow { max-width: 50rem; }
.grid3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1rem; } .grid2 { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 1.4rem; align-items: stretch; } .grid2 > .cmp { height: 100%; }
.step { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 1.4rem; } .step h3 { margin: .7rem 0 .3rem; font-size: 1.15rem; } .step p { margin: 0; color: #c3cde6; font-size: .95rem; }
.num { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: rgba(0, 201, 114, .14); color: var(--g2); font-weight: 700; font-family: Comfortaa, sans-serif; }
.more { color: var(--g2); text-decoration: none; font-weight: 600; } .more:hover { text-decoration: underline; }
.prtgrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2rem; align-items: center; } .prtgrid p { color: #c3cde6; }
.code { background: #0a0f1f; border: 1px solid var(--line); border-radius: 16px; padding: 1.1rem 1.2rem; margin: 0; overflow: auto; font: 12.5px/1.65 ui-monospace, "SF Mono", Menlo, Consolas, monospace; color: #9fb0d6; white-space: pre; }
.cmp { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; font-size: .94rem; }
.cmp th, .cmp td { padding: .8rem 1rem; border-bottom: 1px solid var(--line); text-align: left; } .cmp th:not(:first-child), .cmp td:not(:first-child) { text-align: center; width: 6.5rem; } .cmp th { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--mut); } .cmp th.pr { color: var(--g2); }
.cmp tr:last-child td { border-bottom: 0; } .y { color: var(--g); font-weight: 700; } .n { color: #4a5678; }
.pricebox { background: var(--card); border: 2px solid var(--g); border-radius: 20px; padding: 1.5rem; display: grid; gap: .8rem; box-shadow: 0 0 0 6px rgba(0, 201, 114, .07), 0 30px 70px rgba(0, 0, 0, .35); } .pricebox h3 { margin: 0; font-size: 1.35rem; } .pricebox .chip { justify-self: start; }
.price { font-size: 2.6rem; font-weight: 700; letter-spacing: -.03em; } .price small { font-size: .9rem; font-weight: 400; color: var(--mut); margin-left: .3rem; font-family: Inter, sans-serif; }
.launch { background: rgba(0, 201, 114, .09); border: 1px solid rgba(0, 201, 114, .3); border-radius: 12px; padding: .8rem 1rem; display: grid; gap: .45rem; font-size: .9rem; } .bar { height: 8px; border-radius: 99px; background: rgba(255, 255, 255, .1); overflow: hidden; } .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--g), var(--g2)); border-radius: 99px; }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; } .ticks li::before { content: "✓"; color: var(--g); font-weight: 700; margin-right: .6rem; }
details { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: .95rem 1.1rem; margin-bottom: .6rem; } summary { cursor: pointer; font-weight: 600; } details p { color: #c3cde6; margin: .6rem 0 0; }
.band { margin-top: 4.5rem; padding: 3.2rem 0; background: linear-gradient(135deg, #0c3a2a, #0f2a4a); border-block: 1px solid var(--line); } .band h2 { margin: 0 0 .4rem; } .band p { color: #c3cde6; margin: 0 0 1rem; }
.foot { border-top: 1px solid var(--line); padding: 2.2rem 0 3rem; } .footgrid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 2rem; } .foot a { color: var(--mut); } .foot a:hover { color: var(--g2); } .foot p { margin: .4rem 0; }
.sticky { display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; padding: .6rem 16px calc(.6rem + env(safe-area-inset-bottom)); background: rgba(13, 19, 38, .95); backdrop-filter: blur(10px); border-top: 1px solid var(--line); } .sticky .btn { width: 100%; }
/* innehållssidor */
.article { max-width: 46rem; padding-top: 2.2rem; padding-bottom: 2rem; } .article h1 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); } .article h2 { font-size: 1.35rem; margin-top: 2rem; } .crumbs { font-size: .85rem; color: var(--mut); } .crumbs a { color: var(--mut); }
.steps { padding-left: 1.2rem; } .steps li { margin: 1rem 0; } .steps h3 { margin: 0 0 .2rem; font-size: 1.1rem; } .steps p { margin: 0; color: #c3cde6; }
@media (max-width: 900px) { .herogrid, .prtgrid, .grid2, .footgrid { grid-template-columns: 1fr; } .stats { grid-template-columns: repeat(2, 1fr); margin-top: -1.4rem; } .links { display: none; } .navbtns { margin-left: auto; } }
@media (max-width: 640px) { .navbtns .ghost { padding: .42rem .85rem; font-size: .88rem; } .sticky { display: block; } .foot { padding-bottom: 5.5rem; } .kpis { grid-template-columns: repeat(2, 1fr); } .hero { padding-top: 2.2rem; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .btn { transition: none; } }
.cmp { table-layout: fixed; } .cmp th:not(:first-child), .cmp td:not(:first-child) { width: 5.2rem; }
@media (max-width: 640px) { .cmp { font-size: .84rem; } .cmp th, .cmp td { padding: .65rem .5rem; } .cmp th:not(:first-child), .cmp td:not(:first-child) { width: 4.3rem; } }
.instbox { background: rgba(255, 193, 7, .07); border: 1px solid rgba(255, 193, 7, .35); border-radius: 16px; padding: 1.1rem 1.3rem; } .instbox h3 { margin: 0 0 .3rem; font-size: 1.02rem; color: #ffd666; } .instbox p { margin: 0; color: #c3cde6; font-size: .93rem; }
.codehead { margin: 0 0 .5rem; font-weight: 700; font-family: Comfortaa, sans-serif; font-size: .95rem; } .trust li:nth-child(4)::before { content: "ℹ"; color: #ffd666; }

/* -- mobil: inget får göra sidan bredare än skärmen -- */
html, body { max-width: 100%; overflow-x: hidden; }
.herogrid > *, .prtgrid > *, .grid2 > *, .grid3 > *, .footgrid > *, .demo, .heroside { min-width: 0; }
.code { max-width: 100%; } .cmp { max-width: 100%; }
.btn { white-space: nowrap; } .navbtns { flex-shrink: 0; } .logo img { max-width: 100%; height: auto; }
@media (max-width: 640px) {
  .navbtns .btn.primary { display: none; }            /* den fasta knappen längst ned tar över på mobil */
  .navin { gap: .6rem; height: 58px; } .logo img { width: 126px; } .navbtns { margin-left: auto; gap: .3rem; }
  .cta .btn { flex: 1 1 100%; } .btn.big { width: 100%; }
  .code { font-size: 11.5px; } .demo { padding: 1rem .9rem 1.1rem; } .tabs { gap: .3rem; } .tab { padding: .35rem .6rem; font-size: .8rem; }
  h1 { font-size: 1.95rem; } .stat b { font-size: 1.4rem; }
}
.legal h1 { font-size: clamp(1.7rem, 3vw, 2.2rem); margin-top: 1.4rem; } .legal h2 { font-size: 1.15rem; margin: 1.6rem 0 .3rem; } .legal p { color: #c3cde6; } .legal .draft { background: rgba(255, 193, 7, .08); border: 1px solid rgba(255, 193, 7, .35); border-radius: 12px; padding: .8rem 1rem; color: #ffd666; }

/* -- ljust tema (testas mot det mörka med LANDING_THEME=ab; ?theme=light visar det direkt) -- */
:root { --chart-grid: #243052; --chart-text: #9aa7c7; --chart-b: #8b97b5; }
:root[data-theme="light"] { --bg: #f5f8fc; --bg2: #eef3fb; --card: #ffffff; --line: #dbe3f0; --ink: #0f1a33; --mut: #566282; --g: #00a860; --g2: #008f52; --chart-grid: #e3e9f4; --chart-text: #6b7898; --chart-b: #9aa4b8; }
[data-theme="light"] body { background: var(--bg); color: var(--ink); }
[data-theme="light"] .nav { background: rgba(245, 248, 252, .9); }
[data-theme="light"] .hero { background: radial-gradient(900px 480px at 85% 0%, rgba(0, 168, 96, .13), transparent 60%), radial-gradient(700px 400px at 0% 100%, rgba(60, 100, 255, .08), transparent 60%), var(--bg); }
[data-theme="light"] .hero::before { opacity: .55; }
[data-theme="light"] h1, [data-theme="light"] h2, [data-theme="light"] h3 { color: var(--ink); }
[data-theme="light"] .lead, [data-theme="light"] .lead2, [data-theme="light"] .trust, [data-theme="light"] .step p, [data-theme="light"] .prtgrid p, [data-theme="light"] details p, [data-theme="light"] .instbox p, [data-theme="light"] .legal p, [data-theme="light"] .steps p, [data-theme="light"] .band p { color: #3b4768; }
[data-theme="light"] .eyebrow { color: #00814a; background: rgba(0, 168, 96, .1); border-color: rgba(0, 168, 96, .4); }
[data-theme="light"] .btn.primary { background: var(--g); color: #fff; } [data-theme="light"] .btn.primary:hover { background: var(--g2); }
[data-theme="light"] .btn.ghost { color: var(--ink); border-color: #c5d0e4; } [data-theme="light"] .btn.ghost:hover { color: var(--g2); border-color: var(--g); }
[data-theme="light"] .demo, [data-theme="light"] .stat, [data-theme="light"] .step, [data-theme="light"] .cmp, [data-theme="light"] details, [data-theme="light"] .pricebox { box-shadow: 0 10px 30px rgba(15, 26, 51, .07); }
[data-theme="light"] .kpi { background: #f3f6fb; } [data-theme="light"] .kpi b { color: var(--ink); } [data-theme="light"] .tab.on, [data-theme="light"] .chip.free { color: #fff; }
[data-theme="light"] .chip.ok { color: #00814a; } [data-theme="light"] .stat b { color: var(--g2); } [data-theme="light"] .num { color: var(--g2); background: rgba(0, 168, 96, .12); }
[data-theme="light"] .more, [data-theme="light"] a { color: #00814a; } [data-theme="light"] .btn { color: inherit; } [data-theme="light"] .btn.primary { color: #fff; }
[data-theme="light"] .band { background: linear-gradient(135deg, #e3f6ec, #e6eefc); } [data-theme="light"] .band h2 { color: var(--ink); }
[data-theme="light"] .instbox { background: #fff8e6; } [data-theme="light"] .instbox h3 { color: #8a5a00; }
[data-theme="light"] .launch { background: rgba(0, 168, 96, .08); } [data-theme="light"] .bar { background: #dde5f2; }
[data-theme="light"] .foot a, [data-theme="light"] .links a, [data-theme="light"] .lang { color: var(--mut); }
[data-theme="light"] .legal .draft { background: #fff8e6; color: #8a5a00; }

/* -- rörelse -- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; } .reveal.in { opacity: 1; transform: none; }
.step.reveal:nth-child(2) { transition-delay: .08s; } .step.reveal:nth-child(3) { transition-delay: .16s; }
.btn.primary { box-shadow: 0 6px 18px rgba(0, 201, 114, .25); } .btn.primary:hover { box-shadow: 0 10px 26px rgba(0, 201, 114, .38); }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

.themesw { display: inline-block; margin-top: .3rem; padding: .35rem .8rem; border: 1px solid var(--line); border-radius: 999px; color: var(--muted, inherit); text-decoration: none; }

/* jämförelse: Strategy Library mot ProfitAlgos webshop */
.cmpgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.1rem; margin-top: 1.6rem; align-items: stretch; }
.cmpcard { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 1.5rem 1.5rem 1.3rem; display: flex; flex-direction: column; gap: .5rem; }
.cmpcard.here { border: 2px solid var(--g); box-shadow: 0 0 0 6px rgba(0, 201, 114, .07); }
.cmpcard h3 { margin: .1rem 0 .3rem; font-size: 1.3rem; } .cmpcard ul { margin: 0; padding-left: 1.15rem; display: grid; gap: .55rem; color: var(--mut); } .cmpcard li::marker { color: var(--g); }
.cmptag { align-self: flex-start; font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--g2); background: rgba(0, 201, 114, .1); border-radius: 99px; padding: .2rem .65rem; }
.cmpcta { margin: auto 0 0; padding-top: .9rem; display: flex; flex-wrap: wrap; gap: .6rem; } .cmpnote { margin-top: 1.1rem; }
@media (max-width: 900px) { .cmpgrid { grid-template-columns: 1fr; } .cmpcta .btn { flex: 1 1 100%; } }
[data-theme="light"] .cmpcard ul { color: #44516e; } [data-theme="light"] .cmptag { color: #00814a; }

/* Inloggning som ruta över förstasidan: ramen (iframe) täcker fönstret med dämpad, suddig bakgrund */
.authov { position: fixed; inset: 0; z-index: 9999; background: rgba(8, 12, 24, .55); backdrop-filter: blur(6px); animation: authfade .18s ease; }
.authov iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: transparent; color-scheme: normal; }
@keyframes authfade { from { opacity: 0; } to { opacity: 1; } }

/* Insikter: tabeller med staplar i cellerna och horisontell scroll för breda tabeller */
.scroll { overflow-x: auto; margin: 10px 0 14px; }
.tbl2 { width: 100%; border-collapse: collapse; font-size: .95rem; }
.tbl2 th, .tbl2 td { padding: 10px 12px; border-bottom: 1px solid rgba(127, 127, 127, .22); text-align: left; white-space: nowrap; vertical-align: middle; }
.tbl2 thead th { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; opacity: .7; }
.tbl2 tbody th { font-weight: 600; } .tbl2 th small { display: block; font-weight: 400; opacity: .7; }
.bar2 { display: inline-block; width: 110px; height: 10px; border-radius: 99px; background: rgba(127, 127, 127, .2); vertical-align: middle; margin-right: 8px; overflow: hidden; }
.bar2 i { display: block; height: 100%; border-radius: 99px; background: #04ce78; }
.bar2.b i { background: #5b8cff; }
/* inloggningsrutan laddas i en ram: visa en snurra tills den hunnit ritas (annars ser en långsam server ut som en suddig skärm utan ruta) */
.authov::after { content: ""; position: absolute; left: 50%; top: 50%; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .25); border-top-color: #00e083; animation: authspin .8s linear infinite; pointer-events: none; }
.authov iframe { z-index: 1; }
@keyframes authspin { to { transform: rotate(360deg); } }
