/* ─── App Component Styles ───────────────────────────────────────────────── */
/* DiscoverFile Product Website — Mockup Component Styles                    */
/* These styles replicate the actual application's UI components              */
/* ────────────────────────────────────────────────────────────────────────── */

/* ─── Shared App Frame ───────────────────────────────────────────────────── */

.app-frame {
  background: var(--bg-primary);
  border: 1px solid var(--border-base);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  transition: all 0.6s ease;
}

.app-frame-label {
  display: block;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 12px;
}

/* ─── StatsBar ───────────────────────────────────────────────────────────── */

.stats-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  background: var(--bg-secondary);
  background-image: var(--gradient-statsbar);
  border-bottom: 1px solid var(--border-base);
  font-size: 13px;
}

.stats-bar-left {
  display: flex;
  align-items: center;
  gap: 24px;
}

.stats-bar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
}

.stat-value {
  color: var(--text-primary);
  font-weight: 600;
}

.stat-icon {
  width: 13px;
  height: 13px;
  opacity: 0.7;
}

/* ─── Toolbar ────────────────────────────────────────────────────────────── */

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-base);
}

.toolbar-left {
  display: flex;
  align-items: center;
  gap: 6px;
}

.toolbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* ─── Filter Tabs ────────────────────────────────────────────────────────── */

.filter-tab {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
  border: none;
  background: none;
}

.filter-tab.active {
  background: var(--accent-primary);
  color: #fff;
}

.filter-tab:not(.active):hover {
  color: var(--text-primary);
  background: var(--bg-card-hover);
}

.filter-tab .badge {
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.2);
  font-weight: 600;
}

.filter-tab:not(.active) .badge {
  background: var(--bg-input);
  color: var(--text-muted);
}

/* ─── Search Bar ─────────────────────────────────────────────────────────── */

.search-input {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  border-radius: 6px;
  font-size: 12px;
  color: var(--text-primary);
  min-width: 200px;
  transition: border-color 0.2s;
}

.search-input:focus-within {
  border-color: var(--accent-primary);
}

.search-input svg {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-input input {
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: inherit;
  width: 100%;
}

.search-input input::placeholder {
  color: var(--text-muted);
}

/* ─── Sort Dropdown ──────────────────────────────────────────────────────── */

.sort-control {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-muted);
}

.sort-control select {
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  border-radius: 4px;
  padding: 3px 8px;
  font-size: 11px;
  color: var(--text-secondary);
  outline: none;
  cursor: pointer;
}

/* ─── Drive Card Grid ────────────────────────────────────────────────────── */

.drive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
  padding: 20px;
}

/* ─── Drive Card ─────────────────────────────────────────────────────────── */

.drive-card {
  background: var(--bg-surface);
  background-image: var(--gradient-card);
  border: 1px solid var(--border-base);
  border-radius: 10px;
  padding: 16px;
  transition: all 0.15s ease;
  cursor: pointer;
}

.drive-card:hover {
  background-image: var(--gradient-card-hover);
  border-color: var(--border-hover);
  box-shadow: var(--glow-accent);
}

.drive-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 12px;
}

.drive-card-info {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.drive-status-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-top: 3px;
  flex-shrink: 0;
}

.drive-status-dot.connected {
  background: var(--status-connected);
  box-shadow: 0 0 9px var(--status-connected);
}

.drive-status-dot.unscanned {
  background: var(--status-unscanned);
  box-shadow: 0 0 9px var(--status-unscanned);
}

.drive-status-dot.disconnected {
  background: var(--status-disconnected);
}

.drive-status-dot.scanning {
  background: var(--accent-yellow);
  animation: scan-pulse 1.5s ease infinite;
}

.drive-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.drive-card-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.drive-card-sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ─── Storage Bar ────────────────────────────────────────────────────────── */

.storage-bar-container {
  margin: 8px 0;
}

.storage-bar {
  height: 6px;
  border-radius: 3px;
  background: var(--bg-input);
  overflow: hidden;
  position: relative;
}

.storage-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s ease;
  position: relative;
  overflow: hidden;
}

/* Subtle glow/sheen effect on storage bars to match app */
.storage-bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 3px;
  background: linear-gradient(180deg, rgba(255,255,255,0.18) 0%, transparent 50%, rgba(0,0,0,0.1) 100%);
}

.storage-bar-fill.blue {
  background: var(--gradient-storage-blue);
}

.storage-bar-fill.yellow {
  background: var(--gradient-storage-yellow);
}

.storage-bar-fill.red {
  background: var(--gradient-storage-red);
}

.storage-bar-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 4px;
  font-size: 11px;
  color: var(--text-muted);
}

