﻿/* ===== Millionaire Simulator — site Helvetica + light theme ===== */

.sim-section {
  --bg: #ffffff;
  --grn: #111111;
  --grn2: #000000;
  --grndim: #666666;
  --ink: #1a1a1a;
  --dim: #666666;
  --acc: 0, 0, 0;
  --line: rgba(0, 0, 0, 0.2);
  --good: #1a7a2e;
  --bad: #d12b2b;
  background: #ffffff;
  color: var(--ink);
  padding: 80px 40px 90px;
  border-top: 4px solid #000;
  border-bottom: 4px solid #000;
  position: relative;
  z-index: 2;
}

.sim-section,
.sim-section *:not(svg):not(path) {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
}

.sim-wrap {
  max-width: 1100px;
  margin: 0 auto;
}

.sim-section .sechead {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 22px;
}

.sim-section .sechead .n {
  color: var(--grndim);
  font-size: 14px;
  letter-spacing: 0.06em;
  font-weight: 700;
  text-transform: uppercase;
}

.sim-section .sechead h2 {
  margin: 0;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 800;
  color: #000;
  letter-spacing: -0.02em;
  text-shadow: none;
  text-transform: lowercase;
}

.sim-section .gintro {
  max-width: none;
  margin-bottom: 22px;
  border: 3px solid #000;
  border-radius: 12px;
  background: #fafafa;
  padding: 18px 20px;
  font-size: 15px;
  line-height: 1.7;
  color: #222;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.75);
}

.sim-section .gintro .g {
  color: #000;
  font-weight: 800;
}

.sim-section .gframe {
  position: relative;
  border: 3px solid #000;
  border-radius: 12px;
  background: #f4f4f4;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.8);
  overflow: hidden;
}

.sim-section .gframe:before,
.sim-section .gframe:after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border: 2px solid #000;
  z-index: 6;
  pointer-events: none;
}

.sim-section .gframe:before {
  left: 8px;
  top: 8px;
  border-right: 0;
  border-bottom: 0;
}

.sim-section .gframe:after {
  right: 8px;
  bottom: 8px;
  border-left: 0;
  border-top: 0;
}

.sim-section .gframe.shake {
  animation: gshake 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97);
}

@keyframes gshake {
  10% { transform: translate(-6px, 3px); }
  20% { transform: translate(7px, -4px); }
  30% { transform: translate(-9px, 2px); }
  40% { transform: translate(7px, 4px); }
  50% { transform: translate(-6px, -3px); }
  60% { transform: translate(5px, 2px); }
  70% { transform: translate(-4px, -2px); }
  80% { transform: translate(3px, 2px); }
  100% { transform: translate(0, 0); }
}

.sim-section #gCanvas {
  display: block;
  width: 100%;
  height: clamp(360px, 45vw, 600px);
  touch-action: none;
  background: #ececec;
}

.sim-section .gframe.playing #gCanvas {
  cursor: none;
}

.sim-section .ghud {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  z-index: 4;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 22px;
  pointer-events: none;
}

.sim-section .ghud-lab {
  color: var(--dim);
  font-size: 11px;
  letter-spacing: 0.08em;
  font-weight: 700;
  text-transform: uppercase;
}

.sim-section .gnet {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.05;
  color: var(--bad);
  text-shadow: none;
  transition: color 0.18s;
  letter-spacing: -0.02em;
}

.sim-section .gnet.up {
  color: var(--good);
  text-shadow: none;
}

.sim-section .gstatus {
  color: var(--dim);
  font-size: 11px;
  letter-spacing: 0.06em;
  margin-top: 3px;
  font-weight: 600;
}

.sim-section .gstrikes {
  display: flex;
  gap: 11px;
  padding-top: 5px;
}

.sim-section .gstrikes span {
  width: 15px;
  height: 15px;
  position: relative;
  opacity: 0.25;
  transition: 0.15s;
}

.sim-section .gstrikes span:before,
.sim-section .gstrikes span:after {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: 2.4px;
  height: 15px;
  background: var(--bad);
  border-radius: 2px;
}

.sim-section .gstrikes span:before {
  transform: translateX(-50%) rotate(45deg);
}

.sim-section .gstrikes span:after {
  transform: translateX(-50%) rotate(-45deg);
}

.sim-section .gstrikes span.hit {
  opacity: 1;
}

.sim-section .ghud-r {
  text-align: right;
  flex: 0 0 auto;
}

