/* Lawyer Tycoon v5: uzun vadeli ekonomi ve ofis genişlemesi */

.venture-card {
  grid-template-columns: clamp(108px, 8.1vw, 140px) minmax(0, 1fr);
}

.venture-body {
  grid-template-rows: minmax(43px, 1.08fr) clamp(24px, 3.1vh, 31px) minmax(43px, 1fr);
  gap: clamp(4px, .55vh, 7px);
  padding: 7px 9px 7px 1px;
}

.venture-heading {
  grid-template-columns: minmax(0, .9fr) minmax(clamp(142px, 11vw, 205px), 1.1fr);
  align-items: stretch;
}

.venture-heading > .venture-title {
  display: grid;
  align-content: center;
  min-width: 0;
  padding: 5px 8px 5px 12px;
}

.venture-title strong {
  display: -webkit-box;
  overflow: hidden;
  font-size: clamp(13px, 1.12vw, 20px);
  line-height: 1.02;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.venture-title small {
  display: none;
}

.manager-shortcut {
  position: relative;
  display: grid;
  grid-template-columns: clamp(34px, 2.7vw, 45px) minmax(0, 1fr);
  align-items: center;
  align-self: stretch;
  min-width: 0;
  padding: 2px 7px 2px 3px;
  cursor: pointer;
  color: #eff8ff;
  border: 0;
  border-left: 3px solid #071b2d;
  border-radius: 0;
  background: linear-gradient(145deg, #126b9d, #082e4e);
  box-shadow: inset 0 0 0 2px rgba(107, 211, 255, .45);
  text-align: left;
}

.manager-shortcut img {
  width: 100%;
  height: 100%;
  max-height: 47px;
  margin: 0;
  object-fit: contain;
}

.manager-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.manager-copy small {
  overflow: hidden;
  color: #9ee5ff;
  font-size: clamp(6px, .48vw, 8px);
  font-weight: 1000;
  letter-spacing: .09em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.manager-copy strong {
  overflow: hidden;
  color: #fff6c9;
  font-family: var(--font-ui);
  font-size: clamp(8px, .67vw, 11px);
  line-height: 1.08;
  text-overflow: ellipsis;
  text-shadow: 0 1px 0 #031524;
  white-space: nowrap;
}

.manager-shortcut:hover:not(:disabled) {
  filter: brightness(1.12);
}

.manager-shortcut:active:not(:disabled) {
  box-shadow: inset 0 0 0 2px #ffd562;
  transform: translateY(1px);
}

.manager-shortcut:disabled {
  cursor: not-allowed;
  filter: grayscale(.7) brightness(.75);
}

.manager-shortcut.hired {
  color: #efffdc;
  background: linear-gradient(145deg, #62c546, #286e29);
  box-shadow: inset 0 0 0 2px #d9ff9c;
}

.run-button {
  min-height: 24px;
  padding: 1px 10px;
  border-width: 2px;
  border-radius: 9px 6px 10px 6px;
}

.run-label {
  font-size: clamp(10px, .82vw, 14px);
  letter-spacing: .01em;
}

.run-button em {
  font-size: clamp(15px, 1.15vw, 20px);
}

.venture-footer {
  grid-template-columns: minmax(0, 1fr) clamp(92px, 7.2vw, 126px);
  gap: 6px;
}

.buy-button {
  min-height: 42px;
  padding: 5px 11px;
}

.buy-button span {
  font-size: clamp(10px, .8vw, 14px);
}

.buy-button strong {
  font-size: clamp(11px, .9vw, 15px);
}

.timer-pill {
  min-height: 42px;
  padding: 4px 8px;
}

.venture-card.locked .manager-shortcut {
  filter: grayscale(.9) brightness(.72);
}

.venture-card.office-gated .buy-button {
  color: #fff2d4;
  background: linear-gradient(#be6a37, #8b3026);
}

.cash-panel small.cashflow-positive {
  color: #31732e;
}

.cash-panel small.has-expense {
  color: #6e3b1e;
}

/* Sol raydaki süreli olay kartı */
.sidebar-event-card {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  flex: 0 0 clamp(67px, 8.2vh, 84px);
  align-items: center;
  width: calc(100% - 17px);
  margin: 0 4px 0 13px;
  padding: 7px 8px;
  overflow: hidden;
  color: #fff8db;
  border: 3px solid #061a2d;
  border-radius: 17px 10px 16px 9px;
  background: linear-gradient(135deg, #9d2638, #df6a25);
  box-shadow: inset 0 0 0 2px #ffd45e, 0 4px 0 #041521;
  text-align: left;
}

.sidebar-event-card.buff {
  background: linear-gradient(135deg, #1a7551, #54a431);
}

.sidebar-event-card.debuff {
  background: linear-gradient(135deg, #8f2532, #d25b27);
}

.sidebar-event-card[hidden] {
  display: none;
}

.event-sprite,
.office-sprite,
.office-item-sprite {
  display: block;
  background-repeat: no-repeat;
}

.event-sprite {
  width: 43px;
  height: 43px;
  border: 2px solid #071b2d;
  border-radius: 10px;
  background-image: url("assets/lawyer-tycoon/generated/timed_events_v1.png");
  background-size: 400% 300%;
  background-position: calc(var(--sprite-x, 0) * 33.333%) calc(var(--sprite-y, 0) * 50%);
}

.sidebar-event-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.sidebar-event-copy strong {
  overflow: hidden;
  font-family: var(--font-display);
  font-size: clamp(10px, .78vw, 13px);
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-event-copy small {
  display: -webkit-box;
  overflow: hidden;
  color: #ffedb1;
  font-size: 8px;
  line-height: 1.12;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.sidebar-event-timer {
  grid-column: 2;
  justify-self: start;
  margin-top: 2px;
  padding: 2px 7px;
  color: #6d3213;
  border-radius: 999px;
  background: #fff2bd;
  font-size: 9px;
  font-weight: 1000;
}

.paper-menu-row.office-required::after {
  content: "!";
  position: absolute;
  top: -5px;
  right: 18px;
  display: grid;
  width: 23px;
  height: 23px;
  place-items: center;
  color: #fff;
  border: 2px solid #601c15;
  border-radius: 50%;
  background: #d9472f;
  box-shadow: inset 0 0 0 2px #ffb75c, 0 2px 0 #49120f;
  font-weight: 1000;
}

/* Kilitler ve nadir yükseltmeler */
.milestone-pills > span {
  min-width: 48px;
}

.milestone-pills > span.rare {
  color: #5b3204;
  border: 2px solid #6c3d05;
  background: linear-gradient(#fff49a, #eaa51c);
  box-shadow: inset 0 0 0 2px #fffacb, 0 2px 0 #5a3407;
}

.milestone-pills > span.rare.done {
  color: #fffbd8;
  border-color: #3e2603;
  background: linear-gradient(#ffc932, #b26808);
  text-shadow: 0 1px 0 #543004;
}

.shop-card.rare-upgrade {
  position: relative;
  border-color: #5b3605;
  background: linear-gradient(145deg, #fffde2, #efc353);
  box-shadow: inset 0 0 0 3px #ffdb51, 0 4px 0 #674006, 0 0 18px rgba(255, 190, 37, .32);
}

.shop-card > .office-item-sprite {
  width: 66px;
  height: 66px;
  flex: 0 0 66px;
  border: 3px solid #071d31;
  border-radius: 14px;
  background-color: #fff8d8;
  box-shadow: inset 0 0 0 2px #e8aa2b, 0 3px 0 rgba(7, 29, 49, .35);
}

.rare-badge {
  position: absolute;
  top: 7px;
  left: 8px;
  padding: 3px 7px;
  color: #fff9ce;
  border-radius: 999px;
  background: #7d4010;
  font-size: 8px;
  font-weight: 1000;
  letter-spacing: .1em;
}

/* Ofis sayfası */
.office-dashboard {
  display: grid;
  gap: 14px;
}

.office-overview {
  display: grid;
  grid-template-columns: minmax(230px, .75fr) minmax(300px, 1.25fr) auto;
  align-items: stretch;
  gap: 12px;
  padding: 12px;
  border: 3px solid #071d31;
  border-radius: 20px 13px 20px 12px;
  background: linear-gradient(145deg, #0d5686, #072d4d);
  box-shadow: inset 0 0 0 3px #e8aa2b, 0 4px 0 #061b2d;
}

.office-current {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: center;
  min-width: 0;
  color: #fff6d0;
}

.office-current .office-sprite {
  width: 92px;
  height: 74px;
}

.office-current-copy {
  display: grid;
  min-width: 0;
}

.office-current-copy small {
  color: #97d9f3;
  font-size: 9px;
  font-weight: 1000;
  letter-spacing: .1em;
}

.office-current-copy strong {
  overflow: hidden;
  font-family: var(--font-display);
  font-size: clamp(18px, 1.6vw, 27px);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.office-ledger {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.office-ledger > div {
  display: grid;
  place-content: center;
  padding: 7px;
  color: #0d2c46;
  border: 2px solid #8f641a;
  border-radius: 11px 7px 11px 7px;
  background: linear-gradient(#fffdf0, #efd58d);
  text-align: center;
}

.office-ledger span {
  color: #745112;
  font-size: 8px;
  font-weight: 1000;
  letter-spacing: .07em;
}

.office-ledger strong {
  overflow: hidden;
  font-size: clamp(11px, .95vw, 16px);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.office-customize-button {
  min-width: 145px;
  padding: 9px 13px;
  cursor: pointer;
  color: #112d43;
  border: 2px solid #061a2d;
  border-radius: 13px 8px 13px 8px;
  background: linear-gradient(#fff48b, #efab22);
  box-shadow: inset 0 0 0 2px #fffad0, 0 3px 0 #724308;
  font-weight: 1000;
}

.office-gate-note {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 13px;
  color: #5f251a;
  border: 2px solid #7b2a1e;
  border-radius: 13px;
  background: #ffe4bb;
  font-weight: 800;
}

.office-tier-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
}

.office-tier-card {
  display: grid;
  grid-template-rows: 112px minmax(94px, 1fr) auto;
  min-width: 0;
  overflow: hidden;
  border: 3px solid #0a263d;
  border-radius: 18px 11px 18px 11px;
  background: linear-gradient(145deg, #fffef6, #f1d797);
  box-shadow: inset 0 0 0 2px #e2a928, 0 4px 0 #092238;
}

.office-tier-card.current {
  border-color: #1c5b24;
  box-shadow: inset 0 0 0 3px #78ce50, 0 4px 0 #174321, 0 0 18px rgba(103, 204, 76, .33);
}

.office-tier-card.locked {
  filter: grayscale(.58);
}

.office-sprite {
  width: 100%;
  height: 100%;
  background-image: url("assets/lawyer-tycoon/generated/office_tiers_v1.png");
  background-size: 400% 200%;
  background-position: calc(var(--sprite-x, 0) * 33.333%) calc(var(--sprite-y, 0) * 100%);
}

.office-tier-copy {
  display: grid;
  align-content: start;
  gap: 3px;
  padding: 9px 10px 5px;
}

.office-tier-copy strong {
  color: #0a355a;
  font-family: var(--font-display);
  font-size: clamp(15px, 1.08vw, 19px);
}

.office-tier-copy p {
  margin: 0;
  color: #263f52;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.38;
}

.office-tier-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.office-tier-meta span {
  padding: 3px 6px;
  color: #62440d;
  border: 1px solid #b9892d;
  border-radius: 999px;
  background: #fff4c6;
  font-size: 10px;
  font-weight: 900;
}

.office-tier-card button {
  min-height: 39px;
  margin: 7px;
  cursor: pointer;
  color: #14320f;
  border: 2px solid #0b273b;
  border-radius: 10px 7px 11px 7px;
  background: linear-gradient(#a8ef6d, #5aba3b);
  box-shadow: inset 0 0 0 2px #dcffbf, 0 2px 0 #183d1e;
  font-weight: 1000;
}

.office-tier-card button:disabled {
  cursor: not-allowed;
  color: #676b69;
  background: linear-gradient(#e7e4db, #b8b9b2);
  filter: grayscale(.55);
}

/* Ofis düzenleme widget'ı */
.game-modal.office-studio-dialog {
  width: min(1120px, 97vw);
}

.office-studio {
  display: grid;
  grid-template-columns: minmax(250px, .7fr) minmax(0, 1.3fr);
  gap: 15px;
}

.office-studio-preview {
  display: grid;
  grid-template-rows: minmax(240px, 1fr) auto;
  overflow: hidden;
  border: 3px solid #071d31;
  border-radius: 18px 11px 18px 11px;
  background: linear-gradient(#0e5d8e, #082e4e);
  box-shadow: inset 0 0 0 3px #e8aa2b;
}

.office-studio-preview .office-sprite {
  min-height: 250px;
}

.office-preview-copy {
  display: grid;
  gap: 3px;
  padding: 11px;
  color: #fff7d6;
  border-top: 3px solid #061a2d;
}

.office-preview-copy span {
  color: #a7def1;
  font-size: 11px;
  font-weight: 1000;
  letter-spacing: .1em;
}

.office-preview-copy strong {
  font: 900 24px/1 var(--font-display);
}

.office-catalog {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 420px;
}

.office-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 5px;
  border: 2px solid #0a2b47;
  border-radius: 13px;
  background: #c5d6df;
}

.office-tabs button {
  min-height: 42px;
  cursor: pointer;
  color: #173553;
  border: 0;
  border-radius: 9px;
  background: transparent;
  font-weight: 1000;
}

.office-tabs button[aria-selected="true"] {
  color: #fff6d0;
  background: linear-gradient(#126b9e, #083452);
  box-shadow: inset 0 0 0 2px #5ec9ee, 0 2px 0 #041b2c;
}

.office-catalog-body {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: start;
  gap: 9px;
  max-height: 55vh;
  padding: 11px 2px 2px;
  overflow: auto;
}

.office-item-card {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 8px;
  min-width: 0;
  padding: 8px;
  border: 2px solid #0a2a43;
  border-radius: 14px 9px 14px 9px;
  background: linear-gradient(#fffef5, #edd798);
  box-shadow: inset 0 0 0 2px #eab139, 0 3px 0 #092238;
}

.office-item-sprite {
  width: 76px;
  height: 76px;
  align-self: center;
  border: 2px solid #0a2a43;
  border-radius: 11px;
  background-image: url("assets/lawyer-tycoon/generated/office_items_v1.png");
  background-size: 400% 200%;
  background-position: calc(var(--sprite-x, 0) * 33.333%) calc(var(--sprite-y, 0) * 100%);
}

.office-item-copy {
  display: grid;
  align-content: start;
  gap: 3px;
  min-width: 0;
}

.office-item-copy strong {
  color: #0a355a;
  font-family: var(--font-display);
  font-size: 15px;
}

.office-item-copy small,
.office-item-copy p {
  margin: 0;
  color: #2f4657;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.office-item-copy button {
  min-height: 31px;
  margin-top: 3px;
  cursor: pointer;
  color: #16320f;
  border: 2px solid #12311a;
  border-radius: 8px;
  background: linear-gradient(#aaf072, #5bbb3d);
  font-size: 12px;
  font-weight: 1000;
}

.office-item-copy button:disabled {
  cursor: not-allowed;
  color: #6b6c69;
  border-color: #4c5252;
  background: linear-gradient(#e5e2da, #b6b8b2);
}

/* İtibar ve dünya sıralaması */
.reputation-dashboard {
  display: grid;
  grid-template-columns: minmax(360px, .85fr) minmax(470px, 1.15fr);
  gap: 15px;
  align-items: stretch;
}

.reputation-dashboard .prestige-panel {
  grid-template-columns: 105px 1fr;
  align-content: center;
  max-width: none;
  min-height: 470px;
  margin: 0;
}

.reputation-dashboard .prestige-panel > img {
  width: 100px;
  height: 100px;
}

.reputation-dashboard .prestige-panel > button {
  grid-column: 1 / -1;
  min-height: 45px;
}

.world-ranking-panel {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  min-height: 470px;
  overflow: hidden;
  border: 3px solid #09263d;
  border-radius: 18px 11px 18px 11px;
  background: linear-gradient(#fffef5, #edd797);
  box-shadow: inset 0 0 0 2px #e2a928, 0 4px 0 #092238;
}

.ranking-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 58px;
  padding: 10px 13px;
  color: #fff6cf;
  background: linear-gradient(#0e5d8f, #082f50);
}

.ranking-header strong {
  font-family: var(--font-display);
  font-size: clamp(20px, 1.65vw, 28px);
}

.ranking-header small {
  color: #9fdbef;
  font-size: 8px;
  font-weight: 1000;
  letter-spacing: .08em;
}

.current-rank-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  min-height: 63px;
  padding: 8px 13px;
  color: #102e4b;
  border-bottom: 2px solid #987020;
  background: linear-gradient(90deg, #ffe878, #fff4bd);
}

.current-rank-card > b {
  font: 1000 clamp(22px, 2vw, 33px)/1 var(--font-display);
}

.current-rank-copy {
  display: grid;
  min-width: 0;
}

.current-rank-copy strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.current-rank-copy small {
  color: #765717;
}

.ranking-list {
  display: grid;
  align-content: start;
  gap: 3px;
  margin: 0;
  padding: 8px;
  overflow: auto;
  list-style: none;
}

.ranking-row {
  display: grid;
  grid-template-columns: 40px 35px minmax(0, 1fr) minmax(76px, auto);
  align-items: center;
  gap: 7px;
  min-height: 39px;
  padding: 4px 8px;
  color: #1c344a;
  border: 1px solid #c8aa63;
  border-radius: 9px;
  background: rgba(255, 253, 239, .72);
}

.ranking-row.player {
  border: 2px solid #1b6d36;
  background: #dff5c4;
}

.ranking-row.top-1 { box-shadow: inset 5px 0 0 #e9ae19; }
.ranking-row.top-2 { box-shadow: inset 5px 0 0 #aeb7bd; }
.ranking-row.top-3 { box-shadow: inset 5px 0 0 #b76d2b; }

.rank-avatar {
  display: grid;
  width: 31px;
  height: 31px;
  place-items: center;
  border: 2px solid #0a2a44;
  border-radius: 50%;
  background: #72c8e9;
  font-size: 16px;
}

.ranking-row > span:last-child {
  color: #6b5018;
  font-size: 10px;
  font-weight: 900;
  text-align: right;
}

/* Gider öğreticisi */
.office-tutorial-ledger {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-top: 12px;
}

.office-tutorial-ledger article {
  display: grid;
  gap: 4px;
  padding: 11px;
  border: 2px solid #8e651a;
  border-radius: 12px;
  background: #fff6d2;
  text-align: center;
}

.office-tutorial-ledger b {
  color: #0b3d63;
}

.office-tutorial-ledger small {
  color: #6c604a;
  line-height: 1.25;
}

@media (max-height: 760px) and (min-width: 981px) {
  .venture-body {
    grid-template-rows: minmax(35px, 1.05fr) 20px minmax(35px, 1fr);
    gap: 3px;
    padding-top: 5px;
    padding-bottom: 5px;
  }

  .venture-heading {
    grid-template-columns: minmax(0, .88fr) minmax(130px, 1.12fr);
  }

  .run-button {
    min-height: 20px;
  }

  .buy-button,
  .timer-pill {
    min-height: 35px;
  }

  .sidebar-event-card {
    grid-template-columns: 34px minmax(0, 1fr);
    flex-basis: 50px;
    padding: 4px 6px;
  }

  .event-sprite {
    width: 32px;
    height: 32px;
  }

  .sidebar-event-copy small {
    display: none;
  }

  .sidebar-event-timer {
    margin: 0;
  }
}

/* 1280x720 gibi yaygın dizüstü görünümünde hiçbir ana değer veya menü adı
   kesilmeden kalır; oyun kartlarının kullanılabilir alanı da korunur. */
@media (max-width: 1320px) and (min-width: 981px) {
  .game-shell {
    grid-template-columns: 232px minmax(0, 1fr);
  }

  .paper-menu {
    padding-left: 13px;
  }

  .paper-menu-row {
    grid-template-columns: 36px minmax(0, 1fr);
    padding-right: 12px;
    padding-left: 8px;
  }

  .paper-menu-row img {
    width: 31px;
    height: 31px;
  }

  .paper-menu-row span {
    font-size: clamp(14px, 1.13vw, 17px);
  }

  .cash-panel strong {
    font-size: clamp(24px, 2.55vw, 34px);
  }

  .top-stat strong {
    font-size: clamp(18px, 1.72vw, 24px);
    letter-spacing: -.025em;
  }
}

@media (max-width: 1180px) {
  .office-tier-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .office-overview {
    grid-template-columns: minmax(220px, .8fr) minmax(0, 1.2fr);
  }

  .office-customize-button {
    grid-column: 1 / -1;
  }

  .reputation-dashboard {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .game-sidebar {
    grid-template-rows: auto 48px 30px;
  }

  .profile-card {
    grid-row: 1 / 4;
  }

  .paper-menu {
    grid-column: 2;
    grid-row: 1;
  }

  .sidebar-event-card {
    grid-column: 2;
    grid-row: 2;
    width: 100%;
    height: 48px;
    margin: 0;
  }

  .sound-button {
    grid-column: 3;
    grid-row: 1 / 4;
  }

  .account-strip {
    grid-column: 2;
    grid-row: 3;
  }
}

@media (max-width: 760px) {
  .venture-body {
    grid-template-rows: minmax(38px, 1fr) 28px minmax(40px, 1fr);
  }

  .venture-heading {
    grid-template-columns: minmax(0, .85fr) minmax(118px, 1.15fr);
  }

  .manager-shortcut {
    grid-template-columns: 30px minmax(0, 1fr);
    padding-right: 4px;
  }

  .manager-copy strong {
    font-size: 8px;
  }

  .office-overview,
  .office-studio {
    grid-template-columns: 1fr;
  }

  .office-ledger {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .office-catalog-body {
    grid-template-columns: 1fr;
  }

  .office-tutorial-ledger {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .game-sidebar {
    grid-template-rows: auto auto 48px 36px;
  }

  .profile-card {
    grid-row: 1 / 3;
  }

  .sidebar-event-card {
    grid-column: 2;
    grid-row: 3;
  }

  .sound-button {
    grid-column: 1;
    grid-row: 3 / 5;
    height: 100%;
  }

  .account-strip {
    grid-column: 2;
    grid-row: 4;
  }

  .office-tier-grid {
    grid-template-columns: 1fr;
  }

  .office-tier-card {
    grid-template-columns: 120px minmax(0, 1fr);
    grid-template-rows: minmax(100px, auto) auto;
  }

  .office-tier-card > .office-sprite {
    grid-row: 1 / 3;
  }

  .office-tier-card button {
    grid-column: 2;
  }

  .world-ranking-panel {
    min-height: 430px;
  }
}

@media (max-width: 450px) {
  .venture-heading {
    grid-template-columns: minmax(0, .8fr) minmax(105px, 1.2fr);
  }

  .manager-copy small {
    display: none;
  }

  .manager-shortcut img {
    max-height: 36px;
  }

  .venture-footer {
    grid-template-columns: minmax(0, 1fr) 82px;
  }

  .office-current {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .office-current .office-sprite {
    width: 70px;
    height: 58px;
  }

  .ranking-row {
    grid-template-columns: 34px 30px minmax(0, 1fr);
  }

  .ranking-row > span:last-child {
    grid-column: 3;
    text-align: left;
  }
}

/* v6 — iş kartlarının 2/5/2 oranı, okunaklı yönetici alanı ve yüksek çözünürlüklü ofisler */
.venture-card {
  grid-template-columns: clamp(148px, 10.8vw, 190px) minmax(0, 1fr);
}

.venture-logo {
  width: clamp(143px, 10.45vw, 184px);
  margin-left: 5px;
}

.venture-body {
  grid-template-rows: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 2fr);
  row-gap: 5%;
  padding: 7px 9px 7px 1px;
}

.venture-heading {
  grid-template-columns: minmax(0, 3fr) minmax(150px, 2fr);
  align-items: stretch;
}

.venture-heading > .venture-title {
  padding: 4px 9px 4px 13px;
}

.venture-title strong {
  font-size: clamp(14px, 1.12vw, 20px);
}

.venture-title.long-title {
  padding-top: 2px;
  padding-bottom: 2px;
}

.venture-title.long-title strong {
  font-size: clamp(10px, .86vw, 16px);
  line-height: 1;
  -webkit-line-clamp: 2;
}

.manager-shortcut {
  position: relative;
  display: grid;
  grid-template-columns: clamp(42px, 3.5vw, 61px) minmax(0, 1fr);
  align-items: center;
  height: 100%;
  min-height: 0;
  padding: 0 9px 0 1px;
  overflow: hidden;
  border: 0;
  border-left: 3px solid #071b2d;
  border-radius: 0;
  background:
    radial-gradient(circle at 11% 50%, rgba(116, 220, 255, .38), transparent 29%),
    linear-gradient(145deg, #126b9d, #082e4e);
  box-shadow: inset 0 0 0 2px rgba(118, 216, 255, .52);
  text-align: left;
}

.manager-shortcut img {
  width: 100%;
  height: calc(100% + 18px);
  max-height: none;
  margin: -9px 0 -9px -3px;
  object-fit: contain;
  object-position: center 26%;
  filter: drop-shadow(0 2px 0 #041a2b);
  transform: scale(1.65);
  transform-origin: 50% 18%;
}

.manager-copy,
.manager-shortcut span.manager-copy {
  position: static;
  inset: auto;
  display: grid;
  align-content: center;
  min-width: 0;
  gap: 1px;
  padding: 0;
  background: none;
  text-align: left;
}

.manager-copy small {
  display: block;
  color: #9ee5ff;
  font-size: clamp(7px, .53vw, 10px);
  line-height: 1;
}

.manager-copy strong {
  color: #fff6c9;
  font-size: clamp(9px, .74vw, 14px);
  line-height: 1.05;
}

.run-button {
  min-height: 0;
  padding: 4px 14px;
  border-width: 3px;
}

.run-label {
  font-size: clamp(14px, 1.18vw, 21px);
}

.venture-footer {
  grid-template-columns: minmax(0, 1fr) clamp(92px, 20%, 126px);
  gap: 6px;
}

.buy-button,
.timer-pill {
  min-height: 0;
  height: 100%;
  padding-top: 3px;
  padding-bottom: 3px;
}

.buy-button span {
  font-size: clamp(10px, .8vw, 14px);
}

.buy-button strong {
  font-size: clamp(11px, .92vw, 16px);
}

.timer-pill b {
  font-size: clamp(9px, .76vw, 13px);
}

/* Seviye etiketi çözünürlükten bağımsız, CSS ile çizilen yıldız madalyondur. */
.level-badge {
  right: auto;
  bottom: -8px;
  left: 50%;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 19px 52px;
  justify-items: center;
  width: 90px;
  height: 69px;
  overflow: visible;
  color: #fff9dc;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  transform: translateX(-50%);
}

.level-badge small {
  position: relative;
  z-index: 2;
  display: block;
  width: 80px;
  padding: 4px 6px 3px;
  color: #17304a;
  border: 2px solid #061a2d;
  border-radius: 999px;
  background: linear-gradient(#fff5ad, #e7a52a);
  box-shadow: inset 0 0 0 1px #fffbd5, 0 2px 0 rgba(3, 19, 32, .78);
  font-size: 8px;
  line-height: 1;
  text-align: center;
}

.level-badge b {
  position: relative;
  z-index: 1;
  display: grid;
  width: 54px;
  height: 54px;
  margin-top: -4px;
  padding: 0;
  place-items: center;
  color: #fffde8;
  border: 0;
  background: linear-gradient(145deg, var(--accent), var(--accent-dark));
  clip-path: polygon(50% 0%, 61% 34%, 98% 35%, 68% 57%, 79% 94%, 50% 72%, 21% 94%, 32% 57%, 2% 35%, 39% 34%);
  filter: drop-shadow(0 3px 0 #061a2d) drop-shadow(0 0 2px #ffd65d);
  font-size: clamp(18px, 1.35vw, 24px);
  line-height: 1;
  text-shadow: 0 2px 0 rgba(0, 0, 0, .45);
}

.venture-card.locked .level-badge {
  background: none;
}

.venture-card.locked .level-badge b {
  background: linear-gradient(#7d8588, #454c52);
  filter: drop-shadow(0 3px 0 #2c3338) drop-shadow(0 0 2px #d8d8d0);
}

.venture-card.locked .manager-shortcut {
  filter: none;
}

.milestone-pills > span {
  min-width: 72px;
}

.milestone-pills > span.speed:not(.rare) {
  color: #0a4164;
  border-color: #12608a;
  background: linear-gradient(#dff8ff, #83cfe8);
  box-shadow: inset 0 0 0 1px #f3fdff;
}

.milestone-pills > span.speed.done:not(.rare) {
  color: #f4fdff;
  border-color: #06334f;
  background: linear-gradient(#1685ac, #0b587b);
}

.office-artwork {
  display: block;
  width: 100%;
  height: 100%;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  image-rendering: auto;
}

.office-current {
  grid-template-columns: 178px minmax(0, 1fr);
  gap: 10px;
}

.office-current .office-artwork {
  width: 174px;
  height: 58px;
  aspect-ratio: 3 / 1;
  border: 2px solid #e8aa2b;
  border-radius: 12px 7px 12px 7px;
  box-shadow: 0 2px 0 #061b2d;
}

.office-tier-card {
  grid-template-rows: auto minmax(94px, 1fr) auto;
}

.office-tier-card > .office-artwork {
  height: auto;
  aspect-ratio: 3 / 1;
  min-height: 0;
  border-bottom: 3px solid #0a263d;
}

.office-studio {
  grid-template-columns: minmax(420px, .9fr) minmax(0, 1.1fr);
}

.office-studio-preview {
  grid-template-rows: auto auto;
}

.office-studio-preview .office-artwork {
  aspect-ratio: 3 / 1;
  min-height: 150px;
}

@media (max-width: 1320px) and (min-width: 981px) {
  .venture-card {
    grid-template-columns: 136px minmax(0, 1fr);
  }

  .venture-logo {
    width: 131px;
  }

  .venture-heading {
    grid-template-columns: minmax(0, 3fr) minmax(142px, 2fr);
  }

  .office-tier-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-height: 760px) and (min-width: 981px) {
  .venture-card {
    grid-template-columns: 124px minmax(0, 1fr);
  }

  .venture-logo {
    width: 121px;
  }

  .venture-body {
    grid-template-rows: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 2fr);
    row-gap: 5%;
    padding: 4px 7px 4px 0;
  }

  .venture-heading {
    grid-template-columns: minmax(0, 3fr) minmax(132px, 2fr);
  }

  .manager-shortcut {
    grid-template-columns: 50px minmax(0, 1fr);
    padding-right: 6px;
  }

  .manager-shortcut img {
    height: calc(100% + 14px);
    margin-top: -7px;
    margin-bottom: -7px;
  }

  .run-button,
  .buy-button,
  .timer-pill {
    min-height: 0;
  }

  .level-badge {
    bottom: -7px;
    grid-template-rows: 17px 46px;
    width: 82px;
    height: 61px;
  }

  .level-badge small {
    width: 72px;
    padding-top: 3px;
    padding-bottom: 2px;
    font-size: 7px;
  }

  .level-badge b {
    width: 48px;
    height: 48px;
    font-size: 19px;
  }
}

@media (max-width: 980px) {
  .venture-card {
    grid-template-columns: 132px minmax(0, 1fr);
  }

  .venture-logo {
    width: 127px;
  }

  .venture-body {
    grid-template-rows: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 2fr);
    row-gap: 4%;
  }

  .venture-heading {
    grid-template-columns: minmax(0, 3fr) minmax(135px, 2fr);
  }

  .office-studio {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .office-tier-card {
    grid-template-rows: minmax(100px, auto) auto;
  }

  .office-tier-card > .office-artwork {
    grid-row: 1 / 3;
    height: 100%;
    min-height: 100%;
    aspect-ratio: auto;
  }

  .office-current {
    grid-template-columns: 132px minmax(0, 1fr);
  }

  .office-current .office-artwork {
    width: 128px;
    height: 43px;
  }
}

@media (max-width: 450px) {
  .venture-card {
    grid-template-columns: 96px minmax(0, 1fr);
  }

  .venture-logo {
    width: 93px;
  }

  .venture-heading {
    grid-template-columns: minmax(0, 3fr) minmax(105px, 2fr);
  }

  .manager-shortcut {
    grid-template-columns: 31px minmax(0, 1fr);
    padding-right: 3px;
  }

  .manager-copy small {
    display: none;
  }

  .manager-copy strong {
    font-size: 8px;
  }

  .level-badge {
    grid-template-rows: 15px 42px;
    width: 74px;
    height: 55px;
  }

  .level-badge small {
    display: block;
    width: 64px;
    padding: 2px 4px;
    font-size: 6px;
  }

  .level-badge b {
    width: 43px;
    height: 43px;
    font-size: 16px;
  }

  .venture-footer {
    grid-template-columns: minmax(0, 1fr) 76px;
  }
}

/* ================================================================
   v6.8 — Claude sürümü eklemeleri (dosya sonunda: cascade'de kazanır)
   Menü parlatma, yönlendirme oku, katı pencereler, İnternet Sitesi,
   Sanal Ofis kilidi, yönetici ofis şartı, itibar bilgi kutusu.
   ================================================================ */

/* Madde 9: yeni özellik açılınca menü düğmesi kısa süre parlar */
.paper-menu-row.menu-pulse {
  animation: menuPulse 1s ease-in-out 5;
}

@keyframes menuPulse {
  0%, 100% { filter: none; transform: none; }
  50% {
    filter: brightness(1.28) drop-shadow(0 0 10px rgba(255, 216, 106, .95));
    transform: translateX(4px) scale(1.03);
  }
}

/* Yönlendirme oku: hedef ögenin yanında zıplar */
.guide-arrow {
  position: fixed;
  z-index: 1400;
  color: #ffd86a;
  font-size: 30px;
  line-height: 1;
  text-shadow: 0 2px 0 #071b2d, 0 0 14px rgba(255, 189, 46, .8);
  pointer-events: none;
  animation: guideArrowNudge .7s ease-in-out infinite alternate;
}

.guide-arrow.from-right {
  transform: scaleX(-1);
  animation-name: guideArrowNudgeFlipped;
}

@keyframes guideArrowNudge {
  from { transform: translateX(0); }
  to { transform: translateX(-9px); }
}

@keyframes guideArrowNudgeFlipped {
  from { transform: scaleX(-1) translateX(0); }
  to { transform: scaleX(-1) translateX(-9px); }
}

/* Katı pencere: karartı tıklaması kapatmaz; arka plan biraz daha koyu */
.modal-overlay.strict-modal {
  background: rgba(4, 14, 25, .82);
}

/* Ünlü Müvekkil olay penceresi */
.event-modal-stage {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.event-modal-sprite {
  width: 132px;
  height: 132px;
  border-width: 4px;
  border-radius: 22px;
  box-shadow: 0 6px 0 rgba(7, 27, 45, .4);
}

/* İnternet Sitesi kartı */
.internet-site-card {
  outline: 3px solid #ffbd2e;
  outline-offset: -3px;
}

.office-item-sprite.internet-site-icon {
  display: grid;
  place-content: center;
  background-image: none;
  background-color: #0d3a60;
  color: #8fddff;
  font-size: 40px;
}

/* Sanal Ofis'te kilitli geliştirmeler: listede görünür ama alınamaz */
.office-item-card.virtual-locked .office-item-sprite {
  filter: grayscale(.85) brightness(.8);
}

.virtual-office-note {
  display: block;
  margin-top: 5px;
  color: #a92f2b;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .02em;
}

/* Yönetici kartındaki asgari ofis satırı */
.manager-office-need {
  display: block;
  color: #a9581f;
  font-weight: 800;
}

.manager-office-need.met {
  color: #3f7d2c;
}

/* Madde 10: itibar yanındaki ? bilgi kutusu */
.reputation-stat > span {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.info-dot {
  width: 17px;
  height: 17px;
  padding: 0;
  border: 2px solid #071b2d;
  border-radius: 50%;
  background: linear-gradient(#ffd86a, #ed9315);
  color: #071b2d;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  cursor: help;
}

.info-tip {
  position: absolute;
  z-index: 1300;
  top: calc(100% + 9px);
  left: 50%;
  display: none;
  width: 240px;
  transform: translateX(-50%);
  padding: 9px 11px;
  border: 3px solid #071b2d;
  border-radius: 12px;
  background: linear-gradient(#fffdf4, #f4e3b2);
  color: #10233a;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
  text-transform: none;
  letter-spacing: normal;
  box-shadow: 0 6px 0 rgba(4, 19, 33, .45);
}

.info-dot:hover + .info-tip,
.info-dot:focus-visible + .info-tip {
  display: block;
}

/* Çevrimdışı rapor penceresi */
.offline-rate-note {
  margin: 10px 2px 0;
  color: #6b5310;
  font-size: 12px;
  font-weight: 800;
}

/* ================================================================
   v6.9 — Claude sürümü eklemeleri
   Topbar düzeni, seviye yıldızı, logo köşe kapağı, avatar hizalama,
   dünya sıralaması v2, borç notu.
   ================================================================ */

/* Topbar: KAZANÇ kaldırıldı → 4 sütun (marka / kasa / itibar / satın al).
   DİKKAT: style.css'in dört kırılım noktası (temel, 1320, 980, 720) beş sütuna
   göre yazılmıştır; buradaki override onların HEPSİNİ karşılamalıdır, aksi hâlde
   dar ekranda sabit sütunlar taşar ve SATIN AL seçicisi ekran dışında kalır. */
.tycoon-topbar {
  grid-template-columns: minmax(180px, 1.25fr) minmax(190px, 1.5fr) minmax(96px, .62fr) minmax(210px, 1.12fr);
}

@media (max-width: 1320px) {
  .tycoon-topbar {
    grid-template-columns: minmax(150px, 1.15fr) minmax(160px, 1.4fr) minmax(78px, .55fr) minmax(180px, 1fr);
  }
}

@media (max-width: 980px) {
  .tycoon-topbar {
    grid-template-columns: 1.1fr 1.4fr .6fr 1fr;
  }
}

/* Dar ekran: iki satır × iki sütun; SATIN AL seçicisi tam genişlikte alt satırda */
@media (max-width: 720px) {
  .tycoon-topbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto auto;
    gap: 6px;
  }

  .tycoon-topbar .buy-selector {
    grid-column: 1 / -1;
  }
}

@media (max-width: 450px) {
  .tycoon-topbar {
    grid-template-columns: minmax(0, 1fr);
  }

  .tycoon-topbar .brand-block {
    display: none;                 /* dar ekranda logo yerine oyun alanı öncelikli */
  }
}

.reputation-stat strong {
  font-size: clamp(30px, 3.2vw, 53px);
  color: #7a4e07;
  text-shadow: 0 2px 0 #fff;
}

.cash-panel small {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* Seviye yıldızı: rakamlar sığsın diye büyüdü, logodan biraz aşağı indi */
.level-badge {
  bottom: -20px;
  grid-template-rows: 19px 64px;
  width: 96px;
  height: 84px;
}

.level-badge b {
  width: 66px;
  height: 66px;
  margin-top: -5px;
  font-size: 17px;
  letter-spacing: -.02em;
}

@media (max-width: 1320px) {
  .level-badge b {
    width: 56px;
    height: 56px;
    font-size: 15px;
  }
}

/* İşletme görsellerindeki özgün, gömülü rozetler olduğu gibi görünür. */
.venture-logo::after { content: none; }

/* Avatar aksesuar hizalama: gözlük göze, bıyık dudağa, sakal çeneye */
.avatar-glasses {
  top: 38%;
  left: 44%;
  width: 24%;
  height: 10%;
}

.avatar-moustache {
  top: 46%;
  left: 50%;
  width: 13%;
  height: 5%;
  box-shadow: 6px 1px 0 #322017;
}

.avatar-beard {
  top: 44.5%;
  left: 47%;
  width: 24%;
  height: 16%;
  border-radius: 24% 28% 52% 48%;
}

/* Profil kartında yüz biraz daha aşağıda: aksesuarlar birlikte kayar */
.profile-stage .avatar-glasses { top: 41%; }
.profile-stage .avatar-moustache { top: 49%; }
.profile-stage .avatar-beard { top: 47.5%; }

/* Saç boyama taşmasını azalt: bölge hafif yukarı toplandı, opaklık düştü */
.avatar-hair-tint {
  opacity: .92;
  clip-path: polygon(17% 0, 83% 0, 82% 10%, 75% 13%, 79% 18%, 72% 21%, 67% 18%, 59% 14%, 50% 13%, 42% 15%, 35% 20%, 28% 26%, 20% 23%, 14% 15%);
}

.profile-note-input {
  width: 100%;
  padding: 8px 10px;
  border: 2px solid #9e6a18;
  border-radius: 10px;
  background: #fffdf4;
  color: #10233a;
  font: inherit;
  font-size: 13px;
}

/* ---------- Dünya sıralaması v2 ---------- */
.rank-title { display: inline-flex; align-items: center; gap: 7px; }
.rank-info-wrap { position: relative; display: inline-flex; }
.rank-info-wrap .info-tip { top: calc(100% + 8px); left: auto; right: -10px; transform: none; width: 260px; }
.rank-info-wrap .info-dot:hover + .info-tip,
.rank-info-wrap .info-dot:focus-visible + .info-tip { display: block; }

.current-rank-card.clickable-rank { cursor: pointer; }
.current-rank-card.clickable-rank:hover { filter: brightness(1.05); }

.ranking-search { padding: 6px 10px 2px; }
.ranking-search input {
  width: 100%;
  padding: 8px 12px;
  border: 2px solid #9e6a18;
  border-radius: 999px;
  background: #fffdf4;
  color: #10233a;
  font: inherit;
  font-size: 13px;
}

.ranking-list-full {
  overflow-y: auto;
  max-height: clamp(230px, 34vh, 430px);
  scrollbar-width: thin;
}

.ranking-row { cursor: pointer; }
.ranking-row:hover { filter: brightness(1.06); }
.ranking-row:focus-visible { outline: 3px solid #56c9ff; outline-offset: -3px; }

.ranking-row.self-row {
  border: 2px solid #ed9315;
  background: linear-gradient(#fff6d8, #ffe9ae);
  font-weight: 900;
}

.ranking-empty {
  padding: 14px;
  color: #6a4a10;
  font-weight: 800;
  text-align: center;
  list-style: none;
}

/* Oyuncu profili penceresi */
.player-profile {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.player-profile-portrait {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1;
  border: 3px solid #071b2d;
  border-radius: 16px;
  background: radial-gradient(circle at 50% 20%, rgba(88, 208, 255, .9), rgba(16, 111, 167, .9) 55%, #0a355d);
  box-shadow: inset 0 0 0 3px var(--gold-400);
}

.player-profile-portrait .avatar-stage { position: absolute; inset: 0; }

.player-profile-note {
  margin: 10px 0 0;
  padding: 9px 12px;
  border-left: 4px solid #ed9315;
  border-radius: 0 10px 10px 0;
  background: #fff7dc;
  color: #4a3a12;
  font-size: 13px;
  font-style: italic;
  font-weight: 700;
}

.player-profile-hint { margin: 8px 0 0; color: #7b6a45; font-size: 11px; font-weight: 700; }

.debt-note {
  margin: 10px 2px 0;
  color: #8f2b26;
  font-size: 13px;
  font-weight: 900;
}

@media (max-width: 640px) {
  .player-profile { grid-template-columns: 1fr; }
  .player-profile-portrait { max-width: 190px; }
}

/* ================================================================
   v7.4 — Satın alınmış yükseltmeler ve ofis geliştirmeleri YEŞİL
   ================================================================ */
.shop-card.owned-upgrade {
  background: linear-gradient(#f0fae6, #d7f0bf);
  outline: 3px solid #4f9a3a;
  outline-offset: -3px;
}

.shop-card.owned-upgrade button:disabled {
  border-color: #2f6b22;
  background: linear-gradient(#7cc95c, #4f9a3a);
  color: #fff;
  opacity: 1;
  text-shadow: 0 1px 0 rgba(0, 0, 0, .25);
}

.office-item-card.owned-item {
  background: linear-gradient(#f0fae6, #dcf3c6);
  outline: 3px solid #4f9a3a;
  outline-offset: -3px;
}

.office-item-card.owned-item .office-item-copy button:disabled {
  border-color: #2f6b22;
  background: linear-gradient(#7cc95c, #4f9a3a);
  color: #fff;
  opacity: 1;
  text-shadow: 0 1px 0 rgba(0, 0, 0, .25);
}

/* ================================================================
   v7.6 — Turbo bar: 0,5 sn'den hızlı işlerde bar tam dolu kalır,
   çapraz dalgalar akarak üretimin sürdüğünü gösterir (göz yormaz).
   ================================================================ */
.run-fill.turbo {
  width: 100% !important;
  border-right: 0;
  transition: none;
  animation: turboWave .45s linear infinite;
}

@keyframes turboWave {
  from { background-position: 0 0, 0 0; }
  to { background-position: 22.63px 0, 0 0; }
}

/* ================================================================
   v7.8 — Yayın öncesi denetim düzeltmeleri
   ================================================================ */

/* Dar ekranda sol menü sütunları 105px sabit minimuma kilitliydi; 320-360px'de
   iki sütun sığmadığı için menü satırları kırpılıyordu (etiketler kesiliyordu). */
@media (max-width: 450px) {
  .paper-menu {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 360px) {
  .paper-menu {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Bayat sekme uyarısı: oyun alanının önünde net görünsün */
.stale-tab-modal .game-modal {
  border-color: #a92f2b;
}

/* Dokunmatik: bilgi balonları yalnız :hover ile açılıyordu → dokunmatikte
   erişilemiyordu. Artık düğmeye basınca .tip-open sınıfıyla da açılır. */
.info-dot.tip-open + .info-tip {
  display: block;
}

/* Dokunmatik hedef boyutu: '?' düğmesi 17px idi (WCAG 2.5.5 altında). */
.info-dot {
  min-width: 24px;
  min-height: 24px;
}

/* Devre dışı satın alma düğmesinde metin kontrastı ~2,4:1 idi; okunur seviyeye
   çekildi (koyu zemin üzerinde açık metin). */
.buy-button:disabled,
.manager-card button:disabled,
.shop-card button:disabled {
  color: #f2efe6;
  background: linear-gradient(#6f6a61, #55514a);
  opacity: 1;
}

/* Modal odak halkası görünürlüğü (klavye kullanıcısı için) */
.game-modal:focus {
  outline: none;
}

.game-modal:focus-visible {
  outline: 3px solid #56c9ff;
  outline-offset: 3px;
}

/* Ekran okuyucular için sayfa başlığı (görsel düzeni etkilemez) */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ================================================================
   v8.1 — Satın alma düğmesinde fiyat her zaman görünür
   ================================================================ */

/* Esnek satırda öncelik RAKAMDA: etiket gerekirse kısalır, fiyat kısalmaz. */
.buy-button span {
  flex: 1 1 auto;
  min-width: 0;
}

.buy-button strong {
  flex: 0 0 auto;
}

/* MAKS seçiliyken 1 adete bile para yetmiyor: solda 1 adedin fiyatı,
   sağda eksik tutar. İki rakam sığsın diye punto bir tık küçülür. */
.buy-button.short-funds span,
.buy-button.short-funds strong {
  font-size: clamp(8px, .66vw, 12px);
  letter-spacing: -.01em;
}

.buy-button.short-funds:disabled strong {
  color: #8f2b26;
}

.buy-button.short-funds:disabled {
  background: linear-gradient(#f3ece0, #cfc6b6);
}

/* ================================================================
   v8.2 — 16 içerik, akış muhasebesi, rehber ve yerel avatar katmanı
   ================================================================ */
.venture-grid {
  grid-template-rows: none;
  /* v7.6 kartı ekranda dört satırı dolduruyordu. Yeni liste aynı kartın
     yaklaşık %80 yüksekliğini kullanır; kalan içerik aşağı kayar. */
  grid-auto-rows: clamp(115px, calc((100dvh - 145px) / 5), 188px);
  align-content: start;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 4px 7px 18px 3px;
  scrollbar-color: #dda52a rgba(4, 31, 51, .45);
  scrollbar-width: thin;
}

.venture-card {
  grid-template-columns: clamp(110px, calc((100dvh - 145px) / 5 - 5px), 183px) minmax(0, 1fr);
  min-height: clamp(115px, calc((100dvh - 145px) / 5), 188px);
  height: clamp(115px, calc((100dvh - 145px) / 5), 188px);
}

.venture-logo { width: clamp(106px, calc((100dvh - 145px) / 5 - 9px), 179px); }
.venture-body {
  grid-template-rows: minmax(29px, 2fr) minmax(30px, 5fr) minmax(28px, 2fr);
  gap: 3px;
  padding: 4px 7px 4px 0;
}
.venture-heading { grid-template-columns: minmax(0, 3fr) minmax(126px, 2fr); }
.venture-heading > .venture-title { padding: 2px 7px 2px 12px; }
.venture-title strong { font-size: clamp(12px, .92vw, 17px); }
.venture-title small, .manager-copy strong, .buy-button span, .buy-button strong, .timer-pill b { font-size: 12px; }
.manager-copy small { font-size: 12px; }
.manager-shortcut { grid-template-columns: 38px minmax(0, 1fr); min-height: 29px; }
.run-label { font-size: clamp(13px, 1vw, 18px); }
.level-badge { bottom: -12px; transform: translateX(-50%) scale(.78); }

.business-info-button {
  position: absolute;
  z-index: 9;
  bottom: 5px;
  left: clamp(67px, calc((100dvh - 145px) / 5 - 48px), 131px);
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  color: transparent;
  border: 3px solid transparent;
  border-radius: 50%;
  background: transparent;
}
.business-info-button:hover,
.business-info-button:focus-visible {
  color: #fff6c9;
  border-color: #f4bd35;
  background: rgba(5, 37, 60, .56);
  box-shadow: 0 0 0 3px rgba(255, 220, 91, .32), inset 0 0 0 2px #fff1a6;
  outline: none;
}

.company-card {
  background: linear-gradient(105deg, #fff9cc, #e7ba4d 48%, #8f5b11);
  box-shadow: inset 0 0 0 3px #ffd85c, inset 0 0 0 6px #fff5b9, 0 5px 0 #39230a, 0 0 18px rgba(255, 192, 48, .5);
}
.company-logo { cursor: default; }
.company-status {
  display: grid;
  place-items: center;
  color: #fff6cb;
  border: 3px solid #3b270b;
  border-radius: 9px;
  background: linear-gradient(#8b5a17, #55320b);
  font-size: 12px;
  font-weight: 1000;
  letter-spacing: .06em;
}
.company-buy-button {
  min-height: 28px;
  color: #132b3e;
  border: 2px solid #50330a;
  border-radius: 8px;
  background: linear-gradient(#fff5a3, #f3b52d);
  font-size: 12px;
  font-weight: 1000;
}
.company-card.founded { filter: drop-shadow(0 0 9px #ffd34d); }

.cash-panel { gap: 2px; }
.brand-block strong { font-size: clamp(18px, 1.65vw, 26px); }
.cashflow-ledger {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.cashflow-ledger span {
  display: grid;
  min-width: 0;
  color: #624710;
  font-size: 13px;
  line-height: 1.05;
  letter-spacing: 0;
}
.cashflow-ledger b { overflow: hidden; color: #236a2f; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.cashflow-ledger span:nth-child(2) b { color: #a33a2d; }
.margin-meter {
  position: relative;
  height: 15px;
  overflow: hidden;
  border: 2px solid #173044;
  border-radius: 999px;
  background: #e5dfc8;
}
.margin-meter i { position: absolute; inset: 0 auto 0 0; width: 0; background: #48a84d; transition: width .2s ease; }
.margin-meter.warning i { background: #e7b52c; }
.margin-meter.danger i { background: #d54d3e; }
.margin-meter small { position: absolute; inset: 0; display: grid; place-items: center; color: #132c3d; font-size: 13px; line-height: 11px; text-shadow: 0 1px #fff; }
.cash-panel > span, .top-stat > span, .buy-selector > span, .info-dot, .info-tip { font-size: 13px; }
.reputation-stat strong { font-size: clamp(23px, 2.3vw, 38px); }

.business-info-dialog { width: min(980px, calc(100vw - 24px)); }
.business-info-hero { display: grid; grid-template-columns: minmax(180px, 34%) 1fr; gap: 18px; align-items: center; }
.business-info-hero img { width: 100%; max-height: 300px; object-fit: contain; }
.business-info-hero strong { color: #123d61; font-size: clamp(22px, 3vw, 38px); }
.business-info-hero p { color: #3f3423; font-size: 15px; line-height: 1.5; }
.business-info-hero small { color: #79510d; font-size: 12px; font-weight: 900; }
.business-info-ledger { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-top: 14px; }
.business-info-ledger > div { display: grid; gap: 3px; padding: 9px 11px; border: 2px solid #a87922; border-radius: 10px; background: #fff7d8; }
.business-info-ledger span { color: #735212; font-size: 12px; font-weight: 900; text-transform: uppercase; }
.business-info-ledger strong { color: #102e48; font-size: 13px; line-height: 1.35; }
.company-requirements { display: grid; gap: 6px; margin: 12px 0; }
.company-requirements > div { padding: 9px; border: 2px solid #9c7440; border-radius: 8px; background: #eee4d3; font-weight: 900; }
.company-requirements > div.done { color: #215f2d; border-color: #4f934e; background: #ddf0ce; }
.company-update-note { color: #79510d; font-weight: 900; }
.company-celebration .game-modal { text-align: center; box-shadow: 0 0 45px #ffc937; }
.company-celebration-image { width: min(320px, 70vw); max-height: 280px; object-fit: contain; }
.company-celebration .modal-body > strong { display: block; color: #9c6410; font-size: 40px; }

.upgrade-card, .office-addon-card { position: relative; border-width: 3px; }
.upgrade-grid { align-content: start; }
.upgrade-card {
  min-height: 112px;
  padding: 14px;
}
.upgrade-card > img {
  width: 76px;
  height: 76px;
}
.rarity-common { border-color: #dedede !important; }
.rarity-advanced { border-color: #e4c629 !important; }
.rarity-rare { border-color: #e6781f !important; box-shadow: 0 0 8px rgba(230,120,31,.4); }
.rarity-epic { border-color: #c63b32 !important; box-shadow: 0 0 10px rgba(198,59,50,.48); }
.rarity-legendary { border-color: #f0b720 !important; box-shadow: 0 0 14px rgba(255,200,46,.72), inset 0 0 7px rgba(255,225,104,.45); }
.milestone-pills > span.profit { color: #642019; border-color: #a53c31; background: linear-gradient(#ffe1d4, #ea8a75); }
.milestone-pills > span.both { color: #3f1d5f; border-color: #694090; background: linear-gradient(#eadcff, #ad82d1); }
.milestone-pills > span.profit.done { color: #fff; background: linear-gradient(#c84c3f, #8f2d27); }
.milestone-pills > span.both.done { color: #fff; background: linear-gradient(#7d4aa5, #4d286d); }
.rare-badge { position: absolute; top: 4px; right: 5px; z-index: 2; padding: 2px 6px; border-radius: 999px; background: #17324a; color: #fff6c6; font-size: 10px; font-weight: 1000; }
.upgrade-prerequisite { display: block; color: #92392f; font-weight: 900; }
.office-addon-icon { width: 66px; height: 66px; object-fit: contain; }
.addon-actions { display: grid; grid-template-columns: auto 1fr; gap: 6px; }
.addon-info-button { min-width: 60px; }
.office-credit-note { padding: 9px; border: 2px solid #b78119; border-radius: 9px; background: #fff1ac; color: #67440c; font-weight: 900; }
.addon-detail { display: grid; grid-template-columns: 90px 1fr; gap: 8px 14px; padding: 15px; border: 3px solid; border-radius: 14px; }
.addon-detail img { grid-row: 1 / 3; width: 88px; height: 88px; object-fit: contain; }

.avatar-stage { overflow: hidden; }
.avatar-stage .lawyer-avatar-svg { display: block; width: 100%; height: 100%; }
.avatar-choice-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
.avatar-choice-list button { min-height: 44px; }

@media (max-width: 1320px) and (min-width: 721px) {
  .tycoon-topbar { grid-template-columns: minmax(145px, 1fr) minmax(260px, 1.45fr) minmax(82px, .55fr) minmax(180px, 1fr); }
  .venture-card { grid-template-columns: 102px minmax(0, 1fr); }
  .venture-logo { width: 99px; }
  .business-info-button { left: clamp(59px, calc((100dvh - 145px) / 5 - 48px), 131px); }
  .venture-heading { grid-template-columns: minmax(0, 3fr) minmax(116px, 2fr); }
}

@media (max-width: 980px) {
  .game-main { min-height: 720px; grid-template-rows: auto minmax(0, 1fr); }
  .venture-grid { grid-auto-rows: 125px; max-height: 760px; }
  .venture-card { min-height: 125px; height: 125px; }
  .venture-card { grid-template-columns: 112px minmax(0, 1fr); }
  .venture-logo { width: 108px; }
  .business-info-button { left: 66px; }
}

@media (max-width: 720px) {
  .game-main { min-height: 0; height: auto; grid-template-rows: auto auto; }
  .tycoon-topbar { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: auto auto auto; }
  .brand-block { grid-column: 1 / -1; grid-row: auto; }
  .cash-panel, .cash-panel + .top-stat, .buy-selector { grid-column: auto; grid-row: auto; }
  .buy-selector { grid-column: 1 / -1; }
  .venture-grid { grid-template-columns: 1fr; grid-auto-rows: 148px; max-height: none; overflow-y: visible; }
  .venture-card { grid-template-columns: 112px minmax(0, 1fr); min-height: 148px; height: 148px; }
  .venture-logo { width: 109px; }
  .business-info-button { left: 68px; }
  .venture-body { grid-template-rows: 36px minmax(42px, 1fr) 34px; }
  .venture-heading { grid-template-columns: minmax(0, 3fr) minmax(125px, 2fr); }
  .business-info-hero, .business-info-ledger { grid-template-columns: 1fr; }
  .business-info-hero img { max-height: 230px; }
  .upgrade-card { min-height: 108px; padding: 12px; }
}

/* 640–720 aralığında geniş kâğıt sekmelerin dokusu yazının üstüne gelmesin:
   menü dört kısa sütuna bölünür, 390 px düzeni ise iki sütun olarak korunur. */
@media (min-width: 640px) and (max-width: 720px) {
  .paper-menu { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .paper-menu-row {
    grid-template-columns: 24px minmax(0, 1fr);
    min-width: 0;
    padding: 4px 8px 4px 4px;
  }
  .paper-menu-row img { width: 23px; height: 23px; }
  .paper-menu-row span { font-size: 12px; }
}

@media (max-width: 450px) {
  .tycoon-topbar { grid-template-columns: 1fr; }
  .tycoon-topbar .brand-block { display: none; }
  .cash-panel, .cash-panel + .top-stat, .buy-selector { grid-column: 1; }
  .cashflow-ledger span, .cashflow-ledger b, .margin-meter small,
  .venture-title small, .manager-copy small, .manager-copy strong,
  .buy-button span, .buy-button strong, .timer-pill b { font-size: 12px; }
  .venture-card { grid-template-columns: 98px minmax(0, 1fr); }
  .venture-logo { width: 95px; }
  .business-info-button { left: 54px; bottom: 8px; }
  .venture-heading { grid-template-columns: minmax(0, 1fr) 112px; }
  .avatar-choice-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile-copy small, .profile-copy strong, .paper-menu-row span,
  .account-strip small, .account-strip strong, .sound-button span,
  .sidebar-event-copy small, .sidebar-event-copy strong, .sidebar-event-timer,
  .buy-selector > span, .buy-selector button { font-size: 12px; }
  .account-strip, .account-strip button, .venture-title, .manager-copy,
  .level-badge, .level-badge small { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .rarity-legendary, .company-card, .company-celebration .game-modal { animation: none !important; }
  .margin-meter i { transition: none; }
}

/* ================================================================
   v8.14 — okunabilir kartlar, gerçek rozet parıltısı ve içerik panelleri
   ================================================================ */
.venture-grid {
  grid-auto-rows: clamp(129px, calc((100dvh - 145px) / 4.46), 210px);
  overflow-x: hidden;
  overflow-y: auto;
  scroll-behavior: smooth;
}

.venture-card {
  --venture-art-size: clamp(118px, calc((100dvh - 145px) / 4.46 - 10px), 201px);
  grid-template-columns: clamp(124px, calc((100dvh - 145px) / 4.46 - 5px), 206px) minmax(0, 1fr);
  min-height: clamp(129px, calc((100dvh - 145px) / 4.46), 210px);
  height: clamp(129px, calc((100dvh - 145px) / 4.46), 210px);
}

.venture-art {
  position: relative;
  z-index: 3;
  display: grid;
  width: var(--venture-art-size);
  height: var(--venture-art-size);
  align-self: center;
  place-items: center;
  margin-left: 4px;
  overflow: visible;
}
.venture-art .venture-logo { width: 100%; margin-left: 0; }
.venture-body {
  grid-template-rows: minmax(30px, 2fr) minmax(39px, 5fr) minmax(30px, 2fr);
  gap: 4px;
  padding: 5px 8px 5px 0;
}
.venture-heading { grid-template-columns: minmax(0, 3fr) minmax(126px, 2fr); }
.venture-title strong { font-size: clamp(13px, .94vw, 17px); }
.venture-title small { font-size: clamp(12px, .72vw, 13px); }
.run-label { font-size: clamp(14px, 1.02vw, 18px); }
.manager-shortcut { grid-template-columns: 40px minmax(0, 1fr); min-height: 30px; }

/* Erişilebilir 44px alan, görselin içine gömülü sağ-alt rozetin tam üstündedir.
   Hover yeni bir disk çizmez; mevcut rozetin içinden geçen ışık verir. */
.business-info-button {
  right: 9%;
  bottom: 7%;
  left: auto;
  width: 44px;
  height: 44px;
  overflow: visible;
  border: 0;
  background: transparent;
  box-shadow: none;
  transition: filter .16s ease, transform .16s ease, background .16s ease, box-shadow .16s ease;
}
.business-info-button::before {
  content: "";
  position: absolute;
  top: 4px;
  right: 5px;
  width: 9px;
  height: 9px;
  border: 0;
  background: #fff7bd;
  clip-path: polygon(50% 0, 61% 36%, 100% 50%, 61% 64%, 50% 100%, 39% 64%, 0 50%, 39% 36%);
  filter: drop-shadow(0 0 4px #ffc928);
  opacity: .7;
  pointer-events: none;
  animation: embeddedBadgeBeacon 1.8s ease-in-out infinite;
}
.business-info-button::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: linear-gradient(112deg, transparent 22%, rgba(255,255,255,.9) 48%, transparent 70%);
  opacity: 0;
  transform: translateX(-80%) rotate(9deg);
  clip-path: circle(50%);
  pointer-events: none;
}
.business-info-button:hover,
.business-info-button:focus-visible {
  color: transparent;
  border: 0;
  background: transparent;
  box-shadow: none;
  filter: brightness(1.18) saturate(1.18);
  transform: scale(1.04);
}
.business-info-button:hover::before,
.business-info-button:focus-visible::before {
  background: #fff;
  filter: drop-shadow(0 0 7px #ffc928);
  opacity: 1;
}
.business-info-button:focus-visible { outline: 3px solid #fff0a0; outline-offset: 1px; border-radius: 50%; }
.business-info-button:hover::after,
.business-info-button:focus-visible::after { animation: embeddedBadgeShine .9s ease-out; }
@keyframes embeddedBadgeShine {
  0% { opacity: 0; transform: translateX(-80%) rotate(9deg); }
  25% { opacity: .9; }
  100% { opacity: 0; transform: translateX(130%) rotate(9deg); }
}
@keyframes embeddedBadgeBeacon {
  0%, 100% { opacity: .35; transform: scale(.65) rotate(0); }
  50% { opacity: 1; transform: scale(1.2) rotate(90deg); }
}

/* "SEVİYE" etiketi kaldırıldı; yıldız yalnız sayıyı, daha canlı bir madalyonla gösterir. */
.level-badge {
  bottom: -5px;
  grid-template-rows: 1fr;
  width: 84px;
  height: 74px;
  transform: translateX(-50%) scale(.9);
}
.level-badge small { display: none !important; }
.level-badge b {
  width: 70px;
  height: 70px;
  margin: 0;
  color: #fffce8;
  background:
    radial-gradient(circle at 38% 30%, rgba(255,255,255,.55), transparent 22%),
    linear-gradient(145deg, color-mix(in srgb, var(--accent) 82%, #ffd958), var(--accent-dark));
  filter: drop-shadow(0 4px 0 #061a2d) drop-shadow(0 0 6px #ffd447);
  font-size: clamp(17px, 1.3vw, 24px);
  text-shadow: 0 2px 0 rgba(0,0,0,.58), 0 0 5px rgba(255,250,185,.7);
}
.venture-card.running .level-badge b { animation: levelMedalLife 2.8s ease-in-out infinite; }
@keyframes levelMedalLife { 0%,100% { filter: drop-shadow(0 4px 0 #061a2d) drop-shadow(0 0 5px #ffd447); } 50% { filter: drop-shadow(0 4px 0 #061a2d) drop-shadow(0 0 10px #fff09a); } }

/* Kilitler: tek seviye şeridi + isteğe bağlı, okunabilir ödül dökümü. */
.unlock-card {
  grid-template-columns: 116px minmax(0, 1fr);
  align-items: center;
  gap: 8px 14px;
  padding: 12px;
}
.unlock-grid { grid-template-columns: 1fr; }
.unlock-art {
  position: relative;
  grid-row: 1 / 3;
  width: 112px;
  height: 112px;
  overflow: hidden;
  border-radius: 50%;
  filter: drop-shadow(0 3px 0 rgba(7,28,45,.35));
}
.unlock-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  /* Ana karttaki sağ-alt bilgi rozeti Kilitler ekranında kullanılmaz. */
  transform: scale(1.58);
  transform-origin: 40% 40%;
}
.milestone-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 8px;
  min-width: 0;
}
.milestone-track {
  display: flex;
  flex-wrap: nowrap;
  gap: 2px;
  min-width: 0;
  padding: 32px 2px 6px;
  overflow: visible;
}
.milestone-pills > .milestone-pill {
  position: relative;
  display: grid;
  flex: 1 1 0;
  min-width: 44px;
  min-height: 38px;
  padding: 8px 5px;
  place-items: center;
  cursor: help;
  color: #e9f7ff;
  border: 2px solid #153c59;
  border-radius: 9px;
  background: linear-gradient(#2a6d91, #164461);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18), 0 2px 0 #09263d;
  font-size: 12px;
  font-weight: 1000;
}
.milestone-pills > .milestone-pill.done {
  color: #efffff;
  border-color: #126c68;
  background: linear-gradient(#39a49b, #1f696d);
}
.milestone-pills > .milestone-pill.gold-milestone,
.milestone-pills > .milestone-pill.gold-milestone.done {
  color: #332008;
  border-color: #8c5c0b;
  background: linear-gradient(#fff2a0, #e5a52a);
  box-shadow: inset 0 0 0 2px rgba(255,255,220,.62), 0 2px 0 #543306, 0 0 8px rgba(236,177,35,.5);
}
.milestone-tooltip {
  position: absolute;
  z-index: 35;
  bottom: calc(100% + 7px);
  left: 50%;
  width: max-content;
  max-width: 210px;
  padding: 6px 8px;
  color: #fff8dc;
  border: 2px solid #e5ad32;
  border-radius: 8px;
  background: #082f4d;
  box-shadow: 0 4px 0 #061a2d, 0 7px 14px rgba(0,0,0,.28);
  font-size: 11px;
  font-weight: 900;
  line-height: 1.2;
  white-space: normal;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 5px);
  transition: opacity .14s ease, transform .14s ease;
}
.milestone-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  border: 6px solid transparent;
  border-top-color: #082f4d;
  transform: translateX(-50%);
}
.milestone-pill:hover .milestone-tooltip,
.milestone-pill:focus-visible .milestone-tooltip {
  opacity: 1;
  transform: translate(-50%, 0);
}
.milestone-pill:focus-visible { outline: 3px solid #fff0a0; outline-offset: 2px; }
.milestone-help {
  display: inline-flex;
  width: 48px;
  min-width: 48px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
  color: #fff5d4;
  border: 2px solid #071d30;
  border-radius: 10px;
  background: linear-gradient(#17628f, #0b3659);
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.18), 0 3px 0 #061a2d;
  font: 1000 24px/1 var(--font-display);
}
.milestone-help:hover,
.milestone-help:focus-visible { color: #132c43; background: linear-gradient(#fff0a0, #e7b235); }
.milestone-help-copy { display: grid; gap: 12px; color: #233e52; font-size: 14px; line-height: 1.45; }
.milestone-help-copy p { margin: 0; }
.milestone-help-copy strong { padding: 10px; color: #123b5c; border: 2px solid #c48a22; border-radius: 9px; background: #fff3c0; }
.milestone-detail-panel {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 10px;
  border: 2px solid #174a6c;
  border-radius: 11px;
  background: linear-gradient(135deg, #e8f6f8, #d5e9e8);
}
.milestone-detail-panel[hidden] { display: none; }
.milestone-reward-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 2px 7px;
  padding: 7px 8px;
  color: #173247;
  border: 1px solid #8cb0b5;
  border-radius: 8px;
  background: rgba(255,255,255,.72);
}
.milestone-reward-row b { color: #0d5271; }
.milestone-reward-row span { font-size: 12px; font-weight: 800; }
.milestone-reward-row em { grid-column: 1 / -1; color: #76643e; font-size: 9px; font-style: normal; font-weight: 1000; letter-spacing: .07em; }
.milestone-reward-row.done em { color: #19705e; }
.milestone-reward-row.gold { border-color: #bd851c; background: #fff5c6; }

/* Yükseltmenin etkisi ana bilgi, ön şart ise ikincil bilgidir. */
.upgrade-card p {
  margin-top: 5px;
  color: #203d53;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.28;
  opacity: 1;
}
.upgrade-prerequisite {
  display: block;
  margin-top: 3px;
  color: #876e52;
  font-size: 11px;
  font-weight: 650;
  opacity: .86;
}

/* Yönetici portresi gerçek bir özgeçmiş düğmesidir. */
.manager-card { grid-template-rows: 126px minmax(120px, 1fr) auto; }
.manager-profile-trigger {
  position: relative;
  width: 100%;
  min-width: 0 !important;
  height: 124px;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden;
  cursor: pointer;
  color: #193851 !important;
  border: 2px solid #9c7525 !important;
  border-radius: 12px !important;
  background: transparent !important;
  box-shadow: inset 0 0 0 2px rgba(255,246,202,.72), 0 3px 0 #6b4b14 !important;
}
.manager-profile-trigger img { width: 100%; height: 100%; object-fit: contain; transition: transform .18s ease, filter .18s ease; }
.manager-profile-trigger span {
  position: absolute;
  right: 7px;
  bottom: 6px;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(5,37,61,.88);
  font-size: 9px;
  font-weight: 1000;
  letter-spacing: .06em;
}
.manager-profile-trigger:hover img,
.manager-profile-trigger:focus-visible img { filter: brightness(1.08); transform: scale(1.045); }
.manager-profile-sheet { display: grid; grid-template-columns: minmax(180px, 34%) 1fr; gap: 18px; align-items: stretch; }
.manager-profile-portrait { width: 100%; max-height: 360px; object-fit: contain; border: 3px solid #a37925; border-radius: 18px; background: transparent; }
.manager-profile-copy { display: grid; align-content: start; gap: 10px; }
.manager-profile-role { color: #986313; font-size: 13px; font-weight: 1000; letter-spacing: .06em; text-transform: uppercase; }
.manager-profile-bio { margin: 0; color: #213b50; font-size: 15px; font-weight: 750; line-height: 1.48; }
.manager-profile-facts { display: grid; grid-template-columns: minmax(125px, auto) 1fr; gap: 6px 10px; margin: 0; }
.manager-profile-facts dt { color: #0f5679; font-size: 11px; font-weight: 1000; }
.manager-profile-facts dd { margin: 0; color: #473b2d; font-size: 13px; font-weight: 750; }

/* Dil seçici ses düğmesinin hemen üstündedir. */
.language-picker {
  display: grid;
  grid-template-columns: 1fr auto;
  flex: 0 0 40px;
  align-items: center;
  width: calc(100% - 9px);
  margin-left: 6px;
  padding: 4px 5px 4px 10px;
  color: #dff5ff;
  border: 2px solid #061b2c;
  border-radius: 11px;
  background: linear-gradient(#0e4e76, #082e4d);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 3px 0 #041521;
}
.language-label { font-size: 10px; font-weight: 1000; letter-spacing: .12em; }
.language-buttons { display: flex; gap: 3px; }
.language-option {
  min-width: 39px;
  min-height: 30px;
  cursor: pointer;
  color: #dff5ff;
  border: 1px solid #79bad4;
  border-radius: 7px;
  background: #0a3453;
  font-weight: 1000;
}
.language-option[aria-pressed="true"] { color: #102d43; border-color: #fff0a0; background: linear-gradient(#fff2a0, #e7b438); box-shadow: inset 0 0 0 1px #fffbd3; }

/* Satın alınabilir içerik görünür olur; itibar menüsü bu sınıfı hiçbir zaman almaz. */
.paper-menu-row.can-afford:not(.active) { animation: affordableMenuGlow 1.45s ease-in-out infinite; }
.paper-menu-row.can-afford:not(.active)::after {
  content: "ALINABİLİR";
  position: absolute;
  top: -3px;
  right: 15px;
  padding: 2px 6px;
  color: #fff;
  border-radius: 999px;
  background: #168b75;
  font-size: 8px;
  font-weight: 1000;
  letter-spacing: .05em;
}
html[lang="en"] .paper-menu-row.can-afford:not(.active)::after { content: "AVAILABLE"; }
html[lang="en"] .profile-card::before { content: "CUSTOMISE CHARACTER"; }
@keyframes affordableMenuGlow { 0%,100% { filter: drop-shadow(0 4px 1px rgba(0,0,0,.42)); } 50% { filter: drop-shadow(0 0 9px #54d4c0) brightness(1.08); } }

/* İtibar panosu artık temaya ait bir kupa ve dengeli iki bilgi bloğu kullanır. */
.reputation-dashboard .prestige-panel {
  grid-template-columns: minmax(150px, .72fr) minmax(210px, 1.28fr);
  grid-template-rows: auto auto 54px;
  align-content: center;
  gap: 16px;
  padding: clamp(18px, 2vw, 30px);
  background: linear-gradient(145deg, #f8f4df, #d9ece9);
}
.reputation-dashboard .prestige-panel > img {
  grid-row: 1 / 3;
  width: min(100%, 210px);
  height: auto;
  justify-self: center;
  filter: drop-shadow(0 7px 0 rgba(4,29,47,.28)) drop-shadow(0 0 12px rgba(28,141,138,.25));
}
.prestige-current,
.prestige-next {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 14px;
  border: 2px solid #5b8e91;
  border-radius: 13px;
  background: rgba(255,255,255,.7);
}
.prestige-next { border-color: #b9822d; background: rgba(255,246,211,.78); }
.prestige-panel .prestige-current > strong,
.prestige-panel .prestige-next > strong { font-size: clamp(30px, 3vw, 48px); }
.reputation-dashboard .prestige-panel > button { grid-row: 3; }
.current-rank-card {
  color: #eafcff;
  border-bottom-color: #123f58;
  background: linear-gradient(100deg, #147f82, #155270);
}
.current-rank-copy small { color: #bfe6e8; }
.ranking-row.self-row {
  color: #efffff;
  border-color: #176e78;
  background: linear-gradient(#3d9ca0, #246d79);
}
.ranking-row.self-row > span:last-child { color: #e7ffff; }

@media (max-width: 1320px) and (min-width: 721px) {
  .venture-card {
    --venture-art-size: 116px;
    grid-template-columns: 120px minmax(0, 1fr);
  }
  .milestone-detail-panel { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  .venture-grid { grid-auto-rows: 140px; max-height: 920px; }
  .venture-card { --venture-art-size: 126px; grid-template-columns: 131px minmax(0, 1fr); min-height: 140px; height: 140px; }
  .game-sidebar { grid-template-rows: auto 38px 30px; min-height: 215px; }
  .profile-card { grid-row: 1 / 4; }
  .paper-menu { grid-column: 2; grid-row: 1; }
  .language-picker { grid-column: 2; grid-row: 2; width: 180px; margin: 0; }
  .sound-button { grid-column: 3; grid-row: 1 / 4; }
  .account-strip { grid-column: 2; grid-row: 3; }
  .unlock-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .venture-grid { grid-auto-rows: 166px; max-height: none; overflow-y: visible; }
  .venture-card { --venture-art-size: 141px; grid-template-columns: 146px minmax(0, 1fr); min-height: 166px; height: 166px; }
  .game-sidebar { grid-template-rows: auto auto 38px 38px; min-height: 292px; }
  .profile-card { grid-row: 1 / 3; }
  .paper-menu { grid-column: 2; grid-row: 1 / 3; }
  .language-picker { grid-column: 1; grid-row: 3; width: 140px; margin: 0; }
  .sound-button { grid-column: 1; grid-row: 4; }
  .account-strip { grid-column: 2; grid-row: 3 / 5; align-self: center; }
  .milestone-detail-panel { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .manager-profile-sheet { grid-template-columns: 1fr; }
  .manager-profile-portrait { max-height: 260px; }
  .reputation-dashboard .prestige-panel { grid-template-columns: 120px 1fr; }
}

@media (max-width: 450px) {
  .venture-card { --venture-art-size: 106px; grid-template-columns: 112px minmax(0, 1fr); min-height: 152px; height: 152px; }
  .venture-heading { grid-template-columns: minmax(0, 1fr) 104px; }
  .unlock-card { grid-template-columns: 84px minmax(0, 1fr); padding: 9px; }
  .unlock-art { width: 80px; height: 80px; }
  .milestone-row { grid-column: 1 / -1; }
  .milestone-track { padding-top: 30px; overflow-x: auto; overflow-y: hidden; }
  .milestone-pills > .milestone-pill { flex: 0 0 52px; }
  .milestone-detail-panel { grid-template-columns: 1fr; }
  .manager-profile-facts { grid-template-columns: 1fr; }
  .manager-profile-facts dd { margin-bottom: 5px; }
  .reputation-dashboard .prestige-panel { grid-template-columns: 1fr; }
  .reputation-dashboard .prestige-panel > img { grid-row: auto; width: 150px; }
}

@media (prefers-reduced-motion: reduce) {
  .business-info-button::before,
  .business-info-button::after,
  .venture-card.running .level-badge b,
  .paper-menu-row.can-afford:not(.active) { animation: none !important; }
  .milestone-tooltip, .manager-profile-trigger img { transition: none; }
}
