/* Create (your games), the game editor and the Catalog. */
.back-link { color: var(--brand); display: inline-block; font-weight: bold; margin-bottom: 14px; text-decoration: none; }
.back-link:hover { text-decoration: underline; }

/* ── My games ───────────────────────────────────────────── */
.my-games { display: grid; gap: 14px; list-style: none; margin: 0; padding: 0; }

.my-game {
    align-items: center;
    display: grid;
    gap: 18px;
    grid-template-columns: 220px minmax(0, 1fr) auto;
    padding: 14px;
}

.my-game-thumb .game-thumb { border-radius: 10px; }
.my-game-thumb .game-thumb.placeholder { font-size: 20px; }
.my-game-name { align-items: center; display: flex; flex-wrap: wrap; gap: 10px; }
.my-game-name a { color: var(--ink); font: bold 20px/1.25 Arial, sans-serif; overflow-wrap: anywhere; text-decoration: none; }
.my-game-name a:hover { text-decoration: underline; }
.my-game-meta { color: var(--muted); font-size: 14px; margin: 6px 0 0; }
.my-game-meta .live { color: var(--green-dark); }
.my-game-description {
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    color: var(--text);
    display: -webkit-box;
    font-size: 14px;
    line-height: 1.5;
    margin: 8px 0 0;
    overflow: hidden;
}
.my-game-description em { color: var(--muted); }
.my-game-actions { display: flex; flex-direction: column; gap: 8px; }

.visibility-badge {
    border-radius: 999px;
    font: bold 12px/1 Arial, sans-serif;
    padding: 5px 9px;
}