/* ─── Tags ───────────────────────────────────────────────────────────────── */

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 8px 0;
}

.tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  color: #fff;
}

/* ─── Metadata Badges ────────────────────────────────────────────────────── */

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.metadata-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--bg-input);
  color: var(--text-secondary);
}

/* ─── Indexing Progress ──────────────────────────────────────────────────── */

.indexing-progress {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-base);
}

.indexing-progress-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 11px;
}

.indexing-progress-label .phase {
  color: var(--accent-primary);
  font-weight: 600;
}

.indexing-progress-label .count {
  color: var(--text-muted);
}

.indexing-progress-bar {
  height: 4px;
  border-radius: 2px;
  background: var(--bg-input);
  overflow: hidden;
}

.indexing-progress-bar-fill {
  height: 100%;
  border-radius: 2px;
  background: var(--accent-primary);
  transition: width 0.3s ease;
}

/* ─── Modal Frame ────────────────────────────────────────────────────────── */

.modal-frame {
  background: var(--bg-surface);
  background-image: var(--gradient-card);
  border: 1px solid var(--border-base);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 0;
}

.modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: none;
  background: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  transition: all 0.15s;
}

.modal-close:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}

/* ─── Tabs ───────────────────────────────────────────────────────────────── */

.tab-bar {
  display: flex;
  gap: 0;
  padding: 0 20px;
  margin-top: 16px;
  border-bottom: 1px solid var(--border-base);
}

.tab {
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
}

.tab.active {
  color: var(--accent-primary);
  border-bottom-color: var(--accent-primary);
}

.tab:not(.active):hover {
  color: var(--text-primary);
}

/* ─── Drive Detail Header ────────────────────────────────────────────────── */

.detail-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 20px;
}

.detail-icon {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.detail-info {
  flex: 1;
  min-width: 0;
}

.detail-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.detail-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-muted);
}

.detail-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.detail-status .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.detail-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

/* ─── Storage Breakdown ──────────────────────────────────────────────────── */

.storage-breakdown {
  padding: 0 20px;
}

.storage-breakdown h4 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.folder-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 4px;
  border-radius: 6px;
  transition: background 0.15s;
}

.folder-row:hover {
  background: var(--bg-card-hover);
}

.folder-color {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  flex-shrink: 0;
}

.folder-name {
  flex: 1;
  font-size: 12px;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.folder-size {
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.folder-pct {
  width: 48px;
  text-align: right;
  font-size: 12px;
  color: var(--text-muted);
}

/* Folder entry wrapper (hover highlight, non-clickable) */
.folder-entry {
  border-radius: 6px;
  transition: background 0.15s;
}

.folder-entry:hover {
  background: var(--bg-card-hover);
}

.folder-files {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  min-width: 72px;
  text-align: right;
}

.folder-bar {
  margin: 2px 4px 4px 16px;
  height: 6px;
  border-radius: 3px;
  background: rgba(128, 128, 128, 0.12);
  overflow: hidden;
}

.folder-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s ease;
  position: relative;
}

/* Gradient overlay for folder bars — mimics app's dark-to-bright effect */
.folder-bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 3px;
  background: linear-gradient(90deg, rgba(0,0,0,0.35) 0%, transparent 100%);
}

/* Extension table — hover highlight (non-clickable) */
.donut-legend table tbody tr {
  transition: background 0.15s;
}

.donut-legend table tbody tr:hover {
  background: var(--bg-card-hover);
}

/* ─── Donut Chart ────────────────────────────────────────────────────────── */

.donut-section {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  padding: 0 20px;
}

.donut-chart {
  width: 160px;
  height: 160px;
  flex-shrink: 0;
  position: relative;
}

.donut-chart svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.donut-legend {
  flex: 1;
  max-height: 200px;
  overflow-y: auto;
}

.donut-legend-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 12px;
  border-bottom: 1px solid var(--border-base);
  transition: background 0.15s;
}

.donut-legend-row:last-child {
  border-bottom: none;
}

.donut-legend-row:hover {
  background: var(--bg-card-hover);
}

.legend-color {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

.legend-ext {
  flex: 1;
  color: var(--text-primary);
}

.legend-stats {
  color: var(--text-secondary);
  text-align: right;
  white-space: nowrap;
}

/* ─── File Browser ───────────────────────────────────────────────────────── */

.browser-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-muted);
  padding: 0 20px;
  margin-bottom: 8px;
}

.breadcrumb-seg {
  color: var(--accent-primary);
  cursor: pointer;
}

.breadcrumb-seg:hover {
  text-decoration: underline;
}

.breadcrumb-sep {
  color: var(--text-muted);
  font-size: 10px;
}

.breadcrumb-current {
  color: var(--text-primary);
}

