/* Showcase Maker — Steam-profile layout overrides (match real Steam density) */

html, body {
  margin: 0;
  background: #1b2838;
  color: #fff;
  font-family: "Motiva Sans", "Segoe UI", Arial, sans-serif;
}

/* ---- builder chrome ---- */
.sm-builder {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  min-height: calc(100vh - 72px);
  background: #1b2838;
}
@media (max-width: 960px) {
  .sm-builder { grid-template-columns: 1fr; }
}
.sm-panel {
  background: #171a21;
  border-right: 1px solid rgba(255,255,255,.08);
  padding: 14px 14px 28px;
  overflow: auto;
  max-height: calc(100vh - 72px);
}
.sm-panel h2 {
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #66c0f4;
  margin: 18px 0 10px;
  font-weight: 600;
}
.sm-panel h2:first-child { margin-top: 4px; }
.sm-panel label {
  display: block;
  font-size: 11px;
  color: rgba(255,255,255,.45);
  margin: 8px 0 3px;
}
.sm-panel input, .sm-panel textarea, .sm-panel select {
  width: 100%;
  box-sizing: border-box;
  border-radius: 3px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.35);
  color: #fff;
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
}
.sm-row { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; align-items: center; }
.sm-btn {
  border: none;
  border-radius: 2px;
  padding: 8px 14px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  background: linear-gradient(90deg, #06bfff 0%, #2d73ff 100%);
  color: #fff;
}
.sm-btn--ghost {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,.18);
}
.sm-btn--go { background: linear-gradient(90deg, #06bfff, #2d73ff); }
.sm-stat { font-size: 12px; margin-top: 8px; color: rgba(255,255,255,.5); min-height: 16px; line-height: 1.35; }
.sm-stat.ok { color: #a4d007; }
.sm-stat.bad { color: #ff6b6b; }
.sm-stat.wait { color: #f0c674; }

/* ---- stage: Steam-like page background ---- */
.sm-stage {
  position: relative;
  overflow: auto;
  min-height: calc(100vh - 72px);
  background: #000;
}
.sm-stage.is-public { min-height: 100vh; }

/* Profile sits in a fixed Steam-like width, centered */
.sm-stage .profile_page {
  position: relative;
  z-index: 1;
  width: 100%;
  min-height: 100%;
  padding: 28px 12px 64px;
  box-sizing: border-box;
  background-repeat: no-repeat;
  background-position: center top;
  background-size: 100% auto;
  background-color: #000;
  container-type: inline-size;
}
.sm-stage .profile_page--has-bg { background-attachment: scroll; }
.sm-stage .container_profile {
  width: 100%;
  max-width: 948px; /* Steam content ~948–998 */
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.sm-stage .profile_sections {
  display: flex !important;
  align-items: flex-start !important;
  gap: 12px !important;
  width: 100% !important;
  max-width: none !important;
  max-height: none !important;
  overflow: visible !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Main column ~640px feel, right ~296px */
.sm-stage .profile_section_main {
  width: 640px !important;
  max-width: calc(100% - 308px);
  flex: 1 1 auto;
  min-width: 0;
}
.sm-stage .profile_section_right {
  width: 296px !important;
  flex: 0 0 296px;
  min-width: 0;
}

@media (max-width: 900px) {
  .sm-stage .profile_sections { flex-direction: column; }
  .sm-stage .profile_section_main,
  .sm-stage .profile_section_right {
    width: 100% !important;
    max-width: 100%;
    flex: none;
  }
}

/* ---- animated / static background full bleed behind content ---- */
.profile_animated_background,
.profile_animated_background_fallback {
  position: absolute !important;
  left: 0; right: 0; top: 0;
  width: 100% !important;
  height: auto !important;
  min-height: 0;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background-size: cover;
  background-position: center top;
  z-index: 0 !important;
  opacity: 1 !important;
  pointer-events: none;
  filter: none;
}
/* The Steam background is a 16:9 canvas.  The fade layer starts just before
   its physical lower edge, blurs that edge, and hands the rest of the page to
   real black instead of the old #1b2838 band. */
.profile_background_fade {
  position: absolute;
  z-index: 1;
  left: 0;
  right: 0;
  top: calc(56.25cqw - 190px);
  height: 300px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,0), rgba(0,0,0,.6) 44%, #000 82%);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 24%, #000);
  mask-image: linear-gradient(180deg, transparent, #000 24%, #000);
}
/* darken overlay so glass panels remain readable */
.profile_page::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(7,9,13,.08) 0%, rgba(7,9,13,.2) 54%, rgba(0,0,0,.72) 100%);
}

/* ---- header (avatar + name) denser, Steam-like ---- */
.profile_up {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 8px 4px 6px;
  min-height: 0 !important;
  transform: none !important;
}
.profile_up_avatar_wrap {
  position: relative;
  width: 140px;
  height: 140px;
  flex-shrink: 0;
}
.profile_up_avatar {
  width: 140px !important;
  height: 140px !important;
  object-fit: cover;
  border-radius: 0;
  display: block;
  background: #000;
  box-shadow: 0 0 0 1px rgba(0,0,0,.5);
}
.profile_up_avatar_frame {
  position: absolute;
  inset: -22px;
  width: calc(100% + 44px);
  height: calc(100% + 44px);
  object-fit: contain;
  pointer-events: none;
}
.profile_up_items {
  padding-top: 6px;
  min-width: 0;
  flex: 1;
}
.profile_up_name {
  font-size: 26px;
  font-weight: 400;
  line-height: 1.15;
  color: #ffffff;
  text-shadow: 1px 1px 2px rgba(0,0,0,.6);
}
.profile_up_summary {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.35;
  color: #c6d4df;
  max-width: 380px;
  white-space: pre-wrap;
}

/* ---- showcase cards ---- */
.profile_main_content { padding: 0; }
.profile_main_workshop,
.profile_main_banner,
.profile_main_guide,
.profile_main_info,
.profile_main_illustration {
  margin-top: 10px;
  background: rgba(25, 21, 29, .58) !important;
  border-radius: 3px;
  -webkit-backdrop-filter: blur(8px) saturate(112%);
  backdrop-filter: blur(8px) saturate(112%);
  box-shadow: none;
}
.profile_main_workshop_title,
.profile_main_banner_title,
.profile_main_guide_title,
.profile_main_info_title,
.profile_main_illustration_title {
  padding: 6px 10px 2px !important;
  font-size: 15px !important;
  line-height: 28px !important;
  font-weight: 400;
  color: #ffffff;
}
.profile_main_workshop_main_content,
.profile_main_banner_main_content { padding: 6px 10px 10px !important; }

/* Workshop title row with icon */
.profile_main_workshop_main_title {
  display: flex !important;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px !important;
  color: #c6d4df !important;
  font-size: 14px !important;
  line-height: 22px !important;
}
.profile_main_workshop_main_title img {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(144, 186, 60, 0.85);
  object-fit: cover;
}

/* 5-col workshop grid — images keep natural height (vertical strips OK) */
.profile_main_workshop_main_images {
  display: grid !important;
  grid-template-columns: repeat(5, 1fr) !important;
  gap: 3px !important;
  width: 100% !important;
  align-items: start;
}
.profile_main_workshop_main_image {
  width: 100% !important;
  max-width: none !important;
  flex: none !important;
  display: block;
  margin: 0;
  cursor: pointer;
}
.profile_main_workshop_main_image img,
.profile_main_workshop_img {
  width: 100% !important;
  height: auto !important;
  display: block;
  object-fit: contain !important;
  background: rgba(0,0,0,.35);
  vertical-align: top;
}

/* multi-row support: extra images continue in grid automatically */
.profile_main_workshop_main_stat_items {
  display: flex;
  gap: 28px;
  margin-top: 6px;
  padding: 6px 8px;
  background: rgba(0,0,0,.28);
}
.profile_main_workshop_main_stat_item_number {
  font-size: 22px;
  font-weight: 200;
  line-height: 24px;
  color: #fff;
}
.profile_main_workshop_main_stat_item_text {
  font-size: 11px;
  color: #8f98a0;
}

/* Artwork / Featured / Split: Steam 506 + 100 layout. */
.sm-stage .profile_main_banner_main,
.sm-stage .profile_main_banner_main_content,
.sm-stage .profile_main_banners {
  position: relative !important;
  inset: auto !important;
  transform: none !important;
}
.sm-stage .profile_main_banners {
  display: grid !important;
  grid-template-columns: minmax(0, 506fr) minmax(72px, 100fr) !important;
  align-items: stretch !important;
  gap: 4px !important;
  width: 100% !important;
  height: auto !important;
  min-height: 180px;
  padding: 0 !important;
  background: rgba(0,0,0,.22) !important;
  overflow: hidden;
}
.sm-stage .profile_main_banners > .sm-media-slot {
  position: relative !important;
  inset: auto !important;
  transform: none !important;
  width: 100% !important;
  min-width: 0 !important;
  height: auto !important;
  overflow: hidden;
}
.sm-stage .profile_main_banner_big,
.sm-stage .profile_main_banner_small,
.profile_main_illustration_img {
  position: static !important;
  inset: auto !important;
  transform: none !important;
  width: 100% !important;
  max-width: none !important;
  height: auto !important;
  max-height: none !important;
  object-fit: contain !important;
  display: block !important;
  background: rgba(0,0,0,.3);
}
.sm-stage .profile_main_banner_small { height: 100% !important; object-fit: fill !important; }
.sm-stage .profile_main_banners .sm-slot-empty { height: 100%; min-height: 180px; }
.sm-stage .profile_main_featured,
.sm-stage .profile_main_featured > .sm-media-slot {
  position: relative !important;
  width: 100% !important;
  height: auto !important;
  overflow: hidden;
}
.sm-stage .profile_main_featured_img {
  position: static !important;
  transform: none !important;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  object-fit: contain !important;
  display: block !important;
  background: rgba(0,0,0,.3);
}

/* Guide */
.profile_main_guide_row {
  display: flex;
  gap: 12px;
  padding: 8px 10px 12px;
  align-items: flex-start;
}
.profile_main_guide_img {
  width: 184px;
  height: 104px;
  object-fit: cover;
  flex-shrink: 0;
  background: #000;
}
.profile_main_guide_meta {
  font-size: 13px;
  color: #c6d4df;
  line-height: 1.45;
}

.profile_main_info_body {
  padding: 4px 12px 12px;
  font-size: 13px;
  color: #c6d4df;
  line-height: 1.4;
}
.profile_main_info_link a { color: #66c0f4; text-decoration: none; }
.profile_main_info_link a:hover { color: #fff; }

/* ---- right column ---- */
.profile_right_level {
  display: flex;
  justify-content: space-between;
  align-items: center;
  transform: none !important;
  margin: 4px 0 8px;
}
.profile_right_level em{font-style:normal;font-size:18px;font-weight:300;color:rgba(255,255,255,.88)}
.profile_right_level span {
  width: 36px !important;
  height: 36px !important;
  border-radius: 50%;
  border: 2px solid #66c0f4 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  font-size: 14px !important;
  font-weight: 300;
  color: #fff;
  background: rgba(0,0,0,.25);
}
.profile_right_achievement {
  background: rgba(25, 21, 29, .58) !important;
  border-radius: 3px;
  margin-top: 0 !important;
  transform: none !important;
}
.profile_right_achievement_content {
  padding: 8px !important;
  display: flex;
  gap: 8px;
  align-items: center;
}
.profile_right_achievement_icon {
  width: 48px !important;
  height: 48px !important;
  object-fit: contain;
}
.profile_right_achievement_title { font-size: 12px !important; color: #fff; }
.profile_right_achievement_exp { font-size: 11px !important; color: #8f98a0; }

.profile_right_menu {
  margin-top: 10px !important;
  background: rgba(18, 12, 22, .62) !important;
  border-radius: 3px;
  -webkit-backdrop-filter: blur(14px) saturate(115%);
  backdrop-filter: blur(14px) saturate(115%);
}
.profile_right_menu_content { padding: 10px !important; }
.profile_right_menu_status {
  font-size: 16px !important;
  font-weight: 300 !important;
  color: #898989 !important;
  margin-bottom: 10px;
}
.profile_right_block_title {
  font-size: 14px;
  color: rgba(255,255,255,.9);
  margin: 18px 0 9px;
}
.profile_right_block_title span{color:rgba(255,255,255,.42);font-weight:300}
.profile_right_badges,
.profile_right_awards {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.profile_right_badge_img,
.profile_right_award_img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  background: rgba(0,0,0,.2);
}
.profile_right_stat_row {
  display: flex;
  justify-content: space-between;
  justify-content: flex-start;
  gap: 7px;
  font-size: 14px;
  padding: 5px 0;
  color: rgba(255,255,255,.85);
}
.profile_right_stat_num { color: rgba(255,255,255,.45); font-size:16px; font-weight: 300; }
.profile_groups_item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 5px 0;
  font-size: 12px;
  color: #c6d4df;
}
.profile_groups_text{display:flex;min-width:0;flex-direction:column;gap:2px}.profile_groups_name{color:#fff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.profile_groups_members{font-size:11px;color:rgba(255,255,255,.48)}
.profile_group_av {
  width: 32px;
  height: 32px;
  border-radius: 2px;
  object-fit: cover;
}
.sm-slot-empty {
  min-height: 40px;
  background: rgba(255,255,255,.03);
  border: 1px dashed rgba(255,255,255,.1);
}
.sm-media-slot{position:relative;display:block;width:100%;padding:0;border:0;background:transparent;color:inherit;text-align:inherit;cursor:pointer;overflow:hidden}
.sm-media-slot__action{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);padding:7px 10px;border-radius:3px;background:rgba(12,18,24,.9);border:1px solid rgba(102,192,244,.55);color:#fff;font:600 11px "Motiva Sans",sans-serif;white-space:nowrap;opacity:0;transition:opacity .15s}
.sm-media-slot:hover .sm-media-slot__action,.sm-media-slot:focus-visible .sm-media-slot__action,.sm-media-slot .sm-slot-empty+.sm-media-slot__action{opacity:1}
.sm-media-slot:focus-visible{outline:2px solid #66c0f4;outline-offset:2px}
.profile_up_avatar_wrap>.sm-media-slot{width:140px;height:140px}
.profile_main_workshop_main_image>.sm-media-slot{height:auto;min-height:110px}
.profile_main_workshop_main_image .sm-slot-empty{min-height:180px}
.profile_main_banner_main_content .sm-media-slot,.profile_main_illustration>.sm-media-slot{width:100%}
.profile_main_banner_stats {
  display: flex;
  gap: 12px;
  padding: 6px 2px 0;
  font-size: 12px;
  color: #8f98a0;
}
.sm-generic-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;padding:10px;background:rgba(0,0,0,.18)}
.sm-generic-grid>.sm-media-slot{aspect-ratio:184/69;min-height:58px;background:rgba(255,255,255,.025)}
.sm-generic-grid__media{display:block;width:100%;height:100%;object-fit:cover}
.sm-generic-grid--items{grid-template-columns:repeat(6,minmax(0,1fr))}
.sm-generic-grid--items>.sm-media-slot{aspect-ratio:1;min-height:0}
.sm-generic-grid--items .sm-generic-grid__media{object-fit:contain;padding:5px}
.profile_main_info_body{white-space:pre-wrap;overflow-wrap:anywhere}


/* ---- FIX: background stays behind mockup, does not push layout ---- */
.sm-stage {
  position: relative !important;
  overflow: auto !important;
  isolation: isolate;
}
.sm-stage .profile_page {
  position: relative !important;
  z-index: 1;
  min-height: 100%;
  overflow: visible;
}
.sm-stage .profile_animated_background,
.sm-stage .profile_animated_background_fallback {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 16 / 9 !important;
  max-height: none !important;
  object-fit: cover !important;
  background-size: cover !important;
  background-position: center top !important;
  z-index: 0 !important;
  pointer-events: none !important;
  margin: 0 !important;
  transform: none !important;
}
.sm-stage .container_profile {
  position: relative !important;
  z-index: 2 !important;
}
.profile_up_avatar_wrap video.profile_up_avatar {
  width: 140px;
  height: 140px;
  object-fit: cover;
}
.profile_up_avatar_wrap video.profile_up_avatar_frame {
  position: absolute;
  inset: -22px;
  width: calc(100% + 44px);
  height: calc(100% + 44px);
  object-fit: contain;
  background: transparent;
  pointer-events: none;
}