.sim-section .gtime {
  color: var(--dim);
  font-size: 12px;
  letter-spacing: 0.04em;
  margin-bottom: 7px;
  font-weight: 700;
}

.sim-section .glegend {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  padding: 10px 16px;
  font-size: 11px;
  letter-spacing: 0.02em;
  color: #444;
  text-align: center;
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.92));
  pointer-events: none;
}

.sim-section .glegend .bad {
  color: var(--bad);
  font-weight: 700;
}

.sim-section .gover {
  position: absolute;
  inset: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(3px);
}

.sim-section .gover-in {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 22px;
}

.sim-section .gover-t {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 42px;
  font-weight: 800;
  line-height: 1;
  color: #000;
  text-shadow: none;
  letter-spacing: -0.02em;
}

.sim-section .gover-end .gover-t {
  color: var(--bad);
}

.sim-section .gover-end .gover-t.win {
  color: var(--good);
}

.sim-section .gover-s {
  color: var(--dim);
  font-size: 13px;
  letter-spacing: 0.02em;
}

.sim-section .gover-score {
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--dim);
  font-weight: 700;
  text-transform: uppercase;
}

.sim-section .gover-score b {
  display: block;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 42px;
  font-weight: 800;
  color: #000;
  margin-top: 5px;
  text-shadow: none;
  letter-spacing: -0.02em;
}

.sim-section .gover-btns {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 6px;
}

.sim-section .gover .gagain {
  width: 100%;
  max-width: 342px;
  margin-top: 2px;
}

.sim-section .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  border: 3px solid #000;
  color: #000;
  padding: 14px 26px;
  letter-spacing: 0.02em;
  font-weight: 700;
  background: #fff;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.8);
  transition: 0.15s;
  cursor: pointer;
  text-decoration: none;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  border-radius: 8px;
}

.sim-section .btn:hover {
  background: #000;
  color: #fff;
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.8);
}

.sim-section .btn.big {
  font-size: 18px;
}

.sim-section .btn .bi {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  color: currentColor;
}

.sim-section .btn .bi svg {
  width: 100%;
  height: 100%;
  display: block;
}

.sim-section .btn .bi-x {
  width: 15px;
  height: 15px;
}

.sim-section #gFlex {
  align-items: center;
}

.sim-section .gsave {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2px;
}

.sim-section .gsave input {
  background: #fff;
  border: 3px solid #000;
  color: #111;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 14px;
  padding: 11px 14px;
  width: 220px;
  max-width: 70vw;
  outline: 0;
  letter-spacing: 0.02em;
  border-radius: 8px;
}

.sim-section .gsave input::placeholder {
  color: #888;
}

.sim-section .gsave input:focus {
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.15);
}

.sim-section .gsave .btn {
  padding: 11px 22px;
}

.sim-section .gsaved {
  color: var(--good);
  font-size: 12px;
  letter-spacing: 0.02em;
}

.sim-section .lbwrap {
  margin-top: 26px;
  border: 3px solid #000;
  border-radius: 12px;
  background: #fff;
  padding: 20px 22px;
  position: relative;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.75);
}

.sim-section .lbhead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.sim-section .lbtitle {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 22px;
  font-weight: 800;
  color: #000;
  letter-spacing: -0.01em;
  text-shadow: none;
}

.sim-section .lbsub {
  color: var(--dim);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.sim-section .lbcols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 30px;
}

.sim-section .lbcol {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sim-section .lbrow {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border: 2px solid #000;
  background: #fafafa;
  border-radius: 8px;
  transition: 0.15s;
}

.sim-section .lbrow .lbrk {
  font-weight: 700;
  color: #555;
  font-size: 13px;
  width: 26px;
  flex: 0 0 auto;
}

.sim-section .lbrow .lbnm {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: 0.01em;
  font-size: 14px;
  color: #111;
}

.sim-section .lbrow .lbsc {
  font-weight: 700;
  color: #000;
  font-size: 13px;
  flex: 0 0 auto;
}

.sim-section .lbrow.top .lbrk {
  color: #000;
}

.sim-section .lbrow.me {
  border-color: #000;
  background: #eee;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.5);
}

.sim-section .lbempty {
  color: var(--dim);
  font-size: 13px;
  padding: 8px 12px;
  border: 1px dashed #999;
}

.sim-section .lbseeall {
  margin-top: 14px;
  width: 100%;
  display: block;
  border: 3px solid #000;
  background: #fff;
  color: #000;
  padding: 12px;
  letter-spacing: 0.02em;
  font-weight: 700;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 13px;
  cursor: pointer;
  transition: 0.15s;
  border-radius: 8px;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.75);
}