.file-list {
  border: 1px solid var(--border-base);
  border-radius: 8px;
  background: var(--bg-secondary);
  margin: 0 20px;
  overflow: hidden;
}

.file-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  font-size: 12px;
  transition: background 0.1s;
  border-bottom: 1px solid var(--border-base);
}

.file-row:last-child {
  border-bottom: none;
}

.file-row:hover {
  background: var(--bg-card-hover);
}

.file-row .expand-arrow {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.file-thumb {
  width: 40px;
  height: 40px;
  border-radius: 4px;
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  overflow: hidden;
}

.file-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.file-name {
  flex: 1;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-size {
  color: var(--text-secondary);
  white-space: nowrap;
  min-width: 60px;
  text-align: right;
}

.file-date {
  color: var(--text-muted);
  white-space: nowrap;
  min-width: 80px;
  text-align: right;
}

/* ─── Tile Grid ──────────────────────────────────────────────────────────── */

.tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  padding: 0 20px;
}

.tile-node {
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  border-radius: 8px;
  padding: 8px;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s;
}

.tile-node:hover {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
}

.tile-thumb {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 4px;
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin-bottom: 6px;
  overflow: hidden;
}

.tile-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tile-name {
  font-size: 11px;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tile-meta {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ─── File Detail Panel ──────────────────────────────────────────────────── */

.file-detail-panel {
  width: 340px;
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  border-radius: 8px;
  padding: 16px;
  overflow-y: auto;
}

.detail-thumbnail {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 8px;
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  margin-bottom: 12px;
  overflow: hidden;
}

.detail-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-field {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid var(--border-base);
  font-size: 12px;
}

.detail-field:last-child {
  border-bottom: none;
}

.detail-field-label {
  color: var(--text-muted);
}

.detail-field-value {
  color: var(--text-primary);
  text-align: right;
}

.detail-section-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 12px 0 4px;
}

/* ─── Search Modal ───────────────────────────────────────────────────────── */

.search-modal {
  max-width: 700px;
  width: 100%;
}

.search-modal-header {
  padding: 16px 20px 12px;
  border-bottom: 1px solid var(--border-base);
}

.search-modal-input {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-modal-input svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-modal-input input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-size: 14px;
  color: var(--text-primary);
}

.search-modal-input input::placeholder {
  color: var(--text-muted);
}

.search-results-count {
  font-size: 12px;
  color: var(--text-muted);
}

.search-options {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  font-size: 11px;
  color: var(--text-muted);
}

.search-options label {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.search-options input[type="checkbox"] {
  width: 12px;
  height: 12px;
  accent-color: var(--accent-primary);
}

/* Content search snippet */
.content-snippet {
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 4px;
  line-height: 1.5;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-snippet mark {
  background: rgba(251, 191, 36, 0.3);
  color: var(--text-primary);
  border-radius: 2px;
  padding: 0 2px;
}

/* ─── Photo Map ──────────────────────────────────────────────────────────── */

.map-frame {
  position: relative;
  overflow: hidden;
}

.map-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-base);
}

.map-header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.map-header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.map-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.map-count {
  font-size: 12px;
  color: var(--text-muted);
}

.map-canvas {
  width: 100%;
  height: 400px;
  background: var(--map-bg);
  position: relative;
  overflow: hidden;
}

.map-land {
  fill: var(--map-land);
  stroke: var(--map-border);
  stroke-width: 0.8;
}

.map-cluster {
  border-radius: 50%;
  background: var(--accent-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  position: absolute;
  border: 2px solid rgba(255, 255, 255, 0.3);
  opacity: 0.85;
  cursor: pointer;
}

.map-marker {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent-primary);
  border: 2px solid #fff;
  position: absolute;
  cursor: pointer;
}

.map-controls {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  border-radius: 6px;
  overflow: hidden;
}

.map-controls button {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: var(--bg-surface);
  color: var(--text-primary);
  font-size: 16px;
  cursor: pointer;
  transition: background 0.15s;
}

.map-controls button:hover {
  background: var(--bg-card-hover);
}

.map-attribution {
  position: absolute;
  bottom: 4px;
  right: 4px;
  font-size: 10px;
  color: var(--text-muted);
  opacity: 0.7;
}

/* Map cluster popup */
.cluster-popup {
  width: 320px;
  max-height: 420px;
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  position: absolute;
  overflow-y: auto;
  padding: 8px;
}

.cluster-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.cluster-thumb {
  width: 70px;
  height: 70px;
  border-radius: 4px;
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  overflow: hidden;
}

.cluster-thumb:hover {
  outline: 2px solid var(--accent-primary);
}

/* Photo detail overlay (inside map canvas) */
.photo-detail-overlay {
  position: absolute;
  inset: 0;
  z-index: 10;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-detail-panel {
  width: 320px;
  max-height: 390px;
  overflow-y: auto;
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  border-radius: 10px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  padding: 16px;
  position: relative;
}

.photo-detail-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  border: none;
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  border-radius: 50%;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.photo-detail-close:hover {
  background: rgba(0, 0, 0, 0.6);
}

/* GPS link */
.gps-link {
  color: var(--accent-primary);
  text-decoration: none;
  font-size: 12px;
  cursor: pointer;
}

.gps-link:hover {
  text-decoration: underline;
}

/* ─── Settings Modal ─────────────────────────────────────────────────────── */

.settings-modal {
  max-width: 600px;
  width: 100%;
}

.settings-section {
  margin-bottom: 24px;
}

.settings-section h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
}

.settings-row-label {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Toggle button group */
.toggle-group {
  display: inline-flex;
  border-radius: 8px;
  border: 1px solid var(--border-base);
  overflow: hidden;
}

.toggle-group button {
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
}

.toggle-group button.active {
  background: var(--accent-primary);
  color: #fff;
}

.toggle-group button:not(.active) {
  background: var(--bg-input);
  color: var(--text-secondary);
}

.toggle-group button:not(.active):hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}

/* Toggle switch */
.toggle-switch-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-secondary);
  border-radius: 8px;
  margin-bottom: 6px;
}

