/* Steam-profile-style personal site
   Palette references: https://partner.steamgames.com style guides */

:root {
  --bg: #1b2838;
  --bg-darker: #171a21;
  --bg-darkest: #0e1620;
  --panel: #16202d;
  --panel-grad-from: rgba(62, 99, 130, 0.35);
  --panel-grad-to: rgba(62, 99, 130, 0.08);
  --panel-border: #000;
  --text: #c7d5e0;
  --text-muted: #8f98a0;
  --text-dim: #6a7480;
  --link: #66c0f4;
  --link-hover: #c7d5e0;
  --in-game: #90ba3c;
  --in-game-soft: rgba(144, 186, 60, 0.15);
  --online: #57cbde;
  --offline: #898989;
  --accent-blue: #67c1f5;
  --accent-blue-dark: #417a9b;
  --gold: #e1b941;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Motiva Sans", -apple-system, BlinkMacSystemFont, "Segoe UI",
    Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--link); text-decoration: none; }
a:hover { color: var(--link-hover); }

/* ===== Top bar ===== */

.topbar {
  background: var(--bg-darker);
  border-bottom: 1px solid #000;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.topbar-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  height: 54px;
}

.topbar-brand {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.05em;
  color: var(--text);
  text-transform: uppercase;
}
.topbar-brand span { color: var(--text-muted); font-size: 0.7em; vertical-align: super; }

.topbar-nav {
  display: flex;
  gap: 1.4rem;
  flex: 1;
}

.topbar-nav a {
  color: var(--text);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.topbar-nav a:hover { color: var(--link); }

.topbar-user {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.85rem;
}

.topbar-username { color: var(--link); }

.topbar-avatar {
  display: inline-block;
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg, #67c1f5, #2a475e);
  border: 1px solid #000;
  flex-shrink: 0;
}

/* ===== Profile header ===== */

.profile-header {
  position: relative;
  background: var(--bg-darkest);
  border-bottom: 1px solid #000;
  overflow: hidden;
}

.profile-header-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(103, 193, 245, 0.15), transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(144, 186, 60, 0.08), transparent 60%),
    linear-gradient(180deg, #2a3f5a 0%, #1b2838 100%);
  z-index: 0;
}

.profile-inner {
  position: relative;
  z-index: 1;
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem 1rem;
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2rem;
}

/* avatar column */

.profile-avatar-col { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; }

