/* Trading Crypto Virtuel - styles (compatibles prosilver et dérivés) */
.ct-wrap { --ct-up: #13854e; --ct-down: #c62a2a; --ct-accent: #105289; --ct-border: #d5dde5; --ct-soft: #f3f6f9; --ct-card: #ffffff; --ct-muted: #6b7785; }
.ct-wrap { margin-bottom: 10px; }
.ct-title { margin: 6px 0 10px; font-size: 1.6em; }
.ct-muted { color: var(--ct-muted, #6b7785); }
.ct-small { font-size: 0.9em; }
.ct-right { text-align: right; }
.ct-up { color: var(--ct-up, #13854e); }
.ct-down { color: var(--ct-down, #c62a2a); }
.ct-flat { color: var(--ct-muted, #6b7785); }

/* Menu */
.ct-menu { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; margin: 0 0 10px; padding: 0; border-bottom: 2px solid var(--ct-accent); }
.ct-menu li a { display: block; padding: 7px 12px; border-radius: 6px 6px 0 0; background: var(--ct-soft); color: inherit; font-weight: bold; text-decoration: none; }
.ct-menu li a:hover { background: #e2e9f0; }
.ct-menu li.active a { background: var(--ct-accent); color: #fff; }

/* Alertes */
.ct-alert { padding: 8px 12px; margin: 8px 0; border-radius: 6px; background: #fff7e0; border: 1px solid #f0d58a; }
.ct-alert-error { background: #fdecec; border-color: #f1b0b0; }

/* Barre de championnats */
.ct-seasonbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin: 8px 0; }
.ct-tabs { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; }
.ct-tabs li a { display: inline-block; padding: 5px 10px; border: 1px solid var(--ct-border); border-radius: 18px; background: var(--ct-card); color: inherit; text-decoration: none; }
.ct-tabs li.active a { border-color: var(--ct-accent); background: var(--ct-accent); color: #fff; }
.ct-tabs li.active a .ct-tab-type { background: rgba(255,255,255,0.25); color: #fff; }
.ct-tabs-small { margin-bottom: 10px; }
.ct-tab-type { display: inline-block; padding: 0 6px; border-radius: 8px; background: #e2e9f0; color: #34495e; font-size: 0.85em; font-weight: bold; text-transform: uppercase; }
.ct-season-select { max-width: 100%; }
.ct-season-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; margin: 8px 0 10px; border-radius: 8px; background: var(--ct-soft); border: 1px solid var(--ct-border); }
.ct-season-head h3 { margin: 0 0 2px; border: 0; padding: 0; font-size: 1.25em; text-transform: none; font-family: inherit; }
.ct-season-status { padding: 4px 10px; border-radius: 14px; background: #dff3e8; color: #13854e; font-weight: bold; }
.ct-season-status.finished { background: #e7e7e7; color: #555; }

/* Cartes, grilles */
.ct-card { padding: 10px 12px; margin-bottom: 10px; border: 1px solid var(--ct-border); border-radius: 8px; background: var(--ct-card); }
.ct-card h3 { margin: 0 0 8px; padding-bottom: 4px; font-size: 1.1em; text-transform: none; font-family: inherit; }
.ct-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 10px; }
.ct-grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.ct-col-main, .ct-col-side { min-width: 0; }
@media (max-width: 900px) { .ct-grid { grid-template-columns: minmax(0, 1fr); } }

/* Indicateurs */
.ct-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; margin-bottom: 10px; }
.ct-kpi { display: flex; flex-direction: column; padding: 10px 12px; border: 1px solid var(--ct-border); border-radius: 8px; background: var(--ct-card); }
.ct-kpi-label { color: var(--ct-muted); font-size: 0.9em; text-transform: uppercase; letter-spacing: 0.03em; }
.ct-kpi-value { font-size: 1.6em; font-weight: bold; line-height: 1.3; }
.ct-kpi-value small { font-size: 0.55em; color: var(--ct-muted); }
.ct-kpi-sub { font-size: 0.9em; color: var(--ct-muted); }

/* Tableaux */
.ct-table-wrap { overflow-x: auto; }
.ct-table { width: 100%; border-collapse: collapse; }
.ct-table th { padding: 6px; border-bottom: 2px solid var(--ct-border); text-align: left; font-size: 0.9em; color: var(--ct-muted); text-transform: uppercase; white-space: nowrap; }
.ct-table td { padding: 6px; border-bottom: 1px solid #edf1f5; vertical-align: middle; }
.ct-table tbody tr:hover td { background: #f8fafc; }
.ct-table .ct-num { text-align: right; white-space: nowrap; }
.ct-table.ct-compact td, .ct-table.ct-compact th { padding: 4px 5px; }
.ct-table tr.ct-me td { background: #fff8d6; font-weight: bold; }
.ct-rank-col { width: 40px; text-align: center; }
.ct-share-col { width: 110px; }
.ct-share-col small { color: var(--ct-muted); }
.ct-bar { height: 6px; border-radius: 3px; background: #e8edf2; overflow: hidden; }
.ct-bar span { display: block; height: 100%; background: var(--ct-accent); }
@media (max-width: 700px) { .ct-hide-sm { display: none; } }

/* Symboles, médailles */
.ct-sym { display: inline-block; min-width: 38px; padding: 1px 6px; border-radius: 4px; background: #eef3ff; color: #1d3f8a; font-weight: bold; font-family: Consolas, Monaco, monospace; text-align: center; }
.ct-sym.ct-fiat { background: #ecf8ef; color: #1c6b3a; }
.ct-medal { display: inline-block; width: 22px; height: 22px; line-height: 22px; border-radius: 50%; background: #e8edf2; color: #34495e; font-size: 0.85em; font-weight: bold; text-align: center; }
.ct-medal-1 { background: linear-gradient(135deg, #ffe680, #d4a514); color: #5a4300; }
.ct-medal-2 { background: linear-gradient(135deg, #f2f2f2, #a8a8a8); color: #3d3d3d; }
.ct-medal-3 { background: linear-gradient(135deg, #f3c299, #b8743c); color: #4a2a0c; }
.ct-live { display: inline-block; padding: 0 6px; border-radius: 8px; background: #fdecec; color: #c62a2a; font-size: 0.8em; font-weight: bold; }

/* Formulaire d'ordre */
.ct-side-switch { display: flex; gap: 0; margin-bottom: 10px; border-radius: 6px; overflow: hidden; border: 1px solid var(--ct-border); }
.ct-side { flex: 1; cursor: pointer; text-align: center; }
.ct-side input { position: absolute; opacity: 0; pointer-events: none; }
.ct-side span { display: block; padding: 8px; font-weight: bold; background: var(--ct-soft); }
.ct-side-buy input:checked + span { background: var(--ct-up); color: #fff; }
.ct-side-sell input:checked + span { background: var(--ct-down); color: #fff; }
.ct-form-row { margin-bottom: 10px; }
.ct-form-row > label { display: block; margin-bottom: 3px; font-weight: bold; }
.ct-pair, .ct-amount-row { display: flex; gap: 6px; align-items: center; }
.ct-pair select { flex: 1; min-width: 0; }
.ct-amount-row input { flex: 1; min-width: 0; font-size: 1.2em; padding: 5px; }
.ct-rate, .ct-balance { margin-top: 3px; font-size: 0.9em; color: var(--ct-muted); }
.ct-quick { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.ct-estimate { padding: 8px 10px; border-radius: 6px; background: var(--ct-soft); border: 1px dashed var(--ct-border); }
.ct-estimate.ct-error { background: #fdecec; border-color: #f1b0b0; color: #8f1d1d; }
.ct-submit { margin-top: 8px; }
.button.ct-btn-primary { background: var(--ct-accent, #105289); border-color: #0b3d66; color: #fff; }
.button.ct-btn-primary:hover { background: #0b3d66; color: #fff; }
.ct-join p { margin: 0 0 8px; }

/* Graphiques */
.ct-chart { position: relative; width: 100%; min-height: 220px; }
.ct-chart svg { display: block; width: 100%; height: 260px; }
.ct-chart .ct-grid-line { stroke: #e3e8ee; stroke-width: 1; }
.ct-chart .ct-base-line { stroke: #9aa5b1; stroke-dasharray: 4 4; stroke-width: 1; }
.ct-chart text { fill: #6b7785; font-size: 11px; }
.ct-chart-legend { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; font-size: 0.9em; }
.ct-chart-legend i { display: inline-block; width: 12px; height: 3px; margin-right: 4px; vertical-align: middle; }
.ct-chart-tip { position: absolute; pointer-events: none; padding: 4px 8px; border-radius: 4px; background: rgba(20,30,40,0.9); color: #fff; font-size: 0.85em; white-space: nowrap; display: none; }

/* Barres horizontales */
.ct-hbars { display: flex; flex-direction: column; gap: 5px; }
.ct-hbar { display: grid; grid-template-columns: 95px 1fr 55px; gap: 6px; align-items: center; }
.ct-hbar-label { font-size: 0.9em; white-space: nowrap; }
.ct-hbar-track { height: 12px; border-radius: 6px; background: #edf1f5; overflow: hidden; }
.ct-hbar-fill { display: block; height: 100%; background: var(--ct-up); }
.ct-hbar-fill.neg { background: var(--ct-down); }
.ct-hbar-val { text-align: right; font-weight: bold; font-size: 0.9em; }

/* Faits marquants, palmarès, joueur */
.ct-facts { list-style: none; margin: 0; padding: 0; }
.ct-facts li { padding: 6px 0; border-bottom: 1px solid #edf1f5; }
.ct-facts li > span:first-child { display: block; color: var(--ct-muted); font-size: 0.85em; text-transform: uppercase; }
.ct-podiums { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.ct-podium-card { padding: 8px 10px; border: 1px solid var(--ct-border); border-radius: 8px; background: var(--ct-soft); }
.ct-podium-head { display: flex; flex-direction: column; gap: 2px; margin-bottom: 6px; }
.ct-podium-head .ct-tab-type { align-self: flex-start; }
.ct-podium-list { list-style: none; margin: 0; padding: 0; }
.ct-podium-list li { display: flex; align-items: center; gap: 6px; padding: 3px 0; }
.ct-podium-val { margin-left: auto; font-size: 0.9em; white-space: nowrap; }
.ct-player-head { display: flex; align-items: center; gap: 14px; }
.ct-player-head h3 { border: 0; margin: 0 0 6px; font-size: 1.4em; }
.ct-avatar img { max-width: 80px; height: auto; border-radius: 8px; }
.ct-medals-big { display: flex; gap: 14px; font-weight: bold; }
.ct-rules ol li { margin-bottom: 6px; line-height: 1.5; }
.ct-footnote { margin-top: 6px; color: var(--ct-muted, #6b7785); font-size: 0.85em; text-align: right; }

/* Bloc index */
.ct-index-seasons { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 8px; }
.ct-index-top { list-style: none; margin: 4px 0 0; padding: 0; }
.ct-index-top li { display: flex; align-items: center; gap: 6px; padding: 2px 0; }
.ct-index-top li > span:last-child { margin-left: auto; }
.ct-index-block .ct-medal { width: 18px; height: 18px; line-height: 18px; font-size: 0.75em; }
.ct-index-block .ct-medal-1 { background: linear-gradient(135deg, #ffe680, #d4a514); }
.ct-index-block .ct-up { color: #13854e; }
.ct-index-block .ct-down { color: #c62a2a; }
.ct-index-block .ct-muted { color: #6b7785; }

/* Recommandation */
.ct-share-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.ct-share-btn { display: flex; align-items: center; gap: 6px; padding: 6px 8px; border: 0; border-radius: 6px; color: #fff !important; font: inherit; font-weight: bold; text-decoration: none !important; cursor: pointer; }
.ct-share-btn:hover { filter: brightness(1.1); }
.ct-share-whatsapp { background: #25d366; }
.ct-share-telegram { background: #229ed9; }
.ct-share-facebook { background: #1877f2; }
.ct-share-x { background: #14171a; }
.ct-share-linkedin { background: #0a66c2; }
.ct-share-reddit { background: #ff4500; }
.ct-share-email { background: #6b7785; }
.ct-share-copy { background: #105289; }
.ct-share-copy.done { background: #13854e; }

/* Avertissement */
.ct-disclaimer { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 6px; padding: 12px 14px; border: 2px solid #e0a800; border-radius: 8px; background: #fff8e1; color: #5c4400; }
.ct-disclaimer > .icon { font-size: 1.8em; color: #d48c00; margin-top: 2px; }
.ct-disclaimer strong { display: block; font-size: 1.15em; margin-bottom: 3px; }
.ct-disclaimer p { margin: 0; line-height: 1.5; }

/* Graphique en direct */
.ct-live-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.ct-live-head h3 { margin-bottom: 4px; }
.ct-live-dot { display: inline-block; width: 8px; height: 8px; margin-left: 4px; border-radius: 50%; background: #e53935; vertical-align: middle; animation: ct-pulse 1.6s infinite; }
@keyframes ct-pulse { 0% { box-shadow: 0 0 0 0 rgba(229,57,53,.6); } 70% { box-shadow: 0 0 0 7px rgba(229,57,53,0); } 100% { box-shadow: 0 0 0 0 rgba(229,57,53,0); } }
.ct-live-quote { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; margin: 4px 0 6px; }
.ct-live-price { font-size: 1.8em; font-weight: bold; border-radius: 4px; padding: 0 4px; }
.ct-live-change { font-weight: bold; }
.ct-live-period { margin-left: auto; display: inline-flex; gap: 3px; }
.ct-live-period .button.active { background: var(--ct-accent, #105289); border-color: #0b3d66; color: #fff; }
.ct-live-stats { display: flex; flex-wrap: wrap; gap: 14px; font-size: 0.95em; color: var(--ct-muted, #6b7785); }
.ct-live-msg { padding: 90px 0; text-align: center; }
.ct-live-stamp { margin: 4px 0 0; }
@keyframes ct-flash-up { from { background: rgba(19,133,78,.25); } to { background: transparent; } }
@keyframes ct-flash-down { from { background: rgba(198,42,42,.25); } to { background: transparent; } }
.ct-flash-up { animation: ct-flash-up 1.5s ease-out; }
.ct-flash-down { animation: ct-flash-down 1.5s ease-out; }

/* Marché avec beaucoup d'actifs */
.ct-market-search { width: 100%; box-sizing: border-box; margin-bottom: 6px; padding: 4px 6px; }
.ct-market-scroll { max-height: 480px; overflow-y: auto; }
.ct-market-scroll thead th { position: sticky; top: 0; background: var(--ct-card, #fff); z-index: 1; }

/* ---- Version 2.0 ---- */
.ct-badge { display: inline-block; padding: 1px 6px; border-radius: 10px; background: #e8eef5; color: #29435c; font-size: 0.75em; font-weight: bold; vertical-align: middle; }
.ct-badge-short { background: #fde7e7; color: #a32121; }
.ct-btn-small { padding: 2px 6px; min-height: 0; }
.ct-short-exposure { margin: 8px 0 0; padding: 6px 8px; border-left: 3px solid #c62a2a; background: #fdf2f2; }
.ct-short-note { color: #a35b00; font-weight: bold; }

/* Ordres conditionnels */
.ct-order-type-row select { min-width: 180px; }
.ct-trigger-row { margin-top: 8px; }
.ct-trigger-row label { display: block; font-weight: bold; margin-bottom: 3px; }
.ct-trigger-row input { width: 100%; box-sizing: border-box; }
.ct-order-status-1 td { opacity: .85; }
.ct-order-status-2 td, .ct-order-status-3 td, .ct-order-status-4 td { opacity: .6; }

/* Lien fiche crypto */
.ct-coin-link { color: var(--ct-muted, #6b7785); margin-left: 2px; }
.ct-coin-link:hover { color: var(--ct-accent, #105289); }
.ct-live-info { margin-left: auto; margin-right: 6px; font-size: 0.9em; }

/* Actualités */
.ct-news-list { list-style: none; margin: 0; padding: 0; }
.ct-news-list li { padding: 6px 0; border-bottom: 1px solid rgba(0,0,0,.07); }
.ct-news-list li:last-child { border-bottom: 0; }
.ct-news-list li > a { display: block; font-weight: bold; line-height: 1.35; }
.ct-news-list li > span { display: block; margin-top: 2px; }
.ct-news-full li { padding: 10px 0; }
.ct-news-full p { margin: 4px 0; line-height: 1.5; }

/* Trophées */
.ct-trophy-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.ct-trophy-grid-small { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.ct-trophy { display: flex; align-items: flex-start; gap: 8px; padding: 8px 10px; border-radius: 8px; background: #f6f8fb; border: 1px solid rgba(0,0,0,.06); }
.ct-trophy > .icon { font-size: 1.6em; margin-top: 2px; }
.ct-trophy-grid-small .ct-trophy { align-items: center; font-weight: bold; font-size: 0.9em; }
.ct-trophy-grid-small .ct-trophy > .icon { font-size: 1.3em; margin: 0; }
.ct-trophy strong, .ct-trophy div > span { display: block; }
.ct-trophy-locked { filter: grayscale(1); opacity: .45; }
.ct-trophy-gold > .icon, .ct-trophy-icon.ct-trophy-gold { color: #c9971a; }
.ct-trophy-silver > .icon, .ct-trophy-icon.ct-trophy-silver { color: #8a96a3; }
.ct-trophy-bronze > .icon, .ct-trophy-icon.ct-trophy-bronze { color: #b06a2c; }
.ct-trophy-blue > .icon, .ct-trophy-icon.ct-trophy-blue { color: #105289; }
.ct-trophy-green > .icon, .ct-trophy-icon.ct-trophy-green { color: #13854e; }
.ct-trophy-purple > .icon, .ct-trophy-icon.ct-trophy-purple { color: #7a3fb0; }
.ct-trophy-red > .icon, .ct-trophy-icon.ct-trophy-red { color: #c62a2a; }

/* Fiche crypto */
.ct-coin-head { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.ct-coin-head h3 { border: 0; margin: 0 0 4px; font-size: 1.4em; }
.ct-coin-title { flex: 1; min-width: 200px; }
.ct-coin-logo { border-radius: 50%; }
.ct-coin-price strong { font-size: 1.5em; }
.ct-coin-stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
.ct-coin-stats > div { padding: 8px 10px; border-radius: 6px; background: #f6f8fb; }
.ct-coin-stats span, .ct-coin-stats strong, .ct-coin-stats small { display: block; }
.ct-coin-stats span { color: var(--ct-muted, #6b7785); font-size: 0.85em; }
.ct-coin-desc p { line-height: 1.6; margin: 0 0 8px; }
.ct-dl { display: grid; grid-template-columns: auto 1fr; gap: 4px 10px; margin: 0 0 8px; }
.ct-dl dt { color: var(--ct-muted, #6b7785); }
.ct-dl dd { margin: 0; font-weight: bold; text-align: right; }
.ct-coin-links { list-style: none; margin: 6px 0; padding: 0; }
.ct-coin-links li { padding: 2px 0; }
.ct-coin-nav { display: flex; flex-wrap: wrap; gap: 4px; }
.ct-coin-nav a { padding: 2px 7px; border-radius: 4px; background: #eef2f7; font-weight: bold; font-size: 0.85em; text-decoration: none; }
.ct-coin-nav a.active { background: var(--ct-accent, #105289); color: #fff; }

/* Sous les messages et dans le profil */
.ct-postrow a { text-decoration: none; }
.ct-postrow-medals { display: inline-flex; gap: 2px; vertical-align: middle; }
.ct-postrow .ct-medal, .ct-profile .ct-medal { width: 18px; height: 18px; line-height: 18px; font-size: 0.75em; display: inline-block; text-align: center; border-radius: 50%; font-weight: bold; }
.ct-postrow-trophies, .ct-postrow-rank { margin-left: 4px; white-space: nowrap; }
.ct-postrow .ct-up, .ct-profile .ct-up { color: #13854e; }
.ct-postrow .ct-down, .ct-profile .ct-down { color: #c62a2a; }