.toggle-switch-row:last-child {
  margin-bottom: 0;
}

/* Move toggle to right side (matches real app layout) */
.toggle-switch-row .toggle-switch {
  order: 1;
  margin-top: 2px;
}

.toggle-switch {
  width: 36px;
  height: 20px;
  border-radius: 10px;
  background: var(--border-base);
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s;
}

.toggle-switch.on {
  background: var(--accent-primary);
}

.toggle-switch .knob {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: transform 0.2s;
}

.toggle-switch.on .knob {
  transform: translateX(16px);
}

.toggle-info {
  flex: 1;
}

.toggle-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-primary);
}

.toggle-desc {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  line-height: 1.4;
}

/* Advanced subsection */
.settings-subsection {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.settings-input-group {
  padding: 8px 12px;
  background: var(--bg-secondary);
  border-radius: 8px;
  margin-top: 8px;
}

.settings-input-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.settings-input {
  width: 100%;
  padding: 6px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  border-radius: 6px;
  font-size: 12px;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-primary);
  outline: none;
}

.settings-input:focus {
  border-color: var(--accent-primary);
}

.tool-status {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
  font-size: 11px;
}

.tool-status.found {
  color: var(--accent-green);
}

.tool-status.not-found {
  color: var(--accent-red);
}

/* Tags section */
.tag-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tag-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  transition: background 0.15s;
}

.tag-item:hover {
  background: var(--bg-card-hover);
}

.tag-color-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.tag-name {
  flex: 1;
  font-size: 13px;
  color: var(--text-primary);
}

/* Color picker row */
.color-picker-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.color-swatch {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.1s, border-color 0.15s;
}

.color-swatch:hover {
  transform: scale(1.15);
}

.color-swatch.selected {
  border-color: var(--text-primary);
}

/* ─── Thread/Slider Controls ─────────────────────────────────────────────── */

.slider-row {
  padding: 8px 0;
}

.slider-label {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.slider-value {
  font-weight: 600;
  color: var(--text-primary);
}

.slider-track {
  width: 100%;
  height: 4px;
  border-radius: 2px;
  background: var(--bg-input);
  position: relative;
}

.slider-fill {
  height: 100%;
  border-radius: 2px;
  background: var(--accent-primary);
}

.slider-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent-primary);
  border: 2px solid #fff;
  position: absolute;
  top: -5px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

/* ─── Hero Section ───────────────────────────────────────────────────────── */

.hero {
  padding: 140px 0 80px;
  text-align: center;
}

.hero h1 {
  margin-bottom: 16px;
}

.hero p {
  font-size: 17px;
  margin: 0 auto 32px;
  max-width: 560px;
}

.hero-typewriter-line {
  font-size: 20px;
  font-weight: 500;
  color: var(--text-primary);
  min-height: 2em;
  margin: 0 auto 32px;
}

.hero-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* ─── Features Grid ──────────────────────────────────────────────────────── */

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}

.feature-card {
  padding: 28px;
}

/* ─── Feature Icons — Toggle via data-icon-style on .features-grid ─────── */
/* Use data-icon-style="plain"  → accent-colored SVG, no background         */
/* Use data-icon-style="boxed"  → accent-tinted rounded box + SVG inside    */