.avatar-frame {
  padding: 4px;
  background: linear-gradient(135deg, #67c1f5, #2a475e);
  box-shadow: 0 0 12px rgba(103, 193, 245, 0.25);
}

.avatar {
  width: 184px;
  height: 184px;
  background: linear-gradient(135deg, #2a475e, #1b2838);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  font-weight: 300;
  color: var(--link);
  letter-spacing: -0.05em;
}

.level-badge {
  margin-top: 0.75rem;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #5a8aaa, #1b2838 75%);
  border: 2px solid #67c1f5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text);
  box-shadow: 0 0 10px rgba(103, 193, 245, 0.4);
}

.level-label { font-size: 0.6rem; text-transform: uppercase; color: var(--text-muted); letter-spacing: 0.1em; }
.level-number { font-size: 1.4rem; font-weight: 700; line-height: 1; }

.xp-bar {
  margin-top: 0.5rem;
  width: 180px;
  height: 6px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid #000;
  position: relative;
}
.xp-fill { height: 100%; background: linear-gradient(90deg, #67c1f5, #57cbde); }

.xp-text { margin: 0.25rem 0 0; font-size: 0.72rem; color: var(--text-dim); text-align: center; }

/* info column */

.profile-info-col { display: flex; flex-direction: column; gap: 0.75rem; }

.persona-name {
  margin: 0;
  font-size: 2rem;
  font-weight: 300;
  color: #fff;
  line-height: 1.1;
}

.real-name { margin: 0; color: var(--text-muted); font-size: 0.9rem; }
.country-flag {
  display: inline-block;
  padding: 1px 6px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.75rem;
  color: var(--text);
}

.status-block {
  padding: 0.6rem 0.85rem;
  border-left: 4px solid var(--in-game);
  background: var(--in-game-soft);
  max-width: 360px;
}
.status-block.in-game .status-label { color: var(--in-game); }
.status-block.online .status-label { color: var(--online); }

.status-label { margin: 0; font-weight: 600; font-size: 0.9rem; }
.status-detail { margin: 0.15rem 0 0; color: var(--text); font-size: 0.85rem; }

.profile-summary { color: var(--text); max-width: 560px; }
.profile-summary p { margin: 0; }

.profile-stats {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 0;
  display: flex;
  gap: 1.75rem;
  flex-wrap: wrap;
}
.profile-stats li { display: flex; flex-direction: column; }
.profile-stats strong { font-size: 1.4rem; font-weight: 400; color: var(--link); line-height: 1; }
.profile-stats span { font-size: 0.7rem; text-transform: uppercase; color: var(--text-muted); letter-spacing: 0.08em; margin-top: 0.2rem; }

/* ===== Content grid ===== */

.content-grid {
  max-width: 1000px;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 1.5rem;
}

.main-col, .side-col { display: flex; flex-direction: column; gap: 1.5rem; }

/* ===== Showcase panels ===== */

.showcase {
  background: linear-gradient(to right, var(--panel-grad-from), var(--panel-grad-to)), var(--panel);
  border: 1px solid #000;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.03) inset;
}

.showcase-header {
  padding: 0.55rem 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.4);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  background: rgba(0, 0, 0, 0.15);
}

.showcase-header h2 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 400;
  color: #fff;
  text-transform: none;
  letter-spacing: 0.02em;
}

.showcase-sub { font-size: 0.78rem; color: var(--text-muted); }

.showcase-body { padding: 1rem; }

/* ===== Featured Showcase ===== */

.featured-showcase {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 1rem;
}

.featured-art {
  height: 140px;
  background: linear-gradient(135deg, #355579, #1b2838);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-size: 0.8rem;
  border: 1px solid #000;
}

.featured-text p { margin: 0 0 0.6rem; }
.featured-meta { color: var(--text-muted); font-size: 0.78rem; }
.featured-meta span:first-child { color: var(--gold); }

/* ===== Recent Activity (jobs as games) ===== */

.activity-item {
  display: grid;
  grid-template-columns: 184px 1fr;
  gap: 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.4);
}
.activity-item:last-child { border-bottom: 0; padding-bottom: 0; }
.activity-item:first-child { padding-top: 0; }

.activity-art {
  height: 69px;
  background: linear-gradient(135deg, #355579, #1b2838);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-size: 0.75rem;
  border: 1px solid #000;
  overflow: hidden;
}

.activity-art img,
.workshop-thumb img,
.featured-art img,
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.activity-title {
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--link);
  display: block;
}
.activity-hours { margin: 0.1rem 0 0; font-size: 0.8rem; color: var(--text); }
.activity-last { margin: 0.05rem 0 0.5rem; font-size: 0.75rem; color: var(--text-muted); }

.achievement-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(0, 0, 0, 0.4);
  margin-bottom: 0.5rem;
  font-size: 0.78rem;
}
.achievement-icon {
  width: 14px;
  height: 14px;
  background: var(--gold);
  clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  flex-shrink: 0;
}
.achievement-text strong { color: var(--text); font-weight: 600; }

.activity-bullets {
  margin: 0.25rem 0 0;
  padding-left: 1.1rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}
.activity-bullets li { margin-bottom: 0.2rem; }

/* ===== Workshop Showcase ===== */

.workshop-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.workshop-item {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(0, 0, 0, 0.5);
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
}

.workshop-thumb {
  height: 110px;
  background: linear-gradient(135deg, #355579, #1b2838);
  border: 1px solid #000;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-size: 0.75rem;
  margin-bottom: 0.55rem;
}

.workshop-item h3 { margin: 0 0 0.25rem; font-size: 0.95rem; font-weight: 400; }
.workshop-item h3 a { color: var(--link); }
.workshop-desc { margin: 0 0 0.5rem; font-size: 0.82rem; color: var(--text-muted); }

.workshop-meta {
  margin: auto 0 0.4rem;
  font-size: 0.78rem;
  display: flex;
  justify-content: space-between;
  color: var(--text-muted);
}
.workshop-meta .rating { color: var(--gold); }

.workshop-links { margin: 0; font-size: 0.78rem; color: var(--text-muted); }

/* ===== Badges ===== */

.badge-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.badge {
  text-align: center;
  padding: 0.6rem 0.4rem;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(0, 0, 0, 0.4);
}

.badge-img {
  width: 64px;
  height: 64px;
  margin: 0 auto 0.4rem;
  background: radial-gradient(circle at 35% 30%, #67c1f5, #1b2838 75%);
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(103, 193, 245, 0.3);
  overflow: hidden;
}

.badge-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.badge-name { margin: 0; font-size: 0.85rem; color: var(--text); }
.badge-level { margin: 0; font-size: 0.7rem; color: var(--text-muted); }

/* ===== Comments / guestbook ===== */

.comment {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.3);
}
.comment:first-child { padding-top: 0; }

.comment-avatar {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, #355579, #1b2838);
  border: 1px solid #000;
}

.comment-author { margin: 0 0 0.2rem; font-size: 0.85rem; }
.comment-date { color: var(--text-dim); font-size: 0.75rem; margin-left: 0.4rem; }
.comment-text { margin: 0; color: var(--text); font-size: 0.85rem; }

.comment-form { padding-top: 0.85rem; display: flex; flex-direction: column; gap: 0.5rem; }
.comment-form-label { font-size: 0.78rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }

.comment-form textarea,
.comment-form input {
  font: inherit;
  background: rgba(0, 0, 0, 0.4);
  color: var(--text);
  border: 1px solid #000;
  padding: 0.5rem 0.65rem;
  width: 100%;
}
.comment-form textarea:focus,
.comment-form input:focus { outline: 1px solid var(--link); }

.comment-form-row { display: flex; gap: 0.5rem; align-items: stretch; }
.comment-form-row input { flex: 1; }

.btn-steam {
  font: inherit;
  background: linear-gradient(to bottom, var(--accent-blue) 5%, var(--accent-blue-dark) 95%);
  color: #fff;
  border: 0;
  padding: 0.4rem 1rem;
  cursor: pointer;
  font-weight: 400;
  font-size: 0.85rem;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
}
.btn-steam:hover { background: linear-gradient(to bottom, #8ed5fb 5%, #5494b8 95%); color: #fff; }

.resume-body { display: flex; flex-direction: column; gap: 0.75rem; }
.resume-body p { margin: 0; font-size: 0.85rem; color: var(--text); }

.form-status { margin: 0; font-size: 0.8rem; color: var(--in-game); min-height: 1.2em; }

/* ===== Side column: Friends ===== */

.friends-list, .groups-list { display: flex; flex-direction: column; gap: 0.6rem; }

.friend, .group {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 0.65rem;
  padding: 0.5rem;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(0, 0, 0, 0.4);
  color: var(--text);
}
.friend:hover, .group:hover { background: rgba(103, 193, 245, 0.08); color: var(--text); }

.friend-avatar, .group-avatar {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #67c1f5, #2a475e);
  border: 1px solid #000;
}

.friend-info, .group-info { display: flex; flex-direction: column; min-width: 0; }

.friend-name { margin: 0; font-size: 0.9rem; color: var(--link); }
.friend-status { margin: 0.05rem 0 0; font-size: 0.72rem; font-weight: 600; }
.friend-status.in-game { color: var(--in-game); }
.friend-status.online { color: var(--online); }
.friend-status.offline { color: var(--offline); }
.friend-game { margin: 0; font-size: 0.72rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.group-name { margin: 0; font-size: 0.9rem; color: var(--link); }
.group-meta { margin: 0.05rem 0 0; font-size: 0.72rem; color: var(--text-muted); }

/* ===== Footer ===== */

.site-footer {
  background: var(--bg-darker);
  border-top: 1px solid #000;
  padding: 1.25rem 0;
  color: var(--text-dim);
  font-size: 0.78rem;
}

.footer-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 1rem;
  text-align: center;
}

/* ===== Responsive ===== */

@media (max-width: 860px) {
  .content-grid { grid-template-columns: 1fr; }
  .profile-inner { grid-template-columns: 1fr; text-align: center; }
  .profile-avatar-col { justify-self: center; }
  .profile-stats { justify-content: center; }
  .status-block { margin: 0 auto; }
  .featured-showcase { grid-template-columns: 1fr; }
  .activity-item { grid-template-columns: 1fr; }
  .activity-art { height: 100px; }
  .workshop-grid { grid-template-columns: 1fr; }
  .topbar-nav { gap: 0.85rem; }
  .topbar-nav a { font-size: 0.7rem; }
  .topbar-user { display: none; }
}

@media (max-width: 480px) {
  .badge-grid { grid-template-columns: repeat(2, 1fr); }
  .persona-name { font-size: 1.6rem; }
  .profile-stats { gap: 1rem; }
}
