.settings-section-panel {
  overflow: hidden;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18rpx;
  min-height: 104rpx;
  padding: 0 24rpx;
  border-top: 1rpx solid #edf2f7;
  box-sizing: border-box;
}

.settings-row:first-of-type {
  border-top: 0;
}

.settings-row-main {
  min-width: 0;
  flex: 1;
}

.settings-tool-row {
  min-height: 92rpx;
}

.settings-tool-row:active {
  opacity: 0.72;
}

.storage-protocol-guide-panel {
  padding: 24rpx;
}

.storage-protocol-guide-kicker {
  color: var(--accent-dark);
  font-size: 22rpx;
  line-height: 1.35;
  font-weight: 900;
}

.storage-protocol-guide-title {
  margin-top: 8rpx;
  color: #111827;
  font-size: 34rpx;
  line-height: 1.28;
  font-weight: 900;
}

.storage-protocol-guide-text {
  margin-top: 14rpx;
  color: #475569;
  font-size: 25rpx;
  line-height: 1.58;
  word-break: break-all;
}

.storage-protocol-guide-points {
  margin-top: 18rpx;
}

.storage-protocol-guide-point {
  position: relative;
  padding: 14rpx 0 14rpx 30rpx;
  border-top: 1rpx solid #edf2f7;
  color: #334155;
  font-size: 24rpx;
  line-height: 1.5;
  word-break: break-all;
}

.storage-protocol-guide-point::before {
  content: "";
  position: absolute;
  left: 4rpx;
  top: 28rpx;
  width: 10rpx;
  height: 10rpx;
  border-radius: 50%;
  background: var(--accent);
}

.storage-protocol-file-row.is-active {
  background: #effaf8;
}

.storage-protocol-file-row:active {
  opacity: 0.72;
}

.storage-protocol-file-head {
  display: flex;
  align-items: center;
  gap: 12rpx;
}

.storage-protocol-file-badge {
  flex: none;
  height: 34rpx;
  padding: 0 12rpx;
  border-radius: 999rpx;
  background: #e8f6f5;
  color: var(--accent-dark);
  font-size: 20rpx;
  line-height: 34rpx;
  font-weight: 900;
}

.storage-protocol-copy-button {
  flex: none;
  height: 50rpx;
  padding: 0 18rpx;
  border: 1rpx solid #d9edeb;
  border-radius: 999rpx;
  background: #f4fbfa;
  color: var(--accent-dark);
  font-size: 22rpx;
  line-height: 50rpx;
  font-weight: 900;
}

.storage-protocol-copy-button:active {
  opacity: 0.72;
}

.storage-protocol-detail-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16rpx;
}

.storage-protocol-detail-name {
  min-width: 0;
  flex: 1;
  color: #111827;
  font-size: 26rpx;
  line-height: 1.35;
  font-weight: 900;
  word-break: break-all;
}

.storage-protocol-detail-role {
  flex: none;
  color: #64748b;
  font-size: 22rpx;
  line-height: 1.35;
  font-weight: 800;
}

.storage-protocol-detail-body {
  padding: 22rpx 24rpx 24rpx;
}

.storage-protocol-file-location {
  padding: 14rpx 16rpx;
  border-radius: 12rpx;
  background: #f8fafc;
  color: #0f766e;
  font-family: Menlo, Monaco, Consolas, monospace;
  font-size: 22rpx;
  line-height: 1.45;
  word-break: break-all;
}

.storage-protocol-copy-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16rpx;
  margin-top: 16rpx;
}

.storage-protocol-copy-meta {
  min-width: 0;
  flex: 1;
  color: #64748b;
  font-size: 23rpx;
  line-height: 1.35;
  font-weight: 800;
}

.storage-protocol-copy-action {
  flex: none;
  width: auto;
  min-width: 170rpx;
  padding: 0 18rpx;
}

.storage-protocol-file-summary {
  margin-top: 18rpx;
  color: #334155;
  font-size: 25rpx;
  line-height: 1.55;
  word-break: break-all;
}

.storage-protocol-detail-list {
  margin-top: 16rpx;
}

.storage-protocol-detail-item {
  position: relative;
  padding: 10rpx 0 10rpx 28rpx;
  color: #475569;
  font-size: 24rpx;
  line-height: 1.5;
  word-break: break-all;
}

.storage-protocol-detail-item::before {
  content: "";
  position: absolute;
  left: 4rpx;
  top: 25rpx;
  width: 8rpx;
  height: 8rpx;
  border-radius: 50%;
  background: #94a3b8;
}

.settings-tool-main {
  min-width: 0;
  flex: 1;
  display: flex;
  align-items: center;
  gap: 14rpx;
}

.settings-tool-icon-frame {
  flex: none;
  position: relative;
  width: 34rpx;
  height: 34rpx;
  border-radius: 10rpx;
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.26) 0%, rgba(255, 255, 255, 0.1) 24%, rgba(255, 255, 255, 0) 54%),
    linear-gradient(180deg, var(--icon-start, #129a91) 0%, var(--icon-end, #08746e) 100%);
  border: 1rpx solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 8rpx 16rpx rgba(15, 143, 135, 0.14);
  overflow: hidden;
  box-sizing: border-box;
}

.settings-tool-icon-image {
  position: absolute;
  left: 6rpx;
  top: 6rpx;
  width: 22rpx;
  height: 22rpx;
}

.settings-tool-title {
  flex: 1;
  white-space: nowrap;
  word-break: keep-all;
  overflow: hidden;
  text-overflow: ellipsis;
}

.upgrade-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 286rpx;
  row-gap: 8rpx;
}

