/* SERtool search page-specific styles */

    .container { max-width: 960px; margin: 0 auto; padding: 0 20px; }

    .page-header {
      margin: 32px auto 0;
      padding: 24px 28px;
      background: linear-gradient(135deg, #14304f 0%, #1c4a76 50%, #266a9c 100%);
      border-radius: 12px;
      color: white;
      box-shadow: 0 6px 20px rgba(20, 48, 79, 0.18);
      text-align: center;
    }
    .page-title {
      font-size: 24px;
      color: #ffffff;
      margin: 0 0 8px;
      font-weight: 700;
      text-shadow: 0 1px 10px rgba(0, 20, 45, 0.5);
    }
    .page-sub {
      font-size: 14px;
      color: #dbeafe;
      text-shadow: 0 1px 6px rgba(0, 20, 45, 0.4);
      margin: 0 auto;
      max-width: 780px;
      line-height: 1.7;
    }
    .page-sub strong { color: #ffffff; }

    /* ========== 搜索区 ========== */
    .search-container {
      margin: 20px auto 0;
      padding: 20px 24px;
      background: #ffffff;
      border-radius: 12px;
      box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
      border: 1px solid #e2e8f0;
    }
    .search-box {
      display: flex;
      gap: 10px;
      align-items: center;
      flex-wrap: nowrap;
    }
    .search-options {
      display: flex;
      gap: 14px;
      align-items: center;
      flex-shrink: 0;
      padding-right: 6px;
    }
    .radio-label {
      display: flex;
      align-items: center;
      gap: 6px;
      cursor: pointer;
      font-size: 14px;
      color: #4a5568;
      user-select: none;
      transition: color 0.2s;
      font-weight: 500;
      white-space: nowrap;
    }
    .radio-label:hover { color: #2b6cb0; }
    .radio-label input[type="radio"] { accent-color: #1a365d; width: 15px; height: 15px; cursor: pointer; margin: 0; }

    .search-box input[type="text"] {
      flex: 1;
      min-width: 0;
      padding: 13px 18px;
      border: 1px solid #cbd5e0;
      border-radius: 8px;
      font-size: 15px;
      outline: none;
      transition: all 0.25s ease;
      background-color: #f8fafc;
      color: #2d3748;
    }
    .search-box input[type="text"]:focus {
      border-color: #3182ce;
      background-color: #ffffff;
      box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.15);
    }
    .search-box button {
      background-color: #1a365d;
      color: white;
      border: none;
      padding: 13px 28px;
      font-size: 15px;
      font-weight: 600;
      cursor: pointer;
      border-radius: 8px;
      transition: all 0.2s;
      box-shadow: 0 4px 12px rgba(26, 54, 93, 0.25);
      flex-shrink: 0;
    }
    .search-box button:hover:not(:disabled) {
      background-color: #2c5282;
      transform: translateY(-1px);
      box-shadow: 0 6px 16px rgba(26, 54, 93, 0.3);
    }
    .search-box button:disabled {
      background-color: #a0aec0;
      cursor: not-allowed;
      transform: none;
      box-shadow: none;
    }

    .search-examples {
      margin-top: 14px;
      color: #718096;
      font-size: 13px;
      text-align: center;
      opacity: 0.95;
    }
    .search-examples span {
      margin: 0 4px;
      background-color: #ebf8ff;
      padding: 3px 10px;
      border-radius: 12px;
      font-family: monospace;
      color: #2c5282;
      cursor: pointer;
      transition: all 0.2s ease;
      display: inline-block;
      border: 1px solid #bee3f8;
    }
    .search-examples span:hover {
      background-color: #bee3f8;
      color: #1a365d;
      transform: translateY(-1px);
      box-shadow: 0 2px 4px rgba(49, 130, 206, 0.2);
    }

    /* ========== 说明卡片 ========== */
    .legend-container { margin: 16px auto 0; }
    .legend-box {
      background: #f0f7ff;
      color: #2d3748;
      padding: 14px 18px;
      font-size: 13.5px;
      border-radius: 10px;
      border: 1px solid #dbeafe;
      line-height: 1.7;
    }
    .legend-box strong { color: #1a365d; }
    .legend-box .chip {
      display: inline-block;
      padding: 2px 8px;
      border-radius: 4px;
      font-size: 12px;
      font-weight: 600;
      margin-right: 2px;
    }
    .chip-gray { background: #eaeaea; color: #4a5568; }
    .chip-red { background: #ffebee; color: #c53030; }
    .legend-box .legend-tag {
      display: inline-block;
      background: #ebf8ff;
      color: #2c5282;
      padding: 1px 8px;
      border-radius: 4px;
      font-family: monospace;
      font-size: 12.5px;
      border: 1px solid #bee3f8;
      margin: 0 2px;
    }

    #results { margin-top: 20px; display: none; }
    #results.force-visible { display: block !important; }

    .results-frame {
      background-color: #ffffff;
      border: 1px solid #e2e8f0;
      border-radius: 12px;
      box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
      overflow: hidden;
      padding: 0;
      margin: 0 auto;
    }

    .results-header {
      padding: 16px 20px;
      background: linear-gradient(135deg, #14304f 0%, #1c4a76 60%, #266a9c 100%);
      color: #ffffff;
      font-size: 15px;
      font-weight: 600;
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
      letter-spacing: 0.02em;
    }
    #result-count { color: #ffffff; }

    .result-filter-area {
      width: 100%;
      padding: 14px 20px;
      background: #f8fafc;
      border-bottom: 1px solid #edf2f7;
      display: flex;
      align-items: center;
      gap: 12px;
      flex-wrap: wrap;
    }
    .filter-input-group {
      display: flex;
      align-items: center;
      flex: 1;
      min-width: 200px;
      position: relative;
    }
    .filter-input-group input {
      width: 100%;
      padding: 8px 12px 8px 32px;
      border: 1px solid #cbd5e0;
      border-radius: 6px;
      font-size: 13.5px;
      outline: none;
      transition: border-color 0.2s, box-shadow 0.2s;
      background: #ffffff;
      color: #2d3748;
    }
    .filter-input-group input:focus {
      border-color: #3182ce;
      box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.15);
    }
    .filter-icon {
      position: absolute;
      left: 10px;
      color: #718096;
      font-size: 13px;
      pointer-events: none;
    }

    .nmd-filter-container {
      display: flex;
      align-items: center;
      gap: 8px;
      padding-left: 12px;
      border-left: 1px solid #e2e8f0;
    }
    .nmd-filter-label { font-size: 13.5px; color: #4a5568; white-space: nowrap; font-weight: 600; }
    .nmd-filter-select {
      padding: 7px 12px;
      border: 1px solid #cbd5e0;
      border-radius: 6px;
      background-color: white;
      font-size: 13.5px;
      outline: none;
      cursor: pointer;
      min-width: 160px;
      color: #2d3748;
      transition: border-color 0.2s, box-shadow 0.2s;
    }
    .nmd-filter-select:focus {
      border-color: #3182ce;
      box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.15);
    }

    .filter-count-info { font-size: 12.5px; color: #64748b; white-space: nowrap; }

    .action-btn {
      background-color: #1a365d;
      color: white;
      border: none;
      border-radius: 6px;
      padding: 7px 14px;
      font-size: 13px;
      font-weight: 600;
      cursor: pointer;
      display: inline-flex;
      align-items: center;
      gap: 4px;
      transition: all 0.2s ease;
      margin-left: 4px;
      box-shadow: 0 2px 6px rgba(26, 54, 93, 0.15);
    }
    .action-btn:hover:not(:disabled) {
      background-color: #2c5282;
      transform: translateY(-1px);
      box-shadow: 0 4px 10px rgba(26, 54, 93, 0.25);
    }
    .action-btn:disabled { background-color: #a0aec0; cursor: not-allowed; opacity: 0.75; transform: none; box-shadow: none; }

    .results-controls { margin-left: auto; display: flex; gap: 8px; flex-wrap: nowrap; }

    .results-table-container {
      overflow-y: auto;
      padding: 14px 20px;
      margin: 0;
      max-width: 100%;
      overflow-x: auto;
      min-height: 50px;
    }

    .results-table-container table { width: 100%; border-collapse: separate; border-spacing: 0 8px; font-size: 13px; table-layout: fixed; }
    .header-row td:first-child { width: 36px; text-align: center; padding: 0; }
    .header-row td:nth-child(2) { width: calc(100% - 36px); padding: 12px 14px; word-wrap: break-word; white-space: normal; vertical-align: middle; }
    .header-row {
      background-color: #ffffff;
      cursor: pointer;
      transition: box-shadow 0.15s, background-color 0.15s;
    }
    .header-row td {
      border-top: 1px solid #edf2f7;
      border-bottom: 1px solid #edf2f7;
    }
    .header-row td:first-child { border-left: 1px solid #edf2f7; border-radius: 8px 0 0 8px; }
    .header-row td:last-child { border-right: 1px solid #edf2f7; border-radius: 0 8px 8px 0; }
    .header-row:hover { background-color: #ebf8ff; box-shadow: 0 2px 8px rgba(49, 130, 206, 0.1); }
    .header-row:hover td { border-color: #bee3f8; }

    .detail-row { background-color: transparent !important; }
    .detail-row td { padding: 0 !important; border: none !important; }

    .toggle-icon {
      cursor: pointer;
      color: #1a365d;
      font-size: 0.85em;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 22px;
      height: 22px;
      border-radius: 50%;
      background-color: #ebf8ff;
      transition: all 0.2s ease;
      box-shadow: 0 1px 2px rgba(0,0,0,0.06);
      border: 1px solid #bee3f8;
    }
    .toggle-icon:hover { background-color: #11999E; color: white; border-color: #11999E; transform: scale(1.08); }

    .detail-card {
      margin: 4px 0 12px;
      padding: 14px 16px;
      background-color: #f8fafc;
      border: 1px solid #e2e8f0;
      border-radius: 10px;
      font-size: 13px;
      width: 100%;
      box-sizing: border-box;
      overflow: hidden;
    }
    .detail-header {
      font-size: 13.5px;
      font-weight: 600;
      margin-bottom: 10px;
      padding: 8px 12px;
      color: #1a365d;
      word-wrap: break-word !important;
      overflow-wrap: break-word !important;
      white-space: pre-wrap !important;
      line-height: 1.5;
      background: #ebf8ff;
      border-radius: 6px;
      border-left: 3px solid #3182ce;
      font-family: monospace;
    }

    .detail-card table { width: 100%; table-layout: fixed !important; border-collapse: collapse !important; font-size: 12px; border: 1px solid #e2e8f0 !important; border-radius: 6px; overflow: hidden; }
    .detail-card th, .detail-card td { border: 1px solid #e2e8f0 !important; padding: 8px 10px !important; text-align: left !important; vertical-align: top !important; word-wrap: break-word !important; overflow-wrap: break-word !important; white-space: normal !important; background-color: #ffffff !important; color: #334155; }
    .detail-card th { background-color: #1a365d !important; color: #ffffff !important; font-weight: 600 !important; font-size: 12px !important; letter-spacing: 0.02em; }
    .detail-card tr:last-child td { border-bottom: none !important; }

    .detail-card th:nth-child(1), .detail-card td:nth-child(1) { width: 10% !important; }
    .detail-card th:nth-child(2), .detail-card td:nth-child(2) { width: 25% !important; }
    .detail-card th:nth-child(3), .detail-card td:nth-child(3) { width: 20% !important; }
    .detail-card th:nth-child(4), .detail-card td:nth-child(4) { width: 10% !important; }
    .detail-card th:nth-child(5), .detail-card td:nth-child(5) { width: 10% !important; }
    .detail-card th:nth-child(6), .detail-card td:nth-child(6) { width: 20% !important; }

    .sequence {
      white-space: pre-wrap !important;
      word-wrap: break-word !important;
      overflow-wrap: break-word !important;
      background-color: #ffffff;
      border: 1px solid #e2e8f0;
      border-radius: 6px;
      font-family: 'Monaco','Menlo','Courier New',monospace;
      font-size: 12px;
      line-height: 1.55;
      padding: 10px 12px;
      margin: 4px 0 0;
      display: block;
      width: 100%;
      box-sizing: border-box;
      color: #2d3748;
    }

    .results-empty {
      text-align: center;
      padding: 32px 20px;
      color: #718096;
      font-size: 15px;
      font-style: italic;
      background-color: #f8fafc;
      border-radius: 8px;
    }
    .results-error {
      color: #c53030;
      padding: 14px 18px;
      background-color: #fff5f5;
      border-radius: 8px;
      margin: 8px 0;
      border: 1px solid #feb2b2;
      border-left: 4px solid #e53e3e;
      font-size: 14px;
    }
    .loading-state {
      text-align: center;
      padding: 32px 20px;
      color: #2b6cb0;
      font-weight: 500;
      background: #f8fafc;
      border-radius: 8px;
      font-size: 14px;
    }

    /* ========== 分页 ========== */
    .pagination-container {
      display: flex;
      justify-content: center;
      align-items: center;
      gap: 6px;
      padding: 16px 20px 20px;
      flex-wrap: wrap;
      background: #f8fafc;
      border-top: 1px solid #edf2f7;
    }
    .page-btn {
      background-color: white;
      border: 1px solid #cbd5e0;
      color: #4a5568;
      padding: 6px 12px;
      border-radius: 6px;
      cursor: pointer;
      font-size: 13px;
      font-weight: 500;
      transition: all 0.2s;
    }
    .page-btn:hover:not(:disabled) {
      background-color: #ebf8ff;
      border-color: #3182ce;
      color: #2b6cb0;
    }
    .page-btn.active {
      background-color: #1a365d;
      color: white;
      border-color: #1a365d;
      font-weight: 700;
      box-shadow: 0 2px 6px rgba(26, 54, 93, 0.25);
    }
    .page-btn:disabled {
      opacity: 0.5;
      cursor: not-allowed;
      background-color: #f7fafc;
    }
    .page-info { font-size: 13px; color: #64748b; margin: 0 8px; }

    @media (max-width: 768px) {
      .nav-links li { margin: 12px 0; width: 100%; text-align: center; position: relative; }
      .dropdown { position: static !important; opacity: 1 !important; visibility: visible !important; transform: none !important; box-shadow: none; background-color: #2d3748; max-height: 0; overflow: hidden; transition: max-height 0.3s ease; margin-top: 8px; border-radius: 6px; width: 80%; margin-left: auto; margin-right: auto; display: flex; flex-direction: column; align-items: center; padding: 0; }
      .nav-links li:hover .dropdown, .nav-links li:focus-within .dropdown { max-height: 300px; padding: 8px 0; }
      .dropdown a { padding: 10px 0; text-align: center; font-size: 15px; color: #cbd5e0; width: 100%; display: flex; justify-content: center; align-items: center; text-decoration: none; transition: background-color 0.2s; }
      .dropdown a:hover { background-color: #4a5568; color: white; }

      .container { padding: 0 12px; }
      .page-header { margin: 20px auto 0; padding: 20px 16px; border-radius: 10px; }
      .page-title { font-size: 19px; }
      .search-container { margin: 14px auto 0; padding: 18px 16px; border-radius: 10px; }
      .search-box { flex-direction: column; align-items: stretch; gap: 10px; flex-wrap: wrap; }
      .search-options { justify-content: center; padding-right: 0; width: 100%; }
      .search-box input[type="text"], .search-box button { width: 100%; }

      .results-frame { border-radius: 10px; }
      .results-header { padding: 14px 14px; font-size: 14px; }
      .results-controls { margin-left: 0; width: 100%; justify-content: center; margin-top: 10px; flex-wrap: wrap; }
      .result-filter-area { flex-direction: column; align-items: stretch; gap: 10px; padding: 12px 14px; }
      .filter-input-group { width: 100%; min-width: auto; }
      .nmd-filter-container { justify-content: center; padding-left: 0; border-left: none; width: 100%; }
      .nmd-filter-select { flex: 1; min-width: 0; }
      .filter-count-info { text-align: center; width: 100%; }
      .results-table-container { padding: 10px 12px; }

      .header-row td:nth-child(2) { padding: 10px 12px; font-size: 13px; }
      .detail-card { padding: 10px 12px; }
      .detail-card th, .detail-card td { font-size: 11px; padding: 6px 6px !important; }
      .detail-card th:nth-child(1), .detail-card td:nth-child(1) { width: 10% !important; }
      .detail-card th:nth-child(2), .detail-card td:nth-child(2) { width: 25% !important; }
      .detail-card th:nth-child(3), .detail-card td:nth-child(3) { width: 20% !important; }
      .detail-card th:nth-child(4), .detail-card td:nth-child(4) { width: 10% !important; }
      .detail-card th:nth-child(5), .detail-card td:nth-child(5) { width: 15% !important; }
      .detail-card th:nth-child(6), .detail-card td:nth-child(6) { width: 20% !important; }

      .pagination-container { gap: 4px; padding: 12px 10px 14px; }
      .page-btn { padding: 5px 9px; font-size: 12px; }

    }
    main.container { padding-bottom: 40px; }
  
  
