/* ============================================
   DRAFT COMPANION & PLAYER NOTES — SaaS Styles
   LevelUpFantasy · Premium Notion-Style Layout
   ============================================ */

/* --- Tool-Specific Tokens --- */
:root {
  --sidebar-w-left: 320px;
  
  /* Tag Colors (Light Mode Harmonic) */
  --clr-target-bg: #FEF9C3;
  --clr-target-border: #FACC15;
  --clr-target-text: #713F12;
  --clr-target-glow: rgba(250, 204, 21, 0.25);

  --clr-sleeper-bg: #F3E8FF;
  --clr-sleeper-border: #C084FC;
  --clr-sleeper-text: #581C87;
  --clr-sleeper-glow: rgba(192, 132, 252, 0.25);

  --clr-avoid-bg: #FEE2E2;
  --clr-avoid-border: #F87171;
  --clr-avoid-text: #991B1B;
  --clr-avoid-glow: rgba(248, 113, 113, 0.2);

  --clr-watchlist-bg: #E0F2FE;
  --clr-watchlist-border: #38BDF8;
  --clr-watchlist-text: #0369A1;
  --clr-watchlist-glow: rgba(56, 189, 248, 0.2);
  
  /* Draft Status Indicators */
  --clr-status-me-bg: #DCFCE7;
  --clr-status-me-border: #22C55E;
  --clr-status-others-bg: #F3F4F6;
  --clr-status-others-border: #9CA3AF;
  
  --font-mono: 'Courier New', Courier, monospace;
}

/* --- Layout Wrapper (2-Column Focus Split-Pane) --- */
.tool-main-dashboard {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 24px;
  width: 100%;
  max-width: 1560px;
  margin: 0 auto;
  padding: 24px 20px 40px;
  align-items: start;
}

/* Spacers & Standard Header */
.tool-header {
  padding: 130px 0 20px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
}
.tool-header h1 {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
}

/* --- Left Sidebar Panel: Player Pool --- */
.dashboard-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: calc(100vh - 180px);
  position: sticky;
  top: 90px;
}

.pool-sidebar-panel {
  grid-column: 1;
}

/* Permanent Right Workspace Panel styling */
.workspace-main-panel {
  grid-column: 2;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  height: calc(100vh - 180px);
  position: sticky;
  top: 90px;
  transition: all var(--transition);
}

/* --- Header Search Pool --- */
.panel-header-search {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-secondary);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.pool-search-box {
  position: relative;
  width: 100%;
}
.pool-search-box svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  pointer-events: none;
}
.pool-search-input {
  width: 100%;
  padding: 10px 12px 10px 38px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.9rem;
  background: var(--bg-primary);
  color: var(--text-primary);
  outline: none;
  transition: all var(--transition);
}
.pool-search-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-dim);
}