.feature-icon {
  margin-bottom: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.feature-icon svg {
  width: 28px;
  height: 28px;
}

/* Style: plain — bare SVG icon in accent color */
[data-icon-style="plain"] .feature-icon {
  color: var(--accent-primary);
}

[data-icon-style="plain"] .feature-icon svg {
  width: 28px;
  height: 28px;
}

/* Style: boxed — rounded box with accent tint background */
[data-icon-style="boxed"] .feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--accent-primary) 12%, transparent);
  color: var(--accent-primary);
}

[data-icon-style="boxed"] .feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-card h3 {
  margin-bottom: 8px;
  color: var(--text-strong);
}

.feature-card p {
  font-size: 13px;
  line-height: 1.5;
}

/* ─── How It Works ───────────────────────────────────────────────────────── */

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  text-align: center;
}

.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gradient-cta);
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
}

.step h3 {
  margin-bottom: 8px;
}

.step p {
  font-size: 13px;
  margin: 0 auto;
  max-width: 280px;
}

@media (max-width: 768px) {
  .steps-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* ─── Pricing Section ────────────────────────────────────────────────────── */

.pricing-card {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
  padding: 40px;
}

.pricing-amount {
  font-size: 48px;
  font-weight: 700;
  color: var(--text-strong);
  line-height: 1;
  margin-bottom: 8px;
}

.pricing-period {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 24px;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-size: 14px;
  color: var(--text-secondary);
}

.pricing-features li::before {
  content: '✓';
  color: var(--accent-green);
  font-weight: 600;
}

/* ─── FAQ Section ────────────────────────────────────────────────────────── */

.faq-list {
  max-width: 700px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border-base);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 0;
  background: none;
  border: none;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
}

.faq-question:hover {
  color: var(--accent-primary);
}

.faq-chevron {
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  transition: transform 0.2s;
  flex-shrink: 0;
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 300px;
  padding-bottom: 16px;
}

.faq-answer p {
  font-size: 14px;
  line-height: 1.6;
}

/* ─── Footer ─────────────────────────────────────────────────────────────── */

.footer {
  padding: 40px 0;
  border-top: 1px solid var(--border-base);
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-brand {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
}

.footer-copy {
  font-size: 12px;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 20px;
  list-style: none;
}

.footer-links a {
  font-size: 12px;
  color: var(--text-muted);
}

.footer-links a:hover {
  color: var(--text-primary);
}

/* ─── View Toggle ────────────────────────────────────────────────────────── */

.view-toggle {
  display: inline-flex;
  border-radius: 6px;
  border: 1px solid var(--border-base);
  overflow: hidden;
}

.view-toggle button {
  width: 32px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
  font-size: 14px;
  color: var(--text-muted);
}

.view-toggle button.active {
  background: var(--accent-primary);
  color: #fff;
}

.view-toggle button:not(.active) {
  background: var(--bg-input);
}

/* ─── Showcase Section ───────────────────────────────────────────────────── */

.showcase-section {
  padding: 60px 0;
}

.showcase-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.showcase-title {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  margin-bottom: 8px;
}

.showcase-desc {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  max-width: 560px;
}

/* ─── Interactive Demo Layouts ────────────────────────────────────────────── */
/* These replicate exact app animation patterns (slide-in panels, modals)     */

/* File Detail Side Panel — Slide-in animation (matches app: 300ms ease-out) */
.side-panel-wrapper {
  width: 0;
  flex-shrink: 0;
  overflow: hidden;
  transition: width 300ms ease-out;
}

.side-panel-wrapper.open {
  width: 340px;
}

.side-panel-inner {
  width: 340px;
  height: 100%;
  border-left: 1px solid var(--border-base);
  background: var(--bg-surface);
  overflow-y: auto;
  padding: 0;
}

/* Browse content row — flex layout matching the real app */
.browse-content {
  display: flex;
  min-height: 0;
  overflow: hidden;
}

.browse-content .file-list-wrapper {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

/* Search modal — width expansion when panel opens (matches app: 700→1050px) */
.search-modal-expandable {
  width: 700px;
  max-width: 95vw;
  transition: width 300ms ease-out;
}

.search-modal-expandable.panel-open {
  width: 1050px;
}

/* Clickable file rows */
.file-row.clickable {
  cursor: pointer;
}

.file-row.clickable:hover {
  background: var(--bg-card-hover);
}

.file-row.selected {
  background: var(--bg-card-hover);
}

.file-row.selected .file-name {
  color: var(--accent-primary);
  font-weight: 500;
}

/* Interactive hint badge */
.click-hint {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 6px;
  background: var(--accent-primary);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  opacity: 0.9;
  animation: pulse-fade 2s ease infinite;
}

.click-hint svg {
  width: 12px;
  height: 12px;
}

/* Drive card → detail modal demo */
.drive-card.interactive {
  position: relative;
}

.drive-card.interactive::after {
  content: 'Click to explore';
  position: absolute;
  bottom: 8px;
  right: 8px;
  font-size: 10px;
  color: var(--accent-primary);
  opacity: 0;
  transition: opacity 0.2s;
}

.drive-card.interactive:hover::after {
  opacity: 0.7;
}

/* Tab content switcher */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* View toggle content */
.view-content {
  display: none;
}

.view-content.active {
  display: block;
}

/* Modal overlay for demo modals */
.demo-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 300;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
}

.demo-modal-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.demo-modal-overlay .modal-frame {
  transform: scale(0.96);
  transition: transform 200ms ease;
  max-height: 90vh;
  overflow-y: auto;
}

.demo-modal-overlay.visible .modal-frame {
  transform: scale(1);
}

/* Cluster popup animation */
.cluster-popup-demo {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  transition: opacity 150ms ease, transform 150ms ease;
}

.cluster-popup-demo.visible {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

/* Clickable tile nodes */
.tile-node.clickable {
  cursor: pointer;
}

.tile-node.clickable:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
}

.tile-node.selected {
  background: var(--bg-card-hover);
  border-color: var(--accent-primary);
}

.tile-node.selected .tile-name {
  color: var(--accent-primary);
  font-weight: 500;
}

/* Side panel body (injection target for demo content) */
.side-panel-body {
  padding: 16px;
}

/* Toggle switch animation */
.toggle-switch {
  transition: background-color 200ms ease;
}

.toggle-switch .knob {
  transition: transform 200ms ease;
}

/* ─── Tag Filter Pill ────────────────────────────────────────────────────── */

.tag-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.tag-filter-pill:hover {
  color: var(--text-primary);
  border-color: var(--border-hover);
}

.tag-filter-pill svg {
  width: 12px;
  height: 12px;
}

/* ─── Date Range Button ─────────────────────────────────────────────────── */

.date-range-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.date-range-btn:hover {
  color: var(--text-primary);
  border-color: var(--border-hover);
}

.date-range-btn svg {
  width: 12px;
  height: 12px;
}

/* ─── Browse Button (for path inputs) ───────────────────────────────────── */

.browse-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
  flex-shrink: 0;
}

