/* LYX マーケット（窓・グラフ）・マイページの LMP と LIP・運営のタブ。上がりはミント、下がりはコーラル（島の虹の色から取った） */
:root { --mk-up: #2ee6a6; --mk-down: #ff4d6d; --mk-flat: #a8b1dd; }

/* ---- 窓 ---- */
.mk-head { display: flex; align-items: center; gap: 12px; padding-right: 36px; }
.mk-head h2 { font-size: 22px; margin-bottom: 2px; }
.mk-head .tiny { margin: 0; }
.mk-pic { width: 88px; height: auto; flex: none; filter: drop-shadow(0 8px 14px rgba(76, 201, 255, .28)); }
.mk-kicker { margin: 0; font-size: 11px; font-weight: 800; letter-spacing: .24em; color: var(--r5); }

.mk-now { position: relative; overflow: hidden; isolation: isolate; margin: 14px 0 12px; padding: 16px 14px 14px; border-radius: 18px; text-align: center;
  background: radial-gradient(120% 100% at 50% 0%, #17306a 0%, #0b1030 62%, #070a1f 100%); box-shadow: 0 0 0 2px rgba(76, 201, 255, .32), 0 16px 34px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255, 255, 255, .06); }
.mk-now::after { content: ""; position: absolute; left: 16px; right: 16px; top: 0; height: 3px; border-radius: 0 0 3px 3px; background: var(--rainbow); }
.mk-glow { position: absolute; z-index: -1; left: 50%; top: 26px; width: 300px; max-width: 90%; height: 120px; transform: translateX(-50%); filter: blur(10px); pointer-events: none;
  background: radial-gradient(closest-side, rgba(76, 201, 255, .4), transparent); animation: mkBreath 4.5s ease-in-out infinite; }
.mk-glow.up { background: radial-gradient(closest-side, rgba(46, 230, 166, .42), rgba(76, 201, 255, .16) 60%, transparent); }
.mk-glow.down { background: radial-gradient(closest-side, rgba(255, 77, 109, .36), rgba(155, 123, 255, .16) 60%, transparent); }
@keyframes mkBreath { 50% { opacity: .55; transform: translateX(-50%) scale(1.08); } }
.mk-label { margin: 0; font-size: 13px; font-weight: 800; color: var(--sub); letter-spacing: .12em; }
.mk-big { display: block; font-family: var(--head); font-weight: 400; font-size: clamp(36px, 10.5vw, 58px); line-height: 1.1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere;
  background: linear-gradient(180deg, #ffffff 0%, #bdf3ff 50%, #4cc9ff 100%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 14px rgba(76, 201, 255, .5)); }
.mk-chg { margin: 4px 0 0; font-size: 15px; }
.mk-chg small { color: var(--dim); font-size: 12px; }

.mk-delta { display: inline-block; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mk-delta.up { color: var(--mk-up); }
.mk-delta.down { color: var(--mk-down); }
.mk-delta.flat { color: var(--mk-flat); }
.mk-delta.s { font-size: 12px; }

.mk-ranges { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; padding: 4px; margin-bottom: 8px; border-radius: 14px; background: var(--bg2); border: 1px solid var(--line); }
.mk-range { appearance: none; min-height: 40px; border: 0; border-radius: 10px; background: none; color: var(--sub); font-weight: 800; font-size: 13px; cursor: pointer; padding: 0 2px; }
.mk-range.on { background: linear-gradient(180deg, #2b3c8a, #1c2867); color: var(--ink); box-shadow: inset 0 0 0 2px rgba(76, 201, 255, .55), 0 2px 0 #000; }

/* ---- グラフ ---- */
.mk-chart { position: relative; touch-action: pan-y; user-select: none; -webkit-user-select: none; border-radius: 14px; background: linear-gradient(180deg, rgba(23, 34, 82, .55), rgba(10, 14, 40, .2)); border: 1px solid var(--line); outline-offset: 3px; cursor: crosshair; }
.mk-chart.empty { cursor: default; }
.mk-svg { display: block; width: 100%; height: auto; overflow: visible; }
.mk-grid { stroke: rgba(111, 121, 173, .22); stroke-width: 1; stroke-dasharray: 3 6; }
.mk-ref { stroke: rgba(255, 210, 63, .55); stroke-width: 1.5; stroke-dasharray: 8 6; }
.mk-a0 { stop-color: var(--r5); stop-opacity: .34; } .mk-a1 { stop-color: var(--r5); stop-opacity: 0; }
.mk-l0 { stop-color: var(--r6); } .mk-l1 { stop-color: var(--r5); } .mk-l2 { stop-color: var(--r5); }
.mk-chart[data-dir=up] .mk-a0, .mk-chart[data-dir=up] .mk-a1 { stop-color: var(--mk-up); }
.mk-chart[data-dir=up] .mk-l2 { stop-color: var(--mk-up); }
.mk-chart[data-dir=down] .mk-a0, .mk-chart[data-dir=down] .mk-a1 { stop-color: var(--mk-down); }
.mk-chart[data-dir=down] .mk-l1 { stop-color: var(--r6); } .mk-chart[data-dir=down] .mk-l2 { stop-color: var(--mk-down); }
.mk-line { fill: none; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; animation: mkDraw 1.4s .1s cubic-bezier(.3, .7, .2, 1) forwards; filter: drop-shadow(0 0 6px rgba(76, 201, 255, .55)); }
.mk-area { opacity: 0; animation: mkFade .7s .9s forwards; }
.mk-dot { fill: #f3fdff; stroke: var(--r5); stroke-width: 3; opacity: 0; animation: mkFade .3s 1.4s forwards; }
.mk-chart[data-dir=up] .mk-dot { stroke: var(--mk-up); } .mk-chart[data-dir=down] .mk-dot { stroke: var(--mk-down); }
.mk-pulse { fill: rgba(76, 201, 255, .35); transform-box: fill-box; transform-origin: center; opacity: 0; animation: mkPulse 2.2s 1.6s ease-out infinite; }
.mk-chart[data-dir=up] .mk-pulse { fill: rgba(46, 230, 166, .35); } .mk-chart[data-dir=down] .mk-pulse { fill: rgba(255, 77, 109, .3); }
.mk-ghost { fill: none; stroke: rgba(76, 201, 255, .4); stroke-width: 3; stroke-dasharray: 2 12; stroke-linecap: round; }
@keyframes mkDraw { to { stroke-dashoffset: 0; } }
@keyframes mkFade { to { opacity: 1; } }
@keyframes mkPulse { 0% { opacity: .9; transform: scale(.4); } 100% { opacity: 0; transform: scale(1.7); } }

.mk-cross { stroke: rgba(243, 245, 255, .55); stroke-width: 1.2; stroke-dasharray: 4 4; opacity: 0; }
.mk-hot { fill: #fff; stroke: var(--r5); stroke-width: 3; opacity: 0; }
.mk-chart.hover .mk-cross, .mk-chart.hover .mk-hot { opacity: 1; }
.mk-chart.hover .mk-pulse { visibility: hidden; }
.mk-yl, .mk-refl { position: absolute; right: 6px; transform: translateY(-50%); font-size: 10px; font-weight: 700; color: var(--dim); font-variant-numeric: tabular-nums; pointer-events: none; text-shadow: 0 1px 2px #070a1f; }
.mk-refl { left: 6px; right: auto; color: rgba(255, 210, 63, .85); transform: translateY(-120%); }
.mk-tip { position: absolute; z-index: 2; transform: translate(-50%, calc(-100% - 14px)); padding: 6px 10px; border-radius: 10px; background: rgba(7, 10, 31, .94); border: 1.5px solid rgba(76, 201, 255, .6); box-shadow: 0 6px 16px rgba(0, 0, 0, .45);
  display: none; flex-direction: column; align-items: center; gap: 0; white-space: nowrap; pointer-events: none; line-height: 1.35; }
.mk-tip.below { transform: translate(-50%, 16px); }
.mk-chart.hover .mk-tip { display: flex; }
.mk-tip b { font-family: var(--head); font-weight: 400; font-size: 15px; font-variant-numeric: tabular-nums; }
.mk-tip > span { font-size: 11px; color: var(--sub); }
.mk-x { display: flex; justify-content: space-between; gap: 6px; font-size: 11px; color: var(--dim); margin: 4px 2px 0; font-variant-numeric: tabular-nums; }

.mk-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 12px; }
.mk-stat { min-width: 0; padding: 8px 6px; border-radius: 12px; background: var(--bg2); border: 1px solid var(--line); text-align: center; display: flex; flex-direction: column; gap: 1px; }
.mk-stat > span { font-size: 11px; color: var(--dim); font-weight: 700; }
.mk-stat > b { font-family: var(--head); font-weight: 400; font-size: 15px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.mk-stat > b .mk-delta { font-family: var(--body); font-size: 12px; white-space: normal; }
.mk-stat > small { font-size: 10px; color: var(--dim); }
@media (max-width: 420px) { .mk-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.mk-wait { position: relative; }
.mk-wait > p { position: absolute; left: 0; right: 0; bottom: 14px; margin: 0; padding: 0 14px; text-align: center; font-size: 13px; color: var(--sub); }

.mk-mine { appearance: none; width: 100%; margin-top: 14px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: 14px; cursor: pointer; text-align: left; color: var(--ink);
  background: linear-gradient(100deg, rgba(155, 123, 255, .2), rgba(76, 201, 255, .12)); border: 2px solid rgba(155, 123, 255, .5); }
.mk-mine b { font-family: var(--head); font-weight: 400; font-size: 20px; font-variant-numeric: tabular-nums; }
.mk-mine b small { font-family: var(--body); font-size: 12px; color: var(--sub); }
.mk-mine-l { font-size: 12px; font-weight: 800; color: #c9b6ff; letter-spacing: .06em; }
.mk-mine.empty .grow { font-size: 13px; color: var(--sub); min-width: 0; }
.mk-go { margin-left: auto; font-size: 13px; font-weight: 800; color: var(--r5); white-space: nowrap; }

.mk-sec { margin-top: 18px; }
.mk-sec > h3 { font-size: 15px; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.mk-sec > h3::after { content: ""; flex: 1; height: 2px; background: var(--line); }
.mk-news { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.mk-news li { background: rgba(18, 26, 63, .8); border: 1px solid var(--line); border-radius: 12px; padding: 8px 12px; min-width: 0; }
.mk-news .row { gap: 8px; align-items: baseline; flex-wrap: wrap; }
.mk-news time { font-size: 12px; color: var(--dim); font-variant-numeric: tabular-nums; }
.mk-news b { font-family: var(--head); font-weight: 400; font-size: 15px; font-variant-numeric: tabular-nums; }
.mk-news p { margin: 4px 0 0; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }

/* ---- マイページの LMP ---- */
.lmp { position: relative; overflow: hidden; margin-top: 12px; border-color: rgba(155, 123, 255, .55); background: radial-gradient(130% 80% at 100% 0%, rgba(155, 123, 255, .2), transparent 60%), var(--panel); }
.lmp::after { content: ""; position: absolute; left: 14px; right: 14px; top: 0; height: 3px; border-radius: 0 0 3px 3px; background: var(--rainbow); }
.lmp-head { display: flex; align-items: flex-start; gap: 8px; }
.lmp-head h3 { font-size: 17px; }
.lmp-only { flex: none; font-size: 11px; font-weight: 800; color: var(--sub); padding: 3px 9px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg2); }
.lmp-intro { margin: 10px 0 12px; font-size: 14px; color: var(--sub); }
.lmp-now { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; margin: 8px 0 2px; }
.lmp-num { font-family: var(--head); font-weight: 400; font-size: clamp(32px, 9.5vw, 46px); line-height: 1.1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; min-width: 0;
  background: linear-gradient(180deg, #ffffff 0%, #e2d8ff 45%, #9b7bff 100%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 12px rgba(155, 123, 255, .5)); }
.lmp-unit { font-family: var(--head); font-size: 18px; color: #c9b6ff; }
.lmp-chgs { display: flex; flex-wrap: wrap; gap: 2px 16px; margin-bottom: 10px; }
.lmp-chgs p { margin: 0; font-size: 14px; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.lmp-cap { font-size: 12px; color: var(--dim); font-weight: 700; }
.mk-seg { display: inline-flex; padding: 3px; margin-bottom: 8px; border-radius: 12px; background: var(--bg2); border: 1px solid var(--line); }
.mk-seg button { appearance: none; min-width: 84px; min-height: 36px; border: 0; border-radius: 9px; background: none; color: var(--sub); font-weight: 800; font-size: 13px; cursor: pointer; }
.mk-seg button.on { background: linear-gradient(180deg, #3a2f80, #261d5e); color: var(--ink); box-shadow: inset 0 0 0 2px rgba(155, 123, 255, .6); }
.lmp .mk-chart .mk-a0, .lmp .mk-chart .mk-a1 { stop-color: var(--r6); }
.lmp .mk-chart[data-dir=up] .mk-a0, .lmp .mk-chart[data-dir=up] .mk-a1 { stop-color: var(--mk-up); }
.lmp .mk-chart[data-dir=down] .mk-a0, .lmp .mk-chart[data-dir=down] .mk-a1 { stop-color: var(--mk-down); }
.lmp-base { margin: 8px 0 0; }
.lmp-btns { margin-top: 10px; gap: 8px; flex-wrap: wrap; }
.lip { margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: linear-gradient(100deg, rgba(255, 210, 63, .14), rgba(255, 159, 28, .06)); border: 1.5px solid rgba(255, 210, 63, .45); display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; }
.lip-t b { font-family: var(--head); font-weight: 400; font-size: 18px; color: var(--accent); margin-right: 6px; }
.lip-t { display: flex; flex-wrap: wrap; align-items: baseline; }
.lip-t span { font-size: 12px; font-weight: 800; color: var(--sub); white-space: nowrap; }
.lip-v { text-align: right; white-space: nowrap; }
.lip-v em { font-style: normal; font-family: var(--head); font-size: 22px; color: var(--accent); font-variant-numeric: tabular-nums; }
.lip-v small { font-size: 12px; color: var(--sub); }
.lip .tiny { grid-column: 1 / -1; margin: 2px 0 0; }
.lmp-form h2 { margin-bottom: 6px; padding-right: 36px; }
.mk-prev { display: block; margin: -8px 0 12px; color: var(--r5); font-weight: 800; font-variant-numeric: tabular-nums; }
.lmp-form .link { display: block; margin: 12px auto 0; }

/* ---- 運営メニュー ---- */
.mk-adm > .tiny { margin: 0 0 10px; }
.mk-admnow { display: flex; align-items: baseline; justify-content: center; gap: 8px; flex-wrap: wrap; padding: 14px; margin-bottom: 10px; border-radius: 14px; background: radial-gradient(120% 120% at 50% 0%, #17306a, #0b1030); border: 2px solid rgba(76, 201, 255, .35); }
.mk-admnow span { color: var(--sub); font-weight: 700; }
.mk-admnow b { font-family: var(--head); font-weight: 400; font-size: clamp(26px, 8vw, 40px); color: var(--r5); overflow-wrap: anywhere; min-width: 0; }
.mk-admnow small { color: var(--dim); width: 100%; text-align: center; }
.mk-form { margin-top: 12px; }
.mk-form h4 { margin: 0 0 10px; }
.mk-when { gap: 10px; align-items: flex-end; }
.mk-when .field { flex: 1; min-width: 0; }

@media (prefers-reduced-motion: reduce) {
  .mk-glow, .mk-pulse { animation: none; }
  .mk-line { animation: none; stroke-dashoffset: 0; }
  .mk-area, .mk-dot { animation: none; opacity: 1; }
}
