/* CSS Reset and Base Styles */
*,
:after,
:before {
  box-sizing: border-box;
}

body,
div,
dl,
dt,
dd,
ul,
ol,
li,
h1,
h2,
h3,
h4,
h5,
h6,
pre,
code,
form,
fieldset,
legend,
input,
textarea,
p,
blockquote,
th,
td,
hr,
button,
article,
aside,
details,
figcaption,
figure,
footer,
header,
menu,
nav,
section {
  margin: 0;
  padding: 0;
}

article,
aside,
details,
figcaption,
figure,
footer,
header,
menu,
nav,
section {
  display: block;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

audio,
canvas,
video {
  display: inline-block;
}

fieldset,
img {
  border: 0;
}

ol,
ul {
  list-style: none;
}

abbr,
acronym {
  border: 0;
  font-variant: normal;
}

sup {
  vertical-align: text-top;
}

sub {
  vertical-align: text-bottom;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
}

a {
  text-decoration: none;
  outline: none;
  color: #333;
}

body {
  position: relative;
  background: #fff;
  font-family: 'PingFangSC-Regular', 'Microsoft YaHei', 'Segoe UI',
  'Lucida Grande', Helvetica, Arial, FreeSans, Arimo, 'Droid Sans',
  'wenquanyi micro hei', 'Hiragino Sans GB', 'Hiragino Sans GB W3',
  FontAwesome, sans-serif;
  color: #333;
  font-size: 14px !important;
}

body,
html {
  min-height: 100%;
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
  background-color: #f5f5f5;
}

::-webkit-scrollbar-track {
  border-radius: 10px;
  background-color: #f5f5f5;
  -webkit-box-shadow: inset 0 0 3px rgba(0,0,0,0.1);
}

::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background-color: rgba(0, 0, 0, 0.2);
}

/* Utility Classes */
.am-cf:after,
.am-cf:before {
  content: ' ';
  display: table;
}

.am-cf:after {
  clear: both;
}

.am-fl {
  float: left;
}

.am-fr {
  float: right;
}

.am-block {
  display: block;
}

.am-inline {
  display: inline;
}

.am-inline-block {
  display: inline-block;
}

.am-align-center {
  text-align: center;
}

.am-w-100 {
  width: 100%;
}

.am-wh-100 {
  width: 100%;
  height: 100%;
}

.am-text-eill {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.am-text-break {
  white-space: normal;
  word-break: break-all;
}

.am-flex-rc-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.am-flex-rc-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.am-flex-rc-around {
  display: flex;
  align-items: center;
  justify-content: space-around;
}

.am-flex-col-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.am-flex-row-center {
  display: flex;
  align-items: center;
}

.do-main-container {
  max-width: 1200px;
  margin: 15px auto 0;
  background-color: #fff;
}

#app {
  min-height: 100vh;
}

/* Sponsor Banner Styles */
.sponsor-banner {
  background: linear-gradient(-45deg, 
    #667eea 0%,     /* 蓝紫色 */
    #764ba2 12.5%,  /* 深紫色 */
    #f093fb 25%,    /* 粉紫色 */
    #f5576c 37.5%,  /* 珊瑚红 */
    #4facfe 50%,    /* 天蓝色 */
    #00f2fe 62.5%,  /* 青蓝色 */
    #4facfe 75%,    /* 回到天蓝 */
    #43e97b 87.5%,  /* 翠绿色 */
    #38f9d7 100%    /* 薄荷绿 */
  );
  background-size: 600% 600%;
  color: white;
  margin: 15px auto 0;
  max-width: 1200px;
  border-radius: 12px;
  box-shadow: 
    0 8px 32px rgba(102, 126, 234, 0.3), 
    0 4px 16px rgba(245, 87, 108, 0.2), 
    0 2px 8px rgba(67, 233, 123, 0.15),
    0 12px 48px rgba(56, 249, 215, 0.1);
  overflow: hidden;
  position: relative;
  animation: gradientShift 12s ease infinite;
}

.sponsor-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 2px, transparent 2px),
    radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.08) 1.5px, transparent 1.5px),
    radial-gradient(circle at 40% 80%, rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 60px 60px, 80px 80px, 100px 100px, 40px 40px;
  opacity: 0.4;
  pointer-events: none;
  animation: sparkle 10s linear infinite;
}