.filter-pills-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: none;
}
.filter-pills-row::-webkit-scrollbar {
  display: none;
}
.pill-btn {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.75rem;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition);
}
.pill-btn:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}
.pill-btn.active {
  background: var(--text-primary);
  color: #FFFFFF;
  border-color: var(--text-primary);
}
.pill-btn--qb.active { background: #E11D48; border-color: #E11D48; }
.pill-btn--rb.active { background: #16A34A; border-color: #16A34A; }
.pill-btn--wr.active { background: #2563EB; border-color: #2563EB; }
.pill-btn--te.active { background: #D97706; border-color: #D97706; }

.status-select-wrap {
  display: grid;
  grid-template-columns: 1fr;
}
.status-select {
  padding: 8px 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--text-secondary);
  outline: none;
  background: var(--bg-primary);
  cursor: pointer;
}

.pool-scroll-container {
  flex: 1;
  overflow-y: auto;
  padding: 8px 12px;
}
.pool-scroll-container::-webkit-scrollbar {
  width: 6px;
}
.pool-scroll-container::-webkit-scrollbar-thumb {
  background: var(--border-dark);
  border-radius: var(--radius-full);
}

.pool-count-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin: 4px 8px 8px;
  font-weight: 500;
}

/* --- Player Card Styling --- */
.player-list-card {
  display: flex;
  align-items: center;
  padding: 10px 12px;
  margin-bottom: 8px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  cursor: pointer;
  background: var(--bg-primary);
  transition: all var(--transition);
  position: relative;
  user-select: none;
}
.player-list-card:hover {
  border-color: var(--border-dark);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}
.player-list-card.active {
  border-color: var(--accent);
  background: var(--accent-dim);
  box-shadow: 0 0 0 1px var(--accent);
}

.player-card-headshot {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--bg-tertiary);
  margin-right: 12px;
  object-fit: cover;
  border: 1px solid var(--border-color);
  flex-shrink: 0;
}

.player-card-details {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.player-card-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.player-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-tertiary);
}
.player-card-pos {
  font-weight: 800;
  font-family: var(--font-heading);
  font-size: 0.7rem;
}
.pos-qb { color: #E11D48; }
.pos-rb { color: #16A34A; }
.pos-wr { color: #2563EB; }
.pos-te { color: #D97706; }
.pos-k  { color: #0891B2; }
.pos-def{ color: #4F46E5; }

.card-badge-container {
  display: flex;
  gap: 4px;
  align-items: center;
  margin-left: 8px;
  flex-shrink: 0;
}
.card-indicator-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.dot-target { background-color: var(--clr-target-border); box-shadow: 0 0 4px var(--clr-target-border); }
.dot-sleeper { background-color: var(--clr-sleeper-border); box-shadow: 0 0 4px var(--clr-sleeper-border); }
.dot-avoid { background-color: var(--clr-avoid-border); box-shadow: 0 0 4px var(--clr-avoid-border); }
.dot-watchlist { background-color: var(--clr-watchlist-border); box-shadow: 0 0 4px var(--clr-watchlist-border); }

.card-note-icon {
  color: var(--text-tertiary);
  margin-left: 6px;
  opacity: 0.6;
}

/* Card Draft States */
.player-list-card.drafted-others {
  opacity: 0.45;
  background: var(--bg-secondary);
  border-style: dashed;
}
.player-list-card.drafted-others .player-card-name {
  text-decoration: line-through;
  color: var(--text-tertiary);
}
.player-list-card.drafted-others::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 48%, rgba(156, 163, 175, 0.1) 48%, rgba(156, 163, 175, 0.1) 52%, transparent 52%);
  background-size: 16px 16px;
  pointer-events: none;
}

.player-list-card.drafted-me {
  border-color: var(--clr-status-me-border);
  background: var(--clr-status-me-bg);
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.15);
}
.player-list-card.drafted-me::before {
  content: '✓ DRAFTED';
  position: absolute;
  right: 10px;
  top: 6px;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.6rem;
  color: var(--clr-status-me-border);
  letter-spacing: 0.05em;
}

/* --- Consolidated Collapsible control center Accordion --- */
.control-accordion-card {
  background: var(--bg-card);
  border-top: 1px solid var(--border-color);
  border-left: none;
  border-right: none;
  border-bottom: none;
  border-radius: 0;
  box-shadow: none;
  overflow: hidden;
  transition: box-shadow var(--transition);
  flex-shrink: 0;
}
.control-accordion-card:hover {
  box-shadow: var(--shadow-md);
}

.accordion-header-bar {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
  background: var(--bg-secondary);
  transition: background var(--transition);
}
.accordion-header-bar:hover {
  background: var(--border-color);
}
.accordion-header-bar h3 {
  font-size: 1rem;
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Floating Status Indicators inside Header */
.header-status-summary {
  display: flex;
  gap: 8px;
  margin-left: 24px;
  flex-wrap: wrap;
}
.status-pill-indicator {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  color: var(--text-secondary);
  white-space: nowrap;
}
.status-pill-indicator.active {
  background: var(--clr-status-me-bg);
  border-color: var(--clr-status-me-border);
  color: #15803D;
}
.status-pill-indicator.synced {
  background: #E0F2FE;
  border-color: #38BDF8;
  color: #0369A1;
}

.accordion-chevron-icon {
  margin-left: auto;
  color: var(--text-secondary);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: block;
}
.control-accordion-card.expanded .accordion-chevron-icon {
  transform: rotate(180deg);
}

/* Expandable Body Panel */
.accordion-expandable-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
.control-accordion-card.expanded .accordion-expandable-body {
  max-height: 500px; /* Large enough to fit inner forms */
}

.accordion-body-content {
  padding: 16px;
  border-top: 1px solid var(--border-color);
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  background: var(--bg-card);
}

/* Inner Accordion Cards */
.sync-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}
.sync-section h4 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--text-primary);
}
.sync-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.sync-input {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.85rem;
  outline: none;
  background: var(--bg-secondary);
}
.sync-input:focus {
  border-color: var(--accent);
  background: var(--bg-primary);
}
.sync-btn {
  background: var(--text-primary);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition);
}
.sync-btn:hover {
  background: var(--accent);
}
.sync-btn.active-polling {
  background: #E11D48;
  animation: pulse-sync-btn 2s infinite;
}
@keyframes pulse-sync-btn {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

.sync-status-label {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  gap: 6px;
}
.polling-indicator {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22C55E;
  display: inline-block;
  animation: pulse-dot 1.5s infinite;
}

/* Supabase Auth card inside Accordion */
.auth-sync-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.auth-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-color);
}
.auth-title-container {
  display: flex;
  align-items: center;
  gap: 6px;
}
.auth-title-container h4 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.95rem;
}
.cloud-status-icon {
  font-size: 1.1rem;
}
.cloud-status-icon.online {
  filter: drop-shadow(0 0 3px #22C55E);
}
.cloud-status-icon.offline {
  filter: grayscale(1) opacity(0.5);
}
.auth-status-badge {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.65rem;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}
.auth-status-badge.online {
  background: #DCFCE7;
  color: #15803D;
  border-color: #BBF7D0;
}

.auth-content-block {
  display: flex;
  flex-direction: column;
}
.auth-action-row {
  display: flex;
  gap: 8px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.form-group label {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.7rem;
  color: var(--text-secondary);
}
.form-group input {
  padding: 8px 10px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.8rem;
  outline: none;
  background: var(--bg-secondary);
}
.form-group input:focus {
  border-color: var(--accent);
  background: var(--bg-primary);
}
.auth-error-label {
  font-size: 0.7rem;
  font-weight: 600;
  color: #DC2626;
  margin-bottom: 10px;
}
.auth-form-actions {
  display: flex;
  gap: 8px;
}
.logged-in-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Utilities segment inside Accordion */
.utility-actions-section {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}
.actions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.panel-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.8rem;
  border: 1px solid var(--border-dark);
  background: var(--bg-primary);
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition);
}
.panel-btn:hover {
  background: var(--bg-secondary);
  border-color: var(--text-primary);
}
.panel-btn--accent {
  background: var(--accent-dim);
  color: var(--accent);
  border-color: rgba(37, 99, 235, 0.2);
}
.panel-btn--accent:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.panel-btn--danger {
  color: #DC2626;
  border-color: rgba(220, 38, 38, 0.15);
}
.panel-btn--danger:hover {
  background: #FEE2E2;
  border-color: #DC2626;
}

