/* Vrienden en berichten: leesbare kaartclubstijl, bestaande popupmaat behouden. */
.online-dialog:has(.social-shell),
.online-dialog:has(.social-chat) {
  font-family: Arial, sans-serif !important;
}

/* Duidelijke speluitnodiging. */
.online-dialog:has(#friendInviteForm) { width: min(720px, calc(100vw - 24px)) !important; }
.online-dialog:has(#friendInviteForm) #onlineContent { display: grid !important; gap: 12px !important; padding: 12px 16px 16px !important; }
.online-dialog:has(#friendInviteForm) .premium-hero { margin: 0 !important; padding: 16px 18px !important; border: 1px solid rgba(211,169,78,.65) !important; border-radius: 14px !important; background: linear-gradient(135deg,#23452f,#10291c) !important; }
.online-dialog:has(#friendInviteForm) .premium-hero > span { color: #efc960 !important; font: 800 11px/1.2 Arial,sans-serif !important; letter-spacing: .08em !important; }
.online-dialog:has(#friendInviteForm) .premium-hero h2 { margin: 5px 0 4px !important; color: #fff4d5 !important; font: 800 clamp(21px,3vw,28px)/1.15 Arial,sans-serif !important; text-shadow: 0 2px 5px rgba(0,0,0,.35) !important; }
.online-dialog:has(#friendInviteForm) .premium-hero p { margin: 0 !important; color: rgba(255,255,255,.88) !important; font: 14px/1.4 Arial,sans-serif !important; }

.online-dialog:has(.invite-sent-confirmation) #onlineContent { padding: 12px 16px 16px !important; }
.online-dialog .invite-sent-confirmation { margin: 0 !important; padding: 17px 18px !important; border: 1px solid rgba(211,169,78,.65) !important; border-radius: 14px !important; background: linear-gradient(135deg,#23452f,#10291c) !important; }
.online-dialog .invite-sent-confirmation > span { color: #efc960 !important; font: 800 11px/1.2 Arial,sans-serif !important; letter-spacing: .08em !important; }
.online-dialog .invite-sent-confirmation h2 { margin: 5px 0 5px !important; color: #fff4d5 !important; font: 800 clamp(21px,3vw,28px)/1.15 Arial,sans-serif !important; text-shadow: 0 2px 5px rgba(0,0,0,.35) !important; }
.online-dialog .invite-sent-confirmation p { margin: 0 !important; color: rgba(255,255,255,.9) !important; font: 14px/1.4 Arial,sans-serif !important; }

#friendInviteForm { display: grid !important; grid-template-columns: repeat(2,minmax(0,1fr)) !important; gap: 12px !important; margin: 0 !important; padding: 16px !important; border: 1px solid rgba(204,159,70,.55) !important; border-radius: 14px !important; background: linear-gradient(145deg,#173b28,#0b281b) !important; }
#friendInviteForm .friend-invite-field { display: grid !important; gap: 6px !important; min-width: 0 !important; color: #f5dfaa !important; font: 700 12px/1.2 Arial,sans-serif !important; }
#friendInviteForm select { width: 100% !important; min-height: 46px !important; padding: 0 42px 0 13px !important; border: 1px solid #c49a49 !important; border-radius: 10px !important; background-color: #fffaf0 !important; color: #173d29 !important; font: 600 15px/1 Arial,sans-serif !important; }

#friendInviteForm .social-check { grid-column: 1/-1 !important; display: flex !important; min-height: 58px !important; margin: 0 !important; padding: 10px 12px !important; align-items: center !important; gap: 12px !important; border: 1px solid rgba(207,169,87,.42) !important; border-radius: 11px !important; background: rgba(255,250,235,.08) !important; color: #fff4d8 !important; cursor: pointer !important; }
#friendInviteForm .social-check input { appearance: none !important; position: relative !important; flex: 0 0 46px !important; width: 46px !important; height: 26px !important; margin: 0 !important; border-radius: 999px !important; background: #7b817c !important; box-shadow: inset 0 0 0 1px rgba(0,0,0,.2) !important; }
#friendInviteForm .social-check input::after { content: "" !important; position: absolute !important; top: 3px !important; left: 3px !important; width: 20px !important; height: 20px !important; border-radius: 50% !important; background: #fff !important; box-shadow: 0 2px 5px rgba(0,0,0,.3) !important; transition: transform .18s ease !important; }
#friendInviteForm .social-check input:checked { background: #15934d !important; }
#friendInviteForm .social-check input:checked::after { transform: translateX(20px) !important; }
#friendInviteForm .social-check > span { display: grid !important; gap: 3px !important; }
#friendInviteForm .social-check strong { color: #fff4d8 !important; font: 700 14px/1.2 Arial,sans-serif !important; }
#friendInviteForm .social-check small { color: rgba(255,255,255,.72) !important; font: 12px/1.3 Arial,sans-serif !important; }

#friendInviteForm > .start-game-button { grid-column: 1/-1 !important; justify-self: center !important; width: min(320px,100%) !important; min-height: 46px !important; margin: 2px 0 0 !important; padding: 0 20px !important; border: 1px solid #d1a44c !important; border-radius: 11px !important; background: linear-gradient(180deg,#1d7544,#0f5030) !important; color: #fff4d3 !important; font: 700 15px/1 Arial,sans-serif !important; letter-spacing: 0 !important; text-transform: none !important; box-shadow: 0 5px 12px rgba(0,0,0,.24) !important; }

@media (max-width: 600px) {
  .online-dialog:has(#friendInviteForm) #onlineContent { padding: 9px !important; }
  #friendInviteForm { grid-template-columns: 1fr !important; padding: 12px !important; gap: 10px !important; }
  #friendInviteForm .social-check, #friendInviteForm > .start-game-button { grid-column: 1 !important; }
}

.online-dialog:has(.social-shell) #onlineContent,
.online-dialog:has(.social-chat) #onlineContent {
  padding: 0 !important;
  overflow-x: hidden !important;
}

.online-dialog:has(.social-shell) .social-shell,
.online-dialog:has(.social-chat) .social-chat {
  padding: 14px !important;
  gap: 14px !important;
  border: 1px solid #c79b49 !important;
  border-radius: 16px !important;
  background:
    radial-gradient(circle at 18% 0%, rgba(255,255,255,.055), transparent 34%),
    linear-gradient(145deg, #0e4b30, #082f20) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 5px 14px rgba(10,37,23,.14) !important;
  color: #fff9ec !important;
}

.online-dialog:has(.social-shell) .social-tabs {
  margin: -14px -14px 6px !important;
  padding: 0 !important;
  gap: 0 !important;
  overflow: hidden !important;
  border: 0 !important;
  border-bottom: 1px solid #c79b49 !important;
  border-radius: 15px 15px 0 0 !important;
  background: #f7eedc !important;
}

.online-dialog:has(.social-shell) .social-tabs button {
  min-height: 56px !important;
  padding: 10px 12px !important;
  border: 0 !important;
  border-right: 1px solid rgba(161,120,50,.34) !important;
  border-radius: 0 !important;
  background: linear-gradient(180deg, #fffaf0, #eee0c7) !important;
  color: #392b20 !important;
  box-shadow: none !important;
  font: 800 14px/1.1 Arial, sans-serif !important;
  text-transform: uppercase !important;
}

.online-dialog:has(.social-shell) .social-tabs button:last-child { border-right: 0 !important; }
.online-dialog:has(.social-shell) .social-tabs button.active {
  background: linear-gradient(180deg, #175a38, #0d4028) !important;
  color: #f3d58b !important;
  box-shadow: inset 0 -2px 0 #cfa54f !important;
}

.online-dialog:has(.social-shell) .social-tabs b {
  margin-left: 5px !important;
  background: #912a24 !important;
  color: #fff8e8 !important;
}

.online-dialog:has(.social-shell) .social-search {
  gap: 10px !important;
  margin: 0 2px 2px !important;
}

.online-dialog:has(.social-shell) .social-search input,
.online-dialog:has(.social-chat) .social-chat-form input {
  min-height: 46px !important;
  border: 1px solid #b98e45 !important;
  border-radius: 11px !important;
  background: rgba(4, 28, 18, .72) !important;
  color: #fffaf0 !important;
  font: 500 14px/1 Arial, sans-serif !important;
  outline: none !important;
}

.online-dialog:has(.social-shell) .social-search input::placeholder,
.online-dialog:has(.social-chat) .social-chat-form input::placeholder {
  color: rgba(255,250,240,.68) !important;
}

.online-dialog:has(.social-shell) .social-search input:focus,
.online-dialog:has(.social-chat) .social-chat-form input:focus {
  border-color: #e1bc68 !important;
  box-shadow: 0 0 0 3px rgba(218,177,89,.14) !important;
}

.online-dialog:has(.social-shell) .social-search > button,
.online-dialog:has(.social-chat) .social-chat-form > button {
  min-height: 42px !important;
  border: 1px solid #d0a654 !important;
  border-radius: 10px !important;
  background: linear-gradient(180deg, #174f33, #0b3521) !important;
  color: #f5d98f !important;
  font: 800 12px/1 Arial, sans-serif !important;
  text-transform: uppercase !important;
}

.online-dialog:has(.social-chat) .social-chat-form {
  grid-template-columns: minmax(0, 1fr) 104px !important;
  align-items: stretch !important;
  gap: 8px !important;
  min-width: 0 !important;
}

.online-dialog:has(.social-chat) .social-chat-form input {
  min-width: 0 !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.online-dialog:has(.social-chat) .social-chat-form > button {
  width: 104px !important;
  min-width: 0 !important;
  max-width: 104px !important;
  padding: 0 8px !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: clip !important;
  box-sizing: border-box !important;
  letter-spacing: 0 !important;
}

.online-dialog:has(.social-shell) .social-list {
  gap: 10px !important;
}

.online-dialog:has(.social-shell) :is(.social-player-card, .social-search-result, .social-invite-card, .social-message-row) {
  padding: 13px 15px !important;
  border: 1px solid rgba(184, 139, 67, .62) !important;
  border-radius: 13px !important;
  background: linear-gradient(145deg, #fffaf0, #eee0c8) !important;
  color: #30251c !important;
  box-shadow: 0 4px 9px rgba(8, 29, 18, .16), inset 0 1px 0 rgba(255,255,255,.72) !important;
  font-family: Arial, sans-serif !important;
}

.online-dialog:has(.social-shell) .social-player-copy strong,
.online-dialog:has(.social-shell) .social-message-row > span,
.online-dialog:has(.social-shell) .social-search-result strong,
.online-dialog:has(.social-shell) .social-invite-card strong {
  color: #143f29 !important;
  font: 800 16px/1.2 Arial, sans-serif !important;
}

.online-dialog:has(.social-shell) :is(.social-player-copy span, .social-search-result small, .social-invite-card small) {
  color: #6c4d26 !important;
  font-size: 12px !important;
}

.online-dialog:has(.social-shell) .presence.online { color: #16763f !important; }
.online-dialog:has(.social-shell) .presence.playing { color: #a64b12 !important; }
.online-dialog:has(.social-shell) .presence.away { color: #8a6815 !important; }

.online-dialog:has(.social-shell) .social-message-row.has-unread {
  border-width: 2px !important;
  border-color: #0e7141 !important;
  background: linear-gradient(145deg, #f2fff7, #dcefdc) !important;
}

.online-dialog:has(.social-shell) .social-message-row > span {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 9px;
}

.online-dialog:has(.social-shell) .social-unread-label {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #b32028;
  color: #fff;
  font: normal 13px/1 Arial, sans-serif;
  font-style: normal;
  white-space: nowrap;
}
.online-dialog:has(.social-shell) .presence.offline { color: #52685b !important; }

.online-dialog:has(.social-shell) .social-avatar {
  width: 56px !important;
  height: 56px !important;
  border: 2px solid #c69c4d !important;
  background: #174f33 !important;
  box-shadow: 0 3px 8px rgba(19,52,32,.2) !important;
}

.online-dialog:has(.social-shell) .social-card-actions :is(.info-button, .start-game-button),
.online-dialog:has(.social-shell) .social-more {
  min-height: 36px !important;
  border: 1px solid #bc9149 !important;
  border-radius: 9px !important;
  background: #fffaf0 !important;
  color: #16452d !important;
  box-shadow: 0 2px 5px rgba(53,37,20,.09) !important;
  font: 700 12px/1 Arial, sans-serif !important;
}

.online-dialog:has(.social-shell) .social-more {
  min-width: 38px !important;
  padding: 5px 9px !important;
  border-radius: 50% !important;
  background: #174f33 !important;
  color: #f0d07d !important;
}

.online-dialog:has(.social-shell) .account-text-button {
  min-height: 42px !important;
  padding: 9px 12px !important;
  border: 1px solid rgba(199,155,73,.6) !important;
  border-radius: 10px !important;
  background: rgba(7,42,27,.52) !important;
  color: #f1d28a !important;
  font: 700 12px/1.2 Arial, sans-serif !important;
  text-align: left !important;
}

.online-dialog:has(.social-shell) .social-empty {
  margin: 0 !important;
  border: 1px solid rgba(199,155,73,.34) !important;
  border-radius: 12px !important;
  background: rgba(255,250,240,.9) !important;
  color: #4f4135 !important;
}

.online-dialog:has(.social-chat) .social-chat-head { color: #fff6df !important; }
.online-dialog:has(.social-chat) .social-chat-messages p.friend {
  border: 1px solid rgba(185,143,72,.55) !important;
  background: #fffaf0 !important;
  color: #34281f !important;
}
.online-dialog:has(.social-chat) .social-chat-messages p.own {
  border: 1px solid rgba(215,177,93,.48) !important;
  background: #174f33 !important;
  color: #fff9ea !important;
}

@media (max-width: 700px) {
  .online-dialog:has(.social-shell) .social-shell,
  .online-dialog:has(.social-chat) .social-chat { padding: 10px !important; }
  .online-dialog:has(.social-shell) .social-tabs { margin: -10px -10px 3px !important; }
  .online-dialog:has(.social-shell) .social-tabs button { min-height: 46px !important; padding: 7px 4px !important; font-size: 11px !important; }
  .online-dialog:has(.social-shell) .social-avatar { width: 48px !important; height: 48px !important; }
  .online-dialog:has(.social-shell) .social-player-copy strong { font-size: 14px !important; }
  .online-dialog:has(.social-chat) .social-chat-form { grid-template-columns: minmax(0, 1fr) 84px !important; gap: 6px !important; }
  .online-dialog:has(.social-chat) .social-chat-form > button { width: 84px !important; max-width: 84px !important; min-height: 46px !important; padding: 0 4px !important; font-size: 11px !important; }
}

/* Privacy- en notificatie-instellingen */
.online-dialog:has(.social-settings-page) { max-width: 760px !important; }
.online-dialog:has(.social-settings-page) #onlineContent { padding: 14px 18px 18px !important; overflow-y: auto !important; }
.social-settings-page { display: grid; gap: 14px; color: #173e2b; }
.social-settings-intro { padding: 16px 18px; border: 1px solid rgba(190,145,64,.65); border-radius: 14px; background: linear-gradient(135deg,#183d29,#0c261a); color: #fff8e8; }
.social-settings-intro > span { color: #e8c76e; font: 800 11px/1.2 Arial,sans-serif; letter-spacing: .1em; text-transform: uppercase; }
.social-settings-intro h2 { margin: 4px 0 3px; color: #fff3cf; font: 800 23px/1.15 Georgia,serif; }
.social-settings-intro p { margin: 0; color: rgba(255,255,255,.82); font: 13px/1.4 Arial,sans-serif; }
.social-settings-section { overflow: hidden; border: 1px solid rgba(180,135,56,.55); border-radius: 14px; background: #fffaf0; box-shadow: 0 5px 16px rgba(36,47,33,.09); }
.social-settings-heading { display: flex; gap: 11px; align-items: center; padding: 12px 15px; border-bottom: 1px solid rgba(180,135,56,.28); background: #f3ead7; }
.social-settings-heading > span { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 10px; background: #174b31; font-size: 17px; }
.social-settings-heading h3 { margin: 0; color: #17452e; font: 800 16px/1.2 Arial,sans-serif; }
.social-settings-heading p { margin: 2px 0 0; color: #725b3e; font: 12px/1.3 Arial,sans-serif; }
.social-setting-row { display: flex !important; min-height: 60px !important; margin: 0 !important; padding: 9px 15px !important; align-items: center !important; justify-content: space-between; gap: 18px !important; border-bottom: 1px solid rgba(92,91,65,.13); cursor: pointer; }
.social-setting-row:last-child { border-bottom: 0; }
.social-setting-copy { display: grid; gap: 2px; }
.social-setting-copy strong { color: #203f2f; font: 700 14px/1.25 Arial,sans-serif; }
.social-setting-copy small { color: #745f48; font: 12px/1.3 Arial,sans-serif; }
.social-switch { position: relative; flex: 0 0 48px; width: 48px; height: 27px; }
.social-switch input { position: absolute !important; width: 1px !important; height: 1px !important; opacity: 0; }
.social-switch i { position: absolute; inset: 0; border-radius: 999px; background: #a9ada9; box-shadow: inset 0 0 0 1px rgba(0,0,0,.14); transition: .18s ease; }
.social-switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 21px; height: 21px; border-radius: 50%; background: #fff; box-shadow: 0 2px 5px rgba(0,0,0,.28); transition: .18s ease; }
.social-switch input:checked + i { background: #167444; }
.social-switch input:checked + i::after { transform: translateX(21px); }
.social-switch input:focus-visible + i { outline: 3px solid rgba(45,122,205,.45); outline-offset: 2px; }
.social-settings-actions { display: flex; justify-content: flex-end; gap: 10px; }
.social-settings-actions button { min-height: 42px !important; width: auto !important; margin: 0 !important; padding: 0 18px !important; border-radius: 10px !important; font: 800 13px/1 Arial,sans-serif !important; }
.social-settings-save { border: 1px solid #b88b35; background: linear-gradient(#1e7144,#115333); color: #fff5d7; box-shadow: 0 3px 8px rgba(12,57,33,.22); }
.social-settings-save:disabled { opacity: .72; }
.social-settings-status { min-height: 17px; margin: -7px 2px 0; color: #24613e; font: 700 12px/1.3 Arial,sans-serif; text-align: right; }

@media (max-width: 600px) {
  .online-dialog:has(.social-settings-page) #onlineContent { padding: 10px !important; }
  .social-settings-page { gap: 10px; }
  .social-settings-intro { padding: 13px 14px; }
  .social-settings-intro h2 { font-size: 19px; }
  .social-setting-row { min-height: 58px !important; padding: 8px 12px !important; gap: 10px !important; }
  .social-setting-copy small { font-size: 11px; }
  .social-settings-actions { display: grid; grid-template-columns: 1fr 1.5fr; }
  .social-settings-actions button { width: 100% !important; padding: 0 10px !important; }
}