.sponsor-content {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  position: relative;
  z-index: 1;
}

.sponsor-text {
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
  margin: 0 8px;
}

.sponsor-text strong {
  font-weight: 600;
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3), 0 1px 3px rgba(0, 0, 0, 0.2);
}

.sponsor-text-mobile {
  font-size: 13px;
  line-height: 1.4;
  text-align: center;
  margin: 0 8px;
  display: none;
}

.sponsor-text-mobile strong {
  font-weight: 600;
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3), 0 1px 3px rgba(0, 0, 0, 0.2);
}

.sponsor-emoji {
  font-size: 16px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }
}

@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes sparkle {
  0% {
    background-position: 0px 0px, 0px 0px, 0px 0px, 0px 0px;
  }
  100% {
    background-position: 60px 60px, -80px 80px, 100px -100px, 40px 40px;
  }
}

@media (max-width: 760px) {
  .sponsor-banner {
    margin: 10px 15px 0;
    border-radius: 8px;
    box-shadow: 
      0 6px 24px rgba(102, 126, 234, 0.25), 
      0 3px 12px rgba(245, 87, 108, 0.15), 
      0 2px 6px rgba(67, 233, 123, 0.1),
      0 8px 32px rgba(56, 249, 215, 0.08);
  }
  
  .sponsor-content {
    flex-direction: row;
    padding: 10px 15px;
    justify-content: center;
    align-items: center;
  }
  
  .sponsor-text {
    display: none;
  }
  
  .sponsor-text-mobile {
    display: block;
    font-size: 12px;
    margin: 0 6px;
  }
  
  .sponsor-emoji {
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .sponsor-content {
    padding: 8px 12px;
  }
  
  .sponsor-text-mobile {
    font-size: 11px;
    margin: 0 4px;
  }
  
  .sponsor-emoji {
    font-size: 12px;
  }
}

/* Header Styles */
.header-bar {
  position: fixed;
  z-index: 500;
  left: 0;
  top: 0;
  width: 100%;
  background: #fff;
  box-shadow: 0 6px 6px 6px rgba(0,0,0,0.03);
}

.header-bar__place {
  height: 58px;
}

.header-bar__main {
  display: flex;
  max-width: 1200px;
  flex-direction: row;
  margin: 0 auto;
}

.header-bar__index {
  flex-shrink: 0;
  height: 58px;
}

.header-bar__con {
  flex: 1;
  width: 0;
  margin-left: 45px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  border-radius: 6px;
  color: #666;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.2s ease;
  position: relative;
}

.nav-item:hover {
  background: #f5f7fa;
  color: #409eff;
  transform: translateY(-1px);
}

.nav-item.active {
  background: #ecf5ff;
  color: #409eff;
  font-weight: 500;
}

.nav-item.clicked {
  background: #409eff;
  color: white;
  transform: scale(0.95);
  transition: all 0.1s ease;
}

.nav-item.nav-external::after {
  content: '↗';
  font-size: 12px;
  margin-left: 2px;
  opacity: 0.6;
}

.nav-icon {
  font-size: 16px;
  line-height: 1;
}

.nav-text {
  white-space: nowrap;
}

.header-link {
  color: #333;
}

.header-link:hover {
  color: #014196;
}

/* 移动端导航适配 */
@media (max-width: 760px) {
  .header-bar__con {
    margin-left: 15px;
  }
  
  .header-nav {
    gap: 4px;
    align-items: center;
  }
  
  .nav-item {
    padding: 6px 8px;
    font-size: 13px;
    min-height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }
  
  .nav-text {
    display: none;
  }
  
  .nav-icon {
    font-size: 18px;
    line-height: 1;
  }
}

/* Search Styles */
.main-search {
  position: sticky;
  top: 58px;
  padding: 15px 15px;
  background-color: #fff;
  z-index: 50;
}

.search-form {
  display: block;
  width: 100%;
}

.search-input-container {
  position: relative;
  display: flex;
  width: 100%;
}

.search-input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid #dcdfe6;
  border-radius: 4px 0 0 4px;
  font-size: 14px;
  outline: none;
}

.search-input:focus {
  border-color: #409eff;
}

