/* ============================================================
   cms_community - Panel component CSS (auto-extracted)
   Generated from cms_community/templates/cms_community/*.html <style> blocks
   Do not edit directly; edit the source templates or re-run extract.
   ============================================================ */

/* Common avatar */
.cmsc-avatar {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, #1e3a8a, #d97706);
  color: #fff; font-weight: 700; font-size: 0.8rem; flex-shrink: 0;
}
.cmsc-avatar-sm { width: 24px; height: 24px; font-size: 0.65rem; }
.cmsc-avatar-lg { width: 56px; height: 56px; font-size: 1.1rem; }
.cmsc-avatar-online { position: relative; }
.cmsc-avatar-online::after {
  content: ""; position: absolute; bottom: 0; right: 0;
  width: 10px; height: 10px; border-radius: 50%;
  background: #10b981; border: 2px solid #fff;
}
.cmsc-card {
  background: #fff; border: 1px solid #e5e7eb;
  border-radius: 6px; overflow: hidden;
}
.cmsc-card-head {
  padding: 12px 16px; background: #f8fafc;
  border-bottom: 1px solid #e5e7eb;
  display: flex; align-items: center; justify-content: space-between;
  font-weight: 700; color: #1e3a8a; font-size: 0.95rem;
}
.cmsc-card-head a.more {
  font-size: 0.78rem; font-weight: 400; color: #2563eb;
  text-decoration: none;
}
.cmsc-empty {
  padding: 20px; text-align: center; color: #9ca3af;
  font-size: 0.85rem;
}
.cmsc-empty i { font-size: 2rem; display: block; margin-bottom: 6px; color: #d1d5db; }
.cmsc-badge {
  display: inline-block; padding: 1px 8px; border-radius: 999px;
  font-size: 0.7rem; font-weight: 700;
}
.cmsc-badge-unread { background: #dc2626; color: #fff; }
.cmsc-badge-lv {
  background: #eff4fd; color: #1e3a8a; padding: 2px 8px;
  border-radius: 3px; font-size: 0.7rem; font-weight: 700;
}
.cmsc-badge-best { background: #fef3c7; color: #92400e; }
.cmsc-badge-pin { background: #dbeafe; color: #1e40af; }
.cmsc-badge-lock { background: #e5e7eb; color: #4b5563; }
.cmsc-badge-resolved { background: #d1fae5; color: #047857; }
.cmsc-link { color: #2563eb; text-decoration: none; }
a.cmsc-link:hover { text-decoration: underline; }

.cmsc-post-list { padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.cmsc-post { background: #fff; border: 1px solid #e5e7eb; border-radius: 6px; padding: 14px 18px; }
.cmsc-post-best { border-color: #fde68a; background: #fffbeb; }
.cmsc-post-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.cmsc-post-head strong { font-size: 0.9rem; }
.cmsc-post-time { font-size: 0.72rem; color: #6b7280; }
.cmsc-post-actions { margin-left: auto; display: flex; gap: 10px; font-size: 0.78rem; color: #6b7280; align-items: center; }
.cmsc-post-body { font-size: 0.9rem; line-height: 1.7; color: #1f2937; }

.cmsc-thread-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.cmsc-thread-table thead { background: #f8fafc; font-size: 0.72rem; color: #6b7280; letter-spacing: 0.06em; text-transform: uppercase; }
.cmsc-thread-table th, .cmsc-thread-table td { padding: 10px 14px; text-align: left; border-bottom: 1px solid #f3f4f6; }
.cmsc-thread-table tr:hover { background: #f8fafc; }
.cmsc-thread-title { font-weight: 600; }
.cmsc-thread-author { font-size: 0.74rem; color: #6b7280; margin-top: 2px; }
.cmsc-thread-count { text-align: center; color: #6b7280; font-weight: 700; }

.cmsc-friend-wrap { padding: 16px; }
.cmsc-friend-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.cmsc-friend-list .cmsc-friend { display: flex !important; flex-direction: row !important; align-items: center !important; padding: 8px 12px !important; border-radius: 6px; }
.cmsc-friend { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px; border-radius: 6px; text-decoration: none; color: #1f2937; background: #f8fafc; }
.cmsc-friend:hover { background: #eff4fd; color: #1e3a8a; }
.cmsc-friend-name { font-size: 0.82rem; font-weight: 600; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }

.cmsc-badge-count { font-size: 0.72rem; color: #6b7280; font-weight: 400; }
.cmsc-badge-grid { padding: 14px; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.cmsc-badge-item { display: flex; gap: 10px; align-items: center; background: #f8fafc; border-radius: 6px; padding: 10px; }
.cmsc-badge-item:hover { background: #eff4fd; }
.cmsc-badge-icon { flex-shrink: 0; width: 38px; height: 38px; border-radius: 50%; color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 1rem; }
.cmsc-badge-info { min-width: 0; }
.cmsc-badge-name { font-size: 0.82rem; font-weight: 700; color: #1f2937; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmsc-badge-date { font-size: 0.7rem; color: #6b7280; }
.cmsc-badge-special { background: linear-gradient(135deg, #fef3c7, #fff); border: 1px solid #fde68a; }

.cmsc-lvprog-body { padding: 16px; }
.cmsc-lv-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.cmsc-lv-icon { width: 48px; height: 48px; border-radius: 50%; color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 1.2rem; flex-shrink: 0; }
.cmsc-lv-label { font-size: 0.88rem; color: #6b7280; }
.cmsc-lv-label strong { color: #1e3a8a; font-size: 1rem; }
.cmsc-lv-xp { font-size: 1.2rem; font-weight: 800; color: #d97706; font-family: monospace; }
.cmsc-lv-next { margin-left: auto; text-align: right; }
.cmsc-lv-next-label { font-size: 0.7rem; color: #9ca3af; text-transform: uppercase; letter-spacing: 0.08em; }
.cmsc-lv-next-name { font-size: 0.85rem; font-weight: 700; color: #1f2937; }
.cmsc-lv-next-need { font-size: 0.78rem; color: #6b7280; }
.cmsc-lv-bar-wrap { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.cmsc-lv-bar { flex: 1; height: 14px; background: #f3f4f6; border-radius: 999px; overflow: hidden; }
.cmsc-lv-bar-fill { height: 100%; background: linear-gradient(90deg, #1e3a8a, #d97706); border-radius: 999px; }
.cmsc-lv-bar-percent { font-size: 0.82rem; font-weight: 700; color: #1e3a8a; min-width: 3em; text-align: right; }
.cmsc-lv-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; padding: 10px; background: #f8fafc; border-radius: 6px; }
.cmsc-lv-stats > div { text-align: center; }
.cmsc-lv-stats .lbl { font-size: 0.7rem; color: #6b7280; display: block; }
.cmsc-lv-stats strong { font-size: 1rem; color: #1f2937; }
.cmsc-lv-perks { margin-top: 12px; padding: 8px 12px; background: #fef9e6; border-left: 3px solid #f59e0b; font-size: 0.82rem; color: #78350f; border-radius: 3px; }

.cmsc-ranking-list { list-style: none; padding: 0; margin: 0; }
.cmsc-ranking-list li { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid #f3f4f6; }
.cmsc-ranking-list li:hover { background: #f8fafc; }
.cmsc-ranking-list li:last-child { border-bottom: none; }
.cmsc-rank-num { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; font-weight: 800; font-size: 0.85rem; background: #f3f4f6; color: #6b7280; flex-shrink: 0; }
.cmsc-rank-1 { background: #fef3c7; color: #92400e; }
.cmsc-rank-2 { background: #e5e7eb; color: #374151; }
.cmsc-rank-3 { background: #fed7aa; color: #9a3412; }
.cmsc-rank-name { flex: 1; min-width: 0; }
.cmsc-rank-tag { font-size: 0.72rem; color: #6b7280; margin-top: 2px; }
.cmsc-rank-score { font-family: monospace; font-weight: 700; color: #d97706; font-size: 1rem; }

.cmsc-msg-list { list-style: none; margin: 0; padding: 0; }
.cmsc-msg-list li { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid #f3f4f6; }
.cmsc-msg-list li:last-child { border-bottom: none; }
.cmsc-msg-list li:hover { background: #f8fafc; }
.cmsc-msg-link { display: flex; gap: 12px; flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.cmsc-msg-link:hover { color: inherit; text-decoration: none; }
.cmsc-msg-unread { background: #eff6ff; }
.cmsc-msg-unread .cmsc-msg-subject { font-weight: 700; color: #1e3a8a; }
.cmsc-msg-body { flex: 1; min-width: 0; }
.cmsc-msg-top { display: flex; justify-content: space-between; align-items: baseline; }
.cmsc-msg-top strong { font-size: 0.88rem; }
.cmsc-msg-time { font-size: 0.72rem; color: #6b7280; }
.cmsc-msg-subject { font-size: 0.9rem; color: #1f2937; margin: 2px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmsc-msg-preview { font-size: 0.8rem; color: #6b7280; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmsc-msg-profile-action { flex: 0 0 auto; font-size: 0.78rem; font-weight: 700; }
.cmsc-lobby-chat { color: #1f2937; }
.cmsc-chat-channel {
  color: #6b7280; font-size: 0.76rem; font-weight: 600;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 55%;
}
.cmsc-chat-log {
  display: grid; gap: 10px; padding: 14px; max-height: 360px;
  overflow: auto; background: #f8fafc;
}
.cmsc-chat-entry { display: flex; gap: 10px; align-items: flex-start; }
.cmsc-chat-entry-body {
  min-width: 0; flex: 1; border: 1px solid #e5e7eb; border-radius: 6px;
  background: #fff; padding: 9px 11px;
}
.cmsc-chat-entry-body header {
  display: flex; justify-content: space-between; gap: 10px; align-items: baseline;
  margin-bottom: 4px;
}
.cmsc-chat-entry-body strong { color: #1f2937; font-size: 0.84rem; }
.cmsc-chat-entry-body time { color: #6b7280; font-size: 0.72rem; flex: 0 0 auto; }
.cmsc-chat-entry-body p { margin: 0; color: #1f2937; line-height: 1.55; font-size: 0.88rem; overflow-wrap: anywhere; }
.cmsc-chat-report { margin-top: 6px; text-align: right; }
.cmsc-chat-report button {
  border: 0; background: transparent; color: #6b7280; padding: 0;
  font-size: 0.72rem; font-weight: 700;
}
.cmsc-chat-report button:hover { color: #b91c1c; text-decoration: underline; }
.cmsc-chat-form {
  display: grid; gap: 8px; padding: 12px 14px; border-top: 1px solid #e5e7eb;
  background: #fff;
}
.cmsc-chat-form textarea {
  width: 100%; border: 1px solid #e5e7eb; border-radius: 6px;
  padding: 9px 10px; resize: vertical; min-height: 52px; font-size: 0.88rem;
}
.cmsc-chat-form-row { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.cmsc-chat-form-row span { color: #b91c1c; font-size: 0.76rem; }
.cmsc-chat-form-row button {
  border: 0; border-radius: 6px; background: #14b8a6; color: #042f2e;
  padding: 7px 13px; font-weight: 800; font-size: 0.82rem;
}
.cmsc-chat-form-row button:hover { background: #0f766e; color: #fff; }
.cmsc-messages-page { display: grid; gap: 18px; }
.cmsc-page-head, .cmsc-thread-nav {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.cmsc-page-head h1 { margin: 0; font-size: 1.6rem; color: #1f2937; }
.cmsc-flash-list { display: grid; gap: 8px; }
.cmsc-flash {
  padding: 10px 12px; border-radius: 6px; border: 1px solid #dbeafe;
  background: #eff6ff; color: #1e40af; font-size: 0.86rem;
}
.cmsc-flash-error { border-color: #fecaca; background: #fef2f2; color: #b91c1c; }
.cmsc-compose-card { overflow: visible; }
.cmsc-compose-recipient {
  display: flex; align-items: center; gap: 10px; padding: 14px 16px 0;
}
.cmsc-safety-actions {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  padding: 10px 16px 0;
}
.cmsc-safety-btn {
  border: 1px solid #d1d5db; background: #fff; color: #374151;
  border-radius: 6px; padding: 6px 10px; font-size: 0.78rem; font-weight: 700;
}
.cmsc-safety-btn:hover { background: #f8fafc; }
.cmsc-safety-btn.is-danger { border-color: #fecaca; color: #b91c1c; }
.cmsc-safety-actions span { color: #6b7280; font-size: 0.78rem; }
.cmsc-message-form {
  display: grid; gap: 10px; padding: 16px;
}
.cmsc-message-form input,
.cmsc-message-form textarea {
  width: 100%; border: 1px solid #e5e7eb; border-radius: 6px;
  padding: 10px 12px; font-size: 0.92rem; background: #fff;
}
.cmsc-message-form textarea { resize: vertical; }
.cmsc-message-form button {
  justify-self: start; border: 0; border-radius: 999px;
  padding: 8px 16px; background: #1e3a8a; color: #fff;
  font-weight: 700;
}
.cmsc-thread-card { overflow: hidden; }
.cmsc-thread-messages { display: grid; gap: 12px; padding: 16px; background: #f8fafc; }
.cmsc-thread-message { display: flex; gap: 10px; align-items: flex-start; }
.cmsc-thread-message > div {
  max-width: min(720px, 82%); padding: 10px 12px; border: 1px solid #e5e7eb;
  border-radius: 8px; background: #fff;
}
.cmsc-thread-message.is-own { flex-direction: row-reverse; }
.cmsc-thread-message.is-own > div { background: #eff6ff; border-color: #bfdbfe; }
.cmsc-thread-message header {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  margin-bottom: 6px;
}
.cmsc-thread-message header strong { color: #1f2937; font-size: 0.86rem; }
.cmsc-thread-message time { color: #6b7280; font-size: 0.72rem; }
.cmsc-thread-message p { margin: 0; color: #1f2937; line-height: 1.6; font-size: 0.9rem; }
@media (max-width: 575.98px) {
  .cmsc-page-head, .cmsc-thread-nav { align-items: flex-start; flex-direction: column; }
  .cmsc-msg-list li { align-items: flex-start; flex-direction: column; }
  .cmsc-thread-message > div { max-width: 100%; }
}

.cmsc-notif-list { list-style: none; margin: 0; padding: 0; }
.cmsc-notif-list li { display: flex; gap: 12px; padding: 10px 16px; border-bottom: 1px solid #f3f4f6; }
.cmsc-notif-list li:last-child { border-bottom: none; }
.cmsc-notif-list li:hover { background: #f8fafc; }
.cmsc-notif-unread { background: #eff6ff; }
.cmsc-notif-icon { flex-shrink: 0; width: 32px; height: 32px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 0.85rem; }
.cmsc-notif-friend_request, .cmsc-notif-friend_accept { background: #dbeafe; color: #1e40af; }
.cmsc-notif-message { background: #e0e7ff; color: #3730a3; }
.cmsc-notif-post_reply, .cmsc-notif-post_like { background: #fee2e2; color: #dc2626; }
.cmsc-notif-best_answer { background: #d1fae5; color: #059669; }
.cmsc-notif-badge_earned, .cmsc-notif-level_up { background: #fef3c7; color: #d97706; }
.cmsc-notif-system { background: #e5e7eb; color: #374151; }
.cmsc-notif-body { flex: 1; min-width: 0; }
.cmsc-notif-title { font-size: 0.88rem; color: #1f2937; }
.cmsc-notif-unread .cmsc-notif-title { font-weight: 700; }
.cmsc-notif-text { font-size: 0.78rem; color: #6b7280; margin-top: 2px; }
.cmsc-notif-time { font-size: 0.72rem; color: #9ca3af; margin-top: 4px; }

.cmsc-online-list { list-style: none; margin: 0; padding: 0; }
.cmsc-online-list li { display: flex; align-items: center; gap: 8px; padding: 8px 14px; border-bottom: 1px solid #f3f4f6; font-size: 0.88rem; }
.cmsc-online-list li:last-child { border-bottom: none; }
.cmsc-online-list li:hover { background: #f8fafc; }
.cmsc-online-dot { margin-left: auto; font-size: 0.7rem; color: #10b981; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }

.cmsc-contrib-list { padding: 12px; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.cmsc-contrib-item { display: flex; gap: 12px; align-items: flex-start; padding: 10px; background: #f8fafc; border-radius: 6px; }
.cmsc-contrib-info { flex: 1; min-width: 0; }
.cmsc-contrib-name { display: inline; font-weight: 700; font-size: 0.92rem; }
.cmsc-contrib-meta { display: flex; gap: 10px; font-size: 0.76rem; color: #6b7280; margin-top: 4px; }
.cmsc-contrib-tag { font-size: 0.74rem; color: #6b7280; margin-top: 4px; font-style: italic; }

/* QuickGamesArena shogi dark theme overrides. */
.gameportal:has(.qg-shogi-page-head) .cmsc-card,
.gameportal:has(.qg-shogi-site) .cmsc-card {
  background: rgba(15,23,42,0.86);
  border-color: rgba(148,163,184,0.18);
  color: #e5edf7;
  box-shadow: 0 16px 36px rgba(0,0,0,0.22);
}
.gameportal:has(.qg-shogi-page-head) .cmsc-card-head,
.gameportal:has(.qg-shogi-site) .cmsc-card-head {
  background: linear-gradient(180deg, rgba(30,41,59,0.98), rgba(15,23,42,0.92));
  border-bottom-color: rgba(148,163,184,0.16);
  color: #fde68a;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-card-head a.more,
.gameportal:has(.qg-shogi-site) .cmsc-card-head a.more,
.gameportal:has(.qg-shogi-page-head) .cmsc-link,
.gameportal:has(.qg-shogi-site) .cmsc-link {
  color: #5eead4;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-empty,
.gameportal:has(.qg-shogi-site) .cmsc-empty {
  color: #94a3b8;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-empty i,
.gameportal:has(.qg-shogi-site) .cmsc-empty i {
  color: #64748b;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-log,
.gameportal:has(.qg-shogi-site) .cmsc-chat-log,
.gameportal:has(.qg-shogi-page-head) .cmsc-thread-messages,
.gameportal:has(.qg-shogi-site) .cmsc-thread-messages {
  background: rgba(7,11,18,0.54);
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-entry-body,
.gameportal:has(.qg-shogi-site) .cmsc-chat-entry-body,
.gameportal:has(.qg-shogi-page-head) .cmsc-thread-message > div,
.gameportal:has(.qg-shogi-site) .cmsc-thread-message > div,
.gameportal:has(.qg-shogi-page-head) .cmsc-post,
.gameportal:has(.qg-shogi-site) .cmsc-post {
  background: rgba(15,23,42,0.78);
  border-color: rgba(148,163,184,0.18);
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-entry-body strong,
.gameportal:has(.qg-shogi-site) .cmsc-chat-entry-body strong,
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-entry-body p,
.gameportal:has(.qg-shogi-site) .cmsc-chat-entry-body p,
.gameportal:has(.qg-shogi-page-head) .cmsc-post-body,
.gameportal:has(.qg-shogi-site) .cmsc-post-body,
.gameportal:has(.qg-shogi-page-head) .cmsc-thread-message p,
.gameportal:has(.qg-shogi-site) .cmsc-thread-message p {
  color: #dbeafe;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-entry-body time,
.gameportal:has(.qg-shogi-site) .cmsc-chat-entry-body time,
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-channel,
.gameportal:has(.qg-shogi-site) .cmsc-chat-channel,
.gameportal:has(.qg-shogi-page-head) .cmsc-post-time,
.gameportal:has(.qg-shogi-site) .cmsc-post-time {
  color: #94a3b8;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-form,
.gameportal:has(.qg-shogi-site) .cmsc-chat-form {
  background: rgba(15,23,42,0.92);
  border-top-color: rgba(148,163,184,0.16);
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-form textarea,
.gameportal:has(.qg-shogi-site) .cmsc-chat-form textarea,
.gameportal:has(.qg-shogi-page-head) .cmsc-message-form input,
.gameportal:has(.qg-shogi-site) .cmsc-message-form input,
.gameportal:has(.qg-shogi-page-head) .cmsc-message-form textarea,
.gameportal:has(.qg-shogi-site) .cmsc-message-form textarea {
  background: rgba(7,11,18,0.76);
  border-color: rgba(148,163,184,0.24);
  color: #e5edf7;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-form textarea::placeholder,
.gameportal:has(.qg-shogi-site) .cmsc-chat-form textarea::placeholder {
  color: #64748b;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-form-row button,
.gameportal:has(.qg-shogi-site) .cmsc-chat-form-row button {
  background: #14b8a6;
  color: #042f2e;
}
.gameportal:has(.qg-shogi-page-head) .cmsc-chat-form-row button:hover,
.gameportal:has(.qg-shogi-site) .cmsc-chat-form-row button:hover {
  background: #facc15;
  color: #07111f;
}
