/* ===== COMPONENTS - Button variants, utility classes, animations ===== */

/* Temporary warning animations */
@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideOutRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

.temporary-warning {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Section-specific button overrides - consolidated */
/* Most sections use grey buttons by default, only success buttons remain green */
.sandbox-section .btn-success,
.events-section .btn-success {
  background-color: #28a745; /* Keep Push button green */
  color: white;
}

.sandbox-section .btn-success:hover,
.events-section .btn-success:hover {
  background-color: #1e7e34;
}

/* Go to event buttons - blue foreground to indicate they are links */
.go-to-event-btn {
  background-color: #e2e6ea;
  color: #007bff !important; /* Blue text to show they are links */
}

.go-to-event-btn:hover {
  background-color: #d4dadd;
}

/* Add link button - grey */
.add-link-btn {
  background-color: #e2e6ea;
  color: #333;
  padding: 8px 16px;
  border-radius: 6px;
  border: 1px solid #d1d5db;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.add-link-btn:hover {
  background-color: #d4dadd;
  border-color: #9ca3af;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

/* Event actions buttons - match add-link-btn styling */
.event-actions .btn-sm {
  background-color: #e2e6ea;
  color: #333;
  border-radius: 6px;
  border: 1px solid #d1d5db;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.event-actions .btn-sm:hover {
  background-color: #d4dadd;
  border-color: #9ca3af;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

/* Section actions buttons (Playground) - match add-link-btn styling */
.section-actions .btn-sm {
  background-color: #e2e6ea;
  color: #333;
  border-radius: 6px;
  border: 1px solid #d1d5db;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.section-actions .btn-sm:hover {
  background-color: #d4dadd;
  border-color: #9ca3af;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

/* Journey Save button - match add-link-btn styling */
[data-action='save-journey-event'],
[data-testid='btn_journey_save'] {
  background-color: #e2e6ea;
  color: #333;
  border-radius: 6px;
  border: 1px solid #d1d5db;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

[data-action='save-journey-event']:hover,
[data-testid='btn_journey_save']:hover {
  background-color: #d4dadd;
  border-color: #9ca3af;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

/* Small button variant */
.btn-sm {
  font-size: 13px;
  padding: 6px 10px;
}

/* Button states */
.btn-error {
  background-color: #dc3545 !important;
  color: #fff !important;
  cursor: not-allowed;
}

/* Utility classes for common inline styles */
.text-center {
  text-align: center;
}

.mb-15 {
  margin-bottom: 15px;
}

.mb-20 {
  margin-bottom: 20px;
}

.mb-8 {
  margin-bottom: 8px;
}

/* ===== SMOOTH ANIMATIONS & ROUNDED CORNERS ===== */

/* Enhanced smooth animations for event cards */
.preset-wrapper {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.preset-wrapper .preset-content {
  opacity: 1;
  overflow: visible;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 15px;
  transform: translateY(0);
}

.preset-wrapper.collapsed .preset-content {
  max-height: 0;
  opacity: 0;
  padding: 0 15px;
  overflow: hidden;
  transform: translateY(-10px);
  pointer-events: none;
}

/* Collapsible notes sections - aligned with main UI styling */
.notes-section {
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px; /* More rounded corners */
  margin: 15px 0;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.notes-header {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background: #f5f7fa;
  border-bottom: 1px solid #eceff3;
  cursor: pointer;
  -webkit-user-select: none;
  -webkit-user-select: none;
  user-select: none;
  transition: background-color 0.2s ease;
  border-radius: 8px 8px 0 0; /* Rounded top corners */
  pointer-events: none; /* Allow buttons inside to be clickable */
}

.notes-header:hover {
  background: #e2e6ea;
}

.notes-header h4 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #495057;
  flex: 1;
}

.notes-toggle {
  background: none;
  border: none;
  color: #6c757d;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s ease;
  font-size: 14px;
  order: -1;
  margin-right: 10px;
}

.notes-toggle:hover {
  background-color: #e2e6ea;
  color: #495057;
}

.notes-toggle-icon {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.notes-toggle-icon.collapsed {
  transform: rotate(-90deg);
}

.notes-content {
  padding: 16px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 1;
  overflow: hidden;
  background: #fff;
  transform: translateY(0);
  max-height: none;
}

.notes-content.collapsed {
  opacity: 0;
  padding: 0 16px;
  overflow: hidden;
  transform: translateY(-10px);
  max-height: 0;
  pointer-events: none;
}

.notes-text {
  line-height: 1.6;
  color: #495057;
  margin: 0;
}

.notes-text a {
  color: #007bff;
  text-decoration: none;
  font-weight: 500;
}

.notes-text a:hover {
  text-decoration: underline;
  color: #0056b3;
}

.notes-textarea {
  width: 100%;
  min-height: 100px;
  padding: 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.5;
  resize: vertical;
  transition: border-color 0.2s ease;
}

.notes-textarea:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.notes-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #e9ecef;
}

/* Enhanced section headers with more rounded corners */
.section-header {
  border-radius: 8px 8px 0 0; /* More rounded top corners */
}

/* Smooth transitions for all collapsible elements */
.collapsible {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.collapsible .section-content,
.collapsible .notes-content {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  padding: 16px 20px; /* Add padding when expanded for better content spacing */
}

/* Main section collapsed states with smooth animations */
.section-content.collapsed {
  opacity: 0;
  padding: 0;
  overflow: hidden;
  transform: translateY(-10px);
  max-height: 0;
  pointer-events: none;
}

/* ===== EXAMPLE FILE SUB-SECTIONS ===== */

.example-file-subsection {
  margin-bottom: 30px;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.example-file-subsection:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  border-color: #dee2e6;
}

.subsection-header {
  background: #f8f9fa;
  padding: 15px;
  border-bottom: 1px solid #e9ecef;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background-color 0.2s ease;
}

.subsection-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.subsection-toggle-btn {
  background: none;
  border: none;
  font-size: 14px;
  color: #6c757d;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
}

.subsection-toggle-btn:hover {
  background: #e9ecef;
  color: #495057;
}

.subsection-header:hover {
  background: #e9ecef;
}

.subsection-header h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #495057;
}

.subsection-controls {
  display: flex;
  gap: 10px;
  pointer-events: auto; /* Ensure controls are clickable */
}

.subsection-controls .btn-sm {
  font-size: 12px;
  padding: 6px 12px;
  background: #fff;
  border: 1px solid #ced4da;
  color: #495057;
  transition: all 0.2s ease;
  pointer-events: auto; /* Ensure buttons are clickable */
}

.subsection-controls .btn-sm:hover {
  background: #e9ecef;
  border-color: #adb5bd;
  transform: translateY(-1px);
}

.subsection-content {
  padding: 20px;
  transition: all 0.3s ease;
  overflow: hidden;
}

.subsection-content.collapsed {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  opacity: 0;
}

.subsection-events-area {
  margin-top: 20px;
}

/* Notes sub-section within example files */
.example-file-subsection .notes-section {
  margin-bottom: 20px;
}

.example-file-subsection .notes-header {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 8px;
  border-radius: 4px;
  transition: background-color 0.2s ease;
}

.example-file-subsection .notes-header:hover {
  background: #f8f9fa;
}

.example-file-subsection .notes-toggle-icon {
  font-size: 12px;
  color: #6c757d;
  transition: transform 0.2s ease;
}

.example-file-subsection .notes-toggle-icon.collapsed {
  transform: rotate(-90deg);
}

.example-file-subsection .notes-content {
  padding: 15px;
  background: #f8f9fa;
  border-radius: 6px;
  border: 1px solid #e9ecef;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.example-file-subsection .notes-content.collapsed {
  opacity: 0;
  padding: 0 15px;
  overflow: hidden;
  transform: translateY(-10px);
  max-height: 0;
  pointer-events: none;
}

/* Fix for UI blocking issue - ensure buttons are clickable */
.subsection-content button,
.preset-header-actions button {
  position: relative;
  z-index: 10;
}

/* Event navigation within sub-sections */
.event-nav-title {
  font-weight: 500;
  margin-bottom: 10px;
  color: #495057;
  font-size: 14px;
}

.event-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.event-nav .btn-sm {
  font-size: 12px;
  padding: 4px 8px;
  background: #e9ecef;
  border: 1px solid #ced4da;
  color: #495057;
  transition: all 0.2s ease;
}

.event-nav .btn-sm:hover {
  background: #dee2e6;
  border-color: #adb5bd;
  transform: translateY(-1px);
}

/* Responsive adjustments for sub-sections */
@media (max-width: 768px) {
  .subsection-header {
    flex-direction: column;
    gap: 15px;
    align-items: flex-start;
  }

  .subsection-controls {
    width: 100%;
    justify-content: flex-end;
  }

  .subsection-content {
    padding: 15px;
  }

  .event-nav {
    gap: 6px;
  }

  .event-nav .btn-sm {
    font-size: 11px;
    padding: 3px 6px;
  }
}

/* Toggle sections with light frames and headers */
.toggle-section {
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 12px 16px;
  margin: 10px 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.toggle-header {
  font-weight: 600;
  font-size: 14px;
  color: #495057;
  margin-bottom: 10px;
}

.editor-toggles,
.console-toggles {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.console-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
}

.console-toggle input[type='checkbox'] {
  margin: 0;
  cursor: pointer;
}

.console-toggle label {
  font-size: 13px;
  color: #6c757d;
  cursor: pointer;
  line-height: 1.4;
  margin: 0;
}

/* ===== INTERACTIVE HEADER STYLES ===== */
/* Clickable headers with pointer cursor */
.clickable-header {
  cursor: pointer;
  pointer-events: auto !important; /* PRO-031: Override pointer-events: none from .notes-header */
}

/* Make all children inside clickable headers receive pointer events */
.clickable-header * {
  pointer-events: auto;
}

/* ===== LOCAL FILE CONTROLS STYLES ===== */
/* File controls container styling */
.local-file-controls {
  padding: 15px;
  background: #f8f9fa;
  border-radius: 6px;
  border: 1px solid #e9ecef;
}

/* ===== NOTIFICATION BANNER STYLES ===== */
/* Base notification banner style */
.notification-banner {
  padding: 10px;
  border-radius: 4px;
  border-left: 4px solid;
  display: none;
  position: relative;
}

/* Data flow info banner (blue theme) */
.data-flow-info {
  background: #e3f2fd;
  border-left-color: #2196f3;
}

.data-flow-info .banner-title {
  font-size: 18px;
  padding-right: 25px;
}

.data-flow-info .banner-subtitle {
  font-size: 16px;
  padding-right: 25px;
}

/* Template info banner (yellow theme) */
.template-info {
  background: #fff3cd;
  border-left-color: #ffc107;
}

.template-info .banner-icon {
  font-size: 16px;
}

.template-info .banner-title {
  color: #856404;
  font-size: 18px;
  margin-left: 5px;
}

.template-info .banner-subtitle {
  color: #856404;
  font-size: 16px;
  margin-top: 2px;
}

/* TXT file info banner (blue theme) */
.txt-file-info {
  background: #e3f2fd;
  border-left-color: #2196f3;
}

.txt-file-info .banner-icon {
  font-size: 16px;
}

.txt-file-info .banner-title {
  color: #0d47a1;
  font-size: 18px;
  margin-left: 5px;
}

.txt-file-info .banner-subtitle {
  color: #0d47a1;
  font-size: 16px;
  margin-top: 2px;
}

/* Banner close button */
.banner-close-btn {
  position: absolute;
  top: 5px;
  right: 5px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
}

.data-flow-info .banner-close-btn {
  color: #2196f3;
}

.template-info .banner-close-btn {
  color: #856404;
}

.txt-file-info .banner-close-btn {
  color: #0d47a1;
}

/* Banner content wrapper to accommodate close button */
.banner-content {
  padding-right: 25px;
}

/* ===== RANDOM VARIABLES GRID STYLES ===== */
/* Random variables grid layout */
.random-variables-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  font-size: 12px;
}

/* Random variables category headers */
.random-variable-category-header {
  margin: 0 0 12px 0;
  color: #2c3e50;
  font-size: 14px;
  font-weight: 600;
  border-bottom: 2px solid #e9ecef;
  padding-bottom: 6px;
}

/* Secondary category header (for subcategories) */
.random-variable-category-header.secondary {
  margin: 20px 0 12px 0;
}

/* ===== STANDARDIZED SECTION DESIGN SYSTEM ===== */

/* Level 1: Main Sections (Journey, Settings, Examples, Playgrounds, Project) */
.section-main {
  margin: 20px 0;
  padding: 16px;
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.section-main-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  background: #f8f9fa;
  border-bottom: 1px solid #dee2e6;
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
  transition: background-color 0.2s ease;
}

.section-main-header:hover {
  background: #e2e6ea;
}

.section-main-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #495057;
}

.section-main-content {
  padding: 16px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.section-main-content.collapsed {
  max-height: 0;
  opacity: 0;
  padding: 0 16px;
  overflow: hidden;
  pointer-events: none;
}

/* Level 2: Sub-sections (Project Information, Events, etc.) */
.section-sub {
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  margin: 15px 0;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.section-sub-header {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background: #f5f7fa;
  border-bottom: 1px solid #eceff3;
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
  transition: background-color 0.2s ease;
  border-radius: 8px 8px 0 0;
}

.section-sub-header:hover {
  background: #e2e6ea;
}

/* Buttons in grey section sub-headers should have white backgrounds (unless specifically colored) */
/* Exclude deleteProjectBtn which has its own red styling */
.section-sub-header
  button.btn-sm:not(.btn-primary):not(.btn-success):not(.btn-danger):not(.btn-warning):not(
    .queued
  ):not(.queue-clear-btn):not(#deleteProjectBtn),
.section-sub-header
  .project-action-buttons
  button.btn-sm:not(.btn-primary):not(.btn-success):not(.btn-danger):not(.btn-warning):not(
    .queued
  ):not(.queue-clear-btn):not(#deleteProjectBtn) {
  background-color: #fff !important;
  border: 1px solid #ced4da;
  color: #495057;
}

.section-sub-header
  button.btn-sm:not(.btn-primary):not(.btn-success):not(.btn-danger):not(.btn-warning):not(
    .queued
  ):not(.queue-clear-btn):not(#deleteProjectBtn):hover,
.section-sub-header
  .project-action-buttons
  button.btn-sm:not(.btn-primary):not(.btn-success):not(.btn-danger):not(.btn-warning):not(
    .queued
  ):not(.queue-clear-btn):not(#deleteProjectBtn):hover {
  background-color: #e9ecef !important;
  border-color: #adb5bd;
}

.section-sub-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #495057;
  flex: 1;
}

.section-sub-content {
  padding: 16px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.section-sub-content.collapsed {
  opacity: 0;
  padding: 0 16px;
  overflow: hidden;
  transform: translateY(-10px);
  max-height: 0;
  pointer-events: none;
}

/* Level 3: Sub-sub-sections (Description, Random Variables, How It Works) */
.section-sub-sub {
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  margin: 10px 0;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.section-sub-sub-header {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  margin-bottom: 0;
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
  transition: background-color 0.2s ease;
}

.section-sub-sub-header:hover {
  background: #e9ecef;
}

.section-sub-sub-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #495057;
  flex: 1;
}

.section-sub-sub-content {
  padding: 12px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.section-sub-sub-content.collapsed {
  opacity: 0;
  padding: 0 16px;
  overflow: hidden;
  transform: translateY(-10px);
  max-height: 0;
  pointer-events: none;
}

/* Toggle button styling for all levels */
.section-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
}

.section-toggle:hover {
  background: rgba(0, 0, 0, 0.1);
}

.section-toggle-icon {
  font-size: 12px;
  color: #6c757d;
  transition: transform 0.2s ease;
  line-height: 1;
}

.section-toggle-icon.collapsed {
  transform: rotate(-90deg);
}

/* ===== SECTION SPACING ===== */
/* Notes sections with top margin - only when not collapsed */
.notes-section.spaced {
  margin-top: 15px;
}

/* Reduce top margin and padding for first sub-section in Project and Examples sections */
#projectContent > .section-sub:first-child,
#exampleEventsContent > .section-sub:first-child {
  margin-top: 0;
}

/* Also reduce spacing for first sub-section in example files container */
#exampleFilesContainer > .section-sub:first-child {
  margin-top: 0;
}

/* Reduce top padding for Project and Examples section-content to reduce whitespace */
#projectContent,
#exampleEventsContent {
  padding-top: 8px;
}

/* Remove margin when the parent section is collapsed */
.section.collapsed .notes-section.spaced {
  margin-top: 0;
}

/* ===== MY PROJECTS DASHBOARD STYLES ===== */

/* Search container */
.my-projects-search-container {
  margin-bottom: 15px;
  padding: 0 0 12px 0;
  border-bottom: 1px solid #e9ecef;
}

/* Search and sort wrapper */
.my-projects-search-sort-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
}

/* Sort select dropdown */
.my-projects-sort-select {
  flex-shrink: 0;
  padding: 6px 10px;
  font-size: 13px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  background-color: #fff;
  color: #495057;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
  min-width: 140px;
}

.my-projects-sort-select:hover {
  border-color: #adb5bd;
}

.my-projects-sort-select:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.1);
}

/* Search input - less prominent */
.my-projects-search-input {
  flex: 1;
  min-width: 0;
  padding: 6px 12px;
  font-size: 13px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
  background-color: #f8f9fa;
}

.my-projects-search-input:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.1);
  background-color: #fff;
}

.my-projects-search-input::placeholder {
  color: #adb5bd;
  font-size: 12px;
}

/* Project cards container */
.my-projects-cards-container {
  max-height: 600px;
  overflow-y: auto;
  padding: 10px 0;
}

/* Individual project card */
.my-project-card {
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 15px;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.my-project-card:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  border-color: #b8c0c8;
  transform: translateY(-2px);
}

.my-project-card:last-child {
  margin-bottom: 0;
}

/* Card header */
.my-project-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  gap: 15px;
}

.my-project-card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.my-project-card-name {
  font-size: 16px;
  font-weight: 600;
  color: #2c3e50;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.my-project-card-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 500;
  background: #e3f2fd;
  color: #1976d2;
  border-radius: 4px;
  white-space: nowrap;
}

.my-project-card-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* My Projects Load button - uses add-link-btn styling when not loaded */
.my-project-load-btn {
  /* Default styling matches add-link-btn */
  background-color: #e2e6ea;
  color: #333;
  border: 1px solid #d1d5db;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 500;
  border-radius: 6px;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.my-project-load-btn:hover:not(.btn-success) {
  background-color: #d4dadd;
  border-color: #9ca3af;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

/* When loaded, button uses btn-success styling (green) */
.my-project-load-btn.btn-success {
  background-color: #28a745;
  color: #fff;
  border-color: #28a745;
}

.my-project-load-btn.btn-success:hover {
  background-color: #218838;
  border-color: #1e7e34;
  box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
  transform: translateY(-1px);
}

/* Combined status and meta line */
.my-project-card-status-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

/* Card status indicators */
.my-project-card-status {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

/* Card metadata */
.my-project-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #6c757d;
  flex-wrap: wrap;
}

.my-project-card-meta .meta-separator {
  color: #dee2e6;
}

/* Card description wrapper */
.my-project-card-description-wrapper {
  margin-top: 8px;
}

/* Card description toggle button */
.my-project-card-description-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  padding: 4px 0;
  font-size: 12px;
  color: #6c757d;
  cursor: pointer;
  transition: color 0.2s ease;
}

.my-project-card-description-toggle:hover {
  color: #495057;
}

.my-project-card-description-toggle-icon {
  font-size: 10px;
  transition: transform 0.2s ease;
}

.my-project-card-description-toggle-text {
  font-weight: 500;
}

/* Card description */
.my-project-card-description {
  font-size: 13px;
  color: #495057;
  line-height: 1.5;
  margin-top: 6px;
  padding-left: 16px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.my-project-card-description.collapsed {
  display: none;
}

.my-project-status-indicator {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 4px;
  white-space: nowrap;
  letter-spacing: 0.3px;
}

/* Loaded indicator - green/success */
.my-project-status-indicator.loaded-indicator {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

/* Test indicator - matches header TEST badge (blue) */
.my-project-status-indicator.test-status {
  background-color: #007bff;
  color: white;
  border: 1px solid #007bff;
  font-weight: 700;
  letter-spacing: 0.5px;
}

/* Public indicator - blue */
.my-project-status-indicator.public-indicator {
  background-color: #cfe2ff;
  color: #084298;
  border: 1px solid #b6d4fe;
}

/* Private indicator - gray */
.my-project-status-indicator.private-indicator {
  background-color: #e9ecef;
  color: #495057;
  border: 1px solid #dee2e6;
}

/* GTM indicator - matches private indicator styling */
.my-project-status-indicator.gtm-indicator {
  background-color: #e9ecef;
  color: #495057;
  border: 1px solid #dee2e6;
}

/* Empty states */
.my-projects-empty,
.my-projects-loading,
.my-projects-error {
  padding: 40px 20px;
  text-align: center;
  color: #6c757d;
}

.my-projects-error {
  color: #dc3545;
}

/* Project count badge in header */
#myProjectsCount {
  font-size: 14px;
  font-weight: 400;
  color: #6c757d;
  margin-left: 4px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .my-projects-search-sort-wrapper {
    flex-direction: column;
    gap: 8px;
  }

  .my-projects-sort-select {
    width: 100%;
    min-width: auto;
  }

  .my-projects-search-input {
    width: 100%;
  }

  .my-project-card-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .my-project-card-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .my-project-card-status-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .my-project-card-meta {
    font-size: 12px;
  }

  .my-project-card-description {
    font-size: 13px;
  }

  .my-projects-cards-container {
    max-height: 500px;
  }
}

/* Scrollbar styling for cards container */
.my-projects-cards-container::-webkit-scrollbar {
  width: 8px;
}

.my-projects-cards-container::-webkit-scrollbar-track {
  background: #f1f3f5;
  border-radius: 4px;
}

.my-projects-cards-container::-webkit-scrollbar-thumb {
  background: #adb5bd;
  border-radius: 4px;
}

.my-projects-cards-container::-webkit-scrollbar-thumb:hover {
  background: #868e96;
}