.browse-btn:hover {
  color: var(--text-primary);
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
}

/* ─── License Section ───────────────────────────────────────────────────── */

.license-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  background: var(--bg-secondary);
  border-radius: 8px;
  margin-bottom: 8px;
}

.license-status .status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.license-status .status-dot.active {
  background: var(--accent-green);
  box-shadow: 0 0 8px var(--accent-green);
}

.license-field {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  font-size: 12px;
}

.license-field-label {
  color: var(--text-muted);
}

.license-field-value {
  color: var(--text-primary);
  font-family: 'JetBrains Mono', monospace;
}

/* ─── Duplicates ────────────────────────────────────────────────────────── */

.duplicate-summary-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-base);
  font-size: 12px;
}

.duplicate-summary-stats {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--text-secondary);
}

.duplicate-summary-stats .stat-highlight {
  color: var(--text-primary);
  font-weight: 600;
}

.duplicate-summary-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.duplicate-group {
  border-bottom: 1px solid var(--border-base);
}

.duplicate-group:last-child {
  border-bottom: none;
}

.duplicate-group-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  cursor: pointer;
  transition: background 0.15s;
  font-size: 12px;
}

.duplicate-group-header:hover {
  background: var(--bg-card-hover);
}

.duplicate-group-header .expand-icon {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  transition: transform 0.2s;
  flex-shrink: 0;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.duplicate-group.expanded .expand-icon {
  transform: rotate(90deg);
}

.duplicate-group-header .file-icon {
  font-size: 18px;
  flex-shrink: 0;
}

.duplicate-group-header .group-name {
  flex: 1;
  color: var(--text-primary);
  font-weight: 500;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.duplicate-group-header .group-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--text-muted);
  white-space: nowrap;
  font-size: 11px;
}

.wasted-text {
  color: #f59e0b;
  font-weight: 600;
}

.duplicate-group-files {
  display: none;
  background: var(--bg-secondary);
}

.duplicate-group.expanded .duplicate-group-files {
  display: block;
}

.duplicate-file-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px 8px 46px;
  font-size: 11px;
  border-top: 1px solid var(--border-base);
  transition: background 0.15s;
}

.duplicate-file-row:hover {
  background: var(--bg-card-hover);
}