.search-button {
  padding: 12px 20px;
  background: #409eff;
  color: white;
  border: 1px solid #409eff;
  border-radius: 0 4px 4px 0;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  min-width: 80px;
  box-sizing: border-box;
}

.search-button:hover {
  background: #66b1ff;
}

.suggestions-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #dcdfe6;
  border-top: none;
  border-radius: 0 0 4px 4px;
  max-height: 200px;
  overflow-y: auto;
  z-index: 1000;
}

.suggestion-item {
  padding: 10px 16px;
  cursor: pointer;
  border-bottom: 1px solid #f5f5f5;
}

.suggestion-item:hover {
  background: #f5f7fa;
}

.suggestion-item:last-child {
  border-bottom: none;
}

/* Loading Styles */
.loading-container {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.loading-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid #409eff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Result Styles */
.result-item {
  padding: 25px 15px 15px;
  color: #303133;
  border-bottom: 1px solid #e5e5e5;
}

.result-item__name {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.name-text {
  display: inline-block;
  font-size: 24px;
  font-weight: 500;
  color: #303133;
}

.name-text:hover {
  color: #409eff;
}

.result-item-right-link {
  color: #666;
  margin-left: 8px;
  text-decoration: none;
}

.result-item-right-link:hover {
  color: #409eff;
}

.result-item__author {
  margin-top: 15px;
  flex-wrap: wrap;
}

.user-name {
  display: flex;
  align-items: center;
}

.tag {
  display: inline-block;
  padding: 0 10px;
  margin-left: 15px;
  height: 32px;
  line-height: 30px;
  font-size: 12px;
  color: #909399;
  border: 1px solid #e4e7ed;
  border-radius: 4px;
  box-sizing: border-box;
  background: #f4f4f5;
}

.result-item__des {
  margin-top: 15px;
  color: #666;
  line-height: 25px;
  font-size: 15px;
}

.result-item__tag {
  margin-top: 15px;
}

.result-item-tag {
  display: inline-block;
  padding: 0 10px;
  margin-top: 8px;
  margin-right: 15px;
  height: 24px;
  line-height: 22px;
  font-size: 12px;
  color: #909399;
  border: 1px solid #e4e7ed;
  border-radius: 4px;
  background: #f4f4f5;
}

.result-empty-wrap {
  height: 100px;
  color: #ccc;
  border-top: 1px solid #ccc;
}

/* Package Detail Styles */
.package-info {
  padding: 35px 15px;
  min-height: 213px;
}

.package-info-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.package-name {
  font-size: 36px;
  color: #000;
}

.header-link-content {
  display: flex;
  border: 1px solid #e5e5e5;
  border-radius: 6px;
  overflow: hidden;
  width: fit-content;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.link-list {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: #666;
  text-decoration: none;
  font-size: 16px;
  transition: all 0.2s ease;
}

.link-list:hover {
  color: #409eff;
  background-color: #f5f5f5;
}

.link-list:active {
  background-color: #e9ecef;
  transform: scale(0.95);
}

.link-list + .link-list {
  border-left: 1px solid #e5e5e5;
}

.package-info-arg {
  margin-top: 15px;
}

.package-info-des {
  margin-top: 15px;
}

.package-info-tag {
  margin-top: 15px;
  color: #606266;
}

/* Package Files Styles */
.package-list-header {
  padding: 15px 15px;
}

.package-header-name {
  font-weight: bold;
  font-size: 18px;
  color: #409eff;
}

.version-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sync-all-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: linear-gradient(135deg, #67c23a 0%, #85ce61 100%);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(103, 194, 58, 0.3);
}

.sync-all-btn:hover {
  background: linear-gradient(135deg, #85ce61 0%, #95d475 100%);
  box-shadow: 0 4px 8px rgba(103, 194, 58, 0.4);
  transform: translateY(-1px);
}

.sync-all-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(103, 194, 58, 0.3);
}

.sync-all-btn:disabled {
  background: #c0c4cc;
  color: #909399;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.sync-icon {
  font-size: 14px;
  animation: pulse-icon 2s infinite;
}

.sync-text {
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 120px;
}

@keyframes pulse-icon {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

.sync-all-btn.syncing {
  animation: sync-progress 0.3s ease;
}

@keyframes sync-progress {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(103, 194, 58, 0.5);
  }
  100% {
    transform: scale(1);
  }
}

.version-select {
  padding: 8px 12px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  background: white;
  min-width: 120px;
}

.files-wrap {
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  border: 1px solid #e1e8ed;
  overflow: hidden;
  overflow-x: hidden;
  margin: 20px 0;
  position: relative;
}

.files-wrap::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #409eff 0%, #67c23a 50%, #e6a23c 100%);
}

.files-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
}

.files-table th,
.files-table td {
  padding: 16px 20px;
  text-align: left;
  border-bottom: 1px solid #f0f2f5;
  transition: all 0.2s ease;
}

.files-table th {
  background: linear-gradient(135deg, #f8fafe 0%, #f0f6ff 100%);
  font-weight: 600;
  color: #2c3e50;
  font-size: 14px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border-bottom: 2px solid #409eff;
  position: relative;
}

.files-table th::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #409eff 0%, transparent 100%);
}

.files-table tbody tr {
  transition: all 0.3s ease;
  border-left: 3px solid transparent;
}

.files-table tbody tr:hover:not(.file-highlighted) {
  background: linear-gradient(135deg, #f8fafe 0%, #f0f6ff 100%);
  border-left-color: #409eff;
  transform: translateX(2px);
  box-shadow: 0 2px 8px rgba(64, 158, 255, 0.1);
}

.files-table tr:nth-child(even) {
  background: #fafbfc;
}

  .files-table tbody tr:nth-child(even):hover:not(.file-highlighted) {
    background: linear-gradient(135deg, #f8fafe 0%, #f0f6ff 100%);
  }

/* 文件高亮样式 */
.files-table tbody tr.file-highlighted {
  background-color: #fff3cd !important;
  border-left: 4px solid #ffc107 !important;
  transition: all 0.3s ease !important;
}

/* 高亮文件的悬停效果 */
.files-table tbody tr.file-highlighted:hover {
  background-color: #fff3cd !important;
  border-left-color: #ff9500 !important;
}

/* 高亮指示器 - 暂时禁用 */
.files-table tbody tr.file-highlighted::before {
  display: none;
}

@keyframes pulseIndicator {
  0%, 100% { opacity: 0.7; transform: translateY(-50%) scale(1); }
  50% { opacity: 1; transform: translateY(-50%) scale(1.1); }
}

.file-name {
  display: inline-block;
  padding: 4px 8px;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: 13px;
  font-weight: 500;
  color: #333;
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  transition: all 0.2s ease;
  cursor: pointer;
  vertical-align: top;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

.file-name::before {
  display: none;
}

.file-name:hover {
  background: #e9ecef;
  border-color: #adb5bd;
  transform: translateY(-1px);
}

.file-name:active {
  background: #6c757d;
  color: white;
  border-color: #6c757d;
  transform: translateY(0);
}

.file-name:hover::before {
  left: 100%;
}

.sri-indicator {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  pointer-events: none;
  display: inline;
  margin-left: 8px;
  flex-shrink: 0;
  white-space: nowrap;
}

.sri-indicator span {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  transition: opacity 0.2s ease;
}

.sri-indicator:hover span {
  opacity: 0.7;
}

/* 文件名容器的布局优化 */
.files-table td:first-child {
  display: table-cell;
  vertical-align: middle;
  word-wrap: break-word;
  word-break: break-all;
}

.file-wrap-bot {
  padding: 20px;
  background: linear-gradient(135deg, #f8fafe 0%, #f0f6ff 100%);
  border-top: 1px solid #e1e8ed;
  margin: 0;
}

.text-button {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border: 1px solid #dee2e6;
  color: #495057;
  cursor: pointer;
  font-size: 14px;
  padding: 12px 24px;
  border-radius: 8px;
  width: 100%;
  max-width: 300px;
  transition: all 0.3s ease;
  font-weight: 500;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.text-button:hover {
  background: linear-gradient(135deg, #409eff 0%, #66b1ff 100%);
  color: white;
  border-color: #409eff;
  box-shadow: 0 4px 12px rgba(64, 158, 255, 0.3);
  transform: translateY(-1px);
}

.text-button:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(64, 158, 255, 0.2);
}

.text-button svg {
  flex-shrink: 0;
}

/* 响应式样式 */
@media (max-width: 768px) {
  .text-button {
    font-size: 13px;
    padding: 10px 16px;
    max-width: 280px;
  }
  
  .files-wrap {
    border-radius: 8px;
    margin: 15px 0;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.1);
  }
  
  .files-table {
    display: table;
    width: 100%;
  }
  
  .files-table th,
  .files-table td {
    padding: 12px 8px;
    vertical-align: middle;
  }
  
  .files-table th {
    font-size: 12px;
    text-align: center;
  }
  
  /* 确保第一列（文件）占更多空间 */
  .files-table th:first-child,
  .files-table td:first-child {
    width: 60%;
    text-align: left;
  }
  
  /* 确保第二列（操作）固定宽度，左对齐 */
  .files-table th:last-child,
  .files-table td:last-child {
    width: 40%;
    text-align: left;
  }
  
  .files-table tbody tr:hover:not(.file-highlighted) {
    transform: none;
  }
  
  .file-name {
    padding: 3px 6px;
    font-size: 12px;
    word-break: break-all;
    display: inline-block;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 3px;
    color: #333;
    cursor: pointer;
  }
  
  .file-name:hover {
    background: #e9ecef;
    border-color: #adb5bd;
    transform: translateY(-1px);
  }
  
  .file-name:active {
    background: #6c757d;
    color: white;
    border-color: #6c757d;
    transform: translateY(0);
  }
  
  /* 移动端高亮指示器调整 - 暂时禁用 */
  .files-table tbody tr.file-highlighted::before {
    display: none;
  }
  
  /* 中等屏幕按钮优化 */
  .btn {
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 2px 2px 2px 0;
    vertical-align: top;
    font-size: 11px;
    padding: 6px 8px;
  }
  
  /* 确保按钮容器在中等屏幕保持左对齐 */
  .files-table td:last-child {
    display: table-cell;
    text-align: left;
    vertical-align: middle;
    white-space: nowrap;
  }
}

.btn {
  display: inline-block;
  padding: 8px 15px;
  margin-right: 8px;
  font-size: 14px;
  border-radius: 4px;
  border: 1px solid #dcdfe6;
  background: #fff;
  color: #606266;
  cursor: pointer;
  text-decoration: none;
  box-sizing: border-box;
  vertical-align: middle;
}

.btn:hover {
  color: #409eff;
  border-color: #c6e2ff;
  background: #ecf5ff;
}

.btn-primary {
  color: #409eff;
  border-color: #409eff;
}

.btn-primary:hover {
  background: #409eff;
  color: white;
}

.btn-sync {
  color: #e6a23c;
  border-color: #e6a23c;
  background: #fdf6ec;
}

.btn-sync:hover {
  background: #e6a23c;
  color: white;
  border-color: #e6a23c;
}

/* SRI Status Styles */
.sri-status {
  padding: 12px 15px;
  margin: 0 15px 15px;
  border-radius: 6px;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  line-height: 1.4;
}

.sri-status .sri-icon {
  font-size: 16px;
  margin-right: 4px;
}

.sri-status small {
  display: block;
  font-size: 12px;
  opacity: 0.8;
  margin-top: 2px;
}

.sri-status-full {
  background: #f0f9ff;
  border: 1px solid #67c23a;
  color: #67c23a;
}

.sri-status-partial {
  background: #fdf6ec;
  border: 1px solid #e6a23c;
  color: #e6a23c;
}

.sri-status-none {
  background: #fef0f0;
  border: 1px solid #f56c6c;
  color: #f56c6c;
}

.sri-status-loading {
  background: #f0f9ff;
  border: 1px solid #409eff;
  color: #409eff;
}

.sri-status-info {
  background: #fffbf0;
  border: 1px solid #e6a23c;
  color: #e6a23c;
}

/* Suggestions Loading Animation */
.suggestion-loading, .suggestion-error, .suggestion-empty {
  padding: 12px 15px;
  display: flex;
  align-items: center;
  color: #666;
  font-size: 14px;
  border-bottom: 1px solid #eee;
}

.suggestion-loading .loading-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid #409eff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  flex-shrink: 0;
}

.suggestion-error {
  color: #f56c6c;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* File Status Loading Containers */
.btn-loading-container, .btn-syncing-container {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 15px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #f9f9f9;
  color: #666;
  font-size: 14px;
  min-width: 120px;
  height: 36px;
  box-sizing: border-box;
  margin: 2px 4px 2px 0;
  vertical-align: top;
}

.btn-syncing-container {
  border-color: #409eff;
  background: #ecf5ff;
  color: #409eff;
}

.loading-spinner-small {
  width: 14px;
  height: 14px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid #666;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  flex-shrink: 0;
}

.btn-syncing-container .loading-spinner-small {
  border-top-color: #409eff;
}

/* Footer Styles */
.page-footer {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-top: 1px solid #e5e5e5;
  margin-top: 60px;
  padding: 40px 0 20px;
  color: #666;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 30px;
}

.footer-section {
  display: flex;
  flex-direction: column;
}

.footer-title {
  margin: 0 0 15px 0;
  font-size: 16px;
  font-weight: 600;
  color: #333;
}

.footer-desc {
  margin: 0 0 15px 0;
  line-height: 1.6;
  color: #666;
  font-size: 14px;
}

.footer-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-stat {
  background: #e3f2fd;
  color: #1976d2;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-link {
  color: #666;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s ease;
  display: inline-block;
}

.footer-link:hover {
  color: #409eff;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  border-top: 1px solid #e5e5e5;
  flex-wrap: wrap;
  gap: 15px;
}

.footer-copyright {
  flex: 1;
}

.footer-copyright p {
  margin: 0;
  font-size: 13px;
  color: #999;
  line-height: 1.5;
}

.footer-copyright p + p {
  margin-top: 4px;
}

.footer-link-inline {
  color: #409eff;
  text-decoration: none;
}

.footer-link-inline:hover {
  text-decoration: underline;
}

.footer-powered {
  font-weight: 500;
}

.footer-tech {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tech-badge {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  color: #6c757d;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
}

/* 响应式设计 */
@media (max-width: 968px) {
  .footer-content {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }
  
  .footer-section:nth-child(1) {
    grid-column: 1 / -1;
    order: 1;
  }
  
  .footer-section:nth-child(2) {
    order: 3;
  }
  
  .footer-section:nth-child(3) {
    order: 2;
  }
  
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .footer-tech {
    justify-content: flex-start;
  }
}

@media (max-width: 600px) {
  .page-footer {
    padding: 30px 0 15px;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  
  .footer-section:nth-child(1) {
    grid-column: 1;
    order: 1;
  }
  
  .footer-section:nth-child(2) {
    order: 3;
  }
  
  .footer-section:nth-child(3) {
    order: 2;
  }
  
  .footer-stats {
    justify-content: flex-start;
  }
}

/* Toast Message Styles */
#toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
}

.toast {
  background: #f0f9ff;
  border: 1px solid #409eff;
  border-radius: 4px;
  padding: 15px 20px;
  margin-bottom: 10px;
  box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
  animation: slideIn 0.3s ease-out;
}

.toast.warning {
  background: #fdf6ec;
  border-color: #e6a23c;
  color: #e6a23c;
}

.toast.success {
  background: #f0f9ff;
  border-color: #67c23a;
  color: #67c23a;
}

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

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.3s ease-out;
}

.modal-container {
  background: white;
  border-radius: 8px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow: hidden;
  animation: modalSlideIn 0.3s ease-out;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #ebeef5;
  background: #fafafa;
}

.modal-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #303133;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: #999;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: #f5f7fa;
  color: #409eff;
}

.modal-content {
  padding: 24px;
  overflow-y: auto;
  max-height: calc(80vh - 80px);
}

.modal-content h4 {
  margin: 0 0 12px 0;
  color: #409eff;
  font-size: 16px;
}

.modal-content p {
  margin: 0 0 16px 0;
  line-height: 1.6;
  color: #606266;
}

.modal-content ul {
  margin: 0 0 16px 0;
  padding-left: 20px;
}

.modal-content li {
  margin-bottom: 8px;
  line-height: 1.5;
  color: #606266;
}

.modal-content code {
  background: #f5f7fa;
  padding: 2px 6px;
  border-radius: 3px;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  color: #e83e8c;
}

.modal-content a {
  color: #409eff;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.2s ease;
}

.modal-content a:hover {
  color: #66b1ff;
  border-bottom-color: #409eff;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes modalSlideIn {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (max-width: 760px) {
  .modal-container {
    width: 95%;
    max-height: 90vh;
  }
  
  .modal-header {
    padding: 16px 20px;
  }
  
  .modal-content {
    padding: 20px;
    max-height: calc(90vh - 70px);
  }
}

/* Responsive Styles */
@media (max-width: 1200px) {
  .header-bar__main {
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-footer {
    padding-left: 15px;
    padding-right: 15px;
  }
}

@media (max-width: 760px) {
  .package-info-header {
    display: block;
  }
  .package-name {
    font-size: 24px;
  }
  .header-link-content {
    margin-top: 12px;
  }
  
  .link-list {
    width: 44px;
    height: 44px;
    font-size: 18px;
    flex-shrink: 0;
  }
}

@media (max-width: 768px) {
  .version-controls {
    flex-direction: column;
    gap: 8px;
    align-items: stretch;
  }
  
  .sync-all-btn {
    order: 2;
    justify-content: center;
  }
  
  .version-select {
    order: 1;
    width: 100%;
  }
  
  .package-list-header {
    flex-direction: column;
    align-items: stretch !important;
    gap: 12px;
  }
  
  .package-header-name {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .header-link-content {
    margin-top: 10px;
  }
  
  .link-list {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
  
  .file-name {
    padding: 3px 6px;
    font-size: 12px;
    border-radius: 3px;
    word-break: break-all;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #333;
    cursor: pointer;
  }
  
  .files-table th,
  .files-table td {
    padding: 8px;
    font-size: 14px;
  }
  
  .sync-all-btn {
    padding: 6px 10px;
    font-size: 12px;
    gap: 4px;
    min-width: 80px;
    justify-content: center;
  }
  
  .sync-text {
    font-size: 12px;
    max-width: 100px;
  }
  
  .sync-icon {
    font-size: 12px;
  }
  
  /* 小屏幕按钮统一样式 */
  .btn {
    display: inline-block;
    width: auto;
    margin: 1px 2px 1px 0;
    padding: 6px 8px;
    text-align: center;
    box-sizing: border-box;
    font-size: 10px;
    min-width: 50px;
    white-space: nowrap;
  }
  
  /* 小屏幕保持表格结构，确保左右对应 */
  .files-table {
    width: 100%;
    table-layout: fixed;
  }
  
  /* 确保显示状态下的表格样式 */
  .files-table:not([style*="display: none"]):not(.version-changing-hidden) {
    display: table !important;
  }
  
  /* 版本切换时强制隐藏 */
  .files-table.version-changing-hidden {
    display: none !important;
  }
  
  .files-table td:first-child {
    width: 55% !important;
    padding: 8px 4px !important;
    text-align: left !important;
    word-wrap: break-word;
  }
  
  .files-table td:last-child {
    width: 45% !important;
    padding: 8px 4px !important;
    text-align: left !important;
    vertical-align: middle !important;
    display: table-cell !important;
    white-space: nowrap;
  }
  
  .files-table th:first-child {
    width: 55% !important;
    text-align: left !important;
    padding: 8px 4px !important;
  }
  
  .files-table th:last-child {
    width: 45% !important;
    text-align: left !important;
    padding: 8px 4px !important;
  }
  
  /* 搜索区域移动端优化 */
  .search-input-container {
    align-items: stretch;
  }
  
  .search-input {
    min-height: 44px;
    box-sizing: border-box;
  }
  
  .search-button {
    min-height: 44px;
    min-width: 60px;
    padding: 8px 12px;
    font-size: 13px;
  }
  
  /* 移动端状态容器优化 */
  .btn-loading-container, .btn-syncing-container {
    margin: 1px 2px 1px 0;
    min-width: 60px;
    height: auto;
    padding: 4px 6px;
    font-size: 10px;
    white-space: nowrap;
  }
  
  /* SRI指示器在小屏幕的优化 - 保持inline，不换行 */
  .sri-indicator {
    display: inline;
    margin-left: 6px;
    font-size: 10px;
  }
}

/* Page Display */
.page {
  display: none;
}

.page.active {
  display: block;
}