.sim-section .lbseeall:hover {
  background: #000;
  color: #fff;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.75);
}

.sim-section .allmodal,
.sim-section .cardmodal {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(4px);
}

.sim-section .allbox {
  width: min(560px, 96vw);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  border: 3px solid #000;
  background: #fff;
  padding: 18px;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.8);
  color: #111;
  border-radius: 12px;
}

.sim-section .allhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.sim-section .alltitle {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 20px;
  font-weight: 800;
  color: #000;
  letter-spacing: -0.01em;
}

.sim-section .allx {
  background: none;
  border: 0;
  color: #666;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

.sim-section .allx:hover {
  color: #000;
}

.sim-section .allsearch input {
  width: 100%;
  background: #fff;
  border: 2px solid #000;
  color: #111;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
  font-size: 14px;
  padding: 11px 14px;
  outline: 0;
  letter-spacing: 0.02em;
  margin-bottom: 12px;
  border-radius: 8px;
}

.sim-section .allsearch input:focus {
  border-color: #000;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.sim-section .alllist {
  flex: 1;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 220px;
}

.sim-section .allrow {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border: 2px solid #000;
  background: #fafafa;
  border-radius: 8px;
}

.sim-section .allrow .lbrk {
  font-weight: 700;
  color: #555;
  font-size: 13px;
  min-width: 46px;
  flex: 0 0 auto;
}

.sim-section .allrow.top3 .lbrk {
  color: #000;
}

.sim-section .allrow .lbnm {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: 0.01em;
  font-size: 14px;
  color: #111;
}

.sim-section .allrow .lbsc {
  font-weight: 700;
  color: #000;
  font-size: 13px;
  flex: 0 0 auto;
}

.sim-section .allempty {
  color: var(--dim);
  font-size: 13px;
  padding: 24px;
  text-align: center;
}

.sim-section .allpager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
}

.sim-section .allpager .btn {
  padding: 9px 14px;
  font-size: 12px;
  flex: 0 0 auto;
}

.sim-section .allpager .btn:disabled {
  opacity: 0.35;
  cursor: default;
  box-shadow: none;
  background: #f5f5f5;
  color: #888;
}

.sim-section .allpageinfo {
  color: var(--dim);
  font-size: 12px;
  letter-spacing: 0.02em;
}

.sim-section .cardmodal {
  z-index: 120;
}

.sim-section .cardbox {
  width: min(760px, 96vw);
  max-height: 94vh;
  overflow: auto;
  border: 3px solid #000;
  background: #fff;
  padding: 18px;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.8);
  color: #111;
  border-radius: 12px;
}

.sim-section .cardcap {
  color: #333;
  font-size: 12px;
  letter-spacing: 0.02em;
  margin-bottom: 12px;
}

.sim-section .cardcanvaswrap {
  border: 2px solid #000;
  line-height: 0;
  border-radius: 8px;
  overflow: hidden;
}

.sim-section #gCardCanvas {
  display: block;
  width: 100%;
  height: auto;
}

.sim-section .cardbtns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.sim-section .cardbtns .btn {
  flex: 1;
  min-width: 120px;
  padding: 12px 10px;
}

.sim-section .cardhint {
  color: var(--dim);
  font-size: 11px;
  letter-spacing: 0.02em;
  margin-top: 10px;
}

@media (max-width: 900px) {
  .sim-section {
    padding: 60px 20px 70px;
  }

  .sim-section #gCanvas {
    height: clamp(430px, 118vw, 560px);
  }

  .sim-section .gnet {
    font-size: 23px;
  }

  .sim-section .ghud {
    padding: 12px 14px;
  }

  .sim-section .gover-t {
    font-size: 30px;
  }

  .sim-section .gover-score b {
    font-size: 32px;
  }

  .sim-section .glegend {
    font-size: 8.5px;
    padding: 8px 10px;
    line-height: 1.5;
  }
}

@media (max-width: 640px) {
  .sim-section .lbcols {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .sim-section .lbtitle {
    font-size: 18px;
  }

  .sim-section .cardbtns .btn {
    min-width: calc(50% - 5px);
  }
}