.duplicate-file-row .drive-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.duplicate-file-row .drive-indicator .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.duplicate-file-row .file-path {
  flex: 1;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.duplicate-file-row .file-date {
  color: var(--text-muted);
  white-space: nowrap;
}

/* ─── Export Modal ──────────────────────────────────────────────────────── */

.export-modal {
  max-width: 600px;
  width: 100%;
}

.export-drive-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 16px;
}

.export-drive-grid label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
}

.export-drive-grid input[type="checkbox"] {
  accent-color: var(--accent-primary);
}

.category-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg-input);
  border: 1px solid var(--border-base);
  cursor: pointer;
  transition: all 0.15s;
}

.category-pill.active {
  background: var(--accent-primary);
  color: #fff;
  border-color: var(--accent-primary);
}

.category-pill:not(.active):hover {
  color: var(--text-primary);
  border-color: var(--border-hover);
}

.export-mode-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
}

.export-mode-option:hover {
  background: var(--bg-card-hover);
}

.export-mode-option input[type="radio"] {
  margin-top: 2px;
  accent-color: var(--accent-primary);
  flex-shrink: 0;
}

.export-mode-option .mode-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}

.export-mode-option .mode-desc {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.row-count-estimate {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}

.row-count-estimate .count {
  font-weight: 600;
  color: var(--text-primary);
  font-family: 'JetBrains Mono', monospace;
}

.export-done-state {
  padding: 20px;
  text-align: center;
}

.export-done-state .success-icon {
  font-size: 32px;
  margin-bottom: 8px;
}

.export-done-state .success-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.export-done-state .success-detail {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

/* ─── Tags Modal ────────────────────────────────────────────────────────── */

.tags-modal {
  max-width: 480px;
  width: 100%;
}

.tag-edit-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  transition: background 0.15s;
}

.tag-edit-row:hover {
  background: var(--bg-card-hover);
}

.tag-edit-row .tag-color-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.tag-edit-row .tag-name {
  flex: 1;
  font-size: 13px;
  color: var(--text-primary);
}

.tag-edit-row .tag-actions {
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.15s;
}

.tag-edit-row:hover .tag-actions {
  opacity: 1;
}

.tag-edit-row .tag-actions button {
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 500;
  border: 1px solid var(--border-base);
  background: var(--bg-input);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
}

.tag-edit-row .tag-actions button:hover {
  color: var(--text-primary);
  border-color: var(--border-hover);
}

.tag-edit-row .tag-actions button.delete:hover {
  color: var(--accent-red);
  border-color: var(--accent-red);
}

/* File tag picker (context menu) */
.file-tag-picker {
  background: var(--bg-surface);
  border: 1px solid var(--border-base);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  padding: 8px;
  width: 200px;
}

.file-tag-picker .picker-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 8px;
  margin-bottom: 4px;
}

.file-tag-picker .picker-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 4px;
  font-size: 12px;
  color: var(--text-primary);
  cursor: pointer;
  transition: background 0.15s;
}

.file-tag-picker .picker-item:hover {
  background: var(--bg-card-hover);
}

.file-tag-picker .picker-item input[type="checkbox"] {
  accent-color: var(--accent-primary);
  width: 14px;
  height: 14px;
}

/* ─── Duplicate Drive Selection ─────────────────────────────────────────── */

.dup-drive-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 16px;
}

.dup-drive-grid label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
}

.dup-drive-grid input[type="checkbox"] {
  accent-color: var(--accent-primary);
}

/* ─── Feature Carousel ──────────────────────────────────────────────────── */

.showcase-carousel-section {
  padding: 60px 0 32px;
}

.carousel-header {
  text-align: center;
  margin-bottom: 32px;
  transition: opacity 200ms ease;
}

.carousel-header.fading {
  opacity: 0;
}

.carousel-header .showcase-label {
  justify-content: center;
}

.carousel-header .showcase-desc {
  margin-left: auto;
  margin-right: auto;
}

.carousel-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
}

.carousel-viewport {
  overflow: hidden;
  flex: 1;
  min-width: 0;
}

.carousel-track {
  display: flex;
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  opacity: 0.3;
  transition: opacity 500ms ease;
}

.carousel-slide.active {
  pointer-events: auto;
  opacity: 1;
}

/* Arrow buttons */
.carousel-arrow {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--border-base);
  background: var(--bg-secondary);
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 2;
}

