@media (max-width: 1024px) {
  .toolbar { flex-wrap: wrap; }
  .search-wrapper { order: 1; flex-basis: 100%; max-width: none; }
  .multi-select-toolbar { order: 2; flex-basis: 100%; }
  .export-buttons { order: 3; justify-content: flex-end; }
}

@media (max-width: 768px) {
  :root { --header-height: 52px; --row-height: 48px; --header-row-height: 44px; }
  .app-header { flex-wrap: wrap; height: auto; padding: var(--space-sm) var(--space-md); gap: var(--space-sm); }
  .header-left { order: 1; }
  .main-nav { order: 3; width: 100%; overflow-x: auto; flex-wrap: nowrap; padding-bottom: var(--space-xs); -webkit-overflow-scrolling: touch; }
  .header-right { order: 2; margin-left: auto; }
  .app-title { font-size: var(--text-lg); }
  .nav-btn { padding: var(--space-xs) var(--space-sm); font-size: var(--text-xs); }
  .user-badge { display: none; }
  .app-main { padding: var(--space-sm); }
  .view-header { flex-direction: column; align-items: flex-start; gap: var(--space-sm); }
  .header-actions { width: 100%; }
  .header-actions .btn { flex: 1; justify-content: center; }
  .toolbar { padding: var(--space-sm); }
  .multi-select-toolbar { flex-wrap: wrap; }
  .bulk-actions { display: flex; flex-wrap: wrap; gap: var(--space-xs); width: 100%; }
  .bulk-actions .btn { flex: 1; min-width: calc(50% - 4px); justify-content: center; font-size: var(--text-xs); padding: var(--space-xs) var(--space-sm); }
  .export-buttons { width: 100%; justify-content: flex-end; }
  .filter-chips { gap: var(--space-xs); }
  .data-table th, .data-table td { padding: var(--space-xs) var(--space-sm); font-size: var(--text-xs); }
  .data-table .cell-actions .icon-btn { width: 24px; height: 24px; }
  .modal { max-width: 100%; max-height: 100vh; border-radius: 0; margin: 0; }
  .modal-overlay { padding: 0; align-items: flex-end; }
  .modal-overlay:not([hidden]) .modal { transform: translateY(0); }
  .modal { transform: translateY(100%); transition: transform var(--transition-base); }
  .editor-sections { flex-direction: column; }
  .editor-section { min-width: 0; }
  .columns-table { font-size: var(--text-xs); }
  .columns-table th, .columns-table td { padding: var(--space-xs) var(--space-sm); }
  .audit-filters { flex-direction: column; }
  .audit-filters select, .audit-filters input { width: 100%; }
}