.visibility-badge.public { background: #e3f5e6; color: #23702f; }
.visibility-badge.private { background: #fff3cf; color: #7a5b05; }

@media (max-width: 760px) {
    .my-game { grid-template-columns: minmax(0, 1fr); }
    .my-game-actions { flex-direction: row; }
}

/* ── Editor ─────────────────────────────────────────────── */
.edit-grid {
    align-items: start;
    display: grid;
    gap: 22px;
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 1fr);
}

.edit-side { display: grid; gap: 22px; }
.edit-form { display: grid; gap: 18px; }
.field { border: 0; display: grid; gap: 8px; margin: 0; padding: 0; }
.field-label { color: var(--ink); display: flex; font-weight: bold; justify-content: space-between; }
.field-count { color: var(--muted); font-size: 13px; font-weight: normal; }
.field-hint { color: var(--muted); font-size: 14px; line-height: 1.5; margin: 10px 0 0; }

.field input[type="text"], .field textarea {
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    color: var(--text);
    font: 16px/1.5 Arial, sans-serif;
    padding: 10px 12px;
    resize: vertical;
    width: 100%;
}

.field input[type="text"]:focus, .field textarea:focus { border-color: var(--brand-2); box-shadow: 0 0 0 3px #d3e6fb; outline: none; }

.visibility legend { margin-bottom: 8px; }
.choice {
    align-items: flex-start;
    border: 1px solid var(--line);
    border-radius: 11px;
    cursor: pointer;
    display: flex;
    gap: 10px;
    padding: 12px;
}
.choice + .choice { margin-top: 8px; }
.choice:has(input:checked) { background: var(--wash); border-color: var(--brand-2); }
.choice input { accent-color: var(--brand); margin-top: 2px; }
.choice strong { color: var(--ink); display: block; margin-bottom: 2px; }
.choice span { color: var(--muted); font-size: 14px; }

.form-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.form-message { color: var(--muted); font-weight: bold; margin: 0; }
.form-message.success { color: var(--green-dark); }
.form-message.error { color: #b3261e; }
.form-message:empty { display: none; }

.thumb-preview { margin-top: 12px; }
.thumb-preview .game-thumb { border: 1px solid var(--line); border-radius: 10px; }
.thumb-preview .game-thumb.placeholder { font-size: 22px; }

.file-button { position: relative; }
.file-button input { cursor: pointer; inset: 0; opacity: 0; position: absolute; width: 100%; }
.file-button:focus-within { box-shadow: 0 0 0 3px #e7b500; }
.danger-zone { border-color: #f0d3cf; }

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

/* ── Catalog ────────────────────────────────────────────── */
.catalog-layout { align-items: start; display: grid; gap: 22px; grid-template-columns: 200px minmax(0, 1fr); }
.catalog-categories { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); display: grid; gap: 2px; padding: 8px; }
.catalog-categories button {
    background: none;
    border: 0;
    border-radius: 9px;
    color: var(--ink);
    cursor: pointer;
    font: 15px/1 Arial, sans-serif;
    padding: 11px 12px;
    text-align: left;
}
.catalog-categories button:hover { background: var(--wash); }
.catalog-categories button[aria-pressed="true"] { background: var(--wash); color: var(--brand); font-weight: bold; }
.catalog-empty { padding: 56px 24px; }
.catalog-empty p { margin: 0 auto 18px; max-width: 46ch; }
.empty-icon { filter: invert(38%) sepia(51%) saturate(650%) hue-rotate(174deg) brightness(88%) contrast(90%); height: 48px; margin-bottom: 10px; opacity: 0.7; width: 48px; }
.search-box input:disabled { background: transparent; cursor: not-allowed; }

@media (max-width: 760px) {
    .catalog-layout { grid-template-columns: minmax(0, 1fr); }
    .catalog-categories { display: flex; overflow-x: auto; }
    .catalog-categories button { white-space: nowrap; }
}

/* ── Account settings ───────────────────────────────────── */
.account-card { align-items: center; display: flex; flex-wrap: wrap; gap: 18px 22px; }
.account-card .headshot.lg { height: 96px; width: 96px; }
.account-details { flex: 1 1 260px; min-width: 0; }
.account-details dl { display: grid; gap: 4px; margin: 10px 0 0; }
.account-details dl div { display: flex; gap: 10px; }
.account-details dt { color: var(--muted); min-width: 84px; }
.account-details dd { color: var(--ink); font-weight: bold; margin: 0; overflow-wrap: anywhere; }
.account-details dd.ok { color: var(--green-dark); }
.account-links { display: flex; flex-direction: column; gap: 10px; }
.bio-card { margin-top: 22px; }


/* Get Gobrix Studio */
.studio-download {
    align-items: center;
    background: linear-gradient(100deg, #1f5fbf, #3f8fe8);
    border: 0;
    border-bottom: 4px solid #ffc828;
    color: #fff;
    display: flex;
    gap: 18px;
    margin: 0 0 20px;
    padding: 18px 22px;
}
.studio-download-logo { height: 56px; width: 56px; flex: none; }
.studio-download-text { flex: 1; min-width: 0; }
.studio-download-text h2 { color: #fff; font-size: 20px; margin: 0 0 4px; }
.studio-download-text p { color: #e4eefc; margin: 0; }
.studio-download-button { flex: none; white-space: nowrap; }
.studio-download-soon {
    background: rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    flex: none;
    font-weight: bold;
    padding: 6px 14px;
}
@media (max-width: 640px) {
    .studio-download { flex-wrap: wrap; }
    .studio-download-button, .studio-download-soon { width: 100%; text-align: center; }
}

/* 0.8.0: Edit game > Badges */
.edit-badge-list { list-style: none; margin: 12px 0; padding: 0; }
.edit-badge { align-items: center; border-top: 1px solid var(--line); display: flex; gap: 10px; padding: 8px 0; }
.edit-badge:first-child { border-top: 0; }
.edit-badge.off img { filter: grayscale(1); opacity: 0.6; }
.edit-badge-text { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.edit-badge-text small { color: var(--muted); font-size: 12px; }
.badge-form { border-top: 1px solid var(--line); display: grid; gap: 10px; padding-top: 12px; }
.link-button.danger { color: #b3261e !important; }