.carousel-arrow:hover:not(:disabled) {
  background: var(--bg-tertiary, var(--bg-secondary));
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

.carousel-arrow:disabled {
  opacity: 0.25;
  cursor: default;
}

.carousel-arrow svg {
  width: 20px;
  height: 20px;
}

/* Indicator dots with labels */
.carousel-indicators {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  flex-wrap: wrap;
}

.carousel-dot {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-base);
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.carousel-dot:hover {
  color: var(--text-primary);
  border-color: var(--text-secondary);
}

.carousel-dot.active {
  background: var(--accent-primary);
  color: #fff;
  border-color: var(--accent-primary);
}

/* ─── Carousel Responsive ───────────────────────────────────────────────── */

@media (max-width: 768px) {
  .showcase-carousel-section {
    padding: 40px 0 24px;
  }

  .carousel-header {
    margin-bottom: 20px;
  }

  .carousel-header .showcase-title {
    font-size: 1.25rem;
  }

  .carousel-header .showcase-desc {
    font-size: 13px;
  }

  .carousel-wrapper {
    gap: 0;
    position: relative;
    overflow: hidden;
  }

  .carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    background: var(--bg-secondary);
    opacity: 0.9;
    z-index: 10;
  }

  .carousel-arrow-prev {
    left: 4px;
  }

  .carousel-arrow-next {
    right: 4px;
  }

  /* Scale down demo content to fit mobile screens */
  .carousel-slide {
    transform-origin: top center;
    overflow: hidden;
  }

  .carousel-slide .app-frame,
  .carousel-slide .modal-frame,
  .carousel-slide .settings-modal,
  .carousel-slide .search-modal,
  .carousel-slide [data-content-search-demo] .modal-frame {
    max-width: 100% !important;
    width: 100% !important;
    font-size: 11px;
  }

  /* Search slide — constrain everything inside */
  .carousel-slide [data-content-search-demo] {
    max-width: 100%;
    overflow: hidden;
  }

  .carousel-slide .search-modal {
    max-width: 100% !important;
    width: 100% !important;
  }

  .carousel-slide .search-modal .search-options {
    flex-wrap: wrap;
  }

  /* Sort bar: wrap buttons instead of overflowing */
  .carousel-slide .search-modal [style*="display:flex"][style*="gap:4px"] {
    flex-wrap: wrap !important;
  }

  /* Hide tag/date filter buttons on mobile to save space */
  .carousel-slide .search-modal [data-file-type-filter] {
    display: none !important;
  }

  .carousel-slide .stats-bar {
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 12px;
    font-size: 11px;
  }

  .carousel-slide .stats-bar-right {
    display: none;
  }

  .carousel-slide .toolbar {
    flex-direction: column;
    gap: 8px;
    padding: 8px 12px;
  }

  .carousel-slide .toolbar-right {
    flex-wrap: wrap;
  }

  .carousel-slide .drive-grid {
    grid-template-columns: 1fr;
  }

  .carousel-slide .drive-card {
    padding: 12px;
  }

  .carousel-slide .file-row {
    font-size: 11px;
  }

  .carousel-slide .file-date {
    display: none;
  }

  .carousel-slide .side-panel-wrapper.open {
    width: 200px;
  }

  .carousel-slide .side-panel-inner {
    width: 200px;
  }

  /* Tags/Export flex layouts stack on mobile */
  .carousel-slide > div[style*="display:flex"][style*="gap:32px"] {
    flex-direction: column !important;
    align-items: center !important;
  }

  .carousel-indicators {
    gap: 6px;
  }

  .carousel-dot {
    padding: 6px 8px;
    font-size: 0;
    width: 10px;
    height: 10px;
    border-radius: 50%;
  }

  .carousel-dot.active {
    width: auto;
    height: auto;
    font-size: 12px;
    border-radius: 999px;
    padding: 6px 14px;
  }
}

/* ─── Responsive Overrides ───────────────────────────────────────────────── */

@media (max-width: 768px) {
  .drive-grid {
    grid-template-columns: 1fr;
  }

  .donut-section {
    flex-direction: column;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .detail-header {
    flex-direction: column;
    text-align: center;
  }

  .pricing-card {
    max-width: 100%;
    padding: 28px 20px;
  }

  .faq-list {
    max-width: 100%;
  }

  .footer .container {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .side-panel-wrapper.open {
    width: 260px;
  }

  .side-panel-inner {
    width: 260px;
  }

  .search-modal-expandable {
    width: 95vw;
  }

  .search-modal-expandable.panel-open {
    width: 95vw;
  }

  /* Map frame */
  .map-frame {
    max-width: 100% !important;
  }

  .map-header {
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 12px;
  }

  /* Settings modal */
  .settings-modal {
    max-width: 100% !important;
  }

  .settings-modal .toggle-group {
    flex-wrap: wrap;
  }

  /* Pricing grid stacks on mobile */
  #pricing .container > div[style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
  }

  /* Tags/Export flex layouts stack on mobile */
  .tags-modal,
  .export-modal {
    max-width: 100% !important;
    width: 100% !important;
  }
}