/* --- Roster Slots Board --- */
.roster-board-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}
.roster-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.roster-header h3 {
  font-size: 1.25rem;
}
.roster-metrics {
  display: flex;
  gap: 16px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-weight: 700;
}
.metric-pill {
  background: var(--bg-tertiary);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}
.metric-pill strong {
  color: var(--text-primary);
}

.roster-slots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 12px;
}
.roster-slot {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  border: 1px dashed var(--border-dark);
  border-radius: var(--radius-sm);
  background: var(--bg-secondary);
  height: 52px;
  transition: all var(--transition);
}
.roster-slot.filled {
  border-style: solid;
  border-color: var(--clr-status-me-border);
  background: var(--bg-primary);
  box-shadow: var(--shadow-sm);
}

.slot-label {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.75rem;
  color: var(--text-tertiary);
  width: 44px;
  flex-shrink: 0;
  border-right: 1px solid var(--border-color);
  margin-right: 10px;
  padding-right: 6px;
}
.slot-filled-content {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
}
.slot-headshot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  margin-right: 8px;
  border: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  flex-shrink: 0;
}
.slot-player-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.slot-player-team {
  font-size: 0.7rem;
  color: var(--text-tertiary);
}
.slot-remove-btn {
  background: none;
  border: none;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: 4px;
  margin-left: auto;
  opacity: 0;
  transition: opacity var(--transition), color var(--transition);
}
.roster-slot.filled:hover .slot-remove-btn {
  opacity: 1;
}
.slot-remove-btn:hover {
  color: #DC2626;
}

.slot-empty-text {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  font-style: italic;
}

/* --- PLAYERS SCOUTING DATABASE DASHBOARD WELCOME STATE --- */
.editor-welcome-state {
  display: flex;
  flex-direction: column;
  padding: 32px;
  overflow-y: auto;
  height: 100%;
}
.welcome-header {
  margin-bottom: 24px;
}
.welcome-badge {
  display: inline-block;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  color: var(--accent);
  background: var(--accent-dim);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  border: 1px solid rgba(37, 99, 235, 0.15);
}
.welcome-header h2 {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-weight: 800;
}
.welcome-header p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