@media (max-width: 480px) {
  :root { --space-md: 12px; --space-lg: 16px; --text-base: 13px; --text-sm: 12px; --text-xs: 10px; }
  .app-header { padding: var(--space-xs) var(--space-sm); }
  .logo-icon { width: 24px; height: 24px; }
  .app-title { font-size: var(--text-base); }
  .nav-btn { padding: 6px 10px; font-size: 11px; }
  .icon-btn { width: 32px; height: 32px; }
  .icon-btn svg { width: 18px; height: 18px; }
  .view-header h2 { font-size: var(--text-lg); }
  .btn { padding: 8px 12px; font-size: var(--text-xs); }
  .btn svg { width: 14px; height: 14px; }
  .toolbar { padding: var(--space-xs); gap: var(--space-xs); }
  .search-wrapper input { padding: 8px 12px 8px 36px; font-size: var(--text-xs); }
  .search-icon { width: 16px; height: 16px; left: 10px; }
  .multi-select-toolbar { padding: var(--space-xs); font-size: var(--text-xs); }
  .bulk-actions .btn { min-width: 100%; font-size: 11px; padding: 6px 8px; }
  .export-buttons .btn { padding: 6px 10px; font-size: 11px; }
  .export-buttons .btn span { display: none; }
  .filter-chip { font-size: var(--text-xs); padding: 2px 8px; }
  .data-table { font-size: var(--text-xs); }
  .data-table th { padding: 6px 8px; font-size: 10px; }
  .data-table td { padding: 6px 8px; }
  .data-table .checkbox-cell { width: 32px; }
  .data-table .checkbox-cell input { width: 16px; height: 16px; }
  .status-badge { padding: 1px 6px; font-size: 10px; }
  .empty-state { padding: var(--space-lg) var(--space-sm); }
  .empty-state svg { width: 40px; height: 40px; }
  .empty-state p { font-size: var(--text-sm); }
  .pagination { padding: var(--space-sm); gap: var(--space-xs); }
  .pagination button { padding: 4px 8px; font-size: var(--text-xs); }
  .form-group { margin-bottom: var(--space-sm); }
  .form-group label { font-size: var(--text-xs); }
  .form-group input, .form-group select, .form-group textarea { padding: 8px 10px; font-size: var(--text-sm); }
  .form-row { gap: var(--space-sm); }
  .form-actions { flex-direction: column-reverse; gap: var(--space-xs); }
  .form-actions .btn { width: 100%; justify-content: center; }
  .login-card { padding: var(--space-lg); }
  .login-icon { width: 48px; height: 48px; }
  .login-card h1 { font-size: var(--text-xl); }
  .modal-header { padding: var(--space-sm) var(--space-md); }
  .modal-header h3 { font-size: var(--text-base); }
  .modal-body { padding: var(--space-md); }
  .modal-footer { padding: var(--space-sm) var(--space-md); flex-direction: column-reverse; }
  .modal-footer .btn { width: 100%; }
  .detail-grid { grid-template-columns: 1fr; gap: var(--space-xs) 0; }
  .detail-grid dt { font-size: var(--text-xs); color: var(--color-text-muted); }
  .detail-grid dd { font-size: var(--text-sm); padding-bottom: var(--space-sm); border-bottom: 1px solid var(--color-border); }
  .detail-grid dd:last-child { border-bottom: none; }
  .editor-section { padding: var(--space-sm); }
  .editor-section h4 { font-size: var(--text-xs); }
  .columns-table th, .columns-table td { padding: 6px 8px; font-size: 11px; }
  .columns-actions { flex-direction: column-reverse; }
  .columns-actions .btn { width: 100%; }
  .audit-filters select, .audit-filters input { font-size: var(--text-sm); padding: 8px 10px; }
  .audit-row .diff-cell { max-width: 120px; font-size: 10px; }
  .toast-container { left: var(--space-sm); right: var(--space-sm); bottom: var(--space-sm); max-width: none; }
  .toast { font-size: var(--text-sm); padding: var(--space-sm); }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .editor-sections { flex-direction: column; }
  .editor-section { min-width: 0; }
}

@media (hover: none) and (pointer: coarse) {
  .icon-btn, .nav-btn, .btn, .filter-tab, .filter-option, .status-filter-chip, .columns-table .drag-handle, .action-btns .icon-btn { min-height: 44px; min-width: 44px; }
  .data-table td, .data-table th { padding-top: 12px; padding-bottom: 12px; }
  .form-group input, .form-group select, .form-group textarea { padding-top: 12px; padding-bottom: 12px; }
  .search-wrapper input { padding-top: 12px; padding-bottom: 12px; }
}

@media print {
  .app-header, .toolbar, .filter-chips, .pagination, .modal-overlay, .toast-container, .header-actions, .bulk-actions, .export-buttons { display: none !important; }
  .app-main { padding: 0; }
  .table-container { border: none; box-shadow: none; }
  .data-table { font-size: 11px; }
  .data-table th { background: #f0f0f0 !important; color: #000 !important; border-bottom: 2px solid #000 !important; }
  .data-table td { border-bottom: 1px solid #ddd !important; }
  .data-table tbody tr:nth-child(even) { background: #fafafa !important; }
  .status-badge { border: 1px solid currentColor !important; background: transparent !important; }
  .frozen-shadow, .frozen-bg { box-shadow: none !important; background: transparent !important; }
}

@supports not (position: sticky) {
  .data-table thead { position: static; }
  .data-table th.frozen, .data-table td.frozen { position: static; box-shadow: none; }
}