/* Team Hub owns its shell; shared tactic preview styles live in database.css. */
#team-hub-view { height: 100%; overflow-y: auto; background: #080b0a; padding: 0; }
.team-hub { width: min(100%, 1440px); margin: 0 auto; padding: 28px 28px 48px; box-sizing: border-box; color: #e8edea; font: 15px/1.5 Inter, sans-serif; }
.team-hub *, .hub-dialog * { box-sizing: border-box; }
.team-hub button, .hub-dialog button, .team-hub input, .hub-dialog input, .team-hub select, .hub-dialog select, .team-hub textarea, .hub-dialog textarea { font: inherit; }
.team-hub button, .hub-dialog button, .team-hub .hub-primary { min-height: 44px; border: 1px solid #2c3831; border-radius: 9px; background: #141b17; color: #dce6df; padding: 9px 15px; cursor: pointer; font-weight: 650; transition: background .15s, border-color .15s; }
.team-hub button:hover, .hub-dialog button:hover { background: #202c24; border-color: #47614f; }
.team-hub button:disabled, .hub-dialog button:disabled { opacity: .48; cursor: default; }
.team-hub button:focus-visible, .hub-dialog button:focus-visible, .team-hub a:focus-visible, .team-hub select:focus-visible, .hub-dialog select:focus-visible, .team-hub input:focus-visible, .hub-dialog input:focus-visible, .team-hub textarea:focus-visible, .hub-dialog textarea:focus-visible { outline: 2px solid #22c55e; outline-offset: 3px; }
.team-hub .hub-primary, .hub-dialog .hub-primary { background: #22c55e; border-color: #22c55e; color: #031109; text-decoration: none; font-weight: 750; display: inline-flex; align-items: center; justify-content: center; gap: 10px; }
.team-hub .hub-primary:hover, .hub-dialog .hub-primary:hover { background: #3bdd77; border-color: #3bdd77; }
.team-hub h1, .team-hub h2, .team-hub h3, .hub-dialog h2, .hub-dialog h3 { margin: 0; line-height: 1.25; }
.team-hub h1 { font: 750 clamp(24px, 3vw, 32px)/1.15 Inter, sans-serif; letter-spacing: -.8px; overflow-wrap: anywhere; }
.team-hub h2, .hub-dialog h2 { font-size: 19px; font-weight: 700; letter-spacing: -.4px; }
.team-hub h3, .hub-dialog h3 { font-size: 15px; font-weight: 650; }
.team-hub .hub-muted, .hub-dialog .hub-muted { color: #8da195; font-size: 13px; font-weight: 400; }
.hub-team-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-bottom: 22px; }
.hub-team-identity { display: flex; align-items: center; gap: 15px; min-width: 0; }
.hub-tag { color: #38d673; background: #11241a; border: 1px solid #235237; border-radius: 11px; padding: 13px 12px; font-size: 15px; letter-spacing: 1px; font-weight: 800; flex: 0 0 auto; }
.hub-eyebrow { display: block; color: #82968a; font-size: 11px; font-weight: 650; text-transform: uppercase; letter-spacing: 1.8px; margin-bottom: 6px; }
.hub-heading-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.hub-live-dot { display: inline-block; width: 7px; height: 7px; background: #031109; border-radius: 50%; box-shadow: 0 0 0 4px #03110914; }
.hub-team-switcher { border-top: 1px solid #243028; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0 20px; }
.team-hub .hub-team-switcher > select { flex: 0 1 260px; width: 260px; min-width: 180px; max-width: 55%; }
.hub-team-switcher > div { display: flex; gap: 6px; flex-shrink: 0; }
.hub-team-switcher button { background: transparent; border-color: transparent; color: #93a89a; padding-inline: 10px; white-space: nowrap; }
.hub-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; }
.hub-panel { min-width: 0; border: 1px solid #26322a; border-radius: 14px; background: #0e1410; padding: 20px; }
.hub-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.hub-section-heading h2 { display: flex; align-items: center; gap: 9px; }
.hub-section-heading h2 > span { font-size: 12px; color: #8daa98; padding: 3px 7px; border: 1px solid #2b3a30; border-radius: 6px; font-weight: 600; }
.hub-filters { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.team-hub input, .hub-dialog input, .team-hub select, .hub-dialog select, .team-hub textarea, .hub-dialog textarea { display: block; min-height: 44px; max-width: 100%; width: 100%; border: 1px solid #2a3a2f; border-radius: 8px; background: #080e0a; color: #e6eee9; padding: 9px 12px; }
.team-hub input::placeholder, .hub-dialog input::placeholder, .team-hub textarea::placeholder, .hub-dialog textarea::placeholder { color: #718779; }
.team-hub select, .hub-dialog select { cursor: pointer; padding-right: 24px; }
.hub-filter-options { display: grid; grid-template-columns: 1.1fr .9fr 1fr 1fr; gap: 8px; }
.hub-filter-options select { font-size: 13px; padding-left: 10px; }
.hub-tactic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 14px; }
.hub-tactic { min-width: 0; overflow: hidden; border: 1px solid #2a382f; border-radius: 11px; background: #131b16; transition: border-color .15s; }
.hub-tactic:hover { border-color: #39794f; }
.team-hub .hub-tactic-preview, .hub-dialog .hub-tactic-preview { display: block; width: 100%; padding: 0; border: 0; background: transparent; text-align: left; border-radius: 0; }
.team-hub .hub-tactic-preview:hover, .hub-dialog .hub-tactic-preview:hover { background: #18261d; }
.hub-side { position: absolute; top: 10px; left: 10px; z-index: 1; border-radius: 6px; padding: 3px 8px; font-size: 11px; font-weight: 750; border: 1px solid; }
.hub-side-t { color: #e8c771; border-color: #766237; background: #272319; }
.hub-side-ct { color: #a2c6e8; border-color: #476b8c; background: #18252f; }
.hub-added { position: absolute; top: 10px; right: 8px; z-index: 1; color: #62dd92; background: #13271b; border: 1px solid #33583f; border-radius: 5px; font-size: 11px; padding: 3px 6px; }
.hub-tactic-copy { padding: 14px 14px 9px; }
.hub-tactic-copy h3 { min-height: 38px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.hub-tactic-copy p { margin: 5px 0 0; color: #91a598; font-size: 12px; display: flex; gap: 7px; flex-wrap: wrap; }
.hub-tactic-footer { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 3px 8px 8px 14px; }
.hub-tactic-footer > span { color: #718c7b; font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.team-hub .hub-tactic-footer button, .hub-dialog .hub-tactic-footer button { flex: 0 0 auto; padding-inline: 9px; font-size: 12px; color: #52d782; border: 0; background: transparent; }
.hub-roster { padding: 18px 16px; }
.hub-roster .hub-section-heading select { width: 128px; font-size: 13px; }
.hub-roster-list { display: flex; flex-direction: column; gap: 12px; }
.hub-member { border-top: 1px solid #233029; padding-top: 14px; }
.hub-member-identity { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; }
.hub-member-identity img { width: 40px; height: 40px; object-fit: cover; border: 1px solid #364d3e; border-radius: 11px; }
.hub-member-identity > div { min-width: 0; }
.hub-member-identity h3 { font-size: 14px; overflow-wrap: anywhere; }
.hub-member-identity h3 small { color: #799586; font-weight: 400; font-size: 11px; margin-left: 8px; }
.hub-captain { color: #5aca82; font-size: 10px; display: block; margin-top: 4px; }
.hub-member-roles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.hub-role { min-width: 0; display: block; }
.hub-role > span { display: flex; align-items: center; justify-content: space-between; gap: 3px; color: #99ae9f; font-size: 10px; font-weight: 700; margin-bottom: 5px; }
.hub-role .hub-role-conflict { color: #f3b57c; font-size: 9px; }
.team-hub .hub-role select { border-left: 3px solid var(--role-color); padding: 8px 5px; font-size: 11px; text-overflow: ellipsis; }
.team-hub .hub-role select:disabled { opacity: 1; color: #a1b0a7; cursor: default; }
.hub-role-value { min-height: 44px; border: 1px solid #2a3a2f; border-left: 3px solid var(--role-color); background: #080e0a; border-radius: 8px; padding: 8px; font-size: 12px; overflow-wrap: anywhere; }
.hub-mobile-tabs, .hub-mobile-settings { display: none; }
.hub-empty { max-width: 560px; padding: 36px 22px; margin: 60px auto; text-align: center; border: 1px solid #2a382f; border-radius: 16px; background: #0f1611; }
.hub-empty p { color: #8ca494; margin: 16px auto 24px; }
.hub-welcome { margin-top: min(16dvh, 140px); padding: 48px 22px; }
.hub-welcome img { width: 54px; height: 54px; display: block; margin: 0 auto 24px; }
.hub-welcome h1 { font-size: 30px; }
.hub-welcome-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.hub-library-empty { text-align: center; padding: 44px 18px; color: #8fa494; }
.hub-library-empty > span { display: block; font-size: 44px; color: #2d9b50; margin-bottom: 12px; }
.hub-library-empty h3 { color: #c7d5cc; font-size: 17px; }
.hub-library-empty p { font-size: 14px; margin: 10px 0 20px; }
.hub-library-empty a { display: block; margin-top: 16px; color: #5ed08a; text-decoration: none; }
.hub-alert { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: #261813; border: 1px solid #73472d; border-radius: 9px; padding: 8px 10px 8px 14px; margin-bottom: 20px; color: #efbb98; }
.team-hub .hub-icon-button, .hub-dialog .hub-icon-button { width: 44px; padding: 0; min-width: 44px; font-size: 25px; background: transparent; border-color: transparent; }
.hub-dialog .hub-dialog-heading { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 16px 20px 10px; font-size: 22px; font-weight: 700; }
.hub-dialog .MuiDialogContent-root { padding: 12px 20px 22px; }
.hub-form { display: flex; flex-direction: column; gap: 18px; }
.hub-form label { font-size: 14px; font-weight: 600; color: #cbdad0; }
.hub-form label input, .hub-form label textarea, .hub-form label .hub-copy-row { margin-top: 7px; }
.hub-form textarea { min-height: 112px; padding: 12px 14px; line-height: 1.55; font-weight: 400; resize: vertical; transition: border-color .15s, background .15s; }
.hub-form textarea:hover { border-color: #47614f; }
.hub-form textarea:focus { border-color: #22c55e; background: #0c140f; }
.hub-copy-row { display: flex; gap: 8px; }
.hub-copy-row input { min-width: 0; margin: 0 !important; }
.hub-copy-row button { flex: 0 0 auto; }
.hub-confirm-text { line-height: 1.65; color: #b6c7bc; margin: 0 0 24px; }
.hub-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; }
.team-hub .hub-danger-text, .hub-dialog .hub-danger-text { color: #ff9b90; border-color: #65362e; background: #241713; }
.hub-settings-section { margin-top: 24px; padding-top: 22px; border-top: 1px solid #29392f; }
.hub-settings-section h3 { margin-bottom: 14px; }
.hub-settings .hub-section-heading { margin-bottom: 20px; }
.hub-settings-summary p { color: #9db0a3; }
.hub-transfer { display: flex; gap: 8px; }
.hub-transfer select { flex: 1; min-width: 0; }
.hub-settings-member { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; }
.hub-settings-member > span { overflow-wrap: anywhere; }
.hub-picker-tabs { display: flex; gap: 8px; margin-bottom: 18px; }
.hub-picker-tabs .active, .hub-mobile-tabs .active { border-color: #359d56; background: #152b1d; color: #5ce18a; }
.hub-join-summary { padding: 22px; background: #14241a; border: 1px solid #285b38; border-radius: 10px; text-align: center; }
.hub-join-summary .hub-tag { display: inline-block; margin-bottom: 15px; }
.hub-join-summary p { margin: 8px 0 0; color: #8dad97; font-size: 13px; }
.hub-error-message { color: #ffb6a3; }
.hub-loading { min-height: 380px; }
.hub-skeleton { min-height: 220px; border-radius: 13px; background: linear-gradient(100deg, #101b14 25%, #19271e 50%, #101b14 75%); background-size: 200% 100%; animation: hub-shimmer 1.5s linear infinite; }
.hub-skeleton-header { min-height: 78px; margin-bottom: 28px; }
.hub-skeleton-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@keyframes hub-shimmer { to { background-position: -200% 0; } }
.team-preview-overlay { background: #030706b8; backdrop-filter: blur(5px); z-index: 1290; }
.team-preview-overlay .strategy-preview { box-shadow: 0 20px 90px #0009; }
.team-preview-overlay .preview-action-btn:disabled { opacity: .55; cursor: default; }
.team-preview-overlay .role-list-modal { margin-top: 12px; }
@media (max-width: 1100px) and (min-width: 769px) {
  .team-hub { padding: 24px 20px; }
  .hub-workspace { grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; }
  .hub-heading-actions { gap: 5px; }
  .hub-heading-actions button { padding-inline: 10px; }
  .hub-tactic-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
  .hub-panel { padding: 16px; }
}
@media (max-width: 900px) and (min-width: 769px) {
  .hub-team-heading { flex-wrap: wrap; }
  .hub-workspace { grid-template-columns: 1fr; }
  .hub-roster-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
}
@media (max-width: 768px) {
  .team-hub { padding: 20px 14px 32px; font-size: 16px; }
  .hub-team-heading { display: block; padding-bottom: 16px; }
  .hub-team-identity { gap: 12px; margin-bottom: 18px; }
  .hub-team-identity h1 { font-size: 26px; }
  .hub-tag { padding: 12px 10px; font-size: 13px; }
  .hub-heading-actions { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; }
  .hub-heading-actions .hub-settings-button { display: none; }
  .hub-heading-actions button { padding: 10px 9px; font-size: 13px; }
  .hub-heading-actions .hub-primary { gap: 6px; }
  .hub-team-switcher { padding-bottom: 12px; gap: 4px; }
  .team-hub .hub-team-switcher > select { flex: 1; min-width: 0; max-width: none; width: auto; font-size: 14px; }
  .hub-team-switcher > div { gap: 0; }
  .hub-team-switcher button { padding-inline: 8px; font-size: 13px; }
  .hub-mobile-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin-bottom: 16px; }
  .hub-mobile-tabs button { font-size: 14px; padding: 10px 5px; }
  .hub-workspace { display: block; }
  .hub-playbook, .hub-roster-column, .hub-mobile-settings { display: none; }
  .hub-workspace .hub-mobile-active { display: block; }
  .hub-panel { padding: 16px 12px; border-radius: 12px; }
  .hub-section-heading { gap: 8px; }
  .hub-section-heading h2 { font-size: 19px; }
  .hub-section-heading .hub-primary { padding: 9px 10px; font-size: 13px; }
  .hub-filter-options { grid-template-columns: 1fr 1fr; }
  .hub-filter-options select { font-size: 14px; }
  .hub-tactic-grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .hub-tactic-copy h3 { font-size: 17px; min-height: auto; }
  .hub-tactic-copy p, .hub-tactic-footer > span { font-size: 13px; }
  .team-hub .hub-tactic-footer button, .hub-dialog .hub-tactic-footer button { font-size: 14px; }
  .hub-roster { padding: 16px 12px; }
  .hub-member { padding-top: 16px; }
  .hub-member-identity { gap: 12px; margin-bottom: 14px; }
  .hub-member-identity img { width: 46px; height: 46px; }
  .hub-member-identity h3 { font-size: 17px; }
  .hub-captain { font-size: 12px; }
  .hub-role > span { font-size: 12px; }
  .team-hub .hub-role select { font-size: 13px; padding-left: 7px; }
  .hub-role-value { font-size: 13px; }
  .hub-role .hub-role-conflict { font-size: 10px; }
  .hub-form label { font-size: 16px; }
  .hub-empty { margin-top: 50px; }
  .hub-empty h1 { font-size: 26px; }
  .hub-skeleton-grid { grid-template-columns: 1fr; }
  .hub-dialog .MuiDialogContent-root { padding: 10px 16px 20px; }
  .hub-dialog .hub-dialog-heading { padding-inline: 16px; font-size: 21px; }
  .hub-dialog input, .hub-dialog select, .team-hub textarea, .hub-dialog textarea { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) { .hub-skeleton { animation: none; } }