/* VISUAL 3-STEP SCOUTING WIZARD */
.onboarding-steps-flow {
  display: flex;
  gap: 16px;
  margin: 20px 0 28px;
  width: 100%;
}
.onboarding-step-card {
  flex: 1;
  display: flex;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
  transition: all var(--transition);
  align-items: flex-start;
}
.onboarding-step-card:hover {
  border-color: var(--border-dark);
  transform: translateY(-1.5px);
  box-shadow: var(--shadow-sm);
}
.step-num {
  background: var(--accent);
  color: #fff;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.75rem;
  flex-shrink: 0;
  box-shadow: 0 2px 6px var(--accent-dim);
}
.step-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.step-content h4 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.8rem;
  color: var(--text-primary);
  margin: 0;
}
.step-content p {
  font-size: 0.72rem;
  color: var(--text-secondary);
  line-height: 1.35;
  margin: 0;
}

@media (max-width: 768px) {
  .onboarding-steps-flow {
    flex-direction: column;
    gap: 12px;
  }
}

/* Dashboard Metrics counters */
.dashboard-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}
.metric-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 20px 12px;
  text-align: center;
  transition: all var(--transition);
}
.metric-card:hover {
  border-color: var(--border-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}
.metric-val {
  display: block;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 2.2rem;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 8px;
}
#cnt-notes.metric-val { color: var(--accent); }
#cnt-targets.metric-val { color: var(--clr-target-text); }
#cnt-sleepers.metric-val { color: var(--clr-sleeper-text); }
#cnt-avoids.metric-val { color: var(--clr-avoid-text); }

.metric-label {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.7rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Utilities card */
.welcome-actions-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}
.welcome-actions-card h3 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text-primary);
  margin: 0 0 6px 0;
}
.welcome-actions-card p {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin: 0 0 16px 0;
  line-height: 1.4;
}

/* Onboarding Action Buttons Refinement */
.actions-buttons-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.primary-action-btn {
  background: var(--accent-dim);
  color: var(--accent);
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.04);
}
.primary-action-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
  transform: translateY(-1px);
}
.secondary-utilities-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.text-link-btn {
  background: var(--bg-secondary) !important;
  border: 1px solid var(--border-color) !important;
  color: var(--text-secondary) !important;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.75rem !important;
  padding: 6px 12px !important;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  transition: all var(--transition);
}
.text-link-btn:hover {
  background: var(--border-color) !important;
  border-color: var(--border-dark) !important;
  color: var(--text-primary) !important;
}
.danger-link-btn {
  color: #DC2626 !important;
  border-color: rgba(220, 38, 38, 0.15) !important;
}
.danger-link-btn:hover {
  background: #FEE2E2 !important;
  border-color: #DC2626 !important;
  color: #DC2626 !important;
}

/* Scouting tips card */
.notebook-tips-card {
  border-left: 3px solid var(--accent);
  background: var(--bg-secondary);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 16px 20px;
}
.notebook-tips-card h4 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--text-primary);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.notebook-tips-card ul {
  padding-left: 16px;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0;
}
.notebook-tips-card li {
  margin-bottom: 6px;
}

/* Active Player Notebook state layout */
.workspace-toolbar {
  padding: 12px 20px;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
}
.back-dashboard-btn {
  background: none;
  border: none;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--text-secondary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
}
.back-dashboard-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-dim);
}

/* Drawer Panel Inner layouts */
.editor-active-state {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.editor-player-banner {
  padding: 24px 20px;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
}
.editor-headshot {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: var(--bg-tertiary);
  object-fit: cover;
}
.editor-title-meta h2 {
  font-size: 1.3rem;
  margin-bottom: 2px;
  color: var(--text-primary);
}
.editor-title-meta .meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* Close Drawer X Button */
.drawer-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}
.drawer-close-btn:hover {
  background: var(--text-primary);
  color: #fff;
  border-color: var(--text-primary);
  transform: scale(1.08);
}

