/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* ============================================
 * Collapsible Sidebar Styles
 * ============================================ */

/* Width utility for collapsed sidebar (52px) */
.w-13 {
  width: 3.25rem;
}

/* Hide webkit details marker */
summary.list-none::-webkit-details-marker {
  display: none;
}

summary::-webkit-details-marker {
  display: none;
}

/* Sidebar collapse/expand transitions */
details[data-sidebar-target="desktopSidebar"] {
  transition: width 300ms ease-out;
}

/* When details is closed, only show the summary (collapsed state) */
details[data-sidebar-target="desktopSidebar"]:not([open]) {
  width: 3.25rem; /* w-13 */
}

/* When details is open, show full width */
details[data-sidebar-target="desktopSidebar"][open] {
  width: 16rem; /* w-64 */
}

/* Hide the collapsed summary content when expanded */
details[data-sidebar-target="desktopSidebar"][open] > summary {
  display: none;
}

/* Mobile sidebar transitions */
[data-sidebar-target="mobilePanel"] {
  transform: translateX(-100%);
  transition: transform 300ms ease-out;
}

[data-sidebar-target="mobileBackdrop"] {
  opacity: 0;
  transition: opacity 300ms ease-out;
}

/* ============================================
 * Tooltip Styles
 * ============================================ */

/* Tooltip instant mode - disable transitions for fast switching */
.tooltip-content[data-instant] {
  transition: none !important;
}

/* ============================================
 * Legacy responsive layout (kept for backwards compatibility)
 * TODO: Remove once all pages use new sidebar pattern
 * ============================================ */

@media (min-width: 768px) {
  .responsive-layout {
    flex-direction: row;
  }

  .sidebar {
    width: 16rem;
    /* Keep the original width on desktop */
  }
}

@media (max-width: 767px) {
  .sidebar {
    width: 100%;
    /* Full width on mobile */
  }
}

/*
 *= require actiontext
 */