.upgrade-body {
  padding: 8rpx 24rpx 24rpx;
}

.upgrade-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20rpx;
  min-height: 62rpx;
  border-top: 1rpx solid #edf2f7;
}

.upgrade-row:first-child {
  border-top: 0;
}

.upgrade-row--file {
  display: block;
  min-height: 0;
  padding-top: 14rpx;
  padding-bottom: 14rpx;
}

.upgrade-file-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14rpx;
}

.upgrade-file-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10rpx;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.upgrade-file-meta-item {
  flex: none;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.upgrade-file-meta-item--program {
  color: var(--accent-dark);
  font-weight: 800;
}

.upgrade-file-meta-item--checksum,
.upgrade-file-meta-item--size {
  color: #64748b;
}

.upgrade-file-name {
  display: block;
  margin-top: 8rpx;
  color: #111827;
  font-size: 24rpx;
  line-height: 1.35;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.upgrade-label {
  flex: none;
  color: #64748b;
  font-size: 24rpx;
  line-height: 1.35;
}

.upgrade-value {
  min-width: 0;
  flex: 1;
  color: #111827;
  font-size: 24rpx;
  line-height: 1.35;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upgrade-status {
  margin-top: 14rpx;
  padding: 14rpx 16rpx;
  border-radius: 12rpx;
  background: #f8fafc;
  color: #64748b;
  font-size: 23rpx;
  line-height: 1.45;
  font-weight: 700;
  word-break: break-all;
}

.upgrade-status--ready {
  background: #effaf8;
  color: var(--accent-dark);
}

.upgrade-progress {
  position: relative;
  height: 14rpx;
  margin-top: 16rpx;
  border-radius: 999rpx;
  background: #e5e7eb;
  overflow: hidden;
}

.upgrade-progress-bar {
  height: 100%;
  min-width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #10b981 0%, #0f8f87 100%);
  transition: width 0.18s ease;
}

.theme-dark .upgrade-file-meta-item--checksum,
.theme-dark .upgrade-file-meta-item--size,
.theme-dark .upgrade-file-name {
  color: #cbd5e1;
}

.theme-dark .upgrade-file-meta-item--program {
  color: #5eead4;
}

.theme-dark .upgrade-progress {
  background: #263241;
}

.theme-dark .upgrade-progress-bar {
  background: linear-gradient(90deg, #2dd4bf 0%, #14b8a6 100%);
}

.settings-input-wrap {
  flex: none;
  display: flex;
  align-items: center;
  gap: 10rpx;
}

.settings-input-wrap--unit {
  position: relative;
}

.settings-picker-value {
  width: 300rpx;
  min-width: 300rpx;
  max-width: 300rpx;
  height: 70rpx;
  color: #111827;
  font-size: 28rpx;
  line-height: 70rpx;
  font-weight: 800;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  box-sizing: border-box;
}

.settings-value-input {
  width: 300rpx;
}

.settings-value-input--hex {
  width: 300rpx;
}

.settings-value-input--unit {
  padding-right: 62rpx;
}

.settings-unit {
  flex: none;
  color: #64748b;
  font-size: 23rpx;
  line-height: 1.35;
  font-weight: 700;
}

.settings-unit--inside {
  position: absolute;
  right: 18rpx;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

.theme-dark .settings-row {
  border-color: #263241;
}

.theme-dark .storage-protocol-guide-title,
.theme-dark .storage-protocol-detail-name {
  color: #e5e7eb;
}

.theme-dark .storage-protocol-guide-text,
.theme-dark .storage-protocol-guide-point,
.theme-dark .storage-protocol-file-summary,
.theme-dark .storage-protocol-detail-item {
  color: #cbd5e1;
}

.theme-dark .storage-protocol-guide-point {
  border-color: #263241;
}

.theme-dark .storage-protocol-file-row.is-active {
  background: #102f2e;
}

.theme-dark .storage-protocol-file-badge {
  background: #123d3b;
  color: #5eead4;
}

.theme-dark .storage-protocol-copy-button {
  border-color: #174e49;
  background: #123d3b;
  color: #99f6e4;
}

.theme-dark .storage-protocol-detail-role {
  color: #94a3b8;
}

.theme-dark .storage-protocol-file-location {
  background: #111827;
  color: #5eead4;
}

.theme-dark .storage-protocol-copy-meta {
  color: #94a3b8;
}

.theme-dark .settings-unit {
  color: #94a3b8;
}

.theme-dark .settings-picker-value {
  color: #e5e7eb;
}

@media (max-width: 360px) {
  .settings-picker-value {
    width: 260rpx;
    min-width: 260rpx;
    max-width: 260rpx;
  }

  .settings-value-input {
    width: 260rpx;
  }

  .settings-value-input--hex {
    width: 260rpx;
  }
}