/* Note controls inside drawer */
.editor-section {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
}
.editor-section-title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.75rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.tag-pills-selector {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.tag-pill-btn {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 6px 4px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.7rem;
  cursor: pointer;
  text-align: center;
  transition: all var(--transition);
}
.tag-pill-btn:hover {
  background: var(--bg-secondary);
}
.tag-pill-btn.active.btn-tag-target {
  background: var(--clr-target-bg);
  border-color: var(--clr-target-border);
  color: var(--clr-target-text);
  box-shadow: 0 0 6px var(--clr-target-glow);
}
.tag-pill-btn.active.btn-tag-sleeper {
  background: var(--clr-sleeper-bg);
  border-color: var(--clr-sleeper-border);
  color: var(--clr-sleeper-text);
  box-shadow: 0 0 6px var(--clr-sleeper-glow);
}
.tag-pill-btn.active.btn-tag-avoid {
  background: var(--clr-avoid-bg);
  border-color: var(--clr-avoid-border);
  color: var(--clr-avoid-text);
  box-shadow: 0 0 6px var(--clr-avoid-glow);
}
.tag-pill-btn.active.btn-tag-watchlist {
  background: var(--clr-watchlist-bg);
  border-color: var(--clr-watchlist-border);
  color: var(--clr-watchlist-text);
  box-shadow: 0 0 6px var(--clr-watchlist-glow);
}

.draft-state-selector {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.draft-state-btn {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 8px 4px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--text-secondary);
  cursor: pointer;
  text-align: center;
  transition: all var(--transition);
}
.draft-state-btn:hover {
  border-color: var(--border-dark);
  color: var(--text-primary);
}
.draft-state-btn.active.btn-draft-avail {
  border-color: var(--text-primary);
  background: var(--text-primary);
  color: #fff;
}
.draft-state-btn.active.btn-draft-me {
  border-color: var(--clr-status-me-border);
  background: var(--clr-status-me-bg);
  color: var(--clr-status-me-border);
}
.draft-state-btn.active.btn-draft-others {
  border-color: var(--clr-status-others-border);
  background: var(--clr-status-others-bg);
  color: var(--text-secondary);
}

.editor-note-container {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px;
  min-height: 320px;
}
.note-header-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.save-notification {
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-tertiary);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.save-notification.saving {
  opacity: 1;
  color: var(--accent);
}
.save-notification.saved {
  opacity: 1;
  color: #16A34A;
}

.note-templates-row {
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}
.template-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.65rem;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition);
}
.template-btn:hover {
  background: var(--bg-primary);
  border-color: var(--border-dark);
  color: var(--text-primary);
}

.note-textarea {
  flex: 1;
  width: 100%;
  min-height: 200px;
  padding: 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-primary);
  resize: none;
  outline: none;
  background: var(--bg-secondary);
  transition: all var(--transition);
}
.note-textarea:focus {
  border-color: var(--accent);
  background: var(--bg-primary);
  box-shadow: 0 0 0 2px var(--accent-dim);
}

/* --- SEO section FAQ --- */
.tool-seo__faq details {
  margin-bottom: 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background: var(--bg-primary);
}
.tool-seo__faq details[open] {
  border-color: var(--border-dark);
}
.tool-seo__faq summary {
  padding: 16px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
  cursor: pointer;
  user-select: none;
  outline: none;
}
.tool-seo__faq p {
  padding: 0 16px 16px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* --- RESPONSIVE ADJUSTMENTS --- */
@media (max-width: 1024px) {
  .tool-main-dashboard {
    grid-template-columns: 1fr;
    gap: 16px;
    padding-bottom: 88px;
  }
  
  .pool-sidebar-panel {
    display: none;
    height: calc(100vh - 160px);
  }
  .pool-sidebar-panel.mobile-visible {
    display: flex;
  }
  
  .dashboard-center-area {
    display: none;
  }
  .dashboard-center-area.mobile-visible {
    display: flex;
  }
  
  .workspace-main-panel {
    display: none;
    width: 100%;
    border-radius: 0;
    left: 0;
    right: 0;
    height: calc(100vh - 160px);
  }
  .workspace-main-panel.mobile-visible {
    display: flex;
  }
  
  .mobile-dashboard-tabs {
    display: grid;
  }
  
  .accordion-body-content {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .sync-section {
    padding-right: 0;
    border-right: none;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
  }
  .auth-sync-card {
    padding-right: 0;
    border-right: none;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
  }
}

/* Bottom Tab Bar Mobile */
.mobile-dashboard-tabs {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: rgba(255, 255, 255, 0.96);
  border-top: 1px solid var(--border-color);
  backdrop-filter: blur(12px);
  z-index: 1000;
  grid-template-columns: repeat(2, 1fr);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.05);
}
.mobile-tab-btn {
  background: none;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.75rem;
  gap: 4px;
  cursor: pointer;
  transition: color var(--transition);
}
.mobile-tab-btn svg {
  transition: transform var(--transition);
}
.mobile-tab-btn.active {
  color: var(--accent);
}
.mobile-tab-btn.active svg {
  transform: scale(1.1);
}
